Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
iOS UI utility classes
Objective-C
Branch: master

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.
Example
UIUtilis
.gitignore
LICENSE
README.md

README.md

UIUtilis

UIUtilis is a collection of iOS classes for rendering frequently encountered UI elements. The classes are ARC compliant.

Contents

UTModalActivityIndicatorView A modal view in center of screen to show a message and a spinner.
Perfect for display while processing an intensive task (plus restricts user input).
Limitation: Works for non-blocking tasks like an async url request. Requires the containing thread to be alive so it wont, for example work on a sleep or dataWithContentsOfURL call

Example Usage

UTModalActivityIndicatorView

// Before Invoking Task
// Create and Display Modal View Controller in Center of Screen
CGRect viewFrame = [self.view frame];
UTModalActivityIndicatorView *grayView = [[UTModalActivityIndicatorView alloc] 
                                          initWithLabel:@"Processing ..."
                                             atPosition:CGPointMake(viewFrame.size.width/2 - 75.0f, 
                                                                    viewFrame.size.height/2 - 75.0f)];
[self.view addSubview:grayView];
[grayView startAnimating];

// Invoke Awesome Task ...

// To Dismiss Modal View Controller
// Remove Modal View Controller (i.e. the last subview that was added)
[grayView stopAnimating];
[grayView removeFromSuperview];

// Or if in a different method
// Remove Modal View Controller (i.e. the last subview that was added)
[((UTModalActivityIndicatorView*)[[self.view subviews]objectAtIndex:[[self.view subviews]count]-1]) stopAnimating];
[((UTModalActivityIndicatorView*)[[self.view subviews]objectAtIndex:[[self.view subviews]count]-1]) removeFromSuperview];

License

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

Something went wrong with that request. Please try again.