mirror of
https://github.com/nextcloud/talk-android
synced 2025-06-23 21:50:31 +01:00
Lots of progress on fixing search bar
Signed-off-by: Mario Danic <mario@lovelyhq.com>
This commit is contained in:
parent
ebec4c547e
commit
0232cb4af1
21
app/src/main/res/color/outlined_icon_tint.xml
Normal file
21
app/src/main/res/color/outlined_icon_tint.xml
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<!--
|
||||||
|
Copyright (C) 2019 The Android Open Source Project
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
-->
|
||||||
|
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||||
|
<item android:color="?attr/colorPrimary" android:state_activated="true"/>
|
||||||
|
<item android:alpha="0.38" android:color="?attr/colorOnSurface" android:state_enabled="false"/>
|
||||||
|
<item android:alpha="0.6" android:color="?attr/colorOnSurface"/>
|
||||||
|
</selector>
|
@ -30,7 +30,7 @@
|
|||||||
<com.google.android.material.appbar.AppBarLayout
|
<com.google.android.material.appbar.AppBarLayout
|
||||||
android:id="@+id/appBar"
|
android:id="@+id/appBar"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="56dp"
|
android:layout_height="wrap_content"
|
||||||
android:background="@color/transparent"
|
android:background="@color/transparent"
|
||||||
android:elevation="0dp"
|
android:elevation="0dp"
|
||||||
android:windowContentOverlay="@null"
|
android:windowContentOverlay="@null"
|
||||||
|
@ -24,22 +24,20 @@
|
|||||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||||
xmlns:tools="http://schemas.android.com/tools"
|
xmlns:tools="http://schemas.android.com/tools"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="wrap_content"
|
||||||
android:clipChildren="false"
|
android:clipChildren="false"
|
||||||
android:clipToPadding="false">
|
android:clipToPadding="false">
|
||||||
|
|
||||||
<com.google.android.material.card.MaterialCardView
|
<androidx.cardview.widget.CardView
|
||||||
android:id="@+id/searchCardView"
|
android:id="@+id/searchCardView"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="64dp"
|
||||||
android:layout_marginHorizontal="12dp"
|
android:layout_marginHorizontal="12dp"
|
||||||
android:background="@color/transparent"
|
android:background="@color/transparent"
|
||||||
android:elevation="2dp"
|
app:cardCornerRadius="8dp"
|
||||||
android:visibility="gone"
|
android:clipChildren="true"
|
||||||
app:cardBackgroundColor="@color/transparent"
|
android:clipToPadding="false"
|
||||||
app:cardElevation="2dp"
|
app:cardUseCompatPadding="true">
|
||||||
app:contentPaddingLeft="16dp"
|
|
||||||
app:contentPaddingRight="16dp">
|
|
||||||
|
|
||||||
<RelativeLayout
|
<RelativeLayout
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
@ -48,93 +46,109 @@
|
|||||||
<FrameLayout
|
<FrameLayout
|
||||||
android:id="@+id/leftContainer"
|
android:id="@+id/leftContainer"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="match_parent"
|
||||||
android:layout_alignParentStart="true"
|
android:layout_alignParentStart="true"
|
||||||
|
android:minWidth="48dp"
|
||||||
android:layout_centerVertical="true">
|
android:layout_centerVertical="true">
|
||||||
|
|
||||||
<ImageButton
|
<ImageButton
|
||||||
android:id="@+id/leftButton"
|
android:id="@+id/leftButton"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="36dp"
|
||||||
android:layout_height="32dp"
|
android:layout_height="36dp"
|
||||||
|
android:padding="3dp"
|
||||||
android:layout_gravity="center"
|
android:layout_gravity="center"
|
||||||
android:background="?attr/selectableItemBackgroundBorderless"
|
android:background="?attr/selectableItemBackgroundBorderless"
|
||||||
android:scaleType="fitCenter"
|
android:scaleType="fitCenter"
|
||||||
android:src="@drawable/ic_arrow_back_black_24dp"
|
android:src="@drawable/ic_arrow_back_black_24dp"
|
||||||
android:tint="@color/fg_default"
|
android:tint="@color/outlined_icon_tint"
|
||||||
android:visibility="visible"
|
android:visibility="gone"
|
||||||
tools:src="@drawable/ic_arrow_back_black_24dp" />
|
tools:src="@drawable/ic_arrow_back_black_24dp"/>
|
||||||
|
|
||||||
</FrameLayout>
|
</FrameLayout>
|
||||||
|
|
||||||
<EditText
|
<com.google.android.material.textfield.TextInputLayout
|
||||||
android:id="@+id/inputEditText"
|
android:id="@+id/searchTextInputLayout"
|
||||||
|
style="@style/Base.Widget.MaterialComponents.TextInputLayout"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="match_parent"
|
||||||
android:layout_alignWithParentIfMissing="true"
|
|
||||||
android:layout_centerVertical="true"
|
android:layout_centerVertical="true"
|
||||||
android:layout_marginStart="16dp"
|
|
||||||
android:layout_marginEnd="16dp"
|
|
||||||
android:layout_toStartOf="@id/rightContainer"
|
|
||||||
android:layout_toEndOf="@id/leftContainer"
|
android:layout_toEndOf="@id/leftContainer"
|
||||||
android:background="@null"
|
android:layout_toStartOf="@id/rightContainer"
|
||||||
android:focusedByDefault="false"
|
android:focusedByDefault="false"
|
||||||
android:imeOptions="actionSearch|flagNoExtractUi"
|
android:imeOptions="actionSearch|flagNoExtractUi"
|
||||||
android:inputType="textNoSuggestions"
|
android:inputType="textNoSuggestions"
|
||||||
|
android:textColor="@color/conversation_item_header"
|
||||||
|
android:textCursorDrawable="@null"
|
||||||
|
app:boxBackgroundMode="none"
|
||||||
|
app:boxStrokeColor="@color/transparent"
|
||||||
|
app:errorEnabled="true"
|
||||||
|
app:helperTextEnabled="false"
|
||||||
|
app:hintEnabled="false"
|
||||||
|
tools:ignore="UnusedAttribute">
|
||||||
|
|
||||||
|
<com.google.android.material.textfield.TextInputEditText
|
||||||
|
android:id="@+id/inputEditText"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:layout_gravity="center_vertical"
|
||||||
android:lines="1"
|
android:lines="1"
|
||||||
android:maxLines="1"
|
android:maxLines="1"
|
||||||
android:singleLine="true"
|
android:singleLine="true"
|
||||||
android:textColor="@color/conversation_item_header"
|
android:background="@android:color/transparent"
|
||||||
android:textCursorDrawable="@null"
|
android:focusedByDefault="false"
|
||||||
android:textSize="16sp"
|
android:textSize="16sp" />
|
||||||
tools:hint="Search"
|
</com.google.android.material.textfield.TextInputLayout>
|
||||||
tools:ignore="UnusedAttribute" />
|
|
||||||
|
|
||||||
|
|
||||||
<FrameLayout
|
<FrameLayout
|
||||||
android:id="@+id/rightContainer"
|
android:id="@+id/rightContainer"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="match_parent"
|
||||||
android:layout_alignParentEnd="true"
|
android:layout_alignParentEnd="true"
|
||||||
|
android:minWidth="48dp"
|
||||||
android:layout_centerVertical="true">
|
android:layout_centerVertical="true">
|
||||||
|
|
||||||
<ImageView
|
<ImageButton
|
||||||
android:id="@+id/clearButton"
|
android:id="@+id/clearButton"
|
||||||
android:layout_width="32dp"
|
android:layout_width="36dp"
|
||||||
android:layout_height="32dp"
|
android:layout_height="36dp"
|
||||||
|
android:padding="3dp"
|
||||||
android:layout_gravity="center"
|
android:layout_gravity="center"
|
||||||
android:background="?attr/selectableItemBackgroundBorderless"
|
android:background="?attr/selectableItemBackgroundBorderless"
|
||||||
android:scaleType="fitCenter"
|
android:scaleType="fitCenter"
|
||||||
android:src="@drawable/ic_baseline_clear_24"
|
android:src="@drawable/ic_cancel_black_24dp"
|
||||||
android:tint="@color/fg_default"
|
android:tint="@color/outlined_icon_tint"
|
||||||
android:transitionName="userAvatar.transitionTag"
|
android:transitionName="userAvatar.transitionTag"
|
||||||
android:visibility="gone"
|
android:visibility="gone"
|
||||||
tools:src="@tools:sample/avatars[0]" />
|
tools:src="@tools:sample/avatars[0]" />
|
||||||
|
|
||||||
<ImageView
|
<ImageButton
|
||||||
android:id="@+id/settingsButton"
|
android:id="@+id/settingsButton"
|
||||||
android:layout_width="32dp"
|
android:layout_width="36dp"
|
||||||
android:layout_height="32dp"
|
android:layout_height="36dp"
|
||||||
|
android:padding="3dp"
|
||||||
android:layout_gravity="center"
|
android:layout_gravity="center"
|
||||||
android:background="?attr/selectableItemBackgroundBorderless"
|
android:background="?attr/selectableItemBackgroundBorderless"
|
||||||
android:scaleType="fitCenter"
|
android:scaleType="fitCenter"
|
||||||
android:src="@drawable/ic_settings_white_24dp"
|
android:src="@drawable/ic_settings_white_24dp"
|
||||||
android:tint="@color/fg_default"
|
android:tint="@color/outlined_icon_tint"
|
||||||
android:transitionName="userAvatar.transitionTag"
|
android:transitionName="userAvatar.transitionTag"
|
||||||
android:visibility="gone"
|
android:visibility="gone"
|
||||||
tools:src="@tools:sample/avatars[0]" />
|
tools:src="@tools:sample/avatars[0]" />
|
||||||
|
|
||||||
<ProgressBar
|
<ProgressBar
|
||||||
android:id="@+id/searchProgressBar"
|
android:id="@+id/searchProgressBar"
|
||||||
android:layout_width="32dp"
|
android:layout_width="36dp"
|
||||||
android:layout_height="32dp"
|
android:layout_height="36dp"
|
||||||
|
android:padding="3dp"
|
||||||
android:layout_gravity="center"
|
android:layout_gravity="center"
|
||||||
android:indeterminate="true"
|
android:indeterminate="true"
|
||||||
android:visibility="gone"
|
|
||||||
android:indeterminateTint="@color/colorPrimary"
|
android:indeterminateTint="@color/colorPrimary"
|
||||||
android:scaleType="fitCenter" />
|
android:scaleType="fitCenter"
|
||||||
|
android:visibility="gone" />
|
||||||
|
|
||||||
</FrameLayout>
|
</FrameLayout>
|
||||||
</RelativeLayout>
|
</RelativeLayout>
|
||||||
|
|
||||||
</com.google.android.material.card.MaterialCardView>
|
</androidx.cardview.widget.CardView>
|
||||||
</merge>
|
</merge>
|
Loading…
Reference in New Issue
Block a user