diff --git a/Bin/net40/SunnyUI.dll b/Bin/net40/SunnyUI.dll index f730dc63..7cc9d3e9 100644 Binary files a/Bin/net40/SunnyUI.dll and b/Bin/net40/SunnyUI.dll differ diff --git a/Bin/net45/SunnyUI.dll b/Bin/net45/SunnyUI.dll index 56dd16d8..8bf38f42 100644 Binary files a/Bin/net45/SunnyUI.dll and b/Bin/net45/SunnyUI.dll differ diff --git a/Bin/net5.0-windows/SunnyUI.dll b/Bin/net5.0-windows/SunnyUI.dll index e8170121..633f9eba 100644 Binary files a/Bin/net5.0-windows/SunnyUI.dll and b/Bin/net5.0-windows/SunnyUI.dll differ diff --git a/Bin/net5.0-windows/ref/SunnyUI.dll b/Bin/net5.0-windows/ref/SunnyUI.dll index 0791ac7d..eb1c2c8d 100644 Binary files a/Bin/net5.0-windows/ref/SunnyUI.dll and b/Bin/net5.0-windows/ref/SunnyUI.dll differ diff --git a/Bin/netcoreapp3.1/SunnyUI.dll b/Bin/netcoreapp3.1/SunnyUI.dll index 7f7dc79b..09c3b6ba 100644 Binary files a/Bin/netcoreapp3.1/SunnyUI.dll and b/Bin/netcoreapp3.1/SunnyUI.dll differ diff --git a/SunnyUI/Controls/UIFlowLayoutPanel.cs b/SunnyUI/Controls/UIFlowLayoutPanel.cs index 6d4b4ec6..57658f71 100644 --- a/SunnyUI/Controls/UIFlowLayoutPanel.cs +++ b/SunnyUI/Controls/UIFlowLayoutPanel.cs @@ -24,6 +24,7 @@ using System.ComponentModel; using System.Drawing; using System.Drawing.Drawing2D; using System.Windows.Forms; +using System.Windows.Forms.Layout; namespace Sunny.UI { @@ -64,6 +65,40 @@ namespace Sunny.UI timer.Stop(); } + public override LayoutEngine LayoutEngine + { + get { return Panel.LayoutEngine; } + } + + [DefaultValue(System.Windows.Forms.FlowDirection.LeftToRight)] + [Localizable(true)] + public FlowDirection FlowDirection + { + get => Panel.FlowDirection; + set => Panel.FlowDirection = value; + } + + [DefaultValue(true)] + [Localizable(true)] + public bool WrapContents + { + get => Panel.WrapContents; + set => Panel.WrapContents = value; + } + + [DefaultValue(false)] + [DisplayName("FlowBreak")] + public bool GetFlowBreak(Control control) + { + return Panel.GetFlowBreak(control); + } + + [DisplayName("FlowBreak")] + public void SetFlowBreak(Control control, bool value) + { + Panel.SetFlowBreak(control, value); + } + protected override void OnControlAdded(ControlEventArgs e) { if (e.Control is UIHorScrollBarEx bar1) @@ -183,21 +218,7 @@ namespace Sunny.UI { } - [DefaultValue(FlowDirection.LeftToRight)] - [Localizable(true)] - public FlowDirection FlowDirection - { - get => Panel.FlowDirection; - set => Panel.FlowDirection = value; - } - [DefaultValue(true)] - [Localizable(true)] - public bool WrapContents - { - get => Panel.WrapContents; - set => Panel.WrapContents = value; - } public override void SetStyleColor(UIBaseStyle uiColor) { @@ -331,7 +352,6 @@ namespace Sunny.UI SetScrollPos(); } - public FlowLayoutPanel Panel => flowLayoutPanel; private void InitializeComponent()