1
00:00:00,420 --> 00:00:07,770
So now let's actually click on these values folder here and then right click on it and a new and deadly

2
00:00:07,980 --> 00:00:09,680
value resource file.

3
00:00:09,750 --> 00:00:12,690
So here for the name just a pin here.

4
00:00:13,700 --> 00:00:18,500
And as you can see here the source said is Main and that directory name is values.

5
00:00:18,660 --> 00:00:20,190
And then click on OK.

6
00:00:20,550 --> 00:00:25,590
So as you can see here now we have another XML file inside these values folder.

7
00:00:25,590 --> 00:00:31,110
So here as you can see it let me actually double click on this is that ASML file type here as you can

8
00:00:31,110 --> 00:00:34,240
see just double click on this type here in order to make this area right there.

9
00:00:34,440 --> 00:00:36,800
And inside is Resources page.

10
00:00:36,810 --> 00:00:42,000
I'm going to put put paste in some lines of code here and then I'm going to explain to you what's going

11
00:00:42,000 --> 00:00:42,950
on here.

12
00:00:42,960 --> 00:00:48,980
So as you can see here these are the lines of code that I pasted here inside these three sources.

13
00:00:49,230 --> 00:00:55,830
So here we have a three inch alle resource here and the name is number of guesses at least right.

14
00:00:55,830 --> 00:01:00,270
So number underline of underlined guesses underline a list.

15
00:01:00,300 --> 00:01:03,850
So this is the exact name that we have inside this quiz.

16
00:01:03,900 --> 00:01:10,530
Underline preprocess that exemplified as you can see here for the entries here I actually referred to

17
00:01:10,530 --> 00:01:14,030
the name of this area here and I raised that example at St..

18
00:01:14,040 --> 00:01:16,600
Add a slash number of guests list.

19
00:01:16,620 --> 00:01:22,470
And we also provided this value for the entry values at St R8 slash number.

20
00:01:22,470 --> 00:01:25,950
Number of guesses this and as you can see here the error is gone right.

21
00:01:25,950 --> 00:01:27,310
So let's go back to our advice.

22
00:01:27,360 --> 00:01:28,970
RH that isn't on fire here.

23
00:01:29,220 --> 00:01:34,560
So here we have I staring at a resource here as you can see and the name is number of guesses least.

24
00:01:34,680 --> 00:01:40,580
And here inside this source at a year inside this is staring at a resource we have some items right.

25
00:01:40,590 --> 00:01:43,190
We have an array of integer values right.

26
00:01:43,200 --> 00:01:45,780
So the first item is number two.

27
00:01:45,810 --> 00:01:49,880
The second item is number four and the first item is number 6.

28
00:01:49,890 --> 00:01:52,280
So these are going to be the guest options right.

29
00:01:52,320 --> 00:01:56,610
The user can actually select whether he wants he or she wants to.

30
00:01:56,730 --> 00:02:03,650
The queen actually has two options to get buttons or false buttons or six just put the guest buttons.

31
00:02:03,690 --> 00:02:06,010
So let me show you this on the emulator.

32
00:02:06,060 --> 00:02:09,250
So as you can see here this is our application animalcules.

33
00:02:09,360 --> 00:02:12,210
And as you can see here we have 40 Spartans.

34
00:02:12,270 --> 00:02:17,910
So if we actually click on this in here and now if I click on this number of guesses here as you can

35
00:02:17,910 --> 00:02:22,410
see I can actually select six here and if I click on this back button here.

36
00:02:22,530 --> 00:02:26,560
Now as you can see here we have six options here right.

37
00:02:26,580 --> 00:02:29,190
So that's why we created this string arrows here.

38
00:02:29,190 --> 00:02:30,370
Right.

39
00:02:30,390 --> 00:02:32,930
So hopefully that makes sense.

40
00:02:32,940 --> 00:02:35,760
So that's why I actually put these options here.

41
00:02:35,760 --> 00:02:42,390
As you can see I actually created this string at a here in order to provide two values to four or six

42
00:02:42,930 --> 00:02:44,140
number of guesses list.

43
00:02:44,160 --> 00:02:44,700
Right.

44
00:02:44,700 --> 00:02:46,560
So hopefully that makes sense.

45
00:02:46,590 --> 00:02:52,320
And now let's actually go back inside this quiz on the airline preferences that they exemplified and

46
00:02:52,320 --> 00:02:53,490
here as you can see.

47
00:02:53,560 --> 00:02:59,220
Now I'm going to actually in some more lines of code here and then I'm going to explain to you what's

48
00:02:59,220 --> 00:03:00,500
going on here.

49
00:03:00,510 --> 00:03:05,420
So as you can see here these are lines of code that I pasted here.

50
00:03:05,430 --> 00:03:08,610
So here we have a multi selection list preference.

51
00:03:08,820 --> 00:03:15,120
So let me actually show you the emulator here and see if I click on the Settings button here.

52
00:03:15,120 --> 00:03:23,460
Now as you can see if we actually select these animals here these animals up option as you can see now

53
00:03:23,730 --> 00:03:29,440
we have this Actually the checklist right before it actually clicked and clicked on this number the

54
00:03:29,550 --> 00:03:30,700
number of guesses.

55
00:03:30,700 --> 00:03:31,370
I'll get him here.

56
00:03:31,380 --> 00:03:34,140
As you can see we had a radio about.

57
00:03:34,170 --> 00:03:36,630
As you can see here we have some of your buttons.

58
00:03:36,640 --> 00:03:38,030
I'll let you go actually.

59
00:03:38,250 --> 00:03:44,120
But here now if we actually click on this animals item now you can see here we have a checklist right.

60
00:03:44,130 --> 00:03:49,740
We have a group of checklists and this means that we can actually select whether we have what we want

61
00:03:49,980 --> 00:03:53,630
wild animals or tame animals in inside our cookies.

62
00:03:53,640 --> 00:03:54,440
Right.

63
00:03:54,480 --> 00:04:00,570
So as you can see here in order to provide a group of checklists inside your quiz inside the settings

64
00:04:00,600 --> 00:04:05,760
as you can see here you need to actually provide a multi selection or multi-select list preference as

65
00:04:05,760 --> 00:04:06,580
you can see here.

66
00:04:06,630 --> 00:04:07,190
Right.

67
00:04:07,200 --> 00:04:14,040
So I created a multi-select list preference and here for the entries here as you can see again you referred

68
00:04:14,280 --> 00:04:15,350
to at site arey.

69
00:04:15,390 --> 00:04:19,650
And this refers to this address that exemplified slash type of animals.

70
00:04:19,650 --> 00:04:20,250
Right.

71
00:04:20,250 --> 00:04:24,170
So let's actually copy this type of animals here.

72
00:04:24,960 --> 00:04:28,320
And let's actually go inside these areas that examen file.

73
00:04:28,490 --> 00:04:31,190
And now this create another string at a.

74
00:04:31,220 --> 00:04:37,130
So let's open attach and just they've been here strange R8 and the name is going to be that value that

75
00:04:37,130 --> 00:04:39,430
the copied what type of animals.

76
00:04:39,440 --> 00:04:40,080
Right.

77
00:04:40,100 --> 00:04:42,260
And then there's the close this time here.

78
00:04:42,470 --> 00:04:44,990
And now let's actually go inside this area here.

79
00:04:45,050 --> 00:04:52,220
Let's go inside it is a tag here and now we can actually provide some items for example the first item

80
00:04:52,520 --> 00:04:55,030
and then I need to close this item tag.

81
00:04:55,460 --> 00:05:03,140
And here for the value I can't just type in wild animals and let's actually create another item.

82
00:05:03,140 --> 00:05:11,040
So item and I need to close this item tag here and here I can just typing tame animals.

83
00:05:11,420 --> 00:05:12,240
Right.

84
00:05:12,290 --> 00:05:17,480
So as you can see here we have two items in sight these type of animals staring at me.

85
00:05:17,510 --> 00:05:18,180
Right.

86
00:05:18,200 --> 00:05:25,100
So now if I show you the emulator here as you can see we have these animals here as you can see and

87
00:05:25,160 --> 00:05:26,170
we have two options.

88
00:05:26,180 --> 00:05:28,410
Voit animals and tame animals.

89
00:05:28,640 --> 00:05:35,040
So now this is very important that you actually provide these items here for these type of animals here.

90
00:05:35,270 --> 00:05:38,970
Let's go back to our quiz underlined preferences that exemplify.

91
00:05:39,380 --> 00:05:43,230
So as you can see here I actually provided this entries values here right.

92
00:05:43,310 --> 00:05:44,200
Type of animals.

93
00:05:44,210 --> 00:05:46,270
And as you can see here the arrow is gone.

94
00:05:46,790 --> 00:05:52,310
But I told you that these values as you can see here type of animals are the values that are going to

95
00:05:52,310 --> 00:05:54,820
be shown to the user right.

96
00:05:54,830 --> 00:05:56,750
Avoid animals or tame animals.

97
00:05:56,750 --> 00:05:59,450
These are the values that are going to be shown to the user.

98
00:05:59,690 --> 00:06:02,880
But we also have three values as you can see here.

99
00:06:02,960 --> 00:06:04,550
These are the actual values.

100
00:06:04,550 --> 00:06:07,240
These are the values that we are going to work with.

101
00:06:07,310 --> 00:06:07,700
Right.

102
00:06:07,760 --> 00:06:08,570
So at St..

103
00:06:08,660 --> 00:06:14,330
So again it refers to these areas that exemplified slash type of animals are values.

104
00:06:14,390 --> 00:06:20,080
So let's actually copy disvalue here and now let's actually go inside this outrace that is unmodified.

105
00:06:20,240 --> 00:06:22,600
Let's create another thing out of here.

106
00:06:22,670 --> 00:06:25,720
So let's open attack just like in here starting at 8:00.

107
00:06:25,850 --> 00:06:32,960
And for the name just paste that value here type of animals values type underline of underline animals

108
00:06:32,990 --> 00:06:34,110
underline values.

109
00:06:34,220 --> 00:06:36,560
And now let's actually close this tag here.

110
00:06:36,710 --> 00:06:40,730
So now inside this string area here I need to actually provide some items.

111
00:06:40,730 --> 00:06:42,380
So item.

112
00:06:42,410 --> 00:06:50,710
And now let's actually close this item here and here for the value and just type in void underline animals.

113
00:06:50,990 --> 00:06:54,830
So this is very important that you put underline here later.

114
00:06:55,090 --> 00:06:57,530
And we are going to work with this value.

115
00:06:57,710 --> 00:07:01,790
I'll show you how important it is to put this on the line here.

116
00:07:01,790 --> 00:07:03,920
But for now just put this underline here OK.

117
00:07:03,970 --> 00:07:09,610
Wild under like animals and remember that this is the value that we are going to work with.

118
00:07:09,680 --> 00:07:12,790
This is the type of animals values right.

119
00:07:12,950 --> 00:07:16,920
And this is the values as you can see here that are going to be shown to the user.

120
00:07:17,090 --> 00:07:21,570
But at this type of animal's values are going to be the values that you're going to work with.

121
00:07:21,800 --> 00:07:26,870
So let's create another item and let's close this item and just type it here.

122
00:07:26,920 --> 00:07:31,000
Came on the line and Namath's right.

123
00:07:31,010 --> 00:07:34,290
So now as you can see here we have two items inside the three at a.

124
00:07:34,400 --> 00:07:37,230
So let's go back to our inside this quick quiz.

125
00:07:37,260 --> 00:07:39,530
Underline pre-processed that they seem fine.

126
00:07:39,890 --> 00:07:41,800
And now as you can see here the error is gone here.

127
00:07:41,810 --> 00:07:42,580
Right.

128
00:07:42,650 --> 00:07:50,060
So now let's actually let's actually look at this attribute here is the key.

129
00:07:50,190 --> 00:07:51,060
As you can see here.

130
00:07:51,090 --> 00:07:55,110
So the key is setting underline animal type.

131
00:07:55,110 --> 00:07:55,690
Right.

132
00:07:55,890 --> 00:08:00,810
So the key is settings underline animals type.

133
00:08:00,810 --> 00:08:03,460
So just take this value here for the key attribute.

134
00:08:03,690 --> 00:08:06,690
And again if you have another attribute title.

135
00:08:06,690 --> 00:08:12,150
So again this title here as you can see refers to these streams that XML file as you can see here we

136
00:08:12,150 --> 00:08:14,400
have these strings that exemplify.

137
00:08:14,730 --> 00:08:21,080
And now inside this quiz underline preferences that SML you are actually referring to that void at sign

138
00:08:21,090 --> 00:08:24,860
and slash animal types titel right.

139
00:08:24,900 --> 00:08:26,910
So this is going to be the title.

140
00:08:26,910 --> 00:08:28,950
So let me show you the emulator here.

141
00:08:28,950 --> 00:08:31,690
As you can see the title is animals.

142
00:08:31,800 --> 00:08:32,390
Right.

143
00:08:32,460 --> 00:08:37,300
And here disvalue here is type of animals that you can include in the crease.

144
00:08:37,380 --> 00:08:39,650
So this is going to be the description the summary.

145
00:08:39,660 --> 00:08:41,510
And this one animal is the title.

146
00:08:41,610 --> 00:08:48,270
So as you can see here at same strength slash animal types titel is a value that we have inside these

147
00:08:48,660 --> 00:08:53,530
strings that is them and what you have not decided yet does actually create that value such just copy

148
00:08:53,520 --> 00:09:00,440
this value here animal underline types underline the title and let's go inside the strings resembled

149
00:09:00,440 --> 00:09:04,900
file and actually create another string resource.

150
00:09:04,970 --> 00:09:05,970
Just type in here.

151
00:09:05,970 --> 00:09:06,770
Strange.

152
00:09:07,020 --> 00:09:11,430
And for the name just replace that value animal types title.

153
00:09:11,450 --> 00:09:13,430
And now that's actually close.

154
00:09:13,560 --> 00:09:15,840
String resources still intact.

155
00:09:16,200 --> 00:09:20,070
And now for the value as you can see the title is animals right.

156
00:09:20,070 --> 00:09:25,460
So here I can't just type in animals as easy as that.

157
00:09:25,470 --> 00:09:31,320
So now let's actually go inside this quiz underline preferences that exemplified and as again as I can

158
00:09:31,320 --> 00:09:33,090
see the error is gone here.

159
00:09:33,090 --> 00:09:36,150
So now as you can see we have some of the attributes.

160
00:09:36,150 --> 00:09:40,260
So again this summary attributes for the first two these scientists.

161
00:09:40,350 --> 00:09:42,940
Are these strings that resemble files you can see here.

162
00:09:42,990 --> 00:09:46,350
So at science three inch slash animal types description.

163
00:09:46,350 --> 00:09:46,800
Right.

164
00:09:46,950 --> 00:09:52,190
So now here as you can see the description is type of animals that you can include in the quiz.

165
00:09:52,200 --> 00:09:58,930
So now it's actually capitis name here animal underlined types underline description and Eskil inside

166
00:09:59,070 --> 00:10:00,490
things that are exemplified.

167
00:10:00,660 --> 00:10:08,080
And now let's actually create another string actually let's create another screen resource.

168
00:10:08,100 --> 00:10:11,790
So just I just just open a tag and just type in here strange.

169
00:10:11,970 --> 00:10:14,730
And for the name just paste this value here.

170
00:10:14,730 --> 00:10:16,330
Animal types description.

171
00:10:16,470 --> 00:10:20,770
And let's actually close this page here and look for value.

172
00:10:20,790 --> 00:10:24,890
As you can see here the value is type of animals that you can include in the crease.

173
00:10:24,900 --> 00:10:31,290
So here's just a total value here type of animals

174
00:10:34,340 --> 00:10:41,170
that you can include in the quiz.

175
00:10:41,730 --> 00:10:42,840
Right.

176
00:10:42,900 --> 00:10:45,570
So as you can see here it is that value.

177
00:10:46,020 --> 00:10:48,360
So now we can get you to just type.

178
00:10:48,360 --> 00:10:49,500
Types of animals.

179
00:10:49,500 --> 00:10:50,160
OK.

180
00:10:50,550 --> 00:10:52,770
This may be grammatically correct.

181
00:10:52,770 --> 00:10:56,280
So as you can see here we actually provided this right here and now.

182
00:10:56,340 --> 00:11:00,070
Let's actually go inside this quiz underlined preferences that exemplified.

183
00:11:00,210 --> 00:11:02,660
And now as you can see here the error is gone.

184
00:11:02,880 --> 00:11:06,060
And here again we have this persistent attribute.

185
00:11:06,070 --> 00:11:09,830
So this is a very important attribute to persistent.

186
00:11:10,260 --> 00:11:12,720
And as you can see here I assigned the value true.

187
00:11:12,810 --> 00:11:19,260
So remember that I told you this attribute is going to actually persist these settings to the shirt

188
00:11:19,260 --> 00:11:26,550
preferences that we have inside our Android device that is actually specific only to our application

189
00:11:26,730 --> 00:11:28,670
inside our Android device.

190
00:11:28,800 --> 00:11:32,410
So then we actually assign the value true to this persistent attributes.

191
00:11:32,490 --> 00:11:40,020
It's going to actually persist those settings that we actually change inside our application to the

192
00:11:40,470 --> 00:11:41,420
shared preferences.

193
00:11:41,430 --> 00:11:46,680
And later when we are ready we want to actually open our application again if it can actually delete

194
00:11:46,980 --> 00:11:50,780
those settings from the shared preferences and we'll go.

195
00:11:50,820 --> 00:11:54,860
And then we are sure that our settings are actually saved.

196
00:11:55,050 --> 00:12:01,530
So this is very important that you assign the value true to this persistent attribute and you have this

197
00:12:01,530 --> 00:12:03,420
default value as you can see here.

198
00:12:03,420 --> 00:12:08,010
So the default value is going to be for example the value for that for the first time that the user

199
00:12:08,190 --> 00:12:10,450
is actually using this application.

200
00:12:10,530 --> 00:12:17,580
The default value is going to be for example that does both of these search boxes are going to be checked.

201
00:12:17,580 --> 00:12:21,360
So for the default value I actually referred to this as site error.

202
00:12:21,360 --> 00:12:21,830
Here it is.

203
00:12:21,830 --> 00:12:27,050
Address that XML file and pipe up animals values as you can see here.

204
00:12:27,210 --> 00:12:32,940
So again I told you this type of animal values inside these alleys that resemble these values are going

205
00:12:32,940 --> 00:12:35,150
to be the values that we are going to work with.

206
00:12:35,190 --> 00:12:35,670
OK.

207
00:12:35,820 --> 00:12:43,190
And these values type of animals are going to be the values that the user is going to be going to see.

208
00:12:43,410 --> 00:12:43,870
OK.

209
00:12:44,010 --> 00:12:49,860
So here because we want to use these values as you can see here and here actually referred to this area

210
00:12:49,890 --> 00:12:51,600
here type of animal values.

211
00:12:51,600 --> 00:12:53,910
And this means that we want both of these options.

212
00:12:53,930 --> 00:12:54,120
OK.

213
00:12:54,150 --> 00:12:58,540
And we want both of these checkboxes to be checked.

214
00:12:58,590 --> 00:13:00,810
OK this is really important.

215
00:13:00,810 --> 00:13:05,670
So let's go back to our quiz underlined preferences that examined file and as you can see here for the

216
00:13:05,670 --> 00:13:10,610
default value I assign this value as a sign or a slash type of animals values.

217
00:13:10,650 --> 00:13:13,700
So this is our multi-select list preference.

218
00:13:13,710 --> 00:13:13,940
OK.

219
00:13:13,950 --> 00:13:22,440
This is for creating checklists for our settings and list preference is for creating a radio group that

220
00:13:22,440 --> 00:13:25,670
actually contains the radio buttons inside our settings.

221
00:13:25,680 --> 00:13:27,300
So this is very important.

222
00:13:27,300 --> 00:13:33,480
And now let's actually paste in some more lines of code here and then I'm going to explain to you what's

223
00:13:33,480 --> 00:13:34,510
going on here.

