Titanium.UI.ActivityIndicator
> Titanium.UI.ActivityIndicator

An activity indicator that lets the user know an action is taking place.

AndroidiOSWindows Phone

An activity indicator can be used to show the progress of an operation in the UI to let the user know that some action is taking place. An activity indicator consists of a spinning animation and an optional text message, and is used to indicate an ongoing activity of indeterminate length. To show progress, use Titanium.UI.ProgressBar instead.

Use the Titanium.UI.createActivityIndicator method or <ActivityIndicator> Alloy element to create an ActivityIndicator object.

ActivityIndicator is a view and, like any view, must be added to a window or other top-level view before it can be shown. Unlike most views, ActivityIndicator is hidden by default and must be shown explicitly by calling its show method.

Android Platform Notes

Prior to SDK 3.0, activity indicator on Android produced a modal dialog containing a spinner or progress bar. In SDK 3.0, this legacy Android activity indicator was renamed to Titanium.UI.Android.ProgressIndicator.

In SDK 3.0, use ActivityIndicator for a view that can be added as a child of another view. Use ProgressIndicator to display a progress indicator in a modal dialog or window title bar.

Examples

Simple Activity Indicator

Open a yellow window immediately after a blue window. Show an activity indicator while some code executes and hide it on completion. Then close the yellow window.

Ti.UI.backgroundColor = 'white';

var win1 = Ti.UI.createWindow({
  backgroundColor: 'blue'
});

var win2 = Ti.UI.createWindow({
  backgroundColor: 'yellow',
  fullscreen: true
});

var activityIndicator = Ti.UI.createActivityIndicator({
  color: 'green',
  font: {fontFamily:'Helvetica Neue', fontSize:26, fontWeight:'bold'},
  message: 'Loading...',
  style: Ti.UI.ActivityIndicatorStyle.DARK,
  top:10,
  left:10,
  height:Ti.UI.SIZE,
  width:Ti.UI.SIZE
});

// The activity indicator must be added to a window or view for it to appear
win2.add(activityIndicator);

// eventListeners must always be loaded before the event is likely to fire
// hence, the open() method must be positioned before the window is opened
win2.addEventListener('open', function (e) {
  activityIndicator.show();
  // do some work that takes 6 seconds
  // ie. replace the following setTimeout block with your code
  setTimeout(function(){
    e.source.close();
    activityIndicator.hide();
  }, 6000);
});

win1.open();
win2.open();

Alloy XML Markup

Previous example as two Alloy views.

win1.xml:

<Alloy>
    <Window onOpen="openWin2" backgroundColor="blue" />
</Alloy>

win1.js:

function openWin2 () {
    var win2 = Alloy.createController('win2').getView();
    win2.open();
}

win2.xml:

<Alloy>
    <Window onOpen="showIndicator" fullscreen="true" backgroundColor="yellow">

        <!-- Define the styling properties in the TSS file -->
        <ActivityIndicator id="activityIndicator" message="Loading..."/>
    </Window>
</Alloy>

win2.js:

function showIndicator(e){
    $.activityIndicator.show();
    // do some work that takes 6 seconds
    // ie. replace the following setTimeout block with your code
    setTimeout(function(){
        e.source.close();
        $.activityIndicator.hide();
    }, 6000);
}
  • 0.8
  • 0.8
  • 0.8
Defined By

Properties

apiName : Stringreadonly

The name of the API that this proxy corresponds to.

The name of the API that this proxy corresponds to.

The value of this property is the fully qualified name of the API. For example, Button returns Ti.UI.Button.

  • 3.2.0
  • 3.2.0
  • 3.2.0
Titanium.UI.ActivityIndicator
bottom : Number/String

Bottom position of the view.

Bottom position of the view.

Determines the absolute position of the view relative to its parent.

Can be either a float value or a dimension string (for example 100 or '50%'.)

  • 0.9
  • 0.9
  • 0.9

Overrides: Titanium.UI.View.bottom

Indicates if the proxy will bubble an event to its parent. ...

Indicates if the proxy will bubble an event to its parent.

Some proxies (most commonly views) have a relationship to other proxies, often established by the add() method. For example, for a button added to a window, a click event on the button would bubble up to the window. Other common parents are table sections to their rows, table views to their sections, and scrollable views to their views. Set this property to false to disable the bubbling to the proxy's parent.

Default: true

  • 3.0.0
  • 3.0.0
  • 3.0.0
Titanium.UI.ActivityIndicator
color : String

Color of the message text, as a color name or hex triplet.

Color of the message text, as a color name or hex triplet.

For information about color values, see the "Colors" section of Titanium.UI.

Base elevation of the view relative to its parent in pixels. ...

Base elevation of the view relative to its parent in pixels.

Requires: Android 5 and later

The elevation of a view determines the appearance of its shadow. Higher elevations produce larger and softer shadows.

Note: The elevation property only works on Titanium.UI.View objects. Many Android components have a default elevation that cannot be modified. For more information, see Google design guidelines: Elevation and shadows.

  • 5.0.0
Titanium.UI.ActivityIndicator
font : Font

Font used for the message text.

Font used for the message text.

Titanium.UI.ActivityIndicator
: String
Width of the view. ...

Width of the view. Only accepts value of Titanium.UI.SIZE, which must be explicitly set in order to display the message and to position the view correctly.

Defaults to: If undefined, defaults to either Titanium.UI.FILL or Titanium.UI.SIZE depending on the view. See "View Types and Default Layout Behavior" in Transitioning to the New UI Layout System.

Can be either a float value or a dimension string (for example, '50%' or '40dp'). Can also be one of the following special values:

  • Titanium.UI.SIZE. The view should size itself to fit its contents.
  • Titanium.UI.FILL. The view should size itself to fill its parent.
  • 'auto'. Represents the default sizing behavior for a given type of view. The use of 'auto' is deprecated, and should be replaced with the SIZE or FILL constants if it is necessary to set the view's behavior explicitly.

This is an input property for specifying the view's height dimension. To determine the view's size once rendered, use the rect or size properties.

This API can be assigned the following constants:

  • 0.9
  • 0.9
  • 0.9

Overrides: Titanium.UI.View.height

Sets the behavior when hiding an object to release or keep the free space ...

Sets the behavior when hiding an object to release or keep the free space

If setting hiddenBehavior to Titanium.UI.HIDDEN_BEHAVIOR_GONE it will automatically release the space the view occupied. For example: in a vertical layout the views below the object will move up when you hide an object with hiddenBehavior:Titanium.UI.HIDDEN_BEHAVIOR_GONE.

This API can be assigned the following constants:

Default: Titanium.UI.HIDDEN_BEHAVIOR_INVISIBLE

  • 6.1.0
Titanium.UI.ActivityIndicator
: String
Color of the animated indicator. ...

Color of the animated indicator.

Default:

#fff
  • 2.1.0
  • 2.1.0
  • 2.1.0
Titanium.UI.ActivityIndicator
left : Number/String

Left position of the view.

Left position of the view.

Determines the absolute position of the view relative to its parent.

Can be either a float value or a dimension string (for example 100 or '50%'.)

  • 0.9
  • 0.9
  • 0.9

Overrides: Titanium.UI.View.left

The Window or TabGroup whose Activity lifecycle should be triggered on the proxy.

The Window or TabGroup whose Activity lifecycle should be triggered on the proxy.

If this property is set to a Window or TabGroup, then the corresponding Activity lifecycle event callbacks will also be called on the proxy. Proxies that require the activity lifecycle will need this property set to the appropriate containing Window or TabGroup.

  • 3.6.0
Titanium.UI.ActivityIndicator
message : String

Message text.

Message text.

Titanium.UI.ActivityIndicator
messageid : String

Key identifying a string in the locale file to use for the message text.

Key identifying a string in the locale file to use for the message text.

Only one of message or messageid should be specified.

The preview context used in the 3D-Touch feature "Peek and Pop". ...

The preview context used in the 3D-Touch feature "Peek and Pop".

Requires: iOS 9.0 and later

Preview context to present the "Peek and Pop" of a view. Use an configured instance of Titanium.UI.iOS.PreviewContext here.

Note: This property can only be used on devices running iOS9 or later and supporting 3D-Touch. It is ignored on older devices and can manually be checked using Titanium.UI.iOS.forceTouchSupported.

  • 5.1.0
Titanium.UI.ActivityIndicator
right : Number/String

Right position of the view.

Right position of the view.

Determines the absolute position of the view relative to its parent.

Can be either a float value or a dimension string (for example 100 or '50%'.)

  • 0.9
  • 0.9
  • 0.9

Overrides: Titanium.UI.View.right

Clockwise 2D rotation of the view in degrees.

Clockwise 2D rotation of the view in degrees.

Translation values are applied to the static post layout value.

  • 5.4.0

Clockwise rotation of the view in degrees (x-axis).

Clockwise rotation of the view in degrees (x-axis).

Translation values are applied to the static post layout value.

  • 5.4.0

Clockwise rotation of the view in degrees (y-axis).

Clockwise rotation of the view in degrees (y-axis).

Translation values are applied to the static post layout value.

  • 5.4.0

Scaling of the view in x-axis in pixels.

Scaling of the view in x-axis in pixels.

Translation values are applied to the static post layout value.

  • 5.4.0

Scaling of the view in y-axis in pixels.

Scaling of the view in y-axis in pixels.

Translation values are applied to the static post layout value.

  • 5.4.0
Titanium.UI.ActivityIndicator
: Number
The style for the activity indicator. ...

The style for the activity indicator.

One of the activity indicator style constants.

See also: indicatorColor, indicatorDiameter

This API can be assigned the following constants:

Default: Titanium.UI.ActivityIndicatorStyle.PLAIN

Titanium.UI.ActivityIndicator
top : Number/String

Top position of the view.

Top position of the view.

Determines the absolute position of the view relative to its parent.

Can be either a float value or a dimension string (for example 100 or'50%'.)

  • 0.9
  • 0.9
  • 0.9

Overrides: Titanium.UI.View.top

A material design visual construct that provides an instantaneous visual confirmation of touch point. ...

A material design visual construct that provides an instantaneous visual confirmation of touch point.

Requires: Android 5.0 and later

This is an opt-in feature available from Android Lollipop. Touch feedback is applied only if the backgroundColor is a solid color.

Default: false

  • 6.1.0
Optional touch feedback ripple color. ...

Optional touch feedback ripple color. This has no effect unless touchFeedback is true.

Requires: Android 5.0 and later

Default: Theme provided color.

  • 6.1.0
A name to identify this view in activity transition. ...

A name to identify this view in activity transition.

Requires: Android 5 and later

Name should be unique in the View hierarchy.

  • 5.0.2

Horizontal location of the view relative to its left position in pixels.

Horizontal location of the view relative to its left position in pixels.

Translation values are applied to the static post layout value.

  • 5.0.0

Vertical location of the view relative to its top position in pixels.

Vertical location of the view relative to its top position in pixels.

Translation values are applied to the static post layout value.

  • 5.0.0
Depth of the view relative to its elevation in pixels. ...

Depth of the view relative to its elevation in pixels.

Requires: Android 5 and later

Translation values are applied to the static post layout value.

  • 5.0.0
Titanium.UI.ActivityIndicator
: String
Width of the view. ...

Width of the view. Only accepts value of Titanium.UI.SIZE, which must be explicitly set in order to display the message and to position the view correctly.

Defaults to: If undefined, defaults to either Titanium.UI.FILL or Titanium.UI.SIZE depending on the view. See "View Types and Default Layout Behavior" in Transitioning to the New UI Layout System.

Can be either a float value or a dimension string (for example, '50%' or '40dp'). Can also be one of the following special values:

  • Titanium.UI.SIZE. The view should size itself to fit its contents.
  • Titanium.UI.FILL. The view should size itself to fill its parent.
  • 'auto'. Represents the default sizing behavior for a given type of view. The use of 'auto' is deprecated, and should be replaced with the SIZE or FILL constants if it is necessary to set the view's behavior explicitly.

This is an input property for specifying the view's width dimension. To determine the view's size once rendered, use the rect or size properties.

This API can be assigned the following constants:

  • 0.9
  • 0.9
  • 0.9

Overrides: Titanium.UI.View.width

Defined By

Methods

Titanium.UI.ActivityIndicator
( view )
Adds a child to this activity indicator's hierarchy. ...

Adds a child to this activity indicator's hierarchy.

Adding children to an ActivityIndicator is not supported on all platforms.

If you need to display views on top of this object, consider using another view as a container for both this object and the views you want to appear on top of it.

See also: Titanium.UI.View.add.

  • 0.9
  • 0.9

Parameters

Returns

  • void

Overrides: Titanium.UI.View.add

Adds the specified callback as an event listener for the named event. ...

Adds the specified callback as an event listener for the named event.

Parameters

  • name : String

    Name of the event.

  • callback : Callback<Object>

    Callback function to invoke when the event is fired.

Returns

  • void
Applies the properties to the proxy. ...

Applies the properties to the proxy.

Properties are supplied as a dictionary. Each key-value pair in the object is applied to the proxy such that myproxy[key] = value.

  • 3.0.0
  • 3.0.0
  • 3.0.0

Parameters

  • props : Dictionary

    A dictionary of properties to apply.

Returns

  • void
Finishes a batch update of the View's layout properties and schedules a layout pass of the view tree. ...

Finishes a batch update of the View's layout properties and schedules a layout pass of the view tree.

deprecated since 3.0.0

Use the <Titanium.Proxy.applyProperties> method to batch-update layout properties.

Since the layout pass scheduled is asynchronous, the rect and size values may not be available immediately after finishLayout is called.

To be notified when the layout pass completes, add a listener for the postlayout event.

  • 2.0.0
  • 2.0.0
  • 2.0.0

Returns

  • void
Fires a synthesized event to any registered listeners. ...

Fires a synthesized event to any registered listeners.

Parameters

  • name : String

    Name of the event.

  • event : Dictionary

    A dictionary of keys and values to add to the Titanium.Event object sent to the listeners.

Returns

  • void
Gets the value of the apiName property. ...

Gets the value of the apiName property.

  • 3.2.0
  • 3.2.0
  • 3.2.0

Returns

  • String
Titanium.UI.ActivityIndicator
( ) : Number/String
Gets the value of the bottom property. ...

Gets the value of the bottom property.

  • 0.9
  • 0.9
  • 0.9

Returns

  • Number/String

Overrides: Titanium.UI.View.getBottom

Gets the value of the bubbleParent property. ...

Gets the value of the bubbleParent property.

  • 3.0.0
  • 3.0.0
  • 3.0.0

Returns

  • Boolean
Titanium.UI.ActivityIndicator
( ) : String
Gets the value of the color property. ...

Gets the value of the color property.

Returns

  • String
Gets the value of the elevation property. ...

Gets the value of the elevation property.

  • 5.0.0

Returns

  • Number
Titanium.UI.ActivityIndicator
( ) : Font
Gets the value of the font property. ...

Gets the value of the font property.

Returns

Titanium.UI.ActivityIndicator
( ) : String
Gets the value of the height property. ...

Gets the value of the height property.

  • 0.9
  • 0.9
  • 0.9

Returns

  • String

Overrides: Titanium.UI.View.getHeight

Gets the value of the hiddenBehavior property. ...

Gets the value of the hiddenBehavior property.

  • 6.1.0

Returns

  • Number
Titanium.UI.ActivityIndicator
( ) : String
Gets the value of the indicatorColor property. ...

Gets the value of the indicatorColor property.

  • 2.1.0
  • 2.1.0
  • 2.1.0

Returns

  • String
Titanium.UI.ActivityIndicator
( ) : Number/String
Gets the value of the left property. ...

Gets the value of the left property.

  • 0.9
  • 0.9
  • 0.9

Returns

  • Number/String

Overrides: Titanium.UI.View.getLeft

Gets the value of the lifecycleContainer property. ...

Gets the value of the lifecycleContainer property.

  • 3.6.0

Returns

Titanium.UI.ActivityIndicator
( ) : String
Gets the value of the message property. ...

Gets the value of the message property.

Returns

  • String
Titanium.UI.ActivityIndicator
( ) : String
Gets the value of the messageid property. ...

Gets the value of the messageid property.

Returns

  • String
Gets the value of the previewContext property. ...

Gets the value of the previewContext property.

  • 5.1.0

Returns

Titanium.UI.ActivityIndicator
( ) : Number/String
Gets the value of the right property. ...

Gets the value of the right property.

  • 0.9
  • 0.9
  • 0.9

Returns

  • Number/String

Overrides: Titanium.UI.View.getRight

Gets the value of the rotation property. ...

Gets the value of the rotation property.

  • 5.4.0

Returns

  • Number
Gets the value of the rotationX property. ...

Gets the value of the rotationX property.

  • 5.4.0

Returns

  • Number
Gets the value of the rotationY property. ...

Gets the value of the rotationY property.

  • 5.4.0

Returns

  • Number
Gets the value of the scaleX property. ...

Gets the value of the scaleX property.

  • 5.4.0

Returns

  • Number
Gets the value of the scaleY property. ...

Gets the value of the scaleY property.

  • 5.4.0

Returns

  • Number
Titanium.UI.ActivityIndicator
( ) : Number
Gets the value of the style property. ...

Gets the value of the style property.

Returns

  • Number
Titanium.UI.ActivityIndicator
( ) : Number/String
Gets the value of the top property. ...

Gets the value of the top property.

  • 0.9
  • 0.9
  • 0.9

Returns

  • Number/String

Overrides: Titanium.UI.View.getTop

Gets the value of the touchFeedback property. ...

Gets the value of the touchFeedback property.

  • 6.1.0

Returns

  • Boolean
Gets the value of the touchFeedbackColor property. ...

Gets the value of the touchFeedbackColor property.

  • 6.1.0

Returns

  • String
Gets the value of the transitionName property. ...

Gets the value of the transitionName property.

  • 5.0.2

Returns

  • String
Gets the value of the translationX property. ...

Gets the value of the translationX property.

  • 5.0.0

Returns

  • Number
Gets the value of the translationY property. ...

Gets the value of the translationY property.

  • 5.0.0

Returns

  • Number
Gets the value of the translationZ property. ...

Gets the value of the translationZ property.

  • 5.0.0

Returns

  • Number
Returns the matching view of a given view ID. ...

Returns the matching view of a given view ID.

  • 6.1.0
  • 6.1.0
  • 6.1.0

Parameters

  • id : String

    The ID of the view that should be returned. Use the id property in your views to enable it for indexing in this method.

Returns

Titanium.UI.ActivityIndicator
( ) : String
Gets the value of the width property. ...

Gets the value of the width property.

  • 0.9
  • 0.9
  • 0.9

Returns

  • String

Overrides: Titanium.UI.View.getWidth

Titanium.UI.ActivityIndicator
( [options] )
Hides the activity indicator and stops the animation. ...

Hides the activity indicator and stops the animation.

  • 0.9
  • 0.9
  • 0.9

Parameters

  • options : AnimationOption (optional)

    Animation options for Android. Since Release 5.1.0.

Returns

  • void

Overrides: Titanium.UI.View.hide

Inserts a view at the specified position in the children array. ...

Inserts a view at the specified position in the children array.

Useful if the layout property is set to horizontal or vertical.

  • 3.3.0
  • 3.3.0
  • 3.3.0

Parameters

  • params : Dictionary

    Pass an object with the following key-value pairs:

    • view (Titanium.UI.View): View to insert
    • position (Number): Position in the children array to insert the view. If omitted, inserts the view to the end of the array.

Returns

  • void
Titanium.UI.ActivityIndicator
( view )
Removes a child from this activity indicator's hierarchy. ...

Removes a child from this activity indicator's hierarchy.

Adding children to an ActivityIndicator is not supported on all platforms.

See also: add, Titanium.UI.View.add.

  • 0.9
  • 0.9

Parameters

Returns

  • void

Overrides: Titanium.UI.View.remove

Removes the specified callback as an event listener for the named event. ...

Removes the specified callback as an event listener for the named event.

Multiple listeners can be registered for the same event, so the callback parameter is used to determine which listener to remove.

When adding a listener, you must save a reference to the callback function in order to remove the listener later:

var listener = function() { Ti.API.info("Event listener called."); }
window.addEventListener('click', listener);

To remove the listener, pass in a reference to the callback function:

window.removeEventListener('click', listener);

Parameters

  • name : String

    Name of the event.

  • callback : Callback<Object>

    Callback function to remove. Must be the same function passed to addEventListener.

Returns

  • void
Replaces a view at the specified position in the children array. ...

Replaces a view at the specified position in the children array.

Useful if the layout property is set to horizontal or vertical.

  • 3.3.0
  • 3.3.0
  • 3.3.0

Parameters

  • params : Dictionary

    Pass an object with the following key-value pairs:

    • view (Titanium.UI.View): View to insert
    • position (Number): Position in the children array of the view elment to replace.

Returns

  • void
Titanium.UI.ActivityIndicator
( bottom )
Sets the value of the bottom property. ...

Sets the value of the bottom property.

  • 0.9
  • 0.9
  • 0.9

Parameters

  • bottom : Number/String

    New value for the property.

Returns

  • void

Overrides: Titanium.UI.View.setBottom

Sets the value of the bubbleParent property. ...

Sets the value of the bubbleParent property.

  • 3.0.0
  • 3.0.0
  • 3.0.0

Parameters

  • bubbleParent : Boolean

    New value for the property.

Returns

  • void
Titanium.UI.ActivityIndicator
( color )
Sets the value of the color property. ...

Sets the value of the color property.

Parameters

  • color : String

    New value for the property.

Returns

  • void
Sets the value of the elevation property. ...

Sets the value of the elevation property.

  • 5.0.0

Parameters

  • elevation : Number

    New value for the property.

Returns

  • void
Titanium.UI.ActivityIndicator
( font )
Sets the value of the font property. ...

Sets the value of the font property.

Parameters

  • font : Font

    New value for the property.

Returns

  • void
Titanium.UI.ActivityIndicator
( height )
Sets the value of the height property. ...

Sets the value of the height property.

  • 0.9
  • 0.9
  • 0.9

Parameters

  • height : String

    New value for the property.

Returns

  • void

Overrides: Titanium.UI.View.setHeight

Sets the value of the hiddenBehavior property. ...

Sets the value of the hiddenBehavior property.

  • 6.1.0

Parameters

  • hiddenBehavior : Number

    New value for the property.

Returns

  • void
Titanium.UI.ActivityIndicator
( indicatorColor )
Sets the value of the indicatorColor property. ...

Sets the value of the indicatorColor property.

  • 2.1.0
  • 2.1.0
  • 2.1.0

Parameters

  • indicatorColor : String

    New value for the property.

Returns

  • void
Titanium.UI.ActivityIndicator
( left )
Sets the value of the left property. ...

Sets the value of the left property.

  • 0.9
  • 0.9
  • 0.9

Parameters

  • left : Number/String

    New value for the property.

Returns

  • void

Overrides: Titanium.UI.View.setLeft

Sets the value of the lifecycleContainer property. ...

Sets the value of the lifecycleContainer property.

  • 3.6.0

Parameters

Returns

  • void
Titanium.UI.ActivityIndicator
( message )
Sets the value of the message property. ...

Sets the value of the message property.

Parameters

  • message : String

    New value for the property.

Returns

  • void
Titanium.UI.ActivityIndicator
( messageid )
Sets the value of the messageid property. ...

Sets the value of the messageid property.

Parameters

  • messageid : String

    New value for the property.

Returns

  • void
Sets the value of the previewContext property. ...

Sets the value of the previewContext property.

  • 5.1.0

Parameters

Returns

  • void
Titanium.UI.ActivityIndicator
( right )
Sets the value of the right property. ...

Sets the value of the right property.

  • 0.9
  • 0.9
  • 0.9

Parameters

  • right : Number/String

    New value for the property.

Returns

  • void

Overrides: Titanium.UI.View.setRight

Sets the value of the rotation property. ...

Sets the value of the rotation property.

  • 5.4.0

Parameters

  • rotation : Number

    New value for the property.

Returns

  • void
Sets the value of the rotationX property. ...

Sets the value of the rotationX property.

  • 5.4.0

Parameters

  • rotationX : Number

    New value for the property.

Returns

  • void
Sets the value of the rotationY property. ...

Sets the value of the rotationY property.

  • 5.4.0

Parameters

  • rotationY : Number

    New value for the property.

Returns

  • void
Sets the value of the scaleX property. ...

Sets the value of the scaleX property.

  • 5.4.0

Parameters

  • scaleX : Number

    New value for the property.

Returns

  • void
Sets the value of the scaleY property. ...

Sets the value of the scaleY property.

  • 5.4.0

Parameters

  • scaleY : Number

    New value for the property.

Returns

  • void
Titanium.UI.ActivityIndicator
( style )
Sets the value of the style property. ...

Sets the value of the style property.

Parameters

  • style : Number

    New value for the property.

Returns

  • void
Titanium.UI.ActivityIndicator
( top )
Sets the value of the top property. ...

Sets the value of the top property.

  • 0.9
  • 0.9
  • 0.9

Parameters

  • top : Number/String

    New value for the property.

Returns

  • void

Overrides: Titanium.UI.View.setTop

Sets the value of the touchFeedback property. ...

Sets the value of the touchFeedback property.

  • 6.1.0

Parameters

  • touchFeedback : Boolean

    New value for the property.

Returns

  • void
Sets the value of the touchFeedbackColor property. ...

Sets the value of the touchFeedbackColor property.

  • 6.1.0

Parameters

  • touchFeedbackColor : String

    New value for the property.

Returns

  • void
Sets the value of the transitionName property. ...

Sets the value of the transitionName property.

  • 5.0.2

Parameters

  • transitionName : String

    New value for the property.

Returns

  • void
Sets the value of the translationX property. ...

Sets the value of the translationX property.

  • 5.0.0

Parameters

  • translationX : Number

    New value for the property.

Returns

  • void
Sets the value of the translationY property. ...

Sets the value of the translationY property.

  • 5.0.0

Parameters

  • translationY : Number

    New value for the property.

Returns

  • void
Sets the value of the translationZ property. ...

Sets the value of the translationZ property.

  • 5.0.0

Parameters

  • translationZ : Number

    New value for the property.

Returns

  • void
Titanium.UI.ActivityIndicator
( width )
Sets the value of the width property. ...

Sets the value of the width property.

  • 0.9
  • 0.9
  • 0.9

Parameters

  • width : String

    New value for the property.

Returns

  • void

Overrides: Titanium.UI.View.setWidth

Titanium.UI.ActivityIndicator
( [options] )
Shows the activity indicator and starts the animation. ...

Shows the activity indicator and starts the animation.

  • 0.9
  • 0.9
  • 0.9

Parameters

  • options : AnimationOption (optional)

    Animation options for Android. Since Release 5.1.0.

Returns

  • void

Overrides: Titanium.UI.View.show

Starts a batch update of this view's layout properties. ...

Starts a batch update of this view's layout properties.

deprecated since 3.0.0

Use the <Titanium.Proxy.applyProperties> method to batch-update layout properties.

To prevent a layout pass each time a property is modified, call startLayout before changing any properties that may change this view's layout. This initiates a batch update mode where layout changes are deferred.

Call finishLayout to end batch update mode and trigger a layout pass. For example:

view.startLayout();
view.top = 50;
view.left = 50;
view.finishLayout();

Note that any property changes made during the batch update may be deferred until finishLayout is called. This may vary somewhat by platform. For example, changing the text of a label may trigger a layout pass. In iOS, updating the label text is deferred.

See also: updateLayout, finishLayout, postlayout event.

  • 2.0.0
  • 2.0.0
  • 2.0.0

Returns

  • void
( params )deprecated
Performs a batch update of all supplied layout properties and schedules a layout pass after they have been updated. ...

Performs a batch update of all supplied layout properties and schedules a layout pass after they have been updated.

deprecated since 3.0.0

Use the <Titanium.Proxy.applyProperties> method to batch-update layout properties.

This is another way to perform a batch update. The updateLayout method is called with a dictionary of layout properties to perform the batch update. For example:

view.updateLayout({top:50, left:50});

This is equivalent to the following:

view.startLayout();
view.top = 50;
view.left = 50;
view.finishLayout();

See also: startLayout, finishLayout, postlayout event.

  • 2.0.0
  • 2.0.0
  • 2.0.0

Parameters

  • params : Dictionary

    Layout properties to be updated.

Returns

  • void