no message
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
package Visual_DVM_2021.Passes.All;
|
||||
import Common.Utils.CommonUtils;
|
||||
import Common_old.UI.Selectable;
|
||||
import Common.Visual.Selectable;
|
||||
import Common_old.UI.UI;
|
||||
import ProjectData.SapforData.Includes.DependencyInfo;
|
||||
import ProjectData.SapforData.Includes.FileInfo;
|
||||
|
||||
@@ -127,9 +127,6 @@ public class UpdateSetting extends Pass_2021<DBSetting> {
|
||||
if (Current.HasProject())
|
||||
UI.fastAccessMenuBar.Refresh();
|
||||
break;
|
||||
case DarkThemeOn:
|
||||
UI.refreshTheme();
|
||||
break;
|
||||
case ShowFullArraysDeclarations:
|
||||
if (Current.HasProject())
|
||||
Current.getProject().declaratedArrays.ShowUI();
|
||||
|
||||
@@ -1,7 +0,0 @@
|
||||
package Visual_DVM_2021.UI.Interface;
|
||||
public interface FilterWindow extends VisualizerForm {
|
||||
void ShowMatchesCount(int count);
|
||||
default void ShowNoMatches() {
|
||||
ShowMatchesCount(0);
|
||||
}
|
||||
}
|
||||
@@ -1,49 +0,0 @@
|
||||
package Visual_DVM_2021.UI.Interface;
|
||||
import Common.Utils.CommonUtils;
|
||||
import Common_old.Current;
|
||||
import Common_old.UI.DebugPrintLevel;
|
||||
import Common_old.UI.UI;
|
||||
import Common_old.Utils.Utils;
|
||||
|
||||
import java.io.File;
|
||||
import java.io.FileWriter;
|
||||
import java.io.PrintWriter;
|
||||
import java.io.StringWriter;
|
||||
import java.nio.file.Paths;
|
||||
import java.util.Date;
|
||||
public interface Loggable {
|
||||
String getLogHomePath();
|
||||
String getLogName();
|
||||
default File getLogFile() {
|
||||
return Paths.get(getLogHomePath(), (getLogName() + "_log.txt")).toFile();
|
||||
}
|
||||
default void ClearLog() {
|
||||
try {
|
||||
Utils.forceDeleteWithCheck(getLogFile());
|
||||
} catch (Exception ignored) {
|
||||
}
|
||||
}
|
||||
default void Print(String message) {
|
||||
try {
|
||||
FileWriter Log = new FileWriter(getLogFile(), true);
|
||||
String datedMessage = CommonUtils.Brackets(new Date()) + " " + message;
|
||||
Log.write(datedMessage + "\n");
|
||||
Log.close();
|
||||
} catch (Exception ignored) {
|
||||
}
|
||||
}
|
||||
default void Print(DebugPrintLevel level, String message) {
|
||||
if (level.isEnabled())
|
||||
Print(CommonUtils.Brackets(level.getDescription()) + " " + message);
|
||||
}
|
||||
default void PrintException(Exception ex) {
|
||||
StringWriter out = new StringWriter();
|
||||
PrintWriter writer = new PrintWriter(out);
|
||||
ex.printStackTrace(writer);
|
||||
writer.flush();
|
||||
Print(out.toString());
|
||||
if (Current.hasUI())
|
||||
UI.Error("Возникло исключение. Подробности в файле журнала\n" +
|
||||
CommonUtils.Brackets(getLogFile().getAbsolutePath()));
|
||||
}
|
||||
}
|
||||
@@ -1,5 +1,6 @@
|
||||
package Visual_DVM_2021.UI.Main;
|
||||
import Common.Utils.CommonUtils;
|
||||
import Common.Visual.CommonUI;
|
||||
import Common_old.Current;
|
||||
import _VisualDVM.Global;
|
||||
import Common_old.UI.Editor.BaseEditor;
|
||||
@@ -285,7 +286,7 @@ public class CallbackForm implements FormWithSplitters, CallbackWindow {
|
||||
CommentFields commentFields = new CommentFields();
|
||||
@Override
|
||||
public void SwitchScreen(boolean small) {
|
||||
UI.Clear(descriptionPanel);
|
||||
CommonUI.Clear(descriptionPanel);
|
||||
//------------------------------------------------------------------
|
||||
descriptionInterface = small ? descriptionTabs : descriptionFields;
|
||||
descriptionInterface.setEditorScroll(bugDescriptionScroll);
|
||||
@@ -295,7 +296,7 @@ public class CallbackForm implements FormWithSplitters, CallbackWindow {
|
||||
descriptionPanel.revalidate();
|
||||
descriptionPanel.repaint();
|
||||
//---------
|
||||
UI.Clear(commentPanel);
|
||||
CommonUI.Clear(commentPanel);
|
||||
//------------------------------------------------------------------
|
||||
commentInterface = small ? commentTabs : commentFields;
|
||||
commentInterface.setEditorScroll(bugCommentScroll);
|
||||
@@ -365,7 +366,7 @@ public class CallbackForm implements FormWithSplitters, CallbackWindow {
|
||||
settingsTools = new VisualiserMenuBar();
|
||||
}
|
||||
public void EnableBugreports() {
|
||||
UI.Clear(accountPanel);
|
||||
CommonUI.Clear(accountPanel);
|
||||
accountPanel.add(SC10);
|
||||
UI.getMainWindow().SwitchTestingTabs(true);
|
||||
}
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
package Visual_DVM_2021.UI.Main;
|
||||
import Common.CommonConstants;
|
||||
import Common.Visual.CommonUI;
|
||||
import _VisualDVM.Global;
|
||||
import Common_old.UI.Editor.Viewer;
|
||||
import Common_old.UI.Menus_2023.FileMenuBar.FileMenuBar;
|
||||
@@ -213,7 +214,7 @@ public class FileForm implements FileWindow, FormWithSplitters {
|
||||
}
|
||||
@Override
|
||||
public void ShowText() {
|
||||
UI.Clear(editorPanel);
|
||||
CommonUI.Clear(editorPanel);
|
||||
editorPanel.add(new RTextScrollPane(Body = new SPFEditor(file)));
|
||||
UI.getSearchReplaceForm().setEditor(Body);
|
||||
if (UI.getSearchReplaceForm().isVisible())
|
||||
@@ -367,12 +368,12 @@ public class FileForm implements FileWindow, FormWithSplitters {
|
||||
@Override
|
||||
public void CollapseGraphs() {
|
||||
Global.db.splitters.get("SC12").position = SC12.getDividerLocation();
|
||||
UI.Clear(editorBackground);
|
||||
CommonUI.Clear(editorBackground);
|
||||
editorBackground.add(editorPanel);
|
||||
}
|
||||
@Override
|
||||
public void ExpandGraphs() {
|
||||
UI.Clear(editorBackground);
|
||||
CommonUI.Clear(editorBackground);
|
||||
SC12.setRightComponent(editorPanel);
|
||||
editorBackground.add(SC12);
|
||||
//--
|
||||
@@ -382,12 +383,12 @@ public class FileForm implements FileWindow, FormWithSplitters {
|
||||
@Override
|
||||
public void CollapseMessages() {
|
||||
Global.db.splitters.get("SC1").position = SC1.getDividerLocation();
|
||||
UI.Clear(content);
|
||||
CommonUI.Clear(content);
|
||||
content.add(editorBackground);
|
||||
}
|
||||
@Override
|
||||
public void ExpandMessages() {
|
||||
UI.Clear(content);
|
||||
CommonUI.Clear(content);
|
||||
SC1.setLeftComponent(editorBackground);
|
||||
content.add(SC1);
|
||||
SC1.setDividerLocation(Global.db.splitters.get("SC1").position);
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
package Visual_DVM_2021.UI.Main;
|
||||
import Common.Visual.CommonUI;
|
||||
import Common_old.Current;
|
||||
import _VisualDVM.Global;
|
||||
import Common_old.UI.Menus_2023.MainMenuBar.MainWindow;
|
||||
@@ -234,7 +235,7 @@ public class MainForm extends Form implements MainWindow {
|
||||
getTestsWindow().ShowAll();
|
||||
if (getTestingWindow() != null)
|
||||
getTestingWindow().ShowAll();
|
||||
UI.windowsStack.push(this);
|
||||
CommonUI.windowsStack.push(this);
|
||||
super.Show();
|
||||
}
|
||||
@Override
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
package Visual_DVM_2021.UI.Main;
|
||||
import Common.Visual.CommonUI;
|
||||
import Common_old.Current;
|
||||
import _VisualDVM.Global;
|
||||
import Common_old.UI.Editor.Viewer;
|
||||
@@ -170,7 +171,7 @@ public class ProjectForm implements FormWithSplitters, ProjectWindow {
|
||||
projectTabs.setSelectedIndex(0);
|
||||
}
|
||||
});
|
||||
UI.Clear(fileBackground);
|
||||
CommonUI.Clear(fileBackground);
|
||||
//filesTabs.removeAll();
|
||||
}
|
||||
@Override
|
||||
@@ -252,7 +253,7 @@ public class ProjectForm implements FormWithSplitters, ProjectWindow {
|
||||
}
|
||||
@Override
|
||||
public void ShowProjectView() {
|
||||
UI.Clear(projectViewPanel);
|
||||
CommonUI.Clear(projectViewPanel);
|
||||
ProjectView view = Current.getProjectView();
|
||||
menuBar.getProjectViewMenu().setToolTipText(view.getDescription());
|
||||
menuBar.getProjectViewMenu().setIcon(Utils.getIcon(view.getIcon()));
|
||||
@@ -294,7 +295,7 @@ public class ProjectForm implements FormWithSplitters, ProjectWindow {
|
||||
public void CollapseProjectTrees() {
|
||||
Global.db.splitters.get("SC3").position = SC3.getDividerLocation();
|
||||
//---
|
||||
UI.Clear(projectBackground);
|
||||
CommonUI.Clear(projectBackground);
|
||||
projectBackground.add(fileBackground);
|
||||
}
|
||||
@Override
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
package Visual_DVM_2021.UI.Main;
|
||||
import Common.Visual.CommonUI;
|
||||
import Common_old.Current;
|
||||
import Common.Database.Objects.DBObject;
|
||||
import Common_old.UI.Label.ShortLabel;
|
||||
@@ -114,7 +115,7 @@ public class SapforPackagesComparisonForm {
|
||||
}
|
||||
//---
|
||||
public void showNoTree() {
|
||||
UI.Clear(treePanel);
|
||||
CommonUI.Clear(treePanel);
|
||||
}
|
||||
public void showObject() {
|
||||
lObjectName.setText(object.getPK().toString() + (isMaster() ? "(эталон)" : ""));
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
package Visual_DVM_2021.UI.Main;
|
||||
import Common.CommonConstants;
|
||||
import Common.Visual.CommonUI;
|
||||
import Common_old.Current;
|
||||
import _VisualDVM.Global;
|
||||
import Common_old.UI.TextField.StyledTextField;
|
||||
@@ -311,7 +312,7 @@ public class TestingForm implements FormWithSplitters, TestingWindow {
|
||||
@Override
|
||||
public void CollapseCredentials() {
|
||||
Global.db.splitters.get("SC71").position = SC71.getDividerLocation();
|
||||
UI.Clear(credentialsPanel);
|
||||
CommonUI.Clear(credentialsPanel);
|
||||
credentialsPanel.add(UI.credentialsBar);
|
||||
SC71.setDividerLocation(30);
|
||||
SC71.setDividerSize(0);
|
||||
@@ -320,7 +321,7 @@ public class TestingForm implements FormWithSplitters, TestingWindow {
|
||||
}
|
||||
@Override
|
||||
public void ExpandCredentials() {
|
||||
UI.Clear(credentialsPanel);
|
||||
CommonUI.Clear(credentialsPanel);
|
||||
credentialsPanel.add(SC18);
|
||||
SC71.setDividerLocation(200);
|
||||
SC71.setDividerSize(3);
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
package Visual_DVM_2021.UI.Main;
|
||||
import Common.Visual.CommonUI;
|
||||
import Common_old.UI.Trees.TreeForm;
|
||||
import Common_old.UI.UI;
|
||||
import ProjectData.Project.UI.VersionsTree;
|
||||
@@ -50,7 +51,7 @@ public class VersionsForm implements FormWithSplitters, VersionsWindow {
|
||||
}
|
||||
@Override
|
||||
public void ShowNoProjectVariants() {
|
||||
UI.Clear(variantsFormPanel);
|
||||
CommonUI.Clear(variantsFormPanel);
|
||||
versionsTabs.setEnabledAt(0, false);
|
||||
}
|
||||
@Override
|
||||
|
||||
Reference in New Issue
Block a user