|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.tbee.swing.CarouselLayout
public class CarouselLayout
| Nested Class Summary | |
|---|---|
protected class |
CarouselLayout.CarouselPosition
|
| Field Summary | |
|---|---|
protected java.util.Hashtable<java.awt.Component,CarouselLayout.CarouselPosition> |
iAdditionalData
|
protected java.util.LinkedList<java.awt.Component> |
iComponents
|
protected int |
iNumberOfItems
|
protected double |
iRotationalOffset
|
protected double |
iTargetOffset
|
static java.lang.String |
SOURCECODE_VERSION
Standard variable for determining version of a class file. |
| Constructor Summary | |
|---|---|
CarouselLayout(java.awt.Container container)
|
|
| Method Summary | |
|---|---|
void |
actionPerformed(java.awt.event.ActionEvent actionEvent)
Manages timer actions, terminating the timer if any event is fully achieved |
void |
addLayoutComponent(java.lang.String name,
java.awt.Component comp)
Name is ignored |
void |
finalizeLayoutImmediately()
Moves everything to their "target" positions, without animating anything |
double |
getAngle()
Returns the current rotational angle |
java.awt.Component |
getFrontMostComponent()
|
java.awt.Component |
getNextAntiClockwise()
|
java.awt.Component |
getNextClockwise()
|
protected CarouselLayout.CarouselPosition |
getPosition(java.awt.Component comp)
Gets the additional data stored by the layout manager for a given component |
protected boolean |
isAnimating()
Determines if an animation is currently playing |
void |
layoutContainer(java.awt.Container target)
Lays out all of the components on the carousel. |
java.awt.Dimension |
minimumLayoutSize(java.awt.Container parent)
Cheats and bases it's size on the prefered sizes of each component |
java.awt.Dimension |
preferredLayoutSize(java.awt.Container parent)
Determine the widest and tallest dimensions, then return the height as 1.5 * the highest, and 3 * the widest |
protected void |
recalculateCarousel()
|
protected int |
recalculateVisibleItems()
|
void |
removeLayoutComponent(java.awt.Component comp)
Remove the component |
void |
setAngle(double d)
Sets the current rotational angle. |
void |
setFrontMostComponent(java.awt.Component component)
Moves the specified component to the front |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final java.lang.String SOURCECODE_VERSION
protected int iNumberOfItems
protected java.util.LinkedList<java.awt.Component> iComponents
protected java.util.Hashtable<java.awt.Component,CarouselLayout.CarouselPosition> iAdditionalData
protected double iRotationalOffset
protected double iTargetOffset
| Constructor Detail |
|---|
public CarouselLayout(java.awt.Container container)
container - | Method Detail |
|---|
public void addLayoutComponent(java.lang.String name,
java.awt.Component comp)
addLayoutComponent in interface java.awt.LayoutManagerpublic void removeLayoutComponent(java.awt.Component comp)
removeLayoutComponent in interface java.awt.LayoutManagerprotected CarouselLayout.CarouselPosition getPosition(java.awt.Component comp)
comp - The component you wish retreive the data for
protected int recalculateVisibleItems()
protected void recalculateCarousel()
public java.awt.Dimension minimumLayoutSize(java.awt.Container parent)
minimumLayoutSize in interface java.awt.LayoutManagerpublic java.awt.Dimension preferredLayoutSize(java.awt.Container parent)
preferredLayoutSize in interface java.awt.LayoutManagerparent - The container for the layoutpublic void layoutContainer(java.awt.Container target)
layoutContainer in interface java.awt.LayoutManagerpublic double getAngle()
public void setAngle(double d)
d - The desired angle in radiansprotected boolean isAnimating()
public void actionPerformed(java.awt.event.ActionEvent actionEvent)
actionPerformed in interface java.awt.event.ActionListeneractionEvent - the action event, although this will always be the timerpublic void finalizeLayoutImmediately()
public void setFrontMostComponent(java.awt.Component component)
component - The component move to the frontpublic java.awt.Component getFrontMostComponent()
public java.awt.Component getNextClockwise()
public java.awt.Component getNextAntiClockwise()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||