kopia lustrzana https://github.com/jameshball/osci-render
Add osci-render icon to program window
rodzic
fc1c79c597
commit
809a2a229f
4
pom.xml
4
pom.xml
|
@ -6,7 +6,7 @@
|
|||
|
||||
<groupId>sh.ball</groupId>
|
||||
<artifactId>osci-render</artifactId>
|
||||
<version>1.0.2</version>
|
||||
<version>1.0.3</version>
|
||||
|
||||
<name>osci-render</name>
|
||||
|
||||
|
@ -107,7 +107,7 @@
|
|||
<goal>jpackage</goal>
|
||||
</goals>
|
||||
<configuration>
|
||||
<icon>icon.ico</icon>
|
||||
<icon>src/main/resources/icons/icon.ico</icon>
|
||||
<winMenu>true</winMenu>
|
||||
<winMenuGroup>osci-render</winMenuGroup>
|
||||
</configuration>
|
||||
|
|
|
@ -4,7 +4,6 @@ import sh.ball.MovableRenderer;
|
|||
import sh.ball.audio.AudioPlayer;
|
||||
import sh.ball.audio.FrameProducer;
|
||||
|
||||
import java.awt.geom.RoundRectangle2D;
|
||||
import java.io.File;
|
||||
import java.io.IOException;
|
||||
import java.io.InputStream;
|
||||
|
@ -30,7 +29,6 @@ import javax.xml.parsers.ParserConfigurationException;
|
|||
|
||||
import org.xml.sax.SAXException;
|
||||
import sh.ball.engine.Vector3;
|
||||
import sh.ball.shapes.ShapeFrameSet;
|
||||
import sh.ball.parser.obj.ObjFrameSettings;
|
||||
import sh.ball.parser.obj.ObjParser;
|
||||
import sh.ball.parser.ParserFactory;
|
||||
|
|
|
@ -5,25 +5,29 @@ import javafx.application.Platform;
|
|||
import javafx.fxml.FXMLLoader;
|
||||
import javafx.scene.Parent;
|
||||
import javafx.scene.Scene;
|
||||
import javafx.scene.image.Image;
|
||||
import javafx.stage.Stage;
|
||||
|
||||
import java.util.Objects;
|
||||
|
||||
public class Gui extends Application {
|
||||
|
||||
@Override
|
||||
public void start(Stage primaryStage) throws Exception {
|
||||
public void start(Stage stage) throws Exception {
|
||||
FXMLLoader loader = new FXMLLoader(getClass().getResource("/fxml/osci-render.fxml"));
|
||||
Parent root = loader.load();
|
||||
Controller controller = loader.getController();
|
||||
controller.setStage(primaryStage);
|
||||
controller.setStage(stage);
|
||||
|
||||
primaryStage.setTitle("osci-render");
|
||||
primaryStage.setScene(new Scene(root));
|
||||
stage.getIcons().add(new Image(Objects.requireNonNull(getClass().getResourceAsStream("/icons/icon.png"))));
|
||||
stage.setTitle("osci-render");
|
||||
stage.setScene(new Scene(root));
|
||||
|
||||
controller.setStage(primaryStage);
|
||||
controller.setStage(stage);
|
||||
|
||||
primaryStage.show();
|
||||
stage.show();
|
||||
|
||||
primaryStage.setOnCloseRequest(t -> {
|
||||
stage.setOnCloseRequest(t -> {
|
||||
Platform.exit();
|
||||
System.exit(0);
|
||||
});
|
||||
|
|
Przed Szerokość: | Wysokość: | Rozmiar: 2.1 KiB Po Szerokość: | Wysokość: | Rozmiar: 2.1 KiB |
Plik binarny nie jest wyświetlany.
Po Szerokość: | Wysokość: | Rozmiar: 7.1 KiB |
Ładowanie…
Reference in New Issue