Пример #1
0
        // 打开左侧抽屉
        private void CloseLeftDrawer()
        {
            if (leftDrawer.Visibility == Visibility.Collapsed)
            {
                return;
            }
            leftDrawer.Visibility = Visibility.Collapsed;
            this.ShowLeftDrawerGrid();
            PinRotateTransform.Angle = 90;

            mainLayer.ColumnDefinitions.Remove(MinerProfileColumn);
            MainTabControl.SetValue(Grid.ColumnProperty, mainLayer.ColumnDefinitions.Count - 1);
        }
Пример #2
0
        // 关闭左侧抽屉
        private void OpenLeftDrawer()
        {
            if (LeftDrawerGrip.Width != _leftDrawerGripWidth)
            {
                return;
            }
            leftDrawer.Visibility = Visibility.Visible;
            this.HideLeftDrawerGrid();
            PinRotateTransform.Angle = 0;

            if (!mainLayer.ColumnDefinitions.Contains(MinerProfileColumn))
            {
                mainLayer.ColumnDefinitions.Insert(0, MinerProfileColumn);
            }
            MainTabControl.SetValue(Grid.ColumnProperty, mainLayer.ColumnDefinitions.Count - 1);
        }
Пример #3
0
        // 关闭左侧抽屉
        private void OpenLeftDrawer(bool isSizeChanged = false)
        {
            if (LeftDrawerGrip.Width != _leftDrawerGripWidth)
            {
                return;
            }
            leftDrawer.Visibility = Visibility.Visible;
            this.HideLeftDrawerGrid();
            PinRotateTransform.Angle = 0;

            if (!mainLayer.ColumnDefinitions.Contains(MinerProfileColumn))
            {
                mainLayer.ColumnDefinitions.Insert(0, MinerProfileColumn);
            }
            MainTabControl.SetValue(Grid.ColumnProperty, mainLayer.ColumnDefinitions.Count - 1);
            if (!isSizeChanged)
            {
                50.MillisecondsDelay().ContinueWith(t => {
                    UIThread.Execute(ConsoleWindowFit);
                });
            }
        }