diff --git a/presentation/src/main/java/com/moez/QKSMS/feature/compose/ComposeActivity.kt b/presentation/src/main/java/com/moez/QKSMS/feature/compose/ComposeActivity.kt index 4badcfc1..1cfacbe8 100644 --- a/presentation/src/main/java/com/moez/QKSMS/feature/compose/ComposeActivity.kt +++ b/presentation/src/main/java/com/moez/QKSMS/feature/compose/ComposeActivity.kt @@ -130,8 +130,8 @@ class ComposeActivity : QkThemedActivity(), ComposeView { theme .doOnNext { loading.setTint(it.theme) } - .doOnNext { send.setBackgroundTint(it.theme) } - .doOnNext { send.setTint(it.textPrimary) } + .doOnNext { attach.setBackgroundTint(it.theme) } + .doOnNext { attach.setTint(it.textPrimary) } .doOnNext { messageAdapter.theme = it } .autoDisposable(scope()) .subscribe { messageList.scrapViews() } diff --git a/presentation/src/main/java/com/moez/QKSMS/feature/qkreply/QkReplyActivity.kt b/presentation/src/main/java/com/moez/QKSMS/feature/qkreply/QkReplyActivity.kt index cfc0cc32..472da8a4 100644 --- a/presentation/src/main/java/com/moez/QKSMS/feature/qkreply/QkReplyActivity.kt +++ b/presentation/src/main/java/com/moez/QKSMS/feature/qkreply/QkReplyActivity.kt @@ -18,28 +18,25 @@ */ package com.moez.QKSMS.feature.qkreply -import androidx.lifecycle.ViewModelProvider -import androidx.lifecycle.ViewModelProviders import android.os.Build import android.os.Bundle -import androidx.recyclerview.widget.LinearLayoutManager import android.view.Menu import android.view.MenuItem import android.view.ViewGroup import android.view.Window import android.view.WindowManager +import androidx.lifecycle.ViewModelProvider +import androidx.lifecycle.ViewModelProviders +import androidx.recyclerview.widget.LinearLayoutManager import com.jakewharton.rxbinding2.view.clicks import com.jakewharton.rxbinding2.widget.textChanges import com.moez.QKSMS.R -import com.moez.QKSMS.common.androidxcompat.scope import com.moez.QKSMS.common.base.QkThemedActivity import com.moez.QKSMS.common.util.extensions.autoScrollToStart import com.moez.QKSMS.common.util.extensions.resolveThemeColor import com.moez.QKSMS.common.util.extensions.setBackgroundTint -import com.moez.QKSMS.common.util.extensions.setTint import com.moez.QKSMS.common.util.extensions.setVisible import com.moez.QKSMS.feature.compose.MessagesAdapter -import com.uber.autodispose.kotlin.autoDisposable import dagger.android.AndroidInjection import io.reactivex.subjects.PublishSubject import io.reactivex.subjects.Subject @@ -69,13 +66,6 @@ class QkReplyActivity : QkThemedActivity(), QkReplyView { window.setLayout(ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.WRAP_CONTENT) viewModel.bindView(this) - theme - .autoDisposable(scope()) - .subscribe { theme -> - send.setBackgroundTint(theme.theme) - send.setTint(theme.textPrimary) - } - toolbar.clipToOutline = true adapter.autoScrollToStart(messages) @@ -88,7 +78,7 @@ class QkReplyActivity : QkThemedActivity(), QkReplyView { toolbar.setBackgroundTint(resolveThemeColor(R.attr.colorPrimary)) background.setBackgroundTint(resolveThemeColor(R.attr.composeBackground)) composeBackground.setBackgroundTint(resolveThemeColor(R.attr.composeBackground)) - composeBackgroundGradient.setBackgroundTint(resolveThemeColor(R.attr.composeBackground)) + composeBackground2.setBackgroundTint(resolveThemeColor(R.attr.composeBackground)) } } diff --git a/presentation/src/main/res/drawable/rounded_rectangle_22dp.xml b/presentation/src/main/res/drawable/rounded_rectangle_22dp.xml new file mode 100755 index 00000000..907142b5 --- /dev/null +++ b/presentation/src/main/res/drawable/rounded_rectangle_22dp.xml @@ -0,0 +1,27 @@ + + + + + + + + + \ No newline at end of file diff --git a/presentation/src/main/res/layout/attachment_list_item.xml b/presentation/src/main/res/layout/attachment_list_item.xml index ed174a71..190c3a11 100644 --- a/presentation/src/main/res/layout/attachment_list_item.xml +++ b/presentation/src/main/res/layout/attachment_list_item.xml @@ -20,7 +20,8 @@ + android:layout_height="wrap_content" + tools:background="?attr/bubbleColor"> + android:layout_marginTop="16dp" + android:background="@drawable/rounded_rectangle_4dp"> + android:orientation="vertical" + tools:context="com.moez.QKSMS.feature.compose.ComposeActivity"> + app:constraint_referenced_ids="composeBackground, messageBackground, attachments, attach, message, counter, send" /> + + + + + + - - - - - - - - + app:layout_constraintStart_toStartOf="@id/messageBackground" /> + app:layout_constraintBottom_toBottomOf="@id/messageBackground" + app:layout_constraintEnd_toStartOf="@id/send" /> + android:tint="?android:textColorSecondary" + app:layout_constraintBottom_toBottomOf="@id/messageBackground" + app:layout_constraintEnd_toEndOf="@id/messageBackground" + tools:backgroundTint="@color/tools_theme" /> - + app:layout_constraintTop_toTopOf="@id/message" /> + app:layout_constraintBottom_toBottomOf="@id/messageBackground" + app:layout_constraintEnd_toStartOf="@id/send" /> + android:tint="?android:textColorSecondary" + app:layout_constraintBottom_toBottomOf="@id/messageBackground" + app:layout_constraintEnd_toEndOf="@id/messageBackground" + tools:backgroundTint="@color/tools_theme" />