Skip to content

Commit

Permalink
Facebook iOS SDK 3.8
Browse files Browse the repository at this point in the history
Summary:
     see https://developers.facebook.com/ios/change-log-3.x/

    Upgrading from 3.7
     https://developers.facebook.com/docs/ios/upgrading-from-3.7-to-3.8/

Reviewed By: chrisp

Test Plan: Release Testing.
  • Loading branch information
onebit committed Sep 19, 2013
1 parent 99af010 commit 41f9a18
Show file tree
Hide file tree
Showing 131 changed files with 5,546 additions and 2,523 deletions.
Expand Up @@ -73,7 +73,9 @@
E2D6B81115413A570050835F /* Frameworks */,
E2D6B80F15413A570050835F /* Products */,
);
indentWidth = 4;
sourceTree = "<group>";
tabWidth = 4;
};
E2D6B80F15413A570050835F /* Products */ = {
isa = PBXGroup;
Expand Down
23 changes: 16 additions & 7 deletions samples/FriendPickerSample/FriendPickerSample/FPAppDelegate.m
Expand Up @@ -6,7 +6,7 @@
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
Expand Down Expand Up @@ -50,17 +50,26 @@ - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(
} else {
self.rootViewController = [[FPViewController alloc] initWithNibName:@"FPViewController_iPad" bundle:nil];
}
#ifdef __IPHONE_7_0
#ifdef __IPHONE_OS_VERSION_MAX_ALLOWED
#if __IPHONE_OS_VERSION_MAX_ALLOWED >= __IPHONE_7_0
if ([self.rootViewController respondsToSelector:@selector(setEdgesForExtendedLayout:)]) {
self.rootViewController.edgesForExtendedLayout &= ~UIRectEdgeTop;
}
#endif
#endif
#endif
self.rootViewController.navigationItem.title = @"Friend Picker";

// Set up a UINavigationController as the basis of this app, with the nib generated viewController
// as the initial view.
UINavigationController *navigationController =
[[UINavigationController alloc] initWithRootViewController:self.rootViewController];
UINavigationController *navigationController =
[[UINavigationController alloc] initWithRootViewController:self.rootViewController];

self.window = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]];
self.window.rootViewController = navigationController;
[self.window makeKeyAndVisible];

return YES;
}

Expand All @@ -72,7 +81,7 @@ - (NSUInteger)supportedInterfaceOrientations{
// It is important to close any FBSession object that is no longer useful
- (void)applicationWillTerminate:(UIApplication *)application {
// Close the session before quitting
// this is a good idea because things may be hanging off the session, that need
// this is a good idea because things may be hanging off the session, that need
// releasing (completion block, etc.) and other components in the app may be awaiting
// close notification in order to do cleanup
[FBSession.activeSession close];
Expand Down
Expand Up @@ -73,7 +73,9 @@
E2511740152BB6FE00CB342A /* Frameworks */,
E251173E152BB6FE00CB342A /* Products */,
);
indentWidth = 4;
sourceTree = "<group>";
tabWidth = 4;
};
E251173E152BB6FE00CB342A /* Products */ = {
isa = PBXGroup;
Expand Down
Expand Up @@ -76,7 +76,9 @@
5F6AF18C1532A37B00DDBD75 /* Frameworks */,
5F6AF18A1532A37B00DDBD75 /* Products */,
);
indentWidth = 4;
sourceTree = "<group>";
tabWidth = 4;
};
5F6AF18A1532A37B00DDBD75 /* Products */ = {
isa = PBXGroup;
Expand Down
Expand Up @@ -61,6 +61,15 @@ - (void)viewDidLoad {
FBLoginView *loginview = [[FBLoginView alloc] init];

loginview.frame = CGRectOffset(loginview.frame, 5, 5);
#ifdef __IPHONE_7_0
#ifdef __IPHONE_OS_VERSION_MAX_ALLOWED
#if __IPHONE_OS_VERSION_MAX_ALLOWED >= __IPHONE_7_0
if ([self respondsToSelector:@selector(setEdgesForExtendedLayout:)]) {
loginview.frame = CGRectOffset(loginview.frame, 5, 25);
}
#endif
#endif
#endif
loginview.delegate = self;

[self.view addSubview:loginview];
Expand Down

0 comments on commit 41f9a18

Please sign in to comment.