mirror of
https://github.com/libre-tube/LibreTube.git
synced 2025-04-29 08:20:32 +05:30
Merge pull request #5974 from Bnyro/master
fix: welcome activity does not permit auto rotation
This commit is contained in:
commit
6466e9e604
@ -1,6 +1,7 @@
|
|||||||
package com.github.libretube.ui.activities
|
package com.github.libretube.ui.activities
|
||||||
|
|
||||||
import android.content.Intent
|
import android.content.Intent
|
||||||
|
import android.content.pm.ActivityInfo
|
||||||
import android.os.Bundle
|
import android.os.Bundle
|
||||||
import android.widget.Toast
|
import android.widget.Toast
|
||||||
import androidx.activity.result.contract.ActivityResultContracts
|
import androidx.activity.result.contract.ActivityResultContracts
|
||||||
@ -80,4 +81,8 @@ class WelcomeActivity : BaseActivity() {
|
|||||||
startActivity(mainActivityIntent)
|
startActivity(mainActivityIntent)
|
||||||
finish()
|
finish()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
override fun requestOrientationChange() {
|
||||||
|
requestedOrientation = ActivityInfo.SCREEN_ORIENTATION_USER
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -59,7 +59,7 @@ open class BaseActivity : AppCompatActivity() {
|
|||||||
/**
|
/**
|
||||||
* Rotate the screen according to the app orientation preference
|
* Rotate the screen according to the app orientation preference
|
||||||
*/
|
*/
|
||||||
fun requestOrientationChange() {
|
open fun requestOrientationChange() {
|
||||||
requestedOrientation = screenOrientationPref
|
requestedOrientation = screenOrientationPref
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -70,8 +70,9 @@
|
|||||||
android:id="@+id/instances_recycler"
|
android:id="@+id/instances_recycler"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
|
android:clipToPadding="false"
|
||||||
android:fadeScrollbars="false"
|
android:fadeScrollbars="false"
|
||||||
android:paddingBottom="100dp"
|
android:paddingBottom="70dp"
|
||||||
android:scrollbars="vertical"
|
android:scrollbars="vertical"
|
||||||
app:layout_behavior="@string/appbar_scrolling_view_behavior" />
|
app:layout_behavior="@string/appbar_scrolling_view_behavior" />
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user