use of org.apache.cayenne.pref.CayenneProjectPreferences in project cayenne by apache.
the class GeneratorTabController method initBindings.
protected void initBindings() {
// bind actions
BindingBuilder builder = new BindingBuilder(getApplication().getBindingFactory(), this);
builder.bindToAction(view.getGenerationMode(), "updateModeAction()");
CayenneProjectPreferences cayPrPref = application.getCayenneProjectPreferences();
this.preferences = (PreferenceDetail) cayPrPref.getProjectDetailObject(PreferenceDetail.class, getViewPreferences().node("controller"));
if (Util.isEmptyString(preferences.getProperty("mode"))) {
preferences.setProperty("mode", STANDARD_OBJECTS_MODE);
}
builder.bindToComboSelection(view.getGenerationMode(), "preferences.property['mode']").updateView();
updateModeAction();
}
Aggregations