bibliothek.extension.gui.dock.theme.eclipse
Class EclipseFocusTraversalPolicy

java.lang.Object
  extended by bibliothek.extension.gui.dock.theme.eclipse.EclipseFocusTraversalPolicy
All Implemented Interfaces:
SimplifiedFocusTraversalPolicy

public class EclipseFocusTraversalPolicy
extends Object
implements SimplifiedFocusTraversalPolicy

A policy observing an EclipseStackDockComponent, ensures that either a Dockable, a tab or its actions are selected.

Author:
Benjamin Sigg

Constructor Summary
EclipseFocusTraversalPolicy(EclipseStackDockComponent stack)
          Creates a new traversal policy.
 
Method Summary
 Component getAfter(Container container, Component component)
          Gets the Component which should be focused next.
 Component getBefore(Container container, Component component)
          Gets the Component which should be focused when stepping through the circle backwards.
 Component getDefault(Container container)
          Gets the Component which should be focused per default.
 Component getFirst(Container container)
          Gets the Component which should be focused when entering the circle.
 Component getLast(Container container)
          Gets the Component which should be focused when entering the circle backwards.
protected  Component[] list()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

EclipseFocusTraversalPolicy

public EclipseFocusTraversalPolicy(EclipseStackDockComponent stack)
Creates a new traversal policy.

Parameters:
stack - the component for which this policy will be used.
Method Detail

list

protected Component[] list()

getAfter

public Component getAfter(Container container,
                          Component component)
Description copied from interface: SimplifiedFocusTraversalPolicy
Gets the Component which should be focused next.

Specified by:
getAfter in interface SimplifiedFocusTraversalPolicy
Parameters:
container - the root or provider of this policy
component - the currently focused component
Returns:
the next component or null

getBefore

public Component getBefore(Container container,
                           Component component)
Description copied from interface: SimplifiedFocusTraversalPolicy
Gets the Component which should be focused when stepping through the circle backwards.

Specified by:
getBefore in interface SimplifiedFocusTraversalPolicy
Parameters:
container - the root or provider of this policy
component - the currently focused component
Returns:
the previous component or null

getDefault

public Component getDefault(Container container)
Description copied from interface: SimplifiedFocusTraversalPolicy
Gets the Component which should be focused per default.

Specified by:
getDefault in interface SimplifiedFocusTraversalPolicy
Parameters:
container - the root or provider of this policy
Returns:
the default component or null

getFirst

public Component getFirst(Container container)
Description copied from interface: SimplifiedFocusTraversalPolicy
Gets the Component which should be focused when entering the circle.

Specified by:
getFirst in interface SimplifiedFocusTraversalPolicy
Parameters:
container - the root or provider of this policy
Returns:
the next component or null

getLast

public Component getLast(Container container)
Description copied from interface: SimplifiedFocusTraversalPolicy
Gets the Component which should be focused when entering the circle backwards.

Specified by:
getLast in interface SimplifiedFocusTraversalPolicy
Parameters:
container - the root or provider of this policy
Returns:
the next component or null