|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectbibliothek.extension.gui.dock.theme.eclipse.rex.tab.DockTitleTab
public class DockTitleTab
A DockTitleTab
is a wrapper around an ordinary DockTitle
to get a TabComponent
.
This DockTitleTab
will use EclipseDockTitleEvent
s
to inform its DockTitle
when a property has changed, the
method DockTitle.changed(bibliothek.gui.dock.event.DockTitleEvent)
is called for that purpose.
Field Summary | |
---|---|
static TabPainter |
FACTORY
A TabPainter that uses the id EclipseTheme.TAB_DOCK_TITLE
to get a DockTitleVersion from the DockTitleManager
and create a new DockTitle which is then wrapped by a
DockTitleTab . |
Constructor Summary | |
---|---|
DockTitleTab(DockStation station,
Dockable dockable,
DockTitle title,
int index)
Creates a new tab. |
Method Summary | |
---|---|
void |
addMouseInputListener(MouseInputListener listener)
Adds a listener to this representative, it is not defined what to do with that listener, but most subclasses would just add the listener to their component . |
void |
addMouseListener(MouseListener listener)
|
void |
addMouseMotionListener(MouseMotionListener listener)
|
void |
bind()
Informs this tab that it will be shown soon |
static TabPainter |
createFactory(TabPainter fallback)
Creates a new factory which uses fallback to create
a TabComponent when no DockTitle is available. |
protected void |
fire()
Fires an event to the DockTitle of this DockTitleTab . |
Component |
getComponent()
Gets the Component which represents the element . |
Border |
getContentBorder()
|
DockElement |
getElement()
Gets the element which is represented by this . |
int |
getOverlap()
Gets the number of pixels which should be covered at the left side of this component by its left neighbour. |
Point |
getPopupLocation(Point click,
boolean popupTrigger)
Tells whether a popup menu should be opened when the user clicks at click with the mouse. |
void |
removeMouseInputListener(MouseInputListener listener)
Removes a listener from this representative. |
void |
removeMouseListener(MouseListener listener)
|
void |
removeMouseMotionListener(MouseMotionListener listener)
|
void |
setFocused(boolean focused)
|
void |
setIndex(int index)
|
void |
setPaintIconWhenInactive(boolean paint)
|
void |
setSelected(boolean selected)
|
void |
unbind()
Informs this tab that it is invisible and must not have any connections to other resources |
void |
update()
Called when a property of the tab has been changed and this component has to reevaluate its content. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final TabPainter FACTORY
TabPainter
that uses the id EclipseTheme.TAB_DOCK_TITLE
to get a DockTitleVersion
from the DockTitleManager
and create a new DockTitle
which is then wrapped by a
DockTitleTab
.
Constructor Detail |
---|
public DockTitleTab(DockStation station, Dockable dockable, DockTitle title, int index)
station
- the station which uses the tabbed pane, might be null
dockable
- the element for which this tab is showntitle
- the title which represents the tabindex
- the location of this tabMethod Detail |
---|
public static final TabPainter createFactory(TabPainter fallback)
fallback
to create
a TabComponent
when no DockTitle
is available.
fallback
- the backup-factory
TabPainter
public void bind()
TabComponent
bind
in interface TabComponent
public void unbind()
TabComponent
unbind
in interface TabComponent
public void addMouseListener(MouseListener listener)
addMouseListener
in interface TabComponent
public void addMouseMotionListener(MouseMotionListener listener)
addMouseMotionListener
in interface TabComponent
public Component getComponent()
DockElementRepresentative
Component
which represents the element
.
The result of this method must not change.
getComponent
in interface TabComponent
getComponent
in interface DockElementRepresentative
null
public DockElement getElement()
DockElementRepresentative
this
.
The result of this method must not change.
getElement
in interface DockElementRepresentative
null
public Point getPopupLocation(Point click, boolean popupTrigger)
DockElementRepresentative
click
with the mouse. If yes, then the top left edge
of the popup should be returned, otherwise null
should be
returned.
getPopupLocation
in interface DockElementRepresentative
click
- the location where the user clicked with the mousepopupTrigger
- whether the invocation is the systems popup trigger
or not. Many implementations of this method will return click
in case of true
, and null
in case of false
null
if no
popup-menu should be openedpublic void addMouseInputListener(MouseInputListener listener)
DockElementRepresentative
component
. It is valid to do nothing.
addMouseInputListener
in interface DockElementRepresentative
listener
- the new listenerpublic void removeMouseInputListener(MouseInputListener listener)
DockElementRepresentative
removeMouseInputListener
in interface DockElementRepresentative
listener
- the listener to removepublic Border getContentBorder()
getContentBorder
in interface TabComponent
public int getOverlap()
TabComponent
getOverlap
in interface TabComponent
public void removeMouseListener(MouseListener listener)
removeMouseListener
in interface TabComponent
public void removeMouseMotionListener(MouseMotionListener listener)
removeMouseMotionListener
in interface TabComponent
public void setFocused(boolean focused)
setFocused
in interface TabComponent
public void setIndex(int index)
setIndex
in interface TabComponent
public void setPaintIconWhenInactive(boolean paint)
setPaintIconWhenInactive
in interface TabComponent
public void setSelected(boolean selected)
setSelected
in interface TabComponent
public void update()
TabComponent
update
in interface TabComponent
protected void fire()
DockTitle
of this DockTitleTab
.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |