com.badlogic.gdx.scenes.scene2d.ui
Class FlickScrollPane
java.lang.Object
com.badlogic.gdx.scenes.scene2d.Actor
com.badlogic.gdx.scenes.scene2d.Group
com.badlogic.gdx.scenes.scene2d.ui.FlickScrollPane
- All Implemented Interfaces:
- Layout
public class FlickScrollPane
- extends Group
- implements Layout
- Author:
- Nathan Sweet, mzechner
Fields inherited from class com.badlogic.gdx.scenes.scene2d.Group |
batchTransform, children, debug, debugTexture, focusedActor, groups, immutableChildren, immutableGroups, keyboardFocusedActor, lastTouchedChild, localTransform, namesToActors, oldBatchTransform, scrollFocusedActor, transform, worldTransform |
Fields inherited from class com.badlogic.gdx.scenes.scene2d.Actor |
actions, color, height, name, originX, originY, parent, rotation, scaleX, scaleY, touchable, visible, width, x, y |
Methods inherited from class com.badlogic.gdx.scenes.scene2d.Group |
addActor, addActorAfter, addActorAt, addActorBefore, applyTransform, clear, disableDebugging, drawChild, drawChildren, enableDebugging, findActor, focus, getActors, getGroups, keyboardFocus, keyDown, keyTyped, keyUp, removeActor, removeActorRecursive, resetTransform, scrolled, scrollFocus, sortChildren, swapActor, swapActor, toChildCoordinates, touchMoved, unfocusAll, unfocusAll, updateTransform |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
needsLayout
protected boolean needsLayout
bounces
public boolean bounces
flingTime
public float flingTime
bounceDistance
public float bounceDistance
bounceSpeedMin
public float bounceSpeedMin
bounceSpeedMax
public float bounceSpeedMax
emptySpaceOnlyScroll
public boolean emptySpaceOnlyScroll
forceScrollX
public boolean forceScrollX
forceScrollY
public boolean forceScrollY
clamp
public boolean clamp
FlickScrollPane
public FlickScrollPane(Actor widget,
Stage stage)
FlickScrollPane
public FlickScrollPane(java.lang.String name,
Actor widget,
Stage stage,
int prefWidth,
int prefHeight)
act
public void act(float delta)
- Overrides:
act
in class Group
draw
public void draw(SpriteBatch batch,
float parentAlpha)
- Description copied from class:
Actor
- Draws the Actor. The spriteBatch is configured so that the Actor can draw in its parents coordinate system. The parent's
alpha is passed to the method in order for the Actor to multiply it with its own alpha. This will allow
FadeIn
and
other Actions to have an effect even if they are only set on the parent of the Actor.
- Overrides:
draw
in class Group
- Parameters:
batch
- the spritebatch to render withparentAlpha
- the parent's alpha value.
layout
public void layout()
- Description copied from interface:
Layout
- Positions and sizes each child of this actor. Subsequent calls will not have any affect unless
Layout.invalidate()
is
called.
- Specified by:
layout
in interface Layout
invalidate
public void invalidate()
- Description copied from interface:
Layout
- Invalidates the layout, forcing the next call to
Layout.layout()
to relayout. If an actor is resized or otherwise changed
in a way that affects its layout, Layout.invalidate()
should be called.
- Specified by:
invalidate
in interface Layout
getPrefWidth
public float getPrefWidth()
- Specified by:
getPrefWidth
in interface Layout
getPrefHeight
public float getPrefHeight()
- Specified by:
getPrefHeight
in interface Layout
touchDown
public boolean touchDown(float x,
float y,
int pointer)
- Overrides:
touchDown
in class Group
touchUp
public void touchUp(float x,
float y,
int pointer)
- Overrides:
touchUp
in class Group
touchDragged
public void touchDragged(float x,
float y,
int pointer)
- Overrides:
touchDragged
in class Group
hit
public Actor hit(float x,
float y)
- Overrides:
hit
in class Group
setScrollX
public void setScrollX(float pixels)
getScrollX
public float getScrollX()
setScrollY
public void setScrollY(float pixels)
getScrollY
public float getScrollY()
setWidget
public void setWidget(Actor widget)
- Sets the
Actor
embedded in this scroll pane.
- Parameters:
widget
- the Actor
getWidget
public Actor getWidget()
isPanning
public boolean isPanning()
getVelocityX
public float getVelocityX()
getVelocityY
public float getVelocityY()
Copyright 2010 Mario Zechner (contact@badlogicgames.com), Nathan Sweet (admin@esotericsoftware.com)