FilesChanged dialog not over other applications.

This commit is contained in:
Jindra Petřík
2021-02-22 11:36:58 +01:00
parent 11c3c2a8a7
commit 0d2fcb0897
2 changed files with 40 additions and 5 deletions

View File

@@ -1392,7 +1392,9 @@ public class Main {
sourceInfos.clear();
}
filesChangedDialog.setVisible(false);
if (filesChangedDialog != null) {
filesChangedDialog.setVisible(false);
}
return closeResult;
}
@@ -1710,7 +1712,6 @@ public class Main {
}
}
filesChangedDialog = new FilesChangedDialog();
if (watcher != null) {
watcherWorker = new SwingWorker() {
@@ -1750,6 +1751,9 @@ public class Main {
View.execInEventDispatchLater(new Runnable() {
@Override
public void run() {
if (filesChangedDialog == null) {
filesChangedDialog = new FilesChangedDialog(Main.mainFrame.getWindow());
}
filesChangedDialog.addItem(infoFile);
if (!filesChangedDialog.isVisible()) {
filesChangedDialog.setVisible(true);