GitXplorerGitXplorer
t

activity-bar

public
37 stars
5 forks
1 issues

Commits

List of commits on branch master.
Unverified
f3df679d60d7c98ee2f0dcb1f30d3cb8e42b982f

fix image

ttanner0101 committed 9 years ago
Unverified
a05e8e8d418ac942f51165b083b7b52dede44466

update repo

ttanner0101 committed 9 years ago
Unverified
553c8a2a44ba0cf121f95c6f258bfebfbe931490

formatting

ttanner0101 committed 9 years ago
Unverified
966d4908b0c42d0cc2a9fb0261564eb3b0f18d04

add progress option

ttanner0101 committed 9 years ago
Unverified
bd0233c7310d72bb8321189c1dc002fb6b6d0b71

add progress option

ttanner0101 committed 9 years ago
Unverified
60b028921525c0aa7bbcf7644efd9a76023f7f33

add progress option

ttanner0101 committed 9 years ago

README

The README file for this repository.

ActivityBar

[![CI Status](http://img.shields.io/travis/Tanner Nelson/ActivityBar.svg?style=flat)](https://travis-ci.org/Tanner Nelson/ActivityBar) Version License Platform

An iMessage UIProgressBar-style view for showing ogoing activity.

ActivityBar Animation

Example

To run the example project, clone the repo, and run pod install from the Example directory first.

Installation

ActivityBar is available through CocoaPods. To install it, simply add the following line to your Podfile:

pod "ActivityBar"

Getting Started

Add the ActivityBar to your view controller.

import UIKit
import ActivityBar

class ViewController: UIViewController {
    var activityBar: ActivityBar!

    override func viewDidLoad() {
        super.viewDidLoad()

        self.activityBar = ActivityBar.addTo(self)
    }
}

If there is a NavigationBar present, ActivityBar, will attach itself to the NavigationBar. Otherwise, it will be placed directly underneath the Status Bar.

Color

Change the color of the ActivityBar at any time. By default, ActivityBar will be the tintColor of your application.

self.activityBar.color = UIColor.greenColor()

Animation

Start and stop the ActivityBar's indefinite animation.

self.activityBar.start()
self.activityBar.stop()

Progress

Set the ActivityBar to display progress between 0% and 100%.

//displays the ActivityBar and animates to 75%
self.activityBar.progress = 0.75

The ActivityBar will animate between different states of progress. To hide the ActivityBar, set the progress property to nil.

//hides the ActivityBar
self.activityBar.progress = nil

Note: You can call start() at any point without first setting progress to nil.

Author

Tanner Nelson, tanner@bluebite.com

License

ActivityBar is available under the MIT license. See the LICENSE file for more info.