use of io.bitsquare.gui.main.settings.network.NetworkSettingsView in project bitsquare by bitsquare.
the class SettingsView method loadView.
private void loadView(Class<? extends View> viewClass) {
final Tab tab;
View view = viewLoader.load(viewClass);
if (view instanceof PreferencesView)
tab = preferencesTab;
else if (view instanceof NetworkSettingsView)
tab = networkSettingsTab;
else if (view instanceof AboutView)
tab = aboutTab;
else
throw new IllegalArgumentException("Navigation to " + viewClass + " is not supported");
if (tab.getContent() != null && tab.getContent() instanceof ScrollPane) {
((ScrollPane) tab.getContent()).setContent(view.getRoot());
} else {
tab.setContent(view.getRoot());
}
root.getSelectionModel().select(tab);
}
Aggregations