minor ui state tweaks

[ci skip]
This commit is contained in:
Sebastian Stenzel
2020-02-13 14:32:23 +01:00
parent 7755256956
commit 62676d5a83
2 changed files with 3 additions and 1 deletions

View File

@@ -5,6 +5,7 @@
*******************************************************************************/
package org.cryptomator.launcher;
import javafx.application.Platform;
import org.apache.commons.lang3.SystemUtils;
import org.cryptomator.logging.DebugMode;
import org.cryptomator.logging.LoggerConfiguration;
@@ -90,6 +91,7 @@ public class Cryptomator {
try {
uiLauncher.launch();
shutdownLatch.await();
Platform.exit();
LOG.info("UI shut down");
return 0;
} catch (InterruptedException e) {

View File

@@ -48,7 +48,7 @@ public class UiLauncher {
}
// show window on start?
if (settings.startHidden().get()) {
if (hasTrayIcon && settings.startHidden().get()) {
LOG.debug("Hiding application...");
macFunctions.map(MacFunctions::uiState).ifPresent(JniException.ignore(MacApplicationUiState::transformToAgentApplication));
} else {