mirror of
https://github.com/haveno-dex/haveno.git
synced 2025-04-19 15:26:03 -04:00
remove unused wizard interface
This commit is contained in:
parent
efc365f7e3
commit
cdba55f23e
@ -1,28 +0,0 @@
|
||||
/*
|
||||
* This file is part of Bitsquare.
|
||||
*
|
||||
* Bitsquare is free software: you can redistribute it and/or modify it
|
||||
* under the terms of the GNU Affero General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or (at
|
||||
* your option) any later version.
|
||||
*
|
||||
* Bitsquare is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public
|
||||
* License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU Affero General Public License
|
||||
* along with Bitsquare. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
package io.bitsquare.gui.common.view;
|
||||
|
||||
public interface Wizard extends View {
|
||||
void nextStep(Step currentStep);
|
||||
|
||||
interface Step {
|
||||
void hideWizardNavigation();
|
||||
|
||||
void setWizard(Wizard wizard);
|
||||
}
|
||||
}
|
@ -19,7 +19,6 @@ package io.bitsquare.gui.main.account.content.changepassword;
|
||||
|
||||
import io.bitsquare.gui.common.view.FxmlView;
|
||||
import io.bitsquare.gui.common.view.InitializableView;
|
||||
import io.bitsquare.gui.common.view.Wizard;
|
||||
import io.bitsquare.gui.main.help.Help;
|
||||
import io.bitsquare.gui.main.help.HelpId;
|
||||
import javafx.fxml.FXML;
|
||||
@ -31,7 +30,7 @@ import javafx.scene.layout.HBox;
|
||||
import javax.inject.Inject;
|
||||
|
||||
@FxmlView
|
||||
public class ChangePasswordView extends InitializableView<GridPane, ChangePasswordViewModel> implements Wizard.Step {
|
||||
public class ChangePasswordView extends InitializableView<GridPane, ChangePasswordViewModel> {
|
||||
|
||||
@FXML
|
||||
HBox buttonsHBox;
|
||||
@ -40,8 +39,6 @@ public class ChangePasswordView extends InitializableView<GridPane, ChangePasswo
|
||||
@FXML
|
||||
PasswordField oldPasswordField, passwordField, repeatedPasswordField;
|
||||
|
||||
private Wizard wizard;
|
||||
|
||||
@Inject
|
||||
private ChangePasswordView(ChangePasswordViewModel model) {
|
||||
super(model);
|
||||
@ -55,21 +52,9 @@ public class ChangePasswordView extends InitializableView<GridPane, ChangePasswo
|
||||
saveButton.disableProperty().bind(model.saveButtonDisabled);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setWizard(Wizard wizard) {
|
||||
this.wizard = wizard;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void hideWizardNavigation() {
|
||||
buttonsHBox.getChildren().remove(skipButton);
|
||||
}
|
||||
|
||||
@FXML
|
||||
private void onSaved() {
|
||||
if (wizard != null && model.requestSavePassword())
|
||||
wizard.nextStep(this);
|
||||
else
|
||||
if (!model.requestSavePassword())
|
||||
log.debug(model.getErrorMessage()); // TODO use validating TF
|
||||
}
|
||||
|
||||
@ -80,8 +65,6 @@ public class ChangePasswordView extends InitializableView<GridPane, ChangePasswo
|
||||
|
||||
@FXML
|
||||
private void onSkipped() {
|
||||
if (wizard != null)
|
||||
wizard.nextStep(this);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -123,9 +123,6 @@ public class AccountSettingsView extends ActivatableViewAndModel {
|
||||
else {*/
|
||||
View view = viewLoader.load(viewClass);
|
||||
content.getChildren().setAll(view.getRoot());
|
||||
if (view instanceof Wizard.Step)
|
||||
((Wizard.Step) view).hideWizardNavigation();
|
||||
|
||||
|
||||
if (view instanceof PasswordView) password.setSelected(true);
|
||||
else if (view instanceof SeedWordsView) seedWords.setSelected(true);
|
||||
|
Loading…
x
Reference in New Issue
Block a user