mirror of
https://github.com/cryptomator/cryptomator.git
synced 2024-10-07 01:03:31 +00:00
clean up
This commit is contained in:
parent
4305fd3285
commit
2a01aba3cf
@ -102,9 +102,9 @@ public class HubToLocalConvertController implements FxController {
|
||||
Preconditions.checkState(newPasswordController.isGoodPassword());
|
||||
LOG.info("Converting hub vault {} to local", vault.getPath());
|
||||
CompletableFuture.runAsync(() -> conversionStarted.setValue(true), Platform::runLater) //
|
||||
.thenRunAsync(this::convertInternal, backgroundExecutorService) //TODO: which executor is used?
|
||||
.thenRunAsync(this::convertInternal, backgroundExecutorService)
|
||||
.whenCompleteAsync((result, exception) -> {
|
||||
if (exception == null) { //TODO: check, how the exceptions are wrapped
|
||||
if (exception == null) {
|
||||
LOG.info("Conversion of vault {} succeeded.", vault.getPath());
|
||||
window.setScene(successScene.get());
|
||||
} else {
|
||||
|
@ -10,24 +10,15 @@ import javafx.stage.Stage;
|
||||
|
||||
public class HubToLocalSuccessController implements FxController {
|
||||
|
||||
private final FxApplicationWindows appWindows;
|
||||
private final Stage window;
|
||||
private final Vault vault;
|
||||
|
||||
@Inject
|
||||
HubToLocalSuccessController(FxApplicationWindows appWindows, @ConvertVaultWindow Stage window, @ConvertVaultWindow Vault vault) {
|
||||
this.appWindows = appWindows;
|
||||
HubToLocalSuccessController(@ConvertVaultWindow Stage window, @ConvertVaultWindow Vault vault) {
|
||||
this.window = window;
|
||||
this.vault = vault;
|
||||
}
|
||||
|
||||
@FXML
|
||||
public void unlockAndClose() {
|
||||
close();
|
||||
vault.getVaultConfigCache();
|
||||
appWindows.startUnlockWorkflow(vault, window);
|
||||
}
|
||||
|
||||
@FXML
|
||||
public void close() {
|
||||
window.close();
|
||||
|
Loading…
Reference in New Issue
Block a user