In AndroidManifest: Expecting android:screenOrientation=“unspecified”

前端 未结 11 890
隐瞒了意图╮
隐瞒了意图╮ 2021-02-02 04:59

Android Studio 3.6.

I want my app to be always in portrait mode. So in my AndroidMainfest.xml:



        
11条回答
  •  旧时难觅i
    2021-02-02 06:00

    I found 2 way of solving this problem

    First,

    Android Studio -> Preferences (or settings in Windows)
    -> search "chrome" 
    -> Uncheck "Activity is locked to an orientation" 
    -> apply and ok 
    -> Sync Project with Gradle flie
    

    Second, `

    Select "Run" from the main menu 
    -> Edit Configurations.
    -> Launch options - Launch
    -> select Nothing or Specified Activity
    -> Sync Project with Gradle file
    

提交回复
热议问题