diff options
-rw-r--r-- | AndroidManifest.xml | 1 | ||||
-rwxr-xr-x | src/com/android/gallery3d/app/PhotoDataAdapter.java | 7 |
2 files changed, 7 insertions, 1 deletions
diff --git a/AndroidManifest.xml b/AndroidManifest.xml index 9ccac2dc7..4c9bf20cb 100644 --- a/AndroidManifest.xml +++ b/AndroidManifest.xml @@ -20,7 +20,6 @@ <manifest android:versionCode="40030" android:versionName="1.1.40030" xmlns:android="http://schemas.android.com/apk/res/android" - android:sharedUserId="android.uid.system" package="com.android.gallery3d"> <original-package android:name="com.android.gallery3d" /> diff --git a/src/com/android/gallery3d/app/PhotoDataAdapter.java b/src/com/android/gallery3d/app/PhotoDataAdapter.java index 7be48ebeb..c7dd48b1e 100755 --- a/src/com/android/gallery3d/app/PhotoDataAdapter.java +++ b/src/com/android/gallery3d/app/PhotoDataAdapter.java @@ -72,6 +72,7 @@ public class PhotoDataAdapter implements PhotoPage.Model { private static final int BIT_SCREEN_NAIL = 1; private static final int BIT_FULL_IMAGE = 2; + private static final long NOTIFY_DIRTY_WAIT_TIME = 10; // sImageFetchSeq is the fetching sequence for images. // We want to fetch the current screennail first (offset = 0), the next // screennail (offset = +1), then the previous screennail (offset = -1) etc. @@ -1207,6 +1208,12 @@ public class PhotoDataAdapter implements PhotoPage.Model { } public synchronized void notifyDirty() { + while (mDirty) { + try { + wait(NOTIFY_DIRTY_WAIT_TIME); + } catch (Exception ex) { + } + } mDirty = true; notifyAll(); } |