Remove inInput -> replace with inMenu

This commit is contained in:
kookroach
2021-04-03 20:32:11 +02:00
parent ee305b78ec
commit 1e05bb108c
21 changed files with 108 additions and 110 deletions

View File

@@ -13,12 +13,12 @@ export default function ahelp(globalData: IGlobalData): void {
if (ahelpBrowser !== null) {
ahelpBrowser.destroy();
ahelpBrowser = null;
globalData.InInput = false;
globalData.InMenu = false;
mp.gui.cursor.show(false, false);
mp.gui.chat.activate(true);
}
else if (!globalData.InInput) {
globalData.InInput = true;
else if (!globalData.InMenu) {
globalData.InMenu = true;
ahelpBrowser = mp.browsers.new('package://assets/html/helpcommand/ahelp.html');
mp.gui.chat.activate(false);
mp.gui.cursor.show(true, true);
@@ -30,10 +30,10 @@ export default function ahelp(globalData: IGlobalData): void {
if (ahelpBrowser == null) {
return;
}
else if (globalData.InInput) {
else if (globalData.InMenu) {
ahelpBrowser.destroy();
ahelpBrowser = null;
globalData.InInput = false;
globalData.InMenu = false;
mp.gui.cursor.show(false, false);
mp.gui.chat.activate(true);
}
@@ -44,12 +44,12 @@ export default function ahelp(globalData: IGlobalData): void {
if (ahelpBrowser !== null) {
ahelpBrowser.destroy();
ahelpBrowser = null;
globalData.InInput = false;
globalData.InMenu = false;
mp.gui.cursor.show(false, false);
mp.gui.chat.activate(true);
}
else if (!globalData.InInput) {
globalData.InInput = true;
else if (!globalData.InMenu) {
globalData.InMenu = true;
ahelpBrowser = mp.browsers.new('package://assets/html/helpcommand/shelp.html');
mp.gui.chat.activate(false);
mp.gui.cursor.show(true, true);