Cooltey has uploaded a new change for review. (
https://gerrit.wikimedia.org/r/389551 )
Change subject: Follow-up patch for ConstraintLayout
......................................................................
Follow-up patch for ConstraintLayout
Put heights of header, large header and footer to dimen.xml for easier
management.
Change-Id: Ic34282292188873c3b1e888537debcc6fc83cee3
---
M app/src/main/res/layout/view_card_action_footer.xml
M app/src/main/res/layout/view_card_featured_article.xml
M app/src/main/res/layout/view_card_featured_image.xml
M app/src/main/res/layout/view_card_header.xml
M app/src/main/res/layout/view_card_header_large.xml
M app/src/main/res/layout/view_card_offline_compilation.xml
M app/src/main/res/layout/view_card_on_this_day.xml
M app/src/main/res/layout/view_list_card.xml
M app/src/main/res/values/dimens.xml
9 files changed, 12 insertions(+), 11 deletions(-)
git pull ssh://gerrit.wikimedia.org:29418/apps/android/wikipedia
refs/changes/51/389551/1
diff --git a/app/src/main/res/layout/view_card_action_footer.xml
b/app/src/main/res/layout/view_card_action_footer.xml
index 90cd0d9..76efc0d 100644
--- a/app/src/main/res/layout/view_card_action_footer.xml
+++ b/app/src/main/res/layout/view_card_action_footer.xml
@@ -4,7 +4,7 @@
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
tools:layout_width="match_parent"
- tools:layout_height="48dp"
+ tools:layout_height="@dimen/view_card_footer_height"
tools:parentTag="android.support.constraint.ConstraintLayout">
<LinearLayout
diff --git a/app/src/main/res/layout/view_card_featured_article.xml
b/app/src/main/res/layout/view_card_featured_article.xml
index 2f049d3..b8c3fb0 100644
--- a/app/src/main/res/layout/view_card_featured_article.xml
+++ b/app/src/main/res/layout/view_card_featured_article.xml
@@ -9,7 +9,7 @@
<org.wikipedia.feed.view.CardHeaderView
android:id="@+id/view_featured_article_card_header"
android:layout_width="match_parent"
- android:layout_height="48dp" />
+ android:layout_height="@dimen/view_card_header_height" />
<org.wikipedia.views.FaceAndColorDetectImageView
style="@style/SimpleDraweeViewPlaceholder"
@@ -85,7 +85,7 @@
<org.wikipedia.feed.view.ActionFooterView
android:id="@+id/view_featured_article_card_footer"
android:layout_width="match_parent"
- android:layout_height="48dp"
+ android:layout_height="@dimen/view_card_footer_height"
app:layout_constraintTop_toBottomOf="@id/view_featured_article_card_text_container"/>
</android.support.constraint.ConstraintLayout>
\ No newline at end of file
diff --git a/app/src/main/res/layout/view_card_featured_image.xml
b/app/src/main/res/layout/view_card_featured_image.xml
index ddbfbe6..34791dc 100644
--- a/app/src/main/res/layout/view_card_featured_image.xml
+++ b/app/src/main/res/layout/view_card_featured_image.xml
@@ -9,7 +9,7 @@
<org.wikipedia.feed.view.CardHeaderView
android:id="@+id/view_featured_image_card_header"
android:layout_width="match_parent"
- android:layout_height="48dp"/>
+ android:layout_height="@dimen/view_card_header_height"/>
<FrameLayout
android:layout_width="match_parent"
@@ -43,6 +43,6 @@
<org.wikipedia.feed.view.ActionFooterView
android:id="@+id/view_featured_image_card_footer"
android:layout_width="match_parent"
- android:layout_height="48dp"/>
+ android:layout_height="@dimen/view_card_footer_height"/>
</LinearLayout>
\ No newline at end of file
diff --git a/app/src/main/res/layout/view_card_header.xml
b/app/src/main/res/layout/view_card_header.xml
index caa7757..fcddbab 100644
--- a/app/src/main/res/layout/view_card_header.xml
+++ b/app/src/main/res/layout/view_card_header.xml
@@ -3,7 +3,7 @@
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
tools:layout_width="match_parent"
- tools:layout_height="48dp"
+ tools:layout_height="@dimen/view_card_header_height"
tools:parentTag="android.support.constraint.ConstraintLayout">
<android.support.v7.widget.AppCompatImageView
diff --git a/app/src/main/res/layout/view_card_header_large.xml
b/app/src/main/res/layout/view_card_header_large.xml
index c967b19..1c61bc1 100644
--- a/app/src/main/res/layout/view_card_header_large.xml
+++ b/app/src/main/res/layout/view_card_header_large.xml
@@ -3,7 +3,7 @@
xmlns:tools="http://schemas.android.com/tools"
xmlns:app="http://schemas.android.com/apk/res-auto"
tools:layout_width="match_parent"
- tools:layout_height="96dp"
+ tools:layout_height="@dimen/view_card_header_large_height"
tools:parentTag="android.support.constraint.ConstraintLayout">
<View
diff --git a/app/src/main/res/layout/view_card_offline_compilation.xml
b/app/src/main/res/layout/view_card_offline_compilation.xml
index 5af8af0..0f55e7c 100644
--- a/app/src/main/res/layout/view_card_offline_compilation.xml
+++ b/app/src/main/res/layout/view_card_offline_compilation.xml
@@ -1,7 +1,6 @@
<LinearLayout
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
- xmlns:tools="http://schemas.android.com/tools"
android:id="@+id/offline_container"
android:layout_width="match_parent"
android:layout_height="wrap_content"
diff --git a/app/src/main/res/layout/view_card_on_this_day.xml
b/app/src/main/res/layout/view_card_on_this_day.xml
index e88c6e3..51b5dd6 100644
--- a/app/src/main/res/layout/view_card_on_this_day.xml
+++ b/app/src/main/res/layout/view_card_on_this_day.xml
@@ -1,7 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
- xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:clipChildren="false"
diff --git a/app/src/main/res/layout/view_list_card.xml
b/app/src/main/res/layout/view_list_card.xml
index 0d292f6..b1717df 100644
--- a/app/src/main/res/layout/view_list_card.xml
+++ b/app/src/main/res/layout/view_list_card.xml
@@ -8,12 +8,12 @@
<org.wikipedia.feed.view.CardHeaderView
android:id="@+id/view_list_card_header"
android:layout_width="match_parent"
- android:layout_height="48dp"/>
+ android:layout_height="@dimen/view_card_header_height"/>
<org.wikipedia.feed.view.CardLargeHeaderView
android:id="@+id/view_list_card_large_header"
android:layout_width="match_parent"
- android:layout_height="96dp"
+ android:layout_height="@dimen/view_card_header_large_height"
app:layout_constraintTop_toBottomOf="@id/view_list_card_header"
android:visibility="gone" />
diff --git a/app/src/main/res/values/dimens.xml
b/app/src/main/res/values/dimens.xml
index d6d5d02..e9641fb 100644
--- a/app/src/main/res/values/dimens.xml
+++ b/app/src/main/res/values/dimens.xml
@@ -105,6 +105,9 @@
<dimen name="view_list_card_margin_horizontal">8dp</dimen>
<dimen
name="view_horizontal_scrolling_list_card_item_margin_horizontal">4dp</dimen>
<dimen
name="view_horizontal_scrolling_list_card_item_margin_vertical">0dp</dimen>
+ <dimen name="view_card_header_height">48dp</dimen>
+ <dimen name="view_card_header_large_height">96dp</dimen>
+ <dimen name="view_card_footer_height">48dp</dimen>
<dimen name="view_list_card_item_image">40dp</dimen>
<dimen name="overflow_elevation">16dp</dimen>
<integer name="article_engagement_threshold_sec">30</integer>
--
To view, visit https://gerrit.wikimedia.org/r/389551
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: Ic34282292188873c3b1e888537debcc6fc83cee3
Gerrit-PatchSet: 1
Gerrit-Project: apps/android/wikipedia
Gerrit-Branch: master
Gerrit-Owner: Cooltey <[email protected]>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits