mirror of
https://github.com/xpipe-io/xpipe.git
synced 2024-10-02 18:17:27 +13:00
Small fixes [stage]
This commit is contained in:
parent
6a6a155056
commit
118a1ababc
4 changed files with 20 additions and 2 deletions
|
@ -304,6 +304,7 @@ public abstract class DataStorage {
|
||||||
var displayParent = syntheticParent.or(() -> getDisplayParent(e));
|
var displayParent = syntheticParent.or(() -> getDisplayParent(e));
|
||||||
if (displayParent.isPresent()) {
|
if (displayParent.isPresent()) {
|
||||||
displayParent.get().setExpanded(true);
|
displayParent.get().setExpanded(true);
|
||||||
|
e.setCategoryUuid(displayParent.get().getCategoryUuid());
|
||||||
}
|
}
|
||||||
|
|
||||||
e.setDirectory(getStoresDir().resolve(e.getUuid().toString()));
|
e.setDirectory(getStoresDir().resolve(e.getUuid().toString()));
|
||||||
|
|
|
@ -149,16 +149,22 @@ public class StandardStorage extends DataStorage {
|
||||||
ErrorEvent.fromThrowable(exception.get()).handle();
|
ErrorEvent.fromThrowable(exception.get()).handle();
|
||||||
}
|
}
|
||||||
|
|
||||||
if (getStoreCategoryIfPresent(ALL_CONNECTIONS_CATEGORY_UUID).isEmpty()) {
|
var allConnections = getStoreCategoryIfPresent(ALL_CONNECTIONS_CATEGORY_UUID);
|
||||||
|
if (allConnections.isEmpty()) {
|
||||||
var cat = DataStoreCategory.createNew(null, ALL_CONNECTIONS_CATEGORY_UUID, "All connections");
|
var cat = DataStoreCategory.createNew(null, ALL_CONNECTIONS_CATEGORY_UUID, "All connections");
|
||||||
cat.setDirectory(categoriesDir.resolve(ALL_CONNECTIONS_CATEGORY_UUID.toString()));
|
cat.setDirectory(categoriesDir.resolve(ALL_CONNECTIONS_CATEGORY_UUID.toString()));
|
||||||
storeCategories.add(cat);
|
storeCategories.add(cat);
|
||||||
|
} else {
|
||||||
|
allConnections.get().setParentCategory(null);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (getStoreCategoryIfPresent(ALL_SCRIPTS_CATEGORY_UUID).isEmpty()) {
|
var allScripts = getStoreCategoryIfPresent(ALL_SCRIPTS_CATEGORY_UUID);
|
||||||
|
if (allScripts.isEmpty()) {
|
||||||
var cat = DataStoreCategory.createNew(null, ALL_SCRIPTS_CATEGORY_UUID, "All scripts");
|
var cat = DataStoreCategory.createNew(null, ALL_SCRIPTS_CATEGORY_UUID, "All scripts");
|
||||||
cat.setDirectory(categoriesDir.resolve(ALL_SCRIPTS_CATEGORY_UUID.toString()));
|
cat.setDirectory(categoriesDir.resolve(ALL_SCRIPTS_CATEGORY_UUID.toString()));
|
||||||
storeCategories.add(cat);
|
storeCategories.add(cat);
|
||||||
|
} else {
|
||||||
|
allScripts.get().setParentCategory(null);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (getStoreCategoryIfPresent(PREDEFINED_SCRIPTS_CATEGORY_UUID).isEmpty()) {
|
if (getStoreCategoryIfPresent(PREDEFINED_SCRIPTS_CATEGORY_UUID).isEmpty()) {
|
||||||
|
|
|
@ -11,6 +11,8 @@ import javafx.stage.Modality;
|
||||||
|
|
||||||
public class UpdateChangelogAlert {
|
public class UpdateChangelogAlert {
|
||||||
|
|
||||||
|
private static boolean shown = false;
|
||||||
|
|
||||||
public static void showIfNeeded() {
|
public static void showIfNeeded() {
|
||||||
var update = XPipeDistributionType.get().getUpdateHandler().getPerformedUpdate();
|
var update = XPipeDistributionType.get().getUpdateHandler().getPerformedUpdate();
|
||||||
if (update != null && !XPipeDistributionType.get().getUpdateHandler().isUpdateSucceeded()) {
|
if (update != null && !XPipeDistributionType.get().getUpdateHandler().isUpdateSucceeded()) {
|
||||||
|
@ -22,6 +24,11 @@ public class UpdateChangelogAlert {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (shown) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
shown = true;
|
||||||
|
|
||||||
AppWindowHelper.showAlert(
|
AppWindowHelper.showAlert(
|
||||||
alert -> {
|
alert -> {
|
||||||
alert.setTitle(AppI18n.get("updateChangelogAlertTitle"));
|
alert.setTitle(AppI18n.get("updateChangelogAlertTitle"));
|
||||||
|
|
|
@ -19,6 +19,10 @@ public class UnlockAlert {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (AppPrefs.get().getLockPassword().getValue() != null) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
while (true) {
|
while (true) {
|
||||||
var pw = new SimpleObjectProperty<SecretValue>();
|
var pw = new SimpleObjectProperty<SecretValue>();
|
||||||
var canceled = new SimpleBooleanProperty();
|
var canceled = new SimpleBooleanProperty();
|
||||||
|
|
Loading…
Reference in a new issue