1 42 43 package org.jfree.ui.tabbedui; 44 45 import javax.swing.JComponent ; 46 47 52 public abstract class RootPanel extends JComponent implements RootEditor { 53 54 55 private boolean active; 56 57 60 public RootPanel() { 61 } 63 64 69 public final boolean isActive() { 70 return this.active; 71 } 72 73 76 protected void panelActivated() 77 { 78 } 79 80 83 protected void panelDeactivated() 84 { 85 } 86 87 92 public final void setActive(final boolean active) { 93 if (this.active == active) { 94 return; 95 } 96 this.active = active; 97 if (active) { 98 panelActivated(); 99 } 100 else { 101 panelDeactivated(); 102 } 103 } 104 105 111 public JComponent getMainPanel() { 112 return this; 113 } 114 115 121 public JComponent getToolbar() { 122 return null; 123 } 124 125 126 } 127 | Popular Tags |