use of org.phoenicis.javafx.components.engine.control.EngineSidebar in project POL-POM-5 by PlayOnLinux.
the class EnginesView method createEngineSidebar.
private EngineSidebar createEngineSidebar() {
final EngineSidebar sidebar = new EngineSidebar(this.filter, this.engineCategories, this.selectedListWidget);
sidebar.setJavaFxSettingsManager(this.javaFxSettingsManager);
// set the default selection
sidebar.setSelectedListWidget(javaFxSettingsManager.getEnginesListType());
// save changes to the list widget selection to the hard drive
sidebar.selectedListWidgetProperty().addListener((observable, oldValue, newValue) -> {
if (newValue != null) {
javaFxSettingsManager.setEnginesListType(newValue);
javaFxSettingsManager.save();
}
});
return sidebar;
}
Aggregations