Skip to content

Commit 240aed2

Browse files
author
Bytekeeper
committed
More logo sizes, to make setting the task bar icon work.
1 parent f106dcc commit 240aed2

File tree

3 files changed

+5
-1
lines changed

3 files changed

+5
-1
lines changed

src/main/java/org/stt/gui/UIMain.java

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@
2121
import java.util.concurrent.ExecutorService;
2222
import java.util.logging.Level;
2323
import java.util.logging.Logger;
24+
import java.util.stream.Stream;
2425

2526
public class UIMain extends Application {
2627
/**
@@ -92,7 +93,10 @@ private void startService(Service serviceInstance) throws Exception {
9293

9394
@Override
9495
public void start(Stage primaryStage) throws Exception {
95-
primaryStage.getIcons().add(new Image(getClass().getResourceAsStream("/Logo.png")));
96+
Stream.of("/Logo32.png", "/Logo64.png", "/Logo.png")
97+
.map(getClass()::getResourceAsStream)
98+
.map(Image::new)
99+
.forEach(primaryStage.getIcons()::add);
96100
Thread.currentThread().setUncaughtExceptionHandler((t, e) -> {
97101
LOG.log(Level.SEVERE, "Uncaught exception", e);
98102
eventBus.publish(e);

src/main/resources/Logo32.png

1.14 KB
Loading

src/main/resources/Logo64.png

2.47 KB
Loading

0 commit comments

Comments
 (0)