mirror of
https://github.com/nextcloud/talk-android
synced 2025-07-20 19:25:01 +01:00
make tabbar full width
improve design hide "Other" tab Signed-off-by: Marcel Hibbe <dev@mhibbe.de>
This commit is contained in:
parent
8c20180545
commit
a91ff9e920
@ -130,10 +130,10 @@ class SharedItemsActivity : AppCompatActivity() {
|
|||||||
// tabDeckCard.text = "deckcard"
|
// tabDeckCard.text = "deckcard"
|
||||||
// binding.sharedItemsTabs.addTab(tabDeckCard)
|
// binding.sharedItemsTabs.addTab(tabDeckCard)
|
||||||
|
|
||||||
val tabOther: TabLayout.Tab = binding.sharedItemsTabs.newTab()
|
// val tabOther: TabLayout.Tab = binding.sharedItemsTabs.newTab()
|
||||||
tabOther.tag = TAB_OTHER
|
// tabOther.tag = TAB_OTHER
|
||||||
tabOther.setText(R.string.shared_items_other)
|
// tabOther.setText(R.string.shared_items_other)
|
||||||
binding.sharedItemsTabs.addTab(tabOther)
|
// binding.sharedItemsTabs.addTab(tabOther)
|
||||||
|
|
||||||
binding.sharedItemsTabs.addOnTabSelectedListener(object : TabLayout.OnTabSelectedListener {
|
binding.sharedItemsTabs.addOnTabSelectedListener(object : TabLayout.OnTabSelectedListener {
|
||||||
override fun onTabSelected(tab: TabLayout.Tab) {
|
override fun onTabSelected(tab: TabLayout.Tab) {
|
||||||
|
@ -42,15 +42,13 @@
|
|||||||
|
|
||||||
<com.google.android.material.tabs.TabLayout
|
<com.google.android.material.tabs.TabLayout
|
||||||
android:id="@+id/shared_items_tabs"
|
android:id="@+id/shared_items_tabs"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="@dimen/min_size_clickable_area"
|
android:layout_height="@dimen/min_size_clickable_area"
|
||||||
android:layout_marginBottom="8dp"
|
|
||||||
android:background="@color/appbar"
|
android:background="@color/appbar"
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintTop_toBottomOf="@id/shared_items_toolbar"
|
app:layout_constraintTop_toBottomOf="@id/shared_items_toolbar"
|
||||||
app:tabGravity="fill"
|
app:tabGravity="fill"
|
||||||
app:tabMode="scrollable"
|
app:tabMode="fixed"
|
||||||
|
app:tabMaxWidth="0dp"
|
||||||
app:tabTextAppearance="@style/TextAppearanceTab" />
|
app:tabTextAppearance="@style/TextAppearanceTab" />
|
||||||
|
|
||||||
|
|
||||||
@ -61,6 +59,7 @@
|
|||||||
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager"
|
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager"
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
app:layout_constraintTop_toBottomOf="@+id/shared_items_tabs"
|
app:layout_constraintTop_toBottomOf="@+id/shared_items_tabs"
|
||||||
|
android:layout_marginTop="@dimen/double_margin_between_elements"
|
||||||
tools:listitem="@layout/attachment_item" />
|
tools:listitem="@layout/attachment_item" />
|
||||||
|
|
||||||
|
|
||||||
|
@ -24,7 +24,6 @@
|
|||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_marginStart="@dimen/standard_margin"
|
android:layout_marginStart="@dimen/standard_margin"
|
||||||
android:layout_marginTop="@dimen/standard_half_margin"
|
|
||||||
android:layout_marginEnd="@dimen/standard_margin"
|
android:layout_marginEnd="@dimen/standard_margin"
|
||||||
android:layout_marginBottom="@dimen/standard_half_margin"
|
android:layout_marginBottom="@dimen/standard_half_margin"
|
||||||
android:orientation="vertical">
|
android:orientation="vertical">
|
||||||
|
Loading…
Reference in New Issue
Block a user