|
|
@ -29,6 +29,7 @@ public class UIResizableContainer extends JPanel { |
|
|
|
private VerticalToolPane verticalToolPane; |
|
|
|
private VerticalToolPane verticalToolPane; |
|
|
|
|
|
|
|
|
|
|
|
private int direction; |
|
|
|
private int direction; |
|
|
|
|
|
|
|
private boolean hasParameterPane; |
|
|
|
|
|
|
|
|
|
|
|
private static final int MAX_WIDTH = 300; |
|
|
|
private static final int MAX_WIDTH = 300; |
|
|
|
private static final int MIN_WIDTH = 165; |
|
|
|
private static final int MIN_WIDTH = 165; |
|
|
@ -89,7 +90,6 @@ public class UIResizableContainer extends JPanel { |
|
|
|
add(horizontToolPane); |
|
|
|
add(horizontToolPane); |
|
|
|
add(downPane); |
|
|
|
add(downPane); |
|
|
|
add(verticalToolPane); |
|
|
|
add(verticalToolPane); |
|
|
|
add(parameterPane); |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
public UIResizableContainer(JComponent upPane, int direction) { |
|
|
|
public UIResizableContainer(JComponent upPane, int direction) { |
|
|
@ -102,7 +102,6 @@ public class UIResizableContainer extends JPanel { |
|
|
|
setLayout(containerLayout); |
|
|
|
setLayout(containerLayout); |
|
|
|
add(upPane); |
|
|
|
add(upPane); |
|
|
|
add(horizontToolPane); |
|
|
|
add(horizontToolPane); |
|
|
|
add(parameterPane); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
@ -141,7 +140,7 @@ public class UIResizableContainer extends JPanel { |
|
|
|
* @param height |
|
|
|
* @param height |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public void setParameterHeight(int height) { |
|
|
|
public void setParameterHeight(int height) { |
|
|
|
paraHeight = height; |
|
|
|
paraHeight = hasParameterPane? height : 0; |
|
|
|
refreshContainer(); |
|
|
|
refreshContainer(); |
|
|
|
|
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
@ -274,13 +273,18 @@ public class UIResizableContainer extends JPanel { |
|
|
|
|
|
|
|
|
|
|
|
public void addParameterPane(JComponent pane) { |
|
|
|
public void addParameterPane(JComponent pane) { |
|
|
|
add(this.parameterPane = pane); |
|
|
|
add(this.parameterPane = pane); |
|
|
|
|
|
|
|
hasParameterPane = true; |
|
|
|
refreshContainer(); |
|
|
|
refreshContainer(); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
public void removeParameterPane() { |
|
|
|
public void removeParameterPane() { |
|
|
|
remove(this.parameterPane); |
|
|
|
if (this.parameterPane != null) { |
|
|
|
setParameterHeight(0); |
|
|
|
this.remove(this.parameterPane); |
|
|
|
refreshContainer(); |
|
|
|
setParameterHeight(0); |
|
|
|
|
|
|
|
hasParameterPane = false; |
|
|
|
|
|
|
|
refreshContainer(); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|