|
|
|
@ -104,7 +104,7 @@ class TabTrayView(
|
|
|
|
|
expand()
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
behavior.setExpandedOffset(view.context.resources.getDimension(R.dimen.tab_tray_top_offset).toInt())
|
|
|
|
|
setTopOffset(startingInLandscape)
|
|
|
|
|
|
|
|
|
|
(view.tabsTray as? BrowserTabsTray)?.also { tray ->
|
|
|
|
|
TabsTouchHelper(tray.tabsAdapter).attachToRecyclerView(tray)
|
|
|
|
@ -199,6 +199,16 @@ class TabTrayView(
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
fun setTopOffset(landscape: Boolean) {
|
|
|
|
|
val topOffset = if (landscape) {
|
|
|
|
|
0
|
|
|
|
|
} else {
|
|
|
|
|
view.context.resources.getDimension(R.dimen.tab_tray_top_offset).toInt()
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
behavior.setExpandedOffset(topOffset)
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
companion object {
|
|
|
|
|
private const val DEFAULT_TAB_ID = 0
|
|
|
|
|
private const val PRIVATE_TAB_ID = 1
|
|
|
|
|