Android exit transition excludeTarget not working inside android.support.v4.widget.DrawerLayout -


i have activity includes viewpager 3 fragments. first tab, calling activty , trying exclude toolbar , tab bar exit transition.

if (build.version.sdk_int >= 21) {                      getactivity().getwindow().setexittransition(new slide(gravity.left).excludetarget(r.id.toolbar,true));                      pair<view, string> pair1 = pair.create((view) matcvr, matcvr.gettransitionname());                     pair<view, string> pair2 = pair.create((view)mattxt, mattxt.gettransitionname());                      activityoptionscompat options = activityoptionscompat.makescenetransitionanimation(getactivity(),pair1,pair2);                     activitycompat.startactivity(getactivity(), matintent, options.tobundle());                 } 

the issue excludetarget seems not working , whole view sliding left. have tried addtarget below including viewpager alone.but in case, default fade animation happening.

getactivity().getwindow().setexittransition(new slide(gravity.left).addtarget(r.id.viewpager)); 

has faced issue? appreciated.

update

the issue appears when have views inside

android.support.v4.widget.drawerlayout / android.support.design.widget.appbarlayout 

we need make android:transitiongroup="false" explicitly parent views.

true if viewgroup should acted on during activity transition. default value true when there non-null background or if gettransitionname() not null or if non-null viewoutlineprovider other background given setoutlineprovider(viewoutlineprovider) , false otherwise.


Comments

Popular posts from this blog

wordpress - (T_ENDFOREACH) php error -

Export Excel workseet into txt file using vba - (text and numbers with formulas) -

Using django-mptt to get only the categories that have items -