рефакторинг. переносил текущие объекты в другое место

This commit is contained in:
2024-10-13 22:08:13 +03:00
parent 09b64218bd
commit 6afa2dc892
240 changed files with 1472 additions and 1518 deletions

View File

@@ -1,6 +1,8 @@
package Visual_DVM_2021.Passes.All;
import Common.Current_;
import Common.Utils.Utils_;
import _VisualDVM.Current;
import _VisualDVM.Global;
import _VisualDVM.Visual.UI;
import _VisualDVM.ProjectData.Files.DBProjectFile;
import Visual_DVM_2021.Passes.PassCode;
@@ -9,7 +11,7 @@ public class OpenCurrentFile extends Pass<DBProjectFile> {
@Override
protected boolean canStart(Object... args) throws Exception {
target = (args.length > 0) ? (DBProjectFile) args[0] : null;
return (target != null) && (!Current.HasFile() || (!Current.getFile().file.equals(target.file)));
return (target != null) && (!Global.mainModule.HasFile() || (!Global.mainModule.getFile().file.equals(target.file)));
}
@Override
protected void performPreparation() throws Exception {
@@ -21,7 +23,7 @@ public class OpenCurrentFile extends Pass<DBProjectFile> {
}
@Override
protected void performDone() throws Exception {
Current_.set(Current.File, target);
Global.mainModule.set(Current.File, target);
}
@Override
protected void showDone() throws Exception {