-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathCreateKeyBinds.cs
More file actions
40 lines (28 loc) · 1.11 KB
/
Copy pathCreateKeyBinds.cs
File metadata and controls
40 lines (28 loc) · 1.11 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
namespace SetMouseForGames;
internal class CreateKeyBinds
{
internal enum ModKeys
{
LAlt = 0x0001,
LCtrl = 0x0002,
LShift = 0x0004,
LWin = 0x0008,
}
internal static HotKeyStruct[] CreateKeyBindsX()
{
HotKeyStruct[] hotKeyStructsList = new HotKeyStruct[0];
AddKeybind(HotKeyEnum.FullRotation, ModKeys.LWin, Keys.F2);
AddKeybind(HotKeyEnum.RotationDecrement, ModKeys.LWin, Keys.F6);
AddKeybind(HotKeyEnum.RotationIncrement, ModKeys.LWin, Keys.F7);
AddKeybind(HotKeyEnum.RotationScaleDecrement, ModKeys.LWin, Keys.OemOpenBrackets);
AddKeybind(HotKeyEnum.RotationScaleIncrement, ModKeys.LWin, Keys.OemCloseBrackets);
AddKeybind(HotKeyEnum.SaveFile, ModKeys.LWin, Keys.F10);
return hotKeyStructsList.ToArray();
void AddKeybind(HotKeyEnum id, ModKeys _modKeyID, Keys _keyId)
{
if ((int)id >= hotKeyStructsList.Length - 1)
Array.Resize(ref hotKeyStructsList, (int)id + 1);
hotKeyStructsList[(int)id] = new HotKeyStruct(_modKeyID, _keyId);
}
}
}