1
00:00:00,330 --> 00:00:01,170
High or whatever.

2
00:00:01,280 --> 00:00:07,430
So now it's time to go to our main activity class and actually create some valuables in order to actually

3
00:00:07,730 --> 00:00:09,750
access these user interface components.

4
00:00:09,760 --> 00:00:14,920
But you can see that we have not changed that the taste of the Spartan So let's go to the activity under

5
00:00:14,920 --> 00:00:20,650
the light minute example here and as you can see I changed the text of this button but it's not reflecting

6
00:00:20,650 --> 00:00:20,930
here.

7
00:00:20,930 --> 00:00:22,950
So let me actually run the application again.

8
00:00:23,180 --> 00:00:26,620
So now you can see that the text of this button is get that data.

9
00:00:26,780 --> 00:00:28,550
So everything is fine so far.

10
00:00:28,580 --> 00:00:30,810
Let's go to the Android studio and let's go to them.

11
00:00:30,930 --> 00:00:36,890
Put them in the class and at the top of the file here here inside is main activity class.

12
00:00:36,890 --> 00:00:39,190
I'm going to actually create somebody else.

13
00:00:39,230 --> 00:00:44,330
The first valuable that you are going to create is going to be off the edit text so I can say edit text

14
00:00:45,260 --> 00:00:48,090
and the name of this variable is going to be EDT.

15
00:00:48,230 --> 00:00:50,850
Address right semicolon.

16
00:00:51,350 --> 00:00:55,340
The second variable it again is going to be that it takes and the name of this rally is going to be

17
00:00:55,340 --> 00:00:58,240
my EDT mph.

18
00:00:58,310 --> 00:01:09,420
So I can say EDT miles per hour semicolon the first variable is going to be again of think it takes.

19
00:01:09,420 --> 00:01:11,320
And it is going to be meters per mile.

20
00:01:11,370 --> 00:01:22,050
So I can't say it takes the name of this variable is going to be meter's jeremiad semi-colon and we

21
00:01:22,050 --> 00:01:25,960
need to actually create two more valuable for these picks views.

22
00:01:25,960 --> 00:01:37,960
So I can say Take few takes the distance semicolon and another takes a view for these takes for the

23
00:01:37,960 --> 00:01:39,090
time.

24
00:01:39,190 --> 00:01:45,640
So the next value is going to be after it again takes a few takes the time semi-colon.

25
00:01:45,790 --> 00:01:54,690
And finally we have the button button PTEN actually get the data semi-colon.

26
00:01:54,690 --> 00:02:00,270
So now that we have these valuable Let's actually initialize them inside our uncreate method.

27
00:02:00,480 --> 00:02:06,040
So let's go inside these and create Meffert and here after this set the content view method here.

28
00:02:06,330 --> 00:02:10,340
I can actually say it is the address assignment operator.

29
00:02:10,410 --> 00:02:18,480
Actually cast this object to our text editor object actually and it takes fine view by ID or that Id

30
00:02:18,500 --> 00:02:25,750
dot EDT address semicolon EDT mph assignment operator.

31
00:02:25,770 --> 00:02:35,360
It's actually Chrestus object to an edit text object find view by I-T or thoughts ID that EDT mph semicolon

32
00:02:36,090 --> 00:02:37,940
on the next rally.

33
00:02:37,980 --> 00:02:41,120
Is going to be actually this one.

34
00:02:41,150 --> 00:02:42,910
It the meters per mile.

35
00:02:42,910 --> 00:02:47,640
So let's actually change the name of this variable here to EDT meters per hour per mile.

36
00:02:47,660 --> 00:02:53,690
EDT meteor's pair might right.

37
00:02:53,690 --> 00:02:59,990
So there is actually a consistency here so I can say EDT meters per mile assignment operator less cast

38
00:02:59,990 --> 00:03:02,550
this object to an edit text object.

39
00:03:02,690 --> 00:03:12,290
And here I can't say find view about ID are that Id dot EDT meters Pyrmont right semicolon.

40
00:03:12,420 --> 00:03:15,020
Now unless actually initialize Arctic's view.

41
00:03:15,080 --> 00:03:26,840
So the distance assignment operator cast it to an object find via by ID are thought Id gutty X the this

42
00:03:26,850 --> 00:03:31,440
then its value semicolon and the next one is takes the time.

43
00:03:31,450 --> 00:03:37,660
So it takes the time assignment operator lets get this object to a text view object fine view by ID

44
00:03:37,960 --> 00:03:43,530
or that ID that takes the time to waste the time semi-colon.

45
00:03:43,630 --> 00:03:47,740
And we have this PTEN get the data so Pythian get the later.

46
00:03:47,770 --> 00:03:57,100
I mean operator lets cast this object to a button object find view Id artist Id dot PTEN get the data

47
00:03:57,350 --> 00:03:59,000
semicolon.

48
00:03:59,010 --> 00:04:05,820
Now let's actually say that this class main activity actually conforms to a view that unclick listener.

49
00:04:05,990 --> 00:04:09,250
So here I can say PTEN get the data.

50
00:04:09,290 --> 00:04:15,470
So after this line of what I'm going to say that set of listener set on unclick listener and we need

51
00:04:15,470 --> 00:04:18,100
to pass the context main activity that is right.

52
00:04:18,320 --> 00:04:23,610
So here we have an error and that's because the main Akhal-Teke class is not actually implementing the

53
00:04:23,930 --> 00:04:26,750
unclick listener interface Solus scroll to the top.

54
00:04:27,080 --> 00:04:29,110
And here it says employment's.

55
00:04:29,120 --> 00:04:35,110
So here we are already conforming or implementing these two interfaces so let's put a comma here.

56
00:04:35,150 --> 00:04:41,790
Let's also implement the view dot unclick listener interface on click listener.

57
00:04:42,140 --> 00:04:47,770
So now that you are actually implementing these unclick this in an interface we need to actually overwrite

58
00:04:48,260 --> 00:04:49,380
the unclick method.

59
00:04:49,430 --> 00:04:50,620
So let's scroll down here.

60
00:04:50,630 --> 00:04:56,800
After the incredible pace of these uncreate Smurfit inside is main activity class I can't just point

61
00:04:56,940 --> 00:05:05,230
on click on click so just press on until you're on your keyboard in order to select Smurfette and you

62
00:05:05,230 --> 00:05:10,750
can see that if it is actually overlaid it here so we can use our we can actually put our coats here

63
00:05:10,750 --> 00:05:16,900
inside the Smurfette So we are ready to add some implementations inside this unclick method in the next

64
00:05:16,900 --> 00:05:17,780
tutorial.

65
00:05:18,040 --> 00:05:21,140
Thank you very much for watching and I'll see you in the next story.

