Collection of iOS drop-in components to visualize progress

Overview

MRProgress

Twitter: @mrackwitz License: MIT CocoaPods Travis

MRProgress is a collection of drop-in components that display a dimmed overlay with a blurred box view with an indicator and/or labels while work is being done in a background thread.

  • Component oriented: You don't have to use all components or MRProgressOverlayView. You can use just the custom activity indicators or progress views.
  • Configurable: All components implement tintColor.
  • Customizable: You can replace the given blur implementation and hook into your own you are maybe already using in other places of your app. Or simply throw in an UIToolbar's layer, if you prefer Apple's implementation. (Current blur implementation is as given by sample code of WWDC 2013.)
  • Reusable: The code is fragmented in small reusable pieces.
  • Well documented: You can install and open Appledoc documentation.
  • Integrated: It offers an integration into AFNetworking.
  • Accessible: It provides labels, traits and events for UIAccessibility.

Components

The components used in MRProgressOverlayView could be used seperately. The provided Example app demonstrates how they can be used.

MRProgressOverlayView

  • Supports different modes
  • Animated show and hide
  • Blured background
  • With UIMotionEffects for tilting like UIAlertView
  • Supports multi-line title label text

MRCircularProgressView

  • Tint color can be changed
  • Circular progress view like in AppStore
  • Can display a stop button
  • Animated with CABasicAnimation
  • Percentage label change is animated over a NSTimer

MRNavigationBarProgressView

  • Display a progress view in a UINavigationController
  • Hooks UINavigationControllerDelegate and is automatically removed on push or pop
  • Can be used in UINavigationBar or UIToolbar

MRCheckmarkIconView and MRCrossIconView

  • Tint color can be changed
  • Scalable
  • Animatable
  • Backed by CAShapeLayer

MRActivityIndicatorView

  • Tint color can be changed
  • Same API as UIActivityIndicatorView
  • Can display a stop button
  • Animated with CABasicAnimation

Installation

CocoaPods

CocoaPods is the recommended way to add MRProgress to your project.

  1. Add a pod entry for MRProgress to your Podfile pod 'MRProgress'.
  2. Install the pod(s) by running pod install.
  3. Include MRProgress wherever you need it with #import <MRProgress/MRProgress.h> from Objective-C or import MRProgress from Swift.

Source files

  1. Download the latest code version or add the repository as a git submodule to your git-tracked project.
  2. Drag and drop the src directory from the archive in your project navigator. Make sure to select Copy items when asked if you extracted the code archive outside of your project.
  3. Include MRProgress wherever you need any component with #import "MRProgress.h" or include it in your bridging header to use it in Swift.

Static library

  1. Drag and drop MRProgress.xcodeproj in your project navigator.
  2. Select your target and go to the Build Phases tab. In the Link Binary With Libraries section select the add button. On the sheet find and add libMRProgress.a.
  3. Add Target MRProgress to your Target Dependencies list.
  4. Use import <MRProgress/MRProgress.h> from Objective-C or import MRProgress from Swift wherever you want to use the components.

CocoaPods - Subspecs

The library is cut in small subspecs, so that you can just depend on selected components. See the following dependency tree:

─┬─MRProgress/
 │
 ├───Blur
 │
 ├───ActivityIndicator
 │
 ├───Circular
 │
 ├───Icons
 │
 ├───NavigationBarProgress
 │
 ├─┬─Overlay
 │ ├───ActivityIndicator
 │ ├───Circular
 │ ├───Icons
 │ └───Blur
 |
 ├─┬─AFNetworking (optional)
 │ ├───ActivityIndicator
 │ ├───Circular
 │ ├───NavigationBarProgress
 │ └───Overlay
 |
 ├───MethodCopier (optional)
 │
 ├───MessageInterceptor (optional)
 │
 └───WeakProxy (optional)

The tree only list public specs, where you can rely on. You will see in the podspec and your Podfile.lock other subspecs, but you should NOT rely on these. Those are implementation details, which are subject to change and may been removed, even with a minor version update. Furthermore this tree doesn't show any cross-dependencies, which do exist.

Requirements

  • Xcode 5
  • iOS 7
  • ARC
  • Frameworks:
    • QuartzCore
    • CoreGraphics
    • Accelerate

Usage

Check out the provided demo app for many examples how you can use the components. Make sure you also see MRProgress documentation on Cocoadocs.

Basics

  1. Add the following import to the top of the file or to your Prefix header:

    // If used with CocoaPods
    #import "MRProgress.h"
    // If used as Framework
    #import <MRProgress/MRProgress.h>
  2. Use one the following ways to display the overlay:

    // Block whole window
    [MRProgressOverlayView showOverlayAddedTo:self.window animated:YES];
    // Block only the navigation controller
    [MRProgressOverlayView showOverlayAddedTo:self.navigationController.view animated:YES];
    // Block only the view
    [MRProgressOverlayView showOverlayAddedTo:self.view animated:YES];
    // Block a custom view
    [MRProgressOverlayView showOverlayAddedTo:self.imageView animated:YES];
  3. Simply dismiss after complete your task:

    // Dismiss
    [MRProgressOverlayView dismissOverlayForView:self.view animated:YES];

AFNetworking

MRProgress offers an integration into the network library AFNetworking.

  1. Include the following additional line into your Podfile:

    pod 'MRProgress/AFNetworking'
  2. Import the adequate category header for the component you want to use:

    #import <MRProgress/MRProgressOverlayView+AFNetworking.h>
  3. You can now just setup your task / operation as usual and use the category methods to bind to execution state and progress as shown below.

    // Init the progress overlay as usual
    MRProgressOverlayView *overlayView = [MRProgressOverlayView showOverlayAddedTo:self.view animated:YES];
    
    // The following line will do these things automatically:
    // * Set mode to determinate when a download or upload is in progress
    // * Set animated progress of the download or upload
    // * Show a checkmark or cross pane at the end of the progress
    [overlayView setModeAndProgressWithStateOfTask:task];
    
    // Allows the user to cancel the task by using the provided stop button.
    // If you use that, make sure that you handle the error code, which will be
    // delivered to the failure block of the task like shown below:
    //
    //    if ([error.domain isEqualToString:NSURLErrorDomain] && error.code == NSURLErrorCancelled) {
    //        NSLog(@"Task was cancelled by user.");
    //        return;
    //    }
    //
    [overlayView setStopBlockForTask:task];
    
    // If you use the activity indicator directly
    [self.activityIndicatorView setAnimatingWithStateOfTask:task];
    
    // If you use one of the progress views directly
    [self.circularProgressView setProgressWithUploadProgressOfTask:downloadTask animated:YES];   // for uploads
    [self.circularProgressView setProgressWithDownloadProgressOfTask:downloadTask animated:YES]; // for downloads
    [[MRNavigationBarProgressView progressViewForNavigationController:self.navigationController]
      setProgressWithDownloadProgressOfTask:downloadTask animated:YES];

    All methods are available for both 'NSURLSessionTask' and 'AFURLConnectionOperation' and their descendants. For further examples, make sure to also checkout the Example app.

Modes

Name (MRProgressOverlayView<...>) Screenshot Description
Indeterminate Progress is shown using a large round activity indicator view. (MRActivityIndicatorView) This is the default.
DeterminateCircular Progress is shown using a round, pie-chart like, progress view. (MRCircularProgressView)
DeterminateHorizontalBar Progress is shown using a horizontal progress bar. (UIProgressView)
IndeterminateSmall Shows primarily a label. Progress is shown using a small activity indicator. (MRActivityIndicatorView)
IndeterminateSmallDefault Shows primarily a label. Progress is shown using a small activity indicator. (UIActivityIndicatorView in UIActivityIndicatorViewStyleGray)
Checkmark Shows a checkmark. (MRCheckmarkIconView)
Cross Shows a cross. (MRCrossIconView)

Credits

MRProgress' API was inspired by MBProgressHUD project.

The acquarium image was stolen by Jag Cesar's blur implementation.

You can find me on Twitter @mrackwitz.

License

Copyright (c) 2013 Marius Rackwitz [email protected]

The MIT License

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

Comments
  • Full screen flicker when displaying progress overlay

    Full screen flicker when displaying progress overlay

    Using 0.5.0.

    Steps to reproduce:

    Display a progress overlay on device using the sample app. This is reproducible on iPhone and iPad, although it is usually more noticeable on iPad. The screen will briefly flicker with a buggy texture.

    I think from your previous comments that this is related to the asynchronous blur texture rendering. This is likely related to #42

    See video here: https://docs.google.com/file/d/0B7hk_IdN2v-QRy1lNWZHTmg1SDNQWHotalRrVjFldHlhd0lR/edit

    type:bug 
    opened by jdmunro 14
  • iOS 8.1 Issues [EXC_BAD_ACCESS, No Overlay Background Shown)

    iOS 8.1 Issues [EXC_BAD_ACCESS, No Overlay Background Shown)

    Hi, I just updated my app to iOS 8.1, and there are two separate issues I'm having with MRProgress. Perhaps they are related. The app often crashes with EXC_BAD_ACCESS when I show an MRProgressOverlayView, and the overlay view does not have its fancy white background when it happens to not crash. It is a bit random, and unfortunately I haven't been able to get a stack trace. When it does not crash, the only thing shown is the progress view's title and the blue [in]determinate circle.

    Things of note: -I am showing the overlay view in viewDidLoad in [self view]. If I move it to viewDidAppear, it seems to work, but that is not optimal since then the user sees the screen before the loading view is shown! -I do have the fix from the iPad non-flickering branch "installed," but this was also happening before I installed it.

    Thanks.

    opened by Deadpikle 11
  • ActivityView not rotating

    ActivityView not rotating

    Hello Guys,

    I got a issue over here. I have added a MRActivityIndicatorView and called the startAnimating method. The View is visible but its not rotating. It's just like this:

    foto 15 06 14 20 22 07

    But if I touch the home button and go back to the App it starts the animation.

    state:awaiting-input 
    opened by SaifAlDilaimi 8
  • [AFNetworking] Overlay doesn't disappear or show the final state of the operation

    [AFNetworking] Overlay doesn't disappear or show the final state of the operation

    i use MRProgressOverlayView+AFNetworking! but in one tableviewcontroller, it always loading,can not stop! how can i do?!

    - (void)viewDidLoad
    {
        [super viewDidLoad];
        self.tableView.contentInset = UIEdgeInsetsMake(-1.0f, 0.0f, 0.0f, 0.0);
    
        AFHTTPRequestOperationManager *manager = [AFHTTPRequestOperationManager manager];
        AFHTTPRequestOperation *operation = [manager GET:[[NSString stringWithFormat:@"http://localhost:3000/api/teams/%@", self.team_id] stringByAddingPercentEscapesUsingEncoding:NSUTF8StringEncoding] parameters:nil success:^(AFHTTPRequestOperation *operation, id responseObject) {
            self.labelTeamName.text = responseObject[@"name"];
            self.teamSportCell.detailTextLabel.text = responseObject[@"sport"];
            self.teamAreaCell.detailTextLabel.text = responseObject[@"area"];
            self.teamMemberCell.detailTextLabel.text = [NSString stringWithFormat:@"%@个", responseObject[@"members_count"]];
            if ([responseObject[@"avatar"] isEqualToString:@"blank.png!80x80"]) {
                self.imageTeamAvatar.image = [UIImage imageNamed: @"avatar.png"];
            } else {
                NSURLRequest *imageRequest = [NSURLRequest requestWithURL:[NSURL URLWithString:[NSString stringWithFormat:@"%@", responseObject[@"avatar"]]]];
                [self.imageTeamAvatar setImageWithURLRequest:imageRequest placeholderImage:nil success:^(NSURLRequest *request, NSHTTPURLResponse *response, UIImage *image) {
                    self.imageTeamAvatar.image = image;
                } failure:^(NSURLRequest *request, NSHTTPURLResponse *response, NSError *error) {
                    self.imageTeamAvatar.image = [UIImage imageNamed: @"avatar.png"];
                }];
            }
        } failure:^(AFHTTPRequestOperation *operation, NSError *error) {
            UIAlertView *alert = [[UIAlertView alloc] initWithTitle:@"异常提示" message:@"网络异常" delegate:self cancelButtonTitle:@"确定" otherButtonTitles: nil];
            [alert show];
        }];
    
        MRProgressOverlayView *overlayView = [MRProgressOverlayView showOverlayAddedTo:self.view animated:YES];
        [overlayView setModeAndProgressWithStateOfOperation:operation];
        [overlayView setStopBlockForOperation:operation];
    
        [self.tableView addHeaderWithTarget:self action:@selector(headerRereshing)];
    }
    
    type:enhancement 
    opened by 85636682 7
  • Cannot install pods and launch example

    Cannot install pods and launch example

    Hello,

    I am trying to launch example. But after pod install, I always get this error:

    Fetching podspec for `MRProgress` from `.`
    
    [!] Invalid `MRProgress.podspec` file: [!] A subspec can't require one of its parents specifications. Updating CocoaPods might fix the issue.
    
     #  from /Users/genimac/Downloads/MRProgress-master/Pods/Local Podspecs/MRProgress.podspec:66
     #  -------------------------------------------
     #        subspec spec_name do |subs|
     >          subs.dependency 'MRProgress/AFNetworking/Base'
     #          subs.dependency "MRProgress/#{spec_name}"
     #  -------------------------------------------
    

    My version of CocoaPods is 0.33.1

    Any help will be appreciated. Thanks in advance.

    P.S. I also tried to change Local Podspecs file, but each time it is replaced by autogenerated one...

    opened by antonc27 6
  • Features: iOS8 UIVisualEffectView Support

    Features: iOS8 UIVisualEffectView Support

    Uses UIVisualEffectView in combination with UIBlurEffect for the blur in MRProgressOverlayView.

    • [x] Blocked by iOS 8 GM.
    • [x] Blocked by rdar://18466755. (Specific to "classic" resolution on new phones.)
    type:enhancement 
    opened by mrackwitz 6
  • Flickering issue when rotating on iPad

    Flickering issue when rotating on iPad

    If using this component on an iPad, it is possible to cause the screen to flicker briefly while rotating the app. This is reproducible in the sample app. I am unsure if this happens in iPad apps - I have so far only tested this in iPhone apps running on an iPad. Perhaps the issue is related to rendering the blur texture?

    Steps to reproduce:

    • Load up the sample app on an iPad (or iPad Mini).
    • Get once of the progress overlays to appear on screen.
    • Rotate the device whilst it is visible.

    Using version 0.4.3.

    See the video for the glitch - it is quite subtle: https://drive.google.com/file/d/0B7hk_IdN2v-QUUFOcld6VGY2Y2JwYzViWlFxOTE1cy1RRzN3/edit?usp=sharing

    screen shot 2014-05-29 at 10 59 03

    type:enhancement 
    opened by jdmunro 6
  • Progress overlay background delay/sometimes missing

    Progress overlay background delay/sometimes missing

    I have noticed a bug/cosmetic issue with the white background of the progress overlay appearing after a delay, or occasionally not at all. This does not seem to happen in the simulator, but does on an iPhone 4S running 7.1 using the example app.

    Using version 0.4.3.

    Symptoms:

    • With animations disabled, the overlay background does not seem to appear at the same time as the actual progress spinner itself. I have attached a video, although it is quite subtle to see the effect.
    • This also is an issue when displaying the progress view with an animation. In some circumstances, the overlay view can appear, and be dismissed, before the background has actually appeared.

    The background not appearing at all is difficult to reproduce consistently as it does not seem to be deterministic, however, you can see the delay of the background appearing every time by using the sample app (on device) and presenting an overlay view without the animation - observe that the white background appears noticeably after the spinner component.

    Video: Unfortunately this isn't quite as clear as I would hoped. The best way to see is to skip through each frame invidually using Quicktime: https://drive.google.com/file/d/0B7hk_IdN2v-QYlQtSG5hdTBYOGFMWWNtZmVpeTR3Tm1kTm5V/edit?usp=sharing

    Images: screen shot 2014-05-27 at 11 34 02 screen shot 2014-05-27 at 11 34 07

    type:enhancement 
    opened by jdmunro 6
  • Crash on MRProgreessOverlayView.showOverlayAddedTo

    Crash on MRProgreessOverlayView.showOverlayAddedTo

    Getting error that crashes app: 2015-01-24 16:50:04.563 Pickle[24864:6627769] -[UIImage mr_applyBlurWithRadius:tintColor:saturationDeltaFactor:maskImage:]: unrecognized selector sent to instance 0x7f8255323820

    After calling: MRProgressOverlayView.showOverlayAddedTo(self.view.window, animated: true).

    The progress view shows up fine, but it appears that as soon as it tries to make its background an opaque white it is crashing.

    The offending line of code that Xcode is highlighting on the crash: image = [image mr_applyBlurWithRadius:30.0 tintColor:[UIColor colorWithWhite:0.97 alpha:0.82] saturationDeltaFactor:1.0 maskImage:nil]; Which is from the MRBlurView class.

    opened by dcgoss 5
  • Bug with custom fonts & smaller text sizes with iOS Dynamic Type

    Bug with custom fonts & smaller text sizes with iOS Dynamic Type

    If you change the Text Size to a smaller size for iOS Dynamic Type via Settings -> Display & Brightness -> Text Size, the MRProgressOverlayView's label appears to get cut off and not display the text properly.

    type:enhancement 
    opened by objectmethod 5
  • Fixing animation stop when switching controllers

    Fixing animation stop when switching controllers

    Use case:

    1. showing indeterminate progress in list at first controller
    2. push second controller
    3. animation is stopped when popped back to first controller

    This fixes that behaviour

    opened by horovodovodo4ka 4
  • Doesn't work in extensions

    Doesn't work in extensions

    MRProgressHelper.h and MRBlurView.m call +[UIApplication sharedApplication], which is not available in App Extensions, meaning that MRProgress will not compile for extension targets.

    MRProgress/src/Utils/MRProgressHelper.h:41:56: 'sharedApplication' is unavailable: not available on iOS (App Extension) - Use view controller based solutions where appropriate instead.

    image

    opened by lukaskollmer 0
  • How can i change color of .indeterminateSmallDefault

    How can i change color of .indeterminateSmallDefault

    MRProgressOverlayView.showOverlayAdded(to: self.view, title: text, mode: .indeterminateSmallDefault, animated: true) i have added code to MRProgress and working fine but i need to change activity indicator colour from gray to orange. So, how can i do this? please help me.

    opened by MahipalV12 0
  • How to send MRProgressView to other viewController?

    How to send MRProgressView to other viewController?

    Hi, I want to send the MRProgressView to the other viewController. I used it like this but it did not work.

    FirstViewController.m

    self.overlayView = [MRProgressOverlayView showOverlayAddedTo:self.navigationController.view animated:YES];        
    self.overlayView.mode = MRProgressOverlayViewModeIndeterminateSmall;
    self.overlayView.titleLabelText = @"";
    [AppDelegate setOverlayView:self.overlayView]
    

    AppDelegate.m

    // showing overlay = nil
    -(void)setOverlayView:(MRProgressOverlayView *)overlay{
      self.overlayView = overlay;
    }
    
    // I will get from here
    -(MRProgressOverlayView *)getOverlayView{
       return self.overlayView;
    }
    

    SecondViewController.m

    // call from here
    [[AppDelegate getOverlayView] dismiss:YES];
    

    But it always calls setOverlayView and says overlay = nil. why?

    opened by harunozdemir 0
  • Setting progress makes the overlay appear only when progress = 1

    Setting progress makes the overlay appear only when progress = 1

    Hello, trying to use MRProgress with AVAssetExportSession in swift 2.2 I want to display the overlay according the the session.progress value (going from 0 to 1). It seems however that setting the progress to the overlay does nothing until the value is equal to 1. If i did something wrong in my code could someone point me to the good direction? Here is the related code :

    if let exportSession = AVAssetExportSession(asset: urlAsset, presetName: Config.VIDEO_COMPRESSION_PRESET) { exportSession.outputURL = outputURL exportSession.outputFileType = AVFileTypeMPEG4 exportSession.shouldOptimizeForNetworkUse = true exportSession.timeRange = CMTimeRangeMake(kCMTimeZero, urlAsset.duration)

            exportSession.exportAsynchronouslyWithCompletionHandler { () -> Void in
                handler(session: exportSession)
            }
            dispatch_async(dispatch_get_main_queue(), { () -> Void in
                let overlayView = MRProgressOverlayView.showOverlayAddedTo(self.view, title: "Preparing", mode: .DeterminateCircular, animated: true)
                while exportSession.status == .Waiting || exportSession.status == .Exporting {
                    print("Progress: \(exportSession.progress * 100.0)%., progress \(exportSession.progress)")
                    overlayView.setProgress(exportSession.progress, animated: true)
                }
                overlayView.dismiss(true)
            })
        }
    

    output example from my print : Progress: 2.62599%., progress 0.0285576

    Or it can be due to the animation delay for the overlay to appear, not sure about that.

    opened by tirrorex 0
  • setProgress not working in Swift, docs need updating

    setProgress not working in Swift, docs need updating

    Hi guys,

    First off, thanks for putting this really amazing looking library out there

    Could someone please provide a solution as to how to implement this beautiful library in Swift

    I can load the OverlayView but I can't figure out how to connect the progress

    I am using Alamofire

    In my post request

    var progressFloat: Float = 0.0
    ...
                        upload.uploadProgress(closure: { //Get Progress
                            progress in
    
                            print(progress.fractionCompleted)
    
                           // cast value as float
                           progressFloat = Float(progress.fractionCompleted)
                            
                            // the initial overlay view gets loaded 
                            MRProgressOverlayView.showOverlayAdded(to: self.view, title: "Uploading", mode: MRProgressOverlayViewMode.determinateCircular, animated: true)
                            
                            // this is where I am stuck 
                            // setProgress is a child, but throws error:
    //  'use of instance member 'setProgress' on type MRProgressOverlayView'; did you mean to use a value of type MRProgressOverlayView
                            MRProgressOverlayView.setProgress(progressFloat, true)
    
                          // MRProgressView.setProgress doesn't work either 
    
    I am also getting the error 
    /Pods/MRProgress/src/Components/MRProgressOverlayView.m:815
    2017-01-23 16:23:32.207 MyProject[5844:139083] *** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'Mode must support setProgress:animated:, but doesnot!'
    
                            if progress.fractionCompleted == 1 {
                                print("Completed")
     
                                // this is also throwing an error 
                                MRProgressOverlayView.dismiss(self)
                            }
                        })
    
    opened by ghost 2
Releases(0.7.0)
  • 0.7.0(Sep 3, 2014)

    Summary

    This version makes all components more accessible, by providing appropiate UIAccessibility labels, traits and events by default, and in a localizable manner. Furthermore it fixes the issue, that you had a very small hit target for small activity indicators or progress views.

    Changelog

    • UIAccessibility support. (#60)
    • Ensure a min hit area of 44x44 for small stop buttons. (#38, #61)

    Release Details

    Source code(tar.gz)
    Source code(zip)
  • 0.6.0(Jul 22, 2014)

    Summary

    This version includes optional AFNetworking 2.0 support and a bug fix UIAppearance support. It doesn't install anymore some subspecs by default, which are not required.

    AFNetworking Usage

    1. Include the following additional line into your Podfile:

      pod 'MRProgress/AFNetworking'
      
    2. Import the adequate category header for the component you want to use:

      import <MRProgress/MRProgressOverlayView+AFNetworking.h>
      
    3. You can now just setup your task / operation as usual and use the category methods to bind to execution state and progress as shown below.

      // Init the progress overlay as usual
      MRProgressOverlayView *overlayView
      overlayView = [MRProgressOverlayView showOverlayAddedTo:self.view
                                                     animated:YES];
      
      // The following line will do these things automatically:
      // * Set mode to determinate when a download or upload is in progress
      // * Set animated progress of the download or upload
      // * Show a checkmark or cross pane at the end of the progress
      [overlayView setModeAndProgressWithStateOfTask:task];
      
      // Allows the user to cancel the task by using the provided stop button.
      // If you use that, make sure that you handle the error code, which will be
      // delivered to the failure block of the task like shown below:
      //
      //    if ([error.domain isEqualToString:NSURLErrorDomain]
      //      && error.code == NSURLErrorCancelled) {
      //        NSLog(@"Task was cancelled by user.");
      //        return;
      //    }
      //
      [overlayView setStopBlockForTask:task];
      
      // If you use the activity indicator directly
      [self.activityIndicatorView setAnimatingWithStateOfTask:task];
      
      // If you use one of the progress views directly ...
      // ... for uploads:
      [self.circularProgressView setProgressWithUploadProgressOfTask:downloadTask animated:YES];
      
      // ... for downloads:
      [self.circularProgressView setProgressWithDownloadProgressOfTask:downloadTask animated:YES];
      
      [[MRNavigationBarProgressView progressViewForNavigationController:self.navigationController]
      setProgressWithDownloadProgressOfTask:downloadTask animated:YES];
      

      All methods are available for both NSURLSessionTask and AFURLConnectionOperation and their descendants. For further examples, make sure to also checkout the Example app.

    Changelog

    • AFNetworking support. See above or the README for how to get it. (#25, #50)
    • Fixed bug in UIAppearance support. (#48, #52)
    • Make some subspecs optional, and not installed by default. This includes beside the new MRProgress/AFNetworking the following specs: MRProgress/MessageInterceptor and MRProgress/WeakProxy. If you relied implicitly on them, make sure to include them in your Podfile explicitly now.

    Release Details

    Source code(tar.gz)
    Source code(zip)
  • 0.5.0(Jun 2, 2014)

    Summary

    This version includes serveral bug fixes and enhancements for better customizability.

    Changelog

    • Fixed a flickering issue with MRBlurView, which happened on interface rotation. (#42)
    • Added a workaround for slower devices to circumvent the delay until the blurred background appears. (#39)
    • Added the property valueLabel to MRCircularProgressView. (#35)
    • Added the properties sizeRatio and highlightedSizeRatio to MRStopButton to configure the size of the stop button relative to the size of the progress view / activity indicator view. (#37)
    • Fixed a bug in MRCircularProgressView, which caused that the on-touch-down animation of the stop button was not visible. (#34)
    • Published the layer properties borderWidth and lineWidth over the UIAppearance API to make the appearance of the MRCircularProgressView more configurable. (#36)
    • Extended the Example application to demonstrate MRBlurView independently.

    Credits

    Thanks to @jdmunro for his excellent bug reports, backed by videos. Thanks for his help again by mentioning and informing about a bug and potential for enhancements and his pull-request go to @coneybeare. Thanks to @owenworley's attention to the details for finding a type typo.

    Release Details

    Source code(tar.gz)
    Source code(zip)
  • 0.4.2(Apr 22, 2014)

    Summary

    A bug fix, which is needed if you use Nibs or Storyboard and use iOS 7.1 as base SDK to compile your application. This does neither hurt MRProgress/Overlay nor existing apps deployed with iOS 7.0.

    Changelog

    • Fixed bad initialization since iOS 7.1 of MRProgress/Circular's MRCircularProgressView if loaded from Nibs.

    Did you know?

    Since iOS 7.1 tintColorDidChange won't be called automatically if the UIView is initialized / loaded from Nib, at least not in all cases. It is still called if it is initialized by initWithFrame:.

    Credits

    Thanks for his help by mentioning and informing about the issue go to @coneybeare.

    Release Details

    Source code(tar.gz)
    Source code(zip)
  • 0.4.0(Feb 26, 2014)

    Summary

    This release brings small subspecs, so that you can just depend on selected components. So if you want only to use the circular activity indicator, you can use now for example just pod MRProgress/Circular. This means that only this component will be compiled and linked into your project by CocoaPods. But you can also just use pod MRProgress as before. See also the following dependency tree:

    ─┬─MRProgress/
     │
     ├───Blur
     │
     ├───ActivityIndicator
     │
     ├───Circular
     │
     ├───Icons
     │
     ├─┬─NavigationBarProgress
     │ └───MessageInterceptor
     │
     ├─┬─Overlay
     │ ├───ActivityIndicator
     │ ├───Circular
     │ ├───Icons
     │ └───Blur
     │
     ├───MessageInterceptor
     │
     └───WeakProxy
    

    _Attention_: The third level in the tree is only thought to illustrate cross-dependencies, you can't reference the subspecs in this way.

    Changelog

    • Sliced podspec into subspecs
    • Fixed warnings in Xcode 5.0.2.

    Credits

    Thanks for their help by contributing code / creating issues go to:

    • @sdarlington

    Release Details

    Source code(tar.gz)
    Source code(zip)
  • 0.3.0(Jan 13, 2014)

    Summary

    This release brings new features, implementation improvements and a bug fix for a case of a crash in specific scenarios.

    Changelog

    • Cancel button for MRProgressOverlayView for the modes: Indeterminate and DeterminateCircular
    • Cancel button for MRActivityIndicatorView
    • Replaced CADisplayLink based animation in MRCircularProgressView by a property based animation. (The value label is still Timer-based "animated".)
    • Adds an optional completion block argument to dismiss methods, which is executed after the hide animation has been completed. (Keeps backwards-compatibility.)

    Credits

    Thanks for their help by contributing code / creating issues go to:

    • @noradaiko
    • @milkliker
    • @torben

    Release Details

    Source code(tar.gz)
    Source code(zip)
  • 0.2.2(Nov 17, 2013)

    Summary

    This release contains various improvements, several bug fixes for edge cases and API improvements.

    Changelog

    • Improved UIAppearanceAPI support
    • Improved layout if text of titleLabel is empty
    • Variable dialog width for small modes of `MRProgressOverlayView``
    • Added property lineWidth for MRActivityIndicatorView
    • Added showOverlayAddedTo: title: mode: animated:

    Credits

    Thanks for their help by contributing code / creating issues go to:

    • @cxa
    • @frapalla87
    • @jallen
    • @arkuana
    • @dennisreimann
    • @cabeca

    Release Details

    Source code(tar.gz)
    Source code(zip)
  • 0.2.1(Nov 4, 2013)

Owner
Marius Rackwitz
Cofounder @nlbb, Developer, Swift Pioneer @CocoaPods Core team, Conference Speaker. Email me to: contact@$firstName$lastName.de
Marius Rackwitz
Completely customizable progress based loaders drawn using custom CGPaths written in Swift

FillableLoaders Completely customizable progress based loaders drawn using custom CGPaths written in Swift Waves Plain Spike Rounded Demo: Changelog:

Pol Quintana 2.1k Dec 31, 2022
UIProgressView replacement with an highly and fully customizable animated progress bar in pure Core Graphics

The YLProgressBar is an UIProgressView replacement with a highly and fully customizable animated progress bar in pure Core Graphics. It has been imple

Yannick Loriot 1.3k Jan 5, 2023
A simple animated progress bar in Swift

DSGradientProgressView Introduction DSGradientProgressView is a simple and customizable animated progress bar written in Swift. Inspired by GradientPr

Dhol Studio 445 Oct 13, 2022
📊 A customizable gradient progress bar (UIProgressView).

GradientProgressBar A customizable gradient progress bar (UIProgressView). Inspired by iOS 7 Progress Bar from Codepen. Example To run the example pro

Felix M. 490 Dec 16, 2022
Simple and powerful animated progress bar with dots

Example To run the example project, clone the repo, and run pod install from the Example directory first. Requirements iOS 8.0+ Swift 3.0+ Installatio

Nikola Corlija 42 Dec 5, 2022
Step-by-step progress view with labels and shapes. A good replacement for UIActivityIndicatorView and UIProgressView.

StepProgressView Step-by-step progress view with labels and shapes. A good replacement for UIActivityIndicatorView and UIProgressView. Usage let progr

Yonat Sharon 340 Dec 16, 2022
💈 Retro looking progress bar straight from the 90s

Description Do you miss the 90s? We know you do. Dial-up internet, flickering screens, brightly colored websites and, of course, this annoyingly slow

HyperRedink 18 Nov 24, 2022
Simple Swift Progress HUD

MKProgress An iOS Simple Swift Progress HUD Requirements iOS 9.0+ Swift 3.0+ Xcode 8.0+ Installation MKProgress is only available via CocoaPods: pod '

Muhammad Kamran 143 Dec 23, 2022
A clean and lightweight progress HUD based on SVProgressHUD, converted to Swift with the help of Swiftify.

IHProgressHUD IHProgressHUD is a clean and easy-to-use HUD meant to display the progress of an ongoing task on iOS and tvOS. IHProgressHUD is based on

Swiftify 202 Dec 22, 2022
NVActivityIndicatorView is a collection of awesome loading animations.

NVActivityIndicatorView is a collection of awesome loading animations.

Vinh Nguyen 10.3k Jan 5, 2023
A beautiful activity indicator and modal alert written in Swift (originally developed for my app DoodleDoodle) Using blur effects, translucency, flat and bold design - all iOS 8 latest and greatest

SwiftSpinner SwiftSpinner is an extra beautiful activity indicator with plain and bold style. It uses dynamic blur and translucency to overlay the cur

Marin Todorov 2.1k Dec 19, 2022
The easiest way to handle a simple full screen activity indicator in iOS. Written in Swift.

LLSpinner An easy way to handle full screen activity indicator. Easy to use Get Started // Show spinner LLSpinner.spin() // Hide spinner LLSpinner.st

Aleph Retamal 36 Dec 9, 2021
A view class for iOS that makes uploading easy and beautiful.

SVUploader A view class for iOS that makes uploading easy and beautiful. Demo SVUploader is fully customizable - check out 2 demos. Installation Just

Kiran 79 Apr 18, 2022
A lightweight and awesome loading Activity Indicator for your iOS app.

BPCircleActivityIndicator BPCircleActivityIndicator is a clean and easy-to-use Activity Indicator meant to display the progress of an ongoing task on

Ben.Park 46 Aug 12, 2022
A simple and awesome loading Activity Indicator(with block moving animation) for your iOS app.

BPBlockActivityIndicator BPBlockActivityIndicator is a clean and easy-to-use Activity Indicator meant to display the progress of an ongoing task on iO

Ben.Park 43 Nov 6, 2021
IOS HUD Swift Library

JHProgressHUD JHProgressHUD is an iOS class written in Swift to display a translucent HUD with an indicator and/or labels while work is being done in

Harikrishnan T 79 Feb 27, 2021
Basic components for setting up UIKit components programmatically.

UIKit Components Package This repository contains basic components for setting up UIKit components programmatically. It is made by SPACE SQUAD! We mak

SPACE SQUAD 2 Sep 22, 2022
A few drop-in SwiftUI components for easily importing and thumb-nailing files

FilesUI A few drop-in SwiftUI components for easily importing and thumb-nailing files Usage 1. Import Files To import files you can use the FileImport

Brianna Zamora 3 Oct 19, 2022
A charting library to visualize and interact with a vector map on iOS. It's like Geochart but for iOS!

FSInteractiveMap A charting library to visualize data on a map. It's like geochart but for iOS! The idea behind this library is to load a SVG file of

Arthur 544 Dec 30, 2022
iOS app which uses the Moves API to visualize which places you spent the most time at in the last seven days.

Places Places uses the Moves API to visualize which places you spent the most time at in the last seven days. It runs on iOS 7 only and you need to ob

Boris Bügling 43 Feb 9, 2022