1
00:00:00,540 --> 00:00:05,870
OK as you can see here it's now actually showing us are the same results.

2
00:00:05,880 --> 00:00:06,420
OK.

3
00:00:06,510 --> 00:00:11,200
The checkbox of this yes check box is actually checked on.

4
00:00:11,580 --> 00:00:12,190
OK.

5
00:00:12,480 --> 00:00:18,510
So the value of the box is actually true and the value of this check box is actually false.

6
00:00:18,810 --> 00:00:19,680
OK.

7
00:00:20,070 --> 00:00:21,860
So hopefully that makes sense.

8
00:00:21,870 --> 00:00:26,820
Let's actually go back and say this content's underline minute that example and then let's actually

9
00:00:27,110 --> 00:00:35,570
try again linearly out horizontally into this linearly out vertical and then let's actually gain a large

10
00:00:35,580 --> 00:00:39,130
takes you into These are linearly horizontal.

11
00:00:39,330 --> 00:00:44,430
So just click on this larger text here and then put it inside.

12
00:00:44,430 --> 00:00:51,470
These are linearly out horizontal Okay and then double click and these are large text view.

13
00:00:52,050 --> 00:00:56,110
And then for the text of this text you just type in here.

14
00:00:56,160 --> 00:00:58,720
True or false.

15
00:00:59,950 --> 00:01:00,940
OK.

16
00:01:01,310 --> 00:01:08,900
And then let's actually write in a checkbox into this linearly or horizontal and if by mistake you put

17
00:01:08,900 --> 00:01:15,290
this checkbox under this linear layout horizontal for example in here you can just delete this component

18
00:01:15,680 --> 00:01:21,050
or you can drag that component inside these are linearly out here.

19
00:01:21,050 --> 00:01:21,460
OK.

20
00:01:21,470 --> 00:01:29,900
So let's actually track a checkbox into this linearly or horizontal and then double click on this checkbox.

21
00:01:29,960 --> 00:01:32,830
So for that for the text of this checkbox just type in here.

22
00:01:32,870 --> 00:01:33,280
Yes.

23
00:01:33,300 --> 00:01:39,370
And for the ID just type in here C is x true or false.

24
00:01:40,020 --> 00:01:48,940
Yes OK and let's actually do i another checkbox into this linearly or horizontal.

25
00:01:48,940 --> 00:01:54,910
So just click on this checkbox here and then put it inside this linearly or horizontal.

26
00:01:55,180 --> 00:01:59,050
So double click on this checkbox and for the text just typing no.

27
00:01:59,260 --> 00:02:05,690
And for the ID just type in C is x true or false.

28
00:02:06,790 --> 00:02:09,180
No.

29
00:02:09,250 --> 00:02:14,260
So the idea of this checkbox as you can see here the idea of this checkbox is C-h x.

30
00:02:14,260 --> 00:02:15,710
True or false.

31
00:02:15,730 --> 00:02:16,800
Yes.

32
00:02:17,140 --> 00:02:19,970
And the idea of this checkbox is C H.

33
00:02:19,990 --> 00:02:20,850
True or false.

34
00:02:20,860 --> 00:02:21,190
No.

35
00:02:21,190 --> 00:02:21,650
OK.

36
00:02:21,700 --> 00:02:25,630
So let's actually click on this linearly and here and here.

37
00:02:25,660 --> 00:02:30,170
Check this checkbox that says Center underline horizontal.

38
00:02:30,540 --> 00:02:31,210
OK.

39
00:02:31,450 --> 00:02:37,990
Can can actually position these components horizontally in the center of this in the center of this

40
00:02:37,990 --> 00:02:39,130
linearly out.

41
00:02:39,340 --> 00:02:47,320
OK so now let's actually go back inside this main activity of a file Let's actually scroll to the top

42
00:02:47,320 --> 00:02:48,070
of the screen.

43
00:02:48,110 --> 00:02:52,230
And now let's actually scroll to the top of the file here.

44
00:02:52,650 --> 00:02:55,480
And this actually creates a comment here.

45
00:02:55,510 --> 00:02:59,770
True or false.

46
00:02:59,830 --> 00:03:09,410
So here I just need to create two checkbox objects so checkbox see X true or false.

47
00:03:10,120 --> 00:03:11,710
Yes.

48
00:03:11,710 --> 00:03:18,600
Assignment operator and then I need to cast this object to a checkbox object find view by ID or that

49
00:03:18,700 --> 00:03:24,550
Id dot c c is x true or false.

50
00:03:24,910 --> 00:03:26,580
Yes.

51
00:03:27,180 --> 00:03:33,940
Again let's actually create a checkbox object C is x true or false.

52
00:03:34,270 --> 00:03:47,620
No assignment operator checkbox find you by ID are taught ID that C is x true or false.

53
00:03:47,800 --> 00:03:49,910
No.

54
00:03:50,090 --> 00:03:50,730
OK.

55
00:03:50,980 --> 00:03:52,500
So hopefully that makes sense.

56
00:03:52,510 --> 00:03:55,540
Now lets actually interact with these objects.

57
00:03:55,540 --> 00:04:05,720
So scroll down the file here and then this actually creates a comment here so just type in here.

58
00:04:05,820 --> 00:04:09,100
True or false.

59
00:04:09,660 --> 00:04:10,440
OK.

60
00:04:10,830 --> 00:04:19,980
And then let's actually create a boolean variable true or false and then there's actually putting in

61
00:04:20,040 --> 00:04:25,590
an assignment operator here and then actually putting a pair of round brackets here.

62
00:04:25,800 --> 00:04:27,330
So here I am just typing.

63
00:04:27,390 --> 00:04:29,900
True or False.

64
00:04:29,910 --> 00:04:31,190
False.

65
00:04:31,920 --> 00:04:32,540
OK.

66
00:04:32,910 --> 00:04:36,550
And then I need to put in a semi-colon at the end of my statement.

67
00:04:36,770 --> 00:04:37,300
OK.

68
00:04:37,380 --> 00:04:42,900
So as you can see here first of all I actually created a variable of type Boolean and then I actually

69
00:04:42,900 --> 00:04:44,880
gave a name to this variable.

70
00:04:44,880 --> 00:04:46,160
True or false.

71
00:04:46,530 --> 00:04:49,720
And here I actually assigned a value to this variable.

72
00:04:50,010 --> 00:04:53,570
And here actually created a boolean expression.

73
00:04:53,850 --> 00:04:55,650
OK true or false.

74
00:04:55,680 --> 00:04:59,450
So the result of this expression is going to be assigned to this variable.

75
00:04:59,460 --> 00:05:03,090
Ok so now let's actually create and if statement here.

76
00:05:03,090 --> 00:05:09,410
If the value of this true or false value is actually true or false.

77
00:05:09,990 --> 00:05:16,980
OK if the value of these are true or false variable is actually true then execute this line of code

78
00:05:16,980 --> 00:05:19,080
here inside of this curly braces.

79
00:05:19,150 --> 00:05:22,440
C X true or false.

80
00:05:22,860 --> 00:05:27,070
Yes said said checked true.

81
00:05:27,750 --> 00:05:32,140
Otherwise else if the value of this.

82
00:05:32,140 --> 00:05:35,700
True or false value but is actually false.

83
00:05:35,790 --> 00:05:37,070
So exclamation mark.

84
00:05:37,140 --> 00:05:39,680
True or false.

85
00:05:40,070 --> 00:05:48,940
Ok then execute this line of code inside of this curly braces C H x true or false.

86
00:05:49,050 --> 00:05:52,830
No Dot said check it.

87
00:05:52,830 --> 00:05:54,140
True.

88
00:05:55,300 --> 00:05:59,320
OK so now let's actually run our project and see what happens.

89
00:05:59,370 --> 00:06:03,370
As you can see here our application is actually running on this emulator.

90
00:06:03,510 --> 00:06:08,630
And as you can see here the value of this true or false variable is actually true.

91
00:06:08,850 --> 00:06:13,950
OK the value of this search box is actually on the value of this checkbox is actually true.

92
00:06:14,010 --> 00:06:14,500
OK.

93
00:06:14,640 --> 00:06:15,860
Yes checkbox.

94
00:06:15,870 --> 00:06:16,660
OK.

95
00:06:17,040 --> 00:06:19,110
And let me explain again.

96
00:06:19,380 --> 00:06:25,470
First I actually created a value of type Boolean and then I actually assigned a boolean expression to

97
00:06:25,470 --> 00:06:33,510
this variable so the value of this boolean expression is actually to true so that true value is going

98
00:06:33,510 --> 00:06:35,380
to be assigned to this variable.

99
00:06:35,430 --> 00:06:38,580
And here I actually created an if else statement here.

100
00:06:38,790 --> 00:06:44,370
If the value of is true or false value but is actually true then it's going to try to execute this line

101
00:06:44,370 --> 00:06:45,240
of code here.

102
00:06:45,240 --> 00:06:48,370
So as you can see here the value of this checkbox is true.

103
00:06:48,570 --> 00:06:51,100
OK the search box is actually on.

104
00:06:51,330 --> 00:06:51,870
OK.

105
00:06:51,890 --> 00:06:54,620
Else if the value of this check.

106
00:06:54,810 --> 00:06:57,310
True or false value but is actually false.

107
00:06:57,480 --> 00:06:57,740
OK.

108
00:06:57,780 --> 00:06:59,070
Exclamation mark.

109
00:06:59,070 --> 00:07:00,680
True or false means.

110
00:07:00,840 --> 00:07:05,790
If the value of the check box is actually false OK then it's going to actually execute this line of

111
00:07:05,790 --> 00:07:06,410
code here.

112
00:07:06,540 --> 00:07:06,940
OK.

113
00:07:06,990 --> 00:07:12,720
So now let's actually comment out this if else statement here because I want to show you another way

114
00:07:12,720 --> 00:07:15,830
in order to write these codes.

115
00:07:15,840 --> 00:07:16,770
OK everyone.

116
00:07:16,770 --> 00:07:19,010
Now I can just type in here see x.

117
00:07:19,050 --> 00:07:21,220
True or false.

118
00:07:21,570 --> 00:07:22,280
Yes.

119
00:07:22,350 --> 00:07:27,890
That said I checked and then here I need to put in a pair of round brackets.

120
00:07:28,140 --> 00:07:34,920
And here I can't just type in true or false question mark.

121
00:07:34,980 --> 00:07:35,980
True.

122
00:07:36,470 --> 00:07:37,010
OK.

123
00:07:37,110 --> 00:07:39,070
Otherwise false.

124
00:07:39,740 --> 00:07:40,020
OK.

125
00:07:40,020 --> 00:07:48,840
And this means that if the value of this true or false variable is true then assign the value true to

126
00:07:48,840 --> 00:07:50,160
this said checked method.

127
00:07:50,190 --> 00:07:53,450
Otherwise assign the value funds to this.

128
00:07:53,460 --> 00:07:54,200
So check it.

129
00:07:54,210 --> 00:07:55,380
OK.

130
00:07:55,380 --> 00:08:00,440
So if you've got this valuable and be assigned this expression to are valuable.

131
00:08:00,540 --> 00:08:05,200
So the result of this expression is going to be assigned to this variable.

132
00:08:05,310 --> 00:08:11,160
And if the value of this variable is true then it's going to assign the value true to the Smurfette.

133
00:08:11,160 --> 00:08:14,630
Otherwise it's going to actually assign the value false to this method.

134
00:08:14,710 --> 00:08:18,960
Again I can just type in S.H. And it's true or false.

135
00:08:19,260 --> 00:08:21,590
No data set checked.

136
00:08:22,260 --> 00:08:26,470
And then here inside the prentices again I can just put in a pair of round brackets.

137
00:08:26,520 --> 00:08:27,750
Exclamation mark.

138
00:08:27,770 --> 00:08:28,770
True.

139
00:08:30,310 --> 00:08:31,770
Or false.

140
00:08:32,450 --> 00:08:32,980
OK.

141
00:08:32,980 --> 00:08:33,910
Question March.

142
00:08:33,960 --> 00:08:36,840
True otherwise false.

143
00:08:36,910 --> 00:08:37,510
OK.

144
00:08:37,510 --> 00:08:45,190
So as you can see here I specified that if the value of the is true or false variable is false then

145
00:08:45,250 --> 00:08:48,570
assign the value true to this said checked Meffert.

146
00:08:48,700 --> 00:08:52,760
Otherwise assign the value false to this set check for the key.

147
00:08:52,840 --> 00:08:57,380
So as you can see here we put this exclamation marks before this variable name.

148
00:08:57,460 --> 00:08:57,930
OK.

149
00:08:58,060 --> 00:09:04,630
If the value of this variable is false assign the value true to this search check if it is related to

150
00:09:04,640 --> 00:09:07,690
this CSX true or false no object.

151
00:09:07,720 --> 00:09:15,320
Otherwise if the value of this is true or false variable is true assign the value of funds to this search

152
00:09:15,430 --> 00:09:18,080
method that is related to this see x.

153
00:09:18,090 --> 00:09:20,620
True or false no object.

154
00:09:20,620 --> 00:09:23,420
So let's actually run our project and see the results.

155
00:09:23,500 --> 00:09:28,200
Ok everyone as you can see here now our application is actually running on this emulator here.

156
00:09:28,270 --> 00:09:33,010
And as you can see the value of this true or false value of it is true.

157
00:09:33,010 --> 00:09:33,600
OK.

158
00:09:33,940 --> 00:09:39,910
So this checkbox is actually checked on as you can see here the value of this true or false variable

159
00:09:39,910 --> 00:09:40,720
is true.

160
00:09:40,720 --> 00:09:45,440
So this line of code as you can see here is get executed OK.

161
00:09:45,550 --> 00:09:47,650
So hopefully that makes sense.

162
00:09:47,770 --> 00:09:51,670
And let's actually go back and say this content underline made that example.

163
00:09:51,850 --> 00:09:58,290
And then let's actually dragging another linearly out horizontal into this linear layout vertical.

164
00:09:58,590 --> 00:09:59,330
Okay.

165
00:09:59,710 --> 00:10:04,900
And then dreich in a large takes you into this linearly out horizontal here.

166
00:10:04,960 --> 00:10:12,100
You can also put it inside this linear horizontal here inside this componentry or here.

167
00:10:12,160 --> 00:10:12,740
OK.

