native.setActivityIndicator()

Type Function
Library native.*
Return value none
Revision 2017.3111
Keywords activity indicator

Overview

Displays or hides a platform-specific activity indicator. Touch events are ignored while the indicator is shown.

Note that on Android, the activity indicator is shown as a popup dialog, while on iOS and macOS it's an overlay. For Win32 desktop apps, the mouse cursor changes to a "busy/waiting" cursor.

Gotchas

Syntax

native.setActivityIndicator( state )
state (required)

Boolean. Use true to show the indicator and false to hide it.

Example

native.setActivityIndicator( true )

-- Hide activity indicator after 2 seconds
timer.performWithDelay( 2000, function() 
    native.setActivityIndicator( false )
end )