mirror of
https://github.com/DarthAffe/RGB.NET.git
synced 2026-11-11 04:57:15 +00:00
Added shape to led and improved layout-loading
This commit is contained in:
1 parent
bc8e5d54db
commit
bdf446581e
9 files changed
+30
-13
No files matched your search
@@ -1,8 +1,6 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using System.Reflection;
|
||||
using System.Runtime.InteropServices;
|
||||
using RGB.NET.Core;
|
||||
using RGB.NET.Core.Layout;
|
||||
@@ -82,6 +80,8 @@ namespace RGB.NET.Devices.Corsair
|
||||
led.LedRectangle.Location.Y = layoutLed.Y;
|
||||
led.LedRectangle.Size.Width = layoutLed.Width;
|
||||
led.LedRectangle.Size.Height = layoutLed.Height;
|
||||
|
||||
led.Shape = layoutLed.Shape;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -34,6 +34,9 @@ namespace RGB.NET.Devices.Corsair
|
||||
/// <inheritdoc />
|
||||
public Uri Image { get; protected set; }
|
||||
|
||||
/// <inheritdoc />
|
||||
public RGBDeviceLighting Lighting => RGBDeviceLighting.Key;
|
||||
|
||||
/// <summary>
|
||||
/// Gets a flag that describes device capabilities. (<see cref="CorsairDeviceCaps" />)
|
||||
/// </summary>
|
||||
|
||||
@@ -1,11 +1,9 @@
|
||||
// ReSharper disable MemberCanBePrivate.Global
|
||||
// ReSharper disable UnusedMember.Global
|
||||
|
||||
using System;
|
||||
using System.IO;
|
||||
using System.Reflection;
|
||||
using RGB.NET.Core;
|
||||
using RGB.NET.Core.Layout;
|
||||
|
||||
namespace RGB.NET.Devices.Corsair
|
||||
{
|
||||
|
||||
@@ -59,7 +59,7 @@ namespace RGB.NET.Devices.Corsair
|
||||
}
|
||||
|
||||
ApplyLayoutFromFile(Path.Combine(Path.GetDirectoryName(Assembly.GetEntryAssembly().Location),
|
||||
$@"Layouts\Corsair\Keyboards\{KeyboardDeviceInfo.Model.Replace(" ", string.Empty).ToUpper()}\{KeyboardDeviceInfo.LogicalLayout.ToString().ToUpper()}.xml"));
|
||||
$@"Layouts\Corsair\Keyboards\{KeyboardDeviceInfo.Model.Replace(" ", string.Empty).ToUpper()}\{KeyboardDeviceInfo.PhysicalLayout.ToString().ToUpper()}.xml"));
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
Reference in new issue
Block a user