1
2
3 package org.catacomb.druid.gui.base;
4
5
6
7 public class DruCollapsiblePanel extends DruPanel {
8 static final long serialVersionUID = 1001;
9
10
11 DruPanel contentPanel;
12 boolean collapsed;
13
14
15 public DruCollapsiblePanel() {
16 super();
17 }
18
19
20 public void addContentPanel(DruPanel drup) {
21 contentPanel = drup;
22
23 collapsed = true;
24 }
25
26 public void collapse() {
27 if (collapsed) {
28
29 } else {
30 removePanel(contentPanel);
31 collapsed = true;
32 }
33 }
34
35 public void expand() {
36 if (collapsed) {
37 addPanel(contentPanel);
38 collapsed = false;
39 } else {
40
41 }
42 }
43
44
45
46 }
47
48
49
50
51
52
53
54