Updated dependencies (fixing broken directory listing). Loading correct default settings now

This commit is contained in:
Sebastian Stenzel
2017-04-26 14:30:49 +02:00
parent 0debbb83b1
commit 51cb41975b
4 changed files with 15 additions and 5 deletions

View File

@@ -10,6 +10,8 @@ package org.cryptomator.common.settings;
import java.util.function.Consumer;
import org.apache.commons.lang3.SystemUtils;
import javafx.beans.property.BooleanProperty;
import javafx.beans.property.IntegerProperty;
import javafx.beans.property.SimpleBooleanProperty;
@@ -27,7 +29,7 @@ public class Settings {
public static final int MAX_PORT = 65535;
public static final boolean DEFAULT_CHECK_FOR_UDPATES = true;
public static final int DEFAULT_PORT = 42427;
public static final boolean DEFAULT_USE_IPV6 = false;
public static final boolean DEFAULT_USE_IPV6 = SystemUtils.IS_OS_WINDOWS;
public static final int DEFAULT_NUM_TRAY_NOTIFICATIONS = 3;
public static final String DEFAULT_GVFS_SCHEME = "dav";
public static final boolean DEFAULT_DEBUG_MODE = false;

View File

@@ -69,7 +69,10 @@ public class SettingsJsonAdapter extends TypeAdapter<Settings> {
settings.port().set(in.nextInt());
break;
case "useIpv6":
settings.useIpv6().set(in.nextBoolean());
// Temporarily we will disable loading this setting, as we want the default value on each app start.
// This setting might be removed completely in the future
// settings.useIpv6().set(in.nextBoolean());
in.skipValue();
break;
case "numTrayNotifications":
settings.numTrayNotifications().set(in.nextInt());

View File

@@ -25,13 +25,16 @@ import javafx.beans.value.ObservableValue;
public class VaultSettings {
public static final boolean DEFAULT_MOUNT_AFTER_UNLOCK = true;
public static final boolean DEFAULT_REAVEAL_AFTER_MOUNT = true;
private final Settings settings;
private final String id;
private final ObjectProperty<Path> path = new SimpleObjectProperty<>();
private final StringProperty mountName = new SimpleStringProperty();
private final StringProperty winDriveLetter = new SimpleStringProperty();
private final BooleanProperty mountAfterUnlock = new SimpleBooleanProperty();
private final BooleanProperty revealAfterMount = new SimpleBooleanProperty();
private final BooleanProperty mountAfterUnlock = new SimpleBooleanProperty(DEFAULT_MOUNT_AFTER_UNLOCK);
private final BooleanProperty revealAfterMount = new SimpleBooleanProperty(DEFAULT_REAVEAL_AFTER_MOUNT);
public VaultSettings(Settings settings, String id) {
this.settings = settings;
@@ -42,6 +45,7 @@ public class VaultSettings {
mountName.addListener(this::somethingChanged);
winDriveLetter.addListener(this::somethingChanged);
mountAfterUnlock.addListener(this::somethingChanged);
revealAfterMount.addListener(this::somethingChanged);
}
private void somethingChanged(ObservableValue<?> observable, Object oldValue, Object newValue) {

View File

@@ -28,7 +28,7 @@
<!-- dependency versions -->
<cryptomator.cryptolib.version>1.1.1</cryptomator.cryptolib.version>
<cryptomator.cryptofs.version>1.2.1</cryptomator.cryptofs.version>
<cryptomator.cryptofs.version>1.2.2</cryptomator.cryptofs.version>
<cryptomator.webdav.version>0.5.0</cryptomator.webdav.version>
<cryptomator.jni.version>1.0.0</cryptomator.jni.version>
<log4j.version>2.8.1</log4j.version> <!-- keep in sync with https://github.com/edwgiz/maven-shaded-log4j-transformer (used in uber-jar), or wait for https://issues.apache.org/jira/browse/LOG4J2-954 fix -->
@@ -239,6 +239,7 @@
<dependency>
<groupId>org.hamcrest</groupId>
<artifactId>hamcrest-all</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.mockito</groupId>