Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

横屏状态下,开启键盘为竖屏模式。 #5

Open
CXTretar opened this issue May 8, 2018 · 2 comments
Open

横屏状态下,开启键盘为竖屏模式。 #5

CXTretar opened this issue May 8, 2018 · 2 comments

Comments

@CXTretar
Copy link

CXTretar commented May 8, 2018

No description provided.

@dito010
Copy link
Owner

dito010 commented May 8, 2018

用一个 property 来标记当前的是否在输入,然后再 -supportedInterfaceOrientations 里返回横屏,键盘就能正确弹出了。

@CXTretar
Copy link
Author

CXTretar commented May 8, 2018

- (UIInterfaceOrientationMask)supportedInterfaceOrientations {
    if (self.previewView.viewStatus == BLLandscapeViewStatusLandscape) {
        return UIInterfaceOrientationMaskLandscapeRight;
    }else {
        return UIInterfaceOrientationMaskPortrait;
    }
}

我试过这样子写,但是没有起作用。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants