|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjava.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.JPanel
edu.rice.cs.drjava.ui.TabbedPanel
edu.rice.cs.drjava.ui.RegionsListPanel<R>
public abstract class RegionsListPanel<R extends IDocumentRegion>
Panel for displaying regions in a list in the order specified by indices passes to addRegion. This class is a swing view class and hence should only be accessed from the event-handling thread. Not currently used because BrowserHistoryPanel is not used.
| Nested Class Summary | |
|---|---|
protected static class |
RegionsListPanel.RegionListUserObj<R extends IDocumentRegion>
Class that gets put into the list. |
protected class |
RegionsListPanel.RegionMouseAdapter
Mouse adapter for the region tree. |
| Nested classes/interfaces inherited from class javax.swing.JPanel |
|---|
JPanel.AccessibleJPanel |
| Nested classes/interfaces inherited from class javax.swing.JComponent |
|---|
JComponent.AccessibleJComponent |
| Nested classes/interfaces inherited from class java.awt.Container |
|---|
Container.AccessibleAWTContainer |
| Nested classes/interfaces inherited from class java.awt.Component |
|---|
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy |
| Field Summary | |
|---|---|
protected JPanel |
_buttonPanel
|
protected MainFrame |
_frame
|
protected JPanel |
_leftPane
|
protected JList |
_list
|
protected DefaultListModel |
_listModel
|
protected SingleDisplayModel |
_model
|
protected String |
_title
|
| Fields inherited from class edu.rice.cs.drjava.ui.TabbedPanel |
|---|
_closeButton, _closePanel, _displayed, _mainPanel |
| Fields inherited from class javax.swing.JComponent |
|---|
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW |
| Fields inherited from class java.awt.Component |
|---|
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT |
| Fields inherited from interface java.awt.image.ImageObserver |
|---|
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
| Constructor Summary | |
|---|---|
RegionsListPanel(MainFrame frame,
String title)
Constructs a new panel to display regions in a list. |
|
| Method Summary | |
|---|---|
protected void |
_close()
Close the pane. |
void |
addRegion(R r,
int index)
Add a region to the list. |
protected ArrayList<R> |
getSelectedRegions()
Gets the currently selected regions in the region list, or an empty array if no regions are selected. |
protected RegionsListPanel.RegionListUserObj<R> |
getUserObjForRegion(R r)
|
protected void |
goToRegion()
Go to region. |
protected JComponent[] |
makeButtons()
Creates the buttons for controlling the regions. |
protected RegionsListPanel.RegionListUserObj<R> |
makeRegionListUserObj(R r)
Factory method to create user objects put in the list. |
protected void |
performDefaultAction()
Action performed when the Enter key is pressed. |
void |
removeRegion(R r)
Remove a region from the tree. |
protected void |
updateButtons()
Update button state and text. |
| Methods inherited from class edu.rice.cs.drjava.ui.TabbedPanel |
|---|
addCloseListener, dragEnter, dragExit, dragOver, drop, dropActionChanged, getName, isDisplayed, requestFocusInWindow, setDisplayed, setVisible |
| Methods inherited from class javax.swing.JPanel |
|---|
getAccessibleContext, getUI, getUIClassID, paramString, setUI, updateUI |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
protected JPanel _leftPane
protected JList _list
protected DefaultListModel _listModel
protected String _title
protected final SingleDisplayModel _model
protected final MainFrame _frame
protected JPanel _buttonPanel
| Constructor Detail |
|---|
public RegionsListPanel(MainFrame frame,
String title)
frame - the MainFrametitle - title of the pane| Method Detail |
|---|
protected void _close()
_close in class TabbedPanelprotected void updateButtons()
protected void performDefaultAction()
protected JComponent[] makeButtons()
protected ArrayList<R> getSelectedRegions()
protected void goToRegion()
protected RegionsListPanel.RegionListUserObj<R> getUserObjForRegion(R r)
public void addRegion(R r,
int index)
r - the regionindex - the index where the region should be insertedpublic void removeRegion(R r)
r - the regionprotected RegionsListPanel.RegionListUserObj<R> makeRegionListUserObj(R r)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||