diff options
author | Ray Chen <raychen@google.com> | 2011-11-03 17:51:38 +0800 |
---|---|---|
committer | Ray Chen <raychen@google.com> | 2011-11-11 19:21:47 +0800 |
commit | 51f0610147218ee72da9322ee9c10424f33a4227 (patch) | |
tree | df8d9cbcb1f1a3016f48d354226d0852b2799e64 /src/com/android/gallery3d/data/ClusterAlbum.java | |
parent | 89e853d8b714fcef0a864265bb4ddfdd50f07e43 (diff) | |
download | android_packages_apps_Snap-51f0610147218ee72da9322ee9c10424f33a4227.tar.gz android_packages_apps_Snap-51f0610147218ee72da9322ee9c10424f33a4227.tar.bz2 android_packages_apps_Snap-51f0610147218ee72da9322ee9c10424f33a4227.zip |
Fix 5481444 Face clustering should use PWA profile shot instead of random photo
Change-Id: Ie4e3f9ae19431ab5b36d216cd7f4c626de503bbf
Diffstat (limited to 'src/com/android/gallery3d/data/ClusterAlbum.java')
-rw-r--r-- | src/com/android/gallery3d/data/ClusterAlbum.java | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/com/android/gallery3d/data/ClusterAlbum.java b/src/com/android/gallery3d/data/ClusterAlbum.java index 32f902301..569e5a4b3 100644 --- a/src/com/android/gallery3d/data/ClusterAlbum.java +++ b/src/com/android/gallery3d/data/ClusterAlbum.java @@ -24,6 +24,7 @@ public class ClusterAlbum extends MediaSet implements ContentListener { private String mName = ""; private DataManager mDataManager; private MediaSet mClusterAlbumSet; + private MediaItem mCover; public ClusterAlbum(Path path, DataManager dataManager, MediaSet clusterAlbumSet) { @@ -33,6 +34,15 @@ public class ClusterAlbum extends MediaSet implements ContentListener { mClusterAlbumSet.addContentListener(this); } + public void setCoverMediaItem(MediaItem cover) { + mCover = cover; + } + + @Override + public MediaItem getCoverMediaItem() { + return mCover != null ? mCover : super.getCoverMediaItem(); + } + void setMediaItems(ArrayList<Path> paths) { mPaths = paths; } |