Adding an Avatar to the Settings Screen Layout

LinearLayout (Horizontal Orientation)

ImageButton (Avatar)

LinearLayout (Vertical Orientation)

TextView ("Nickname:")

EditText (Nickname Input)


The settings screen layout updates required for the avatar feature.

But wait! You want the user to be able to configure the avatar by using the camera (to take a new picture) or by choosing an image already saved on the device. No problem. You can do this by handling clicks and long-clicks on the same Button control. The user can click the ImageButton control to launch the camera or long-click the same ImageButton control to launch the image picker.

Was this article helpful?

0 0

Post a comment