updating Commons with the new vector icons

This commit is contained in:
tibbi 2019-08-09 12:15:06 +02:00
parent 1cab76d0b5
commit b0d10e400f
8 changed files with 21 additions and 22 deletions

View File

@ -18,6 +18,7 @@ android {
versionName "6.3.3"
multiDexEnabled true
setProperty("archivesBaseName", "file-manager")
vectorDrawables.useSupportLibrary = true
}
signingConfigs {
@ -51,7 +52,7 @@ android {
}
dependencies {
implementation 'com.simplemobiletools:commons:5.15.19'
implementation 'com.simplemobiletools:commons:5.15.26'
implementation 'com.github.Stericson:RootTools:df729dcb13'
implementation 'com.github.Stericson:RootShell:1.6'
implementation 'com.alexvasilkov:gesture-views:2.5.2'

View File

@ -143,8 +143,8 @@ class ItemsAdapter(activity: SimpleActivity, var listItems: MutableList<ListItem
private fun getItemWithKey(key: Int): FileDirItem? = listItems.firstOrNull { it.path.hashCode() == key }
fun initDrawables() {
folderDrawable = activity.resources.getColoredDrawableWithColor(R.drawable.ic_folder, textColor)
fileDrawable = activity.resources.getColoredDrawableWithColor(R.drawable.ic_file, textColor)
folderDrawable = activity.resources.getColoredDrawableWithColor(R.drawable.ic_folder_vector, textColor)
fileDrawable = activity.resources.getColoredDrawableWithColor(R.drawable.ic_file_vector, textColor)
folderDrawable.alpha = 180
fileDrawable.alpha = 180
}
@ -285,7 +285,7 @@ class ItemsAdapter(activity: SimpleActivity, var listItems: MutableList<ListItem
drawable.findDrawableByLayerId(R.id.shortcut_folder_background).applyColorFilter(0)
drawable.setDrawableByLayerId(R.id.shortcut_folder_image, bitmap)
} catch (e: Exception) {
val fileIcon = activity.resources.getDrawable(R.drawable.ic_file)
val fileIcon = activity.resources.getDrawable(R.drawable.ic_file_vector)
drawable.setDrawableByLayerId(R.id.shortcut_folder_image, fileIcon)
}

View File

@ -21,7 +21,7 @@
android:layout_width="@dimen/normal_icon_size"
android:layout_height="@dimen/normal_icon_size"
android:padding="@dimen/medium_margin"
android:src="@drawable/ic_folder"/>
android:src="@drawable/ic_folder_vector"/>
<TextView
android:id="@+id/item_name"

View File

@ -63,9 +63,7 @@
android:layout_height="match_parent"
android:layout_below="@+id/breadcrumbs"
android:layout_alignParentEnd="true"
android:layout_alignParentRight="true"
android:paddingStart="@dimen/normal_margin"
android:paddingLeft="@dimen/normal_margin">
android:paddingStart="@dimen/normal_margin">
<include layout="@layout/fastscroller_handle_vertical"/>
@ -79,6 +77,6 @@
android:layout_height="wrap_content"
android:layout_gravity="bottom|end"
android:layout_margin="@dimen/activity_margin"
android:src="@drawable/ic_plus"/>
android:src="@drawable/ic_plus_vector"/>
</androidx.coordinatorlayout.widget.CoordinatorLayout>

View File

@ -3,7 +3,7 @@
xmlns:app="http://schemas.android.com/apk/res-auto">
<item
android:id="@+id/cab_confirm_selection"
android:icon="@drawable/ic_check"
android:icon="@drawable/ic_check_vector"
android:title="@string/confirm_selection"
app:showAsAction="ifRoom"/>
<item
@ -18,7 +18,7 @@
app:showAsAction="ifRoom"/>
<item
android:id="@+id/cab_share"
android:icon="@drawable/ic_share"
android:icon="@drawable/ic_share_vector"
android:title="@string/share"
app:showAsAction="ifRoom"/>
<item
@ -28,7 +28,7 @@
app:showAsAction="ifRoom"/>
<item
android:id="@+id/cab_unhide"
android:icon="@drawable/ic_unhide"
android:icon="@drawable/ic_unhide_vector"
android:title="@string/unhide"
app:showAsAction="ifRoom"/>
<item
@ -69,12 +69,12 @@
app:showAsAction="never"/>
<item
android:id="@+id/cab_select_all"
android:icon="@drawable/ic_select_all"
android:icon="@drawable/ic_select_all_vector"
android:title="@string/select_all"
app:showAsAction="ifRoom"/>
<item
android:id="@+id/cab_delete"
android:icon="@drawable/ic_delete"
android:icon="@drawable/ic_delete_vector"
android:title="@string/delete"
app:showAsAction="ifRoom"/>
</menu>

View File

@ -3,7 +3,7 @@
xmlns:app="http://schemas.android.com/apk/res-auto">
<item
android:id="@+id/search"
android:icon="@drawable/ic_search"
android:icon="@drawable/ic_search_vector"
android:title="@string/search"
app:actionViewClass="androidx.appcompat.widget.SearchView"
app:showAsAction="collapseActionView|ifRoom"/>
@ -14,22 +14,22 @@
app:showAsAction="ifRoom"/>
<item
android:id="@+id/go_to_favorite"
android:icon="@drawable/ic_open"
android:icon="@drawable/ic_folder_open_vector"
android:title="@string/go_to_favorite"
app:showAsAction="ifRoom"/>
<item
android:id="@+id/sort"
android:icon="@drawable/ic_sort"
android:icon="@drawable/ic_sort_vector"
android:title="@string/sort_by"
app:showAsAction="ifRoom"/>
<item
android:id="@+id/add_favorite"
android:icon="@drawable/ic_star_off"
android:icon="@drawable/ic_star_off_vector"
android:title="@string/add_to_favorites"
app:showAsAction="ifRoom"/>
<item
android:id="@+id/remove_favorite"
android:icon="@drawable/ic_star_on"
android:icon="@drawable/ic_star_on_vector"
android:title="@string/remove_from_favorites"
app:showAsAction="ifRoom"/>
<item

View File

@ -3,13 +3,13 @@
xmlns:app="http://schemas.android.com/apk/res-auto">
<item
android:id="@+id/menu_search"
android:icon="@drawable/ic_search"
android:icon="@drawable/ic_search_vector"
android:title="@string/search"
app:actionViewClass="androidx.appcompat.widget.SearchView"
app:showAsAction="collapseActionView|ifRoom"/>
<item
android:id="@+id/menu_save"
android:icon="@drawable/ic_save"
android:icon="@drawable/ic_save_vector"
android:title="@string/save_as"
app:showAsAction="ifRoom"/>
<item

View File

@ -3,7 +3,7 @@
xmlns:app="http://schemas.android.com/apk/res-auto">
<item
android:id="@+id/add_favorite"
android:icon="@drawable/ic_plus"
android:icon="@drawable/ic_plus_vector"
android:title="@string/add_favorites"
app:showAsAction="ifRoom"/>
</menu>