diff --git a/app/src/main/kotlin/com/simplemobiletools/filemanager/pro/fragments/StorageFragment.kt b/app/src/main/kotlin/com/simplemobiletools/filemanager/pro/fragments/StorageFragment.kt index b949772d..6d95d2d4 100644 --- a/app/src/main/kotlin/com/simplemobiletools/filemanager/pro/fragments/StorageFragment.kt +++ b/app/src/main/kotlin/com/simplemobiletools/filemanager/pro/fragments/StorageFragment.kt @@ -33,6 +33,9 @@ class StorageFragment(context: Context, attributeSet: AttributeSet) : MyViewPage override fun setupColors(textColor: Int, primaryColor: Int) { context.updateTextColors(storage_fragment) + + main_storage_usage_progressbar.setIndicatorColor(primaryColor) + main_storage_usage_progressbar.trackColor = primaryColor.adjustAlpha(0.3f) } private fun getMediaTypeSize(uri: Uri): Long { @@ -70,9 +73,9 @@ class StorageFragment(context: Context, attributeSet: AttributeSet) : MyViewPage val freeSpace = storageStatsManager.getFreeBytes(uuid) activity.runOnUiThread { - storage_usage_progressbar.max = (totalSpace / 1000).toInt() - storage_usage_progressbar.progress = ((totalSpace - freeSpace) / 1000).toInt() - storage_usage_progressbar.beVisible() + main_storage_usage_progressbar.max = (totalSpace / 1000000).toInt() + main_storage_usage_progressbar.progress = ((totalSpace - freeSpace) / 1000000).toInt() + main_storage_usage_progressbar.beVisible() free_space_value.text = freeSpace.formatSizeThousand() total_space.text = String.format(context.getString(R.string.total_storage), totalSpace.formatSizeThousand()) diff --git a/app/src/main/res/layout/storage_fragment.xml b/app/src/main/res/layout/storage_fragment.xml index 91474701..58ccdc15 100644 --- a/app/src/main/res/layout/storage_fragment.xml +++ b/app/src/main/res/layout/storage_fragment.xml @@ -27,7 +27,7 @@ android:visibility="gone" />