Permalink
Browse files

Removing old sample DemoApp.

  • Loading branch information...
1 parent e0e813b commit 60367ef741ae5063570f793520d9c7559a55fbcc Christine Abernathy committed Oct 13, 2011
@@ -1,29 +0,0 @@
-/*
- * Copyright 2010 Facebook
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * 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.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-
-#import <UIKit/UIKit.h>
-#import "DemoAppViewController.h"
-
-@interface DemoAppAppDelegate : NSObject <UIApplicationDelegate> {
- UIWindow *window;
- DemoAppViewController* controller;
-}
-
-@property (nonatomic, retain) IBOutlet UIWindow *window;
-
-@end
-
@@ -1,48 +0,0 @@
-/*
- * Copyright 2010 Facebook
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * 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.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-
-#import "DemoAppAppDelegate.h"
-#import "DemoAppViewController.h"
-
-@implementation DemoAppAppDelegate
-
-@synthesize window;
-
-
-- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {
- // Override point for customization after application launch
- controller = [[DemoAppViewController alloc] init];
- controller.view.frame = CGRectMake(0, 20, 320, 460);
- [window addSubview:controller.view];
-
- [window makeKeyAndVisible];
- return YES;
-
-}
-
-- (BOOL)application:(UIApplication *)application handleOpenURL:(NSURL *)url {
- return [[controller facebook] handleOpenURL:url];
-}
-
-- (void)dealloc {
- [window release];
- [controller release];
- [super dealloc];
-}
-
-
-@end
@@ -1,51 +0,0 @@
-/*
- * Copyright 2010 Facebook
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * 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.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-
-#import <UIKit/UIKit.h>
-#import "FBConnect.h"
-#import "FBLoginButton.h"
-
-
-@interface DemoAppViewController : UIViewController
-<FBRequestDelegate,
-FBDialogDelegate,
-FBSessionDelegate>{
- IBOutlet UILabel* _label;
- IBOutlet FBLoginButton* _fbButton;
- IBOutlet UIButton* _getUserInfoButton;
- IBOutlet UIButton* _getPublicInfoButton;
- IBOutlet UIButton* _publishButton;
- IBOutlet UIButton* _uploadPhotoButton;
- Facebook* _facebook;
- NSArray* _permissions;
-}
-
-@property(nonatomic, retain) UILabel* label;
-
-@property(readonly) Facebook *facebook;
-
--(IBAction)fbButtonClick:(id)sender;
-
--(IBAction)getUserInfo:(id)sender;
-
--(IBAction)getPublicInfo:(id)sender;
-
--(IBAction)publishStream:(id)sender;
-
--(IBAction)uploadPhoto:(id)sender;
-
-@end
Oops, something went wrong.

6 comments on commit 60367ef

hi.

In code ,FBDialog.m

-175 _orientation = [UIApplication sharedApplication].statusBarOrientation;
-176 if (UIInterfaceOrientationIsLandscape(_orientation)) {
-177 self.frame = CGRectMake(kPadding, kPadding, height, width);
-178 } else {
-179 self.frame = CGRectMake(kPadding, kPadding, width, height);
-180 }

the line175 warining ,Implicit conversion from enumeration type 'UIInterfaceOrientation' to different enumeration type 'UIDeviceOrientation'

_orientation = [[UIDevice currentDevice] orientation]; - this with out warning
And will Facebook implicit ARC?

No.

the section, i changed to the _orientation = (UIDeviceOrientation)[[UIDevice currentDevice] orientation];

I have the code, all to the ARC model used below.

also ,in here FBRequest.h.h

that's why
-54 @property(nonatomic,assign) NSURLConnection* connection;
-55 @property(nonatomic,assign) NSMutableData* responseText;

use assign , use retain or strong is better?

if you want to support iOS 4 then unsafe_unretained if not then use weak against assign (using ARC). You could see this in wwdc 2011 video (323).

thank you very much.

and i have a new issue,

In current sdk , facebook.m

-31 static NSString* kSDKVersion = @"2";

but in the old sdk,

In here , is same , kSDKVersion = @"2";

You konw , my app is ok in iso4 and old facebook app, but the own app in a new facebook app ,have a issue (if I can't install a new facebook app , that's ok in safari ), it's can't login it , so i must update it in the new SDK.

Thank you @marko1503 ..

:p

I needed to strengthen my English proficiency

Please sign in to comment.