From 01985d888776fbfaeb8c7d39be58e384e7a4949f Mon Sep 17 00:00:00 2001 From: Moez Bhatti Date: Mon, 12 Mar 2018 19:41:23 -0700 Subject: [PATCH] Convert ComposeActivity to ConstraintLayout --- .../feature/compose/ComposeActivity.kt | 4 +- .../src/main/res/layout/compose_activity.xml | 294 ++++++++++-------- qksms/src/main/res/layout/toolbar_chips.xml | 48 --- 3 files changed, 172 insertions(+), 174 deletions(-) delete mode 100644 qksms/src/main/res/layout/toolbar_chips.xml diff --git a/qksms/src/main/java/presentation/feature/compose/ComposeActivity.kt b/qksms/src/main/java/presentation/feature/compose/ComposeActivity.kt index 96cb92a8..b30e0b85 100644 --- a/qksms/src/main/java/presentation/feature/compose/ComposeActivity.kt +++ b/qksms/src/main/java/presentation/feature/compose/ComposeActivity.kt @@ -46,11 +46,9 @@ import io.reactivex.rxkotlin.Observables import io.reactivex.subjects.PublishSubject import io.reactivex.subjects.Subject import kotlinx.android.synthetic.main.compose_activity.* -import kotlinx.android.synthetic.main.toolbar_chips.* import presentation.common.base.QkThemedActivity import javax.inject.Inject - class ComposeActivity : QkThemedActivity(), ComposeView { override val viewModelClass = ComposeViewModel::class @@ -168,7 +166,7 @@ class ComposeActivity : QkThemedActivity(), ComposeView { .subscribe { color -> contacts.setBackgroundColor(color) } colors.composeBackground - .doOnNext { color -> composeBar.setBackgroundTint(color) } + .doOnNext { color -> composeBackground.setBackgroundTint(color) } .doOnNext { color -> window.decorView.setBackgroundColor(color) } .autoDisposable(scope()) .subscribe() diff --git a/qksms/src/main/res/layout/compose_activity.xml b/qksms/src/main/res/layout/compose_activity.xml index b53264bd..6fc8f19a 100644 --- a/qksms/src/main/res/layout/compose_activity.xml +++ b/qksms/src/main/res/layout/compose_activity.xml @@ -16,156 +16,204 @@ ~ You should have received a copy of the GNU General Public License ~ along with QKSMS. If not, see . --> - - + - - - + android:background="@null" + android:gravity="start|center_vertical" + android:maxLines="1" + android:singleLine="true" + android:textSize="20sp" + app:textColor="primary" + tools:text="Conversations" /> - - - - + android:layout_marginBottom="4dp" + android:layout_marginTop="4dp" + tools:visibility="gone" /> - + - + - + - + - + - + - + - + - + - + - + - + - - - - - + - \ No newline at end of file + + + \ No newline at end of file diff --git a/qksms/src/main/res/layout/toolbar_chips.xml b/qksms/src/main/res/layout/toolbar_chips.xml deleted file mode 100644 index 9dd2a3c0..00000000 --- a/qksms/src/main/res/layout/toolbar_chips.xml +++ /dev/null @@ -1,48 +0,0 @@ - - - - - - - - - \ No newline at end of file