Skip to content

Changing screen orientation doesn't have any effect #25

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

Closed
dluksza opened this issue Jan 12, 2020 · 3 comments
Closed

Changing screen orientation doesn't have any effect #25

dluksza opened this issue Jan 12, 2020 · 3 comments

Comments

@dluksza
Copy link

dluksza commented Jan 12, 2020

Standard way of changing flutter application orientation doesn't work on Rpi. Setting:

SystemChrome.setPreferredOrientations([
    DeviceOrientation.portraitUp,
]);

doesn't affect screen layout. I've also tried with DeviceOrientation.landscapeLeft and there is no difference.

@ardera
Copy link
Owner

ardera commented Jan 13, 2020

Yeah the SystemChrome class is basically just an interface to the platform method channel. Specifically, you're calling the SystemChrome.setPreferredOrientations method on the flutter/platform method channel, which is implemented right here.

Haven't got around to implement it yet. Should not be that hard to do though

@dluksza
Copy link
Author

dluksza commented Jan 13, 2020

Would be nice to have this implemented soonish ;)

ardera added a commit that referenced this issue Jan 14, 2020
implement SystemChrome.setPreferredOrientations
implement surface_transform callback for rotation
implements #25
@ardera ardera closed this as completed Jan 14, 2020
@dluksza
Copy link
Author

dluksza commented Jan 14, 2020

Awesome! Thank you!

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