From 635be61bd9df796a522914244942763bd28d877a Mon Sep 17 00:00:00 2001 From: LoomeL Date: Wed, 14 Aug 2019 14:44:35 +0600 Subject: [PATCH 1/3] [ANY] Js/css pretty print --- Launcher/runtime/config.js | 2 +- Launcher/runtime/dialog/dialog.js | 134 ++++++------- .../runtime/dialog/overlay/debug/debug.css | 33 ++-- .../runtime/dialog/overlay/debug/debug.js | 16 +- .../dialog/overlay/processing/processing.css | 5 +- .../dialog/overlay/processing/processing.js | 12 +- .../dialog/overlay/settings/settings.css | 52 +++-- .../dialog/overlay/settings/settings.js | 64 +++--- .../runtime/dialog/overlay/update/update.css | 17 +- .../runtime/dialog/overlay/update/update.js | 17 +- .../runtime/dialog/scenes/options/options.js | 185 +++++++++--------- Launcher/runtime/dialog/servers.css | 6 +- Launcher/runtime/dialog/styles.css | 150 ++++++++------ Launcher/runtime/init.js | 8 +- 14 files changed, 383 insertions(+), 318 deletions(-) diff --git a/Launcher/runtime/config.js b/Launcher/runtime/config.js index c5fa5bc1..d6433511 100644 --- a/Launcher/runtime/config.js +++ b/Launcher/runtime/config.js @@ -2,7 +2,7 @@ var config = { dir: "GravitLauncher", // Launcher directory title: "GravitLauncher", // Window title - icons: [ "favicon.png" ], // Window icon paths + icons: ["favicon.png"], // Window icon paths // Auth config linkText: "GravitLauncher", // Text for link under "Auth" button diff --git a/Launcher/runtime/dialog/dialog.js b/Launcher/runtime/dialog/dialog.js index 1c23beb4..1173456b 100644 --- a/Launcher/runtime/dialog/dialog.js +++ b/Launcher/runtime/dialog/dialog.js @@ -24,9 +24,9 @@ function initLauncher() { /* ======== init Login window======== */ function initLoginScene() { - loginPane.setOnMousePressed(function(event){ movePoint = new javafx.geometry.Point2D(event.getSceneX(), event.getSceneY())}); + loginPane.setOnMousePressed(function(event) { movePoint = new javafx.geometry.Point2D(event.getSceneX(), event.getSceneY()) }); loginPane.setOnMouseDragged(function(event) { - if(movePoint === null) { + if (movePoint === null) { return; } stage.setX(event.getScreenX() - movePoint.getX()); @@ -35,9 +35,9 @@ function initLoginScene() { var pane = loginPane.lookup("#bar"); bar = pane; - loginPane.lookup("#close").setOnAction(function(event){ javafx.application.Platform.exit()}); - loginPane.lookup("#hide").setOnAction(function(event){ stage.setIconified(true)}); - loginPane.lookup("#discord").setOnAction(function(){ openURL(config.discord); }); + loginPane.lookup("#close").setOnAction(function(event) { javafx.application.Platform.exit() }); + loginPane.lookup("#hide").setOnAction(function(event) { stage.setIconified(true) }); + loginPane.lookup("#discord").setOnAction(function() { openURL(config.discord); }); var pane = loginPane.lookup("#authPane"); authPane = pane; @@ -46,14 +46,14 @@ function initLoginScene() { loginPaneLayout = loginLayout; loginField = pane.lookup("#login"); - loginField.setOnMouseMoved(function(event){rootPane.fireEvent(event)}); + loginField.setOnMouseMoved(function(event) { rootPane.fireEvent(event) }); loginField.setOnAction(goAuth); if (settings.login !== null) { loginField.setText(settings.login); } passwordField = pane.lookup("#password"); - passwordField.setOnMouseMoved(function(event){rootPane.fireEvent(event)}); + passwordField.setOnMouseMoved(function(event) { rootPane.fireEvent(event) }); passwordField.setOnAction(goAuth); if (settings.rsaPassword !== null) { passwordField.getStyleClass().add("hasSaved"); @@ -74,9 +74,9 @@ function initLoginScene() { /* ======== init Menu window======== */ function initMenuScene() { - menuPane.setOnMousePressed(function(event){ movePoint = new javafx.geometry.Point2D(event.getSceneX(), event.getSceneY())}); + menuPane.setOnMousePressed(function(event) { movePoint = new javafx.geometry.Point2D(event.getSceneX(), event.getSceneY()) }); menuPane.setOnMouseDragged(function(event) { - if(movePoint === null) { + if (movePoint === null) { return; } @@ -86,9 +86,9 @@ function initMenuScene() { var pane = menuPane.lookup("#bar"); bar = pane; - pane.lookup("#close").setOnAction(function(event){ javafx.application.Platform.exit()}); - pane.lookup("#hide").setOnAction(function(event){ stage.setIconified(true)}); - pane.lookup("#discord").setOnAction(function(){ openURL(config.discord); }); + pane.lookup("#close").setOnAction(function(event) { javafx.application.Platform.exit() }); + pane.lookup("#hide").setOnAction(function(event) { stage.setIconified(true) }); + pane.lookup("#discord").setOnAction(function() { openURL(config.discord); }); pane.lookup("#settings").setOnAction(goSettings); pane.lookup("#goConsole").setOnAction(goConsole); @@ -105,10 +105,10 @@ function initMenuScene() { serverEntrance = pane.lookup("#serverentrance"); serverStatus = serverEntrance.lookup("#serverStatus"); serverLabel = serverEntrance.lookup("#serverLabel"); - serverEntrance.lookup("#clientLaunch").setOnAction(function(){ + serverEntrance.lookup("#clientLaunch").setOnAction(function() { doUpdate(profilesList[serverHolder.old], loginData.pp, loginData.accessToken); }); - pane.lookup("#logout").setOnAction(function(){ + pane.lookup("#logout").setOnAction(function() { setCurrentScene(loginScene); }); @@ -116,9 +116,9 @@ function initMenuScene() { /* ======== init Console window======== */ function initConsoleScene() { - consoleMenu.setOnMousePressed(function(event){ movePoint = new javafx.geometry.Point2D(event.getSceneX(), event.getSceneY())}); + consoleMenu.setOnMousePressed(function(event) { movePoint = new javafx.geometry.Point2D(event.getSceneX(), event.getSceneY()) }); consoleMenu.setOnMouseDragged(function(event) { - if(movePoint === null) { + if (movePoint === null) { return; } @@ -128,21 +128,21 @@ function initConsoleScene() { var pane = consoleMenu.lookup("#bar"); consoleBar = pane; - pane.lookup("#close").setOnAction(function(){ + pane.lookup("#close").setOnAction(function() { consoleStage.hide(); }); var text = consoleMenu.lookup("#textField"); var output = consoleMenu.lookup("#output"); var appendFunction = function(line) javafx.application.Platform.runLater(function() output.appendText(line)); - consoleMenu.lookup("#send").setOnAction(function(){ + consoleMenu.lookup("#send").setOnAction(function() { execCommand(text.getText()); - if (text.getText() == "clear") { - output.setText(""); - } + if (text.getText() == "clear") { + output.setText(""); + } text.setText(""); }); FunctionalBridge.addPlainOutput(function(string) { - appendFunction(string+"\n"); + appendFunction(string + "\n"); }) pane.lookup("#hide").setOnAction(function(event) { consoleStage.setIconified(true) }); @@ -153,9 +153,9 @@ function initConsoleScene() { /* ======== init Options window======== */ function initOptionsScene() { - optionsMenu.setOnMousePressed(function(event){ movePoint = new javafx.geometry.Point2D(event.getSceneX(), event.getSceneY())}); + optionsMenu.setOnMousePressed(function(event) { movePoint = new javafx.geometry.Point2D(event.getSceneX(), event.getSceneY()) }); optionsMenu.setOnMouseDragged(function(event) { - if(movePoint === null) { + if (movePoint === null) { return; } @@ -165,9 +165,9 @@ function initOptionsScene() { var pane = optionsMenu.lookup("#bar"); bar = pane; - pane.lookup("#close").setOnAction(function(event){ javafx.application.Platform.exit()}); - pane.lookup("#hide").setOnAction(function(event){ stage.setIconified(true)}); - pane.lookup("#back").setOnAction(function(){ + pane.lookup("#close").setOnAction(function(event) { javafx.application.Platform.exit() }); + pane.lookup("#hide").setOnAction(function(event) { stage.setIconified(true) }); + pane.lookup("#back").setOnAction(function() { setCurrentScene(menuScene); }); } @@ -202,29 +202,29 @@ function goAuth(event) { return; // No auth selected } - var rsaPassword = null; - var auth = authOptions.getSelectionModel().getSelectedItem(); - if (auth === null) { + var rsaPassword = null; + var auth = authOptions.getSelectionModel().getSelectedItem(); + if (auth === null) { return; - } - if (!passwordField.isDisable()) { - var password = passwordField.getText(); - if (password !== null && !password.isEmpty()) { - rsaPassword = settingsOverlay.setPassword(password); - } else if (settings.rsaPassword !== null) { - rsaPassword = settings.rsaPassword; - } else { - return; - } + } + if (!passwordField.isDisable()) { + var password = passwordField.getText(); + if (password !== null && !password.isEmpty()) { + rsaPassword = settingsOverlay.setPassword(password); + } else if (settings.rsaPassword !== null) { + rsaPassword = settings.rsaPassword; + } else { + return; + } - settings.rsaPassword = savePasswordBox.isSelected() ? rsaPassword : null; - } + settings.rsaPassword = savePasswordBox.isSelected() ? rsaPassword : null; + } - settings.login = login; - doAuth(login, rsaPassword, authTypes[auth]); - } + settings.login = login; + doAuth(login, rsaPassword, authTypes[auth]); +} - /* ======== Console ======== */ +/* ======== Console ======== */ function goConsole(event) { setConsoleCurrentScene(consoleScene); } @@ -267,7 +267,7 @@ function verifyLauncher(e) { authOptions.getSelectionModel().select(0); var sm = authOptions.getSelectionModel().selectedIndexProperty(); sm.addListener(new javafx.beans.value.ChangeListener({ - changed: function (observableValue, oldSelection, newSelection) { + changed: function(observableValue, oldSelection, newSelection) { settings.auth = authTypes[authOptions.getSelectionModel().getSelectedItem()]; } })); @@ -287,14 +287,18 @@ function verifyLauncher(e) { function doAuth(login, rsaPassword, auth_type) { processing.resetOverlay(); - overlay.show(processing.overlay, function (event) { + overlay.show(processing.overlay, function(event) { FunctionalBridge.getHWID.join(); - makeAuthRequest(login, rsaPassword, auth_type, function (result) { + makeAuthRequest(login, rsaPassword, auth_type, function(result) { FunctionalBridge.setAuthParams(result); - loginData = { pp: result.playerProfile , accessToken: result.accessToken, permissions: result.permissions, - auth_type: settings.auth}; + loginData = { + pp: result.playerProfile, + accessToken: result.accessToken, + permissions: result.permissions, + auth_type: settings.auth + }; - overlay.hide(0, function () { + overlay.hide(0, function() { setCurrentScene(menuScene); }); return result; @@ -355,10 +359,8 @@ function doUpdate(profile, pp, accessToken) { function doLaunchClient(assetDir, assetHDir, clientDir, clientHDir, profile, pp, accessToken) { processing.resetOverlay(); - overlay.swap(0, processing.overlay, function(event) - launchClient(assetHDir, clientHDir, profile, new ClientLauncherParams(settings.lastDigest, - assetDir, clientDir, pp, accessToken, settings.autoEnter, settings.fullScreen, settings.ram, 0, 0), doDebugClient) -); + overlay.swap(0, processing.overlay, function(event) launchClient(assetHDir, clientHDir, profile, new ClientLauncherParams(settings.lastDigest, + assetDir, clientDir, pp, accessToken, settings.autoEnter, settings.fullScreen, settings.ram, 0, 0), doDebugClient)); } function doDebugClient(process) { @@ -398,10 +400,10 @@ function updateProfilesList(profiles) { if (profile.getOptional() != null) profile.updateOptionalGraph(); index++; }); - LogHelper.debug("Load selected %d profile",settings.profile); - if(profiles.length > 0) { - if(settings.profile >= profiles.length) - settings.profile = profiles.length-1; + LogHelper.debug("Load selected %d profile", settings.profile); + if (profiles.length > 0) { + if (settings.profile >= profiles.length) + settings.profile = profiles.length - 1; serverHolder.set(serverList.getChildren().get(settings.profile)); } } @@ -412,11 +414,11 @@ function pingServer(btn) { var task = newTask(function() pingers[profile].ping()); task.setOnSucceeded(function(event) { var result = task.getValue(); - if(btn==serverHolder.old){ + if (btn == serverHolder.old) { setServerStatus(java.lang.String.format("%d из %d", result.onlinePlayers, result.maxPlayers)); } }); - task.setOnFailed(function(event){ if(btn==serverHolder.old){setServerStatus("Недоступен")}}); + task.setOnFailed(function(event) { if (btn == serverHolder.old) { setServerStatus("Недоступен") } }); startTask(task); } @@ -482,7 +484,7 @@ var overlay = { fade(overlay.current, delay, 1.0, 0.0, function(event) { dimPane.requestFocus(); - if(overlay.current==null){ + if (overlay.current == null) { overlay.show(newOverlay, onFinished); return; } @@ -504,13 +506,13 @@ var overlay = { var serverHolder = { old: null, - set: function(btn){ + set: function(btn) { pingServer(btn); serverLabel.setText(profilesList[btn]); serverDescription.setText(profilesList[btn].info); btn.setSelected(true); btn.setDisable(true); - if(serverHolder.old!=null){ + if (serverHolder.old != null) { serverHolder.old.setSelected(false); serverHolder.old.setDisable(false); } @@ -527,4 +529,4 @@ launcher.loadScript("dialog/overlay/update/update.js"); /* ======== Scenes scripts ======== */ launcher.loadScript("dialog/scenes/options/options.js"); -launcher.loadScript("dialog/scenes/console/console.js"); +launcher.loadScript("dialog/scenes/console/console.js"); \ No newline at end of file diff --git a/Launcher/runtime/dialog/overlay/debug/debug.css b/Launcher/runtime/dialog/overlay/debug/debug.css index 85f6905f..61a3ffe1 100644 --- a/Launcher/runtime/dialog/overlay/debug/debug.css +++ b/Launcher/runtime/dialog/overlay/debug/debug.css @@ -4,23 +4,23 @@ Button { } /* Outputs */ -#overlay > #output, -#background > #output { +#overlay>#output, +#background>#output { -fx-background-color: white; -fx-background-radius: 0; -fx-font-family: monospace; -fx-font-size: 8pt; } -#overlay > #output .content, -#background > #output .content { +#overlay>#output .content, +#background>#output .content { -fx-background-color: white; -fx-background-radius: 0; } /* Close button */ -#overlay > #copy, -#overlay > #action.close { +#overlay>#copy, +#overlay>#action.close { -fx-background-radius: 0; -fx-text-fill: white; -fx-background-position: center; @@ -29,17 +29,17 @@ #overlay > #action.close { -fx-pref-height: 25px; } -#overlay > #copy:hover, -#overlay > #copy:focused, -#overlay > #action.close:hover, -#overlay > #action.close:focused, -#overlay > #copy:pressed, -#overlay > #action.close:pressed { +#overlay>#copy:hover, +#overlay>#copy:focused, +#overlay>#action.close:hover, +#overlay>#action.close:focused, +#overlay>#copy:pressed, +#overlay>#action.close:pressed { -fx-background-color: #1568ce; } /* Kill button */ -#overlay > #action.kill { +#overlay>#action.kill { -fx-background-radius: 0; -fx-text-fill: white; -fx-background-position: center; @@ -48,9 +48,10 @@ #overlay > #action.kill { -fx-pref-height: 25px; } -#overlay > #action.kill:hover, -#overlay > #action.kill:focused, -#overlay > #action.kill:pressed { +#overlay>#action.kill:hover, +#overlay>#action.kill:focused, +#overlay>#action.kill:pressed { -fx-background-color: #DB5252; } + /*-- DrLeonardo Design --*/ \ No newline at end of file diff --git a/Launcher/runtime/dialog/overlay/debug/debug.js b/Launcher/runtime/dialog/overlay/debug/debug.js index 389b2475..0f67fb54 100644 --- a/Launcher/runtime/dialog/overlay/debug/debug.js +++ b/Launcher/runtime/dialog/overlay/debug/debug.js @@ -1,10 +1,13 @@ var debug = { - overlay: null, output: null, action: null, process: null, + overlay: null, + output: null, + action: null, + process: null, initOverlay: function() { debug.overlay = loadFXML("dialog/overlay/debug/debug.fxml"); - debug.overlay.lookup("#version").setText( + debug.overlay.lookup("#version").setText( java.lang.String.format( "%s | Java %s x%s", FunctionalBridge.getLauncherVersion(), @@ -22,7 +25,7 @@ var debug = { content.putString(debug.output.getText()); javafx.scene.input.Clipboard.getSystemClipboard(). - setContent(content); + setContent(content); }); debug.action = debug.overlay.lookup("#action"); @@ -47,8 +50,7 @@ var debug = { append: function(text) { //Experimental Feature - if(debug.output.getText().length() > 32000 /* Max length */) - { + if (debug.output.getText().length() > 32000 /* Max length */ ) { debug.output.deleteText(0, text.length()); } debug.output.appendText(text); @@ -79,7 +81,7 @@ function debugProcess(process) { var reader = IOHelper.newReader(process.getInputStream(), java.nio.charset.Charset.defaultCharset()); var appendFunction = function(line) - javafx.application.Platform.runLater(function() debug.append(line)); + javafx.application.Platform.runLater(function() debug.append(line)); for (var length = reader.read(buffer); length >= 0; length = reader.read(buffer)) { appendFunction(new java.lang.String(buffer, 0, length)); } @@ -97,4 +99,4 @@ function debugProcess(process) { }); startTask(task); -} +} \ No newline at end of file diff --git a/Launcher/runtime/dialog/overlay/processing/processing.css b/Launcher/runtime/dialog/overlay/processing/processing.css index 39c74e65..dc405dc0 100644 --- a/Launcher/runtime/dialog/overlay/processing/processing.css +++ b/Launcher/runtime/dialog/overlay/processing/processing.css @@ -1,11 +1,12 @@ /*-- DrLeonardo Design --*/ -#overlay > #description { +#overlay>#description { -fx-font-size: 12pt; -fx-text-fill: #fff; -fx-wrap-text: true; } -#overlay > #description.error { +#overlay>#description.error { -fx-text-fill: red; } + /*-- DrLeonardo Design --*/ \ No newline at end of file diff --git a/Launcher/runtime/dialog/overlay/processing/processing.js b/Launcher/runtime/dialog/overlay/processing/processing.js index cfff7bc6..f80d6074 100644 --- a/Launcher/runtime/dialog/overlay/processing/processing.js +++ b/Launcher/runtime/dialog/overlay/processing/processing.js @@ -1,6 +1,9 @@ var processing = { - overlay: null, spinner: null, description: null, - processingImage: null, errorImage: null, + overlay: null, + spinner: null, + description: null, + processingImage: null, + errorImage: null, initOverlay: function() { processing.overlay = loadFXML("dialog/overlay/processing/processing.fxml"); @@ -69,6 +72,7 @@ function makeLauncherRequest(callback) { task.updateMessage("Обновление лаунчера"); startTask(task); } + function makeProfilesRequest(callback) { var task = newRequestTask(new ProfilesRequest()); @@ -83,6 +87,7 @@ function makeProfilesRequest(callback) { task.updateMessage("Обновление профилей"); startTask(task); } + function makeAuthAvailabilityRequest(callback) { var task = newRequestTask(new GetAvailabilityAuthRequest()); @@ -98,6 +103,7 @@ function makeAuthAvailabilityRequest(callback) { task.updateMessage("Обновление способов авторизации"); startTask(task); } + function makeSetProfileRequest(profile, callback) { var task = newRequestTask(new SetProfileRequest(profile)); @@ -128,4 +134,4 @@ function launchClient(assetHDir, clientHDir, profile, params, callback) { processing.setTaskProperties(task, callback, null, true); task.updateMessage("Запуск выбранного клиента"); startTask(task); -} +} \ No newline at end of file diff --git a/Launcher/runtime/dialog/overlay/settings/settings.css b/Launcher/runtime/dialog/overlay/settings/settings.css index 544826aa..0e18cf86 100644 --- a/Launcher/runtime/dialog/overlay/settings/settings.css +++ b/Launcher/runtime/dialog/overlay/settings/settings.css @@ -1,14 +1,19 @@ /*-- DrLeonardo Design --*/ + #holder { - -fx-background-color: #fff; + -fx-background-color: #fff; } -#holder > #transferDialog { + +#holder>#transferDialog { -fx-background-color: rgba(0, 0, 0, 0.5); -fx-pref-width: 694px; -fx-pref-height: 425px; } + + /* Labels */ -#holder > #settingsTitle { + +#holder>#settingsTitle { -fx-font-size: 14pt; -fx-alignment: baseline-center; } @@ -19,30 +24,35 @@ #holder #dirChange { -fx-font-weight: bold; } + /* RAM slider */ -#holder > #ramSlider > .track { + +#holder>#ramSlider>.track { -fx-background-color: #909090; } -#holder > #ramSlider > .thumb { +#holder>#ramSlider>.thumb { -fx-background-color: #5fd97a; } -#holder > #ramSlider > .colored-track { +#holder>#ramSlider>.colored-track { -fx-background-color: #5fd97a; } -#holder > #ramSlider > .animated-thumb { +#holder>#ramSlider>.animated-thumb { -fx-background-color: #5fd97a; } -#holder > #ramSlider > .slider-value { +#holder>#ramSlider>.slider-value { -fx-fill: white; -fx-stroke: white; } + /* Dir options */ -#holder > #deleteDir, #cancelTransfer { + +#holder>#deleteDir, +#cancelTransfer { -fx-background-radius: 0; -fx-text-fill: white; -fx-background-position: center; @@ -51,23 +61,26 @@ #holder > #deleteDir, #cancelTransfer { -fx-pref-height: 25px; } -#holder > #deleteDir:hover,#cancelTransfer:hover, -#holder > #deleteDir:focused,#cancelTransfer:focused { +#holder>#deleteDir:hover, +#cancelTransfer:hover, +#holder>#deleteDir:focused, +#cancelTransfer:focused { -fx-background-color: #DB5252; } -#holder > #changeDir { +#holder>#changeDir { -fx-background-color: transparent; -fx-text-fill: #909090; -fx-background-radius: 0; } -#holder > #changeDir:focused, -#holder > #changeDir:pressed { +#holder>#changeDir:focused, +#holder>#changeDir:pressed { -fx-font-weight: bold; } -#holder > #apply,#applyTransfer{ +#holder>#apply, +#applyTransfer { -fx-background-color: #5fd97a; -fx-background-radius: 0; -fx-text-fill: white; @@ -75,8 +88,13 @@ #holder > #apply,#applyTransfer{ -fx-pref-width: 150px; -fx-pref-height: 25px; } -#holder > #apply:hover,#applyTransfer:hover, -#holder > #apply:focused,#applyTransfer:focused{ + +#holder>#apply:hover, +#applyTransfer:hover, +#holder>#apply:focused, +#applyTransfer:focused { -fx-background-color: #75e18c; } + + /*-- DrLeonardo Design --*/ \ No newline at end of file diff --git a/Launcher/runtime/dialog/overlay/settings/settings.js b/Launcher/runtime/dialog/overlay/settings/settings.js index 17090929..9a4dfe50 100644 --- a/Launcher/runtime/dialog/overlay/settings/settings.js +++ b/Launcher/runtime/dialog/overlay/settings/settings.js @@ -1,7 +1,11 @@ var settingsOverlay = { -/* ===================== OVERLAY ===================== */ - overlay: null, ramLabel: null, dirLabel: null, transferDialog: null, - deleteDirPressedAgain: false, count: 0, + /* ===================== OVERLAY ===================== */ + overlay: null, + ramLabel: null, + dirLabel: null, + transferDialog: null, + deleteDirPressedAgain: false, + count: 0, initOverlay: function() { settingsOverlay.overlay = loadFXML("dialog/overlay/settings/settings.fxml"); @@ -14,8 +18,7 @@ var settingsOverlay = { function(o, ov, nv) settings.autoEnter = nv); settingsOverlay.dirLabel = holder.lookup("#dirLabel"); - settingsOverlay.dirLabel.setOnAction(function(event) - app.getHostServices().showDocument(settings.updatesDir.toUri())); + settingsOverlay.dirLabel.setOnAction(function(event) app.getHostServices().showDocument(settings.updatesDir.toUri())); settingsOverlay.updateDirLabel(); settingsOverlay.transferDialog = holder.lookup("#transferDialog"); @@ -70,17 +73,17 @@ var settingsOverlay = { settingsOverlay.deleteUpdatesDir(); settingsOverlay.deleteDirPressedAgain = false; - settingsOverlay.count = settingsOverlay.count+1; - if(settingsOverlay.count>9){ - javafx.application.Platform.exit(); - } + settingsOverlay.count = settingsOverlay.count + 1; + if (settingsOverlay.count > 9) { + javafx.application.Platform.exit(); + } deleteDirButton.setText( - settingsOverlay.count>8?"Прощай :(": - (settingsOverlay.count>7?"Я умираю!": - (settingsOverlay.count>5?"DeathCry, спаси!": - (settingsOverlay.count>4?"Умоляю, перестань!": - (settingsOverlay.count>3?"Да хорош уже!":"Ещё раз") - )))); + settingsOverlay.count > 8 ? "Прощай :(" : + (settingsOverlay.count > 7 ? "Я умираю!" : + (settingsOverlay.count > 5 ? "DeathCry, спаси!" : + (settingsOverlay.count > 4 ? "Умоляю, перестань!" : + (settingsOverlay.count > 3 ? "Да хорош уже!" : "Ещё раз") + )))); }); var debugBox = settingsOverlay.overlay.lookup("#debug"); @@ -93,8 +96,7 @@ var settingsOverlay = { transferCatalogDialog: function(newDir) { settingsOverlay.transferDialog.setVisible(true); - settingsOverlay.transferDialog.lookup("#cancelTransfer").setOnAction(function(event) - { + settingsOverlay.transferDialog.lookup("#cancelTransfer").setOnAction(function(event) { settings.updatesDir = newDir; DirBridge.dirUpdates = settings.updatesDir; settingsOverlay.updateDirLabel(); @@ -133,11 +135,11 @@ var settingsOverlay = { setRAM: function(ram) { - if (ram>762&&ram<1024){ - settings.ram = java.lang.Math["min(int,int)"](ram, FunctionalBridge.getJVMTotalMemory()); - }else{ - settings.ram = java.lang.Math["min(int,int)"](((ram / 256) | 0) * 256, FunctionalBridge.getJVMTotalMemory()); - } + if (ram > 762 && ram < 1024) { + settings.ram = java.lang.Math["min(int,int)"](ram, FunctionalBridge.getJVMTotalMemory()); + } else { + settings.ram = java.lang.Math["min(int,int)"](((ram / 256) | 0) * 256, FunctionalBridge.getJVMTotalMemory()); + } }, updateDirLabel: function() { @@ -148,9 +150,16 @@ LogHelper.debug("Dir: %s", DirBridge.dir); /* ====================== CLI PARAMS ===================== */ var cliParams = { - login: null, password: null, profile: -1, autoLogin: false, - updatesDir: null, autoEnter: null, fullScreen: null, ram: -1, - offline: false, featureStore: null, + login: null, + password: null, + profile: -1, + autoLogin: false, + updatesDir: null, + autoEnter: null, + fullScreen: null, + ram: -1, + offline: false, + featureStore: null, init: function(params) { var named = params.getNamed(); @@ -200,8 +209,7 @@ var cliParams = { if (cliParams.profile >= 0) { settings.profile = cliParams.profile; } - if (cliParams.updatesDir !== null) { - } + if (cliParams.updatesDir !== null) {} if (cliParams.autoEnter !== null) { settings.autoLogin = cliParams.autoEnter; } @@ -218,4 +226,4 @@ var cliParams = { settings.offline = cliParams.offline; } } -}; +}; \ No newline at end of file diff --git a/Launcher/runtime/dialog/overlay/update/update.css b/Launcher/runtime/dialog/overlay/update/update.css index 4035391a..0ec06064 100644 --- a/Launcher/runtime/dialog/overlay/update/update.css +++ b/Launcher/runtime/dialog/overlay/update/update.css @@ -6,16 +6,16 @@ #overlay { -fx-background-image: url('../../images/downloader/blured.jpg'); } -#overlay > #utitle { +#overlay>#utitle { -fx-alignment: top-left; } -#overlay > #description { +#overlay>#description { -fx-alignment: top-left; -fx-wrap-text: true; } -#overlay > #description.error { +#overlay>#description.error { -fx-text-fill: #CE5757; } @@ -29,15 +29,15 @@ .progress-bar { -fx-background-color: transparent; } -.progress-indicator{ - -fx-background-color: transparent ; +.progress-indicator { + -fx-background-color: transparent; } .progress-indicator .indicator { - -fx-background-color: transparent ; + -fx-background-color: transparent; } -.progress-bar > .bar { +.progress-bar>.bar { -fx-background-image: url("../../images/downloader/line.png"); -fx-background-color: transparent; -fx-background-insets: 0; @@ -45,9 +45,10 @@ .progress-bar > .bar { -fx-padding: 0; } -.progress-bar > .track { +.progress-bar>.track { -fx-background-color: transparent; -fx-background-insets: 0; -fx-background-radius: 3px; } + /*-- DrLeonardo Design --*/ \ No newline at end of file diff --git a/Launcher/runtime/dialog/overlay/update/update.js b/Launcher/runtime/dialog/overlay/update/update.js index 4996f7f8..92803cd5 100644 --- a/Launcher/runtime/dialog/overlay/update/update.js +++ b/Launcher/runtime/dialog/overlay/update/update.js @@ -1,5 +1,8 @@ var update = { - overlay: null, title: null, description: null, progress: null, + overlay: null, + title: null, + description: null, + progress: null, initOverlay: function() { update.overlay = loadFXML("dialog/overlay/update/update.fxml"); @@ -41,7 +44,7 @@ var update = { "Примерно осталось: %d:%02d:%02d%n", state.filePath, - state.getTotalDownloadedMiB() + 0.0, state.getTotalSizeMiB() + 0.0, + state.getTotalDownloadedMiB() + 0.0, state.getTotalSizeMiB() + 0.0, bps <= 0.0 ? 0.0 : bps / 1024.0, estimatedHH, estimatedMM, estimatedSS )); @@ -83,13 +86,13 @@ function offlineUpdateRequest(dirName, dir, matcher, digest) { /* Export functions */ function makeUpdateRequest(dirName, dir, matcher, digest, callback) { - var request = settings.offline ? { setStateCallback: function(stateCallback) { } } : - new UpdateRequest(dirName, dir, matcher, digest); - var task = settings.offline ? newTask(offlineUpdateRequest(dirName, dir, matcher, digest)) : - newRequestTask(request); + var request = settings.offline ? { setStateCallback: function(stateCallback) {} } : + new UpdateRequest(dirName, dir, matcher, digest); + var task = settings.offline ? newTask(offlineUpdateRequest(dirName, dir, matcher, digest)) : + newRequestTask(request); update.setTaskProperties(task, request, callback); task.updateMessage("Состояние: Хеширование"); task.updateProgress(-1, -1); startTask(task); -} +} \ No newline at end of file diff --git a/Launcher/runtime/dialog/scenes/options/options.js b/Launcher/runtime/dialog/scenes/options/options.js index 98c28232..ed573704 100644 --- a/Launcher/runtime/dialog/scenes/options/options.js +++ b/Launcher/runtime/dialog/scenes/options/options.js @@ -5,7 +5,7 @@ var options = { LogHelper.debug("Loading options file"); try { tryWithResources(new HInput(IOHelper.newInput(options.file)), options.read); - } catch(e) { + } catch (e) { LogHelper.error(e); } }, @@ -14,7 +14,7 @@ var options = { LogHelper.debug("Saving options file"); try { tryWithResources(new HOutput(IOHelper.newOutput(options.file)), options.write); - } catch(e) { + } catch (e) { LogHelper.error(e); } }, @@ -24,33 +24,27 @@ var options = { if (magic != config.settingsMagic) { throw new java.io.IOException("options magic mismatch: " + java.lang.Integer.toString(magic, 16)); } - var profilesCount = input.readInt(); - LogHelper.debug("Load options. ProfilesCount %d",profilesCount); - for(var i = 0;i 1) + subLevel = modFile.subTreeLevel; + var testMod = new javafx.scene.control.CheckBox(modName); + testMod.getStyleClass().add("checkboxOpt"); + + if (subLevel > 1) + for (var i = 1; i < subLevel; i++) + testMod.setTranslateX(25 * i); + + testMod.setSelected(modFile.mark); + testMod.setOnAction(function(event) { + var isSelected = event.getSource().isSelected(); + if (isSelected) { + profile.markOptional(modFile); + LogHelper.debug("Selected mod %s", modFile.name); + } else { + profile.unmarkOptional(modFile); + LogHelper.debug("Unselected mod %s", modFile.name); + } + options.update(); }); - nodelist.forEach(function(node,i,arr) { - modlist.getChildren().remove(node); - }); - var profile = profilesList[serverHolder.old]; - var list = profile.getOptional(); - var checkBoxList = new java.util.ArrayList; - list.forEach(function(modFile) { - var modName = modFile.name, modDescription = "", subLevel = 1; - if(!modFile.visible) - { - LogHelper.debug("optionalMod %s hidden",modFile.name); - return; - } - - if(modFile.permissions != 0 && ((loginData.permissions.toLong() & modFile.permissions) == 0)) - { - LogHelper.debug("optionalMod %s permissions deny",modFile.name); - return; - } - if(modFile.info != null) - modDescription = modFile.info; - if(modFile.subTreeLevel != null && modFile.subTreeLevel > 1) - subLevel = modFile.subTreeLevel; - var testMod = new javafx.scene.control.CheckBox(modName); - testMod.getStyleClass().add("checkboxOpt"); - - if(subLevel > 1) - for(var i = 1; i < subLevel; i++) - testMod.setTranslateX(25*i); - - testMod.setSelected(modFile.mark); - testMod.setOnAction(function(event) { - var isSelected = event.getSource().isSelected(); - if(isSelected) - { - profile.markOptional(modFile); - LogHelper.debug("Selected mod %s", modFile.name); - } - else - { - profile.unmarkOptional(modFile); - LogHelper.debug("Unselected mod %s", modFile.name); - } - options.update(); - }); - testMod.setFocusTraversable(false); - checkBoxList.add(testMod); - testMod.getStyleClass().add("modname"); - if(modDescription != "") { - textDescr = new javafx.scene.text.Text(modDescription); - if(subLevel > 1) { - for(var i = 1; i < subLevel; i++){ - textDescr.setWrappingWidth(620-(25*i)); - textDescr.setTranslateX(25+(25*i)); - } - } else { - textDescr.setWrappingWidth(620); - textDescr.setTranslateX(25); - } - textDescr.setTextAlignment(javafx.scene.text.TextAlignment.JUSTIFY); - textDescr.getStyleClass().add("description-text"); - checkBoxList.add(textDescr); - } - sep = new javafx.scene.control.Separator(); - sep.getStyleClass().add("separator"); - checkBoxList.add(sep); - }); - modlist.getChildren().clear(); - modlist.getChildren().addAll(checkBoxList); + testMod.setFocusTraversable(false); + checkBoxList.add(testMod); + testMod.getStyleClass().add("modname"); + if (modDescription != "") { + textDescr = new javafx.scene.text.Text(modDescription); + if (subLevel > 1) { + for (var i = 1; i < subLevel; i++) { + textDescr.setWrappingWidth(620 - (25 * i)); + textDescr.setTranslateX(25 + (25 * i)); + } + } else { + textDescr.setWrappingWidth(620); + textDescr.setTranslateX(25); + } + textDescr.setTextAlignment(javafx.scene.text.TextAlignment.JUSTIFY); + textDescr.getStyleClass().add("description-text"); + checkBoxList.add(textDescr); + } + sep = new javafx.scene.control.Separator(); + sep.getStyleClass().add("separator"); + checkBoxList.add(sep); + }); + modlist.getChildren().clear(); + modlist.getChildren().addAll(checkBoxList); } -}; +}; \ No newline at end of file diff --git a/Launcher/runtime/dialog/servers.css b/Launcher/runtime/dialog/servers.css index 11d11a93..b0852e67 100644 --- a/Launcher/runtime/dialog/servers.css +++ b/Launcher/runtime/dialog/servers.css @@ -1,6 +1,6 @@ /*-- DrLeonardo Design --*/ - /* Server buttons */ + .server-button { -fx-font-weight: bold; -fx-font-size: 16pt; @@ -16,14 +16,14 @@ .server-button { } .server-button:selected { - -fx-effect: dropshadow(gaussian, rgba(23, 25, 29, 0.3), 15,0,0,3); + -fx-effect: dropshadow(gaussian, rgba(23, 25, 29, 0.3), 15, 0, 0, 3); } + /** server-button- **/ .server-button-Example { -fx-background-image: url('images/servers/example.png'); } - /*-- DrLeonardo Design --*/ \ No newline at end of file diff --git a/Launcher/runtime/dialog/styles.css b/Launcher/runtime/dialog/styles.css index 0091ec73..e613ab1d 100644 --- a/Launcher/runtime/dialog/styles.css +++ b/Launcher/runtime/dialog/styles.css @@ -1,6 +1,6 @@ /*-- Without jfoenix --*/ Button { - -fx-background-color: TRANSPARENT, TRANSPARENT, TRANSPARENT, TRANSPARENT; + -fx-background-color: TRANSPARENT, TRANSPARENT, TRANSPARENT, TRANSPARENT; -fx-background-radius: 3px; -fx-background-insets: 0px; } @@ -12,7 +12,7 @@ CheckBox .box-container { CheckBox .box, CheckBox:indeterminate .box, -CheckBox:indeterminate:selected .box{ +CheckBox:indeterminate:selected .box { -fx-pref-width: 18; -fx-pref-height: 18; @@ -27,11 +27,11 @@ CheckBox:indeterminate:selected .box{ CheckBox:selected .box { -fx-border-color: #5fd97a; - -fx-background-color: #5fd97a; + -fx-background-color: #5fd97a; } CheckBox .mark { - -fx-background-color: TRANSPARENT; + -fx-background-color: TRANSPARENT; } CheckBox:selected .mark { @@ -46,7 +46,7 @@ CheckBox:selected .mark { -fx-border-radius: 2; } -CheckBox .indeterminate-mark{ +CheckBox .indeterminate-mark { -fx-background-color: #5fd97a; -fx-background-radius: 2; -fx-border-width: 0; @@ -56,8 +56,11 @@ CheckBox .indeterminate-mark{ /*-- DrLeonardo Design --*/ -Button, CheckBox, ComboBox, RadioButton { - -fx-cursor: hand; +Button, +CheckBox, +ComboBox, +RadioButton { + -fx-cursor: hand; } @@ -69,20 +72,22 @@ #layout { -fx-pref-height: 450px; -fx-background-image: url('images/background.jpg'); } + #background { -fx-background-color: #fff; } + /** Labels **/ -#background > #settingsTitle { +#background>#settingsTitle { -fx-font-size: 14pt; -fx-alignment: baseline-center; } -#serverLabel{ +#serverLabel { -fx-text-fill: #323232; } -#serverStatus{ +#serverStatus { -fx-text-fill: #323232; -fx-pref-width: 120px; -fx-pref-height: 25px; @@ -90,17 +95,17 @@ #serverStatus{ /* Mask */ #mask { - -fx-effect: DropShadow( gaussian , rgba(255,255,255,0.5) , 0,0,0,1 ); + -fx-effect: DropShadow(gaussian, rgba(255, 255, 255, 0.5), 0, 0, 0, 1); } /** Errors **/ -#errormessage{ +#errormessage { -fx-background-color: transparent; -fx-text-alignment: center; -fx-text-fill: #CE5757; } -.error{ +.error { -fx-text-fill: #CE5757; } @@ -110,6 +115,7 @@ #bar { -fx-pref-width: 46px; -fx-pref-height: 450px; } + /** buttons in bar **/ #close { -fx-background-position: center; @@ -118,28 +124,35 @@ #close { -fx-pref-width: 46px; -fx-pref-height: 45px; } -#hide, #back, #goConsole, #settings, #discord { + +#hide, +#back, +#goConsole, +#settings, +#discord { -fx-background-position: center; -fx-background-radius: 0; -fx-pref-width: 46px; -fx-pref-height: 45px; } -#logout{ - -fx-text-fill:#323232; - -fx-font-size:12; - -fx-font-weight:normal; - -fx-border-color:#CE5757; - -fx-border-width:1; - -fx-background-color:transparent; - -fx-padding:0; +#logout { + -fx-text-fill: #323232; + -fx-font-size: 12; + -fx-font-weight: normal; + -fx-border-color: #CE5757; + -fx-border-width: 1; + -fx-background-color: transparent; + -fx-padding: 0; } + #logout:hover, -#logout:focus{ - -fx-text-fill:#ff6a5e; +#logout:focus { + -fx-text-fill: #ff6a5e; } -#logout:pressed{ - -fx-border-color:#cb4d43; + +#logout:pressed { + -fx-border-color: #cb4d43; } #send { @@ -151,7 +164,9 @@ #send { -fx-pref-height: 30px; } -#send:pressed { -fx-background-color: #d8d8d8; } +#send:pressed { + -fx-background-color: #d8d8d8; +} /* LoginMenu */ #authPane { @@ -176,18 +191,22 @@ .auth { -fx-text-fill: #ffffff; -fx-pref-width: 200px; -fx-pref-height: 45px; - -fx-effect: dropshadow(gaussian, rgba(23, 25, 29, 0.3), 15,0,0,3); + -fx-effect: dropshadow(gaussian, rgba(23, 25, 29, 0.3), 15, 0, 0, 3); } -.auth:hover, .auth:pressed { -fx-background-color: #75e18c; } +.auth:hover, +.auth:pressed { + -fx-background-color: #75e18c; +} -#password, #login { +#password, +#login { -fx-background-radius: 0; -fx-pref-width: 200px; -fx-pref-height: 30px; } -.text-input{ +.text-input { -fx-focus-color: transparent; -fx-background-repeat: no-repeat; -fx-text-fill: #909090; @@ -208,21 +227,26 @@ #link { -fx-pref-height: 17px; } -#link:hover, #link:pressed { -fx-opacity: 0.8; } +#link:hover, +#link:pressed { + -fx-opacity: 0.8; +} /** CheckBox & ComboBox**/ -#rememberchb{ +#rememberchb { -fx-font-size: 13; -fx-text-fill: #909090; -fx-pref-width: 145px; -fx-pref-height: 30px; } + #combologin { -fx-text-fill: #909090; -fx-prompt-text-fill: #909090; -fx-pref-width: 200px; -fx-pref-height: 30px; } + .combologin, .combologin { -fx-font-size: 13px; @@ -240,7 +264,7 @@ .combologin .list-cell { .combologin-popup .list-view { -fx-background-color: white, white; -fx-background-insets: 0, 1; - -fx-effect: dropshadow( three-pass-box , rgba(0,0,0,0.6) , 8, 0.0 , 0 , 0 ); + -fx-effect: dropshadow(three-pass-box, rgba(0, 0, 0, 0.6), 8, 0.0, 0, 0); } .combologin .list-cell:filled:selected .text, @@ -253,20 +277,18 @@ .combologin .arrow { -fx-background-color: #5fd97a; } -.combologin-popup .list-view .list-cell -{ +.combologin-popup .list-view .list-cell { -fx-background-color: white; } -.combologin-popup .list-view .list-cell:filled:selected, .combologin-popup .list-view .list-cell:filled:selected:hover -{ +.combologin-popup .list-view .list-cell:filled:selected, +.combologin-popup .list-view .list-cell:filled:selected:hover { -fx-background: -fx-accent; -fx-background-color: -fx-selection-bar; -fx-text-fill: #909090; } -.combologin-popup .list-view .list-cell:filled:hover -{ +.combologin-popup .list-view .list-cell:filled:hover { -fx-background-color: white; -fx-text-fill: #909090; } @@ -286,20 +308,24 @@ .serverentrance { } /** buttons **/ -.clientLaunch{ +.clientLaunch { -fx-font-weight: bold; -fx-font-size: 16pt; -fx-background-radius: 0; -fx-background-color: #5fd97a; -fx-text-fill: #ffffff; } -.clientSettings{ + +.clientSettings { -fx-background-position: center; -fx-background-color: #5fd97a; -fx-background-radius: 0; } -.clientLaunch:hover, .clientLaunch:pressed { -fx-background-color: #75e18c; } +.clientLaunch:hover, +.clientLaunch:pressed { + -fx-background-color: #75e18c; +} /* Scrolls */ .scroll-pane { @@ -340,11 +366,11 @@ .scroll-pane>.corner { } /* OptionsPane */ -#optionsPane > #modlist { +#optionsPane>#modlist { -fx-background-color: transparent; } -#optionsPane > #modlist > .viewport { +#optionsPane>#modlist>.viewport { -fx-background-color: transparent; } @@ -368,38 +394,42 @@ .separator *.line { -fx-border-width: 0 0 10 0; } -#serverlist{ - -fx-background-color: transparent; -} -#serverlist > .viewport { +#serverlist { -fx-background-color: transparent; } -#serverdesc{ - -fx-background-color: transparent; -} -#serverdesc > .viewport { +#serverlist>.viewport { -fx-background-color: transparent; } -#serverinfo{ - -fx-background-color: transparent; -} -#serverinfo > .viewport { +#serverdesc { -fx-background-color: transparent; } -#servercontainer{ +#serverdesc>.viewport { + -fx-background-color: transparent; +} + +#serverinfo { + -fx-background-color: transparent; +} + +#serverinfo>.viewport { + -fx-background-color: transparent; +} + +#servercontainer { -fx-background-color: transparent; -fx-pref-width: 282px; -fx-pref-height: 75px; } -.toggle-button:disabled{ +.toggle-button:disabled { -fx-opacity: 1.0; } -.heading{ +.heading { -fx-text-fill: #555555; } + /*-- DrLeonardo Design --*/ \ No newline at end of file diff --git a/Launcher/runtime/init.js b/Launcher/runtime/init.js index 9b1ccb43..b3d9a949 100644 --- a/Launcher/runtime/init.js +++ b/Launcher/runtime/init.js @@ -9,7 +9,8 @@ var LauncherApp = Java.extend(JSApplication, { settings = SettingsManager.settings; settingsManager.loadHDirStore(); cliParams.applySettings(); - }, start: function(primaryStage) { + }, + start: function(primaryStage) { stage = primaryStage; stage.initStyle(javafx.stage.StageStyle.TRANSPARENT); stage.setResizable(false); @@ -45,7 +46,8 @@ var LauncherApp = Java.extend(JSApplication, { setCurrentScene(loginScene); initLauncher(); - }, stop: function() { + }, + stop: function() { settingsManager.saveConfig(); settingsManager.saveHDirStore(); options.save(); @@ -82,7 +84,7 @@ function start(args) { if (config.jvm.enable) { switch (JVMHelper.OS_TYPE) { case JVMHelperOS.MUSTDIE: - jvmDirName = JVMHelper.OS_BITS === 32 ? config.jvm.jvmMustdie32Dir : + jvmDirName = JVMHelper.OS_BITS === 32 ? config.jvm.jvmMustdie32Dir : jvmDirName = JVMHelper.OS_BITS === 64 ? config.jvm.jvmMustdie64Dir : config.jvm.enable = false; break; default: From bc6315391b503bf91624b3e50e0cd7fac3763514 Mon Sep 17 00:00:00 2001 From: LoomeL Date: Wed, 14 Aug 2019 16:21:06 +0600 Subject: [PATCH 2/3] [ANY] Cut FontAwesome-FX --- Launcher/build.gradle | 1 - Launcher/runtime/dialog/images/icons/back.png | Bin 0 -> 2130 bytes .../runtime/dialog/images/icons/close.png | Bin 0 -> 2181 bytes .../runtime/dialog/images/icons/console.png | Bin 0 -> 2247 bytes .../runtime/dialog/images/icons/discord.png | Bin 0 -> 2482 bytes Launcher/runtime/dialog/images/icons/hide.png | Bin 0 -> 2009 bytes Launcher/runtime/dialog/images/icons/list.png | Bin 0 -> 2417 bytes .../runtime/dialog/images/icons/settings.png | Bin 0 -> 2586 bytes .../dialog/scenes/console/console.fxml | 55 ++++++----- .../runtime/dialog/scenes/login/login.fxml | 50 ++++++---- .../dialog/scenes/mainmenu/mainmenu.fxml | 89 +++++++++++------- .../dialog/scenes/options/options.fxml | 46 +++++---- 12 files changed, 141 insertions(+), 100 deletions(-) create mode 100644 Launcher/runtime/dialog/images/icons/back.png create mode 100644 Launcher/runtime/dialog/images/icons/close.png create mode 100644 Launcher/runtime/dialog/images/icons/console.png create mode 100644 Launcher/runtime/dialog/images/icons/discord.png create mode 100644 Launcher/runtime/dialog/images/icons/hide.png create mode 100644 Launcher/runtime/dialog/images/icons/list.png create mode 100644 Launcher/runtime/dialog/images/icons/settings.png diff --git a/Launcher/build.gradle b/Launcher/build.gradle index a1d73860..8c40adc7 100644 --- a/Launcher/build.gradle +++ b/Launcher/build.gradle @@ -39,7 +39,6 @@ dependencies { pack project(':LauncherAuthlib') bundle 'com.github.oshi:oshi-core:3.13.0' - bundle 'de.jensd:fontawesomefx:8.9' bundle 'org.apache.httpcomponents:httpclient:4.5.7' pack 'io.netty:netty-codec-http:4.1.36.Final' pack 'org.ow2.asm:asm-tree:7.1' diff --git a/Launcher/runtime/dialog/images/icons/back.png b/Launcher/runtime/dialog/images/icons/back.png new file mode 100644 index 0000000000000000000000000000000000000000..9c261d9f66c5dc0be9c0e14a5fe097e0eb106f72 GIT binary patch literal 2130 zcmcIleNYr-7~k`w@DQSOL?y;;snEf_-M#N!y$}wBV?0101wTgjcHiSp?snJRg*!-t zOz|5>8%CW{G(Q?L{io7#us~DMOa@6J%}L6dnoKCs8B5dNgX3}U%Z8t7eAB*i^vLyBZ|%5BKi{U=A|G54}5E^kKT*1HM$TKNHz^ZD&%af@m$DYi))=$6s)BF(JCg=IDKw!~g6=`A|< zJ}Bwvc{%OHO;2yHYcm|3w0dpMn9d8cgodoB z8B=ZXC27Iky6RWQPkZaSt5up1+sjrJ@l6)#h$i|-=HYp(ZjPHCTaC1w&ikvcF!c;OUtQ2IK{SF)PYp^eR|Ztn1xmew z4eM=c#!xSB!{(Ztq*Jm3k2kwY28C6*MO;-GNApXQM)Ju)TA@x9A(s_7FtJ{Nm_55it0(qLXZ}MGTg} zqu~RC(PZAu6lBZ{$AWh@%%iFjLlA*LKo>CRM7flJ%|a8Tp3v)Yh`^OfL1lxupd<}4 zWB`Sey^`t`1vJFSy2NtThC!tRDfp!bt)PU<1Pew4S&5)@WGJOUpwszesNWw!D{5v1 zj1t!SNMfa^QUXK)P{eYX1DO>-P?H9O@myrDR4)7aGvzq~_<$e66ex^}gpxd>Dk>iF zF?mE@N3xL^y9`)Wl#4{sH)vG;APZ`@qm$=)1zrp&Q$l*eaFD^Oz=lE3Xq>d-l(C31 zGZe)bjVaJMk{p0KVHfbM$_@=I@?Ll4P@qmH;}8^;6*%C?uwhV?&gemJLXNX*RsCc3M15L||9OQ`9hcN>Zuz;m;)?lD< zGcW?&YBlh<#Y6)WY2qzz+B(RVCwt*{!}=a(4XNTGBWE;G2A7e>X)|lVEqbFBX8}dw zyg^U8fI)92triUBImRu@ein9#*Uy#$LJ~?b^dB{L(I?7Ik%u)mgnAjW!z{AB3N)@V z{B;z9rQwy&i}tr1!*Zccw_#k!V!&hJ$KFR&Z)iFPXagPqNuOZ;08A0xYJinNS}Cmb zf3z0yIOz&o@nqpcv;BV)9xf^8VTDovM<#)VQXxXaWxx>P-(K~Do#QG7Yik zBsf|-vv=NUtN$VHhPo$p)V0p}`!v>JU*~?c6`8Z!-M80q(;@dAn4h_B&hZ~TBd@Gz ztNo^ZyOhF23t6QtO}h-;3)}g7=l+QLHZ^rrUh{+2gB>vqCGJzD@t1#F*X22$(mn2& zR@a*HUBR)5_hXvtZZUPqGm+J2FDJI(7nf|iqu!j-I%eZX_j4v_-q9?0H&Y1C`{mbm gD6mipXnWeC!J@MbpI%QtANtF3WaefZN?*L;M1& literal 0 HcmV?d00001 diff --git a/Launcher/runtime/dialog/images/icons/close.png b/Launcher/runtime/dialog/images/icons/close.png new file mode 100644 index 0000000000000000000000000000000000000000..b3ddaa563ceaad9e47d8b7a3265ecd3b589c86c5 GIT binary patch literal 2181 zcmcIlX;9Q=7!II-h=^@1Dkveeibpod9_%K%D(+GaT|}S?S_iT@*vRfCZUVb7TEMd& z)d8zTr`D@=ig^7|%TNTouW`hpRHv<1ZJj#GSaimzR{AY0Tc@LzKi!#Zz9i50ywCf* zZ{DoR%t#p&HX;myph0P=<}7elfddT<2LG*S-ew32&;nj4R|-XLQx2JEu7Z(T8KMQ3hZ$@f+Je>;CIimwT* z$f)_cq^=l>9JBDmup1qr744RWhuTxm%GI&E(}Us*8lt(lPr@!WU9Jr#`d!$*Z9(MV zirS3py2zPRYd?P$of+opg3`}DSrnOHaZNVHt|gnpUHJhsM$Rv)m|Gp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fc_x!7L0TnTn(%5ww=f)IqMP#6^pB?lx; zQUlVz>y*seP3;v3`fx6xHTv63nkpsCd2L?qM1cA5vEhg5? zn*eU}8GX2kr+qj}TR5DdEk+Y%vXDO7)~yTfcS&5iZl1osr)hbKgB&q`>FKWG#NPm4RA}MjAJoX(P_q zC@an|J}a=<{E!D=D9_pbk`iKJmk1%Y6cDmlilKk1aY{i+aZ5b(+@$w1WQSQy6I58Z zir%+l7Fg7~3JPd<%h_2@?{o*o=_LkGZ_jPvAKbe;ojv;_0RTzwQ2ZX4D*3ettAMOh z==6WI7V&S=RW^KQ;dfW||4n$WrCfj&O93321g57#=)>tE|@^sVdIvgL)krjmxb z=We&%-uhZ#)A$!^>Q9G#nXatlRqvdgnDF$a>0gJBKYC-^L^1NqCGwczLdMFPVc+h; zNxbOd#tB#5!+#ySYKbX*)b6BFaf4G9BA->8I^PmYa`t>x9DiYIMuxRD{}L)RY(Kxi zv;6eh`nc#!Ufz-N_RYe5%}3^!-K?+wa^pAScN{(uoY?;?#_uWK zH@7LR>43Lw{+fXsqqC1*Z7;b{^>X#xn(H&#pX%H<_RyfuublE8OsiVhIn4I;lGmGC zr@DvyK>daV=}*M0xR`PvilH&P~TJL`M*vZJ$* zNl$DqtXTOZ)i$qvNgYo-du#MZ;krH-)@{F@zN~9XJzaa{w*H;W&CYl2e7vOQ4?FN3 Ag#Z8m literal 0 HcmV?d00001 diff --git a/Launcher/runtime/dialog/images/icons/discord.png b/Launcher/runtime/dialog/images/icons/discord.png new file mode 100644 index 0000000000000000000000000000000000000000..f55666a506e63f6c0446ad17c8431f4794725f14 GIT binary patch literal 2482 zcmcImdsGv579OxDic(||bP*kf7USwDwM2sG@;R5i-Ayy` z$2t!*JRkCSX;a!4l92SLnreTD%$VbN0Hs{`c2h`hX)mi>S}8v>*OBX&8nv;Ybi$P;k5N^s8AB90@@Itroq(Y0#xANZQ6HeD&pfYz&8npoG;Ph9C=o z6E=c;i(QEfwRjQOLMf5;5}iQDsDRm$T z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DZ7zT{;FCRFZS+%p75~PC*|IoFu#13 zcG2%gaR2}S literal 0 HcmV?d00001 diff --git a/Launcher/runtime/dialog/images/icons/hide.png b/Launcher/runtime/dialog/images/icons/hide.png new file mode 100644 index 0000000000000000000000000000000000000000..4cccaf233339a1ce8751c5860341c10b36739e50 GIT binary patch literal 2009 zcmcIleQeZZ81KNrHegOMf=;s988$w8{ko5~a>BTq+fD9vi~}~NfnNLGuI#QYZMVBE zm<{rA0h&piT@a5WI-SrQS|NZLt+5;k4@Tp+y36) z^Lw7()92O)16AV+o-9BRWSpK)aTL;=8QR5`Qf6~zdSypumd@KqV~@l z^JboemCV;~JZ7Ca+ou&4BS`L1IaF`f`{(eY8n+2neQn9O2GIyIV`fql#AaZk zVbCNiZfvlxA46ryjV*NeNx$X+QMtNZ2lLtkA+fz#QQxoI&4l{r0g{6;%tvn&bSc8ud7n?mf_H8#YML5P5Q#*>mSAkE-bBD=;Ruo@Xc~tI+-OrwA&DzS zX@v>|lmYtv4~E9$S+rqR zw!$cBz4s(GLTwr#>VToP=pv|W1&Udk2_}izy;_SN8_HA?2@nHu2s5BCDjQ0Rs-|j0 z)%)a;eVxrl<2^bMOjQr5YAj<^FvEg+JZSksS&`I)F~!o8h6Ar)0yhRd<8YG2DSL== z@)X58*lEx?l1xGUunQ!?6ov;@B{|YI9H`&V`xL_z6cPBmZVZaD$+E=Lv_LZ~>%_y1 z-HAt7JAf;S#sMuxBq}UA1PTo4g8RLy*kTpW+MjA#NfjYSwm!T=w1bEg4&xllaX3ZV zT{y=`3=XJ>7~yDvWf?KUR;$bKyAfh{vs$Vo$SAOsQ*eZxI43$CIK$W(oC6GlQ-F*x z4riDpfeS+=k&mc)T!397$Au<9Xi5`?{-egD##G&}O0edP)yt3_W>GC0(73kr*D(() zORr)wI@EH!AX=U7#zf0vAYtjp@;$0IJe?`pL=-^M2biCN8EV8#2s)@}f|dS{)*|jF z-4I$IEPQyj|8K(6B^9HB(gfhhBrq!#!Wu3qLx_KSHT3STL6m{R>1HjnV-?DAn?nEhL*G0Ya*iiLknEoJtK zR|Y!Y&)+vbP_`?;c4_=o^XQMO&gbvDvfH`jgi0zn_pdv~3mZ{F;xY5cAH qPS5lM*QYMuc{xyd_l^|Bw_`Ti_MaiD7dxzf4qs)!+dF&7D}Mv(v8X8k literal 0 HcmV?d00001 diff --git a/Launcher/runtime/dialog/images/icons/list.png b/Launcher/runtime/dialog/images/icons/list.png new file mode 100644 index 0000000000000000000000000000000000000000..be11c6fb27d568dc10a9668e9d202331a2b3a6ed GIT binary patch literal 2417 zcmcIlZB!K386Kc0P(`91-4re3$SD}IJ2U&e6E}#v6c)3%;8qZm$n4DBWo36}+!>aS zW6MWd4OXSWC>lf5LhA>WT91Y*RUj&))kuOS7}FCrvDVN;i2+-xmG&+l+nk=n`lox& z+_`t=xzByx_j%{tT3dF;%$V=QAP6$kl4;I`_oeVsMNNa_#UsTB5hP6KHkoW`Ebjnl zZpLynnKT&mOAsXa<(+jMS?6qXH+RIRUpTNj>XU$wlw2LE@4&oR%yK}_(E}2 zL4EAiHAD7`N5GoCJKsx7ted`P`(@Rsgw3^CbKZM5XZ~A55rt%eN4N0Q>XW}dbFXsD z_(cCO;Pz!iEqmHHe@$B10Y&8xWY6sQ%+Vt}89PK**x7cS&=&UXw)8g&e){FSrLmPr zXZOm7!>dx?f|-mKGS`R*5_>*)h3!mswh<{c%KW0#bUq-C9YJ; zAwn*ea}r%9=fuTR3}zrQKDQvbc@7OS(hj~vGGb8aL*X4iS|c}TRCI7KXjzAfB-He{F1X*!GbO>~1@})BEz2{I zBa|OX=U`PThfXI~5`+p4YQ5Z{a}si`lF&M|4ucjrHB)RWeQx;O(4Mcd234_;kx(mD zDz#QE*J&AzoYbosIjz@f)@W-?L|0aAgrA!gcxd3dLI2H^A4>p$x zL-7ChYW&?-8qpLScDLX()K=jl)R+MWseQ2RwvNQ-AxQXai#g3+RDFB5b%i}g)>GNE zNR}MEKE0+Ukn-f!q^RqWM+;8ODY!OWxN&?nx4!9_yjF9~JnjL4Mf71YU0Z5jlpUJ) z#PV0}mu{%LblbnDL5vl9Zv3MQyl&_{(_20!?i*GfOspL?=e-+!VsElu`bFTK+8R?* zOl;%C;#6Q!_e%%$ZwpZy{n55BzxeyH@U5q(x$EmXcdw|*@0<7e&wqc@Z!4J@Xlm}A zd#km%X?%ZA&+(DCPx+6>+Bz>%V_}6KU0YXuYghTr#ecYW#CNF?aS}a{83`c7R4aBKk3Tf=E|lyt2YF!-Klr3HVs+2J~_SP)#ev1Pl127 z<&KrsS6sf|d`|}&sy~-~7`c6$JW#j7)rgKJgWj8?u0uD=GnFkLt`ZC@_ny?gUEi#@ zkx+kP$K4KL@Jdg1@toiF1zvyZ3-sW_=_fU#uYkg8cGubH=P!*`uKjcVxpQle93pp8 zy?7Q?KXUr=a7W^q1_>Q}b;a36VpCpqOJ_;o*<%fNc|@1Ft0}r($8W3KmZ9o7adg3N zK8ko_>%)bz!Ox1?vATbCEs{2RHefb;+W literal 0 HcmV?d00001 diff --git a/Launcher/runtime/dialog/images/icons/settings.png b/Launcher/runtime/dialog/images/icons/settings.png new file mode 100644 index 0000000000000000000000000000000000000000..2811cd09f10e2bc3f489bb612c2aaa2b8345be19 GIT binary patch literal 2586 zcmcImdsGv577j0YDN=DkMI}U0Kqv19lM)_=S6IR`Rvtc>%uGmxWMXC@frSFr6;Tuk zMMUXZ#nweA+qEs&Vg(hU2P_H{DOH4mr*79pq*PIx3rMJ-P|O4>u{b&q!Q?14Hgpr!lLdl4 zUKEOFNm+4I_?76T1x>EOS5LlWGd!eS9}}I{d#Om0w4WMZBQ|~{5tqrAXzFsGIUdri z+Il<3e0}Jpz;WAbi>uY|i1#eCIxzV2dxPN0PO~a`-+Oyw_D;mtWb~BO-RtOgQ5-eT zi#+;4Mol`!as95AWrJfjd41Bx2i(@FT(;YX;TCI>8(mTNeRemRx~mtkEU&$PVyENc zyz0pBc#cs4)#X#J(RR9*l<@XP*^WE%`f-t45!k#?x5F%A)wa~UM5D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scenes/console/console.fxml index 71843dd6..5e87be6a 100644 --- a/Launcher/runtime/dialog/scenes/console/console.fxml +++ b/Launcher/runtime/dialog/scenes/console/console.fxml @@ -1,54 +1,57 @@ + + - - - + + - + - - + + - + - + - + - - - + + + diff --git a/Launcher/runtime/dialog/scenes/mainmenu/mainmenu.fxml b/Launcher/runtime/dialog/scenes/mainmenu/mainmenu.fxml index c5dd660f..1f19607e 100644 --- a/Launcher/runtime/dialog/scenes/mainmenu/mainmenu.fxml +++ b/Launcher/runtime/dialog/scenes/mainmenu/mainmenu.fxml @@ -1,19 +1,19 @@ - - - + + + - + @@ -22,7 +22,7 @@ - @@ -51,10 +51,14 @@ - + - - - - - + + + + + diff --git a/Launcher/runtime/dialog/scenes/options/options.fxml b/Launcher/runtime/dialog/scenes/options/options.fxml index 4884c670..aa3b28a3 100644 --- a/Launcher/runtime/dialog/scenes/options/options.fxml +++ b/Launcher/runtime/dialog/scenes/options/options.fxml @@ -1,10 +1,11 @@ - - + + + @@ -13,7 +14,7 @@ - + @@ -38,21 +39,30 @@ - - - + + + From 37dbcf73f7f7ea89f07a36f835f809d6202da65a Mon Sep 17 00:00:00 2001 From: LoomeL Date: Thu, 15 Aug 2019 22:10:52 +0600 Subject: [PATCH 3/3] =?UTF-8?q?[FEATURE]=20=D0=98=D0=B7=D0=BC=D0=B5=D0=BD?= =?UTF-8?q?=D0=B5=D0=BD=D0=B8=D0=B5=20=D0=BE=D0=B2=D0=B5=D1=80=D0=BB=D0=B5?= =?UTF-8?q?=D1=8F=20=D0=BD=D0=B0=D1=81=D1=82=D1=80=D0=BE=D0=B5=D0=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../dialog/overlay/settings/settings.fxml | 41 ++++++++++++++----- .../dialog/overlay/settings/settings.js | 26 ++++++++++++ 2 files changed, 56 insertions(+), 11 deletions(-) diff --git a/Launcher/runtime/dialog/overlay/settings/settings.fxml b/Launcher/runtime/dialog/overlay/settings/settings.fxml index 6d8f24db..b58950e2 100644 --- a/Launcher/runtime/dialog/overlay/settings/settings.fxml +++ b/Launcher/runtime/dialog/overlay/settings/settings.fxml @@ -1,10 +1,11 @@ + - - + + @@ -13,16 +14,22 @@ - + - - - - - - + + + + + + + + + + + + @@ -44,8 +51,20 @@ - - + + + + + + + + + + diff --git a/Launcher/runtime/dialog/overlay/settings/settings.js b/Launcher/runtime/dialog/overlay/settings/settings.js index 9a4dfe50..514b5739 100644 --- a/Launcher/runtime/dialog/overlay/settings/settings.js +++ b/Launcher/runtime/dialog/overlay/settings/settings.js @@ -6,6 +6,8 @@ var settingsOverlay = { transferDialog: null, deleteDirPressedAgain: false, count: 0, + descLabel: null, + description: null, initOverlay: function() { settingsOverlay.overlay = loadFXML("dialog/overlay/settings/settings.fxml"); @@ -16,6 +18,9 @@ var settingsOverlay = { autoEnterBox.setSelected(settings.autoEnter); autoEnterBox.selectedProperty()["addListener(javafx.beans.value.ChangeListener)"]( function(o, ov, nv) settings.autoEnter = nv); + autoEnterBox.setOnMouseEntered(function() { + settingsOverlay.updateDesc(autoEnterBox.getText(), "Включение авто-входа означает что вы сразу после загрузки клиента попадете на сервер"); + }); settingsOverlay.dirLabel = holder.lookup("#dirLabel"); settingsOverlay.dirLabel.setOnAction(function(event) app.getHostServices().showDocument(settings.updatesDir.toUri())); @@ -36,15 +41,24 @@ var settingsOverlay = { } }); + this.descLabel = holder.lookup("#descLabel"); + this.description = holder.lookup("#description"); + var featureStore = holder.lookup("#featureStore"); featureStore.setSelected(settings.featureStore); featureStore.selectedProperty()["addListener(javafx.beans.value.ChangeListener)"]( function(o, ov, nv) settings.featureStore = nv); + featureStore.setOnMouseEntered(function() { + settingsOverlay.updateDesc(featureStore.getText(), "Используется для экономии вашего трафика, аналогичные файлы будут скопированы с других игровых клиентов"); + }); var fullScreenBox = holder.lookup("#fullScreen"); fullScreenBox.setSelected(settings.fullScreen); fullScreenBox.selectedProperty()["addListener(javafx.beans.value.ChangeListener)"]( function(o, ov, nv) settings.fullScreen = nv); + fullScreenBox.setOnMouseEntered(function() { + settingsOverlay.updateDesc(fullScreenBox.getText(), "Включение данной функции позволяет запустить игру сразу в полноэкранном режиме"); + }); settingsOverlay.ramLabel = holder.lookup("#ramLabel"); settingsOverlay.updateRAMLabel(); @@ -90,10 +104,22 @@ var settingsOverlay = { debugBox.setSelected(settings.debug); debugBox.selectedProperty()["addListener(javafx.beans.value.ChangeListener)"]( function(o, ov, nv) settings.debug = nv); + debugBox.setOnMouseEntered(function() { + settingsOverlay.updateDesc(debugBox.getText(), "Режим отладки позволяет просмотреть лог запуска и работы программы в реальном времени прямо из лаунчера, что упрощает поиск нужной информации"); + }); holder.lookup("#apply").setOnAction(function(event) overlay.hide(0, null)); }, + updateDesc: function(label, desc) { + //На случай если человек решил избавится от этой фишки + if (this.descLabel == null) return; + if (this.description == null) return; + + this.descLabel.setText(label); + this.description.setText(desc); + }, + transferCatalogDialog: function(newDir) { settingsOverlay.transferDialog.setVisible(true); settingsOverlay.transferDialog.lookup("#cancelTransfer").setOnAction(function(event) {