summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Juick.xcodeproj/project.pbxproj4
-rw-r--r--Juick/AppDelegate.h2
-rw-r--r--Juick/AppDelegate.m14
-rw-r--r--Juick/Images.xcassets/AppIcon.appiconset/AppIcon29x29-1.pngbin0 -> 6571 bytes
-rw-r--r--Juick/Images.xcassets/AppIcon.appiconset/AppIcon29x29.pngbin0 -> 6571 bytes
-rw-r--r--Juick/Images.xcassets/AppIcon.appiconset/AppIcon29x29@2x-1.pngbin0 -> 9324 bytes
-rw-r--r--Juick/Images.xcassets/AppIcon.appiconset/AppIcon29x29@2x.pngbin0 -> 9324 bytes
-rw-r--r--Juick/Images.xcassets/AppIcon.appiconset/AppIcon40x40.pngbin0 -> 7427 bytes
-rw-r--r--Juick/Images.xcassets/AppIcon.appiconset/AppIcon40x40@2x-1.pngbin0 -> 12547 bytes
-rw-r--r--Juick/Images.xcassets/AppIcon.appiconset/AppIcon40x40@2x.pngbin0 -> 12547 bytes
-rw-r--r--Juick/Images.xcassets/AppIcon.appiconset/AppIcon60x60@2x.pngbin0 -> 19564 bytes
-rw-r--r--Juick/Images.xcassets/AppIcon.appiconset/AppIcon76x76.pngbin0 -> 11214 bytes
-rw-r--r--Juick/Images.xcassets/AppIcon.appiconset/AppIcon76x76@2x.pngbin0 -> 28000 bytes
-rw-r--r--Juick/Images.xcassets/AppIcon.appiconset/Contents.json77
-rw-r--r--Juick/MessagesViewController.h2
-rw-r--r--Juick/MessagesViewController.m19
16 files changed, 104 insertions, 14 deletions
diff --git a/Juick.xcodeproj/project.pbxproj b/Juick.xcodeproj/project.pbxproj
index 21f3035..0e7a9b3 100644
--- a/Juick.xcodeproj/project.pbxproj
+++ b/Juick.xcodeproj/project.pbxproj
@@ -475,7 +475,7 @@
INFOPLIST_FILE = "Juick/Juick-Info.plist";
IPHONEOS_DEPLOYMENT_TARGET = 7.0;
PRODUCT_NAME = "$(TARGET_NAME)";
- TARGETED_DEVICE_FAMILY = 1;
+ TARGETED_DEVICE_FAMILY = "1,2";
WRAPPER_EXTENSION = app;
};
name = Debug;
@@ -495,7 +495,7 @@
INFOPLIST_FILE = "Juick/Juick-Info.plist";
IPHONEOS_DEPLOYMENT_TARGET = 7.0;
PRODUCT_NAME = "$(TARGET_NAME)";
- TARGETED_DEVICE_FAMILY = 1;
+ TARGETED_DEVICE_FAMILY = "1,2";
WRAPPER_EXTENSION = app;
};
name = Release;
diff --git a/Juick/AppDelegate.h b/Juick/AppDelegate.h
index 087b6fd..0b1fbb7 100644
--- a/Juick/AppDelegate.h
+++ b/Juick/AppDelegate.h
@@ -13,6 +13,6 @@
@interface AppDelegate : UIResponder <UIApplicationDelegate>
@property (strong, nonatomic) UIWindow *window;
-@property (strong, nonatomic) SWRevealViewController *viewController;
+@property (strong, nonatomic) UIViewController *viewController;
@end
diff --git a/Juick/AppDelegate.m b/Juick/AppDelegate.m
index f59ff02..28bacc9 100644
--- a/Juick/AppDelegate.m
+++ b/Juick/AppDelegate.m
@@ -30,12 +30,18 @@
UINavigationController *main = [[UINavigationController alloc] initWithRootViewController:messages];
UINavigationController *rearNav = [[UINavigationController alloc] initWithRootViewController:rear];
-
- SWRevealViewController *reveal = [[SWRevealViewController alloc] initWithRearViewController:rearNav frontViewController:main];
- self.viewController = reveal;
+ if (UI_USER_INTERFACE_IDIOM() == UIUserInterfaceIdiomPhone) {
+ SWRevealViewController *reveal = [[SWRevealViewController alloc] initWithRearViewController:rearNav frontViewController:main];
+ self.viewController = reveal;
+ } else {
+ UISplitViewController *split = [[UISplitViewController alloc] init];
+ split.viewControllers = [NSArray arrayWithObjects:rearNav, main, nil];
+ split.delegate = messages;
+ self.viewController = split;
+ }
self.window = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]];
- self.window.rootViewController = reveal;
+ self.window.rootViewController = self.viewController;
[self.window makeKeyAndVisible];
return YES;
diff --git a/Juick/Images.xcassets/AppIcon.appiconset/AppIcon29x29-1.png b/Juick/Images.xcassets/AppIcon.appiconset/AppIcon29x29-1.png
new file mode 100644
index 0000000..c17b09a
--- /dev/null
+++ b/Juick/Images.xcassets/AppIcon.appiconset/AppIcon29x29-1.png
Binary files differ
diff --git a/Juick/Images.xcassets/AppIcon.appiconset/AppIcon29x29.png b/Juick/Images.xcassets/AppIcon.appiconset/AppIcon29x29.png
new file mode 100644
index 0000000..c17b09a
--- /dev/null
+++ b/Juick/Images.xcassets/AppIcon.appiconset/AppIcon29x29.png
Binary files differ
diff --git a/Juick/Images.xcassets/AppIcon.appiconset/AppIcon29x29@2x-1.png b/Juick/Images.xcassets/AppIcon.appiconset/AppIcon29x29@2x-1.png
new file mode 100644
index 0000000..1f51f3e
--- /dev/null
+++ b/Juick/Images.xcassets/AppIcon.appiconset/AppIcon29x29@2x-1.png
Binary files differ
diff --git a/Juick/Images.xcassets/AppIcon.appiconset/AppIcon29x29@2x.png b/Juick/Images.xcassets/AppIcon.appiconset/AppIcon29x29@2x.png
new file mode 100644
index 0000000..1f51f3e
--- /dev/null
+++ b/Juick/Images.xcassets/AppIcon.appiconset/AppIcon29x29@2x.png
Binary files differ
diff --git a/Juick/Images.xcassets/AppIcon.appiconset/AppIcon40x40.png b/Juick/Images.xcassets/AppIcon.appiconset/AppIcon40x40.png
new file mode 100644
index 0000000..0af7db9
--- /dev/null
+++ b/Juick/Images.xcassets/AppIcon.appiconset/AppIcon40x40.png
Binary files differ
diff --git a/Juick/Images.xcassets/AppIcon.appiconset/AppIcon40x40@2x-1.png b/Juick/Images.xcassets/AppIcon.appiconset/AppIcon40x40@2x-1.png
new file mode 100644
index 0000000..f08b9dc
--- /dev/null
+++ b/Juick/Images.xcassets/AppIcon.appiconset/AppIcon40x40@2x-1.png
Binary files differ
diff --git a/Juick/Images.xcassets/AppIcon.appiconset/AppIcon40x40@2x.png b/Juick/Images.xcassets/AppIcon.appiconset/AppIcon40x40@2x.png
new file mode 100644
index 0000000..f08b9dc
--- /dev/null
+++ b/Juick/Images.xcassets/AppIcon.appiconset/AppIcon40x40@2x.png
Binary files differ
diff --git a/Juick/Images.xcassets/AppIcon.appiconset/AppIcon60x60@2x.png b/Juick/Images.xcassets/AppIcon.appiconset/AppIcon60x60@2x.png
new file mode 100644
index 0000000..55ec21c
--- /dev/null
+++ b/Juick/Images.xcassets/AppIcon.appiconset/AppIcon60x60@2x.png
Binary files differ
diff --git a/Juick/Images.xcassets/AppIcon.appiconset/AppIcon76x76.png b/Juick/Images.xcassets/AppIcon.appiconset/AppIcon76x76.png
new file mode 100644
index 0000000..9bcf101
--- /dev/null
+++ b/Juick/Images.xcassets/AppIcon.appiconset/AppIcon76x76.png
Binary files differ
diff --git a/Juick/Images.xcassets/AppIcon.appiconset/AppIcon76x76@2x.png b/Juick/Images.xcassets/AppIcon.appiconset/AppIcon76x76@2x.png
new file mode 100644
index 0000000..e06b21e
--- /dev/null
+++ b/Juick/Images.xcassets/AppIcon.appiconset/AppIcon76x76@2x.png
Binary files differ
diff --git a/Juick/Images.xcassets/AppIcon.appiconset/Contents.json b/Juick/Images.xcassets/AppIcon.appiconset/Contents.json
index a396706..985f259 100644
--- a/Juick/Images.xcassets/AppIcon.appiconset/Contents.json
+++ b/Juick/Images.xcassets/AppIcon.appiconset/Contents.json
@@ -1,18 +1,93 @@
{
"images" : [
{
+ "size" : "29x29",
"idiom" : "iphone",
+ "filename" : "AppIcon29x29.png",
+ "scale" : "1x"
+ },
+ {
"size" : "29x29",
+ "idiom" : "iphone",
+ "filename" : "AppIcon29x29@2x.png",
"scale" : "2x"
},
{
- "idiom" : "iphone",
"size" : "40x40",
+ "idiom" : "iphone",
+ "filename" : "AppIcon40x40@2x-1.png",
"scale" : "2x"
},
{
"idiom" : "iphone",
+ "size" : "57x57",
+ "scale" : "1x"
+ },
+ {
+ "idiom" : "iphone",
+ "size" : "57x57",
+ "scale" : "2x"
+ },
+ {
"size" : "60x60",
+ "idiom" : "iphone",
+ "filename" : "AppIcon60x60@2x.png",
+ "scale" : "2x"
+ },
+ {
+ "size" : "29x29",
+ "idiom" : "ipad",
+ "filename" : "AppIcon29x29-1.png",
+ "scale" : "1x"
+ },
+ {
+ "size" : "29x29",
+ "idiom" : "ipad",
+ "filename" : "AppIcon29x29@2x-1.png",
+ "scale" : "2x"
+ },
+ {
+ "size" : "40x40",
+ "idiom" : "ipad",
+ "filename" : "AppIcon40x40.png",
+ "scale" : "1x"
+ },
+ {
+ "size" : "40x40",
+ "idiom" : "ipad",
+ "filename" : "AppIcon40x40@2x.png",
+ "scale" : "2x"
+ },
+ {
+ "idiom" : "ipad",
+ "size" : "50x50",
+ "scale" : "1x"
+ },
+ {
+ "idiom" : "ipad",
+ "size" : "50x50",
+ "scale" : "2x"
+ },
+ {
+ "idiom" : "ipad",
+ "size" : "72x72",
+ "scale" : "1x"
+ },
+ {
+ "idiom" : "ipad",
+ "size" : "72x72",
+ "scale" : "2x"
+ },
+ {
+ "size" : "76x76",
+ "idiom" : "ipad",
+ "filename" : "AppIcon76x76.png",
+ "scale" : "1x"
+ },
+ {
+ "size" : "76x76",
+ "idiom" : "ipad",
+ "filename" : "AppIcon76x76@2x.png",
"scale" : "2x"
}
],
diff --git a/Juick/MessagesViewController.h b/Juick/MessagesViewController.h
index ceff611..a5081de 100644
--- a/Juick/MessagesViewController.h
+++ b/Juick/MessagesViewController.h
@@ -8,7 +8,7 @@
#import <UIKit/UIKit.h>
-@interface MessagesViewController : UITableViewController
+@interface MessagesViewController : UITableViewController<UISplitViewControllerDelegate>
- (id)initWithURL:(NSURL *)messagesURL;
- (void) refreshData:(UIRefreshControl *)refresh;
@end
diff --git a/Juick/MessagesViewController.m b/Juick/MessagesViewController.m
index 1fb4ece..2f5cc29 100644
--- a/Juick/MessagesViewController.m
+++ b/Juick/MessagesViewController.m
@@ -95,12 +95,13 @@ static NSString *CellIdentifier = @"MessageCell";
self.dataLoading = NO;
self.title = @"Discover";
[self.view setBackgroundColor:[ColorsAndButtons mainBackground]];
- SWRevealViewController *revealController = [self revealViewController];
- [self.navigationController.navigationBar addGestureRecognizer:revealController.panGestureRecognizer];
- UIBarButtonItem *revealButtonItem = [[UIBarButtonItem alloc] initWithImage:[UIImage imageNamed:@"reveal-icon.png"]
+ if (UI_USER_INTERFACE_IDIOM() == UIUserInterfaceIdiomPhone) {
+ SWRevealViewController *revealController = [self revealViewController];
+ [self.navigationController.navigationBar addGestureRecognizer:revealController.panGestureRecognizer];
+ UIBarButtonItem *revealButtonItem = [[UIBarButtonItem alloc] initWithImage:[UIImage imageNamed:@"reveal-icon.png"]
style:UIBarButtonItemStyleBordered target:revealController action:@selector(revealToggle:)];
-
- self.navigationItem.leftBarButtonItem = revealButtonItem;
+ self.navigationItem.leftBarButtonItem = revealButtonItem;
+ }
self.messages = [NSMutableArray array];
UIRefreshControl *refresh = [[UIRefreshControl alloc] init];
[refresh addTarget:self action:@selector(refreshData:) forControlEvents:UIControlEventValueChanged];
@@ -198,5 +199,13 @@ static NSString *CellIdentifier = @"MessageCell";
return 100.0f;
}
+-(void)splitViewController:(UISplitViewController *)svc willShowViewController:(UIViewController *)aViewController invalidatingBarButtonItem:(UIBarButtonItem *)barButtonItem {
+ self.navigationItem.leftBarButtonItem = nil;
+}
+
+-(void)splitViewController:(UISplitViewController *)svc willHideViewController:(UIViewController *)aViewController withBarButtonItem:(UIBarButtonItem *)barButtonItem forPopoverController:(UIPopoverController *)pc {
+ self.navigationItem.leftBarButtonItem = barButtonItem;
+}
+
@end