Module Client : renommage fichier css ("dark-theme.css" -> "nightmode.css"); Correction bugs divers; Clear de code

This commit is contained in:
Notmoo 2017-08-20 16:16:34 +02:00
parent 827451d665
commit 367e639150
6 changed files with 18 additions and 96 deletions

View File

@ -5,6 +5,7 @@ import com.pqt.client.gui.ressources.strings.GUIStringTool;
import com.pqt.core.entities.user_account.Account;
import com.pqt.core.entities.user_account.AccountLevel;
import javafx.application.Platform;
import javafx.geometry.Pos;
import javafx.scene.control.*;
import javafx.scene.input.MouseButton;
import javafx.scene.layout.*;
@ -14,7 +15,7 @@ import java.util.Collection;
class AccountManagerScreenView implements IFXComponent{
private Pane mainPane;
private StackPane mainPane;
private AccountManagerScreenController ctrl;
private ChoiceBox<AccountLevel> levelChoiceBox;
@ -27,11 +28,13 @@ class AccountManagerScreenView implements IFXComponent{
}
private void initGui() {
mainPane = new Pane();
mainPane = new StackPane();
BorderPane mainPaneContent = new BorderPane();
GridPane mainPaneCenterContent = new GridPane();
mainPaneCenterContent.setAlignment(Pos.CENTER);
Label nameLabel = new Label(GUIStringTool.getUsernameLabel());
nameTextField = new TextField();
nameTextField.textProperty().addListener((obs, oldVal, newVal)->ctrl.onNameChanged(oldVal, newVal));

View File

@ -107,7 +107,6 @@ class ProductManagerScreenView implements IFXComponent {
mainPaneContent.setCenter(mainPaneCenterContent);
VBox mainPaneRightContent = new VBox();
mainPaneRightContent.getStyleClass().add(GUICssTool.getContainerStyleClass());
mainPaneRightContent.setAlignment(Pos.CENTER);
Label title = new Label(GUIStringTool.getComponentListTitleLabel());
title.setAlignment(Pos.CENTER);

View File

@ -67,7 +67,6 @@ public class CategoryTabStockDisplayer implements IFXDisplayerComponent<Collecti
private void init(){
mainPane = new BorderPane();
mainPane.getStyleClass().add("stock-displayer");
Label title = new Label(GUIStringTool.getCategorytabStockDisplayerTitle());
title.setAlignment(Pos.CENTER);

View File

@ -30,7 +30,6 @@ public class CommandComposerSaleDisplayer implements IFXSaleDisplayerComponent {
private void init() {
mainPane = new BorderPane();
mainPane.getStyleClass().add("sale-displayer");
Label title = new Label(GUIStringTool.getCommandComposerTitleLabel());
title.setAlignment(Pos.CENTER);

View File

@ -2,7 +2,8 @@ package com.pqt.client.gui.ressources.css;
public class GUICssTool {
public static String getCssFilePath(){
return "/dark-theme.css";
//return "/daymode-blue.css";
return "/nightmode.css";
}
public static String getMainModulePaneCssClass() {
@ -16,8 +17,4 @@ public class GUICssTool {
public static String getTitleTextStyleClass() {
return "label-header";
}
public static String getContainerStyleClass() {
return "pqt-container";
}
}

View File

@ -37,28 +37,13 @@
.tab-pane *.tab-header-background {
-fx-background-color: #1d1d1d;
-fx-border-width: 1px;
-fx-border-radius: 1px;
-fx-border-color: gray;
}
.tab-pane {
-fx-border-width: 2px;
-fx-border-radius: 1px;
-fx-border-color: gray;
}
.list-view {
-fx-base: #1d1d1d;
-fx-control-inner-background: #1d1d1d;
-fx-control-inner-background-alt: #333333;
-fx-background-color: #1d1d1d;
-fx-table-cell-border-color: transparent;
-fx-table-header-border-color: transparent;
-fx-padding: 5;
-fx-border-width: 2px;
-fx-border-radius: 1px;
-fx-border-color: gray;
-fx-border-width: 0px;
}
.list-view .list-cell .label{
@ -66,7 +51,6 @@
-fx-font-family: "Segoe UI Light";
-fx-text-fill: white;
-fx-alignment: center-left;
-fx-opacity: 1;
}
.list-view:focused .list-cell:filled:focused:selected {
@ -81,7 +65,7 @@
.table-view {
-fx-base: #1d1d1d;
-fx-control-inner-background: #1d1d1d;
-fx-background-color: #1d1d1d;
-fx-control-inner-background-alt: #333333;
-fx-table-cell-border-color: transparent;
-fx-table-header-border-color: transparent;
-fx-padding: 5;
@ -135,75 +119,25 @@
-fx-background-color: -fx-focus-color;
}
.split-pane:horizontal > .split-pane-divider {
-fx-border-color: transparent #1d1d1d transparent #1d1d1d;
-fx-background-color: transparent, derive(#1d1d1d,20%);
}
.split-pane {
-fx-padding: 1 0 0 0;
}
.grid-pane {
-fx-hgap: 10;
-fx-vgap: 10;
}
.menu-bar {
-fx-background-color: derive(#1d1d1d,20%);
}
.context-menu {
-fx-background-color: derive(#1d1d1d,50%);
-fx-background-color: derive(#1d1d1d,5%);
}
.menu-bar .label {
-fx-font-size: 14pt;
-fx-font-family: "Segoe UI Light";
-fx-text-fill: white;
-fx-opacity: 0.9;
}
.menu .left-container {
-fx-background-color: black;
}
.text-field, .password-field, .choice-box, .text-area {
.text-field, .password-field, .choice-box, .text-area, .combo-box, .button {
-fx-font-size: 12pt;
-fx-font-family: "Segoe UI Semibold";
-fx-pref-width: 125;
-fx-pref-width: 150;
-fx-pref-height: 30;
-fx-background-radius: 0;
-fx-background-color: #1d1d1d;
-fx-background-insets: 0 0 0 0, 0, 1, 2;
-fx-border-color: #e2e2e2;
-fx-border-width: 2;
-fx-text-fill: #d8d8d8;
}
.text-area .content {
-fx-background-color: #1d1d1d;
-fx-padding: 15 15 15 15;
}
#stat-screen-text-area {
-fx-border-width: 0;
}
.button {
-fx-padding: 5 22 5 22;
-fx-border-color: #e2e2e2;
-fx-border-width: 2;
-fx-background-radius: 0;
-fx-background-color: #1d1d1d;
-fx-font-family: "Segoe UI", Helvetica, Arial, sans-serif;
-fx-font-size: 11pt;
-fx-text-fill: #d8d8d8;
-fx-background-insets: 0 0 0 0, 0, 1, 2;
-fx-pref-width: 125;
-fx-pref-height: 30;
}
.button:hover {
-fx-background-color: #3a3a3a;
}
@ -236,14 +170,13 @@
-fx-background-color: derive(-fx-focus-color,30%);
}
.menu-button-selected {
-fx-background-color: #d8d8d8;
-fx-text-fill: #1d1d1d;
.text-area .content {
-fx-background-color: #1d1d1d;
-fx-padding: 15 15 15 15;
}
.menu-button-selected:hover {
-fx-background-color: white;
-fx-text-fill: #1d1d1d;
#stat-screen-text-area {
-fx-border-width: 0;
}
.progress-indicator {
@ -258,8 +191,6 @@
.main-module-pane {
-fx-padding: 10 10 10 10;
-fx-border-width: 2px;
-fx-border-color: whitesmoke;
}
.validator {
@ -279,7 +210,7 @@
-fx-border-width: 2;
-fx-background-radius: 0;
-fx-background-insets: 0 0 0 0, 0, 1, 2;
-pqt-expanded-width : 175px;
-pqt-expanded-width : 195px;
}
.tool-bar {
@ -301,10 +232,4 @@
-fx-border-color: whitesmoke;
-fx-border-radius: 6px;
-fx-padding: 25px;
}
.pqt-container {
-fx-border-width: 2px;
-fx-border-color: whitesmoke;
-fx-padding: 5 5 5 5;
}