public class ExpandHelper extends Object implements Gefingerpoken
Modifier and Type | Class and Description |
---|---|
static interface |
ExpandHelper.Callback |
Modifier and Type | Field and Description |
---|---|
protected static boolean |
DEBUG |
protected static boolean |
DEBUG_SCALE |
Constructor and Description |
---|
ExpandHelper(Context context,
ExpandHelper.Callback callback,
int small,
int large)
Handle expansion gestures to expand and contract children of the callback.
|
Modifier and Type | Method and Description |
---|---|
void |
cancel()
Use this to abort any pending expansions in progress.
|
boolean |
onInterceptTouchEvent(MotionEvent ev) |
void |
onlyObserveMovements(boolean onlyMovements)
Change the expansion mode to only observe movements and don't perform any resizing.
|
boolean |
onTouchEvent(MotionEvent ev) |
void |
setEnabled(boolean enable) |
void |
setEventSource(View eventSource) |
void |
setGravity(int gravity) |
void |
setScrollAdapter(ScrollAdapter adapter) |
protected static final boolean DEBUG
protected static final boolean DEBUG_SCALE
public ExpandHelper(Context context, ExpandHelper.Callback callback, int small, int large)
context
- application contextcallback
- the container that holds the items to be manipulatedsmall
- the smallest allowable size for the manuipulated items.large
- the largest allowable size for the manuipulated items.public void setEventSource(View eventSource)
public void setGravity(int gravity)
public void setScrollAdapter(ScrollAdapter adapter)
public boolean onInterceptTouchEvent(MotionEvent ev)
onInterceptTouchEvent
in interface Gefingerpoken
public void setEnabled(boolean enable)
public boolean onTouchEvent(MotionEvent ev)
onTouchEvent
in interface Gefingerpoken
public void cancel()
public void onlyObserveMovements(boolean onlyMovements)
onlyMovements
- Should only movements be observed?