|
25 | 25 | android:background="@drawable/notify_panel_clock_bg" |
26 | 26 | > |
27 | 27 |
|
28 | | - <LinearLayout |
| 28 | + <TableLayout |
29 | 29 | android:id="@+id/icons" |
30 | | - android:layout_width="wrap_content" |
| 30 | + android:layout_width="match_parent" |
31 | 31 | android:layout_height="wrap_content" |
32 | 32 | android:layout_alignParentLeft="true" |
33 | 33 | android:layout_alignParentBottom="true" |
34 | | - android:baselineAlignedChildIndex="0" |
35 | 34 | android:layout_marginLeft="16dp" |
36 | 35 | android:layout_marginTop="16dp" |
37 | 36 | android:layout_marginBottom="16dp" |
| 37 | + android:shrinkColumns="2,4" |
| 38 | + android:stretchColumns="7" |
38 | 39 | > |
| 40 | + <TableRow> |
39 | 41 |
|
40 | | - <ImageView |
41 | | - android:id="@+id/bluetooth" |
42 | | - android:layout_height="wrap_content" |
43 | | - android:layout_width="wrap_content" |
44 | | - android:scaleType="centerInside" |
45 | | - android:baseline="18dp" |
46 | | - android:visibility="gone" |
47 | | - android:contentDescription="@null" |
48 | | - /> |
49 | | - |
50 | | - <FrameLayout |
51 | | - android:id="@+id/netwerk" |
52 | | - android:layout_height="wrap_content" |
53 | | - android:layout_width="wrap_content" |
54 | | - android:layout_marginRight="4dp" |
55 | | - > |
| 42 | + <!-- to keep the column ids stable we wrap disappearing views in |
| 43 | + frames --> |
| 44 | + <FrameLayout |
| 45 | + android:layout_height="wrap_content" |
| 46 | + android:layout_width="wrap_content" |
| 47 | + > |
| 48 | + <ImageView |
| 49 | + android:id="@+id/bluetooth" |
| 50 | + android:layout_height="wrap_content" |
| 51 | + android:layout_width="wrap_content" |
| 52 | + android:scaleType="centerInside" |
| 53 | + android:visibility="gone" |
| 54 | + android:contentDescription="@null" |
| 55 | + android:layout_gravity="center_vertical" |
| 56 | + /> |
| 57 | + </FrameLayout> |
56 | 58 |
|
57 | | - <ImageView |
58 | | - android:id="@+id/network_signal" |
| 59 | + <!-- mobile data --> |
| 60 | + <FrameLayout |
| 61 | + android:id="@+id/mobile_icon" |
59 | 62 | android:layout_height="wrap_content" |
60 | 63 | android:layout_width="wrap_content" |
61 | | - android:contentDescription="@null" |
| 64 | + android:paddingRight="4dp" |
| 65 | + android:layout_gravity="center_vertical" |
| 66 | + > |
| 67 | + |
| 68 | + <ImageView |
| 69 | + android:id="@+id/mobile_signal" |
| 70 | + android:layout_height="wrap_content" |
| 71 | + android:layout_width="wrap_content" |
| 72 | + android:contentDescription="@null" |
| 73 | + /> |
| 74 | + |
| 75 | + <ImageView |
| 76 | + android:id="@+id/mobile_type" |
| 77 | + android:layout_height="wrap_content" |
| 78 | + android:layout_width="wrap_content" |
| 79 | + android:contentDescription="@null" |
| 80 | + /> |
| 81 | + |
| 82 | + </FrameLayout> |
| 83 | + <TextView |
| 84 | + android:id="@+id/mobile_text" |
| 85 | + style="@style/StatusBarNotificationText" |
| 86 | + android:layout_gravity="left|center_vertical" |
| 87 | + android:layout_width="wrap_content" |
| 88 | + android:layout_height="wrap_content" |
| 89 | + android:paddingRight="8dp" |
| 90 | + android:layout_weight="1" |
| 91 | + android:singleLine="true" |
| 92 | + android:ellipsize="end" |
| 93 | + android:text="@string/status_bar_settings_settings_button" |
62 | 94 | /> |
63 | 95 |
|
64 | | - <ImageView |
65 | | - android:id="@+id/network_type" |
| 96 | + <!-- wifi --> |
| 97 | + <FrameLayout |
| 98 | + android:id="@+id/wifi_icon" |
66 | 99 | android:layout_height="wrap_content" |
67 | 100 | android:layout_width="wrap_content" |
68 | | - android:contentDescription="@null" |
| 101 | + android:paddingRight="4dp" |
| 102 | + android:layout_gravity="center_vertical" |
| 103 | + > |
| 104 | + |
| 105 | + <ImageView |
| 106 | + android:id="@+id/wifi_signal" |
| 107 | + android:layout_height="wrap_content" |
| 108 | + android:layout_width="wrap_content" |
| 109 | + android:contentDescription="@null" |
| 110 | + /> |
| 111 | + |
| 112 | + <ImageView |
| 113 | + android:id="@+id/wifi_direction" |
| 114 | + android:layout_height="wrap_content" |
| 115 | + android:layout_width="wrap_content" |
| 116 | + android:contentDescription="@null" |
| 117 | + /> |
| 118 | + |
| 119 | + </FrameLayout> |
| 120 | + <TextView |
| 121 | + android:id="@+id/wifi_text" |
| 122 | + style="@style/StatusBarNotificationText" |
| 123 | + android:layout_gravity="left|center_vertical" |
| 124 | + android:layout_width="wrap_content" |
| 125 | + android:layout_height="wrap_content" |
| 126 | + android:paddingRight="8dp" |
| 127 | + android:singleLine="true" |
| 128 | + android:ellipsize="end" |
| 129 | + android:text="@string/status_bar_settings_settings_button" |
69 | 130 | /> |
70 | 131 |
|
71 | 132 | <ImageView |
72 | | - android:id="@+id/network_direction" |
| 133 | + android:id="@+id/battery" |
73 | 134 | android:layout_height="wrap_content" |
74 | 135 | android:layout_width="wrap_content" |
| 136 | + android:scaleType="centerInside" |
| 137 | + android:layout_gravity="center_vertical" |
| 138 | + android:layout_alignBaseline="@id/wifi_signal" |
| 139 | + android:paddingLeft="8dp" |
| 140 | + android:paddingRight="8dp" |
75 | 141 | android:contentDescription="@null" |
76 | 142 | /> |
77 | 143 |
|
78 | | - </FrameLayout> |
79 | | - |
80 | | - <TextView |
81 | | - android:id="@+id/network_text" |
82 | | - style="@style/StatusBarNotificationText" |
83 | | - android:layout_width="wrap_content" |
84 | | - android:layout_height="wrap_content" |
85 | | - android:layout_toRightOf="@id/netwerk" |
86 | | - android:layout_marginRight="8dp" |
87 | | - android:layout_alignBaseline="@id/network_signal" |
88 | | - android:singleLine="true" |
89 | | - android:text="@string/status_bar_settings_settings_button" |
90 | | - /> |
| 144 | + <TextView |
| 145 | + android:id="@+id/battery_text" |
| 146 | + style="@style/StatusBarNotificationText" |
| 147 | + android:layout_width="56dp" |
| 148 | + android:layout_height="wrap_content" |
| 149 | + android:layout_gravity="left|center_vertical" |
| 150 | + android:paddingRight="8dp" |
| 151 | + android:singleLine="true" |
| 152 | + android:text="@string/status_bar_settings_settings_button" |
| 153 | + /> |
91 | 154 |
|
92 | | - <ImageView |
93 | | - android:id="@+id/battery" |
94 | | - android:layout_height="wrap_content" |
95 | | - android:layout_width="wrap_content" |
96 | | - android:scaleType="centerInside" |
97 | | - android:layout_toRightOf="@id/network_text" |
98 | | - android:layout_alignBaseline="@id/network_signal" |
99 | | - android:baseline="18dp" |
100 | | - android:layout_marginLeft="8dp" |
101 | | - android:layout_marginRight="8dp" |
102 | | - android:contentDescription="@null" |
103 | | - /> |
104 | | - |
105 | | - <TextView |
106 | | - android:id="@+id/battery_text" |
107 | | - style="@style/StatusBarNotificationText" |
108 | | - android:layout_width="56dp" |
109 | | - android:layout_height="wrap_content" |
110 | | - android:layout_toRightOf="@id/battery" |
111 | | - android:layout_alignBaseline="@id/battery" |
112 | | - android:layout_marginRight="8dp" |
113 | | - android:singleLine="true" |
114 | | - android:text="@string/status_bar_settings_settings_button" |
115 | | - /> |
116 | | - </LinearLayout> |
| 155 | + <!-- this will stretch to eat up available space --> |
| 156 | + <View |
| 157 | + android:layout_width="0dp" |
| 158 | + android:layout_height="0dp" |
| 159 | + /> |
117 | 160 |
|
118 | | - <ImageView |
119 | | - android:id="@+id/settings_button" |
120 | | - android:layout_width="wrap_content" |
121 | | - android:layout_height="wrap_content" |
122 | | - android:layout_alignBaseline="@id/icons" |
123 | | - android:layout_alignParentRight="true" |
124 | | - android:paddingRight="16dp" |
125 | | - android:src="@drawable/ic_sysbar_quicksettings" |
126 | | - android:baseline="21dp" |
127 | | - android:contentDescription="@string/accessibility_settings_button" |
128 | | - /> |
| 161 | + <FrameLayout |
| 162 | + android:layout_width="wrap_content" |
| 163 | + android:layout_height="wrap_content" |
| 164 | + android:layout_gravity="center_vertical" |
| 165 | + > |
129 | 166 |
|
130 | | - <ImageView |
131 | | - android:id="@+id/notification_button" |
132 | | - android:layout_width="wrap_content" |
133 | | - android:layout_height="wrap_content" |
134 | | - android:layout_alignBaseline="@id/icons" |
135 | | - android:layout_alignParentRight="true" |
136 | | - android:paddingRight="16dp" |
137 | | - android:src="@drawable/ic_notification_open" |
138 | | - android:baseline="21dp" |
139 | | - android:visibility="invisible" |
140 | | - android:contentDescription="@string/accessibility_notifications_button" |
141 | | - /> |
| 167 | + <ImageView |
| 168 | + android:id="@+id/settings_button" |
| 169 | + android:layout_width="wrap_content" |
| 170 | + android:layout_height="wrap_content" |
| 171 | + android:paddingRight="16dp" |
| 172 | + android:src="@drawable/ic_sysbar_quicksettings" |
| 173 | + android:contentDescription="@string/accessibility_settings_button" |
| 174 | + /> |
| 175 | + |
| 176 | + <ImageView |
| 177 | + android:id="@+id/notification_button" |
| 178 | + android:layout_width="wrap_content" |
| 179 | + android:layout_height="wrap_content" |
| 180 | + android:paddingRight="16dp" |
| 181 | + android:src="@drawable/ic_notification_open" |
| 182 | + android:visibility="invisible" |
| 183 | + android:contentDescription="@string/accessibility_notifications_button" |
| 184 | + /> |
| 185 | + </FrameLayout> |
| 186 | + |
| 187 | + </TableRow> |
| 188 | + </TableLayout> |
142 | 189 |
|
143 | 190 | <com.android.systemui.statusbar.tablet.HoloClock |
144 | 191 | android:id="@+id/clock" |
|
0 commit comments