Merge "Visual refinements for lockscreen." into lmp-preview-dev

This commit is contained in:
Jorim Jaggi
2014-05-26 14:23:38 +00:00
committed by Android (Google) Code Review
10 changed files with 28 additions and 21 deletions

View File

@@ -39,13 +39,12 @@
android:id="@+id/clock_view"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center_horizontal|top"
android:layout_gravity="center_horizontal"
android:textColor="@color/clock_white"
android:singleLine="true"
style="@style/widget_big_thin"
android:format12Hour="@string/keyguard_widget_12_hours_format"
android:format24Hour="@string/keyguard_widget_24_hours_format"
android:baselineAligned="true"
android:layout_marginBottom="@dimen/bottom_text_spacing_digital" />
<include layout="@layout/keyguard_status_area" />

View File

@@ -26,5 +26,4 @@
<!-- Overload default clock widget parameters -->
<dimen name="widget_big_font_size">88dp</dimen>
<dimen name="bottom_text_spacing_digital">-24dp</dimen>
</resources>

View File

@@ -65,7 +65,7 @@
<!-- Overload default clock widget parameters -->
<dimen name="widget_big_font_size">96dp</dimen>
<dimen name="widget_label_font_size">16sp</dimen>
<dimen name="bottom_text_spacing_digital">-24dp</dimen>
<dimen name="bottom_text_spacing_digital">-8dp</dimen>
<!-- EmergencyCarrierArea overlap - amount to overlap the emergency button and carrier text.
Should be 0 on devices with plenty of room (e.g. tablets) -->

View File

@@ -155,7 +155,7 @@
<dimen name="eca_overlap">-10dip</dimen>
<!-- Default clock parameters -->
<dimen name="bottom_text_spacing_digital">-18dp</dimen>
<dimen name="bottom_text_spacing_digital">-6dp</dimen>
<dimen name="label_font_size">14dp</dimen>
<dimen name="widget_label_font_size">14sp</dimen>
<dimen name="widget_big_font_size">68dp</dimen>

View File

@@ -97,9 +97,9 @@
<string name="keyguard_sim_unlock_progress_dialog_message">Unlocking SIM card\u2026</string>
<!-- Time format strings for fall-back clock widget -->
<string name="keyguard_widget_12_hours_format" translatable="false">h&#58;mm</string>
<string name="keyguard_widget_12_hours_format" translatable="false">h\uee01mm</string>
<!-- Time format strings for fall-back clock widget -->
<string name="keyguard_widget_24_hours_format" translatable="false">kk&#58;mm</string>
<string name="keyguard_widget_24_hours_format" translatable="false">kk\uee01mm</string>
<!-- Accessibility description sent when user changes the current lock screen widget. [CHAR_LIMIT=none] -->
<string name="keyguard_accessibility_widget_changed">%1$s. Widget %2$d of %3$d.</string>

View File

@@ -59,8 +59,6 @@
<!-- Built-in clock widget stuff -->
<style name="widget_label">
<item name="android:textStyle">bold</item>
<item name="android:fontFamily">sans-serif-light</item>
<item name="android:textSize">@dimen/widget_label_font_size</item>
</style>
<style name="big_thin">

View File

@@ -95,6 +95,10 @@ public class KeyguardStatusView extends GridLayout {
final boolean screenOn = KeyguardUpdateMonitor.getInstance(mContext).isScreenOn();
setEnableMarquee(screenOn);
refresh();
// Disable elegant text height because our fancy colon makes the ymin value huge for no
// reason.
mClockView.setElegantTextHeight(false);
}
protected void refresh() {
@@ -164,6 +168,10 @@ public class KeyguardStatusView extends GridLayout {
clockView24 = DateFormat.getBestDateTimePattern(locale, clockView24Skel);
// Use fancy colon.
clockView24 = clockView24.replace(':', '\uee01');
clockView12 = clockView12.replace(':', '\uee01');
cacheKey = key;
}
}

View File

@@ -53,7 +53,8 @@
android:layout_marginBottom="100dp"
android:layout_gravity="bottom|center_horizontal"
android:textStyle="italic"
android:textAppearance="?android:attr/textAppearanceMedium"/>
android:textColor="#ffffff"
android:textAppearance="?android:attr/textAppearanceSmall"/>
<ImageView
android:id="@+id/lock_icon"

View File

@@ -65,15 +65,6 @@
/>
</RelativeLayout>
<com.android.keyguard.CarrierText
android:id="@+id/keyguard_carrier_text"
android:layout_width="wrap_content"
android:layout_height="@dimen/status_bar_header_height_keyguard"
android:layout_marginLeft="8dp"
android:gravity="center_vertical"
android:ellipsize="marquee"
android:textAppearance="?android:attr/textAppearanceMedium" />
<com.android.systemui.statusbar.phone.MultiUserSwitch android:id="@+id/multi_user_switch"
android:layout_width="40dp"
android:layout_height="@dimen/status_bar_header_height"
@@ -98,6 +89,17 @@
android:layout_marginEnd="4dp"
/>
<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_marginLeft="8dp"
android:layout_toStartOf="@id/system_icons_container"
android:gravity="center_vertical"
android:ellipsize="marquee"
android:textAppearance="?android:attr/textAppearanceSmall"
android:textColor="#ffffff" />
<include
layout="@layout/quick_settings_brightness_dialog"
android:id="@+id/brightness_container"

View File

@@ -57,6 +57,6 @@
<!-- The margin between the clock and the notifications on Keyguard. See
keyguard_clock_height_fraction_* for the difference between min and max.-->
<dimen name="keyguard_clock_notifications_margin_min">32dp</dimen>
<dimen name="keyguard_clock_notifications_margin_max">32dp</dimen>
<dimen name="keyguard_clock_notifications_margin_min">36dp</dimen>
<dimen name="keyguard_clock_notifications_margin_max">36dp</dimen>
</resources>