diff --git a/app/build.gradle b/app/build.gradle index fbec8a5fb..845c40f1e 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -95,7 +95,7 @@ dependencies { configurations.all { resolutionStrategy { - force 'com.github.seven332:glgallery:0f276c0' + force 'com.github.seven332:glgallery:f03e2be' force 'com.github.seven332:glview-image:4c744db' force 'com.github.seven332:image:bab9b11' diff --git a/app/src/main/java/com/hippo/ehviewer/ui/GalleryActivity.java b/app/src/main/java/com/hippo/ehviewer/ui/GalleryActivity.java index 19432379f..3cd92c3a9 100644 --- a/app/src/main/java/com/hippo/ehviewer/ui/GalleryActivity.java +++ b/app/src/main/java/com/hippo/ehviewer/ui/GalleryActivity.java @@ -622,6 +622,16 @@ public class GalleryActivity extends EhActivity implements SeekBar.OnSeekBarChan SimpleHandler.getInstance().post(task); } + @Override + public void onTapErrorText(int index) { + NotifyTask task = mNotifyTaskPool.pop(); + if (task == null) { + task = new NotifyTask(); + } + task.setData(NotifyTask.KEY_TAP_ERROR_TEXT, index); + SimpleHandler.getInstance().post(task); + } + @Override public void onLongPressPage(int index) { NotifyTask task = mNotifyTaskPool.pop(); @@ -1014,7 +1024,8 @@ public class GalleryActivity extends EhActivity implements SeekBar.OnSeekBarChan public static final int KEY_CURRENT_INDEX = 2; public static final int KEY_TAP_SLIDER_AREA = 3; public static final int KEY_TAP_MENU_AREA = 4; - public static final int KEY_LONG_PRESS_PAGE = 5; + public static final int KEY_TAP_ERROR_TEXT = 5; + public static final int KEY_LONG_PRESS_PAGE = 6; private int mKey; private int mValue; @@ -1047,6 +1058,12 @@ public class GalleryActivity extends EhActivity implements SeekBar.OnSeekBarChan } } + private void onTapErrorText(int index) { + if (mGalleryProvider != null) { + mGalleryProvider.forceRequest(index); + } + } + private void onLongPressPage(final int index) { showPageDialog(index); } @@ -1074,6 +1091,9 @@ public class GalleryActivity extends EhActivity implements SeekBar.OnSeekBarChan case KEY_TAP_SLIDER_AREA: onTapSliderArea(); break; + case KEY_TAP_ERROR_TEXT: + onTapErrorText(mValue); + break; case KEY_LONG_PRESS_PAGE: onLongPressPage(mValue); break;