Skip to content

Commit

Permalink
resources: smoother mylibrary icons (fixes #4526) (#4631)
Browse files Browse the repository at this point in the history
Co-authored-by: dogi <[email protected]>
  • Loading branch information
deeppp15 and dogi authored Oct 15, 2024
1 parent 50c14c4 commit 77235ad
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 8 deletions.
4 changes: 2 additions & 2 deletions app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@ android {
applicationId "org.ole.planet.myplanet"
minSdkVersion 26
targetSdkVersion 34
versionCode 2025
versionName "0.20.25"
versionCode 2026
versionName "0.20.26"
ndkVersion '21.3.6528147'
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
vectorDrawables.useSupportLibrary = true
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -85,12 +85,11 @@ class AdapterResource(private val context: Context, private var libraryList: Lis
displayTagCloud(holder.rowLibraryBinding.flexboxDrawable, position)
holder.itemView.setOnClickListener { openLibrary(libraryList[position]) }
userModel = UserProfileDbHandler(context).userModel
holder.rowLibraryBinding.ivDownloaded.setImageResource(
if (libraryList[position]?.isResourceOffline() == true) {
R.drawable.ic_eye
} else {
R.drawable.ic_download
})
if (libraryList[position]?.isResourceOffline() == true) {
holder.rowLibraryBinding.ivDownloaded.visibility = View.INVISIBLE
} else {
holder.rowLibraryBinding.ivDownloaded.visibility = View.VISIBLE
}
holder.rowLibraryBinding.ivDownloaded.contentDescription =
if (libraryList[position]?.isResourceOffline() == true) {
context.getString(R.string.view)
Expand Down
1 change: 1 addition & 0 deletions app/src/main/res/layout/row_library.xml
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,7 @@
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:src="@drawable/ic_download"
android:layout_margin="@dimen/padding_small" />
<LinearLayout
android:id="@+id/ll_rating"
Expand Down

0 comments on commit 77235ad

Please sign in to comment.