Experimental: Always check for keybinds
This commit is contained in:
@@ -159,6 +159,8 @@ internal sealed unsafe class Chat : IDisposable {
|
|||||||
internal bool UsesTellTempChannel { get; set; }
|
internal bool UsesTellTempChannel { get; set; }
|
||||||
internal InputChannel? PreviousChannel { get; private set; }
|
internal InputChannel? PreviousChannel { get; private set; }
|
||||||
|
|
||||||
|
private long LastRefresh;
|
||||||
|
|
||||||
internal Chat(Plugin plugin)
|
internal Chat(Plugin plugin)
|
||||||
{
|
{
|
||||||
Plugin = plugin;
|
Plugin = plugin;
|
||||||
@@ -396,11 +398,17 @@ internal sealed unsafe class Chat : IDisposable {
|
|||||||
|
|
||||||
private void InterceptKeybinds(IFramework framework1)
|
private void InterceptKeybinds(IFramework framework1)
|
||||||
{
|
{
|
||||||
CheckFocus();
|
// CheckFocus();
|
||||||
UpdateKeybinds();
|
|
||||||
|
|
||||||
if (_inputFocused)
|
// Refresh current keybinds every 5s
|
||||||
return;
|
if (LastRefresh + 5 * 1000 < Environment.TickCount64)
|
||||||
|
{
|
||||||
|
UpdateKeybinds();
|
||||||
|
LastRefresh = Environment.TickCount64;
|
||||||
|
}
|
||||||
|
|
||||||
|
// if (_inputFocused)
|
||||||
|
// return;
|
||||||
|
|
||||||
var modifierState = (ModifierFlag) 0;
|
var modifierState = (ModifierFlag) 0;
|
||||||
foreach (var modifier in Enum.GetValues<ModifierFlag>())
|
foreach (var modifier in Enum.GetValues<ModifierFlag>())
|
||||||
|
|||||||
Reference in New Issue
Block a user