Android, trouble with clicking after layout animation -
i have listview on screen , menu @ bottom. upon click of menu key, animates-slides off screen , listview expands.
menubtmvisable = false; animation menu_off = animationutils.loadanimation(this, r.anim.menu_off); menubtm.startanimation(menu_off); display display = getwindowmanager().getdefaultdisplay(); layoutparams listlp = new layoutparams(display.getwidth(), display.getheight()-87 , 0, 50); listviewmain.setlayoutparams(listlp);
menu_off.xml
<set android:fillenabled="true" android:fillafter="true" xmlns:android="http://schemas.android.com/apk/res/android"> <translate android:fromydelta="0" android:toydelta="120" android:duration="500" /> </set>
yet when, menu down, click on listview item "13" ( see picture ), results in menu click, if still in place...
what think best way take care of it?
thanks!
i've looking answer problem that, , finally, after week, i've managed solve problem. since looks similar yours, maybe you.
set , animationlistener()
in animation and, onanimationend
, change layout want. in case, wanted slide layout up, 2 buttons appear below. however, layout slided visually; buttons still off screen, interactionally speaking. have this:
final view screen = findviewbyid(r.id.welcome_screen); final animation = animationutils.loadanimation(getapplicationcontext(), r.anim.slide_home_up); a.setfillafter(true); a.setanimationlistener(new animationlistener() { public void onanimationstart(animation animation) { } public void onanimationrepeat(animation animation) { } public void onanimationend(animation animation) { screen.clearanimation(); screen.setpadding(0, -222, 0, 0); } }); screen.startanimation(a);
Comments
Post a Comment