|
Build 1.0_r1(from source) | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectandroid.view.View
android.widget.ProgressBar
android.widget.AbsSeekBar
public abstract class AbsSeekBar
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from class android.view.View |
|---|
View.BaseSavedState, View.MeasureSpec, View.OnClickListener, View.OnCreateContextMenuListener, View.OnFocusChangeListener, View.OnKeyListener, View.OnLongClickListener, View.OnTouchListener |
| Field Summary | |
|---|---|
(package private) float |
mDisabledAlpha
|
(package private) boolean |
mIsUserSeekable
Whether this is user seekable. |
(package private) float |
mTouchProgressOffset
On touch, this offset plus the scaled value from the position of the touch will form the progress value. |
| Fields inherited from class android.widget.ProgressBar |
|---|
mMaxHeight, mMaxWidth, mMinHeight, mMinWidth, mSampleTile |
| Constructor Summary | |
|---|---|
AbsSeekBar(Context context)
|
|
AbsSeekBar(Context context,
AttributeSet attrs)
|
|
AbsSeekBar(Context context,
AttributeSet attrs,
int defStyle)
|
|
| Method Summary | |
|---|---|
protected void |
drawableStateChanged()
This function is called whenever the state of the view changes in such a way that it impacts the state of drawables being shown. |
int |
getThumbOffset()
|
protected void |
onDraw(Canvas canvas)
Implement this to do your drawing. |
protected void |
onMeasure(int widthMeasureSpec,
int heightMeasureSpec)
Measure the view and its content to determine the measured width and the measured height. |
(package private) void |
onProgressRefresh(float scale,
boolean fromTouch)
|
protected void |
onSizeChanged(int w,
int h,
int oldw,
int oldh)
This is called during layout when the size of this view has changed. |
(package private) void |
onStartTrackingTouch()
This is called when the user has started touching this widget. |
(package private) void |
onStopTrackingTouch()
This is called when the user either releases his touch or the touch is canceled. |
boolean |
onTouchEvent(MotionEvent event)
Implement this method to handle touch screen motion events. |
void |
setThumb(Drawable thumb)
Sets the thumb that will be drawn at the end of the progress meter within the SeekBar |
void |
setThumbOffset(int thumbOffset)
Sets the thumb offset that allows the thumb to extend out of the range of the track. |
protected boolean |
verifyDrawable(Drawable who)
If your view subclass is displaying its own Drawable objects, it should override this function and return true for any Drawable it is displaying. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
float mTouchProgressOffset
boolean mIsUserSeekable
float mDisabledAlpha
| Constructor Detail |
|---|
public AbsSeekBar(Context context)
public AbsSeekBar(Context context,
AttributeSet attrs)
public AbsSeekBar(Context context,
AttributeSet attrs,
int defStyle)
| Method Detail |
|---|
public void setThumb(Drawable thumb)
thumb - Drawable representing the thumbpublic int getThumbOffset()
setThumbOffset(int)public void setThumbOffset(int thumbOffset)
thumbOffset - The offset amount in pixels.protected boolean verifyDrawable(Drawable who)
ViewBe sure to call through to the super class when overriding this function.
verifyDrawable in class ProgressBarwho - The Drawable to verify. Return true if it is one you are
displaying, else return the result of calling through to the
super class.
View.unscheduleDrawable(android.graphics.drawable.Drawable, java.lang.Runnable),
View.drawableStateChanged()protected void drawableStateChanged()
ViewBe sure to call through to the superclass when overriding this function.
drawableStateChanged in class ViewDrawable.setState(int[])
void onProgressRefresh(float scale,
boolean fromTouch)
onProgressRefresh in class ProgressBar
protected void onSizeChanged(int w,
int h,
int oldw,
int oldh)
View
onSizeChanged in class ProgressBarw - Current width of this view.h - Current height of this view.oldw - Old width of this view.oldh - Old height of this view.protected void onDraw(Canvas canvas)
View
onDraw in class ProgressBarcanvas - the canvas on which the background will be drawn
protected void onMeasure(int widthMeasureSpec,
int heightMeasureSpec)
View
Measure the view and its content to determine the measured width and the
measured height. This method is invoked by View.measure(int, int) and
should be overriden by subclasses to provide accurate and efficient
measurement of their contents.
CONTRACT: When overriding this method, you
must call View.setMeasuredDimension(int, int) to store the
measured width and height of this view. Failure to do so will trigger an
IllegalStateException, thrown by
View.measure(int, int). Calling the superclass'
View.onMeasure(int, int) is a valid use.
The base class implementation of measure defaults to the background size,
unless a larger size is allowed by the MeasureSpec. Subclasses should
override View.onMeasure(int, int) to provide better measurements of
their content.
If this method is overridden, it is the subclass's responsibility to make
sure the measured height and width are at least the view's minimum height
and width (View.getSuggestedMinimumHeight() and
View.getSuggestedMinimumWidth()).
onMeasure in class ProgressBarwidthMeasureSpec - horizontal space requirements as imposed by the parent.
The requirements are encoded with
View.MeasureSpec.heightMeasureSpec - vertical space requirements as imposed by the parent.
The requirements are encoded with
View.MeasureSpec.View.getMeasuredWidth(),
View.getMeasuredHeight(),
View.setMeasuredDimension(int, int),
View.getSuggestedMinimumHeight(),
View.getSuggestedMinimumWidth(),
View.MeasureSpec.getMode(int),
View.MeasureSpec.getSize(int)public boolean onTouchEvent(MotionEvent event)
View
onTouchEvent in class Viewevent - The motion event.
void onStartTrackingTouch()
void onStopTrackingTouch()
|
Build 1.0_r1(from source) | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||