Пример #1
0
        void UpdateDrawerState(bool isOpen)
        {
            double endState  = isOpen ? 1 : 0;
            var    animation = new Animation((r) =>
            {
                OpenRatio = r;
                InvalidateLayout();
            }, OpenRatio, endState, Easing.SinIn);

            animation.Commit(this, "DrawerOpen", length: (uint)(250 * Math.Abs(endState - OpenRatio)), finished: (f, aborted) =>
            {
                if (!aborted)
                {
                    if (isOpen)
                    {
                        DrawerOpened?.Invoke(this, EventArgs.Empty);
                    }
                    else
                    {
                        DrawerClosed?.Invoke(this, EventArgs.Empty);
                    }
                }
            });
        }
Пример #2
0
        public override void OnDrawerClosed(View drawerView)
        {
            DrawerClosed?.Invoke(this, new ActionBarDrawerEventArgs(drawerView));

            base.OnDrawerClosed(drawerView);
        }
Пример #3
0
        public override void OnDrawerClosed(View drawerView)
        {
            base.OnDrawerClosed(drawerView);

            DrawerClosed.Raise(this);
        }
 public override void OnDrawerClosed(View drawerView)
 {
     base.OnDrawerClosed(drawerView);
     DrawerClosed?.Invoke(drawerView);
 }