diff options
author | Tor Norbye <tnorbye@google.com> | 2012-11-29 16:18:19 -0800 |
---|---|---|
committer | Tor Norbye <tnorbye@google.com> | 2012-11-29 16:20:40 -0800 |
commit | 4c2c7f656cc57c1f12d0efa1a753ab372b6b69de (patch) | |
tree | 7bdd01af267305330f3d0d3033699c149cfefee4 /templates/activities | |
parent | e36c788c93fc115415241e31d0d4ea2107aef19b (diff) | |
download | sdk-4c2c7f656cc57c1f12d0efa1a753ab372b6b69de.zip sdk-4c2c7f656cc57c1f12d0efa1a753ab372b6b69de.tar.gz sdk-4c2c7f656cc57c1f12d0efa1a753ab372b6b69de.tar.bz2 |
Make inefficient weight detector identify more candidates
The inefficient weight detector looks for horizontal layouts with
weights where all the children are layouts. It didn't have a very good
heuristic for finding out whether all children are layouts; it just
looked for whether the tag name contains "Layout".
This changeset generalizes this a bit, adding other layouts, as well
as <fragment> tags to the lint check.
It also updates the Master/Detail template to set the baseline
alignment attribute to false (to avoid triggering the updated lint
check), as well as android:textIsSelectable to clear another recent
new lint rule.
Change-Id: I887962b5e29a9ad0c5b5c01970b0c66f884125d8
Diffstat (limited to 'templates/activities')
-rw-r--r-- | templates/activities/MasterDetailFlow/root/res/layout/activity_content_twopane.xml.ftl | 1 | ||||
-rw-r--r-- | templates/activities/MasterDetailFlow/root/res/layout/fragment_content_detail.xml.ftl | 1 |
2 files changed, 2 insertions, 0 deletions
diff --git a/templates/activities/MasterDetailFlow/root/res/layout/activity_content_twopane.xml.ftl b/templates/activities/MasterDetailFlow/root/res/layout/activity_content_twopane.xml.ftl index cc14028..575e9e6 100644 --- a/templates/activities/MasterDetailFlow/root/res/layout/activity_content_twopane.xml.ftl +++ b/templates/activities/MasterDetailFlow/root/res/layout/activity_content_twopane.xml.ftl @@ -4,6 +4,7 @@ android:layout_height="match_parent" android:layout_marginLeft="16dp" android:layout_marginRight="16dp" + android:baselineAligned="false" android:divider="?android:attr/dividerHorizontal" android:orientation="horizontal" android:showDividers="middle" diff --git a/templates/activities/MasterDetailFlow/root/res/layout/fragment_content_detail.xml.ftl b/templates/activities/MasterDetailFlow/root/res/layout/fragment_content_detail.xml.ftl index d27e1ed..808fc31 100644 --- a/templates/activities/MasterDetailFlow/root/res/layout/fragment_content_detail.xml.ftl +++ b/templates/activities/MasterDetailFlow/root/res/layout/fragment_content_detail.xml.ftl @@ -5,4 +5,5 @@ android:layout_width="match_parent" android:layout_height="match_parent" android:padding="16dp" + android:textIsSelectable="true" tools:context=".${DetailName}Fragment" /> |