ProgressHUD.h 2.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354
  1. //
  2. // Copyright (c) 2016 Related Code - http://relatedcode.com
  3. //
  4. // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
  5. // IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
  6. // FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
  7. // AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
  8. // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
  9. // OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
  10. // THE SOFTWARE.
  11. #import <UIKit/UIKit.h>
  12. //-------------------------------------------------------------------------------------------------------------------------------------------------
  13. @interface ProgressHUD : UIView
  14. //-------------------------------------------------------------------------------------------------------------------------------------------------
  15. #pragma mark - Display methodsProgressHUD
  16. + (void)dismiss;
  17. + (void)show;
  18. + (void)show:(NSString *)status;
  19. + (void)show:(NSString *)status Interaction:(BOOL)interaction;
  20. + (void)showSuccess;
  21. + (void)showSuccess:(NSString *)status;
  22. + (void)showSuccess:(NSString *)status Interaction:(BOOL)interaction;
  23. + (void)showError;
  24. + (void)showError:(NSString *)status;
  25. + (void)showError:(NSString *)status Interaction:(BOOL)interaction;
  26. #pragma mark - Property methods
  27. + (void)statusFont:(UIFont *)font;
  28. + (void)statusColor:(UIColor *)color;
  29. + (void)spinnerColor:(UIColor *)color;
  30. + (void)hudColor:(UIColor *)color;
  31. + (void)backgroundColor:(UIColor *)color;
  32. + (void)imageSuccess:(UIImage *)image;
  33. + (void)imageError:(UIImage *)image;
  34. #pragma mark - Properties
  35. @property (strong, nonatomic) UIFont *statusFont;
  36. @property (strong, nonatomic) UIColor *statusColor;
  37. @property (strong, nonatomic) UIColor *spinnerColor;
  38. @property (strong, nonatomic) UIColor *hudColor;
  39. @property (strong, nonatomic) UIColor *backgroundColor;
  40. @property (strong, nonatomic) UIImage *imageSuccess;
  41. @property (strong, nonatomic) UIImage *imageError;
  42. @end