Small fixes

This commit is contained in:
crschnick 2024-07-14 08:19:00 +00:00
parent 972f106cb0
commit 21b7e063aa
4 changed files with 10 additions and 5 deletions

View file

@ -32,9 +32,9 @@ public class BrowserStatusBarComp extends SimpleComp {
@Override
protected Region createSimple() {
var bar = new HorizontalComp(List.of(
createProgressEstimateStatus(),
createProgressNameStatus(),
createProgressStatus(),
createProgressEstimateStatus(),
Comp.hspacer(),
createClipboardStatus(),
createSelectionStatus()

View file

@ -112,6 +112,11 @@ public class StoreCategoryWrapper {
}
public void update() {
// We are probably in shutdown then
if (StoreViewState.get() == null) {
return;
}
// Avoid reupdating name when changed from the name property!
var catName = translatedName(category.getName());
if (!catName.equals(name.getValue())) {

View file

@ -39,7 +39,7 @@ public class FilterComp extends Comp<CompStructure<CustomTextField>> {
filter.getStyleClass().add("filter-comp");
filter.promptTextProperty().bind(AppI18n.observable("searchFilter"));
filter.rightProperty().bind(Bindings.createObjectBinding(() -> {
return filter.isFocused() ? clear : fi;
return filter.isFocused() || (filter.getText() != null && !filter.getText().isEmpty()) ? clear : fi;
}, filter.focusedProperty()));
filter.setAccessibleText("Filter");

View file

@ -36,8 +36,6 @@ public class VaultCategory extends AppPrefsCategory {
}
builder.addTitle("vaultSecurity")
.sub(new OptionsBuilder()
.nameAndDescription("encryptAllVaultData")
.addToggle(prefs.encryptAllVaultData)
.nameAndDescription("workspaceLock")
.addComp(
new ButtonComp(
@ -57,7 +55,9 @@ public class VaultCategory extends AppPrefsCategory {
.addToggle(prefs.lockVaultOnHibernation)
.hide(prefs.getLockCrypt()
.isNull()
.or(prefs.getLockCrypt().isEmpty())));
.or(prefs.getLockCrypt().isEmpty()))
.nameAndDescription("encryptAllVaultData")
.addToggle(prefs.encryptAllVaultData));
return builder.buildComp();
}
}