Skip to content

Commit

Permalink
Update new icon
Browse files Browse the repository at this point in the history
  • Loading branch information
bifrurcated committed Jul 8, 2022
1 parent dd58a1b commit 683468b
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 2 deletions.
Binary file modified helpcreator.ico
Binary file not shown.
Binary file added helpcreator.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,7 @@
<version>1.4.0</version>
<configuration>
<name>HelpCreator</name>
<appVersion>1.0.1</appVersion>
<appVersion>1.0.2</appVersion>
<vendor>ru.vvsu</vendor>
<module>helpcreator/${mainClass}</module>
<runtimeImage>target/helpcreator</runtimeImage>
Expand All @@ -170,7 +170,7 @@
<macPackageName>HelpCreator</macPackageName>
<macPackageSigningPrefix>fx</macPackageSigningPrefix>
<macSign>true</macSign>
<icon>${project.basedir}/helpcreator.ico</icon>
<icon>helpcreator.ico</icon>
<javaOptions>
<option>-Dfile.encoding=UTF-8</option>
</javaOptions>
Expand Down
9 changes: 9 additions & 0 deletions src/main/java/ru/vvsu/helpcreator/utils/ViewWindow.java
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
import javafx.scene.Node;
import javafx.scene.Parent;
import javafx.scene.Scene;
import javafx.scene.image.Image;
import javafx.stage.Modality;
import javafx.stage.Stage;
import org.kordamp.bootstrapfx.BootstrapFX;
Expand All @@ -17,14 +18,18 @@

import java.io.IOException;
import java.util.List;
import java.util.Objects;

public final class ViewWindow {

private static final Image DEFAULT_ICON = new Image(Objects.requireNonNull(Main.class.getResourceAsStream("images/logo32.png")), 16D, 16D, true, false);

public static void openProjectCreate(Stage stage) throws IOException {
FXMLLoader fxmlLoader = new FXMLLoader(Main.class.getResource("view/project-create.fxml"));
final Parent parent = fxmlLoader.load();
Scene scene = new Scene(parent, 800, 600);
scene.getStylesheets().add(BootstrapFX.bootstrapFXStylesheet());
stage.getIcons().add(DEFAULT_ICON);
stage.setTitle("Help Creator");
stage.setScene(scene);
stage.show();
Expand All @@ -37,6 +42,7 @@ public static void openMainWindow(Project project) throws IOException {
final MainWindow mainWindow = fxmlLoader.getController();
mainWindow.setRootTreeView(project);
Scene scene = new Scene(parent, 800, 600);
stage.getIcons().add(DEFAULT_ICON);
stage.setTitle("Help Creator");
stage.setScene(scene);
stage.show();
Expand All @@ -48,6 +54,7 @@ public static void openNewProject(Stage projectStage) throws IOException {
final Parent parent = fxmlLoader.load();
Scene scene = new Scene(parent, 600, 275);
scene.getStylesheets().add(BootstrapFX.bootstrapFXStylesheet());
newProject.getIcons().add(DEFAULT_ICON);
newProject.setTitle("Новый проект");
newProject.setScene(scene);
newProject.initModality(Modality.WINDOW_MODAL);
Expand All @@ -64,6 +71,7 @@ public static void openSettingsProject(Stage projectStage, Project project, Main
settingsProject.setMainWindow(mainWindow);
Scene scene = new Scene(parent);
scene.getStylesheets().add(BootstrapFX.bootstrapFXStylesheet());
settingsStage.getIcons().add(DEFAULT_ICON);
settingsStage.setMaxWidth(618);
settingsStage.setMaxHeight(578);
settingsStage.setTitle("Настройки проекта");
Expand All @@ -83,6 +91,7 @@ public static void openHtmlGenerate(Stage projectStage, Project project, List<Pa
htmlGenerate.setMainWindow(mainWindow);
Scene scene = new Scene(parent);
scene.getStylesheets().add(BootstrapFX.bootstrapFXStylesheet());
htmlGenerateStage.getIcons().add(DEFAULT_ICON);
htmlGenerateStage.setTitle("HTML-генератор");
htmlGenerateStage.setScene(scene);
htmlGenerateStage.initModality(Modality.WINDOW_MODAL);
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 683468b

Please sign in to comment.