Skip to content

Commit

Permalink
Merge pull request #6573 from Bnyro/master
Browse files Browse the repository at this point in the history
fix: video fails to play when shared to app with zero navbar tabs
  • Loading branch information
Bnyro authored Oct 2, 2024
2 parents 208a277 + 5e2bc2f commit b5cf18f
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ import androidx.core.net.toUri
import androidx.core.os.bundleOf
import androidx.core.view.allViews
import androidx.core.view.children
import androidx.core.view.isNotEmpty
import androidx.core.view.isVisible
import androidx.core.widget.NestedScrollView
import androidx.lifecycle.lifecycleScope
Expand Down Expand Up @@ -528,7 +529,7 @@ class MainActivity : BaseActivity() {

intent.getStringExtra(IntentData.videoId)?.let {
// the below explained work around only seems to work on Android 11 and above
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.R) {
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.R && binding.bottomNav.menu.isNotEmpty()) {
// the bottom navigation bar has to be created before opening the video
// otherwise the player layout measures aren't calculated properly
// and the miniplayer is opened at a closed state and overlapping the navigation bar
Expand Down

0 comments on commit b5cf18f

Please sign in to comment.