diff --git a/main/commons/src/main/java/org/cryptomator/common/Environment.java b/main/commons/src/main/java/org/cryptomator/common/Environment.java index 890840b7d..d920b1b9f 100644 --- a/main/commons/src/main/java/org/cryptomator/common/Environment.java +++ b/main/commons/src/main/java/org/cryptomator/common/Environment.java @@ -40,6 +40,7 @@ public class Environment { LOG.debug("cryptomator.mountPointsDir: {}", System.getProperty("cryptomator.mountPointsDir")); LOG.debug("cryptomator.minPwLength: {}", System.getProperty("cryptomator.minPwLength")); LOG.debug("cryptomator.buildNumber: {}", System.getProperty("cryptomator.buildNumber")); + LOG.debug("fuse.experimental: {}", Boolean.getBoolean("fuse.experimental")); } public boolean useCustomLogbackConfig() { @@ -74,6 +75,10 @@ public class Environment { return getInt("cryptomator.minPwLength", DEFAULT_MIN_PW_LENGTH); } + public boolean useExperimentalFuse() { + return Boolean.getBoolean("fuse.experimental"); + } + private int getInt(String propertyName, int defaultValue) { String value = System.getProperty(propertyName); try { diff --git a/main/ui/src/main/java/org/cryptomator/ui/vaultoptions/MountOptionsController.java b/main/ui/src/main/java/org/cryptomator/ui/vaultoptions/MountOptionsController.java index e9bb4f043..975f40bf3 100644 --- a/main/ui/src/main/java/org/cryptomator/ui/vaultoptions/MountOptionsController.java +++ b/main/ui/src/main/java/org/cryptomator/ui/vaultoptions/MountOptionsController.java @@ -18,6 +18,7 @@ import javafx.stage.DirectoryChooser; import javafx.stage.Stage; import javafx.util.StringConverter; import org.apache.commons.lang3.SystemUtils; +import org.cryptomator.common.Environment; import org.cryptomator.common.settings.Settings; import org.cryptomator.common.settings.VolumeImpl; import org.cryptomator.common.vaults.Vault; @@ -57,15 +58,14 @@ public class MountOptionsController implements FxController { private final BooleanBinding fuseAndWindows; @Inject - MountOptionsController(@VaultOptionsWindow Stage window, @VaultOptionsWindow Vault vault, Settings settings, WindowsDriveLetters windowsDriveLetters, ResourceBundle resourceBundle) { + MountOptionsController(@VaultOptionsWindow Stage window, @VaultOptionsWindow Vault vault, Settings settings, WindowsDriveLetters windowsDriveLetters, ResourceBundle resourceBundle, Environment environment) { this.window = window; this.vault = vault; this.webDavAndWindows = settings.preferredVolumeImpl().isEqualTo(VolumeImpl.WEBDAV).and(osIsWindows); this.windowsDriveLetters = windowsDriveLetters; this.resourceBundle = resourceBundle; - System.out.println(Boolean.getBoolean("fuse.experimental")); - this.fuseAndWindows = settings.preferredVolumeImpl().isEqualTo(VolumeImpl.FUSE).and(osIsWindows).and(new SimpleBooleanProperty(!Boolean.getBoolean("fuse.experimental"))); + this.fuseAndWindows = settings.preferredVolumeImpl().isEqualTo(VolumeImpl.FUSE).and(osIsWindows).and(new SimpleBooleanProperty(!environment.useExperimentalFuse())); } @FXML