mirror of
https://github.com/xpipe-io/xpipe.git
synced 2024-10-01 09:40:35 +13:00
Appearance fixes
This commit is contained in:
parent
56bd49b932
commit
76c29f719b
8 changed files with 29 additions and 8 deletions
|
@ -72,7 +72,7 @@ public class LoadingOverlayComp extends Comp<CompStructure<StackPane>> {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
PlatformThread.sync(showLoading).addListener(listener);
|
showLoading.addListener(listener);
|
||||||
|
|
||||||
var stack = new StackPane(r, loadingOverlay);
|
var stack = new StackPane(r, loadingOverlay);
|
||||||
|
|
||||||
|
|
|
@ -3,10 +3,7 @@ package io.xpipe.app.comp.store;
|
||||||
import io.xpipe.app.comp.base.ErrorOverlayComp;
|
import io.xpipe.app.comp.base.ErrorOverlayComp;
|
||||||
import io.xpipe.app.comp.base.MultiStepComp;
|
import io.xpipe.app.comp.base.MultiStepComp;
|
||||||
import io.xpipe.app.comp.base.PopupMenuButtonComp;
|
import io.xpipe.app.comp.base.PopupMenuButtonComp;
|
||||||
import io.xpipe.app.core.AppExtensionManager;
|
import io.xpipe.app.core.*;
|
||||||
import io.xpipe.app.core.AppFont;
|
|
||||||
import io.xpipe.app.core.AppI18n;
|
|
||||||
import io.xpipe.app.core.AppWindowHelper;
|
|
||||||
import io.xpipe.app.core.mode.OperationMode;
|
import io.xpipe.app.core.mode.OperationMode;
|
||||||
import io.xpipe.app.ext.DataStoreProvider;
|
import io.xpipe.app.ext.DataStoreProvider;
|
||||||
import io.xpipe.app.fxcomps.Comp;
|
import io.xpipe.app.fxcomps.Comp;
|
||||||
|
|
|
@ -62,10 +62,15 @@ public class AppWindowHelper {
|
||||||
stage.setTitle(title);
|
stage.setTitle(title);
|
||||||
addIcons(stage);
|
addIcons(stage);
|
||||||
setupContent(stage, contentFunc, bindSize, loading);
|
setupContent(stage, contentFunc, bindSize, loading);
|
||||||
AppTheme.initThemeHandlers(stage);
|
|
||||||
setupStylesheets(stage.getScene());
|
setupStylesheets(stage.getScene());
|
||||||
|
|
||||||
stage.setOnShown(e -> {
|
stage.setOnShown(e -> {
|
||||||
|
// If we set the theme pseudo classes earlier when the window is not shown
|
||||||
|
// they do not apply. Is this a bug in JavaFX?
|
||||||
|
Platform.runLater(() -> {
|
||||||
|
AppTheme.initThemeHandlers(stage);
|
||||||
|
});
|
||||||
|
|
||||||
centerToMainWindow(stage);
|
centerToMainWindow(stage);
|
||||||
});
|
});
|
||||||
return stage;
|
return stage;
|
||||||
|
|
|
@ -63,6 +63,8 @@ public class ChoicePaneComp extends Comp<CompStructure<VBox>> {
|
||||||
} else {
|
} else {
|
||||||
vbox.getChildren().set(1, region);
|
vbox.getChildren().set(1, region);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
region.requestFocus();
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
|
@ -57,6 +57,12 @@ public class FileStoreChoiceComp extends SimpleComp {
|
||||||
var layout = new HorizontalComp(List.of(fileSystemChoiceComp, fileNameComp, fileBrowseButton))
|
var layout = new HorizontalComp(List.of(fileSystemChoiceComp, fileNameComp, fileBrowseButton))
|
||||||
.apply(struc -> struc.get().setFillHeight(true));
|
.apply(struc -> struc.get().setFillHeight(true));
|
||||||
|
|
||||||
|
layout.apply(struc -> {
|
||||||
|
struc.get().focusedProperty().addListener((observable, oldValue, newValue) -> {
|
||||||
|
struc.get().getChildren().get(1).requestFocus();
|
||||||
|
});
|
||||||
|
});
|
||||||
|
|
||||||
return layout.createRegion();
|
return layout.createRegion();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -49,11 +49,16 @@ public class OptionsComp extends Comp<CompStructure<Pane>> {
|
||||||
|
|
||||||
var nameRegions = new ArrayList<Region>();
|
var nameRegions = new ArrayList<Region>();
|
||||||
|
|
||||||
|
Region firstComp = null;
|
||||||
|
|
||||||
for (var entry : getEntries()) {
|
for (var entry : getEntries()) {
|
||||||
Region compRegion = null;
|
Region compRegion = null;
|
||||||
if (entry.comp() != null) {
|
if (entry.comp() != null) {
|
||||||
compRegion = entry.comp().createRegion();
|
compRegion = entry.comp().createRegion();
|
||||||
}
|
}
|
||||||
|
if (firstComp == null) {
|
||||||
|
firstComp = compRegion;
|
||||||
|
}
|
||||||
|
|
||||||
if (entry.name() != null && entry.description() != null) {
|
if (entry.name() != null && entry.description() != null) {
|
||||||
var line = new VBox();
|
var line = new VBox();
|
||||||
|
@ -162,6 +167,13 @@ public class OptionsComp extends Comp<CompStructure<Pane>> {
|
||||||
nameRegions.forEach(r -> r.minWidthProperty().bind(nameWidthBinding));
|
nameRegions.forEach(r -> r.minWidthProperty().bind(nameWidthBinding));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Region finalFirstComp = firstComp;
|
||||||
|
pane.focusedProperty().addListener((observable, oldValue, newValue) -> {
|
||||||
|
if (finalFirstComp != null && newValue) {
|
||||||
|
finalFirstComp.requestFocus();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
return new SimpleCompStructure<>(pane);
|
return new SimpleCompStructure<>(pane);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -54,7 +54,6 @@ public class SecretRetrievalStrategyHelper {
|
||||||
new SimpleObjectProperty<>(p.getValue() != null ? p.getValue().getCommand() : null);
|
new SimpleObjectProperty<>(p.getValue() != null ? p.getValue().getCommand() : null);
|
||||||
var content = new TextFieldComp(cmdProperty);
|
var content = new TextFieldComp(cmdProperty);
|
||||||
return new OptionsBuilder()
|
return new OptionsBuilder()
|
||||||
.name("command")
|
|
||||||
.addComp(content, cmdProperty)
|
.addComp(content, cmdProperty)
|
||||||
.bind(
|
.bind(
|
||||||
() -> {
|
() -> {
|
||||||
|
|
|
@ -82,7 +82,7 @@ developerModeDescription=When enabled, you will have access to a variety of addi
|
||||||
editor=Editor
|
editor=Editor
|
||||||
custom=Custom
|
custom=Custom
|
||||||
passwordManagerCommand=Password manager command
|
passwordManagerCommand=Password manager command
|
||||||
passwordManagerCommandDescription=The command to execute to fetch passwords. The placeholder string $KEY will be replaced by the quoted password key when called. This should call your password manager CLI to print the password to stdout, e.g. mypassmgr get $KEY.\n\nYou can check here whether the output is correct. The command should only output the password itself, no other formatting should be included in the output.
|
passwordManagerCommandDescription=The command to execute to fetch passwords. The placeholder string $KEY will be replaced by the quoted password key when called. This should call your password manager CLI to print the password to stdout, e.g. mypassmgr get $KEY.\n\nYou can test below whether the output is correct. The command should only output the password itself, no other formatting should be included in the output.
|
||||||
preferEditorTabs=Prefer to open new tabs
|
preferEditorTabs=Prefer to open new tabs
|
||||||
preferEditorTabsDescription=Controls whether XPipe will try to open new tabs in your chosen editor instead of new windows.
|
preferEditorTabsDescription=Controls whether XPipe will try to open new tabs in your chosen editor instead of new windows.
|
||||||
customEditorCommand=Custom editor command
|
customEditorCommand=Custom editor command
|
||||||
|
|
Loading…
Reference in a new issue