Skip to content

Commit d2aac47

Browse files
authored
Update orientation.py
adding mode ='user'
1 parent f9e68fa commit d2aac47

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

plyer/platforms/android/orientation.py

+2
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,8 @@ def _set_sensor(self, **kwargs):
3131
if mode == 'any':
3232
activity.setRequestedOrientation(
3333
ActivityInfo.SCREEN_ORIENTATION_SENSOR)
34+
elif:mode =='user':
35+
activity.setRequestedOrientation(ActivityInfo.SCREEN_ORIENTATION_USER)
3436
elif mode == 'landscape':
3537
activity.setRequestedOrientation(
3638
ActivityInfo.SCREEN_ORIENTATION_SENSOR_LANDSCAPE)

0 commit comments

Comments
 (0)