[Android] Fix SecondaryActivity FAB not working

Nicolas Pomepuy git at videolan.org
Thu Jul 15 11:23:53 UTC 2021


vlc-android | branch: master | Nicolas Pomepuy <nicolas at videolabs.io> | Tue Jul 13 09:57:15 2021 +0200| [942783a53888a20c9a0313aaa686e77c816cf294] | committer: Nicolas Pomepuy

Fix SecondaryActivity FAB not working

Fixes #2094

> https://code.videolan.org/videolan/vlc-android/commit/942783a53888a20c9a0313aaa686e77c816cf294
---

 .../src/org/videolan/medialibrary/interfaces/media/Album.java         | 2 ++
 .../src/org/videolan/medialibrary/interfaces/media/Artist.java        | 4 ++++
 2 files changed, 6 insertions(+)

diff --git a/medialibrary/src/org/videolan/medialibrary/interfaces/media/Album.java b/medialibrary/src/org/videolan/medialibrary/interfaces/media/Album.java
index 192eaf479..09ca633f6 100644
--- a/medialibrary/src/org/videolan/medialibrary/interfaces/media/Album.java
+++ b/medialibrary/src/org/videolan/medialibrary/interfaces/media/Album.java
@@ -48,6 +48,7 @@ public abstract class Album extends MediaLibraryItem {
         this.albumArtistId = in.readLong();
         this.mTracksCount = in.readInt();
         this.duration = in.readLong();
+        this.mPresentTracksCount = in.readInt();
     }
 
     abstract public int getRealTracksCount();
@@ -129,5 +130,6 @@ public abstract class Album extends MediaLibraryItem {
         parcel.writeInt(mTracksCount);
         parcel.writeInt(mPresentTracksCount);
         parcel.writeLong(duration);
+        parcel.writeInt(mTracksCount);
     }
 }
diff --git a/medialibrary/src/org/videolan/medialibrary/interfaces/media/Artist.java b/medialibrary/src/org/videolan/medialibrary/interfaces/media/Artist.java
index 5ee2e7257..a552646a6 100644
--- a/medialibrary/src/org/videolan/medialibrary/interfaces/media/Artist.java
+++ b/medialibrary/src/org/videolan/medialibrary/interfaces/media/Artist.java
@@ -101,6 +101,8 @@ abstract public class Artist extends MediaLibraryItem {
         parcel.writeString(shortBio);
         parcel.writeString(artworkMrl);
         parcel.writeString(musicBrainzId);
+        parcel.writeInt(tracksCount);
+        parcel.writeInt(albumsCount);
     }
 
     public static Parcelable.Creator<Artist> CREATOR
@@ -121,5 +123,7 @@ abstract public class Artist extends MediaLibraryItem {
         this.shortBio = in.readString();
         this.artworkMrl = in.readString();
         this.musicBrainzId = in.readString();
+        this.tracksCount = in.readInt();
+        this.albumsCount = in.readInt();
     }
 }



More information about the Android mailing list