Skip to content
Snippets Groups Projects
Commit 47f0d62f authored by Dominique Blouin's avatar Dominique Blouin
Browse files

Provide API to limit dialog boxes sizes to the size of the screen + cleanup

parent 122b8133
No related branches found
No related tags found
No related merge requests found
...@@ -47,18 +47,16 @@ knowledge of the CeCILL license and that you accept its terms. ...@@ -47,18 +47,16 @@ knowledge of the CeCILL license and that you accept its terms.
package ui.tmlsd; package ui.tmlsd;
import java.awt.*; import javax.swing.JFrame;
import javax.swing.*;
import org.w3c.dom.*;
import java.awt.event.*;
import java.util.*;
import myutil.*; import myutil.GraphicLib;
import ui.*; import ui.IconManager;
import ui.tmldd.*; import ui.SwallowTGComponent;
import ui.window.*; import ui.TAttribute;
import ui.TDiagramPanel;
import tmltranslator.tmlcp.*; import ui.TGComponent;
import ui.TGComponentManager;
import ui.window.JDialogTMLCPStorageInstance;
public class TMLSDStorageInstance extends TMLSDInstance implements SwallowTGComponent { public class TMLSDStorageInstance extends TMLSDInstance implements SwallowTGComponent {
...@@ -94,13 +92,12 @@ public class TMLSDStorageInstance extends TMLSDInstance implements SwallowTGComp ...@@ -94,13 +92,12 @@ public class TMLSDStorageInstance extends TMLSDInstance implements SwallowTGComp
} }
public boolean editOndoubleClick(JFrame frame) { public boolean editOndoubleClick(JFrame frame) {
JDialogTMLCPStorageInstance jdab = new JDialogTMLCPStorageInstance( myAttributes, null, frame, JDialogTMLCPStorageInstance jdab = new JDialogTMLCPStorageInstance( myAttributes, null, frame,
"Setting properties of " + name, "Attribute", name ); "Setting properties of " + name, "Attribute", name );
setJDialogOptions(jdab); setJDialogOptions(jdab);
jdab.setSize(650, 575); // jdab.setSize(650, 575);
GraphicLib.centerOnParent(jdab); GraphicLib.centerOnParent( jdab, 650, 575 );
jdab.setVisible(true); // blocked until dialog has been closed jdab.setVisible(true); // blocked until dialog has been closed
name = jdab.getName(); name = jdab.getName();
//makeValue(); //makeValue();
//if (oldValue.equals(value)) { //if (oldValue.equals(value)) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment