mirror of
https://github.com/DarthAffe/CUE.NET.git
synced 2025-12-12 16:58:29 +00:00
Refactored to fit the project coding style
This commit is contained in:
parent
54231ec4e8
commit
02aaf24c41
@ -63,6 +63,8 @@
|
||||
<Compile Include="Devices\Generic\Enums\CorsairAccessMode.cs" />
|
||||
<Compile Include="Devices\Generic\Enums\CorsairDeviceCaps.cs" />
|
||||
<Compile Include="Devices\Generic\Enums\CorsairDeviceType.cs" />
|
||||
<Compile Include="Devices\Keyboard\ColorBrushes\IBrush.cs" />
|
||||
<Compile Include="Devices\Keyboard\ColorBrushes\SolidColorBrush.cs" />
|
||||
<Compile Include="Devices\Keyboard\Enums\CorsairLogicalKeyboardLayout.cs" />
|
||||
<Compile Include="Devices\Headset\Enums\CorsairHeadsetLedId.cs" />
|
||||
<Compile Include="Devices\Keyboard\Enums\CorsairKeyboardKeyId.cs" />
|
||||
|
||||
@ -1,10 +1,9 @@
|
||||
using System.Drawing;
|
||||
|
||||
namespace CUE.NET.Devices.Keyboard.ColorBrushes
|
||||
|
||||
{
|
||||
public interface IBrush
|
||||
{
|
||||
Color getColorAtPoint(Point point);
|
||||
Color GetColorAtPoint(Point point);
|
||||
}
|
||||
}
|
||||
@ -4,33 +4,26 @@ namespace CUE.NET.Devices.Keyboard.ColorBrushes
|
||||
{
|
||||
public class SolidColorBrush : IBrush
|
||||
{
|
||||
Color color;
|
||||
#region Properties & Fields
|
||||
|
||||
public Color Color { get; set; }
|
||||
|
||||
#endregion
|
||||
|
||||
#region Constructors
|
||||
|
||||
public SolidColorBrush(Color color)
|
||||
{
|
||||
this.color = color;
|
||||
this.Color = color;
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region Methods
|
||||
|
||||
public Color getColorAtPoint(Point point)
|
||||
public Color GetColorAtPoint(Point point)
|
||||
{
|
||||
/* a solid color brush returns the same color no matter the point */
|
||||
return this.color;
|
||||
}
|
||||
|
||||
public Color getColor()
|
||||
{
|
||||
return this.color;
|
||||
}
|
||||
|
||||
public void setColor(Color color)
|
||||
{
|
||||
this.color = color;
|
||||
return Color; // A solid color brush returns the same color no matter the point
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user