git://source.jalview.org
/
jalview.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
JAL-2668 add tests for HMMER commands, annotation and io
[jalview.git]
/
src
/
jalview
/
gui
/
Desktop.java
diff --git
a/src/jalview/gui/Desktop.java
b/src/jalview/gui/Desktop.java
index
b8f8399
..
63d88a0
100644
(file)
--- a/
src/jalview/gui/Desktop.java
+++ b/
src/jalview/gui/Desktop.java
@@
-129,6
+129,10
@@
public class Desktop extends jalview.jbgui.GDesktop implements
DropTargetListener, ClipboardOwner, IProgressIndicator,
jalview.api.StructureSelectionManagerProvider
{
DropTargetListener, ClipboardOwner, IProgressIndicator,
jalview.api.StructureSelectionManagerProvider
{
+ private static int DEFAULT_MIN_WIDTH = 300;
+
+ private static int DEFAULT_MIN_HEIGHT = 250;
+
private static final String EXPERIMENTAL_FEATURES = "EXPERIMENTAL_FEATURES";
private JalviewChangeSupport changeSupport = new JalviewChangeSupport();
private static final String EXPERIMENTAL_FEATURES = "EXPERIMENTAL_FEATURES";
private JalviewChangeSupport changeSupport = new JalviewChangeSupport();
@@
-745,7
+749,7
@@
public class Desktop extends jalview.jbgui.GDesktop implements
public static synchronized void addInternalFrame(
final JInternalFrame frame, String title, int w, int h)
{
public static synchronized void addInternalFrame(
final JInternalFrame frame, String title, int w, int h)
{
- addInternalFrame(frame, title, true, w, h, true);
+ addInternalFrame(frame, title, true, w, h, true, false);
}
/**
}
/**
@@
-767,7
+771,7
@@
public class Desktop extends jalview.jbgui.GDesktop implements
final JInternalFrame frame, String title, boolean makeVisible,
int w, int h)
{
final JInternalFrame frame, String title, boolean makeVisible,
int w, int h)
{
- addInternalFrame(frame, title, makeVisible, w, h, true);
+ addInternalFrame(frame, title, makeVisible, w, h, true, false);
}
/**
}
/**
@@
-788,7
+792,7
@@
public class Desktop extends jalview.jbgui.GDesktop implements
final JInternalFrame frame, String title, int w, int h,
boolean resizable)
{
final JInternalFrame frame, String title, int w, int h,
boolean resizable)
{
- addInternalFrame(frame, title, true, w, h, resizable);
+ addInternalFrame(frame, title, true, w, h, resizable, false);
}
/**
}
/**
@@
-807,10
+811,12
@@
public class Desktop extends jalview.jbgui.GDesktop implements
* height
* @param resizable
* Allow resize
* height
* @param resizable
* Allow resize
+ * @param ignoreMinSize
+ * Do not set the default minimum size for frame
*/
public static synchronized void addInternalFrame(
final JInternalFrame frame, String title, boolean makeVisible,
*/
public static synchronized void addInternalFrame(
final JInternalFrame frame, String title, boolean makeVisible,
- int w, int h, boolean resizable)
+ int w, int h, boolean resizable, boolean ignoreMinSize)
{
// TODO: allow callers to determine X and Y position of frame (eg. via
{
// TODO: allow callers to determine X and Y position of frame (eg. via
@@
-836,6
+842,11
@@
public class Desktop extends jalview.jbgui.GDesktop implements
openFrameCount++;
openFrameCount++;
+ if (!ignoreMinSize)
+ {
+ frame.setMinimumSize(new Dimension(DEFAULT_MIN_WIDTH,
+ DEFAULT_MIN_HEIGHT));
+ }
frame.setVisible(makeVisible);
frame.setClosable(true);
frame.setResizable(resizable);
frame.setVisible(makeVisible);
frame.setClosable(true);
frame.setResizable(resizable);