Some resource fixes for drop target
> Making it singleline with ellipsis everywhere > Decreasing the text size on smaller devices > Decreasing char limit for various labels Bug: 17563793 Bug: 17938450 Change-Id: I8ad1a156de0601d07419b2cc6418389bc2e24a4e
This commit is contained in:
parent
24e0fc1221
commit
0e375f947b
|
@ -1,39 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!-- Copyright (C) 2011 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.
|
||||
-->
|
||||
<merge xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<FrameLayout
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
style="@style/DropTargetButtonContainer"
|
||||
android:layout_weight="1">
|
||||
<!-- Delete target -->
|
||||
<com.android.launcher3.DeleteDropTarget
|
||||
style="@style/DropTargetButton"
|
||||
android:id="@+id/delete_target_text"
|
||||
android:text="@string/delete_zone_label_workspace"
|
||||
android:drawableStart="@drawable/remove_target_selector" />
|
||||
</FrameLayout>
|
||||
<FrameLayout
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
style="@style/DropTargetButtonContainer"
|
||||
android:layout_weight="1">
|
||||
<!-- Info target -->
|
||||
<com.android.launcher3.InfoDropTarget
|
||||
style="@style/DropTargetButton"
|
||||
android:id="@+id/info_target_text"
|
||||
android:text="@string/info_target_label"
|
||||
android:drawableStart="@drawable/info_target_selector" />
|
||||
</FrameLayout>
|
||||
</merge>
|
|
@ -1,5 +1,6 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!-- Copyright (C) 2011 The Android Open Source Project
|
||||
<!--
|
||||
Copyright (C) 2011 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.
|
||||
|
@ -13,21 +14,45 @@
|
|||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
-->
|
||||
<com.android.launcher3.SearchDropTargetBar
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:orientation="horizontal"
|
||||
android:focusable="false"
|
||||
<com.android.launcher3.SearchDropTargetBar xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
android:layout_height="match_parent"
|
||||
android:focusable="false"
|
||||
android:orientation="horizontal" >
|
||||
|
||||
<!-- Drag specific targets container -->
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/drag_target_bar"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_gravity="center">
|
||||
android:layout_gravity="center" >
|
||||
|
||||
<include
|
||||
layout="@layout/drop_target_bar" />
|
||||
<FrameLayout
|
||||
style="@style/DropTargetButtonContainer"
|
||||
android:layout_weight="1" >
|
||||
|
||||
<!-- Delete target -->
|
||||
|
||||
<com.android.launcher3.DeleteDropTarget
|
||||
android:id="@+id/delete_target_text"
|
||||
style="@style/DropTargetButton"
|
||||
android:drawableStart="@drawable/remove_target_selector"
|
||||
android:text="@string/delete_zone_label_workspace" />
|
||||
</FrameLayout>
|
||||
|
||||
<FrameLayout
|
||||
style="@style/DropTargetButtonContainer"
|
||||
android:layout_weight="1" >
|
||||
|
||||
<!-- Info target -->
|
||||
|
||||
<com.android.launcher3.InfoDropTarget
|
||||
android:id="@+id/info_target_text"
|
||||
style="@style/DropTargetButton"
|
||||
android:drawableStart="@drawable/info_target_selector"
|
||||
android:text="@string/info_target_label" />
|
||||
</FrameLayout>
|
||||
</LinearLayout>
|
||||
</com.android.launcher3.SearchDropTargetBar>
|
||||
|
||||
</com.android.launcher3.SearchDropTargetBar>
|
|
@ -18,27 +18,25 @@
|
|||
-->
|
||||
|
||||
<resources>
|
||||
<!-- Search Bar -->
|
||||
<style name="SearchButton">
|
||||
</style>
|
||||
|
||||
<!-- Search Bar -->
|
||||
<style name="SearchButton"></style>
|
||||
|
||||
<style name="DropTargetButtonContainer">
|
||||
<item name="android:layout_width">match_parent</item>
|
||||
<item name="android:layout_height">wrap_content</item>
|
||||
</style>
|
||||
<style name="DropTargetButton">
|
||||
<item name="android:layout_width">wrap_content</item>
|
||||
|
||||
<!-- This style applies to the drop target when it is shown in the sidebar -->
|
||||
<style name="DropTargetButton" parent="DropTargetButton.Base">
|
||||
<item name="android:layout_height">wrap_content</item>
|
||||
<item name="android:layout_gravity">center</item>
|
||||
<item name="android:gravity">center</item>
|
||||
<item name="android:drawablePadding">0dp</item>
|
||||
<item name="android:paddingTop">@dimen/toolbar_button_vertical_padding</item>
|
||||
<item name="android:paddingBottom">@dimen/toolbar_button_vertical_padding</item>
|
||||
<item name="android:paddingLeft">@dimen/toolbar_button_horizontal_padding</item>
|
||||
<item name="android:paddingRight">@dimen/toolbar_button_horizontal_padding</item>
|
||||
<item name="android:shadowColor">#DD000000</item>
|
||||
<item name="android:shadowDx">0.0</item>
|
||||
<item name="android:shadowDy">1.0</item>
|
||||
<item name="android:shadowRadius">4.0</item>
|
||||
</style>
|
||||
|
||||
</resources>
|
||||
|
||||
</resources>
|
|
@ -1,5 +1,6 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!-- Copyright (C) 2011 The Android Open Source Project
|
||||
<!--
|
||||
Copyright (C) 2011 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.
|
||||
|
@ -15,6 +16,9 @@
|
|||
-->
|
||||
|
||||
<resources>
|
||||
|
||||
<!-- Drag padding to add to the bottom of drop targets -->
|
||||
<dimen name="drop_target_drag_padding">20dp</dimen>
|
||||
</resources>
|
||||
<dimen name="drop_target_text_size">16sp</dimen>
|
||||
|
||||
</resources>
|
|
@ -18,26 +18,22 @@
|
|||
-->
|
||||
|
||||
<resources>
|
||||
<!-- Workspace -->
|
||||
<style name="SearchButton">
|
||||
</style>
|
||||
|
||||
<!-- Workspace -->
|
||||
<style name="SearchButton"></style>
|
||||
|
||||
<style name="DropTargetButtonContainer">
|
||||
<item name="android:layout_width">0dp</item>
|
||||
<item name="android:layout_height">match_parent</item>
|
||||
</style>
|
||||
<style name="DropTargetButton">
|
||||
<item name="android:layout_width">wrap_content</item>
|
||||
<item name="android:layout_height">match_parent</item>
|
||||
<item name="android:layout_gravity">center</item>
|
||||
<item name="android:gravity">center_vertical</item>
|
||||
<item name="android:drawablePadding">7.5dp</item>
|
||||
|
||||
<style name="DropTargetButton" parent="DropTargetButton.Base">
|
||||
<item name="android:paddingLeft">60dp</item>
|
||||
<item name="android:paddingRight">60dp</item>
|
||||
<item name="android:textColor">#FFFFFFFF</item>
|
||||
<item name="android:textSize">16sp</item>
|
||||
<item name="android:shadowColor">#393939</item>
|
||||
<item name="android:shadowDx">0.0</item>
|
||||
<item name="android:shadowDy">0.0</item>
|
||||
<item name="android:shadowRadius">2.0</item>
|
||||
</style>
|
||||
</resources>
|
||||
|
||||
</resources>
|
|
@ -62,6 +62,7 @@
|
|||
|
||||
<!-- Drag padding to add to the bottom of drop targets -->
|
||||
<dimen name="drop_target_drag_padding">14dp</dimen>
|
||||
<dimen name="drop_target_text_size">14sp</dimen>
|
||||
|
||||
<!-- Dragging -->
|
||||
<!-- the area at the edge of the screen that makes the workspace go left
|
||||
|
|
|
@ -125,11 +125,11 @@ s -->
|
|||
device. [CHAR_LIMIT=30]-->
|
||||
<string name="delete_zone_label_all_apps">Uninstall</string>
|
||||
|
||||
<!-- Label for delete drop target. [CHAR_LIMIT=30] -->
|
||||
<!-- Label for delete drop target. [CHAR_LIMIT=20] -->
|
||||
<string name="delete_target_label">Remove</string>
|
||||
<!-- Label for uninstall drop target. [CHAR_LIMIT=30]-->
|
||||
<!-- Label for uninstall drop target. [CHAR_LIMIT=20]-->
|
||||
<string name="delete_target_uninstall_label">Uninstall</string>
|
||||
<!-- Label for the info icon. [CHAR_LIMIT=30] -->
|
||||
<!-- Label for the info icon. [CHAR_LIMIT=20] -->
|
||||
<string name="info_target_label">App info</string>
|
||||
|
||||
<!-- Accessibility: Search button -->
|
||||
|
|
|
@ -32,10 +32,9 @@
|
|||
<item name="android:fontFamily">sans-serif-condensed</item>
|
||||
</style>
|
||||
|
||||
<style name="WorkspaceIcon.Portrait">
|
||||
</style>
|
||||
<style name="WorkspaceIcon.Landscape">
|
||||
</style>
|
||||
<style name="WorkspaceIcon.Portrait"></style>
|
||||
|
||||
<style name="WorkspaceIcon.Landscape"></style>
|
||||
|
||||
<style name="WorkspaceIcon.AppsCustomize">
|
||||
<item name="android:background">@null</item>
|
||||
|
@ -52,15 +51,16 @@
|
|||
<item name="customShadows">false</item>
|
||||
</style>
|
||||
|
||||
<style name="SearchDropTargetBar">
|
||||
</style>
|
||||
<style name="SearchButton">
|
||||
</style>
|
||||
<style name="SearchDropTargetBar"></style>
|
||||
|
||||
<style name="SearchButton"></style>
|
||||
|
||||
<style name="DropTargetButtonContainer">
|
||||
<item name="android:layout_width">0dp</item>
|
||||
<item name="android:layout_height">match_parent</item>
|
||||
</style>
|
||||
<style name="DropTargetButton">
|
||||
|
||||
<style name="DropTargetButton.Base">
|
||||
<item name="android:layout_width">wrap_content</item>
|
||||
<item name="android:layout_height">match_parent</item>
|
||||
<item name="android:layout_gravity">center</item>
|
||||
|
@ -69,7 +69,7 @@
|
|||
<item name="android:paddingLeft">25dp</item>
|
||||
<item name="android:paddingRight">25dp</item>
|
||||
<item name="android:textColor">#FFFFFFFF</item>
|
||||
<item name="android:textSize">16sp</item>
|
||||
<item name="android:textSize">@dimen/drop_target_text_size</item>
|
||||
<item name="android:singleLine">true</item>
|
||||
<item name="android:ellipsize">end</item>
|
||||
<item name="android:shadowColor">#FF000000</item>
|
||||
|
@ -78,6 +78,8 @@
|
|||
<item name="android:shadowRadius">4.0</item>
|
||||
</style>
|
||||
|
||||
<style name="DropTargetButton" parent="DropTargetButton.Base"></style>
|
||||
|
||||
<style name="PreloadIcon">
|
||||
<item name="background">@drawable/virtual_preload</item>
|
||||
<item name="indicatorSize">4dp</item>
|
||||
|
@ -94,7 +96,9 @@
|
|||
<style name="PagedViewWidgetImageView">
|
||||
<item name="android:paddingLeft">@dimen/app_widget_preview_padding_left</item>
|
||||
</style>
|
||||
|
||||
<style name="SearchButton.WithPaddingStart">
|
||||
<item name="android:paddingLeft">8dp</item>
|
||||
</style>
|
||||
</resources>
|
||||
|
||||
</resources>
|
Loading…
Reference in New Issue