Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit c46d3339 authored by Adam Powell's avatar Adam Powell
Browse files

Action bar transitions - handle expanding/collapsing action views

Make sure we beginDelayedTransition when we expand and collapse action
views, specifically before any callbacks go out that might alter the
hierarchy.

Change-Id: Iffc286cccd9be83ad03aeede605870ac12cc6bab
parent 60fcce6c
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -1639,6 +1639,8 @@ public class ActionBarView extends AbsActionBarView {

        @Override
        public boolean expandItemActionView(MenuBuilder menu, MenuItemImpl item) {
            TransitionManager.beginDelayedTransition(ActionBarView.this, sTransition);

            mExpandedActionView = item.getActionView();
            mExpandedHomeLayout.setIcon(mIcon.getConstantState().newDrawable(getResources()));
            mCurrentExpandedItem = item;
@@ -1666,6 +1668,8 @@ public class ActionBarView extends AbsActionBarView {

        @Override
        public boolean collapseItemActionView(MenuBuilder menu, MenuItemImpl item) {
            TransitionManager.beginDelayedTransition(ActionBarView.this, sTransition);

            // Do this before detaching the actionview from the hierarchy, in case
            // it needs to dismiss the soft keyboard, etc.
            if (mExpandedActionView instanceof CollapsibleActionView) {