org.pushingpixels.trident.swing
Class SwingRepaintCallback

java.lang.Object
  extended by org.pushingpixels.trident.callback.TimelineCallbackAdapter
      extended by org.pushingpixels.trident.swing.SwingRepaintCallback
All Implemented Interfaces:
TimelineCallback

public class SwingRepaintCallback
extends TimelineCallbackAdapter


Constructor Summary
SwingRepaintCallback(Component comp)
           
SwingRepaintCallback(Component comp, Rectangle rect)
           
 
Method Summary
 void forceRepaintOnNextPulse()
           
 void onTimelinePulse(float durationFraction, float timelinePosition)
          Indicates that the timeline pulse has happened.
 void onTimelineStateChanged(Timeline.TimelineState oldState, Timeline.TimelineState newState, float durationFraction, float timelinePosition)
          Indicates that the timeline state has changed.
 void setAutoRepaintMode(boolean autoRepaintMode)
           
 void setRepaintRectangle(Rectangle rect)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SwingRepaintCallback

public SwingRepaintCallback(Component comp)

SwingRepaintCallback

public SwingRepaintCallback(Component comp,
                            Rectangle rect)
Method Detail

setAutoRepaintMode

public void setAutoRepaintMode(boolean autoRepaintMode)

forceRepaintOnNextPulse

public void forceRepaintOnNextPulse()

setRepaintRectangle

public void setRepaintRectangle(Rectangle rect)

onTimelinePulse

public void onTimelinePulse(float durationFraction,
                            float timelinePosition)
Description copied from interface: TimelineCallback
Indicates that the timeline pulse has happened.

Specified by:
onTimelinePulse in interface TimelineCallback
Overrides:
onTimelinePulse in class TimelineCallbackAdapter
Parameters:
durationFraction - The current timeline duration fraction.Is guaranteed to be in 0.0-1.0 range. The rate of change of this value is linear, and the value is proportional to Timeline.setDuration(long).
timelinePosition - The current timeline position. Is guaranteed to be in 0.0-1.0 range. The rate of change of this value is not necessarily linear and is affected by the Timeline.setEase(org.pushingpixels.trident.ease.TimelineEase) .

onTimelineStateChanged

public void onTimelineStateChanged(Timeline.TimelineState oldState,
                                   Timeline.TimelineState newState,
                                   float durationFraction,
                                   float timelinePosition)
Description copied from interface: TimelineCallback
Indicates that the timeline state has changed.

Specified by:
onTimelineStateChanged in interface TimelineCallback
Overrides:
onTimelineStateChanged in class TimelineCallbackAdapter
Parameters:
oldState - The old timeline state.
newState - The new timeline state.
durationFraction - The current timeline duration fraction.Is guaranteed to be in 0.0-1.0 range. The rate of change of this value is linear, and the value is proportional to Timeline.setDuration(long).
timelinePosition - The current timeline position. Is guaranteed to be in 0.0-1.0 range. The rate of change of this value is not necessarily linear and is affected by the Timeline.setEase(org.pushingpixels.trident.ease.TimelineEase) .