Skip to content

A simple, thread-safe class that manages the iOS network activity indicator across multiple code paths.

License

Notifications You must be signed in to change notification settings

allenpc/APCNetworkActivityIndicatorManager

Repository files navigation

APCNetworkActivityIndicatorManager

APCNetworkActivityIndicatorManager is a simple, thread-safe class that manages the iOS network activity indicator across multiple code paths. It solves the problem of interleaving calls to setNetworkActivityIndicatorVisible leading to the network activity indicator being in an inconsistent state.

APCNetworkActivityIndicatorManager will also restore the indicator to the proper state after the app has been backgrounded and then opened again.

Usage

The easiest way to use APCNetworkActivityIndicatorManager is to simply copy the two source files into your project.

#import "APCNetworkActivityIndicatorManager.h"

[APCNetworkActivityIndicatorManager start]; // start the indicator

// ...

[APCNetworkActivityIndicatorManager stop];  // stop the indicator

License

See included LICENSE file

About

A simple, thread-safe class that manages the iOS network activity indicator across multiple code paths.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published