Index: chrome/android/java/res/layout/infobar_subcontrol_toggle.xml |
diff --git a/chrome/android/java/res/layout/infobar_subcontrol_toggle.xml b/chrome/android/java/res/layout/infobar_subcontrol_toggle.xml |
new file mode 100644 |
index 0000000000000000000000000000000000000000..d947b88d05faf388e6716e83b21f572f21b4b164 |
--- /dev/null |
+++ b/chrome/android/java/res/layout/infobar_subcontrol_toggle.xml |
@@ -0,0 +1,43 @@ |
+<?xml version="1.0" encoding="utf-8"?> |
newt (away)
2015/11/05 05:52:15
If this is a "subcontrol" what is a "regular contr
gone
2015/11/05 20:42:03
Done.
|
+<!-- Copyright 2015 The Chromium Authors. All rights reserved. |
+ Use of this source code is governed by a BSD-style license that can be |
+ found in the LICENSE file. --> |
+ |
+<LinearLayout |
+ xmlns:android="http://schemas.android.com/apk/res/android" |
+ android:id="@+id/subcontrol_toggle" |
+ android:layout_width="match_parent" |
+ android:layout_height="36dp"> |
+ |
+ <ImageView |
+ android:id="@+id/subcontrol_toggle_icon" |
+ android:layout_width="wrap_content" |
+ android:layout_height="match_parent" |
+ android:layout_weight="0" |
newt (away)
2015/11/05 05:52:15
weight="0" is the default. I'd just leave it out,
gone
2015/11/05 20:42:03
Done.
|
+ android:layout_gravity="center_vertical|start" |
newt (away)
2015/11/05 05:52:15
"start" isn't needed here, and "end" isn't needed
gone
2015/11/05 20:42:03
Done.
|
+ android:layout_marginEnd="8dp" |
+ android:visibility="gone" |
+ android:scaleType="centerInside" |
+ android:contentDescription="@null" /> |
+ |
+ <TextView |
+ android:id="@+id/subcontrol_toggle_message" |
+ android:layout_width="0dp" |
+ android:layout_height="match_parent" |
+ android:layout_weight="1" |
+ android:layout_gravity="center_vertical" |
newt (away)
2015/11/05 05:52:15
Instead of adding layout_gravity="center_vertical"
gone
2015/11/05 20:42:03
Done.
|
+ android:gravity="center_vertical" |
+ android:lineSpacingExtra="@dimen/infobar_subcontrol_text_extra_spacing" |
newt (away)
2015/11/05 05:52:16
I'd recommend lineSpacingMultiplier instead of lin
gone
2015/11/05 20:42:03
Going with 1.4 instead of 1.428, assuming dp=sp an
|
+ android:textDirection="locale" |
newt (away)
2015/11/05 05:52:16
Use textAlignment instead of textDirection. textDi
gone
2015/11/05 20:42:02
Took it out. Was copied over from the previous ve
|
+ android:textSize="@dimen/infobar_subcontrol_text_size" |
+ android:textColor="@color/default_text_color" /> |
+ |
+ <Switch |
+ android:id="@+id/subcontrol_toggle_switch" |
+ android:layout_width="wrap_content" |
+ android:layout_height="match_parent" |
+ android:layout_weight="0" |
+ android:layout_gravity="center_vertical|end" |
+ android:layout_marginStart="16dp" /> |
+ |
+</LinearLayout> |