Browse Source

update project

Marino Faggiana 6 years ago
parent
commit
3942ae7fbf
49 changed files with 1621 additions and 188 deletions
  1. 1 0
      Cartfile
  2. 1 0
      Cartfile.resolved
  3. 20 0
      Carthage/Checkouts/JDStatusBarNotification/.gitignore
  4. 101 0
      Carthage/Checkouts/JDStatusBarNotification/ExampleProject/JDStatusBarNotificationExample/Images.xcassets/AppIcon.appiconset/Contents.json
  5. BIN
      Carthage/Checkouts/JDStatusBarNotification/ExampleProject/JDStatusBarNotificationExample/Images.xcassets/AppIcon.appiconset/Icon60x60@2x.png
  6. BIN
      Carthage/Checkouts/JDStatusBarNotification/ExampleProject/JDStatusBarNotificationExample/Images.xcassets/AppIcon.appiconset/Icon76x76.png
  7. BIN
      Carthage/Checkouts/JDStatusBarNotification/ExampleProject/JDStatusBarNotificationExample/Images.xcassets/AppIcon.appiconset/Icon76x76@2x.png
  8. 52 0
      Carthage/Checkouts/JDStatusBarNotification/ExampleProject/JDStatusBarNotificationExample/Images.xcassets/LaunchImage.launchimage/Contents.json
  9. BIN
      Carthage/Checkouts/JDStatusBarNotification/ExampleProject/JDStatusBarNotificationExample/Images.xcassets/LaunchImage.launchimage/default6+.png
  10. BIN
      Carthage/Checkouts/JDStatusBarNotification/ExampleProject/JDStatusBarNotificationExample/Images.xcassets/LaunchImage.launchimage/default6.png
  11. BIN
      Carthage/Checkouts/JDStatusBarNotification/ExampleProject/JDStatusBarNotificationExample/Images.xcassets/LaunchImage.launchimage/defaultRetina4.png
  12. BIN
      Carthage/Checkouts/JDStatusBarNotification/ExampleProject/JDStatusBarNotificationExample/Images.xcassets/LaunchImage.launchimage/x.png
  13. 44 0
      Carthage/Checkouts/JDStatusBarNotification/ExampleProject/JDStatusBarNotificationExample/JDStatusBarNotificationExample-Info.plist
  14. 16 0
      Carthage/Checkouts/JDStatusBarNotification/ExampleProject/JDStatusBarNotificationExample/JDStatusBarNotificationExample-Prefix.pch
  15. 15 0
      Carthage/Checkouts/JDStatusBarNotification/ExampleProject/JDStatusBarNotificationExample/SBAppDelegate.h
  16. 26 0
      Carthage/Checkouts/JDStatusBarNotification/ExampleProject/JDStatusBarNotificationExample/SBAppDelegate.m
  17. 39 0
      Carthage/Checkouts/JDStatusBarNotification/ExampleProject/JDStatusBarNotificationExample/SBCustomStyleViewController.h
  18. 321 0
      Carthage/Checkouts/JDStatusBarNotification/ExampleProject/JDStatusBarNotificationExample/SBCustomStyleViewController.m
  19. 281 0
      Carthage/Checkouts/JDStatusBarNotification/ExampleProject/JDStatusBarNotificationExample/SBCustomStyleViewController.xib
  20. 13 0
      Carthage/Checkouts/JDStatusBarNotification/ExampleProject/JDStatusBarNotificationExample/SBExampleViewController.h
  21. 235 0
      Carthage/Checkouts/JDStatusBarNotification/ExampleProject/JDStatusBarNotificationExample/SBExampleViewController.m
  22. 20 0
      Carthage/Checkouts/JDStatusBarNotification/ExampleProject/JDStatusBarNotificationExample/SBSelectPropertyViewController.h
  23. 70 0
      Carthage/Checkouts/JDStatusBarNotification/ExampleProject/JDStatusBarNotificationExample/SBSelectPropertyViewController.m
  24. 18 0
      Carthage/Checkouts/JDStatusBarNotification/ExampleProject/JDStatusBarNotificationExample/main.m
  25. 9 0
      Carthage/Checkouts/JDStatusBarNotification/ExampleProject/Podfile
  26. 20 0
      Carthage/Checkouts/JDStatusBarNotification/ExampleProject/Podfile.lock
  27. 20 0
      Carthage/Checkouts/JDStatusBarNotification/JDStatusBarNotification.podspec
  28. 10 0
      Carthage/Checkouts/JDStatusBarNotification/JDStatusBarNotification/JDStatusBarLayoutMarginHelper.h
  29. 19 0
      Carthage/Checkouts/JDStatusBarNotification/JDStatusBarNotification/JDStatusBarLayoutMarginHelper.m
  30. 11 2
      Carthage/Checkouts/JDStatusBarNotification/JDStatusBarNotification/JDStatusBarNotification.h
  31. 67 27
      Carthage/Checkouts/JDStatusBarNotification/JDStatusBarNotification/JDStatusBarNotification.m
  32. 106 0
      Carthage/Checkouts/JDStatusBarNotification/JDStatusBarNotification/JDStatusBarStyle.h
  33. 2 0
      Carthage/Checkouts/JDStatusBarNotification/JDStatusBarNotification/JDStatusBarStyle.m
  34. 6 3
      Carthage/Checkouts/JDStatusBarNotification/JDStatusBarNotification/JDStatusBarView.h
  35. 19 50
      Carthage/Checkouts/JDStatusBarNotification/JDStatusBarNotification/JDStatusBarView.m
  36. 25 0
      Carthage/Checkouts/JDStatusBarNotification/LICENSE
  37. 24 0
      Carthage/Checkouts/JDStatusBarNotification/Miscellaneous/Info.plist
  38. BIN
      Carthage/Checkouts/JDStatusBarNotification/gfx/activity.gif
  39. BIN
      Carthage/Checkouts/JDStatusBarNotification/gfx/animation.gif
  40. BIN
      Carthage/Checkouts/JDStatusBarNotification/gfx/iphoneX.png
  41. BIN
      Carthage/Checkouts/JDStatusBarNotification/gfx/progress.gif
  42. BIN
      Carthage/Checkouts/JDStatusBarNotification/gfx/screenshots.png
  43. BIN
      Carthage/Checkouts/JDStatusBarNotification/gfx/styles.png
  44. BIN
      Carthage/Checkouts/JDStatusBarNotification/gfx/tweetbutton.png
  45. 0 77
      Libraries external/JDStatusBarNotification/JDStatusBarStyle.h
  46. 5 26
      Nextcloud.xcodeproj/project.pbxproj
  47. 1 1
      iOSClient/AppDelegate.m
  48. 2 1
      iOSClient/Main/CCMain.m
  49. 2 1
      iOSClient/Settings/CCManageAccount.m

+ 1 - 0
Cartfile

@@ -5,3 +5,4 @@ github "sgr-ksmt/PDFGenerator" ~> 2.1
 github "MortimerGoro/MGSwipeTableCell"
 github "dzenbot/DZNEmptyDataSet"
 github "ealeksandrov/EAIntroView"
+github "calimarkus/JDStatusBarNotification"

+ 1 - 0
Cartfile.resolved

@@ -1,4 +1,5 @@
 github "MortimerGoro/MGSwipeTableCell" "1.6.7"
+github "calimarkus/JDStatusBarNotification" "1.6.0"
 github "danielsaidi/Sheeeeeeeeet" "1.0.1"
 github "dzenbot/DZNEmptyDataSet" "v1.8.1"
 github "ealeksandrov/EAIntroView" "2.12.0"

+ 20 - 0
Carthage/Checkouts/JDStatusBarNotification/.gitignore

@@ -0,0 +1,20 @@
+# Xcode
+.DS_Store
+build/
+*.pbxuser
+!default.pbxuser
+*.mode1v3
+!default.mode1v3
+*.mode2v3
+!default.mode2v3
+*.perspectivev3
+!default.perspectivev3
+*.xcworkspace
+!default.xcworkspace
+xcuserdata
+xcuserdatad
+profile
+*.moved-aside
+DerivedData
+.xcconfig
+ExampleProject/Pods/

+ 101 - 0
Carthage/Checkouts/JDStatusBarNotification/ExampleProject/JDStatusBarNotificationExample/Images.xcassets/AppIcon.appiconset/Contents.json

@@ -0,0 +1,101 @@
+{
+  "images" : [
+    {
+      "idiom" : "iphone",
+      "size" : "20x20",
+      "scale" : "2x"
+    },
+    {
+      "idiom" : "iphone",
+      "size" : "20x20",
+      "scale" : "3x"
+    },
+    {
+      "idiom" : "iphone",
+      "size" : "29x29",
+      "scale" : "2x"
+    },
+    {
+      "idiom" : "iphone",
+      "size" : "29x29",
+      "scale" : "3x"
+    },
+    {
+      "idiom" : "iphone",
+      "size" : "40x40",
+      "scale" : "2x"
+    },
+    {
+      "idiom" : "iphone",
+      "size" : "40x40",
+      "scale" : "3x"
+    },
+    {
+      "size" : "60x60",
+      "idiom" : "iphone",
+      "filename" : "Icon60x60@2x.png",
+      "scale" : "2x"
+    },
+    {
+      "idiom" : "iphone",
+      "size" : "60x60",
+      "scale" : "3x"
+    },
+    {
+      "idiom" : "ipad",
+      "size" : "20x20",
+      "scale" : "1x"
+    },
+    {
+      "idiom" : "ipad",
+      "size" : "20x20",
+      "scale" : "2x"
+    },
+    {
+      "idiom" : "ipad",
+      "size" : "29x29",
+      "scale" : "1x"
+    },
+    {
+      "idiom" : "ipad",
+      "size" : "29x29",
+      "scale" : "2x"
+    },
+    {
+      "idiom" : "ipad",
+      "size" : "40x40",
+      "scale" : "1x"
+    },
+    {
+      "idiom" : "ipad",
+      "size" : "40x40",
+      "scale" : "2x"
+    },
+    {
+      "size" : "76x76",
+      "idiom" : "ipad",
+      "filename" : "Icon76x76.png",
+      "scale" : "1x"
+    },
+    {
+      "size" : "76x76",
+      "idiom" : "ipad",
+      "filename" : "Icon76x76@2x.png",
+      "scale" : "2x"
+    },
+    {
+      "idiom" : "ipad",
+      "size" : "83.5x83.5",
+      "scale" : "2x"
+    },
+    {
+      "idiom" : "ios-marketing",
+      "size" : "1024x1024",
+      "scale" : "1x"
+    }
+  ],
+  "info" : {
+    "version" : 1,
+    "author" : "xcode"
+  }
+}

BIN
Carthage/Checkouts/JDStatusBarNotification/ExampleProject/JDStatusBarNotificationExample/Images.xcassets/AppIcon.appiconset/Icon60x60@2x.png


BIN
Carthage/Checkouts/JDStatusBarNotification/ExampleProject/JDStatusBarNotificationExample/Images.xcassets/AppIcon.appiconset/Icon76x76.png


BIN
Carthage/Checkouts/JDStatusBarNotification/ExampleProject/JDStatusBarNotificationExample/Images.xcassets/AppIcon.appiconset/Icon76x76@2x.png


+ 52 - 0
Carthage/Checkouts/JDStatusBarNotification/ExampleProject/JDStatusBarNotificationExample/Images.xcassets/LaunchImage.launchimage/Contents.json

@@ -0,0 +1,52 @@
+{
+  "images" : [
+    {
+      "extent" : "full-screen",
+      "idiom" : "iphone",
+      "subtype" : "2436h",
+      "filename" : "x.png",
+      "minimum-system-version" : "11.0",
+      "orientation" : "portrait",
+      "scale" : "3x"
+    },
+    {
+      "extent" : "full-screen",
+      "idiom" : "iphone",
+      "subtype" : "736h",
+      "filename" : "default6+.png",
+      "minimum-system-version" : "8.0",
+      "orientation" : "portrait",
+      "scale" : "3x"
+    },
+    {
+      "extent" : "full-screen",
+      "idiom" : "iphone",
+      "subtype" : "667h",
+      "filename" : "default6.png",
+      "minimum-system-version" : "8.0",
+      "orientation" : "portrait",
+      "scale" : "2x"
+    },
+    {
+      "orientation" : "portrait",
+      "idiom" : "iphone",
+      "filename" : "defaultRetina4.png",
+      "extent" : "full-screen",
+      "minimum-system-version" : "7.0",
+      "scale" : "2x"
+    },
+    {
+      "extent" : "full-screen",
+      "idiom" : "iphone",
+      "subtype" : "retina4",
+      "filename" : "defaultRetina4.png",
+      "minimum-system-version" : "7.0",
+      "orientation" : "portrait",
+      "scale" : "2x"
+    }
+  ],
+  "info" : {
+    "version" : 1,
+    "author" : "xcode"
+  }
+}

BIN
Carthage/Checkouts/JDStatusBarNotification/ExampleProject/JDStatusBarNotificationExample/Images.xcassets/LaunchImage.launchimage/default6+.png


BIN
Carthage/Checkouts/JDStatusBarNotification/ExampleProject/JDStatusBarNotificationExample/Images.xcassets/LaunchImage.launchimage/default6.png


BIN
Carthage/Checkouts/JDStatusBarNotification/ExampleProject/JDStatusBarNotificationExample/Images.xcassets/LaunchImage.launchimage/defaultRetina4.png


BIN
Carthage/Checkouts/JDStatusBarNotification/ExampleProject/JDStatusBarNotificationExample/Images.xcassets/LaunchImage.launchimage/x.png


+ 44 - 0
Carthage/Checkouts/JDStatusBarNotification/ExampleProject/JDStatusBarNotificationExample/JDStatusBarNotificationExample-Info.plist

@@ -0,0 +1,44 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
+<plist version="1.0">
+<dict>
+	<key>CFBundleDevelopmentRegion</key>
+	<string>en</string>
+	<key>CFBundleDisplayName</key>
+	<string>Notifications</string>
+	<key>CFBundleExecutable</key>
+	<string>${EXECUTABLE_NAME}</string>
+	<key>CFBundleIdentifier</key>
+	<string>$(PRODUCT_BUNDLE_IDENTIFIER)</string>
+	<key>CFBundleInfoDictionaryVersion</key>
+	<string>6.0</string>
+	<key>CFBundleName</key>
+	<string>${PRODUCT_NAME}</string>
+	<key>CFBundlePackageType</key>
+	<string>APPL</string>
+	<key>CFBundleShortVersionString</key>
+	<string>1.0</string>
+	<key>CFBundleVersion</key>
+	<string>1.0</string>
+	<key>LSRequiresIPhoneOS</key>
+	<true/>
+	<key>UIRequiredDeviceCapabilities</key>
+	<array>
+		<string>armv7</string>
+	</array>
+	<key>UISupportedInterfaceOrientations</key>
+	<array>
+		<string>UIInterfaceOrientationPortrait</string>
+		<string>UIInterfaceOrientationPortraitUpsideDown</string>
+		<string>UIInterfaceOrientationLandscapeLeft</string>
+		<string>UIInterfaceOrientationLandscapeRight</string>
+	</array>
+	<key>UISupportedInterfaceOrientations~ipad</key>
+	<array>
+		<string>UIInterfaceOrientationPortrait</string>
+		<string>UIInterfaceOrientationPortraitUpsideDown</string>
+		<string>UIInterfaceOrientationLandscapeLeft</string>
+		<string>UIInterfaceOrientationLandscapeRight</string>
+	</array>
+</dict>
+</plist>

+ 16 - 0
Carthage/Checkouts/JDStatusBarNotification/ExampleProject/JDStatusBarNotificationExample/JDStatusBarNotificationExample-Prefix.pch

@@ -0,0 +1,16 @@
+//
+//  Prefix header
+//
+//  The contents of this file are implicitly included at the beginning of every source file.
+//
+
+#import <Availability.h>
+
+#ifndef __IPHONE_3_0
+#warning "This project uses features only available in iOS SDK 3.0 and later."
+#endif
+
+#ifdef __OBJC__
+    #import <UIKit/UIKit.h>
+    #import <Foundation/Foundation.h>
+#endif

+ 15 - 0
Carthage/Checkouts/JDStatusBarNotification/ExampleProject/JDStatusBarNotificationExample/SBAppDelegate.h

@@ -0,0 +1,15 @@
+//
+//  SBAppDelegate.h
+//  JDStatusBarNotificationExample
+//
+//  Created by Markus on 29.10.13.
+//  Copyright (c) 2013 Markus. All rights reserved.
+//
+
+#import <UIKit/UIKit.h>
+
+@interface SBAppDelegate : UIResponder <UIApplicationDelegate>
+
+@property (strong, nonatomic) UIWindow *window;
+
+@end

+ 26 - 0
Carthage/Checkouts/JDStatusBarNotification/ExampleProject/JDStatusBarNotificationExample/SBAppDelegate.m

@@ -0,0 +1,26 @@
+//
+//  SBAppDelegate.m
+//  JDStatusBarNotificationExample
+//
+//  Created by Markus on 29.10.13.
+//  Copyright (c) 2013 Markus. All rights reserved.
+//
+
+#import "SBExampleViewController.h"
+
+#import "SBAppDelegate.h"
+
+@implementation SBAppDelegate
+
+- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
+{
+  self.window = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]];
+  self.window.backgroundColor = [UIColor whiteColor];
+  self.window.rootViewController = [[UINavigationController alloc] initWithRootViewController:
+                                    [[SBExampleViewController alloc] initWithStyle:UITableViewStyleGrouped]];
+  [self.window makeKeyAndVisible];
+
+  return YES;
+}
+
+@end

+ 39 - 0
Carthage/Checkouts/JDStatusBarNotification/ExampleProject/JDStatusBarNotificationExample/SBCustomStyleViewController.h

@@ -0,0 +1,39 @@
+//
+//  SBCustomStyleViewController.h
+//  JDStatusBarNotificationExample
+//
+//  Created by Markus on 08.11.13.
+//  Copyright (c) 2013 Markus. All rights reserved.
+//
+
+#import <UIKit/UIKit.h>
+
+@interface SBCustomStyleViewController : UIViewController
+
+@property (weak, nonatomic) IBOutlet UIScrollView *scrollView;
+@property (weak, nonatomic) IBOutlet UIView *bottomBarView;
+@property (weak, nonatomic) IBOutlet UITextField *textField;
+@property (weak, nonatomic) IBOutlet UIButton *fontButton;
+@property (weak, nonatomic) IBOutlet UIView *textColorPreview;
+@property (weak, nonatomic) IBOutlet UIView *barColorPreview;
+@property (weak, nonatomic) IBOutlet UIButton *animationStyleButton;
+@property (weak, nonatomic) IBOutlet UIButton *heightForIPhoneXButton;
+@property (weak, nonatomic) IBOutlet UIView *progressBarColorPreview;
+@property (weak, nonatomic) IBOutlet UIButton *barPositionButton;
+@property (weak, nonatomic) IBOutlet UILabel *barHeightLabel;
+@property (weak, nonatomic) IBOutlet UIView *lastRow;
+
+- (IBAction)selectFont:(id)sender;
+- (IBAction)selectFontSize:(UIStepper*)sender;
+- (IBAction)selectTextColor:(id)sender;
+- (IBAction)selectBarColor:(id)sender;
+- (IBAction)selectAnimationStyle:(id)sender;
+- (IBAction)selectIPhoneXHeight:(id)sender;
+- (IBAction)selectProgressBarColor:(id)sender;
+- (IBAction)selectProgressBarPosition:(id)sender;
+- (IBAction)setProgressBarHeight:(UIStepper*)sender;
+
+- (IBAction)show:(id)sender;
+- (IBAction)showWithProgress:(id)sender;
+
+@end

+ 321 - 0
Carthage/Checkouts/JDStatusBarNotification/ExampleProject/JDStatusBarNotificationExample/SBCustomStyleViewController.m

@@ -0,0 +1,321 @@
+//
+//  SBCustomStyleViewController.m
+//  JDStatusBarNotificationExample
+//
+//  Created by Markus on 08.11.13.
+//  Copyright (c) 2013 Markus. All rights reserved.
+//
+
+#import <QuartzCore/QuartzCore.h>
+#import "JDStatusBarLayoutMarginHelper.h"
+#import "JDStatusBarNotification.h"
+#import "FTFontSelectorController.h"
+#import "SBSelectPropertyViewController.h"
+#import "InfColorPicker.h"
+
+#import "SBCustomStyleViewController.h"
+
+@interface SBCustomStyleViewController () <UITextFieldDelegate, FTFontSelectorControllerDelegate, InfColorPickerControllerDelegate>
+@property (nonatomic, assign) NSInteger colorMode;
+@property (nonatomic, assign) CGFloat progress;
+@property (nonatomic, weak) NSTimer *timer;
+
+@property (nonatomic, assign) JDStatusBarHeightForIPhoneX heightForIPhoneX;
+@property (nonatomic, assign) JDStatusBarAnimationType animationType;
+@property (nonatomic, assign) JDStatusBarProgressBarPosition progressBarPosition;
+@end
+
+@implementation SBCustomStyleViewController
+
+- (void)viewDidLoad;
+{
+    [super viewDidLoad];
+    
+    self.animationType = JDStatusBarAnimationTypeMove;
+    self.heightForIPhoneX = JDStatusBarHeightForIPhoneXFullNavBar;
+    self.progressBarPosition = JDStatusBarProgressBarPositionBottom;
+    
+    self.textColorPreview.backgroundColor = self.fontButton.titleLabel.textColor;
+    self.barColorPreview.backgroundColor = [UIColor colorWithWhite:0.9 alpha:1.000];
+    self.progressBarColorPreview.backgroundColor = [UIColor redColor];
+    
+    self.textColorPreview.layer.cornerRadius = round(CGRectGetHeight(self.textColorPreview.frame)/3.0);
+    self.barColorPreview.layer.cornerRadius = self.textColorPreview.layer.cornerRadius;
+    self.progressBarColorPreview.layer.cornerRadius = self.textColorPreview.layer.cornerRadius;
+    
+    [self updateFontText];
+    [self updateStyle];
+
+    [self adjustForLayoutMargin];
+}
+
+- (void)adjustForLayoutMargin
+{
+    // adjust bottom bar to respect layout margins
+    CGFloat bottomLayoutMargin = JDStatusBarRootVCLayoutMargin().bottom;
+
+    CGRect frame = self.bottomBarView.frame;
+    frame.origin.y -= bottomLayoutMargin;
+    frame.size.height += bottomLayoutMargin;
+    self.bottomBarView.frame = frame;
+
+    CGRect scrollViewFrame = self.scrollView.frame;
+    scrollViewFrame.size.height -= bottomLayoutMargin;
+    self.scrollView.frame = scrollViewFrame;
+}
+
+- (void)viewDidLayoutSubviews;
+{
+    [super viewDidLayoutSubviews];
+    
+    self.scrollView.contentSize = CGSizeMake(self.scrollView.frame.size.width,
+                                             self.lastRow.frame.origin.y + self.lastRow.frame.size.height + 10.0);
+}
+
+#pragma mark UI Updates
+
+- (void)updateFontText;
+{
+    NSString *title = [NSString stringWithFormat: @"Change font (%.1f pt)",
+                       self.fontButton.titleLabel.font.pointSize];
+    [self.fontButton setTitle:title forState:UIControlStateNormal];
+    self.textColorPreview.backgroundColor = self.fontButton.titleLabel.textColor;
+}
+
+- (void)updateStyle;
+{
+    [JDStatusBarNotification addStyleNamed:@"style" prepare:^JDStatusBarStyle *(JDStatusBarStyle *style) {
+        style.font = self.fontButton.titleLabel.font;
+        style.textColor = self.textColorPreview.backgroundColor;
+        style.barColor = self.barColorPreview.backgroundColor;
+        style.animationType = self.animationType;
+        style.heightForIPhoneX = self.heightForIPhoneX;
+
+        style.progressBarColor = self.progressBarColorPreview.backgroundColor;
+        style.progressBarPosition = self.progressBarPosition;
+
+        NSString *height = [self.barHeightLabel.text stringByReplacingOccurrencesOfString:@"ProgressBarHeight (" withString:@""];
+        height = [height stringByReplacingOccurrencesOfString:@" pt)" withString:@""];
+        style.progressBarHeight = [height doubleValue];
+
+        return style;
+    }];
+}
+
+#pragma mark UITextFieldDelegate
+
+- (BOOL)textFieldShouldReturn:(UITextField *)textField
+{
+    [textField resignFirstResponder];
+    
+    if (textField.text.length == 0) {
+        textField.text = @"Notification Text";
+    }
+    
+    [self show:nil];
+    
+    return YES;
+}
+
+#pragma mark FTFontSelectorControllerDelegate
+
+- (void)fontSelectorControllerShouldBeDismissed:(FTFontSelectorController *)controller;
+{
+    [self dismissViewControllerAnimated:YES completion:nil];
+}
+
+- (void)fontSelectorController:(FTFontSelectorController *)controller didChangeSelectedFontName:(NSString *)fontName;
+{
+    self.fontButton.titleLabel.font = [UIFont fontWithName:fontName size:self.fontButton.titleLabel.font.pointSize];
+    [self updateFontText];
+    [self updateStyle];
+}
+
+#pragma mark InfColorPicker
+
+- (void)showColorPickerWithColor:(UIColor*)color;
+{
+    InfColorPickerController *colorController = [InfColorPickerController colorPickerViewController];
+    colorController.delegate = self;
+    colorController.sourceColor = color;
+    colorController.resultColor = color;
+    [colorController presentModallyOverViewController:self];
+    
+    if([[[UIDevice currentDevice] systemVersion] floatValue] >= 7.0) {
+        UIView *view = colorController.view;
+        colorController.view = [[UIView alloc] initWithFrame:view.frame];
+        colorController.view.backgroundColor = [UIColor blackColor];
+        view.frame = CGRectMake(0, 64, view.bounds.size.width, view.bounds.size.height-64);
+        [colorController.view addSubview:view];
+    }
+}
+
+#pragma mark InfColorPickerControllerDelegate
+
+- (void)colorPickerControllerDidChangeColor:(InfColorPickerController *)controller;
+{
+    switch (self.colorMode) {
+        case 0: {
+            [self.fontButton setTitleColor:controller.resultColor forState:UIControlStateNormal];
+            self.textColorPreview.backgroundColor = controller.resultColor;
+            [self updateFontText];
+            break;
+        }
+        case 1: {
+            self.barColorPreview.backgroundColor = controller.resultColor;
+            break;
+        }
+        case 2: {
+            self.progressBarColorPreview.backgroundColor = controller.resultColor;
+            break;
+        }
+    }
+    
+    [self updateStyle];
+}
+
+- (void)colorPickerControllerDidFinish:(InfColorPickerController *)controller;
+{
+    [self dismissViewControllerAnimated:YES completion:nil];
+}
+
+#pragma mark Actions
+
+- (IBAction)selectFont:(id)sender;
+{
+    FTFontSelectorController *fontController = [[FTFontSelectorController alloc] initWithSelectedFontName:self.fontButton.titleLabel.font.fontName];
+    [fontController setFontDelegate:self];
+    [self presentViewController:fontController
+                       animated:YES completion:nil];
+}
+
+- (IBAction)selectFontSize:(UIStepper*)sender;
+{
+    self.fontButton.titleLabel.font = [UIFont fontWithName:self.fontButton.titleLabel.font.fontName size:sender.value];
+    [self updateFontText];
+    [self updateStyle];
+}
+
+- (IBAction)selectTextColor:(id)sender;
+{
+    self.colorMode = 0;
+    [self showColorPickerWithColor:self.textColorPreview.backgroundColor];
+}
+
+- (IBAction)selectBarColor:(id)sender;
+{
+    self.colorMode = 1;
+    [self showColorPickerWithColor:self.barColorPreview.backgroundColor];
+}
+
+- (IBAction)selectAnimationStyle:(id)sender;
+{
+  NSArray *data = @[@"JDStatusBarAnimationTypeNone",
+                    @"JDStatusBarAnimationTypeMove",
+                    @"JDStatusBarAnimationTypeBounce",
+                    @"JDStatusBarAnimationTypeFade"];
+  SBSelectPropertyViewController *controller = [[SBSelectPropertyViewController alloc] initWithData:data resultBlock:^(NSInteger selectedRow) {
+    self.animationType = selectedRow;
+    [self.animationStyleButton setTitle:data[selectedRow] forState:UIControlStateNormal];
+    [self.navigationController popViewControllerAnimated:YES];
+    [self updateStyle];
+  }];
+  controller.title = @"Animation Type";
+  controller.activeRow = self.animationType;
+  [self.navigationController pushViewController:controller animated:YES];
+}
+
+- (IBAction)selectIPhoneXHeight:(id)sender;
+{
+  NSArray *data = @[@"JDStatusBarHeightForIPhoneXHalf",
+                    @"JDStatusBarHeightForIPhoneXFullNavBar"];
+  SBSelectPropertyViewController *controller = [[SBSelectPropertyViewController alloc] initWithData:data resultBlock:^(NSInteger selectedRow) {
+    self.heightForIPhoneX = selectedRow;
+    [self.heightForIPhoneXButton setTitle:data[selectedRow] forState:UIControlStateNormal];
+    [self.navigationController popViewControllerAnimated:YES];
+    [self updateStyle];
+  }];
+  controller.title = @"Height for iPhoneX";
+  controller.activeRow = self.heightForIPhoneX;
+  [self.navigationController pushViewController:controller animated:YES];
+}
+
+- (IBAction)selectProgressBarColor:(id)sender;
+{
+    self.colorMode = 2;
+    [self showColorPickerWithColor:self.progressBarColorPreview.backgroundColor];
+}
+
+- (IBAction)selectProgressBarPosition:(id)sender;
+{
+    NSArray *data = @[@"JDStatusBarProgressBarPositionBottom",
+                      @"JDStatusBarProgressBarPositionCenter",
+                      @"JDStatusBarProgressBarPositionTop",
+                      @"JDStatusBarProgressBarPositionBelow",
+                      @"JDStatusBarProgressBarPositionNavBar"];
+    SBSelectPropertyViewController *controller = [[SBSelectPropertyViewController alloc] initWithData:data resultBlock:^(NSInteger selectedRow) {
+        self.progressBarPosition = selectedRow;
+        [self.barPositionButton setTitle:data[selectedRow] forState:UIControlStateNormal];
+        [self.navigationController popViewControllerAnimated:YES];
+        [self updateStyle];
+    }];
+    controller.title = @"Progress Bar Position";
+    controller.activeRow = self.progressBarPosition;
+    [self.navigationController pushViewController:controller animated:YES];
+}
+
+- (IBAction)setProgressBarHeight:(UIStepper*)sender;
+{
+    if (sender.value < 1) sender.value = 0.5;
+    if (sender.value >= 1) sender.value = round(sender.value);
+    
+    self.barHeightLabel.text = [NSString stringWithFormat: @"ProgressBarHeight (%.1f pt)", sender.value];
+    [self updateStyle];
+}
+
+#pragma mark Presentation
+
+- (IBAction)show:(id)sender;
+{
+    [JDStatusBarNotification showWithStatus:self.textField.text dismissAfter:2.0 styleName:@"style"];
+}
+
+- (IBAction)showWithProgress:(id)sender;
+{
+    double delayInSeconds = [JDStatusBarNotification isVisible] ? 0.0 : 0.25;
+    dispatch_time_t popTime = dispatch_time(DISPATCH_TIME_NOW, (int64_t)(delayInSeconds * NSEC_PER_SEC));
+    dispatch_after(popTime, dispatch_get_main_queue(), ^(void){
+        self.progress = 0.0;
+        [self startTimer];
+    });
+    
+    [JDStatusBarNotification showWithStatus:self.textField.text dismissAfter:1.3 styleName:@"style"];
+}
+
+#pragma mark Progress Timer
+
+- (void)startTimer;
+{
+    [JDStatusBarNotification showProgress:self.progress];
+    
+    [self.timer invalidate];
+    self.timer = nil;
+    
+    if (self.progress < 1.0) {
+        CGFloat step = 0.02;
+        self.timer = [NSTimer scheduledTimerWithTimeInterval:step target:self
+                                                    selector:@selector(startTimer)
+                                                    userInfo:nil repeats:NO];
+        self.progress += step;
+    } else {
+        [self performSelector:@selector(hideProgress)
+                   withObject:nil afterDelay:0.5];
+    }
+}
+
+- (void)hideProgress;
+{
+    [JDStatusBarNotification showProgress:0.0];
+}
+
+@end

+ 281 - 0
Carthage/Checkouts/JDStatusBarNotification/ExampleProject/JDStatusBarNotificationExample/SBCustomStyleViewController.xib

@@ -0,0 +1,281 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="14113" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" colorMatched="YES">
+    <device id="retina5_9" orientation="portrait">
+        <adaptation id="fullscreen"/>
+    </device>
+    <dependencies>
+        <deployment identifier="iOS"/>
+        <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="14088"/>
+        <capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
+    </dependencies>
+    <objects>
+        <placeholder placeholderIdentifier="IBFilesOwner" id="-1" userLabel="File's Owner" customClass="SBCustomStyleViewController">
+            <connections>
+                <outlet property="animationStyleButton" destination="DqG-hy-DfL" id="Pid-pq-zJv"/>
+                <outlet property="barColorPreview" destination="eJj-Ph-CWv" id="38S-zx-JgF"/>
+                <outlet property="barHeightLabel" destination="VCm-BG-2Vb" id="oDI-bo-1BD"/>
+                <outlet property="barPositionButton" destination="xtI-RV-WoB" id="fin-9o-Caa"/>
+                <outlet property="bottomBarView" destination="dQj-wo-lGp" id="eze-Kw-0O5"/>
+                <outlet property="fontButton" destination="kor-Fn-M5R" id="dej-s8-rjl"/>
+                <outlet property="heightForIPhoneXButton" destination="fMb-vm-Wz0" id="1G8-bS-ztG"/>
+                <outlet property="lastRow" destination="o8d-dh-GmA" id="Ktt-yb-DrB"/>
+                <outlet property="progressBarColorPreview" destination="LLJ-gT-L1E" id="uEh-0Q-6ZK"/>
+                <outlet property="scrollView" destination="yUa-6Q-US6" id="zC6-WP-Zxe"/>
+                <outlet property="textColorPreview" destination="6TJ-pl-R0h" id="5Jg-BW-edY"/>
+                <outlet property="textField" destination="Xir-AU-sSX" id="Wu6-7C-tvM"/>
+                <outlet property="view" destination="1" id="3"/>
+            </connections>
+        </placeholder>
+        <placeholder placeholderIdentifier="IBFirstResponder" id="-2" customClass="UIResponder"/>
+        <view contentMode="scaleToFill" misplaced="YES" id="1">
+            <rect key="frame" x="0.0" y="0.0" width="320" height="536"/>
+            <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
+            <subviews>
+                <scrollView clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="scaleToFill" id="yUa-6Q-US6">
+                    <rect key="frame" x="0.0" y="0.0" width="320" height="473"/>
+                    <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
+                    <subviews>
+                        <view contentMode="scaleToFill" id="mxf-Om-xe1">
+                            <rect key="frame" x="0.0" y="0.0" width="320" height="44"/>
+                            <autoresizingMask key="autoresizingMask" widthSizable="YES" flexibleMaxY="YES"/>
+                            <subviews>
+                                <textField opaque="NO" clipsSubviews="YES" contentMode="scaleToFill" contentHorizontalAlignment="left" contentVerticalAlignment="center" text="Notification Text" placeholder="Notification Text" clearsOnBeginEditing="YES" minimumFontSize="17" clearButtonMode="always" id="Xir-AU-sSX">
+                                    <rect key="frame" x="20" y="7" width="280" height="30"/>
+                                    <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
+                                    <fontDescription key="fontDescription" type="system" pointSize="14"/>
+                                    <textInputTraits key="textInputTraits" autocorrectionType="no"/>
+                                    <connections>
+                                        <outlet property="delegate" destination="-1" id="ZoT-ed-6ld"/>
+                                    </connections>
+                                </textField>
+                            </subviews>
+                            <color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+                        </view>
+                        <label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" misplaced="YES" text="Notification Bar" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" id="PGm-sg-PAE">
+                            <rect key="frame" x="10" y="54" width="150" height="21"/>
+                            <autoresizingMask key="autoresizingMask" widthSizable="YES" flexibleMaxY="YES"/>
+                            <fontDescription key="fontDescription" type="boldSystem" pointSize="12"/>
+                            <nil key="highlightedColor"/>
+                        </label>
+                        <button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="left" contentVerticalAlignment="center" showsTouchWhenHighlighted="YES" lineBreakMode="middleTruncation" id="kor-Fn-M5R">
+                            <rect key="frame" x="0.0" y="78" width="320" height="44"/>
+                            <autoresizingMask key="autoresizingMask" widthSizable="YES" flexibleMaxY="YES"/>
+                            <color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+                            <fontDescription key="fontDescription" name="HelveticaNeue" family="Helvetica Neue" pointSize="12"/>
+                            <inset key="contentEdgeInsets" minX="20" minY="0.0" maxX="124" maxY="0.0"/>
+                            <state key="normal" title="Change font: 12pt">
+                                <color key="titleColor" red="0.071822978556156158" green="0.58929067850112915" blue="0.99853438138961792" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+                                <color key="titleShadowColor" red="0.5" green="0.5" blue="0.5" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+                            </state>
+                            <state key="highlighted">
+                                <color key="titleColor" red="0.33333333333333331" green="0.33333333333333331" blue="0.33333333333333331" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+                            </state>
+                            <connections>
+                                <action selector="selectFont:" destination="-1" eventType="touchUpInside" id="qAB-ee-qTd"/>
+                            </connections>
+                        </button>
+                        <stepper opaque="NO" clipsSubviews="YES" contentMode="scaleToFill" horizontalHuggingPriority="750" verticalHuggingPriority="750" contentHorizontalAlignment="center" contentVerticalAlignment="center" continuous="NO" autorepeat="NO" value="12" minimumValue="1" maximumValue="99" id="zcb-h7-7D1">
+                            <rect key="frame" x="206" y="86" width="94" height="29"/>
+                            <autoresizingMask key="autoresizingMask" flexibleMinX="YES" flexibleMaxY="YES"/>
+                            <connections>
+                                <action selector="selectFontSize:" destination="-1" eventType="valueChanged" id="Mu1-DX-hRE"/>
+                            </connections>
+                        </stepper>
+                        <button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="left" contentVerticalAlignment="center" showsTouchWhenHighlighted="YES" lineBreakMode="middleTruncation" id="SnD-sq-J0V">
+                            <rect key="frame" x="0.0" y="124" width="320" height="44"/>
+                            <autoresizingMask key="autoresizingMask" widthSizable="YES" flexibleMaxY="YES"/>
+                            <color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+                            <fontDescription key="fontDescription" type="system" pointSize="12"/>
+                            <inset key="contentEdgeInsets" minX="20" minY="0.0" maxX="124" maxY="0.0"/>
+                            <state key="normal" title="TextColor">
+                                <color key="titleColor" red="0.07182297856" green="0.58929067850000005" blue="0.99853438139999995" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+                                <color key="titleShadowColor" red="0.5" green="0.5" blue="0.5" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+                            </state>
+                            <state key="highlighted">
+                                <color key="titleColor" red="0.33333333333333331" green="0.33333333333333331" blue="0.33333333333333331" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+                            </state>
+                            <connections>
+                                <action selector="selectTextColor:" destination="-1" eventType="touchUpInside" id="4af-G6-XWd"/>
+                            </connections>
+                        </button>
+                        <view userInteractionEnabled="NO" contentMode="scaleToFill" id="6TJ-pl-R0h">
+                            <rect key="frame" x="206" y="131" width="134" height="30"/>
+                            <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
+                            <color key="backgroundColor" red="0.0" green="0.0" blue="0.0" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+                        </view>
+                        <button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="left" contentVerticalAlignment="center" showsTouchWhenHighlighted="YES" lineBreakMode="middleTruncation" id="Fxv-Cz-Wo2">
+                            <rect key="frame" x="0.0" y="170" width="320" height="44"/>
+                            <autoresizingMask key="autoresizingMask" widthSizable="YES" flexibleMaxY="YES"/>
+                            <color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+                            <fontDescription key="fontDescription" type="system" pointSize="12"/>
+                            <inset key="contentEdgeInsets" minX="20" minY="0.0" maxX="124" maxY="0.0"/>
+                            <state key="normal" title="BarColor">
+                                <color key="titleColor" red="0.07182297856" green="0.58929067850000005" blue="0.99853438139999995" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+                                <color key="titleShadowColor" red="0.5" green="0.5" blue="0.5" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+                            </state>
+                            <state key="highlighted">
+                                <color key="titleColor" red="0.33333333333333331" green="0.33333333333333331" blue="0.33333333333333331" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+                            </state>
+                            <connections>
+                                <action selector="selectBarColor:" destination="-1" eventType="touchUpInside" id="yEc-my-c8G"/>
+                            </connections>
+                        </button>
+                        <view userInteractionEnabled="NO" contentMode="scaleToFill" id="eJj-Ph-CWv">
+                            <rect key="frame" x="206" y="180" width="134" height="30"/>
+                            <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
+                            <color key="backgroundColor" red="0.0" green="0.0" blue="0.0" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+                        </view>
+                        <button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="left" contentVerticalAlignment="center" showsTouchWhenHighlighted="YES" lineBreakMode="middleTruncation" id="DqG-hy-DfL">
+                            <rect key="frame" x="0.0" y="216" width="320" height="44"/>
+                            <autoresizingMask key="autoresizingMask" widthSizable="YES" flexibleMaxY="YES"/>
+                            <color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+                            <fontDescription key="fontDescription" type="system" pointSize="12"/>
+                            <inset key="contentEdgeInsets" minX="20" minY="0.0" maxX="20" maxY="0.0"/>
+                            <state key="normal" title="JDStatusBarAnimationStyleMove">
+                                <color key="titleColor" red="0.07182297856" green="0.58929067850000005" blue="0.99853438139999995" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+                                <color key="titleShadowColor" red="0.5" green="0.5" blue="0.5" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+                            </state>
+                            <state key="highlighted">
+                                <color key="titleColor" red="0.33333333333333331" green="0.33333333333333331" blue="0.33333333333333331" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+                            </state>
+                            <connections>
+                                <action selector="selectAnimationStyle:" destination="-1" eventType="touchUpInside" id="VTo-Wp-ox5"/>
+                            </connections>
+                        </button>
+                        <label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" misplaced="YES" text="Progress Bar" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" id="NUQ-T4-zDZ">
+                            <rect key="frame" x="10" y="307" width="300" height="21"/>
+                            <autoresizingMask key="autoresizingMask" widthSizable="YES" flexibleMaxY="YES"/>
+                            <fontDescription key="fontDescription" type="boldSystem" pointSize="12"/>
+                            <nil key="highlightedColor"/>
+                        </label>
+                        <button opaque="NO" contentMode="scaleToFill" misplaced="YES" contentHorizontalAlignment="left" contentVerticalAlignment="center" showsTouchWhenHighlighted="YES" lineBreakMode="middleTruncation" id="lEu-EP-Jkd">
+                            <rect key="frame" x="0.0" y="332" width="320" height="44"/>
+                            <autoresizingMask key="autoresizingMask" widthSizable="YES" flexibleMaxY="YES"/>
+                            <color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+                            <fontDescription key="fontDescription" type="system" pointSize="12"/>
+                            <inset key="contentEdgeInsets" minX="20" minY="0.0" maxX="124" maxY="0.0"/>
+                            <state key="normal" title="ProgressBarColor">
+                                <color key="titleColor" red="0.07182297856" green="0.58929067850000005" blue="0.99853438139999995" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+                                <color key="titleShadowColor" red="0.5" green="0.5" blue="0.5" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+                            </state>
+                            <state key="highlighted">
+                                <color key="titleColor" red="0.33333333333333331" green="0.33333333333333331" blue="0.33333333333333331" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+                            </state>
+                            <connections>
+                                <action selector="selectProgressBarColor:" destination="-1" eventType="touchUpInside" id="o9V-O3-TPY"/>
+                            </connections>
+                        </button>
+                        <view userInteractionEnabled="NO" contentMode="scaleToFill" misplaced="YES" id="LLJ-gT-L1E">
+                            <rect key="frame" x="206" y="339" width="134" height="30"/>
+                            <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
+                            <color key="backgroundColor" red="0.0" green="0.0" blue="0.0" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+                        </view>
+                        <button opaque="NO" contentMode="scaleToFill" misplaced="YES" contentHorizontalAlignment="left" contentVerticalAlignment="center" showsTouchWhenHighlighted="YES" lineBreakMode="middleTruncation" id="xtI-RV-WoB">
+                            <rect key="frame" x="0.0" y="377" width="320" height="44"/>
+                            <autoresizingMask key="autoresizingMask" widthSizable="YES" flexibleMaxY="YES"/>
+                            <color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+                            <fontDescription key="fontDescription" type="system" pointSize="12"/>
+                            <inset key="contentEdgeInsets" minX="20" minY="0.0" maxX="20" maxY="0.0"/>
+                            <state key="normal" title="JDProgressBarPositionBottom">
+                                <color key="titleColor" red="0.07182297856" green="0.58929067850000005" blue="0.99853438139999995" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+                                <color key="titleShadowColor" red="0.5" green="0.5" blue="0.5" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+                            </state>
+                            <state key="highlighted">
+                                <color key="titleColor" red="0.33333333333333331" green="0.33333333333333331" blue="0.33333333333333331" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+                            </state>
+                            <connections>
+                                <action selector="selectProgressBarPosition:" destination="-1" eventType="touchUpInside" id="c0j-gB-NzV"/>
+                            </connections>
+                        </button>
+                        <view contentMode="scaleToFill" misplaced="YES" id="o8d-dh-GmA">
+                            <rect key="frame" x="0.0" y="424" width="320" height="44"/>
+                            <autoresizingMask key="autoresizingMask" widthSizable="YES" flexibleMaxY="YES"/>
+                            <subviews>
+                                <label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="ProgressBarHeight (1pt)" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" id="VCm-BG-2Vb">
+                                    <rect key="frame" x="20" y="0.0" width="180" height="44"/>
+                                    <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
+                                    <fontDescription key="fontDescription" type="system" pointSize="12"/>
+                                    <color key="textColor" red="0.07182297856" green="0.58929067850000005" blue="0.99853438139999995" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+                                    <nil key="highlightedColor"/>
+                                </label>
+                                <stepper opaque="NO" clipsSubviews="YES" contentMode="scaleToFill" horizontalHuggingPriority="750" verticalHuggingPriority="750" contentHorizontalAlignment="center" contentVerticalAlignment="center" continuous="NO" autorepeat="NO" value="1" maximumValue="20" id="zQd-eF-2ku">
+                                    <rect key="frame" x="216" y="8" width="94" height="29"/>
+                                    <autoresizingMask key="autoresizingMask" flexibleMinX="YES" flexibleMinY="YES" flexibleMaxY="YES"/>
+                                    <connections>
+                                        <action selector="setProgressBarHeight:" destination="-1" eventType="valueChanged" id="ldk-U3-SkC"/>
+                                    </connections>
+                                </stepper>
+                            </subviews>
+                            <color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+                        </view>
+                        <button opaque="NO" contentMode="scaleToFill" misplaced="YES" contentHorizontalAlignment="left" contentVerticalAlignment="center" showsTouchWhenHighlighted="YES" lineBreakMode="middleTruncation" id="fMb-vm-Wz0">
+                            <rect key="frame" x="0.0" y="262" width="320" height="44"/>
+                            <autoresizingMask key="autoresizingMask" widthSizable="YES" flexibleMaxY="YES"/>
+                            <color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+                            <fontDescription key="fontDescription" type="system" pointSize="12"/>
+                            <inset key="contentEdgeInsets" minX="20" minY="0.0" maxX="20" maxY="0.0"/>
+                            <state key="normal" title="JDStatusBarHeightForIPhoneXFullNavBar">
+                                <color key="titleColor" red="0.07182297856" green="0.58929067850000005" blue="0.99853438139999995" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+                                <color key="titleShadowColor" red="0.5" green="0.5" blue="0.5" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+                            </state>
+                            <state key="highlighted">
+                                <color key="titleColor" red="0.33333333329999998" green="0.33333333329999998" blue="0.33333333329999998" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+                            </state>
+                            <connections>
+                                <action selector="selectIPhoneXHeight:" destination="-1" eventType="touchUpInside" id="hjo-3Y-hzu"/>
+                            </connections>
+                        </button>
+                    </subviews>
+                    <color key="backgroundColor" red="0.92584240436553955" green="0.92504066228866577" blue="0.94968438148498535" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+                </scrollView>
+                <view contentMode="scaleToFill" misplaced="YES" id="dQj-wo-lGp">
+                    <rect key="frame" x="0.0" y="473" width="320" height="63"/>
+                    <autoresizingMask key="autoresizingMask" widthSizable="YES" flexibleMinY="YES"/>
+                    <subviews>
+                        <view contentMode="scaleToFill" misplaced="YES" id="vmK-8H-mj5">
+                            <rect key="frame" x="0.0" y="0.0" width="320" height="1"/>
+                            <autoresizingMask key="autoresizingMask" widthSizable="YES" flexibleMaxY="YES"/>
+                            <color key="backgroundColor" red="0.79923993349075317" green="0.79923993349075317" blue="0.79923993349075317" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+                        </view>
+                        <button opaque="NO" contentMode="scaleToFill" misplaced="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" showsTouchWhenHighlighted="YES" lineBreakMode="middleTruncation" id="YRP-G8-SEf">
+                            <rect key="frame" x="12" y="9" width="145" height="44"/>
+                            <autoresizingMask key="autoresizingMask" widthSizable="YES" flexibleMaxX="YES" flexibleMaxY="YES"/>
+                            <color key="backgroundColor" red="0.92161363363265991" green="0.9206281304359436" blue="0.94577103853225708" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+                            <fontDescription key="fontDescription" type="boldSystem" pointSize="12"/>
+                            <state key="normal" title="Show">
+                                <color key="titleColor" red="0.33333333333333331" green="0.33333333333333331" blue="0.33333333333333331" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+                                <color key="titleShadowColor" red="0.5" green="0.5" blue="0.5" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+                            </state>
+                            <state key="highlighted">
+                                <color key="titleColor" red="0.0" green="0.0" blue="0.0" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+                            </state>
+                            <connections>
+                                <action selector="show:" destination="-1" eventType="touchUpInside" id="hPW-fw-MfI"/>
+                            </connections>
+                        </button>
+                        <button opaque="NO" contentMode="scaleToFill" misplaced="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" showsTouchWhenHighlighted="YES" lineBreakMode="middleTruncation" id="jqn-Mq-S18">
+                            <rect key="frame" x="165" y="9" width="145" height="44"/>
+                            <autoresizingMask key="autoresizingMask" flexibleMinX="YES" widthSizable="YES" flexibleMaxY="YES"/>
+                            <color key="backgroundColor" red="0.92161363363265991" green="0.9206281304359436" blue="0.94577103853225708" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+                            <fontDescription key="fontDescription" type="boldSystem" pointSize="12"/>
+                            <state key="normal" title="Show with progress">
+                                <color key="titleColor" red="0.33333333333333331" green="0.33333333333333331" blue="0.33333333333333331" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+                                <color key="titleShadowColor" red="0.5" green="0.5" blue="0.5" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+                            </state>
+                            <state key="highlighted">
+                                <color key="titleColor" red="0.0" green="0.0" blue="0.0" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+                            </state>
+                            <connections>
+                                <action selector="showWithProgress:" destination="-1" eventType="touchUpInside" id="3re-IS-P29"/>
+                            </connections>
+                        </button>
+                    </subviews>
+                    <color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
+                </view>
+            </subviews>
+            <color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+            <freeformSimulatedSizeMetrics key="simulatedDestinationMetrics"/>
+            <point key="canvasLocation" x="34" y="62"/>
+        </view>
+    </objects>
+</document>

+ 13 - 0
Carthage/Checkouts/JDStatusBarNotification/ExampleProject/JDStatusBarNotificationExample/SBExampleViewController.h

@@ -0,0 +1,13 @@
+//
+//  SBExampleViewController.h
+//  JDStatusBarNotificationExample
+//
+//  Created by Markus on 29.10.13.
+//  Copyright (c) 2013 Markus. All rights reserved.
+//
+
+#import <UIKit/UIKit.h>
+
+@interface SBExampleViewController : UITableViewController
+
+@end

+ 235 - 0
Carthage/Checkouts/JDStatusBarNotification/ExampleProject/JDStatusBarNotificationExample/SBExampleViewController.m

@@ -0,0 +1,235 @@
+//
+//  SBExampleViewController.m
+//  JDStatusBarNotificationExample
+//
+//  Created by Markus on 29.10.13.
+//  Copyright (c) 2013 Markus. All rights reserved.
+//
+
+#import "JDStatusBarNotification.h"
+#import "SBCustomStyleViewController.h"
+
+#import "SBExampleViewController.h"
+
+static NSString *const JDButtonName = @"JDButtonName";
+static NSString *const JDButtonInfo = @"JDButtonInfo";
+static NSString *const JDNotificationText = @"JDNotificationText";
+
+static NSString *const SBStyle1 = @"SBStyle1";
+static NSString *const SBStyle2 = @"SBStyle2";
+
+@interface SBExampleViewController ()
+@property (nonatomic, strong) NSArray *data;
+
+@property (nonatomic, assign) UIActivityIndicatorViewStyle indicatorStyle;
+@property (nonatomic, assign) CGFloat progress;
+@property (nonatomic, weak) NSTimer *timer;
+@end
+
+@implementation SBExampleViewController
+
+- (id)initWithStyle:(UITableViewStyle)style
+{
+    self = [super initWithStyle:style];
+    if (self) {
+        self.title = @"JDStatusBarNotification";
+        
+        [JDStatusBarNotification addStyleNamed:SBStyle1
+                                       prepare:^JDStatusBarStyle *(JDStatusBarStyle *style) {
+                                           style.barColor = [UIColor colorWithRed:0.797 green:0.000 blue:0.662 alpha:1.000];
+                                           style.textColor = [UIColor whiteColor];
+                                           style.animationType = JDStatusBarAnimationTypeFade;
+                                           style.font = [UIFont fontWithName:@"SnellRoundhand-Bold" size:17.0];
+                                           style.progressBarColor = [UIColor colorWithRed:0.986 green:0.062 blue:0.598 alpha:1.000];
+                                           style.progressBarHeight = 20.0;
+                                           return style;
+                                       }];
+        
+        [JDStatusBarNotification addStyleNamed:SBStyle2
+                                       prepare:^JDStatusBarStyle *(JDStatusBarStyle *style) {
+                                           style.barColor = [UIColor cyanColor];
+                                           style.textColor = [UIColor colorWithRed:0.056 green:0.478 blue:0.998 alpha:1.000];
+                                           style.animationType = JDStatusBarAnimationTypeBounce;
+                                           style.progressBarColor = style.textColor;
+                                           style.progressBarHeight = 5.0;
+                                           style.progressBarPosition = JDStatusBarProgressBarPositionTop;
+                                           if ([[[UIDevice currentDevice] systemVersion] floatValue] >= 7.0) {
+                                               style.font = [UIFont fontWithName:@"DINCondensed-Bold" size:17.0];
+                                               style.textVerticalPositionAdjustment = 2.0;
+                                           } else {
+                                               style.font = [UIFont fontWithName:@"HelveticaNeue-CondensedBold" size:17.0];
+                                           }
+                                           return style;
+                                       }];
+        
+        self.data = @[@[@{JDButtonName:@"Show Notification", JDButtonInfo:@"JDStatusBarStyleDefault", JDNotificationText:@"Better call Saul!"},
+                        @{JDButtonName:@"Show Progress", JDButtonInfo:@"0-100% in 1s", JDNotificationText:@"Some Progress…"},
+                        @{JDButtonName:@"Show Activity Indicator", JDButtonInfo:@"UIActivityIndicatorViewStyleGray", JDNotificationText:@"Some Activity…"},
+                        @{JDButtonName:@"Update text", JDButtonInfo:@"", JDNotificationText:@"Some Activity…"},
+                        @{JDButtonName:@"Dismiss Notification", JDButtonInfo:@"Animated", JDNotificationText:@""}],
+                      @[@{JDButtonName:@"Show JDStatusBarStyleError", JDButtonInfo:@"Duration: 2s", JDNotificationText:@"No, I don't have the money.."},
+                        @{JDButtonName:@"Show JDStatusBarStyleWarning", JDButtonInfo:@"Duration: 2s", JDNotificationText:@"You know who I am!"},
+                        @{JDButtonName:@"Show JDStatusBarStyleSuccess", JDButtonInfo:@"Duration: 2s", JDNotificationText:@"That's how we roll!"},
+                        @{JDButtonName:@"Show JDStatusBarStyleDark", JDButtonInfo:@"Duration: 2s", JDNotificationText:@"Don't mess with me!"},
+                        @{JDButtonName:@"Show JDStatusBarStyleMatrix", JDButtonInfo:@"Duration: 2s", JDNotificationText:@"Wake up Neo…"}],
+                      @[@{JDButtonName:@"Show custom style 1", JDButtonInfo:@"Duration: 4s, JDStatusBarAnimationTypeFade", JDNotificationText:@"Oh, I love it!"},
+                        @{JDButtonName:@"Show custom style 2", JDButtonInfo:@"Duration: 4s, JDStatusBarAnimationTypeBounce", JDNotificationText:@"Level up!"}],
+                      @[@{JDButtonName:@"Create your own style", JDButtonInfo:@"Test all possibilities", JDNotificationText:@""}]];
+    }
+    return self;
+}
+
+- (void)viewDidLoad;
+{
+    [super viewDidLoad];
+    
+    self.tableView.backgroundColor = [UIColor colorWithRed:0.93 green:0.93 blue:0.95 alpha:1.0];
+    self.tableView.backgroundView = nil;
+    
+    // presenting a notification, before a keyWindow is set
+    self.indicatorStyle = UIActivityIndicatorViewStyleWhite;
+    [JDStatusBarNotification showWithStatus:@"Hello World!" dismissAfter:2.0
+                                  styleName:JDStatusBarStyleMatrix];
+}
+
+- (BOOL)prefersStatusBarHidden
+{
+    return NO;
+}
+
+#pragma mark UITableViewDataSource
+
+- (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView;
+{
+    return self.data.count;
+}
+
+- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section;
+{
+    return [self.data[section] count];
+}
+
+- (UITableViewCell*)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath;
+{
+    // create / dequeue cell
+    static NSString* identifier = @"identifier";
+    UITableViewCell* cell = [tableView dequeueReusableCellWithIdentifier:identifier];
+    if (cell == nil) {
+        cell = [[UITableViewCell alloc] initWithStyle:UITableViewCellStyleSubtitle reuseIdentifier:identifier];
+        cell.accessoryType = UITableViewCellAccessoryDisclosureIndicator;
+        cell.textLabel.font = [UIFont systemFontOfSize:15.0];
+        cell.detailTextLabel.font = [UIFont systemFontOfSize:11.0];
+        cell.detailTextLabel.textColor = [UIColor colorWithWhite:0.5 alpha:1.0];
+
+        if ([[[UIDevice currentDevice] systemVersion] floatValue] < 7.0) {
+            cell.textLabel.backgroundColor = [UIColor clearColor];
+            cell.detailTextLabel.backgroundColor = [UIColor clearColor];
+            cell.backgroundView = [[UIView alloc] init];
+            cell.backgroundView.backgroundColor = [UIColor whiteColor];
+            cell.selectedBackgroundView = [[UIView alloc] init];
+            cell.selectedBackgroundView.backgroundColor = [UIColor colorWithWhite:0.8 alpha:1.0];
+        }
+    }
+    
+    NSDictionary *data = self.data[indexPath.section][indexPath.row];
+    cell.textLabel.text = data[JDButtonName];
+    cell.detailTextLabel.text = data[JDButtonInfo];
+    
+    return cell;
+}
+
+- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath;
+{
+    NSInteger section = indexPath.section;
+    NSInteger row = indexPath.row;
+    
+    NSDictionary *data = self.data[indexPath.section][indexPath.row];
+    NSString *status = data[JDNotificationText];
+    
+    // reset progress timer
+    self.progress = 0.0;
+    [self.timer invalidate];
+    self.timer = nil;
+    
+    // show notification
+    if (section == 0) {
+        if (row == 0) {
+            self.indicatorStyle = UIActivityIndicatorViewStyleGray;
+            [JDStatusBarNotification showWithStatus:status];
+        } else if (row == 1) {
+            if(![JDStatusBarNotification isVisible]) {
+                self.indicatorStyle = UIActivityIndicatorViewStyleGray;
+                [JDStatusBarNotification showWithStatus:status dismissAfter:1.4];
+            }
+            [self startTimer];
+        } else if (row == 2) {
+            if(![JDStatusBarNotification isVisible]) {
+                self.indicatorStyle = UIActivityIndicatorViewStyleGray;
+                [JDStatusBarNotification showWithStatus:status dismissAfter:2.0];
+            }
+            [JDStatusBarNotification showActivityIndicator:YES
+                                            indicatorStyle:self.indicatorStyle];
+        } else if (row == 3) {
+          [JDStatusBarNotification updateStatus:@"Replaced Text.."];
+        } else if (row == 4) {
+          [JDStatusBarNotification dismiss];
+        }
+    } else if (section == 1) {
+        self.indicatorStyle = UIActivityIndicatorViewStyleWhite;
+        NSString *style = JDStatusBarStyleError;
+        if (row == 1) {
+            style = JDStatusBarStyleWarning;
+            self.indicatorStyle = UIActivityIndicatorViewStyleGray;
+        } else if(row == 2) {
+            style = JDStatusBarStyleSuccess;
+        } else if(row == 3) {
+            style = JDStatusBarStyleDark;
+        } else if(row == 4) {
+            style = JDStatusBarStyleMatrix;
+        }
+        
+        [JDStatusBarNotification showWithStatus:status
+                                   dismissAfter:2.0
+                                      styleName:style];
+    } else if (section == 2) {
+        self.indicatorStyle = (row==0) ? UIActivityIndicatorViewStyleWhite : UIActivityIndicatorViewStyleGray;
+        
+        NSString *style = (row==0) ? SBStyle1 : SBStyle2;
+        [JDStatusBarNotification showWithStatus:status
+                                   dismissAfter:4.0
+                                      styleName:style];
+    } else if (section == 3) {
+        SBCustomStyleViewController* viewController = [[SBCustomStyleViewController alloc] init];
+        viewController.title = [tableView cellForRowAtIndexPath:indexPath].textLabel.text;
+        [self.navigationController pushViewController:viewController animated:YES];
+    }
+    
+    [tableView deselectRowAtIndexPath:indexPath animated:YES];
+}
+
+
+- (void)startTimer;
+{
+    [JDStatusBarNotification showProgress:self.progress];
+    
+    [self.timer invalidate];
+    self.timer = nil;
+    
+    if (self.progress < 1.0) {
+        CGFloat step = 0.02;
+        self.timer = [NSTimer scheduledTimerWithTimeInterval:step target:self
+                                                    selector:@selector(startTimer)
+                                                    userInfo:nil repeats:NO];
+        self.progress += step;
+    } else {
+        [self performSelector:@selector(hideProgress)
+                   withObject:nil afterDelay:0.5];
+    }
+}
+
+- (void)hideProgress;
+{
+    [JDStatusBarNotification showProgress:0.0];
+}
+
+@end

+ 20 - 0
Carthage/Checkouts/JDStatusBarNotification/ExampleProject/JDStatusBarNotificationExample/SBSelectPropertyViewController.h

@@ -0,0 +1,20 @@
+//
+//  SBSelectPropertyViewController.h
+//  JDStatusBarNotificationExample
+//
+//  Created by Markus Emrich on 09.11.13.
+//  Copyright (c) 2013 Markus. All rights reserved.
+//
+
+#import <UIKit/UIKit.h>
+
+typedef void(^SBSelectPropertyResultBlock)(NSInteger selectedRow);
+
+@interface SBSelectPropertyViewController : UITableViewController
+
+@property (nonatomic, assign) NSInteger activeRow;
+
+- (id)initWithData:(NSArray*)data
+       resultBlock:(SBSelectPropertyResultBlock)resultBlock;
+
+@end

+ 70 - 0
Carthage/Checkouts/JDStatusBarNotification/ExampleProject/JDStatusBarNotificationExample/SBSelectPropertyViewController.m

@@ -0,0 +1,70 @@
+//
+//  SBSelectPropertyViewController.m
+//  JDStatusBarNotificationExample
+//
+//  Created by Markus Emrich on 09.11.13.
+//  Copyright (c) 2013 Markus. All rights reserved.
+//
+
+#import "SBSelectPropertyViewController.h"
+
+@interface SBSelectPropertyViewController ()
+@property (nonatomic, strong) NSArray *data;
+@property (nonatomic, copy) SBSelectPropertyResultBlock resultBlock;
+@end
+
+@implementation SBSelectPropertyViewController
+
+- (id)initWithData:(NSArray*)data
+       resultBlock:(SBSelectPropertyResultBlock)resultBlock;
+{
+    self = [super initWithStyle:UITableViewStylePlain];
+    if (self) {
+        self.data = data;
+        self.resultBlock = resultBlock;
+        self.activeRow = -1;
+    }
+    return self;
+}
+
+#pragma mark - Table view data source
+
+- (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView
+{
+    return 1;
+}
+
+- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section
+{
+    return self.data.count;
+}
+
+- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
+{
+    // create / dequeue cell
+    static NSString* identifier = @"identifier";
+    UITableViewCell* cell = [tableView dequeueReusableCellWithIdentifier:identifier];
+    if (cell == nil) {
+        cell = [[UITableViewCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:identifier];
+        cell.textLabel.font = [UIFont systemFontOfSize:14.0];
+    }
+    
+    cell.textLabel.text = self.data[indexPath.row];
+    
+    if (indexPath.row == self.activeRow) {
+        cell.accessoryType = UITableViewCellAccessoryCheckmark;
+    } else {
+        cell.accessoryType = UITableViewCellAccessoryNone;
+    }
+    
+    return cell;
+}
+
+- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath;
+{
+    if (self.resultBlock) {
+        self.resultBlock(indexPath.row);
+    }
+}
+
+@end

+ 18 - 0
Carthage/Checkouts/JDStatusBarNotification/ExampleProject/JDStatusBarNotificationExample/main.m

@@ -0,0 +1,18 @@
+//
+//  main.m
+//  JDStatusBarNotificationExample
+//
+//  Created by Markus on 29.10.13.
+//  Copyright (c) 2013 Markus. All rights reserved.
+//
+
+#import <UIKit/UIKit.h>
+
+#import "SBAppDelegate.h"
+
+int main(int argc, char * argv[])
+{
+    @autoreleasepool {
+        return UIApplicationMain(argc, argv, nil, NSStringFromClass([SBAppDelegate class]));
+    }
+}

+ 9 - 0
Carthage/Checkouts/JDStatusBarNotification/ExampleProject/Podfile

@@ -0,0 +1,9 @@
+platform :ios, "8.0"
+source 'https://github.com/CocoaPods/Specs.git'
+inhibit_all_warnings!
+
+target 'JDStatusBarNotificationExample' do
+  pod 'InfColorPicker'
+  pod 'FTFontSelector'
+end
+

+ 20 - 0
Carthage/Checkouts/JDStatusBarNotification/ExampleProject/Podfile.lock

@@ -0,0 +1,20 @@
+PODS:
+  - FTFontSelector (1.1.3)
+  - InfColorPicker (0.0.1)
+
+DEPENDENCIES:
+  - FTFontSelector
+  - InfColorPicker
+
+SPEC REPOS:
+  https://github.com/cocoapods/specs.git:
+    - FTFontSelector
+    - InfColorPicker
+
+SPEC CHECKSUMS:
+  FTFontSelector: a5f0fc4dfb1606ad76da38570b0816c2e6c0d136
+  InfColorPicker: 8bfb8d8d44c356f0c98587a049783e900d7b5ff9
+
+PODFILE CHECKSUM: 82ca418f297a92c39ba3d6ed8c8457ea4538fa5e
+
+COCOAPODS: 1.5.3

+ 20 - 0
Carthage/Checkouts/JDStatusBarNotification/JDStatusBarNotification.podspec

@@ -0,0 +1,20 @@
+Pod::Spec.new do |s|
+  
+  s.name         = 'JDStatusBarNotification'
+  s.version      = '1.6.0'
+  s.summary      = 'Easy, customizable notifications displayed on top of the statusbar. With progress and activity. iPhone X ready.'
+
+  s.description  = 'Show messages on top of the status bar. Customizable colors, font and animation. Supports progress display and can show an activity indicator. Supports iOS 6+ and iPhone X.'
+  
+  s.homepage     = 'https://github.com/calimarkus/JDStatusBarNotification'
+  s.license      = { :type => 'MIT' }
+  s.author       = { 'Markus Emrich' => 'markus.emrich@gmail.com' }  
+  
+  s.source       = { :git => 'https://github.com/calimarkus/JDStatusBarNotification.git', :tag => "#{s.version}" }
+  s.source_files = 'JDStatusBarNotification/**'
+  s.frameworks   = 'QuartzCore'
+  
+  s.platform     = :ios, '6.0'
+  s.requires_arc = true
+
+end

+ 10 - 0
Carthage/Checkouts/JDStatusBarNotification/JDStatusBarNotification/JDStatusBarLayoutMarginHelper.h

@@ -0,0 +1,10 @@
+//
+//  JDStatusBarLayoutMarginHelper.h
+//  JDStatusBarNotificationExample
+//
+//  Copyright (c) 2013 Markus. All rights reserved.
+//
+
+#import <UIKit/UIKit.h>
+
+extern UIEdgeInsets JDStatusBarRootVCLayoutMargin(void);

+ 19 - 0
Carthage/Checkouts/JDStatusBarNotification/JDStatusBarNotification/JDStatusBarLayoutMarginHelper.m

@@ -0,0 +1,19 @@
+//
+//  JDStatusBarView.m
+//  JDStatusBarNotificationExample
+//
+//  Created by Markus on 04.12.13.
+//  Copyright (c) 2013 Markus. All rights reserved.
+//
+
+#import "JDStatusBarLayoutMarginHelper.h"
+
+UIEdgeInsets JDStatusBarRootVCLayoutMargin(void)
+{
+    UIEdgeInsets layoutMargins = [[[[[UIApplication sharedApplication] keyWindow] rootViewController] view] layoutMargins];
+    if (layoutMargins.top > 8 && layoutMargins.bottom > 8) {
+        return layoutMargins;
+    } else {
+        return UIEdgeInsetsZero;  // ignore default margins
+    }
+}

+ 11 - 2
Libraries external/JDStatusBarNotification/JDStatusBarNotification.h → Carthage/Checkouts/JDStatusBarNotification/JDStatusBarNotification/JDStatusBarNotification.h

@@ -12,6 +12,8 @@
 #import "JDStatusBarStyle.h"
 #import "JDStatusBarView.h"
 
+NS_ASSUME_NONNULL_BEGIN
+
 /**
  *  A block that is used to define the appearance of a notification.
  *  A JDStatusBarStyle instance defines the notification appeareance.
@@ -137,7 +139,14 @@ typedef JDStatusBarStyle*(^JDPrepareStyleBlock)(JDStatusBarStyle *style);
 + (NSString*)addStyleNamed:(NSString*)identifier
                    prepare:(JDPrepareStyleBlock)prepareBlock;
 
-#pragma mark progress & activity
+#pragma mark Modifications
+
+/**
+ *  Update the text of the label without presenting a new notification.
+ *
+ *  @param status The new message to display
+ */
++ (void)updateStatus:(NSString *)status;
 
 /**
  *  Show the progress below the label.
@@ -166,4 +175,4 @@ typedef JDStatusBarStyle*(^JDPrepareStyleBlock)(JDStatusBarStyle *style);
 
 @end
 
-
+NS_ASSUME_NONNULL_END

+ 67 - 27
Libraries external/JDStatusBarNotification/JDStatusBarNotification.m → Carthage/Checkouts/JDStatusBarNotification/JDStatusBarNotification/JDStatusBarNotification.m

@@ -9,6 +9,7 @@
 
 #import <QuartzCore/QuartzCore.h>
 
+#import "JDStatusBarLayoutMarginHelper.h"
 #import "JDStatusBarNotification.h"
 
 @interface JDStatusBarStyle (Hidden)
@@ -115,6 +116,11 @@
                                       prepare:prepareBlock];
 }
 
++ (void)updateStatus:(NSString *)status;
+{
+  [[self sharedInstance] setStatus:status];
+}
+
 + (void)showProgress:(CGFloat)progress;
 {
   [[self sharedInstance] setProgress:progress];
@@ -196,14 +202,19 @@
 
   // prepare for new style
   if (style != self.activeStyle) {
-    self.activeStyle = style;
-    if (self.activeStyle.animationType == JDStatusBarAnimationTypeFade) {
-      self.topBar.alpha = 0.0;
-      self.topBar.transform = CGAffineTransformIdentity;
-    } else {
-      self.topBar.alpha = 1.0;
-      self.topBar.transform = CGAffineTransformMakeTranslation(0, -self.topBar.frame.size.height);
-    }
+      self.activeStyle = style;
+      if (self.activeStyle.animationType == JDStatusBarAnimationTypeFade) {
+          self.topBar.alpha = 0.0;
+          self.topBar.transform = CGAffineTransformIdentity;
+      } else {
+          self.topBar.alpha = 1.0;
+          self.topBar.transform = CGAffineTransformMakeTranslation(0, -self.topBar.frame.size.height);
+      }
+  }
+
+  // Force update the TopBar frame if the height is 0
+  if (self.topBar.frame.size.height == 0) {
+    [self updateContentFrame:[[UIApplication sharedApplication] statusBarFrame]];
   }
 
   // cancel previous dismissing & remove animations
@@ -283,10 +294,10 @@
   void(^complete)(BOOL) = ^(BOOL finished) {
     [self.overlayWindow removeFromSuperview];
     [self.overlayWindow setHidden:YES];
-    _overlayWindow.rootViewController = nil;
-    _overlayWindow = nil;
-    _progressView = nil;
-    _topBar = nil;
+    self.overlayWindow.rootViewController = nil;
+    self->_overlayWindow = nil;
+    self->_progressView = nil;
+    self->_topBar = nil;
   };
 
   if (animated) {
@@ -342,7 +353,18 @@
   [self.topBar.layer removeAllAnimations];
 }
 
-#pragma mark Progress & Activity
+#pragma mark Modifications
+
+- (void)setStatus:(NSString *)status;
+{
+  if (_topBar == nil) return;
+
+  UILabel *textLabel = self.topBar.textLabel;
+  textLabel.accessibilityLabel = status;
+  textLabel.text = status;
+
+  [self.topBar setNeedsLayout];
+}
 
 - (void)setProgress:(CGFloat)progress;
 {
@@ -439,8 +461,7 @@
 #if __IPHONE_OS_VERSION_MIN_REQUIRED < 70000 // only when deployment target is < ios7
     _overlayWindow.rootViewController.wantsFullScreenLayout = YES;
 #endif
-    [self updateWindowTransform];
-    [self updateTopBarFrameWithStatusBarFrame:[[UIApplication sharedApplication] statusBarFrame]];
+    [self updateContentFrame:[[UIApplication sharedApplication] statusBarFrame]];
   }
   return _overlayWindow;
 }
@@ -452,6 +473,7 @@
     [self.overlayWindow.rootViewController.view addSubview:_topBar];
 
     JDStatusBarStyle *style = self.activeStyle ?: self.defaultStyle;
+    self.topBar.heightForIPhoneX = style.heightForIPhoneX;
     if (style.animationType != JDStatusBarAnimationTypeFade) {
       self.topBar.transform = CGAffineTransformMakeTranslation(0, -self.topBar.frame.size.height);
     } else {
@@ -471,6 +493,11 @@
 
 #pragma mark Rotation
 
+- (void)updateContentFrame:(CGRect)rect {
+    [self updateWindowTransform];
+    [self updateTopBarFrameWithStatusBarFrame:rect];
+}
+
 - (void)updateWindowTransform;
 {
   UIWindow *window = [[UIApplication sharedApplication]
@@ -479,20 +506,34 @@
   _overlayWindow.frame = window.frame;
 }
 
+static CGFloat topBarHeightAdjustedForIphoneX(JDStatusBarStyle *style, CGFloat height) {
+  CGFloat topLayoutMargin = JDStatusBarRootVCLayoutMargin().top;
+  if (topLayoutMargin > 0) {
+    switch (style.heightForIPhoneX) {
+      case JDStatusBarHeightForIPhoneXFullNavBar:
+        return height + topLayoutMargin;
+      case JDStatusBarHeightForIPhoneXHalf:
+        return height + 8.0;
+    }
+  } else {
+    return height;
+  }
+}
+
 - (void)updateTopBarFrameWithStatusBarFrame:(CGRect)rect;
 {
   CGFloat width = MAX(rect.size.width, rect.size.height);
   CGFloat height = MIN(rect.size.width, rect.size.height);
-    
-  // on ios7 fix position, if statusBar has double height
+
+  // adjust position for iOS 7, if statusBar has double height
   CGFloat yPos = 0;
-  if ([JDStatusBarView isIphoneX]) {
-    height = 64;
-  } else {
-    if ([[[UIDevice currentDevice] systemVersion] floatValue] >= 7.0 && height > 20.0) {
-      yPos = -height/2.0;
-    }
+  if ([[[UIDevice currentDevice] systemVersion] floatValue] >= 7.0 && height == 40.0) {
+    yPos = -height/2.0;
   }
+
+  // adjust height for iPhone X
+  height = topBarHeightAdjustedForIphoneX(self.activeStyle ?: self.defaultStyle, height);
+
   _topBar.frame = CGRectMake(0, yPos, width, height);
 }
 
@@ -502,10 +543,9 @@
   NSTimeInterval duration = [[UIApplication sharedApplication] statusBarOrientationAnimationDuration];
 
   // update window & statusbar
-  void(^updateBlock)() = ^{
-    [self updateWindowTransform];
-    [self updateTopBarFrameWithStatusBarFrame:newBarFrame];
-    self.progress = self.progress; // // relayout progress bar
+  void(^updateBlock)(void) = ^{
+    [self updateContentFrame:newBarFrame];
+    self.progress = self.progress; // relayout progress bar
   };
 
   [UIView animateWithDuration:duration animations:^{

+ 106 - 0
Carthage/Checkouts/JDStatusBarNotification/JDStatusBarNotification/JDStatusBarStyle.h

@@ -0,0 +1,106 @@
+//
+//  JDStatusBarStyle.h
+//  JDStatusBarNotificationExample
+//
+//  Created by Markus on 04.12.13.
+//  Copyright (c) 2013 Markus. All rights reserved.
+//
+
+#import <Foundation/Foundation.h>
+#import <UIKit/UIKit.h>
+
+NS_ASSUME_NONNULL_BEGIN
+
+/// This style has a red background with a white Helvetica label.
+extern NSString *const JDStatusBarStyleError;
+/// This style has a yellow background with a gray Helvetica label.
+extern NSString *const JDStatusBarStyleWarning;
+/// This style has a green background with a white Helvetica label.
+extern NSString *const JDStatusBarStyleSuccess;
+/// This style has a black background with a green bold Courier label.
+extern NSString *const JDStatusBarStyleMatrix;
+/// This style has a white background with a gray Helvetica label.
+extern NSString *const JDStatusBarStyleDefault;
+/// This style has a nearly black background with a nearly white Helvetica label.
+extern NSString *const JDStatusBarStyleDark;
+
+typedef NS_ENUM(NSInteger, JDStatusBarAnimationType) {
+    /// Notification won't animate
+    JDStatusBarAnimationTypeNone,
+    /// Notification will move in from the top, and move out again to the top
+    JDStatusBarAnimationTypeMove,
+    /// Notification will fall down from the top and bounce a little bit
+    JDStatusBarAnimationTypeBounce,
+    /// Notification will fade in and fade out
+    JDStatusBarAnimationTypeFade,
+};
+
+typedef NS_ENUM(NSInteger, JDStatusBarProgressBarPosition) {
+    /// progress bar will be at the bottom of the status bar
+    JDStatusBarProgressBarPositionBottom,
+    /// progress bar will be at the center of the status bar
+    JDStatusBarProgressBarPositionCenter,
+    /// progress bar will be at the top of the status bar
+    JDStatusBarProgressBarPositionTop,
+    /// progress bar will be below the status bar (the progress bar won't move with the status bar in this case)
+    JDStatusBarProgressBarPositionBelow,
+    /// progress bar will be below the navigation bar (the progress bar won't move with the status bar in this case)
+    JDStatusBarProgressBarPositionNavBar,
+};
+
+typedef NS_ENUM(NSInteger, JDStatusBarHeightForIPhoneX) {
+    /// shows parts of the navigation bar
+    JDStatusBarHeightForIPhoneXHalf,
+    /// covers the full navigation bar
+    JDStatusBarHeightForIPhoneXFullNavBar,
+};
+
+/**
+ *  A Style defines the appeareance of a notification.
+ */
+@interface JDStatusBarStyle : NSObject <NSCopying>
+
+/// The background color of the notification bar
+@property (nonatomic, strong) UIColor *barColor;
+
+/// The text color of the notification label
+@property (nonatomic, strong) UIColor *textColor;
+
+/// The text shadow of the notification label
+@property (nonatomic, strong) NSShadow *textShadow;
+
+/// The font of the notification label
+@property (nonatomic, strong) UIFont *font;
+
+/// A correction of the vertical label position in points. Default is 0.0
+@property (nonatomic, assign) CGFloat textVerticalPositionAdjustment;
+
+#pragma mark Animation
+
+/// The animation, that is used to present the notification
+@property (nonatomic, assign) JDStatusBarAnimationType animationType;
+
+#pragma mark Progress Bar
+
+/// The background color of the progress bar (on top of the notification bar)
+@property (nonatomic, strong) UIColor *progressBarColor;
+
+/// The height of the progress bar. Default is 1.0
+@property (nonatomic, assign) CGFloat progressBarHeight;
+
+/// The position of the progress bar. Default is JDStatusBarProgressBarPositionBottom
+@property (nonatomic, assign) JDStatusBarProgressBarPosition progressBarPosition;
+
+/// The insets of the progress bar. Default is 0.0
+@property (nonatomic, assign) CGFloat progressBarHorizontalInsets;
+
+/// The corner radius of the progress bar. Default is 0.0
+@property (nonatomic, assign) CGFloat progressBarCornerRadius;
+
+#pragma mark iPhone X height
+
+@property (nonatomic, assign) JDStatusBarHeightForIPhoneX heightForIPhoneX;
+
+@end
+
+NS_ASSUME_NONNULL_END

+ 2 - 0
Libraries external/JDStatusBarNotification/JDStatusBarStyle.m → Carthage/Checkouts/JDStatusBarNotification/JDStatusBarNotification/JDStatusBarStyle.m

@@ -29,6 +29,7 @@ NSString *const JDStatusBarStyleDark    = @"JDStatusBarStyleDark";
   style.progressBarColor = self.progressBarColor;
   style.progressBarHeight = self.progressBarHeight;
   style.progressBarPosition = self.progressBarPosition;
+  style.heightForIPhoneX = self.heightForIPhoneX;
   return style;
 }
 
@@ -50,6 +51,7 @@ NSString *const JDStatusBarStyleDark    = @"JDStatusBarStyleDark";
   style.textColor = [UIColor grayColor];
   style.font = [UIFont systemFontOfSize:12.0];
   style.animationType = JDStatusBarAnimationTypeMove;
+  style.heightForIPhoneX = JDStatusBarHeightForIPhoneXFullNavBar;
 
   // JDStatusBarStyleDefault
   if ([styleName isEqualToString:JDStatusBarStyleDefault]) {

+ 6 - 3
Libraries external/JDStatusBarNotification/JDStatusBarView.h → Carthage/Checkouts/JDStatusBarNotification/JDStatusBarNotification/JDStatusBarView.h

@@ -7,12 +7,15 @@
 //
 
 #import <UIKit/UIKit.h>
+#import "JDStatusBarStyle.h"
+
+NS_ASSUME_NONNULL_BEGIN
 
 @interface JDStatusBarView : UIView
 @property (nonatomic, strong, readonly) UILabel *textLabel;
 @property (nonatomic, strong, readonly) UIActivityIndicatorView *activityIndicatorView;
 @property (nonatomic, assign) CGFloat textVerticalPositionAdjustment;
-
-+ (BOOL)isIphoneX;
-
+@property (nonatomic, assign) JDStatusBarHeightForIPhoneX heightForIPhoneX;
 @end
+
+NS_ASSUME_NONNULL_END

+ 19 - 50
Libraries external/JDStatusBarNotification/JDStatusBarView.m → Carthage/Checkouts/JDStatusBarNotification/JDStatusBarNotification/JDStatusBarView.m

@@ -7,9 +7,7 @@
 //
 
 #import "JDStatusBarView.h"
-#import <sys/utsname.h>
-
-CGFloat const ADJUSTIPHONEX = 28;
+#import "JDStatusBarLayoutMarginHelper.h"
 
 @interface JDStatusBarView ()
 @property (nonatomic, strong) UILabel *textLabel;
@@ -57,29 +55,32 @@ CGFloat const ADJUSTIPHONEX = 28;
 - (void)layoutSubviews;
 {
   [super layoutSubviews];
-    
-  CGFloat yPos = self.textVerticalPositionAdjustment;
-  CGFloat textLabelHeight = self.bounds.size.height-1;
-  if ([JDStatusBarView isIphoneX]) {
-    yPos += ADJUSTIPHONEX;
-    textLabelHeight -= ADJUSTIPHONEX;
-  }
 
   // label
-  self.textLabel.frame = CGRectMake(0, 1+yPos,
-                                    self.bounds.size.width, textLabelHeight);
+  CGFloat topLayoutMargin = JDStatusBarRootVCLayoutMargin().top;
+  CGFloat labelY = self.textVerticalPositionAdjustment + topLayoutMargin + 1;
+  CGFloat height = self.bounds.size.height - topLayoutMargin - 1;
+
+  // adjust for iPhone X
+  if (topLayoutMargin > 0){
+    switch (_heightForIPhoneX) {
+      case JDStatusBarHeightForIPhoneXHalf:
+        labelY -= 12;
+        height += 9.0;
+        break;
+      case JDStatusBarHeightForIPhoneXFullNavBar:
+        break;
+    }
+  }
+
+  self.textLabel.frame = CGRectMake(0, labelY, self.bounds.size.width, height);
 
   // activity indicator
   if (_activityIndicatorView ) {
     CGSize textSize = [self currentTextSize];
     CGRect indicatorFrame = _activityIndicatorView.frame;
     indicatorFrame.origin.x = round((self.bounds.size.width - textSize.width)/2.0) - indicatorFrame.size.width - 8.0;
-    indicatorFrame.origin.y = ceil(1+(self.bounds.size.height - indicatorFrame.size.height)/2.0);
-      
-  if ([JDStatusBarView isIphoneX]) {
-    indicatorFrame.origin.y += ADJUSTIPHONEX * 0.5;
-  }
-      
+    indicatorFrame.origin.y = labelY + 1 + floor((CGRectGetHeight(self.textLabel.bounds) - CGRectGetHeight(indicatorFrame))/2.0);
     _activityIndicatorView.frame = indicatorFrame;
   }
 }
@@ -107,36 +108,4 @@ CGFloat const ADJUSTIPHONEX = 28;
   return textSize;
 }
 
-+ (BOOL)isIphoneX
-{
-  NSString *modelName = [self modelName];
-  return [modelName isEqualToString: @"Phone10,3"] || [modelName isEqualToString: @"iPhone10,6"] || [JDStatusBarView isSimulatorIphoneX];
-}
-
-+ (NSString *)modelName
-{
-  struct utsname systemInfo;
-  uname(&systemInfo);
-  return [NSString stringWithCString:systemInfo.machine encoding:NSUTF8StringEncoding];
-}
-
-+ (BOOL)isSimulatorIphoneX
-{
-  if ([JDStatusBarView isSimulator] && [UIScreen mainScreen].bounds.size.height == 812) {
-    return YES;
-  } else {
-    return NO;
-  }
-}
-
-+ (BOOL)isSimulator
-{
-#if TARGET_OS_SIMULATOR
-  return YES;
-#else
-  return NO;
-#endif
-}
-
-
 @end

+ 25 - 0
Carthage/Checkouts/JDStatusBarNotification/LICENSE

@@ -0,0 +1,25 @@
+Copyright © 2013 Markus Emrich
+
+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.
+
+
+(MIT License)

+ 24 - 0
Carthage/Checkouts/JDStatusBarNotification/Miscellaneous/Info.plist

@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
+<plist version="1.0">
+<dict>
+	<key>CFBundleDevelopmentRegion</key>
+	<string>$(DEVELOPMENT_LANGUAGE)</string>
+	<key>CFBundleExecutable</key>
+	<string>$(EXECUTABLE_NAME)</string>
+	<key>CFBundleIdentifier</key>
+	<string>$(PRODUCT_BUNDLE_IDENTIFIER)</string>
+	<key>CFBundleInfoDictionaryVersion</key>
+	<string>6.0</string>
+	<key>CFBundleName</key>
+	<string>$(PRODUCT_NAME)</string>
+	<key>CFBundlePackageType</key>
+	<string>FMWK</string>
+	<key>CFBundleShortVersionString</key>
+	<string>1.0</string>
+	<key>CFBundleVersion</key>
+	<string>$(CURRENT_PROJECT_VERSION)</string>
+	<key>NSPrincipalClass</key>
+	<string></string>
+</dict>
+</plist>

BIN
Carthage/Checkouts/JDStatusBarNotification/gfx/activity.gif


BIN
Carthage/Checkouts/JDStatusBarNotification/gfx/animation.gif


BIN
Carthage/Checkouts/JDStatusBarNotification/gfx/iphoneX.png


BIN
Carthage/Checkouts/JDStatusBarNotification/gfx/progress.gif


BIN
Carthage/Checkouts/JDStatusBarNotification/gfx/screenshots.png


BIN
Carthage/Checkouts/JDStatusBarNotification/gfx/styles.png


BIN
Carthage/Checkouts/JDStatusBarNotification/gfx/tweetbutton.png


+ 0 - 77
Libraries external/JDStatusBarNotification/JDStatusBarStyle.h

@@ -1,77 +0,0 @@
-//
-//  JDStatusBarStyle.h
-//  JDStatusBarNotificationExample
-//
-//  Created by Markus on 04.12.13.
-//  Copyright (c) 2013 Markus. All rights reserved.
-//
-
-#import <Foundation/Foundation.h>
-#import <UIKit/UIKit.h>
-
-extern NSString *const JDStatusBarStyleError;   /// This style has a red background with a white Helvetica label.
-extern NSString *const JDStatusBarStyleWarning; /// This style has a yellow background with a gray Helvetica label.
-extern NSString *const JDStatusBarStyleSuccess; /// This style has a green background with a white Helvetica label.
-extern NSString *const JDStatusBarStyleMatrix;  /// This style has a black background with a green bold Courier label.
-extern NSString *const JDStatusBarStyleDefault; /// This style has a white background with a gray Helvetica label.
-extern NSString *const JDStatusBarStyleDark;    /// This style has a nearly black background with a nearly white Helvetica label.
-
-typedef NS_ENUM(NSInteger, JDStatusBarAnimationType) {
-    JDStatusBarAnimationTypeNone,   /// Notification won't animate
-    JDStatusBarAnimationTypeMove,   /// Notification will move in from the top, and move out again to the top
-    JDStatusBarAnimationTypeBounce, /// Notification will fall down from the top and bounce a little bit
-    JDStatusBarAnimationTypeFade    /// Notification will fade in and fade out
-};
-
-typedef NS_ENUM(NSInteger, JDStatusBarProgressBarPosition) {
-    JDStatusBarProgressBarPositionBottom, /// progress bar will be at the bottom of the status bar
-    JDStatusBarProgressBarPositionCenter, /// progress bar will be at the center of the status bar
-    JDStatusBarProgressBarPositionTop,    /// progress bar will be at the top of the status bar
-    JDStatusBarProgressBarPositionBelow,  /// progress bar will be below the status bar (the prograss bar won't move with the statusbar in this case)
-    JDStatusBarProgressBarPositionNavBar, /// progress bar will be below the navigation bar (the prograss bar won't move with the statusbar in this case)
-};
-
-/**
- *  A Style defines the appeareance of a notification.
- */
-@interface JDStatusBarStyle : NSObject <NSCopying>
-
-/// The background color of the notification bar
-@property (nonatomic, strong) UIColor *barColor;
-
-/// The text color of the notification label
-@property (nonatomic, strong) UIColor *textColor;
-
-/// The text shadow of the notification label
-@property (nonatomic, strong) NSShadow *textShadow;
-
-/// The font of the notification label
-@property (nonatomic, strong) UIFont *font;
-
-/// A correction of the vertical label position in points. Default is 0.0
-@property (nonatomic, assign) CGFloat textVerticalPositionAdjustment;
-
-#pragma mark Animation
-
-/// The animation, that is used to present the notification
-@property (nonatomic, assign) JDStatusBarAnimationType animationType;
-
-#pragma mark Progress Bar
-
-/// The background color of the progress bar (on top of the notification bar)
-@property (nonatomic, strong) UIColor *progressBarColor;
-
-/// The height of the progress bar. Default is 1.0
-@property (nonatomic, assign) CGFloat progressBarHeight;
-
-/// The position of the progress bar. Default is JDStatusBarProgressBarPositionBottom
-@property (nonatomic, assign) JDStatusBarProgressBarPosition progressBarPosition;
-
-/// The insets of the progress bar. Default is 0.0
-@property (nonatomic, assign) CGFloat progressBarHorizontalInsets;
-
-/// The corner radius of the progress bar. Default is 0.0
-@property (nonatomic, assign) CGFloat progressBarCornerRadius;
-
-@end
-

+ 5 - 26
Nextcloud.xcodeproj/project.pbxproj

@@ -401,9 +401,6 @@
 		F784FA2F210F6FC000256C26 /* KTVCocoaHTTPServer.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = F784FA26210F672E00256C26 /* KTVCocoaHTTPServer.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; };
 		F784FA30210F6FC500256C26 /* KTVHTTPCache.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = F784FA27210F672E00256C26 /* KTVHTTPCache.framework */; };
 		F784FA31210F6FC500256C26 /* KTVHTTPCache.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = F784FA27210F672E00256C26 /* KTVHTTPCache.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; };
-		F78964AD1EBB576C00403E13 /* JDStatusBarNotification.m in Sources */ = {isa = PBXBuildFile; fileRef = F78964A81EBB576C00403E13 /* JDStatusBarNotification.m */; };
-		F78964AE1EBB576C00403E13 /* JDStatusBarStyle.m in Sources */ = {isa = PBXBuildFile; fileRef = F78964AA1EBB576C00403E13 /* JDStatusBarStyle.m */; };
-		F78964AF1EBB576C00403E13 /* JDStatusBarView.m in Sources */ = {isa = PBXBuildFile; fileRef = F78964AC1EBB576C00403E13 /* JDStatusBarView.m */; };
 		F78ACD4021903CC20088454D /* NCGridCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = F78ACD3F21903CC20088454D /* NCGridCell.swift */; };
 		F78ACD4221903CE00088454D /* NCListCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = F78ACD4121903CE00088454D /* NCListCell.swift */; };
 		F78ACD4421903CF20088454D /* NCListCell.xib in Resources */ = {isa = PBXBuildFile; fileRef = F78ACD4321903CF20088454D /* NCListCell.xib */; };
@@ -460,6 +457,7 @@
 		F7C40BE721998F410004137E /* DZNEmptyDataSet.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = F7C40BE621998F410004137E /* DZNEmptyDataSet.framework */; };
 		F7C40BE9219991A60004137E /* EAIntroView.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = F7C40BE8219991A60004137E /* EAIntroView.framework */; };
 		F7C40BEB219991AC0004137E /* EARestrictedScrollView.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = F7C40BEA219991AC0004137E /* EARestrictedScrollView.framework */; };
+		F7C40BED219993330004137E /* JDStatusBarNotification.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = F7C40BEC219993330004137E /* JDStatusBarNotification.framework */; };
 		F7C525A01E3B48B700FFE02C /* CCNotification.swift in Sources */ = {isa = PBXBuildFile; fileRef = F7C5259F1E3B48B700FFE02C /* CCNotification.swift */; };
 		F7C525A21E3B6DA800FFE02C /* CCNotification.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = F7C525A11E3B6DA800FFE02C /* CCNotification.storyboard */; };
 		F7CA1ED020E7E3FE002CC65E /* UIImage+PKDownloadButton.m in Sources */ = {isa = PBXBuildFile; fileRef = F7CA1EBC20E7E3FE002CC65E /* UIImage+PKDownloadButton.m */; };
@@ -1144,12 +1142,6 @@
 		F784FA25210F672E00256C26 /* KTVHTTPCache.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = KTVHTTPCache.h; sourceTree = "<group>"; };
 		F784FA26210F672E00256C26 /* KTVCocoaHTTPServer.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; path = KTVCocoaHTTPServer.framework; sourceTree = "<group>"; };
 		F784FA27210F672E00256C26 /* KTVHTTPCache.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; path = KTVHTTPCache.framework; sourceTree = "<group>"; };
-		F78964A71EBB576C00403E13 /* JDStatusBarNotification.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = JDStatusBarNotification.h; sourceTree = "<group>"; };
-		F78964A81EBB576C00403E13 /* JDStatusBarNotification.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = JDStatusBarNotification.m; sourceTree = "<group>"; };
-		F78964A91EBB576C00403E13 /* JDStatusBarStyle.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = JDStatusBarStyle.h; sourceTree = "<group>"; };
-		F78964AA1EBB576C00403E13 /* JDStatusBarStyle.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = JDStatusBarStyle.m; sourceTree = "<group>"; };
-		F78964AB1EBB576C00403E13 /* JDStatusBarView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = JDStatusBarView.h; sourceTree = "<group>"; };
-		F78964AC1EBB576C00403E13 /* JDStatusBarView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = JDStatusBarView.m; sourceTree = "<group>"; };
 		F78ACD3F21903CC20088454D /* NCGridCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = NCGridCell.swift; sourceTree = "<group>"; };
 		F78ACD4121903CE00088454D /* NCListCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = NCListCell.swift; sourceTree = "<group>"; };
 		F78ACD4321903CF20088454D /* NCListCell.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; path = NCListCell.xib; sourceTree = "<group>"; };
@@ -1244,6 +1236,7 @@
 		F7C40BE621998F410004137E /* DZNEmptyDataSet.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = DZNEmptyDataSet.framework; path = Carthage/Build/iOS/DZNEmptyDataSet.framework; sourceTree = "<group>"; };
 		F7C40BE8219991A60004137E /* EAIntroView.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = EAIntroView.framework; path = Carthage/Build/iOS/EAIntroView.framework; sourceTree = "<group>"; };
 		F7C40BEA219991AC0004137E /* EARestrictedScrollView.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = EARestrictedScrollView.framework; path = Carthage/Build/iOS/EARestrictedScrollView.framework; sourceTree = "<group>"; };
+		F7C40BEC219993330004137E /* JDStatusBarNotification.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = JDStatusBarNotification.framework; path = Carthage/Build/iOS/JDStatusBarNotification.framework; sourceTree = "<group>"; };
 		F7C5259F1E3B48B700FFE02C /* CCNotification.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = CCNotification.swift; path = Notification/CCNotification.swift; sourceTree = "<group>"; };
 		F7C525A11E3B6DA800FFE02C /* CCNotification.storyboard */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.storyboard; name = CCNotification.storyboard; path = Notification/CCNotification.storyboard; sourceTree = "<group>"; };
 		F7C742C01E7BD01F00D9C973 /* iOSClient.entitlements */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.entitlements; path = iOSClient.entitlements; sourceTree = "<group>"; };
@@ -1486,6 +1479,7 @@
 				F7C40BE521998D5B0004137E /* MGSwipeTableCell.framework in Frameworks */,
 				F7C40BEB219991AC0004137E /* EARestrictedScrollView.framework in Frameworks */,
 				F7A3771A1EB2364A002856D3 /* Fabric.framework in Frameworks */,
+				F7C40BED219993330004137E /* JDStatusBarNotification.framework in Frameworks */,
 				F7C40BE721998F410004137E /* DZNEmptyDataSet.framework in Frameworks */,
 				F72D0FFE210B6638009C96B7 /* nanopb.framework in Frameworks */,
 				F72D0FFD210B6638009C96B7 /* GoogleToolboxForMac.framework in Frameworks */,
@@ -1652,7 +1646,6 @@
 			children = (
 				F70F02B21C889183008DAB36 /* AFViewShaker */,
 				F72D0FED210B6638009C96B7 /* Firebase */,
-				F78964A61EBB576C00403E13 /* JDStatusBarNotification */,
 				F784FA24210F672E00256C26 /* KTVHTTPCache */,
 				F7659A2F1DC0B737004860C4 /* iRate */,
 				F70F04821C889183008DAB36 /* MBProgressHUD */,
@@ -2384,19 +2377,6 @@
 			path = KTVHTTPCache;
 			sourceTree = "<group>";
 		};
-		F78964A61EBB576C00403E13 /* JDStatusBarNotification */ = {
-			isa = PBXGroup;
-			children = (
-				F78964A71EBB576C00403E13 /* JDStatusBarNotification.h */,
-				F78964A81EBB576C00403E13 /* JDStatusBarNotification.m */,
-				F78964A91EBB576C00403E13 /* JDStatusBarStyle.h */,
-				F78964AA1EBB576C00403E13 /* JDStatusBarStyle.m */,
-				F78964AB1EBB576C00403E13 /* JDStatusBarView.h */,
-				F78964AC1EBB576C00403E13 /* JDStatusBarView.m */,
-			);
-			path = JDStatusBarNotification;
-			sourceTree = "<group>";
-		};
 		F78ACD3E21903BA20088454D /* Cell */ = {
 			isa = PBXGroup;
 			children = (
@@ -3046,6 +3026,7 @@
 		F7FC7D541DC1F93700BB2C6A /* Frameworks */ = {
 			isa = PBXGroup;
 			children = (
+				F7C40BEC219993330004137E /* JDStatusBarNotification.framework */,
 				F7C40BEA219991AC0004137E /* EARestrictedScrollView.framework */,
 				F7C40BE8219991A60004137E /* EAIntroView.framework */,
 				F7C40BE621998F410004137E /* DZNEmptyDataSet.framework */,
@@ -3487,6 +3468,7 @@
 				"$(SRCROOT)/Carthage/Build/iOS/DZNEmptyDataSet.framework",
 				"$(SRCROOT)/Carthage/Build/iOS/EAIntroView.framework",
 				"$(SRCROOT)/Carthage/Build/iOS/EARestrictedScrollView.framework",
+				"$(SRCROOT)/Carthage/Build/iOS/JDStatusBarNotification.framework",
 			);
 			outputPaths = (
 			);
@@ -3768,7 +3750,6 @@
 				F77B0E311D118A16002130FE /* CCExifGeo.m in Sources */,
 				F758B449212C516300515F55 /* UIImage+Orientation.swift in Sources */,
 				F73B4F0E1F470D9100BBEE4B /* nsMBCSGroupProber.cpp in Sources */,
-				F78964AE1EBB576C00403E13 /* JDStatusBarStyle.m in Sources */,
 				F7EC9CBC21185F2000F1C5CE /* CCMedia.m in Sources */,
 				F7D423831F0596C6009C9782 /* ReaderThumbFetch.m in Sources */,
 				F73B4F171F470D9100BBEE4B /* uchardet.cpp in Sources */,
@@ -3872,7 +3853,6 @@
 				F758B43E212C516300515F55 /* ImageScannerController.swift in Sources */,
 				F70022B31EC4C9100080073F /* OCActivity.m in Sources */,
 				F70022D41EC4C9100080073F /* NSDate+ISO8601.m in Sources */,
-				F78964AD1EBB576C00403E13 /* JDStatusBarNotification.m in Sources */,
 				F758B44C212C516300515F55 /* ZoomGestureController.swift in Sources */,
 				F762CB151EACB66200B38484 /* XLFormRowNavigationAccessoryView.m in Sources */,
 				F77B0EB61D118A16002130FE /* MBProgressHUD.m in Sources */,
@@ -3896,7 +3876,6 @@
 				F7F54D0B1E5B14C800E19C62 /* MWTapDetectingImageView.m in Sources */,
 				F7D423821F0596C6009C9782 /* ReaderThumbCache.m in Sources */,
 				F70022A71EC4C9100080073F /* AFSecurityPolicy.m in Sources */,
-				F78964AF1EBB576C00403E13 /* JDStatusBarView.m in Sources */,
 				F7CA1ED220E7E3FE002CC65E /* PKCircleView.m in Sources */,
 				F7F54D0D1E5B14C800E19C62 /* MWZoomingScrollView.m in Sources */,
 				F762CB0B1EACB66200B38484 /* XLFormRowDescriptor.m in Sources */,

+ 1 - 1
iOSClient/AppDelegate.m

@@ -22,6 +22,7 @@
 //
 
 #import "AppDelegate.h"
+#import <JDStatusBarNotification/JDStatusBarNotification.h>
 
 #import "iRate.h"
 #import "AFURLSessionManager.h"
@@ -33,7 +34,6 @@
 #import "CCDetail.h"
 #import <Fabric/Fabric.h>
 #import <Crashlytics/Crashlytics.h>
-#import "JDStatusBarNotification.h"
 #import "NCBridgeSwift.h"
 #import "NCAutoUpload.h"
 #import "Firebase.h"

+ 2 - 1
iOSClient/Main/CCMain.m

@@ -21,6 +21,8 @@
 //  along with this program.  If not, see <http://www.gnu.org/licenses/>.
 //
 
+#import <JDStatusBarNotification/JDStatusBarNotification.h>
+
 #import "CCMain.h"
 #import "AppDelegate.h"
 #import "CCMedia.h"
@@ -30,7 +32,6 @@
 #import "OCNotificationsAction.h"
 #import "OCFrameworkConstants.h"
 #import "OCCapabilities.h"
-#import "JDStatusBarNotification.h"
 #import "NCAutoUpload.h"
 #import "NCBridgeSwift.h"
 #import "NCNetworkingEndToEnd.h"

+ 2 - 1
iOSClient/Settings/CCManageAccount.m

@@ -21,9 +21,10 @@
 //  along with this program.  If not, see <http://www.gnu.org/licenses/>.
 //
 
+#import <JDStatusBarNotification/JDStatusBarNotification.h>
+
 #import "CCManageAccount.h"
 #import "AppDelegate.h"
-#import "JDStatusBarNotification.h"
 #import "CCLogin.h"
 #import "NCAutoUpload.h"
 #import "NCBridgeSwift.h"