1
0
Fork 0

For #225 - Adds icons for list items

master
Jeff Boek 2019-05-24 13:06:15 -07:00
parent 3006b21508
commit e9c7943fe8
6 changed files with 94 additions and 11 deletions

View File

@ -26,7 +26,7 @@ class DeleteBrowsingDataItem @JvmOverloads constructor(
attrs.let { attrs.let {
context.theme.obtainStyledAttributes( context.theme.obtainStyledAttributes(
it, it,
R.styleable.LibraryListItem, R.styleable.DeleteBrowsingDataItem,
0, 0 0, 0
).apply { ).apply {
try { try {

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -20,8 +20,9 @@
android:clickable="true" android:clickable="true"
android:contentDescription="@string/library_bookmarks" android:contentDescription="@string/library_bookmarks"
android:focusable="true" android:focusable="true"
app:listItemIcon="@drawable/bookmarks_circle_background_outline" app:deleteBrowsingDataItemIcon="@drawable/ic_tab_circle_background"
app:listItemTitle="@string/library_bookmarks" /> app:deleteBrowsingDataItemTitle="@string/preferences_delete_browsing_data_tabs_title"
app:deleteBrowsingDataItemSubtitle="@string/preferences_delete_browsing_data_tabs_subtitle" />
<org.mozilla.fenix.settings.DeleteBrowsingDataItem <org.mozilla.fenix.settings.DeleteBrowsingDataItem
android:id="@+id/browsingDataItem" android:id="@+id/browsingDataItem"
android:layout_width="match_parent" android:layout_width="match_parent"
@ -30,8 +31,9 @@
android:clickable="true" android:clickable="true"
android:contentDescription="@string/library_bookmarks" android:contentDescription="@string/library_bookmarks"
android:focusable="true" android:focusable="true"
app:listItemIcon="@drawable/bookmarks_circle_background_outline" app:deleteBrowsingDataItemIcon="@drawable/library_icon_history_circle_background"
app:listItemTitle="@string/library_bookmarks" /> app:deleteBrowsingDataItemTitle="@string/preferences_delete_browsing_data_browsing_data_title"
app:deleteBrowsingDataItemSubtitle="@string/preferences_delete_browsing_data_browsing_data_subtitle" />
<org.mozilla.fenix.settings.DeleteBrowsingDataItem <org.mozilla.fenix.settings.DeleteBrowsingDataItem
android:id="@+id/collectionsItem" android:id="@+id/collectionsItem"
android:layout_width="match_parent" android:layout_width="match_parent"
@ -40,11 +42,8 @@
android:clickable="true" android:clickable="true"
android:contentDescription="@string/library_bookmarks" android:contentDescription="@string/library_bookmarks"
android:focusable="true" android:focusable="true"
app:listItemIcon="@drawable/bookmarks_circle_background_outline" app:deleteBrowsingDataItemIcon="@drawable/ic_collections_circle_background"
app:listItemTitle="@string/library_bookmarks" /> app:deleteBrowsingDataItemTitle="@string/preferences_delete_browsing_data_collections_title"
app:deleteBrowsingDataItemSubtitle="@string/preferences_delete_browsing_data_collections_subtitle" />
</LinearLayout> </LinearLayout>
</ScrollView> </ScrollView>

View File

@ -102,6 +102,12 @@
<color name="library_reading_list_icon_background">#FCE98F</color> <color name="library_reading_list_icon_background">#FCE98F</color>
<color name="library_reading_list_icon">#8A201F</color> <color name="library_reading_list_icon">#8A201F</color>
<color name="tab_circle_icon_background">#FFDDBD</color>
<color name="tab_circle_icon_foreground">#7C1504</color>
<color name="collection_circle_icon_background">#D1FFEE</color>
<color name="collection_circle_icon_foreground">#084036</color>
<!-- Quick action buttons--> <!-- Quick action buttons-->
<color name="quick_action_share_icon">#174291</color> <color name="quick_action_share_icon">#174291</color>
<color name="quick_action_share_icon_background">#b9f0fd</color> <color name="quick_action_share_icon_background">#b9f0fd</color>

View File

@ -565,4 +565,18 @@
<!-- Title for the Delete browsing data preference --> <!-- Title for the Delete browsing data preference -->
<string name="preferences_delete_browsing_data">Delete browsing data</string> <string name="preferences_delete_browsing_data">Delete browsing data</string>
<!-- Title for the tabs item in Delete browsing data -->
<string name="preferences_delete_browsing_data_tabs_title">Open Tabs</string>
<!-- Subtitle for the tabs item in Delete browsing data, parameter will be replaced with the number of open tabs -->
<string name="preferences_delete_browsing_data_tabs_subtitle">%s tabs</string>
<!-- Title for the data and history items in Delete browsing data -->
<string name="preferences_delete_browsing_data_browsing_data_title">Browsing history and site data</string>
<!-- Subtitle for the data and history items item in Delete browsing data, parameter will be replaced with the
number of history items the user has -->
<string name="preferences_delete_browsing_data_browsing_data_subtitle">%s addresses</string>
<!-- Title for the collections item in Delete browsing data -->
<string name="preferences_delete_browsing_data_collections_title">Collections</string>
<!-- Subtitle for the collections item in Delete browsing data, parameter will be replaced with the
number of collections that will be deleted -->
<string name="preferences_delete_browsing_data_collections_subtitle">%s collections</string>
</resources> </resources>