Moved all enums and event args to their own files

This commit is contained in:
Robin 2015-12-08 17:57:25 +00:00
parent b676410b3f
commit 862002e0ef
22 changed files with 129 additions and 117 deletions

View File

@ -6,12 +6,6 @@ using System.Windows.Forms;
namespace DarkUI.Controls
{
public enum DarkButtonStyle
{
Normal,
Flat
}
[ToolboxBitmap(typeof(Button))]
[DefaultEvent("Click")]
public class DarkButton : Button

View File

@ -0,0 +1,8 @@
namespace DarkUI.Controls
{
public enum DarkButtonStyle
{
Normal,
Flat
}
}

View File

@ -0,0 +1,9 @@
namespace DarkUI.Controls
{
public enum DarkContentAlignment
{
Center,
Left,
Right
}
}

View File

@ -1,41 +0,0 @@
using System.ComponentModel;
using System.Drawing;
using System.Windows.Forms;
namespace DarkUI.Controls
{
public enum DarkControlState
{
Normal,
Hover,
Pressed
}
public enum DarkContentAlignment
{
Center,
Left,
Right
}
public class DarkControl : Control
{
#region Property Region
[Browsable(false)]
[DesignerSerializationVisibility(DesignerSerializationVisibility.Hidden)]
public new Image BackgroundImage
{
get { return base.BackgroundImage; }
}
[Browsable(false)]
[DesignerSerializationVisibility(DesignerSerializationVisibility.Hidden)]
public new ImageLayout BackgroundImageLayout
{
get { return base.BackgroundImageLayout; }
}
#endregion
}
}

View File

@ -0,0 +1,9 @@
namespace DarkUI.Controls
{
public enum DarkControlState
{
Normal,
Hover,
Pressed
}
}

View File

@ -7,23 +7,7 @@ using System.Windows.Forms;
namespace DarkUI.Controls
{
public enum DarkScrollOrientation
{
Vertical,
Horizontal
}
public class ScrollValueEventArgs : EventArgs
{
public int Value { get; private set; }
public ScrollValueEventArgs(int value)
{
Value = value;
}
}
public class DarkScrollBar : DarkControl
public class DarkScrollBar : Control
{
#region Event Region

View File

@ -6,7 +6,7 @@ using System.Windows.Forms;
namespace DarkUI.Controls
{
public abstract class DarkScrollBase : DarkControl
public abstract class DarkScrollBase : Control
{
#region Event Region

View File

@ -0,0 +1,8 @@
namespace DarkUI.Controls
{
public enum DarkScrollOrientation
{
Vertical,
Horizontal
}
}

View File

@ -4,7 +4,7 @@ using System.Windows.Forms;
namespace DarkUI.Controls
{
public class DarkSeparator : DarkControl
public class DarkSeparator : Control
{
#region Constructor Region

View File

@ -0,0 +1,14 @@
using System;
namespace DarkUI.Controls
{
public class ScrollValueEventArgs : EventArgs
{
public int Value { get; private set; }
public ScrollValueEventArgs(int value)
{
Value = value;
}
}
}

View File

@ -12,6 +12,10 @@
<TargetFrameworkVersion>v4.0</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment>
<TargetFrameworkProfile>Client</TargetFrameworkProfile>
<SccProjectName>SAK</SccProjectName>
<SccLocalPath>SAK</SccLocalPath>
<SccAuxPath>SAK</SccAuxPath>
<SccProvider>SAK</SccProvider>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<DebugSymbols>true</DebugSymbols>
@ -42,15 +46,16 @@
<Compile Include="Collections\ObservableListModified.cs" />
<Compile Include="Config\Colors.cs" />
<Compile Include="Config\Consts.cs" />
<Compile Include="Controls\DarkButtonStyle.cs" />
<Compile Include="Controls\DarkCheckBox.cs">
<SubType>Component</SubType>
</Compile>
<Compile Include="Controls\DarkControl.cs">
<SubType>Component</SubType>
</Compile>
<Compile Include="Controls\DarkContentAlignment.cs" />
<Compile Include="Controls\DarkControlState.cs" />
<Compile Include="Controls\DarkRadioButton.cs">
<SubType>Component</SubType>
</Compile>
<Compile Include="Controls\DarkScrollOrientation.cs" />
<Compile Include="Controls\DarkTitle.cs">
<SubType>Component</SubType>
</Compile>
@ -76,7 +81,9 @@
<Compile Include="Controls\DarkMenuStrip.cs">
<SubType>Component</SubType>
</Compile>
<Compile Include="Controls\DarkScrollBar.cs" />
<Compile Include="Controls\DarkScrollBar.cs">
<SubType>Component</SubType>
</Compile>
<Compile Include="Controls\DarkScrollView.cs">
<SubType>Component</SubType>
</Compile>
@ -96,7 +103,11 @@
<SubType>Component</SubType>
</Compile>
<Compile Include="Controls\DarkTreeNode.cs" />
<Compile Include="Docking\DarkDockContent.cs" />
<Compile Include="Controls\ScrollValueEventArgs.cs" />
<Compile Include="Docking\DarkDockArea.cs" />
<Compile Include="Docking\DarkDockContent.cs">
<SubType>UserControl</SubType>
</Compile>
<Compile Include="Docking\DarkDockGroup.cs">
<SubType>Component</SubType>
</Compile>
@ -109,12 +120,14 @@
<Compile Include="Docking\DarkDocument.cs">
<SubType>UserControl</SubType>
</Compile>
<Compile Include="Docking\DarkSplitterType.cs" />
<Compile Include="Docking\DarkToolWindow.cs">
<SubType>UserControl</SubType>
</Compile>
<Compile Include="Docking\DarkDockSplitter.cs" />
<Compile Include="Docking\DarkDockTab.cs" />
<Compile Include="Docking\DarkDockTabArea.cs" />
<Compile Include="Docking\DockContentEvenArgs.cs" />
<Compile Include="Extensions\BitmapExtensions.cs" />
<Compile Include="Extensions\IEnumerableExtensions.cs" />
<Compile Include="Forms\DarkDialog.cs">
@ -123,6 +136,7 @@
<Compile Include="Forms\DarkDialog.Designer.cs">
<DependentUpon>DarkDialog.cs</DependentUpon>
</Compile>
<Compile Include="Forms\DarkDialogButton.cs" />
<Compile Include="Forms\DarkForm.cs">
<SubType>Form</SubType>
</Compile>
@ -132,6 +146,7 @@
<Compile Include="Forms\DarkMessageBox.Designer.cs">
<DependentUpon>DarkMessageBox.cs</DependentUpon>
</Compile>
<Compile Include="Forms\DarkMessageBoxIcon.cs" />
<Compile Include="Forms\DarkTranslucentForm.cs">
<SubType>Form</SubType>
</Compile>

View File

@ -0,0 +1,10 @@
namespace DarkUI.Docking
{
public enum DarkDockArea
{
Document,
Left,
Right,
Bottom
}
}

View File

@ -5,16 +5,6 @@ using System.Windows.Forms;
namespace DarkUI.Docking
{
public class DockContentEventArgs : EventArgs
{
public DarkDockContent Content { get; private set; }
public DockContentEventArgs(DarkDockContent content)
{
Content = content;
}
}
[ToolboxItem(false)]
public class DarkDockContent : UserControl
{

View File

@ -7,14 +7,6 @@ using System.Windows.Forms;
namespace DarkUI.Docking
{
public enum DarkDockArea
{
Document,
Left,
Right,
Bottom
}
public class DarkDockPanel : UserControl
{
#region Event Region

View File

@ -104,7 +104,7 @@ namespace DarkUI.Docking
public List<DarkDockContent> GetContents()
{
var result = new List<DarkDockContent>();
foreach (var group in _groups)
result.AddRange(group.GetContents());

View File

@ -5,14 +5,6 @@ using System.Windows.Forms;
namespace DarkUI.Docking
{
public enum DarkSplitterType
{
Left,
Right,
Top,
Bottom
}
public class DarkDockSplitter
{
#region Field Region

View File

@ -0,0 +1,10 @@
namespace DarkUI.Docking
{
public enum DarkSplitterType
{
Left,
Right,
Top,
Bottom
}
}

View File

@ -0,0 +1,14 @@
using System;
namespace DarkUI.Docking
{
public class DockContentEventArgs : EventArgs
{
public DarkDockContent Content { get; private set; }
public DockContentEventArgs(DarkDockContent content)
{
Content = content;
}
}
}

View File

@ -5,17 +5,6 @@ using System.Windows.Forms;
namespace DarkUI.Forms
{
public enum DarkDialogButton
{
Ok,
Close,
OkCancel,
YesNo,
YesNoCancel,
AbortRetryIgnore,
RetryCancel
}
public partial class DarkDialog : DarkForm
{
#region Field Region

View File

@ -0,0 +1,13 @@
namespace DarkUI.Forms
{
public enum DarkDialogButton
{
Ok,
Close,
OkCancel,
YesNo,
YesNoCancel,
AbortRetryIgnore,
RetryCancel
}
}

View File

@ -6,14 +6,6 @@ using System.Windows.Forms;
namespace DarkUI.Forms
{
public enum DarkMessageBoxIcon
{
None,
Information,
Warning,
Error
}
public partial class DarkMessageBox : DarkDialog
{
#region Field Region

View File

@ -0,0 +1,10 @@
namespace DarkUI.Forms
{
public enum DarkMessageBoxIcon
{
None,
Information,
Warning,
Error
}
}