mirror of
https://github.com/DarthAffe/CUE.NET.git
synced 2026-11-11 04:56:44 +00:00
Added key-position, initialized keyboard with available keys
This commit is contained in:
1 parent
0167828a19
commit
64e0902046
4 files changed
+25
-8
No files matched your search
+2
-1
@@ -1,6 +1,7 @@
|
||||
using System;
|
||||
using System.Runtime.InteropServices;
|
||||
using CUE.NET.Devices.Generic.Enums;
|
||||
using CUE.NET.Devices.Keyboard.Enums;
|
||||
|
||||
namespace CUE.NET.Native
|
||||
{
|
||||
@@ -52,7 +53,7 @@ namespace CUE.NET.Native
|
||||
[DllImport("CUESDK_2013.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
#endif
|
||||
// retrieves led id for key name taking logical layout into account.
|
||||
internal static extern int CorsairGetLedIdForKeyName(char keyName);
|
||||
internal static extern CorsairKeyboardKeyId CorsairGetLedIdForKeyName(char keyName);
|
||||
|
||||
#if WIN64
|
||||
[DllImport("CUESDK.x64_2013.dll", CallingConvention = CallingConvention.Cdecl)]
|
||||
|
||||
@@ -3,17 +3,18 @@
|
||||
#pragma warning disable 649 // Field 'x' is never assigned
|
||||
|
||||
using System.Runtime.InteropServices;
|
||||
using CUE.NET.Devices.Keyboard.Enums;
|
||||
|
||||
namespace CUE.NET.Native
|
||||
{
|
||||
// ReSharper disable once InconsistentNaming
|
||||
[StructLayout(LayoutKind.Sequential)]
|
||||
internal class _CorsairLedPosition // contains led id and position of led rectangle.Most of the keys are rectangular. In case if key is not rectangular(like Enter in ISO / UK layout) it returns the smallest rectangle that fully contains the key
|
||||
internal class _CorsairLedPosition // contains led id and position of led rectangle.Most of the keys are rectangular. In case if key is not rectangular(like Enter in ISO / UK layout) it returns the smallest rectangle that fully contains the key
|
||||
{
|
||||
internal int ledId; // identifier of led
|
||||
internal CorsairKeyboardKeyId ledId; // identifier of led
|
||||
internal double top;
|
||||
internal double left;
|
||||
internal double height;
|
||||
internal double width; // values in mm
|
||||
internal double width; // values in mm
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user