Hongbo wrote:
> Hey guys:
> 
> I wonder how to make floating buttons, like the zoom button in the
> build-in web browsee?
> 
> Actually there are 2 things i'd like to know:
> 
> 1. How to make a view(button) floating above other views?

Use RelativeLayout as the container for the other views, and add your
Button last in the XML. If the Button overlaps other views, the Button
will appear "above" those other views.

> 2. How to make the fade in/fade out effect regarding to touch screen?

For the fade-in/fade-out, use an AlphaAnimation.

For the touch screen, you have a number of options. I used
onTouchEvent() in one sample:

http://github.com/commonsguy/vidtry

-- 
Mark Murphy (a Commons Guy)
http://commonsware.com | http://twitter.com/commonsguy

Android Development Wiki: http://wiki.andmob.org

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to