mirror of
https://github.com/GravitLauncher/Launcher
synced 2024-11-15 11:39:11 +03:00
Merge pull request #260 from Yshmeel/dev
Добавил блюр на задний фон, сделал выбор по умолчанию в ComboBox типа авторизации
This commit is contained in:
commit
77c8607d20
4 changed files with 146 additions and 128 deletions
|
@ -1,4 +1,4 @@
|
|||
var authPane, dimPane, serverPane, bar, consoleBar, optionsPane, consolePane;
|
||||
var authPane, dimPane, serverPane, bar, consoleBar, optionsPane, consolePane, loginPaneLayout, serverPaneLayout;
|
||||
var loginField, passwordField, savePasswordBox, authOptions;
|
||||
var serverList, serverInfo, serverDescription, serverEntrance, serverLabel, serverStatus;
|
||||
var profilesList = [];
|
||||
|
@ -43,6 +43,9 @@ function initLoginScene() {
|
|||
var pane = loginPane.lookup("#authPane");
|
||||
authPane = pane;
|
||||
|
||||
var loginLayout = loginPane.lookup("#layout");
|
||||
loginPaneLayout = loginLayout;
|
||||
|
||||
loginField = pane.lookup("#login");
|
||||
loginField.setOnMouseMoved(function(event){rootPane.fireEvent(event)});
|
||||
loginField.setOnAction(goAuth);
|
||||
|
@ -93,6 +96,9 @@ function initMenuScene() {
|
|||
var pane = menuPane.lookup("#serverPane");
|
||||
serverPane = pane;
|
||||
|
||||
var menuLayout = menuPane.lookup("#layout");
|
||||
serverPaneLayout = menuLayout;
|
||||
|
||||
pane.lookup("#clientSettings").setOnAction(goOptions);
|
||||
serverList = pane.lookup("#serverlist").getContent();
|
||||
serverInfo = pane.lookup("#serverinfo").getContent();
|
||||
|
@ -258,6 +264,7 @@ function verifyLauncher(e) {
|
|||
authTypes[auth_type.displayName] = auth_type.name;
|
||||
iter++;
|
||||
});
|
||||
authOptions.getSelectionModel().select(0);
|
||||
var sm = authOptions.getSelectionModel().selectedIndexProperty();
|
||||
// add listener to authOptions select
|
||||
sm.addListener(new javafx.beans.value.ChangeListener({
|
||||
|
@ -416,7 +423,8 @@ var overlay = {
|
|||
|
||||
dimPane.setVisible(true);
|
||||
dimPane.toFront();
|
||||
|
||||
loginPaneLayout.setEffect(new javafx.scene.effect.GaussianBlur(55));
|
||||
serverPaneLayout.setEffect(new javafx.scene.effect.GaussianBlur(55));
|
||||
fade(dimPane, 0.0, 0.0, 1.0, function(event) {
|
||||
dimPane.requestFocus();
|
||||
dimPane.getChildren().add(newOverlay);
|
||||
|
@ -436,7 +444,8 @@ var overlay = {
|
|||
|
||||
authPane.setDisable(false);
|
||||
rootPane.requestFocus();
|
||||
|
||||
loginPaneLayout.setEffect(new javafx.scene.effect.GaussianBlur(0));
|
||||
serverPaneLayout.setEffect(new javafx.scene.effect.GaussianBlur(0));
|
||||
overlay.current = null;
|
||||
if (onFinished !== null) {
|
||||
onFinished();
|
||||
|
|
|
@ -14,7 +14,9 @@
|
|||
|
||||
<!-- DrLeonardo Design -->
|
||||
|
||||
<Pane fx:id="layout" prefWidth="740.0" xmlns="http://javafx.com/javafx/8.0.201" xmlns:fx="http://javafx.com/fxml/1">
|
||||
<Pane fx:id="loginPane" prefWidth="740.0" xmlns="http://javafx.com/javafx/8.0.201" xmlns:fx="http://javafx.com/fxml/1">
|
||||
<children>
|
||||
<Pane fx:id="layout" prefWidth="740.0">
|
||||
<children>
|
||||
<Pane fx:id="authPane" layoutX="422.0" prefHeight="411.0" prefWidth="286.0" styleClass="loginPane">
|
||||
<children>
|
||||
|
@ -33,7 +35,10 @@
|
|||
</children>
|
||||
</Pane>
|
||||
<JFXMasonryPane fx:id="news" prefHeight="432.0" prefWidth="423.0" styleClass="news" />
|
||||
<Pane fx:id="bar" layoutX="692.0" prefHeight="425.0" prefWidth="43.0" styleClass="bar">
|
||||
</children>
|
||||
</Pane>
|
||||
<Pane id="mask" opacity="0.0" prefHeight="425.0" prefWidth="694.0" visible="false" />
|
||||
<Pane fx:id="bar" layoutX="696.0" prefHeight="425.0" prefWidth="43.0" styleClass="bar">
|
||||
<children>
|
||||
<JFXButton id="hide" alignment="CENTER" contentDisplay="CENTER" layoutY="45.0" ripplerFill="#646464" text="" textAlignment="CENTER">
|
||||
<graphic>
|
||||
|
@ -52,7 +57,6 @@
|
|||
</JFXButton>
|
||||
</children>
|
||||
</Pane>
|
||||
<Pane id="mask" opacity="0.0" prefHeight="425.0" prefWidth="694.0" visible="false" />
|
||||
</children>
|
||||
<stylesheets>
|
||||
<URL value="@../../styles.css" />
|
||||
|
|
|
@ -13,7 +13,9 @@
|
|||
|
||||
<!-- DrLeonardo Design -->
|
||||
|
||||
<Pane fx:id="layout" maxHeight="-1.0" maxWidth="-1.0" prefHeight="400.0" prefWidth="600.0" visible="true" xmlns="http://javafx.com/javafx/8.0.201" xmlns:fx="http://javafx.com/fxml/1">
|
||||
<Pane fx:id="serverPaneLayout" maxHeight="-1.0" maxWidth="-1.0" prefWidth="740.0" visible="true" xmlns="http://javafx.com/javafx/8.0.201" xmlns:fx="http://javafx.com/fxml/1">
|
||||
<children>
|
||||
<Pane fx:id="layout" maxHeight="-1.0" maxWidth="-1.0" prefWidth="740.0" visible="true" xmlns="http://javafx.com/javafx/8.0.201" xmlns:fx="http://javafx.com/fxml/1">
|
||||
<children>
|
||||
<Pane id="serverPane" prefHeight="450.0" prefWidth="693.0">
|
||||
<children>
|
||||
|
@ -68,7 +70,9 @@
|
|||
</Pane>
|
||||
</children>
|
||||
</Pane>
|
||||
<Pane fx:id="bar" layoutX="692.0" prefHeight="425.0" prefWidth="43.0" styleClass="bar">
|
||||
</children>
|
||||
</Pane>
|
||||
<Pane fx:id="bar" layoutX="696.0" prefHeight="425.0" prefWidth="43.0" styleClass="bar">
|
||||
<children>
|
||||
<JFXButton id="hide" alignment="CENTER" contentDisplay="CENTER" layoutY="45.0" ripplerFill="#646464" text="" textAlignment="CENTER">
|
||||
<graphic>
|
||||
|
|
|
@ -3,6 +3,7 @@ Button, CheckBox, ComboBox, RadioButton {
|
|||
-fx-cursor: hand;
|
||||
}
|
||||
|
||||
|
||||
/* Backgrounds */
|
||||
#layout {
|
||||
-fx-background-color: transparent;
|
||||
|
@ -32,7 +33,7 @@ #serverStatus{
|
|||
|
||||
/* Mask */
|
||||
#mask {
|
||||
-fx-background-color: rgba(0, 0, 0, 0.5);
|
||||
-fx-effect: DropShadow( gaussian , rgba(255,255,255,0.5) , 0,0,0,1 );
|
||||
-fx-pref-width: 692px;
|
||||
-fx-pref-height: 450px;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue