Messaging: Vendor chips, colorpicker, photoviewer, and vcard in-tree
Clone no longer depends on LineageOS gitlinks; the libraries used by the app live in this repo. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -0,0 +1,36 @@
|
||||
<?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.
|
||||
-->
|
||||
<resources>
|
||||
<declare-styleable name="RecipientEditTextView">
|
||||
<attr name="avatarPosition">
|
||||
<enum name="end" value="0" />
|
||||
<enum name="start" value="1" />
|
||||
</attr>
|
||||
<attr name="chipBackground" format="reference" />
|
||||
<attr name="chipDelete" format="reference" />
|
||||
<attr name="chipFontSize" format="reference" />
|
||||
<attr name="chipHeight" format="reference" />
|
||||
<attr name="chipPadding" format="reference" />
|
||||
<attr name="disableDelete" format="boolean" />
|
||||
<attr name="invalidChipBackground" format="reference" />
|
||||
<attr name="imageSpanAlignment">
|
||||
<enum name="bottom" value = "0"/>
|
||||
<enum name="baseline" value = "1"/>
|
||||
</attr>
|
||||
<attr name="unselectedChipBackgroundColor" format="color" />
|
||||
<attr name="unselectedChipTextColor" format="color" />
|
||||
</declare-styleable>
|
||||
</resources>
|
||||
@@ -0,0 +1,34 @@
|
||||
<?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.
|
||||
-->
|
||||
|
||||
<resources>
|
||||
|
||||
<color name="chips_dropdown_background_activated">#4285f4</color>
|
||||
<color name="chips_dropdown_background_pressed">#ededed</color>
|
||||
|
||||
<color name="autocomplete_divider_color">#cccccc</color>
|
||||
<color name="autocomplete_bottom_shadow_start">#40000000</color>
|
||||
|
||||
<color name="chip_background">#f6f6f6</color>
|
||||
<color name="chip_background_invalid">#db4437</color>
|
||||
|
||||
<color name="chips_dropdown_text_default">#212121</color>
|
||||
<color name="chips_dropdown_text_activated">@android:color/white</color>
|
||||
<color name="chips_dropdown_text_highlighted">#757575</color>
|
||||
<color name="chips_dropdown_permission_text">#4285f4</color>
|
||||
|
||||
</resources>
|
||||
@@ -0,0 +1,39 @@
|
||||
<?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.
|
||||
-->
|
||||
|
||||
<resources>
|
||||
<!-- override default padding values, -1dp if it's not set to override -->
|
||||
<dimen name="chip_padding_start">-1dp</dimen>
|
||||
<dimen name="chip_padding_end">12dp</dimen>
|
||||
|
||||
<!-- chip -->
|
||||
<dimen name="chip_padding">8dp</dimen>
|
||||
<dimen name="chip_height">32dp</dimen>
|
||||
<dimen name="chip_text_size">14sp</dimen>
|
||||
<dimen name="line_spacing_extra">3dp</dimen>
|
||||
<integer name="chips_max_lines">-1</integer>
|
||||
|
||||
<!-- dropdown -->
|
||||
<dimen name="chip_icon_margin_end">12dp</dimen>
|
||||
<dimen name="chip_dropdown_height">72dp</dimen>
|
||||
<dimen name="chip_custom_divider_height">0.5dp</dimen>
|
||||
<dimen name="chip_icon_padding">8dp</dimen>
|
||||
<!-- autocomplete dropdown -->
|
||||
<dimen name="chip_wrapper_start_padding">16dp</dimen>
|
||||
<dimen name="chip_wrapper_top_padding">16dp</dimen>
|
||||
<dimen name="chip_wrapper_end_padding">16dp</dimen>
|
||||
<dimen name="chip_wrapper_bottom_padding">16dp</dimen>
|
||||
</resources>
|
||||
@@ -0,0 +1,37 @@
|
||||
<?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.
|
||||
-->
|
||||
<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
|
||||
<!-- Text displayed when the recipientedittextview is not focused. Displays the total number of recipients since the field is shrunk to just display a portion -->
|
||||
<string name="more_string">\u002B<xliff:g id="count">%1$d</xliff:g></string>
|
||||
<!-- Text displayed when the user long presses on a chip to copy the recipients email address [CHAR LIMIT=200] -->
|
||||
<string name="copy_email">Copy email address</string>
|
||||
<!-- Text displayed when the user long presses on a chip to copy the recipient's phone number [CHAR LIMIT=200] -->
|
||||
<string name="copy_number">Copy phone number</string>
|
||||
<!-- Text displayed in the enter key slot when the recipientedittextview has focus [CHAR LIMIT=12] -->
|
||||
<string name="action_label">Return</string>
|
||||
<!-- Announce the number of possible recipient entries that the user can select from for accessibility purposes [CHAR LIMIT=200] -->
|
||||
<string name="accessbility_suggestion_dropdown_opened">Contact suggestions opened</string>
|
||||
<!-- Announce that there are no possible recipient entries that the user can select from for accessibility purposes [CHAR LIMIT=200] -->
|
||||
<string name="accessbility_suggestion_dropdown_closed">No suggestions available</string>
|
||||
<!-- Description for the delete button that removes the selected contact from the recipients [CHAR LIMIT=100] -->
|
||||
<string name="dropdown_delete_button_desc">Remove <xliff:g id="contact">%s</xliff:g> from recipients</string>
|
||||
<!-- Text displayed as the primary action for a dialog to copy text. [CHAR LIMIT=25] -->
|
||||
<string name="chips_action_copy">Copy</string>
|
||||
<!-- Text displayed as the secondary action for a dialog to cancel. [CHAR LIMIT=25] -->
|
||||
<string name="chips_action_cancel">Cancel</string>
|
||||
<!-- Text displayed on the drop down item that is shown when app doesn't have Contact permission. This item will open dialog to request permission. [CHAR LIMIT=50] -->
|
||||
<string name="chips_permission_text">Allow contacts suggestions</string>
|
||||
</resources>
|
||||
@@ -0,0 +1,139 @@
|
||||
<?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.
|
||||
-->
|
||||
<resources xmlns:tools="http://schemas.android.com/tools">
|
||||
<style name="RecipientEditTextViewBase">
|
||||
<item name="android:layout_width">match_parent</item>
|
||||
<item name="android:layout_height">wrap_content</item>
|
||||
<item name="android:background">@null</item>
|
||||
<item name="android:inputType">textEmailAddress|textMultiLine</item>
|
||||
<item name="android:minHeight">@dimen/chip_height</item>
|
||||
<item name="android:popupBackground">@android:color/white</item>
|
||||
<item name="android:textAlignment" tools:ignore="NewApi">viewStart</item>
|
||||
<item name="android:textAppearance">?android:attr/textAppearanceMedium</item>
|
||||
<item name="android:textDirection" tools:ignore="NewApi">locale</item>
|
||||
</style>
|
||||
|
||||
<style name="RecipientEditTextView" parent="@style/RecipientEditTextViewBase">
|
||||
<item name="android:imeOptions">actionNext|flagNoFullscreen</item>
|
||||
</style>
|
||||
|
||||
<style name="ChipAutocompleteWrapperStyle">
|
||||
<item name="android:paddingLeft">@dimen/chip_wrapper_start_padding</item>
|
||||
<item name="android:paddingTop">@dimen/chip_wrapper_top_padding</item>
|
||||
<item name="android:paddingRight">@dimen/chip_wrapper_end_padding</item>
|
||||
<item name="android:paddingBottom">@dimen/chip_wrapper_bottom_padding</item>
|
||||
</style>
|
||||
|
||||
<style name="ChipAutocompleteDividerStyle">
|
||||
<item name="android:layout_width">match_parent</item>
|
||||
<item name="android:layout_height">@dimen/chip_custom_divider_height</item>
|
||||
<item name="android:background">@color/autocomplete_divider_color</item>
|
||||
<item name="android:layout_marginLeft">@dimen/chip_wrapper_start_padding</item>
|
||||
</style>
|
||||
|
||||
<style name="ChipAutocompleteDividerStyle.PermissionItem">
|
||||
<item name="android:background">@drawable/chip_autocomplete_divider_background</item>
|
||||
<item name="android:layout_height">3dp</item>
|
||||
<item name="android:layout_marginLeft">0dp</item>
|
||||
</style>
|
||||
|
||||
<style name="ChipTextViewLayoutStyle">
|
||||
<item name="android:layout_width">0dp</item>
|
||||
<item name="android:layout_height">wrap_content</item>
|
||||
<item name="android:layout_gravity">center_vertical</item>
|
||||
<item name="android:layout_weight">1</item>
|
||||
<item name="android:orientation">vertical</item>
|
||||
</style>
|
||||
|
||||
<style name="ChipTitleStyle">
|
||||
<item name="android:id">@android:id/title</item>
|
||||
<item name="android:layout_width">match_parent</item>
|
||||
<item name="android:layout_height">wrap_content</item>
|
||||
<item name="android:ellipsize">middle</item>
|
||||
<item name="android:singleLine">true</item>
|
||||
<item name="android:textAlignment">viewStart</item>
|
||||
<item name="android:textColor">@color/chips_dropdown_text</item>
|
||||
<item name="android:textSize">16sp</item>
|
||||
</style>
|
||||
|
||||
<style name="ChipSubtitleStyle">
|
||||
<item name="android:id">@android:id/text1</item>
|
||||
<item name="android:layout_width">match_parent</item>
|
||||
<item name="android:layout_height">wrap_content</item>
|
||||
<item name="android:ellipsize">middle</item>
|
||||
<item name="android:singleLine">true</item>
|
||||
<item name="android:textAlignment">viewStart</item>
|
||||
<item name="android:textColor">@color/chips_dropdown_text</item>
|
||||
<item name="android:textSize">14sp</item>
|
||||
</style>
|
||||
|
||||
<style name="ChipIndicatorTextStyle" parent="@style/ChipSubtitleStyle">
|
||||
<item name="android:layout_marginTop">6dp</item>
|
||||
<item name="android:gravity">center_vertical</item>
|
||||
<item name="android:drawablePadding">4dp</item>
|
||||
</style>
|
||||
|
||||
<style name="ChipPermissionStyle">
|
||||
<item name="android:layout_width">0dp</item>
|
||||
<item name="android:layout_height">wrap_content</item>
|
||||
<item name="android:layout_gravity">center_vertical</item>
|
||||
<item name="android:layout_weight">1</item>
|
||||
<item name="android:textAlignment">viewStart</item>
|
||||
<item name="android:textColor">@color/chips_dropdown_permission_text</item>
|
||||
<item name="android:textSize">16sp</item>
|
||||
<item name="android:text">@string/chips_permission_text</item>
|
||||
</style>
|
||||
|
||||
<style name="ChipIconBaseStyle">
|
||||
<item name="android:id">@android:id/icon</item>
|
||||
<item name="android:layout_width">40dp</item>
|
||||
<item name="android:layout_height">40dp</item>
|
||||
<item name="android:layout_gravity">center_vertical</item>
|
||||
<item name="android:contentDescription">@null</item>
|
||||
</style>
|
||||
|
||||
<style name="ChipStartIconStyle" parent="@style/ChipIconBaseStyle">
|
||||
<item name="android:layout_marginRight">@dimen/chip_icon_margin_end</item>
|
||||
</style>
|
||||
|
||||
<style name="ChipEndIconStyle" parent="@style/ChipIconBaseStyle">
|
||||
<item name="android:layout_marginLeft">@dimen/chip_icon_margin_end</item>
|
||||
</style>
|
||||
|
||||
<style name="ChipDeleteIconBaseStyle">
|
||||
<item name="android:id">@android:id/icon1</item>
|
||||
<item name="android:layout_width">36dp</item>
|
||||
<item name="android:layout_height">48dp</item>
|
||||
<item name="android:layout_gravity">center_vertical</item>
|
||||
<item name="android:paddingTop">10dp</item>
|
||||
<item name="android:paddingBottom">10dp</item>
|
||||
</style>
|
||||
|
||||
<style name="ChipDeleteIconStyle" parent="@style/ChipDeleteIconBaseStyle">
|
||||
<item name="android:paddingLeft">@dimen/chip_icon_padding</item>
|
||||
</style>
|
||||
|
||||
<style name="ChipPermissionDismissIconStyle">
|
||||
<item name="android:id">@android:id/icon2</item>
|
||||
<item name="android:layout_width">wrap_content</item>
|
||||
<item name="android:layout_height">wrap_content</item>
|
||||
<item name="android:layout_gravity">center_vertical</item>
|
||||
<item name="android:background">?android:attr/selectableItemBackground</item>
|
||||
<item name="android:contentDescription">@android:string/cancel</item>
|
||||
<item name="android:padding">@dimen/chip_icon_padding</item>
|
||||
<item name="android:src">@drawable/chips_ic_close_24dp</item>
|
||||
</style>
|
||||
</resources>
|
||||
Reference in New Issue
Block a user