Update #9 - Fixed stuck F+3 key when releasing F before 3

This commit is contained in:
LAX1DUDE 2023-01-04 18:44:17 -08:00
parent ee2a583fd5
commit d93fbdc9f6
3 changed files with 13 additions and 7 deletions

View File

@ -1 +1 @@
u8
u9

View File

@ -8,7 +8,7 @@ public class EaglercraftVersion {
/// Customize these to fit your fork:
public static final String projectForkName = "EaglercraftX";
public static final String projectForkVersion = "u8";
public static final String projectForkVersion = "u9";
public static final String projectForkVendor = "lax1dude";
public static final String projectForkURL = "https://gitlab.com/lax1dude/eaglercraftx-1.8";
@ -23,7 +23,7 @@ public class EaglercraftVersion {
public static final String projectOriginName = "EaglercraftX";
public static final String projectOriginAuthor = "lax1dude";
public static final String projectOriginRevision = "1.8";
public static final String projectOriginVersion = "u8";
public static final String projectOriginVersion = "u9";
public static final String projectOriginURL = "https://gitlab.com/lax1dude/eaglercraftx-1.8";

View File

@ -168,8 +168,8 @@ public class PlatformInput {
evt.preventDefault();
evt.stopPropagation();
if(!enableRepeatEvents && evt.isRepeat()) return;
w = processFunctionKeys(w);
keyStates[KeyboardConstants.getEaglerKeyFromBrowser(w, evt.getLocation())] = true;
int ww = processFunctionKeys(w);
keyStates[KeyboardConstants.getEaglerKeyFromBrowser(ww, ww == w ? evt.getLocation() : 0)] = true;
keyEvents.add(evt);
}
});
@ -180,8 +180,14 @@ public class PlatformInput {
evt.preventDefault();
evt.stopPropagation();
if(!enableRepeatEvents && evt.isRepeat()) return;
w = processFunctionKeys(w);
keyStates[KeyboardConstants.getEaglerKeyFromBrowser(w, evt.getLocation())] = false;
int ww = processFunctionKeys(w);
int eagKey = KeyboardConstants.getEaglerKeyFromBrowser(ww, ww == w ? evt.getLocation() : 0);
keyStates[eagKey] = false;
if(eagKey == functionKeyModifier) {
for(int key = KeyboardConstants.KEY_F1; key <= KeyboardConstants.KEY_F10; ++key) {
keyStates[key] = false;
}
}
keyEvents.add(evt);
}
});