no message
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
package Common_old.UI;
|
||||
import _VisualDVM.Global;
|
||||
import Common.Utils.CommonUtils;
|
||||
|
||||
import javax.swing.*;
|
||||
import java.awt.*;
|
||||
@@ -34,7 +34,7 @@ public class ControlForm<C extends Component> {
|
||||
try {
|
||||
control = control_class.newInstance();
|
||||
} catch (Exception e) {
|
||||
Global.Log.PrintException(e);
|
||||
CommonUtils.MainLog.PrintException(e);
|
||||
}
|
||||
}
|
||||
public boolean isShown() {
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
package Common_old.UI;
|
||||
import Common.CommonConstants;
|
||||
import Common.Utils.CommonUtils;
|
||||
import Common.Visual.CommonUI;
|
||||
import Common_old.Current;
|
||||
import Common.Database.Objects.DBObject;
|
||||
@@ -220,7 +221,7 @@ public class DataSetControlForm extends ControlWithCurrentForm<DataTable> {
|
||||
try {
|
||||
ShowCurrentObject();
|
||||
} catch (Exception ex) {
|
||||
Global.Log.PrintException(ex);
|
||||
CommonUtils.MainLog.PrintException(ex);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -231,7 +232,7 @@ public class DataSetControlForm extends ControlWithCurrentForm<DataTable> {
|
||||
try {
|
||||
ShowNoCurrentObject();
|
||||
} catch (Exception ex) {
|
||||
Global.Log.PrintException(ex);
|
||||
CommonUtils.MainLog.PrintException(ex);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -244,7 +245,7 @@ public class DataSetControlForm extends ControlWithCurrentForm<DataTable> {
|
||||
try {
|
||||
MouseAction2();
|
||||
} catch (Exception ex) {
|
||||
Global.Log.PrintException(ex);
|
||||
CommonUtils.MainLog.PrintException(ex);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -255,7 +256,7 @@ public class DataSetControlForm extends ControlWithCurrentForm<DataTable> {
|
||||
try {
|
||||
ShowNoCurrentObject();
|
||||
} catch (Exception e) {
|
||||
Global.Log.PrintException(e);
|
||||
CommonUtils.MainLog.PrintException(e);
|
||||
}
|
||||
}
|
||||
//---
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
package Common_old.UI.DragDrop;
|
||||
import _VisualDVM.Global;
|
||||
import Common.Utils.CommonUtils;
|
||||
|
||||
import java.awt.datatransfer.DataFlavor;
|
||||
import java.io.*;
|
||||
@@ -314,12 +314,12 @@ public class FileDrop {
|
||||
} // end try
|
||||
catch (IOException io) {
|
||||
log(out, "FileDrop: IOException - abort:");
|
||||
Global.Log.PrintException(io);
|
||||
CommonUtils.MainLog.PrintException(io);
|
||||
evt.rejectDrop();
|
||||
} // end catch IOException
|
||||
catch (java.awt.datatransfer.UnsupportedFlavorException ufe) {
|
||||
log(out, "FileDrop: UnsupportedFlavorException - abort:");
|
||||
Global.Log.PrintException(ufe);
|
||||
CommonUtils.MainLog.PrintException(ufe);
|
||||
evt.rejectDrop();
|
||||
} // end catch: UnsupportedFlavorException
|
||||
finally {
|
||||
@@ -446,7 +446,7 @@ public class FileDrop {
|
||||
dt.addDropTargetListener(dropListener);
|
||||
} // end try
|
||||
catch (java.util.TooManyListenersException e) {
|
||||
Global.Log.PrintException(e);
|
||||
CommonUtils.MainLog.PrintException(e);
|
||||
log(out, "FileDrop: Drop will not work due to previous error. Do you have another listener attached?");
|
||||
} // end catch
|
||||
// Listen for hierarchy changes and remove the drop target when the parent gets cleared out.
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
package Common_old.UI.Editor;
|
||||
import Common.Utils.CommonUtils;
|
||||
import Common_old.Current;
|
||||
import _VisualDVM.Global;
|
||||
import Common_old.UI.Menus.StyledPopupMenu;
|
||||
import Common_old.UI.Menus.TextEditorMenu;
|
||||
import _VisualDVM.Syntax.ThemeElement;
|
||||
@@ -115,8 +115,8 @@ public class BaseEditor extends RSyntaxTextArea implements ThemeElement, DialogF
|
||||
setSelectionEnd(getLineStartOffset(LineNum));
|
||||
}
|
||||
} catch (Exception ex) {
|
||||
Global.Log.Print("Не удалось перейти на строку " + LineNum);
|
||||
Global.Log.PrintException(ex);
|
||||
CommonUtils.MainLog.Print("Не удалось перейти на строку " + LineNum);
|
||||
CommonUtils.MainLog.PrintException(ex);
|
||||
}
|
||||
}
|
||||
//------------------------------------------
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
package Common_old.UI.Editor;
|
||||
import _VisualDVM.Global;
|
||||
import Common.Utils.CommonUtils;
|
||||
import ProjectData.Files.UI.Editor.SPFEditor;
|
||||
import org.fife.ui.rsyntaxtextarea.RSyntaxTextArea;
|
||||
public class CaretInfo {
|
||||
@@ -22,7 +22,7 @@ public class CaretInfo {
|
||||
prefix_word = SPFEditor.getLastWord(before, ' ', ',', ':', '.', '(', ')');
|
||||
suffix_word = SPFEditor.getFirstWord(after, ' ', ',', ':', '.', '(', ')');
|
||||
} catch (Exception ex) {
|
||||
Global.Log.PrintException(ex);
|
||||
CommonUtils.MainLog.PrintException(ex);
|
||||
}
|
||||
}
|
||||
public CaretInfo() {
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
package Common_old.UI.Menus;
|
||||
import Common.Utils.CommonUtils;
|
||||
import Common_old.Current;
|
||||
import _VisualDVM.Global;
|
||||
import Visual_DVM_2021.Passes.PassCode_2021;
|
||||
import Visual_DVM_2021.Passes.Pass_2021;
|
||||
|
||||
@@ -21,7 +21,7 @@ public class AttachementsMenu extends StyledPopupMenu {
|
||||
try {
|
||||
Desktop.getDesktop().open(Current.getProject().getAttachmentsDirectory());
|
||||
} catch (Exception ex) {
|
||||
Global.Log.PrintException(ex);
|
||||
CommonUtils.MainLog.PrintException(ex);
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
package Common_old.UI.Menus;
|
||||
import Common.Utils.CommonUtils;
|
||||
import Common_old.Current;
|
||||
import _VisualDVM.Global;
|
||||
import Common_old.UI.Editor.CaretInfo;
|
||||
import Common_old.Utils.Utils;
|
||||
import ProjectData.Files.DBProjectFile;
|
||||
@@ -85,7 +84,7 @@ public class MainEditorMenu extends TextEditorMenu {
|
||||
1
|
||||
);
|
||||
} catch (Exception ex) {
|
||||
Global.Log.PrintException(ex);
|
||||
CommonUtils.MainLog.PrintException(ex);
|
||||
}
|
||||
}
|
||||
});
|
||||
@@ -102,7 +101,7 @@ public class MainEditorMenu extends TextEditorMenu {
|
||||
0
|
||||
);
|
||||
} catch (Exception ex) {
|
||||
Global.Log.PrintException(ex);
|
||||
CommonUtils.MainLog.PrintException(ex);
|
||||
}
|
||||
}
|
||||
});
|
||||
@@ -190,7 +189,7 @@ public class MainEditorMenu extends TextEditorMenu {
|
||||
try {
|
||||
Current.getSapfor().UpdateProjectFiles(false);
|
||||
} catch (Exception ex) {
|
||||
Global.Log.PrintException(ex);
|
||||
CommonUtils.MainLog.PrintException(ex);
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
@@ -35,7 +35,7 @@ public class ProjectFilesMenu extends GraphMenu {
|
||||
try {
|
||||
Desktop.getDesktop().open(Current.getProject().Home);
|
||||
} catch (Exception ex) {
|
||||
Global.Log.PrintException(ex);
|
||||
CommonUtils.MainLog.PrintException(ex);
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
package Common_old.UI.Menus;
|
||||
import Common.CommonConstants;
|
||||
import Common_old.Utils.Utils;
|
||||
import Common.Utils.CommonUtils;
|
||||
|
||||
import javax.swing.*;
|
||||
public class TableMenu extends StyledPopupMenu {
|
||||
@@ -14,7 +14,7 @@ public class TableMenu extends StyledPopupMenu {
|
||||
owner = owner_in;
|
||||
mcopy = new VisualiserMenuItem("Копировать текст текущей ячейки", "/icons/Editor/Copy.png");
|
||||
//если удалось нажать значит все условия выполнены
|
||||
mcopy.addActionListener(e -> Utils.CopyToClipboard(target.toString()));
|
||||
mcopy.addActionListener(e -> CommonUtils.CopyToClipboard(target.toString()));
|
||||
add(mcopy);
|
||||
}
|
||||
@Override
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
package Common_old.UI.Menus;
|
||||
import Common.Utils.CommonUtils;
|
||||
import Common.Visual.CommonUI;
|
||||
import Common_old.Utils.Utils;
|
||||
|
||||
import javax.swing.*;
|
||||
import java.awt.event.ActionEvent;
|
||||
@@ -18,7 +18,7 @@ public class TextComboBoxMenu extends StyledPopupMenu {
|
||||
new AbstractAction() {
|
||||
@Override
|
||||
public void actionPerformed(ActionEvent e) {
|
||||
Utils.CopyToClipboard(box.getSelectedItem().toString());
|
||||
CommonUtils.CopyToClipboard(box.getSelectedItem().toString());
|
||||
}
|
||||
});
|
||||
add(m_copy);
|
||||
@@ -27,7 +27,7 @@ public class TextComboBoxMenu extends StyledPopupMenu {
|
||||
new AbstractAction() {
|
||||
@Override
|
||||
public void actionPerformed(ActionEvent e) {
|
||||
CommonUI.TrySelect(box, Utils.getFromClipboard());
|
||||
CommonUI.TrySelect(box, CommonUtils.getFromClipboard());
|
||||
}
|
||||
});
|
||||
add(m_paste);
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
package Common_old.UI.Menus;
|
||||
import Common_old.Utils.Utils;
|
||||
import Common.Utils.CommonUtils;
|
||||
|
||||
import javax.swing.*;
|
||||
import javax.swing.text.JTextComponent;
|
||||
@@ -52,7 +52,7 @@ public class TextEditorMenu extends StyledPopupMenu {
|
||||
String[] data = selectedText.split("\n");
|
||||
Vector<String> new_data = new Vector<>();
|
||||
for (String line: data){
|
||||
new_data.add(Utils.strikeThrough(line));
|
||||
new_data.add(CommonUtils.strikeThrough(line));
|
||||
}
|
||||
editor.replaceSelection(String.join("\n", new_data));
|
||||
}
|
||||
@@ -66,7 +66,7 @@ public class TextEditorMenu extends StyledPopupMenu {
|
||||
String[] data = selectedText.split("\n");
|
||||
Vector<String> new_data = new Vector<>();
|
||||
for (String line: data){
|
||||
new_data.add(Utils.noStrikeThrough(line));
|
||||
new_data.add(CommonUtils.noStrikeThrough(line));
|
||||
}
|
||||
editor.replaceSelection(String.join("\n", new_data));
|
||||
}
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
package Common_old.UI.Menus_2023.MainMenuBar.VisualiserSettingsMenu;
|
||||
import Common.Utils.CommonUtils;
|
||||
import _VisualDVM.Global;
|
||||
import Common_old.UI.Menus.PropertiesSubmenu;
|
||||
import Common_old.UI.Menus_2023.SettingsSubmenu;
|
||||
@@ -14,7 +15,7 @@ public class VisualiserSettingsMenu extends VisualiserMenu {
|
||||
"FocusPassesResult"
|
||||
));
|
||||
add(new CompactnessSettingsMenu());
|
||||
if (Global.isWindows) {
|
||||
if (CommonUtils.isWindows) {
|
||||
add(new SettingsSubmenu("Компиляция на локальной машине", null,
|
||||
SettingName.LocalMakePathWindows,
|
||||
SettingName.Kernels
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
package Common_old.UI.Tables;
|
||||
import Common_old.Utils.Utils;
|
||||
import Common.Utils.CommonUtils;
|
||||
|
||||
import javax.swing.*;
|
||||
import java.util.Date;
|
||||
@@ -13,6 +13,6 @@ public class DateRenderer_ extends RendererCell<Date> {
|
||||
@Override
|
||||
public void Display() {
|
||||
if (value != null)
|
||||
setText(value.equals(zero) ? "нет" : Utils.print_date(value));
|
||||
setText(value.equals(zero) ? "нет" : CommonUtils.print_date(value));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
package Common_old.UI.Trees;
|
||||
import Common.Utils.CommonUtils;
|
||||
import Common_old.Current;
|
||||
import _VisualDVM.Global;
|
||||
import Common_old.UI.DataControl_OLD;
|
||||
|
||||
import javax.swing.tree.DefaultMutableTreeNode;
|
||||
@@ -25,7 +25,7 @@ public class DataTree extends StyledTree implements DataControl_OLD {
|
||||
try {
|
||||
ShowCurrentObject();
|
||||
} catch (Exception ex) {
|
||||
Global.Log.PrintException(ex);
|
||||
CommonUtils.MainLog.PrintException(ex);
|
||||
}
|
||||
}
|
||||
public void SelectNodeByCriteria(Object criteria) {
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
package Common_old.UI;
|
||||
import Common.Utils.CommonUtils;
|
||||
import Common_old.Current;
|
||||
import Common_old.UI.Menus_2023.CredentialsBar.CredentialsBar;
|
||||
import Common.Visual.DataMenuBar;
|
||||
@@ -13,7 +14,6 @@ import Common_old.UI.Trees.GraphTreeCellRenderer;
|
||||
import Common_old.UI.Trees.SelectionTreeCellRenderer;
|
||||
import Common_old.UI.Windows.FormType;
|
||||
import Common_old.UI.Windows.SearchReplaceForm;
|
||||
import Common_old.Utils.Utils;
|
||||
import Common.Database.Tables.DataSet;
|
||||
import Common.Visual.CommonUI;
|
||||
import GlobalData.Compiler.CompilersDBTable;
|
||||
@@ -329,12 +329,12 @@ public class UI {
|
||||
return Question(getFrontWindow(), text);
|
||||
}
|
||||
public static void Info(String message) {
|
||||
Utils.CopyToClipboard(message);
|
||||
CommonUtils.CopyToClipboard(message);
|
||||
if (Current.hasUI())
|
||||
JOptionPane.showMessageDialog(getFrontWindow(), message, "", 1);
|
||||
}
|
||||
public static void Error(String message) {
|
||||
Utils.CopyToClipboard(message);
|
||||
CommonUtils.CopyToClipboard(message);
|
||||
if (Current.hasUI())
|
||||
JOptionPane.showMessageDialog(getFrontWindow(), message, "", 0);
|
||||
}
|
||||
|
||||
@@ -2,7 +2,6 @@ package Common_old.UI.Windows.Dialog;
|
||||
import Common.Utils.CommonUtils;
|
||||
import Common.Visual.CommonUI;
|
||||
import Common_old.Current;
|
||||
import _VisualDVM.Global;
|
||||
import _VisualDVM.Syntax.ThemeElement;
|
||||
import _VisualDVM.Syntax.VisualiserFonts;
|
||||
import Common_old.UI.UI;
|
||||
@@ -68,7 +67,7 @@ public class Dialog<T, F extends DialogFields> extends JDialog implements ThemeE
|
||||
content = (fields = f.newInstance()).getContent();
|
||||
//--?
|
||||
} catch (Exception e) {
|
||||
Global.Log.PrintException(e);
|
||||
CommonUtils.MainLog.PrintException(e);
|
||||
}
|
||||
}
|
||||
public void onClose() {
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
package Common_old.UI.Windows;
|
||||
import Common.Utils.CommonUtils;
|
||||
import _VisualDVM.Global;
|
||||
import _VisualDVM.Syntax.ThemeElement;
|
||||
import GlobalData.FormsParams.DBForm;
|
||||
@@ -13,7 +14,7 @@ public abstract class Form extends JFrame implements ThemeElement {
|
||||
public Form() {
|
||||
if (getIconName().length() > 0) setIconImage(new ImageIcon(Form.class.getResource(getIconName())).getImage());
|
||||
SetListener();
|
||||
this.setTitle(Global.isWindows ? getWTitleText() : getUTitleText());
|
||||
this.setTitle(CommonUtils.isWindows ? getWTitleText() : getUTitleText());
|
||||
pack();
|
||||
setMinimumSize(new Dimension(getDefaultWidth(), getDefaultHeight()));
|
||||
}
|
||||
@@ -55,7 +56,7 @@ public abstract class Form extends JFrame implements ThemeElement {
|
||||
try {
|
||||
LoadWindowParameters();
|
||||
} catch (Exception e) {
|
||||
Global.Log.PrintException(e);
|
||||
CommonUtils.MainLog.PrintException(e);
|
||||
}
|
||||
setContentPane(getMainPanel());
|
||||
setVisible(true);
|
||||
@@ -64,7 +65,7 @@ public abstract class Form extends JFrame implements ThemeElement {
|
||||
try {
|
||||
SaveWindowParameters();
|
||||
} catch (Exception e) {
|
||||
Global.Log.PrintException(e);
|
||||
CommonUtils.MainLog.PrintException(e);
|
||||
}
|
||||
setVisible(false);
|
||||
dispose();
|
||||
|
||||
Reference in New Issue
Block a user