Snap left/right keybinds

This commit is contained in:
Tyfon
2024-05-29 15:04:40 -07:00
parent 328224ca65
commit 34a0a24030
2 changed files with 58 additions and 10 deletions

View File

@@ -1,6 +1,7 @@
using BepInEx.Configuration;
using System.Collections.Generic;
using System.ComponentModel;
using UnityEngine;
namespace UIFixes
{
@@ -54,6 +55,8 @@ namespace UIFixes
public static ConfigEntry<bool> RememberInspectSize { get; set; }
public static ConfigEntry<bool> LockInspectPreviewSize { get; set; }
public static ConfigEntry<bool> ExpandDescriptionHeight { get; set; }
public static ConfigEntry<KeyboardShortcut> SnapLeftKeybind { get; set; }
public static ConfigEntry<KeyboardShortcut> SnapRightKeybind { get; set; }
public static ConfigEntry<bool> StyleItemPanel { get; set; } // Advanced
// In Raid
@@ -246,6 +249,24 @@ namespace UIFixes
null,
new ConfigurationManagerAttributes { })));
configEntries.Add(SnapLeftKeybind = config.Bind(
InspectSection,
"Snap Window Left shortcut",
new KeyboardShortcut(KeyCode.LeftArrow),
new ConfigDescription(
"Keybind to snap the inspect panel to the left half of the screen",
null,
new ConfigurationManagerAttributes { })));
configEntries.Add(SnapRightKeybind = config.Bind(
InspectSection,
"Snap Window Right shortcut",
new KeyboardShortcut(KeyCode.RightArrow),
new ConfigDescription(
"Keybind to snap the inspect panel to the right half of the screen",
null,
new ConfigurationManagerAttributes { })));
configEntries.Add(StyleItemPanel = config.Bind(
InspectSection,
"Style Attribute Panels",