Small fixes [release]

This commit is contained in:
crschnick
2023-02-01 18:18:42 +00:00
parent 76c78d9d78
commit c1cafcfced
5 changed files with 13 additions and 5 deletions

View File

@@ -7,6 +7,7 @@ import com.dlsc.preferencesfx.formsfx.view.controls.ToggleControl;
import com.dlsc.preferencesfx.model.Category;
import com.dlsc.preferencesfx.model.Group;
import com.dlsc.preferencesfx.model.Setting;
import com.dlsc.preferencesfx.util.VisibilityProperty;
import io.xpipe.app.core.AppDistributionType;
import io.xpipe.app.core.AppProperties;
import io.xpipe.app.core.AppStyle;
@@ -104,6 +105,9 @@ public class AppPrefs {
? ExternalStartupBehaviour.TRAY
: ExternalStartupBehaviour.BACKGROUND),
ExternalStartupBehaviour.class);
private final SingleSelectionField<ExternalStartupBehaviour> externalStartupBehaviourControl =
Field.ofSingleSelectionType(externalStartupBehaviourList, externalStartupBehaviour)
.render(() -> new TranslatableComboBoxControl<>());
@@ -395,7 +399,7 @@ public class AppPrefs {
Group.of(
"editor",
Setting.of("defaultProgram", externalEditorControl, externalEditor),
Setting.of("customEditorCommand", customEditorCommandControl, customEditorCommand),
Setting.of("customEditorCommand", customEditorCommandControl, customEditorCommand).applyVisibility( VisibilityProperty.of(externalEditor.isEqualTo(ExternalEditorType.CUSTOM))),
Setting.of(
"editorReloadTimeout",
editorReloadTimeout,