diff options
author | Mangesh Ghiware <mghiware@google.com> | 2012-09-30 12:58:56 -0700 |
---|---|---|
committer | Mangesh Ghiware <mghiware@google.com> | 2012-09-30 12:58:56 -0700 |
commit | c1c67ea813421a6173d1dab2ad75c11b51c7976d (patch) | |
tree | 88b02d73d0a25b3e7b169978319ad0b69a846903 /src | |
parent | 0c3203f1789df3f8bd772dfd655e73b44636b629 (diff) | |
download | android_packages_apps_Gallery2-c1c67ea813421a6173d1dab2ad75c11b51c7976d.tar.gz android_packages_apps_Gallery2-c1c67ea813421a6173d1dab2ad75c11b51c7976d.tar.bz2 android_packages_apps_Gallery2-c1c67ea813421a6173d1dab2ad75c11b51c7976d.zip |
Remove video play icon and tap to play behavior for panorama.
Bug: 7258968
Per new UX design, there'll be a panorama viewer icon in the bottom
right instead (see b/7233446)
This is essentially a revert of Change-Id
I17fdb5d6bcab1f3997a1ab92fcf45e0309b394b3
Change-Id: Ib35c99cca4ee9b2422dd16f5ea3b931ad5f08f35
Diffstat (limited to 'src')
-rw-r--r-- | src/com/android/gallery3d/app/PhotoDataAdapter.java | 10 | ||||
-rw-r--r-- | src/com/android/gallery3d/app/PhotoPage.java | 4 | ||||
-rw-r--r-- | src/com/android/gallery3d/app/SinglePhotoDataAdapter.java | 5 | ||||
-rw-r--r-- | src/com/android/gallery3d/ui/PhotoView.java | 11 |
4 files changed, 2 insertions, 28 deletions
diff --git a/src/com/android/gallery3d/app/PhotoDataAdapter.java b/src/com/android/gallery3d/app/PhotoDataAdapter.java index 04518b580..66f2874f7 100644 --- a/src/com/android/gallery3d/app/PhotoDataAdapter.java +++ b/src/com/android/gallery3d/app/PhotoDataAdapter.java @@ -477,16 +477,6 @@ public class PhotoDataAdapter implements PhotoPage.Model { } @Override - public boolean usePanoramaViewer(int offset) { - MediaItem item = getItem(mCurrentIndex + offset); - boolean usePanoramaViewer = false; - if (item != null) { - usePanoramaViewer = item.usePanoramaViewer(); - } - return usePanoramaViewer; - } - - @Override public boolean isDeletable(int offset) { MediaItem item = getItem(mCurrentIndex + offset); return (item == null) diff --git a/src/com/android/gallery3d/app/PhotoPage.java b/src/com/android/gallery3d/app/PhotoPage.java index 3caa8689e..74dc7a95d 100644 --- a/src/com/android/gallery3d/app/PhotoPage.java +++ b/src/com/android/gallery3d/app/PhotoPage.java @@ -980,8 +980,6 @@ public class PhotoPage extends ActivityState implements int supported = item.getSupportedOperations(); boolean playVideo = (mSecureAlbum == null) && ((supported & MediaItem.SUPPORT_PLAY) != 0); - boolean viewPanorama = (mSecureAlbum == null) && - ((supported & MediaItem.SUPPORT_PANORAMA) != 0); boolean unlock = ((supported & MediaItem.SUPPORT_UNLOCK) != 0); boolean goBack = ((supported & MediaItem.SUPPORT_BACK) != 0); @@ -996,8 +994,6 @@ public class PhotoPage extends ActivityState implements if (playVideo) { playVideo(mActivity, item.getPlayUri(), item.getName()); - } else if (viewPanorama) { - LightCycleHelper.viewPanorama(mActivity, item.getContentUri()); } else if (goBack) { onBackPressed(); } else if (unlock) { diff --git a/src/com/android/gallery3d/app/SinglePhotoDataAdapter.java b/src/com/android/gallery3d/app/SinglePhotoDataAdapter.java index 1bfd64fc2..60817556d 100644 --- a/src/com/android/gallery3d/app/SinglePhotoDataAdapter.java +++ b/src/com/android/gallery3d/app/SinglePhotoDataAdapter.java @@ -217,11 +217,6 @@ public class SinglePhotoDataAdapter extends TileImageViewAdapter } @Override - public boolean usePanoramaViewer(int offset) { - return mItem.usePanoramaViewer(); - } - - @Override public boolean isDeletable(int offset) { return (mItem.getSupportedOperations() & MediaItem.SUPPORT_DELETE) != 0; } diff --git a/src/com/android/gallery3d/ui/PhotoView.java b/src/com/android/gallery3d/ui/PhotoView.java index 54ee07f24..303d302d2 100644 --- a/src/com/android/gallery3d/ui/PhotoView.java +++ b/src/com/android/gallery3d/ui/PhotoView.java @@ -79,9 +79,6 @@ public class PhotoView extends GLView { // Returns true if the item is the Panorama. public boolean isPanorama(int offset); - // Returns true if the item uses a special panorama viewer - public boolean usePanoramaViewer(int offset); - // Returns true if the item is a static image that represents camera // preview. public boolean isStaticCamera(int offset); @@ -572,7 +569,6 @@ public class PhotoView extends GLView { private int mRotation; private boolean mIsCamera; private boolean mIsPanorama; - private boolean mUsePanoramaViewer; private boolean mIsStaticCamera; private boolean mIsVideo; private boolean mIsDeletable; @@ -586,7 +582,6 @@ public class PhotoView extends GLView { mIsCamera = mModel.isCamera(0); mIsPanorama = mModel.isPanorama(0); - mUsePanoramaViewer = mModel.usePanoramaViewer(0); mIsStaticCamera = mModel.isStaticCamera(0); mIsVideo = mModel.isVideo(0); mIsDeletable = mModel.isDeletable(0); @@ -715,7 +710,7 @@ public class PhotoView extends GLView { // Draw the play video icon and the message. canvas.translate((int) (cx + 0.5f), (int) (cy + 0.5f)); int s = (int) (scale * Math.min(r.width(), r.height()) + 0.5f); - if (mIsVideo || mUsePanoramaViewer) drawVideoPlayIcon(canvas, s); + if (mIsVideo) drawVideoPlayIcon(canvas, s); if (mLoadingState == Model.LOADING_FAIL) { drawLoadingFailMessage(canvas); } @@ -757,7 +752,6 @@ public class PhotoView extends GLView { private ScreenNail mScreenNail; private boolean mIsCamera; private boolean mIsPanorama; - private boolean mUsePanoramaViewer; private boolean mIsStaticCamera; private boolean mIsVideo; private boolean mIsDeletable; @@ -772,7 +766,6 @@ public class PhotoView extends GLView { public void reload() { mIsCamera = mModel.isCamera(mIndex); mIsPanorama = mModel.isPanorama(mIndex); - mUsePanoramaViewer = mModel.usePanoramaViewer(mIndex); mIsStaticCamera = mModel.isStaticCamera(mIndex); mIsVideo = mModel.isVideo(mIndex); mIsDeletable = mModel.isDeletable(mIndex); @@ -838,7 +831,7 @@ public class PhotoView extends GLView { invalidate(); } int s = Math.min(drawW, drawH); - if (mIsVideo || mUsePanoramaViewer) drawVideoPlayIcon(canvas, s); + if (mIsVideo) drawVideoPlayIcon(canvas, s); if (mLoadingState == Model.LOADING_FAIL) { drawLoadingFailMessage(canvas); } |