iPad中的FBWebDialog旋转问题

时间:2013-07-04 08:11:26

标签: iphone ios ios6

当我使用以下代码打开FBWebDialog时,一旦打开FBWebDialog,单击用户名文本字段,如果您旋转iPad设备,现在会显示键盘,FBWebDialog不会自动旋转到横向。

[FBSession setActiveSession: [[FBSession alloc] initWithPermissions:permission] ];
[[FBSession activeSession] openWithBehavior:FBSessionLoginBehaviorForcingWebView completionHandler:^(FBSession *session, FBSessionState status, NSError *error) {
    switch (status) {
        case FBSessionStateOpen:
            [self getMyData];
            break;
        case FBSessionStateClosedLoginFailed: {
            NSString *errorCode = [[error userInfo] objectForKey:FBErrorLoginFailedOriginalErrorCode];
            NSString *errorReason = [[error userInfo] objectForKey:FBErrorLoginFailedReason];
            BOOL userDidCancel = !errorCode && (!errorReason || [errorReason isEqualToString:FBErrorLoginFailedReasonInlineCancelledValue]);
            if(error.code == 2 && ![errorReason isEqualToString:@"com.facebook.sdk:UserLoginCancelled"]) {
                UIAlertView *errorMessage = [[UIAlertView alloc] initWithTitle:kFBAlertTitle message:kFBAuthenticationErrorMessage delegate:nil cancelButtonTitle:kOk otherButtonTitles:nil];
                [errorMessage performSelectorOnMainThread:@selector(show) withObject:nil waitUntilDone:YES];
                errorMessage = nil;
            }

        }
        break;
    // presently extension, log-out and invalidation are being implemented in the Facebook class
    default:
        break; // so we do nothing in response to those state transitions
    }
}];

以下是重现此问题的步骤:

  1. 打开在iPad应用程序内打开的FBWebialog
  2. 点击用户名文字字段并显示键盘
  3. 现在,如果您旋转iPad设备,FBWebDialog不会自动旋转到横向。
  4. 请帮我解决这个问题......

1 个答案:

答案 0 :(得分:0)

来自facebook方面的bug,这是我的查询发布到facebook支持团队。即使没有得到Facebook的任何回应,也是荒谬的......

https://developers.facebook.com/bugs/355080977928726?browse=external_tasks_search_results_52820409e9c884976463112