public class

WheelContainer

extends LinearLayout
implements WheelInterfaces.Views.WheelContainerInterface
java.lang.Object
   ↳ android.view.View
     ↳ android.view.ViewGroup
       ↳ android.widget.LinearLayout
         ↳ com.droidux.pack.wheel.widget.WheelContainer
Known Direct Subclasses

Class Overview

A container of wheel widgets.

Summary

XML Attributes
Attribute Name Related Method Description
dux_casingDrawable setCasingDrawable(int) Reference to a drawable resource to use as casing/cover for a wheel container. 
[Expand]
Inherited Constants
From class android.widget.LinearLayout
From class android.view.ViewGroup
From class android.view.View
[Expand]
Inherited Fields
From class android.view.View
Public Constructors
WheelContainer(Context context)
WheelContainer(Context context, AttributeSet attrs)
WheelContainer(Context context, AttributeSet attrs, int defStyle)
Public Methods
void addWheel(WheelInterfaces.Views.WheelSpinnerInterface wheel, int index, ViewGroup.LayoutParams params)
Adds a wheel view to this container with the specified layout parameters.
void setCasingDrawable(Drawable d)
Sets the drawable to be used as the casing/cover of the container.
void setCasingDrawable(int resId)
Sets the drawable to be used as the casing/cover of the container.
Protected Methods
void dispatchDraw(Canvas canvas)
Called by draw to draw the child views.
void onAttachedToWindow()
This is called when the view is attached to a window.
void onDetachedFromWindow()
This is called when the view is detached from a window.
void onSizeChanged(int w, int h, int oldw, int oldh)
This is called during layout when the size of this view has changed.
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.
[Expand]
Inherited Methods
From class android.widget.LinearLayout
From class android.view.ViewGroup
From class android.view.View
From class java.lang.Object
From interface android.graphics.drawable.Drawable.Callback
From interface android.view.KeyEvent.Callback
From interface android.view.ViewManager
From interface android.view.ViewParent
From interface android.view.accessibility.AccessibilityEventSource
From interface com.droidux.pack.wheel.interfaces.WheelInterfaces.Views.WheelContainerInterface

XML Attributes

dux_casingDrawable

Since: API Level

Reference to a drawable resource to use as casing/cover for a wheel container.

Must be a reference to another resource, in the form "@[+][package:]type:name" or to a theme attribute in the form "?[package:][type:]name".

Related Methods

Public Constructors

public WheelContainer (Context context)

Since: API Level 2.5

public WheelContainer (Context context, AttributeSet attrs)

Since: API Level 2.5

public WheelContainer (Context context, AttributeSet attrs, int defStyle)

Since: API Level 2.5

Public Methods

public void addWheel (WheelInterfaces.Views.WheelSpinnerInterface wheel, int index, ViewGroup.LayoutParams params)

Since: API Level 2.5

Adds a wheel view to this container with the specified layout parameters.

Parameters
wheel The wheel to add
index The position at which to add the wheel
params The layout parameters to set on the child

public void setCasingDrawable (Drawable d)

Since: API Level 2.5

Sets the drawable to be used as the casing/cover of the container.

Related XML Attributes
Parameters
d The casing drawable.

public void setCasingDrawable (int resId)

Since: API Level 2.5

Sets the drawable to be used as the casing/cover of the container.

Related XML Attributes
Parameters
resId The casing drawable resource id.

Protected Methods

protected void dispatchDraw (Canvas canvas)

Since: API Level

Called by draw to draw the child views. This may be overridden by derived classes to gain control just before its children are drawn (but after its own view has been drawn).

Parameters
canvas the canvas on which to draw the view

protected void onAttachedToWindow ()

Since: API Level

This is called when the view is attached to a window. At this point it has a Surface and will start drawing. Note that this function is guaranteed to be called before onDraw(android.graphics.Canvas), however it may be called any time before the first onDraw -- including before or after onMeasure(int, int).

protected void onDetachedFromWindow ()

Since: API Level

This is called when the view is detached from a window. At this point it no longer has a surface for drawing.

protected void onSizeChanged (int w, int h, int oldw, int oldh)

Since: API Level

This is called during layout when the size of this view has changed. If you were just added to the view hierarchy, you're called with the old values of 0.

Parameters
w Current width of this view.
h Current height of this view.
oldw Old width of this view.
oldh Old height of this view.

protected boolean verifyDrawable (Drawable who)

Since: API Level

If your view subclass is displaying its own Drawable objects, it should override this function and return true for any Drawable it is displaying. This allows animations for those drawables to be scheduled.

Be sure to call through to the super class when overriding this function.

Parameters
who The Drawable to verify. Return true if it is one you are displaying, else return the result of calling through to the super class.
Returns
  • boolean If true than the Drawable is being displayed in the view; else false and it is not allowed to animate.