Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 1045eee2 authored by Jorim Jaggi's avatar Jorim Jaggi Committed by Android (Google) Code Review
Browse files

Merge "Factor out keyguard components of StatusBarHeaderView" into lmp-dev

parents 5e8cb22e 4538027d
Loading
Loading
Loading
Loading
+78 −0
Original line number Diff line number Diff line
<?xml version="1.0" encoding="utf-8"?>
<!--
  ~ Copyright (C) 2014 The Android Open Source Project
  ~
  ~ Licensed under the Apache License, Version 2.0 (the "License");
  ~ you may not use this file except in compliance with the License.
  ~ You may obtain a copy of the License at
  ~
  ~      http://www.apache.org/licenses/LICENSE-2.0
  ~
  ~ Unless required by applicable law or agreed to in writing, software
  ~ distributed under the License is distributed on an "AS IS" BASIS,
  ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  ~ See the License for the specific language governing permissions and
  ~ limitations under the License
  -->

<!-- Extends RelativeLayout -->
<com.android.systemui.statusbar.phone.KeyguardStatusBarView
    xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:systemui="http://schemas.android.com/apk/res/com.android.systemui"
    android:id="@+id/keyguard_header"
    android:layout_width="match_parent"
    android:layout_height="@dimen/status_bar_header_height_keyguard"
    android:baselineAligned="false"
    >

    <com.android.systemui.statusbar.phone.MultiUserSwitch android:id="@+id/multi_user_switch"
        android:layout_width="@dimen/multi_user_switch_width_keyguard"
        android:layout_height="@dimen/status_bar_header_height_keyguard"
        android:layout_alignParentEnd="true"
        android:background="@drawable/ripple_drawable"
        android:layout_marginEnd="@dimen/multi_user_switch_keyguard_margin">
        <ImageView android:id="@+id/multi_user_avatar"
            android:layout_width="@dimen/multi_user_avatar_keyguard_size"
            android:layout_height="@dimen/multi_user_avatar_keyguard_size"
            android:layout_gravity="center"
            android:scaleType="centerInside"/>
    </com.android.systemui.statusbar.phone.MultiUserSwitch>

    <LinearLayout android:id="@+id/system_icons_super_container"
        android:layout_width="wrap_content"
        android:layout_height="@dimen/status_bar_header_height"
        android:layout_toStartOf="@id/multi_user_switch"
        android:layout_alignWithParentIfMissing="true"
        android:layout_marginStart="16dp"
        android:paddingEnd="2dp">
        <FrameLayout android:id="@+id/system_icons_container"
            android:layout_width="wrap_content"
            android:layout_height="@dimen/status_bar_height"
            android:layout_gravity="center_vertical"
            >
            <include layout="@layout/system_icons" />
        </FrameLayout>
        <TextView android:id="@+id/battery_level"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_gravity="center_vertical"
            android:layout_marginStart="@dimen/header_battery_margin_keyguard"
            android:paddingEnd="@dimen/battery_level_padding_end"
            android:textColor="#ffffff"
            android:visibility="gone"
            android:textSize="12sp"/>
    </LinearLayout>

    <com.android.keyguard.CarrierText
        android:id="@+id/keyguard_carrier_text"
        android:layout_width="match_parent"
        android:layout_height="@dimen/status_bar_header_height_keyguard"
        android:layout_marginStart="@dimen/keyguard_carrier_text_margin"
        android:layout_toStartOf="@id/system_icons_super_container"
        android:gravity="center_vertical"
        android:ellipsize="marquee"
        android:textAppearance="?android:attr/textAppearanceSmall"
        android:textColor="#ffffff"
        android:singleLine="true" />

</com.android.systemui.statusbar.phone.KeyguardStatusBarView>
+2 −26
Original line number Diff line number Diff line
@@ -82,33 +82,9 @@
            android:layout_height="match_parent"
            android:orientation="horizontal"
            >
            <LinearLayout android:id="@+id/system_icons"
                android:layout_width="wrap_content"
                android:layout_height="match_parent"
                android:gravity="center_vertical"
                >
                <com.android.systemui.statusbar.AlphaOptimizedLinearLayout
                    android:id="@+id/statusIcons"
                    android:layout_width="wrap_content"
                    android:layout_height="match_parent"
                    android:gravity="center_vertical"
                    android:orientation="horizontal"/>

                <include layout="@layout/signal_cluster_view"
                    android:id="@+id/signal_cluster"
                    android:layout_width="wrap_content"
                    android:layout_height="wrap_content"
                    android:layout_marginStart="2dp"
                    />
                <!-- battery must be padded below to match assets -->
                <com.android.systemui.BatteryMeterView
                    android:id="@+id/battery"
                    android:layout_height="16dp"
                    android:layout_width="10.5dp"
                    android:layout_marginBottom="0.33dp"
                    android:layout_marginStart="4dip"
                    />
            </LinearLayout>
            <include layout="@layout/system_icons" />

            <com.android.systemui.statusbar.policy.Clock
                android:id="@+id/clock"
                android:textAppearance="@style/TextAppearance.StatusBar.Clock"
+4 −0
Original line number Diff line number Diff line
@@ -50,6 +50,10 @@
        android:visibility="gone"
        />

    <include
        layout="@layout/keyguard_status_bar"
        android:visibility="invisible" />

    <com.android.systemui.statusbar.phone.NotificationsQuickSettingsContainer
        style="@style/NotificationsQuickSettings"
        android:id="@+id/notification_container_parent"
+1 −13
Original line number Diff line number Diff line
@@ -68,7 +68,7 @@
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_gravity="center_vertical"
            android:layout_marginStart="@dimen/header_battery_margin_keyguard"
            android:layout_marginStart="@dimen/header_battery_margin_expanded"
            android:paddingEnd="@dimen/battery_level_padding_end"
            android:textColor="#ffffff"
            android:textSize="12sp"/>
@@ -139,18 +139,6 @@
        android:visibility="gone"
        />

    <com.android.keyguard.CarrierText
        android:id="@+id/keyguard_carrier_text"
        android:layout_width="match_parent"
        android:layout_height="@dimen/status_bar_header_height_keyguard"
        android:layout_marginStart="@dimen/keyguard_carrier_text_margin"
        android:layout_toStartOf="@id/system_icons_super_container"
        android:gravity="center_vertical"
        android:ellipsize="marquee"
        android:textAppearance="?android:attr/textAppearanceSmall"
        android:textColor="#ffffff"
        android:singleLine="true" />

    <include
        android:id="@+id/qs_detail_header"
        layout="@layout/qs_detail_header"
+41 −0
Original line number Diff line number Diff line
<?xml version="1.0" encoding="utf-8"?><!--
  ~ Copyright (C) 2014 The Android Open Source Project
  ~
  ~ Licensed under the Apache License, Version 2.0 (the "License");
  ~ you may not use this file except in compliance with the License.
  ~ You may obtain a copy of the License at
  ~
  ~      http://www.apache.org/licenses/LICENSE-2.0
  ~
  ~ Unless required by applicable law or agreed to in writing, software
  ~ distributed under the License is distributed on an "AS IS" BASIS,
  ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  ~ See the License for the specific language governing permissions and
  ~ limitations under the License
  -->

<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
    android:id="@+id/system_icons"
    android:layout_width="wrap_content"
    android:layout_height="match_parent"
    android:gravity="center_vertical">

    <com.android.systemui.statusbar.AlphaOptimizedLinearLayout android:id="@+id/statusIcons"
        android:layout_width="wrap_content"
        android:layout_height="match_parent"
        android:gravity="center_vertical"
        android:orientation="horizontal"/>

    <include layout="@layout/signal_cluster_view"
        android:id="@+id/signal_cluster"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_marginStart="2dp"/>

    <!-- battery must be padded below to match assets -->
    <com.android.systemui.BatteryMeterView android:id="@+id/battery"
        android:layout_height="16dp"
        android:layout_width="10.5dp"
        android:layout_marginBottom="0.33dp"
        android:layout_marginStart="4dip"/>
</LinearLayout>
 No newline at end of file
Loading