Okiee... Let's continue our game about button glowing... :v
Next let's add a new button in main layout....
Theeen... Instead of using clickListener, we are using touchListener here...
Aand the result is like this :
Okieee... That's the end of this part... :D
You can see my source code here....
Friday, May 20, 2016
Glowing Pressed Button Part I
This post will gonna show you steps for making a glowing button when pressed... :)
First let's create new project using android studio 2.1...
Next... Let's create our first button...
Then let's create new drawable xml file for default button gradient, right click on drawable folder, choose "New" then "Drawable resource file" as shown in picture below :
Give a name to that xml file :
Then give a code to default_gradient like this :
Nexxt... Add another drawable gradient {pressed_gradient} :
And then button_selector :
Aaaand.... finally we can assign this style to our button... :D
Result.....
Yeeeei... That's the end of part I... :D
Aaand.... You can download above android studio source code here....
Go to Part II....
First let's create new project using android studio 2.1...
Next... Let's create our first button...
Then let's create new drawable xml file for default button gradient, right click on drawable folder, choose "New" then "Drawable resource file" as shown in picture below :
Give a name to that xml file :
Then give a code to default_gradient like this :
And then button_selector :
Aaaand.... finally we can assign this style to our button... :D
Result.....
Yeeeei... That's the end of part I... :D
Aaand.... You can download above android studio source code here....
Go to Part II....
Label:
Android,
Android Studio,
GIMP,
Programming
Subscribe to:
Posts (Atom)