ActivityIndicator


super: UIActivityIndicatorView on iOS

Use an activity indicator to show that a task is in progress. An activity indicator appears as a "gear" that is either spinning or stopped.

ActivityIndicator

Events

  • Load() This event is called when the object becames available in the current runtime system.

  • TouchesBegan(touches: Object): Bool This event is called when one or more new touches occurred in this view and the userInteractionEnabled property is enabled. Return "true" if you want to consume the event and not forward it to the next responder, return "no" to forward any events that you do not handle yourself.

  • TouchesMoved(touches: Object, touchInside: Bool): Bool This event is called when the location or force of a touch changes and the userInteractionEnabled property is enabled. Return "true" if you want to consume the event and not forward it to the next responder, return "no" to forward any events that you do not handle yourself.

  • TouchesEnded(touches: Object, touchInside: Bool): Bool This event is called when one or more fingers are raised and the userInteractionEnabled property is enabled. Return "true" if you want to consume the event and not forward it to the next responder, return "no" to forward any events that you do not handle yourself.

  • TouchesCancelled(touches: Object): Bool This event is called when the sysyem receives a system interruption (such as a system alert) requiring cancellation of the touch sequence and the userInteractionEnabled property is enabled. Return "true" if you want to consume the event and not forward it to the next responder, return "no" to forward any events that you do not handle yourself.

  • Unload() This event is called when the object has been removed from the current runtime system (but not yet deallocated).

Properties

  • var color: Color The color of the activity indicator.

  • var style: ActivityIndicatorStyle The basic appearance of the activity indicator.

  • var hidesWhenStopped: Bool A Boolean value that controls whether the receiver is hidden when the animation is stopped.

Methods

  • func startAnimating() Starts the animation of the activity indicator.

  • func stopAnimating() Stops the animation of the activity indicator.

  • func isAnimating(): Bool Returns true if the animation is active, false if it isn't.

  • func animate(duration: Float, delay: Float, options: Int, closure: Closure, completion: Closure) Animate changes to one or more views using the specified duration, delay, options and completion handler.

    Enumeration

      ActivityIndicatorStyle

      • .Gray
      • .White
      • .WhiteLarge