Handle case if content item is used in settings (wizard not set)

This commit is contained in:
Manfred Karrer 2014-11-27 00:36:49 +01:00
parent c4295bc55e
commit 3f5d82f8b0
6 changed files with 11 additions and 10 deletions

View File

@ -151,7 +151,8 @@ public class FiatAccountView extends ActivatableViewAndModel<GridPane, FiatAccou
@FXML
void onCompleted() {
wizard.nextStep(this);
if (wizard != null)
wizard.nextStep(this);
}
@FXML

View File

@ -152,7 +152,7 @@ public class IrcAccountView extends ActivatableViewAndModel<GridPane, IrcAccount
@FXML
void onSave() {
if (model.requestSaveBankAccount().isValid)
if (wizard != null && model.requestSaveBankAccount().isValid)
wizard.nextStep(this);
}

View File

@ -64,7 +64,7 @@ public class PasswordView extends InitializableView<GridPane, PasswordViewModel>
@FXML
private void onSaved() {
if (model.requestSavePassword())
if (wizard != null && model.requestSavePassword())
wizard.nextStep(this);
else
log.debug(model.getErrorMessage()); // TODO use validating passwordTF
@ -72,7 +72,8 @@ public class PasswordView extends InitializableView<GridPane, PasswordViewModel>
@FXML
private void onSkipped() {
wizard.nextStep(this);
if (wizard != null)
wizard.nextStep(this);
}
@FXML

View File

@ -109,11 +109,8 @@ public class RegistrationView extends InitializableView<GridPane, RegistrationVi
@Override
public void handle(ActionEvent actionEvent) {
getProperties().put("type", "CLOSE");
try {
if (wizard != null)
wizard.nextStep(RegistrationView.this);
} catch (Exception e) {
e.printStackTrace();
}
Dialog.Actions.CLOSE.handle(actionEvent);
overlayManager.removeBlurContent();
}

View File

@ -122,7 +122,7 @@ public class RestrictionsView extends ActivatableViewAndModel<GridPane, Restrict
}
@FXML
private void onOpenArbitratorScreen(){
private void onOpenArbitratorScreen() {
View view = viewLoader.load(ArbitratorBrowserView.class);
showStage(view);
}
@ -130,6 +130,7 @@ public class RestrictionsView extends ActivatableViewAndModel<GridPane, Restrict
@FXML
private void onCompleted() {
if (wizard != null)
wizard.nextStep(this);
}

View File

@ -60,7 +60,8 @@ public class SeedWordsView extends InitializableView<GridPane, SeedWordsViewMode
@FXML
private void onCompleted() {
wizard.nextStep(this);
if (wizard != null)
wizard.nextStep(this);
}
@FXML