diff --git a/BeDesignerSCADA/Controls/MenuRunCanvas.xaml.cs b/BeDesignerSCADA/Controls/MenuRunCanvas.xaml.cs index 88575270..b5de2410 100644 --- a/BeDesignerSCADA/Controls/MenuRunCanvas.xaml.cs +++ b/BeDesignerSCADA/Controls/MenuRunCanvas.xaml.cs @@ -201,12 +201,21 @@ namespace BeDesignerSCADA.Controls //拉出按钮 lachu.HorizontalAlignment = HorizontalAlignment.Right; lachu.VerticalAlignment = VerticalAlignment.Stretch; - lachu.BorderThickness = new Thickness(1, 0, 0, 0); + lachu.BorderThickness = new Thickness(0, 0, 1, 0); //closeGrid closeGrid.HorizontalAlignment = HorizontalAlignment.Center; closeGrid.VerticalAlignment = VerticalAlignment.Bottom; closeGrid.Margin = new Thickness(10); ButClose.Margin = new Thickness(0, 5, 0, 0); + FrameworkElement border = null; + foreach (FrameworkElement item in waibustack.Children) + { + if (item is Border) + border = item; + } + waibustack.Children.Remove(border); + waibustack.Children.Insert(0,border); + break; case MenuAlignment.底部: //左边菜单栏 @@ -236,16 +245,26 @@ namespace BeDesignerSCADA.Controls //外部Stackpanl waibustack.Orientation = Orientation.Vertical; waibustack.VerticalAlignment = VerticalAlignment.Bottom; + waibustack.Margin = new Thickness(0, 0, 0, 25); //拉出按钮 lachu.HorizontalAlignment = HorizontalAlignment.Stretch; lachu.VerticalAlignment = VerticalAlignment.Bottom; lachu.LayoutTransform = new RotateTransform() { Angle = 270 }; - lachu.BorderThickness = new Thickness(0, 0, 1, 0); + lachu.BorderThickness = new Thickness(1, 0, 0, 0); + lachu.Margin = new Thickness(0, 0, 0, 0); //closeGrid closeGrid.HorizontalAlignment = HorizontalAlignment.Right; closeGrid.VerticalAlignment = VerticalAlignment.Center; closeGrid.Margin = new Thickness(10, 0, 10, 0); ButClose.Margin = new Thickness(0, 5, 0, 0); + border = null; + foreach (FrameworkElement item in waibustack.Children) + { + if (item is Border) + border = item; + } + waibustack.Children.Remove(border); + waibustack.Children.Insert(0, border); break; default: break;