Hire everyone in this theater you are really going to go ahead and create another Android application.
So just click on this.
Start on your Android studio project here and then for the application name just type in your app 52
and then click on next year and then he had to choose a 16 Android 4.1 Jelly Bean for minimum STK clicker.
Next he heads to his blench activity next and then click on finish.
So here selectees hello work takes you here and in person delete key on your keyboard and then double
click on the rest folder.
Lay out activity underline that example and then choose this flicking action button and then press on
delete key on your keyboard.
OK so now let's get you to go back and say this our content underline minute example and then here we
need to actually design the user interface of our application.
Now let's actually track our linearly out vertical here as you can see selectees linearly aesthetical
and put it at the center of this relatively here and now let's actually drag a large text view here
at the center of this linearly and vertical double click on it.
And here are delete the text of the stakes for you and for the ID just type in here TXI the value and
then press on and to the key on your keyboard.
OK.
And now let's actually track.
Actually a text field into this linearly alphabetical.
So as you can see here inside these takes real fall there you have lots of text fields here.
OK.
So I just select this plain text field here and put it below.
This takes you and insight is linearly elsewhere stickle here.
OK.
And double click on it and for the ID just type in here EDT value and then person enter key on your
keyboard and then lets actually direct and autocomplete it takes you into this linearly outworks the
call.
So as you can see here are inside this expert folder as you can see we have an auto complete text view
here.
OK.
So just select this takes view and put it up with this edit text.
Here are the stakes real here.
OK.
And double click on it deletes the text of this takes all the complete text view.
And for the OED or just leave this idea as default.
OK.
Well to a complete text and then press on and to key on your keyboard and then let's actually do like
a multi autocomplete takes you into these linearly aesthetical so put it at the center of this linearly
outwards call up double clicking on it deletes the takes of these takes and leave the ID as as default.
Ok multi or to complete text.
OK.
Now let's actually go back inside.
Inside this main activity that have a fight here and then it's actually delete these lines of code that
are related to the Options menu.
OK.
And then as I actually did delete these are lines of code that are related with a floating action button
here.
OK.
Now we can actually put in our own code here.
OK.
So now inside of this main activity class I'm going to actually pasting some lines of code and then
I'm going to explain to you what's going on here.
So as you can see here these are the lines of code that they actually paste that here.
So first about in line 13 I actually declared an object of type text view and the name of this object
is the value here in line 14.
I declared an object of type edit edit text as you can see and the name of this object is it is the
value and in line 15 I actually are declared an object of type or to a complete text view and the name
of this object is autocomplete text.
OK.
And 16 I actually declared another object of type T or to accomplish takes view and the name of this
object is Motti or to complete text view OK.
And in a second I am going to actually explain to you how we can actually use these two new objects.
OK I'm going to explain to you how we can use these objects.
OK.
So first of all are we going to actually instantiate these objects that we actually declared inside
of this main activity class.
OK so inside of this uncreate a moped.
I'm going to instantiate these objects.
So now I'm going to paste in some lines of code and then I'm going to explain to you what's going on
here.
So as you can see here these are the lines of code that they actually pasted here.
And first of all in line 26 I actually instantiated this takes the value objects that I actually create
created in line 15 and inline 26 inside of this uncreate Meffert instantiating this object.
So as you can see here I am referring to the name of this ID or that Id 30 x the value at inline 27
I am instantiating this as it takes object find view by id r that ID that it is the value and in line
28 instantiating this autocomplete takes object.
And here as you can see I am referring to the name of this ID are the ID that or to copy text view and
11:29 by instantiating this Motti autocomplete takes view.
And as you can see here I am referring to the name of the ID art that idea that multi autocomplete takes
to you.
OK.
So hopefully that makes sense.
So now I'm going to actually pasting two lines of code here and then I'm going to explain to you what's
going on here.
So as you can see here I pasted these lines of code here.
First of all in line festively I want to actually set some text to these TXI the value object.
So I just revert to the name of this object DXP value that set text.
Awesome.
OK.
And he had a line of metaphor I want to actually change the background color of this text the value
object as you can see here.
So I just referred to the name of this object TXI the value that said background color color that's
blue.
OK.
And now let's actually run our project and see what happens.
So as you can see our application is running on this emulator.
And as you can see here the text of these takes is awesome.
OK.
And the background color of this text is blue.
OK.
And as you can see here this is our text and this is our autocomplete takes few.
And this is our multi overcomplicates.
Later in the story actually explain to you how we can use these to our text use here.
This autocomplete takes few and these multi are too complex.
OK.
So let's actually to go back inside this main activity the java file here.
And now I'm going to make these make these itx the value object a listener.
OK.
So here I can just type in TXI the value that's set on a click listener.
OK.
And here I need to actually put it into context.
OK.
So here I just need to put in the class that would be the listener.
OK.
So here I just want to make this DXi value object the listener and inside Apprentice's of this set up
like this in an effort I need to specify that the class that is actually a listener to these are click
through the clicks that you use and make on this RTX the body object.
OK so here I can just typing main activity class that this.
OK.
And here as you can see it's now showing us an error.
So here we need to actually implement this interface implement our view that unclick listener.
OK so this is actually an interface.
OK and here we need to actually implement the abstract method that we actually inherit from this interface.
OK.
So class mean activity must either be declared abstract or implement an abstract method on a college
view.
In unclick listen.
OK so here after the Indian calibrates of this uncreate Mefford I just need to overwrite that the Anklage
method.
OK.
Unclick.
And as you can see here now I am actually overwriting this uncle Moffit that we actually inherit from
Rambis interface.
So there is actually an is a relationship between these main activity class and this view that unclick
listener interface.
OK.
So now I just make this RTX the value object the listener.
And now as you can see the error is gone.
OK.
And now inside of this method I can just type in the value that sets takes the color text color.
And here inside the parenthesis I can just revert to the name of the color class color dots for example
right.
OK.
And let's actually run our project and see what happens.
So as you can see here our application is running on this emulator.
And now if I actually click on this text view here let's see what happens.
OK so now as you can see the column of a text view actually change the key the color of this text is
actually to change to let.
OK so that's because of execution of this line of code.
Here inside this unclear method.
OK.
So as you can see here I made these takes the value object a listener to the clicks of the user.
OK.
So hopefully that makes sense.
So now I want to actually also make these it is you value object as you can see here.
This is of type.
It detects the Cape.
I want to make this object a listener or to the clicks of the user.
So here I can just say EDT value that said Uncle listener.
OK.
And here inside Apprentice's I need to actually specify the context.
OK.
So here I am just typing this.
OK.
This refers to the name of this class.
OK.
And or I could actually just type in here.
Main main activity dot this.
OK.
It doesn't make any difference.
And now as you can see I already implemented this a view that unclick listener interface in sight of
this class.
OK.
And I also are overrated this ugly method but how we can actually differentiate between these two listeners.
OK.
We have we actually made this tax the value object.
A listener to the clicks of the user.
And we also mateys EDT value object a listener to the class of the user.
So here as you can see the view class is actually the superclass all the user interface components it
ends right.
OK.