mirror of
https://github.com/SimpleMobileTools/Simple-Gallery.git
synced 2025-02-17 12:30:36 +01:00
make bottom actions work well with extended details
This commit is contained in:
parent
3559147c98
commit
02ce6bd11b
@ -431,6 +431,7 @@ class PhotoFragment : ViewPagerFragment() {
|
||||
private fun getExtendedDetailsY(height: Int): Float {
|
||||
val smallMargin = resources.getDimension(R.dimen.small_margin)
|
||||
val fullscreenOffset = context!!.navigationBarHeight.toFloat() - smallMargin
|
||||
return context!!.usableScreenSize.y - height + if (isFullscreen) fullscreenOffset else -smallMargin
|
||||
val actionsHeight = if (context!!.config.bottomActions && !isFullscreen) resources.getDimension(R.dimen.bottom_actions_height) else 0f
|
||||
return context!!.usableScreenSize.y - height - actionsHeight + if (isFullscreen) fullscreenOffset else -smallMargin
|
||||
}
|
||||
}
|
||||
|
@ -199,6 +199,10 @@ class VideoFragment : ViewPagerFragment(), SurfaceHolder.Callback, SeekBar.OnSee
|
||||
right += context!!.navigationBarWidth
|
||||
bottom += context!!.navigationBarHeight
|
||||
}
|
||||
|
||||
if (context!!.config.bottomActions) {
|
||||
bottom += resources.getDimension(R.dimen.bottom_actions_height).toInt()
|
||||
}
|
||||
mTimeHolder!!.setPadding(left, top, right, bottom)
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user