Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

a copycat of the HUD shown on orientation and volume change in iOS.

branch: master

Merge pull request #6 from nochkin/master

Mergin the patch from SVProgressHUD
latest commit fbd53f3b19
Sam Vermette authored
Octocat-spinner-32 Demo Update build settings.
Octocat-spinner-32 SVStatusHUD Don't call makeKeyVisible on overlayWindow
Octocat-spinner-32 .gitignore Initial commit.
Octocat-spinner-32 LICENSE.txt Initial commit.
Octocat-spinner-32 README.textile Updated info about ARC.
README.textile

SVStatusHUD

SVStatusHUD mimics the HUD shown on orientation lock, mute and volume change on iOS. It should only be used in response to hardware or other important notifications (for instance when an accessory is detected by your app). If you’re just looking to show the progress or success of an operation, you should have a look at SVProgressHUD.


Glyph icons kindly provided by @jpmartineau for the sake of showing appropriate use cases.

SVStatusHUD features:

  • simple singleton convenience methods ([SVStatus method])
  • automatic styling of the image it’s provided
  • optional status string and showing duration
  • automatic positioning based on device type and orientation

Installation

  • Drag the SVStatusHUD/SVStatusHUD folder into your project.
  • Add the QuartzCore framework to your project.

If you plan on using SVStatusHUD in a lot of places inside your app, I recommend importing it directly inside your prefix file.

Usage

(see sample Xcode project in /Demo)

SVStatusHUD is created as a singleton (i.e. it doesn’t need to be explicitly allocated and instantiated; you directly call [SVStatusHUD method]) and can be shown using one of the following convenience/class methods:

+ (void)showWithImage:(UIImage*)image;
+ (void)showWithImage:(UIImage*)image status:(NSString*)string;
+ (void)showWithImage:(UIImage*)image status:(NSString*)string duration:(NSTimeInterval)duration;

Important: for crispier rendering, provided image should precisely be 86×86 pixels (retina: 172×172).

Automatic Reference Counting (ARC) support

Maintaining an official ARC branch has proven to be too much work, often leading to confusion since the ARC branch is always a few commits behind. If you’d like to use SVStatusHUD in your ARC-enabled project, you’ll have to add the -fno-objc-arc compiler flag to all of SVStatusHUD’s files.

Credits

SVStatusHUD is brought to you by Sam Vermette and contributors to the project. If you have feature suggestions or bug reports, feel free to help out by sending pull requests or by creating new issues. If you’re using SVStatusHUD in your project, attribution would be nice.

Something went wrong with that request. Please try again.