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

Commit 272dfed9 authored by Selim Cinek's avatar Selim Cinek Committed by android-build-merger
Browse files

Merge "Fixes an issue where the padding to the clock was wrong" into qt-r1-dev

am: c2abf3b9

Change-Id: Iee76ad95bfa33815be9348043c9007a5b1fff8bc
parents f5e896e2 c2abf3b9
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -41,7 +41,7 @@
            <ImageView
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                android:layout_marginTop="@dimen/widget_vertical_padding"
                android:layout_marginTop="24dp"
                android:layout_gravity="center_horizontal"
                android:src="@drawable/kg_security_lock_normal" />
        </LinearLayout>
+1 −1
Original line number Diff line number Diff line
@@ -74,7 +74,7 @@
            android:id="@+id/clock_notification_icon_container"
            android:layout_width="match_parent"
            android:layout_height="@dimen/notification_shelf_height"
            android:layout_marginTop="18dp"
            android:layout_marginTop="@dimen/widget_vertical_padding"
        />
    </LinearLayout>
</com.android.keyguard.KeyguardStatusView>
+2 −2
Original line number Diff line number Diff line
@@ -53,8 +53,8 @@
    <dimen name="title_clock_padding">4dp</dimen>
    <!-- Clock with header -->
    <dimen name="widget_small_font_size">@dimen/widget_title_font_size</dimen>
    <dimen name="widget_vertical_padding">24dp</dimen>
    <dimen name="widget_vertical_padding_with_header">32dp</dimen>
    <dimen name="widget_vertical_padding">17dp</dimen>
    <dimen name="widget_vertical_padding_with_header">25dp</dimen>
    <dimen name="widget_vertical_padding_clock">12dp</dimen>
    <!-- Subtitle paddings -->
    <dimen name="widget_horizontal_padding">8dp</dimen>
+12 −10
Original line number Diff line number Diff line
@@ -73,8 +73,8 @@ public class KeyguardStatusView extends GridLayout implements
     * Bottom margin that defines the margin between bottom of smart space and top of notification
     * icons on AOD.
     */
    private int mBottomMargin;
    private int mBottomMarginWithHeader;
    private int mIconTopMargin;
    private int mIconTopMarginWithHeader;
    private boolean mShowingHeader;

    private KeyguardUpdateMonitorCallback mInfoCallback = new KeyguardUpdateMonitorCallback() {
@@ -209,12 +209,14 @@ public class KeyguardStatusView extends GridLayout implements
            return;
        }
        mShowingHeader = hasHeader;
        // Update bottom margin since header has appeared/disappeared.
        if (mStatusViewContainer != null) {
            MarginLayoutParams params = (MarginLayoutParams) mStatusViewContainer.getLayoutParams();
            params.setMargins(params.leftMargin, params.topMargin, params.rightMargin,
                    hasHeader ? mBottomMarginWithHeader : mBottomMargin);
            mStatusViewContainer.setLayoutParams(params);
        if (mNotificationIcons != null) {
            // Update top margin since header has appeared/disappeared.
            MarginLayoutParams params = (MarginLayoutParams) mNotificationIcons.getLayoutParams();
            params.setMargins(params.leftMargin,
                    hasHeader ? mIconTopMarginWithHeader : mIconTopMargin,
                    params.rightMargin,
                    params.bottomMargin);
            mNotificationIcons.setLayoutParams(params);
        }
    }

@@ -340,8 +342,8 @@ public class KeyguardStatusView extends GridLayout implements
    }

    private void loadBottomMargin() {
        mBottomMargin = getResources().getDimensionPixelSize(R.dimen.widget_vertical_padding);
        mBottomMarginWithHeader = getResources().getDimensionPixelSize(
        mIconTopMargin = getResources().getDimensionPixelSize(R.dimen.widget_vertical_padding);
        mIconTopMarginWithHeader = getResources().getDimensionPixelSize(
                R.dimen.widget_vertical_padding_with_header);
    }