From 5de1c462d7236e06658f415d88e109f8b2ed16bc Mon Sep 17 00:00:00 2001 From: Robb <35880555+RobbWatershed@users.noreply.github.com> Date: Thu, 25 Jul 2019 21:09:20 +0200 Subject: [PATCH 01/11] Taps do not pass through the Hentoid logo of the left drawer anymore --- app/src/main/res/layout/fragment_navigation_drawer.xml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/app/src/main/res/layout/fragment_navigation_drawer.xml b/app/src/main/res/layout/fragment_navigation_drawer.xml index 26957aa227..f21a03a118 100644 --- a/app/src/main/res/layout/fragment_navigation_drawer.xml +++ b/app/src/main/res/layout/fragment_navigation_drawer.xml @@ -10,6 +10,8 @@ android:layout_width="match_parent" android:layout_height="@dimen/drawer_image_height" android:background="@drawable/nav_header_bg" + android:clickable="true" + android:focusable="true" android:padding="@dimen/drawer_header_icon_padding"> Date: Thu, 25 Jul 2019 21:12:22 +0200 Subject: [PATCH 02/11] Priorize notification over DB initialization --- .../me/devsaki/hentoid/services/ContentDownloadService.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/src/main/java/me/devsaki/hentoid/services/ContentDownloadService.java b/app/src/main/java/me/devsaki/hentoid/services/ContentDownloadService.java index d961cdf5bd..e323450005 100644 --- a/app/src/main/java/me/devsaki/hentoid/services/ContentDownloadService.java +++ b/app/src/main/java/me/devsaki/hentoid/services/ContentDownloadService.java @@ -87,8 +87,6 @@ public ContentDownloadService() { @Override public void onCreate() { super.onCreate(); - db = ObjectBoxDB.getInstance(this); - notificationManager = new ServiceNotificationManager(this, 1); notificationManager.cancel(); notificationManager.startForeground(new DownloadProgressNotification("Starting download", 0, 0)); @@ -98,6 +96,8 @@ public void onCreate() { EventBus.getDefault().register(this); + db = ObjectBoxDB.getInstance(this); + Timber.d("Download service created"); } From 6d1af7df419f6c7e302dd33a71aeaa332dc97eab Mon Sep 17 00:00:00 2001 From: Robb <35880555+RobbWatershed@users.noreply.github.com> Date: Thu, 25 Jul 2019 22:23:56 +0200 Subject: [PATCH 03/11] Fix update notifications and update package install (#342) --- app/src/main/AndroidManifest.xml | 2 ++ .../java/me/devsaki/hentoid/HentoidApp.java | 12 ++++++----- .../downloads/NavigationDrawerFragment.java | 21 +++++++++++-------- .../update/UpdateInstallNotification.java | 20 +++++++++++++++++- .../update/UpdateNotificationChannel.java | 10 ++++++--- .../hentoid/services/UpdateCheckService.java | 2 -- .../services/UpdateDownloadService.java | 2 -- .../me/devsaki/hentoid/util/FileHelper.java | 5 +++++ 8 files changed, 52 insertions(+), 22 deletions(-) diff --git a/app/src/main/AndroidManifest.xml b/app/src/main/AndroidManifest.xml index bc5c11b141..7f5e4f9437 100644 --- a/app/src/main/AndroidManifest.xml +++ b/app/src/main/AndroidManifest.xml @@ -10,6 +10,8 @@ + + = Build.VERSION_CODES.O) { startForegroundService(intent); @@ -118,10 +124,6 @@ public void onCreate() { startService(intent); } - // Clears all previous notifications - NotificationManager manager = (NotificationManager) instance.getSystemService(Context.NOTIFICATION_SERVICE); - if (manager != null) manager.cancelAll(); - if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.N_MR1) { ShortcutHelper.buildShortcuts(this); } diff --git a/app/src/main/java/me/devsaki/hentoid/fragments/downloads/NavigationDrawerFragment.java b/app/src/main/java/me/devsaki/hentoid/fragments/downloads/NavigationDrawerFragment.java index b7c7da34d2..f70b31dd1b 100644 --- a/app/src/main/java/me/devsaki/hentoid/fragments/downloads/NavigationDrawerFragment.java +++ b/app/src/main/java/me/devsaki/hentoid/fragments/downloads/NavigationDrawerFragment.java @@ -4,16 +4,17 @@ import android.content.Intent; import android.graphics.drawable.Drawable; import android.os.Bundle; +import android.view.LayoutInflater; +import android.view.View; +import android.view.ViewGroup; + import androidx.annotation.NonNull; import androidx.annotation.Nullable; import androidx.core.app.ActivityOptionsCompat; -import androidx.fragment.app.Fragment; import androidx.core.content.ContextCompat; +import androidx.fragment.app.Fragment; import androidx.recyclerview.widget.DividerItemDecoration; import androidx.recyclerview.widget.RecyclerView; -import android.view.LayoutInflater; -import android.view.View; -import android.view.ViewGroup; import com.annimon.stream.Stream; @@ -85,11 +86,13 @@ private boolean onItemClick(View view, int position) { } private void showFlagAboutItem() { - int aboutItemPos = DrawerItem.ABOUT.ordinal(); - DrawerItemFlex item = drawerAdapter.getItem(aboutItemPos); - if (item != null) { - item.setFlag(true); - drawerAdapter.notifyItemChanged(aboutItemPos); + if (drawerAdapter != null) { + int aboutItemPos = DrawerItem.ABOUT.ordinal(); + DrawerItemFlex item = drawerAdapter.getItem(aboutItemPos); + if (item != null) { + item.setFlag(true); + drawerAdapter.notifyItemChanged(aboutItemPos); + } } } diff --git a/app/src/main/java/me/devsaki/hentoid/notification/update/UpdateInstallNotification.java b/app/src/main/java/me/devsaki/hentoid/notification/update/UpdateInstallNotification.java index fe4a836bed..e9feee1d5d 100644 --- a/app/src/main/java/me/devsaki/hentoid/notification/update/UpdateInstallNotification.java +++ b/app/src/main/java/me/devsaki/hentoid/notification/update/UpdateInstallNotification.java @@ -4,14 +4,22 @@ import android.content.Context; import android.content.Intent; import android.net.Uri; +import android.os.Build; +import android.webkit.MimeTypeMap; + import androidx.annotation.NonNull; import androidx.core.app.NotificationCompat; +import androidx.core.content.FileProvider; + +import java.io.File; import me.devsaki.hentoid.R; +import me.devsaki.hentoid.util.FileHelper; import me.devsaki.hentoid.util.notification.Notification; public class UpdateInstallNotification implements Notification { + private final static String APK_MIMETYPE = MimeTypeMap.getSingleton().getMimeTypeFromExtension("apk"); private final Uri apkUri; public UpdateInstallNotification(Uri apkUri) { @@ -21,7 +29,17 @@ public UpdateInstallNotification(Uri apkUri) { @NonNull @Override public android.app.Notification onCreateNotification(Context context) { - Intent intent = new Intent(Intent.ACTION_INSTALL_PACKAGE, apkUri); + Intent intent; + if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.N) { + File f = new File(apkUri.getPath()); + Uri contentUri = FileProvider.getUriForFile(context, FileHelper.getFileProviderAuthority(), f); + intent = new Intent(Intent.ACTION_INSTALL_PACKAGE, contentUri); + intent.setFlags(Intent.FLAG_GRANT_READ_URI_PERMISSION); + } else { + intent = new Intent(Intent.ACTION_VIEW); + intent.setDataAndType(apkUri, APK_MIMETYPE); + intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK); + } PendingIntent pendingIntent = PendingIntent.getActivity(context, 0, intent, 0); diff --git a/app/src/main/java/me/devsaki/hentoid/notification/update/UpdateNotificationChannel.java b/app/src/main/java/me/devsaki/hentoid/notification/update/UpdateNotificationChannel.java index a41dcf2df0..9b8e13e83a 100644 --- a/app/src/main/java/me/devsaki/hentoid/notification/update/UpdateNotificationChannel.java +++ b/app/src/main/java/me/devsaki/hentoid/notification/update/UpdateNotificationChannel.java @@ -10,18 +10,22 @@ public class UpdateNotificationChannel { private static final String ID_OLD = "update"; - static final String ID = "update2"; + private static final String ID_OLD2 = "update2"; + static final String ID = "update3"; public static void init(Context context) { if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O) { - String name = "App updates"; - int importance = NotificationManager.IMPORTANCE_MIN; + String name = "Updates"; + int importance = NotificationManager.IMPORTANCE_DEFAULT; NotificationChannel channel = new NotificationChannel(ID, name, importance); + channel.setSound(null, null); + channel.setVibrationPattern(null); NotificationManager notificationManager = context.getSystemService(NotificationManager.class); // Mandatory; it is not possible to change the sound of an existing channel after its initial creation notificationManager.deleteNotificationChannel(ID_OLD); + notificationManager.deleteNotificationChannel(ID_OLD2); Objects.requireNonNull(notificationManager).createNotificationChannel(channel); } diff --git a/app/src/main/java/me/devsaki/hentoid/services/UpdateCheckService.java b/app/src/main/java/me/devsaki/hentoid/services/UpdateCheckService.java index b8a8d654c5..4ac82b2e41 100644 --- a/app/src/main/java/me/devsaki/hentoid/services/UpdateCheckService.java +++ b/app/src/main/java/me/devsaki/hentoid/services/UpdateCheckService.java @@ -59,13 +59,11 @@ public IBinder onBind(Intent intent) { public void onCreate() { notificationManager = new ServiceNotificationManager(this, NOTIFICATION_ID); notificationManager.startForeground(new UpdateCheckNotification()); - Timber.w("Service created"); } @Override public void onDestroy() { - notificationManager.cancel(); if (disposable != null) disposable.dispose(); Timber.w("Service destroyed"); } diff --git a/app/src/main/java/me/devsaki/hentoid/services/UpdateDownloadService.java b/app/src/main/java/me/devsaki/hentoid/services/UpdateDownloadService.java index 0bb5d8b423..f0ac886271 100644 --- a/app/src/main/java/me/devsaki/hentoid/services/UpdateDownloadService.java +++ b/app/src/main/java/me/devsaki/hentoid/services/UpdateDownloadService.java @@ -25,7 +25,6 @@ /** * Service responsible for downloading an update APK. - * Does not support targetSdkVersion > 23 due to exposure of "file:" URI * * @see UpdateCheckService */ @@ -68,7 +67,6 @@ public void onCreate() { @Override public void onDestroy() { running = false; - notificationManager.cancel(); downloadManager.release(); Timber.w("Service destroyed"); } diff --git a/app/src/main/java/me/devsaki/hentoid/util/FileHelper.java b/app/src/main/java/me/devsaki/hentoid/util/FileHelper.java index c7ac0b7b4a..a56d3fa401 100644 --- a/app/src/main/java/me/devsaki/hentoid/util/FileHelper.java +++ b/app/src/main/java/me/devsaki/hentoid/util/FileHelper.java @@ -597,6 +597,11 @@ public static void openFile(Context context, File aFile) { } } + public static String getFileProviderAuthority() + { + return AUTHORITY; + } + /** * Open built-in image viewer telling it to display the images of the given Content * From b78f71e24061aab70e10e9aef8b9e689d3fb0710 Mon Sep 17 00:00:00 2001 From: Robb <35880555+RobbWatershed@users.noreply.github.com> Date: Thu, 25 Jul 2019 22:32:35 +0200 Subject: [PATCH 04/11] Disable left/right tap for vertical mode --- .../hentoid/fragments/viewer/ImagePagerFragment.java | 10 +++++++--- .../me/devsaki/hentoid/widget/OnZoneTapListener.java | 6 +++--- 2 files changed, 10 insertions(+), 6 deletions(-) diff --git a/app/src/main/java/me/devsaki/hentoid/fragments/viewer/ImagePagerFragment.java b/app/src/main/java/me/devsaki/hentoid/fragments/viewer/ImagePagerFragment.java index c9f41f5906..ed82aac086 100644 --- a/app/src/main/java/me/devsaki/hentoid/fragments/viewer/ImagePagerFragment.java +++ b/app/src/main/java/me/devsaki/hentoid/fragments/viewer/ImagePagerFragment.java @@ -194,12 +194,16 @@ else if (1.0 != scale && pageSnapWidget.isPageSnapEnabled()) }); recyclerView.setLongTapListener(ev -> false); - OnZoneTapListener onZoneTapListener = new OnZoneTapListener(recyclerView) + OnZoneTapListener onHorizontalZoneTapListener = new OnZoneTapListener(recyclerView) .setOnLeftZoneTapListener(this::onLeftTap) .setOnRightZoneTapListener(this::onRightTap) .setOnMiddleZoneTapListener(this::onMiddleTap); - recyclerView.setTapListener(onZoneTapListener); // For paper roll mode (vertical) - adapter.setItemTouchListener(onZoneTapListener); // For independent images mode (horizontal) + + OnZoneTapListener onVerticalZoneTapListener = new OnZoneTapListener(recyclerView) + .setOnMiddleZoneTapListener(this::onMiddleTap); + + recyclerView.setTapListener(onVerticalZoneTapListener); // For paper roll mode (vertical) + adapter.setItemTouchListener(onHorizontalZoneTapListener); // For independent images mode (horizontal) adapter.setRecyclerView(recyclerView); diff --git a/app/src/main/java/me/devsaki/hentoid/widget/OnZoneTapListener.java b/app/src/main/java/me/devsaki/hentoid/widget/OnZoneTapListener.java index 0986a4365f..b8c54827b5 100644 --- a/app/src/main/java/me/devsaki/hentoid/widget/OnZoneTapListener.java +++ b/app/src/main/java/me/devsaki/hentoid/widget/OnZoneTapListener.java @@ -49,12 +49,12 @@ public OnZoneTapListener setOnMiddleZoneTapListener(Runnable onMiddleZoneTapList } public boolean onSingleTapConfirmedAction(MotionEvent e) { - if (e.getX() < pagerTapZoneWidth) { + if (e.getX() < pagerTapZoneWidth && onLeftZoneTapListener != null) { onLeftZoneTapListener.run(); - } else if (e.getX() > view.getWidth() - pagerTapZoneWidth) { + } else if (e.getX() > view.getWidth() - pagerTapZoneWidth && onRightZoneTapListener != null) { onRightZoneTapListener.run(); } else { - onMiddleZoneTapListener.run(); + if (onMiddleZoneTapListener != null) onMiddleZoneTapListener.run(); } return true; } From ae79a2cc4f88bd26bf84cea0a2a250a393d34214 Mon Sep 17 00:00:00 2001 From: Robb <35880555+RobbWatershed@users.noreply.github.com> Date: Thu, 25 Jul 2019 22:38:59 +0200 Subject: [PATCH 05/11] Fix downloads view moving back to top when exiting image viewer (#339) --- .../java/me/devsaki/hentoid/abstracts/DownloadsFragment.java | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/app/src/main/java/me/devsaki/hentoid/abstracts/DownloadsFragment.java b/app/src/main/java/me/devsaki/hentoid/abstracts/DownloadsFragment.java index d0a289cff6..06b4f8b14e 100644 --- a/app/src/main/java/me/devsaki/hentoid/abstracts/DownloadsFragment.java +++ b/app/src/main/java/me/devsaki/hentoid/abstracts/DownloadsFragment.java @@ -324,10 +324,7 @@ public void onDownloadEvent(DownloadEvent event) { } private void openBook(Content content) { - // The list order might change when viewing books when certain sort orders are activated - // "unread" status might also change - // => plan a refresh next time DownloadsFragment is called - plannedRefresh = true; + // TODO : plan an individual refresh of displayed books according to their new DB value (esp. read/unread) Bundle bundle = new Bundle(); searchManager.saveToBundle(bundle); int pageOffset = 0; From 4e2872b52e5435ce138ccef3422ca6e5b84605f2 Mon Sep 17 00:00:00 2001 From: Robb <35880555+RobbWatershed@users.noreply.github.com> Date: Thu, 25 Jul 2019 23:07:23 +0200 Subject: [PATCH 06/11] Fix display (and data) for old books that don't have page metadata (#343) --- .../viewmodels/ImageViewerViewModel.java | 36 +++++++++++++++---- 1 file changed, 29 insertions(+), 7 deletions(-) diff --git a/app/src/main/java/me/devsaki/hentoid/viewmodels/ImageViewerViewModel.java b/app/src/main/java/me/devsaki/hentoid/viewmodels/ImageViewerViewModel.java index d2082f79a5..236067e251 100644 --- a/app/src/main/java/me/devsaki/hentoid/viewmodels/ImageViewerViewModel.java +++ b/app/src/main/java/me/devsaki/hentoid/viewmodels/ImageViewerViewModel.java @@ -29,11 +29,13 @@ import io.reactivex.android.schedulers.AndroidSchedulers; import io.reactivex.disposables.CompositeDisposable; import io.reactivex.schedulers.Schedulers; +import me.devsaki.hentoid.HentoidApp; import me.devsaki.hentoid.R; import me.devsaki.hentoid.database.ObjectBoxCollectionAccessor; import me.devsaki.hentoid.database.ObjectBoxDB; import me.devsaki.hentoid.database.domains.Content; import me.devsaki.hentoid.database.domains.ImageFile; +import me.devsaki.hentoid.enums.StatusContent; import me.devsaki.hentoid.listener.PagedResultListener; import me.devsaki.hentoid.util.Consts; import me.devsaki.hentoid.util.FileHelper; @@ -148,8 +150,7 @@ public void onShuffleClick() { if (imgs != null) sortAndSetImages(imgs, isShuffled); } - private void sortAndSetImages(@Nonnull List imgs, boolean shuffle) - { + private void sortAndSetImages(@Nonnull List imgs, boolean shuffle) { if (shuffle) { Collections.shuffle(imgs); } else { @@ -245,10 +246,16 @@ private void processContent(Content theContent) { theContent.setLast(currentContentIndex == contentIds.size() - 1); // Load new content - File[] pictures = FileHelper.getPictureFilesFromContent(theContent); - if (pictures != null && pictures.length > 0 && theContent.getImageFiles() != null) { - List imageFiles = new ArrayList<>(theContent.getImageFiles()); - matchFilesToImageList(pictures, imageFiles); + File[] pictureFiles = FileHelper.getPictureFilesFromContent(theContent); + if (pictureFiles != null && pictureFiles.length > 0) { + List imageFiles; + if (null == theContent.getImageFiles() || theContent.getImageFiles().isEmpty()) { + imageFiles = new ArrayList<>(); + saveFilesToImageList(pictureFiles, imageFiles, theContent); + } else { + imageFiles = new ArrayList<>(theContent.getImageFiles()); + matchFilesToImageList(pictureFiles, imageFiles); + } setImages(imageFiles); if (Preferences.isViewerResumeLastLeft()) { @@ -272,7 +279,7 @@ private void processContent(Content theContent) { } } - private static void matchFilesToImageList(File[] files, List images) { + private static void matchFilesToImageList(File[] files, @Nonnull List images) { int i = 0; while (i < images.size()) { boolean matchFound = false; @@ -291,6 +298,21 @@ private static void matchFilesToImageList(File[] files, List images) } } + private static void saveFilesToImageList(File[] files, @Nonnull List images, @Nonnull Content content) { + int order = 0; + // Sort files by name alpha + List fileList = Stream.of(files).sortBy(File::getName).collect(toList()); + for (File f : fileList) { + order++; + ImageFile img = new ImageFile(); + String name = FileHelper.getFileNameWithoutExtension(f.getName()); + img.setName(name).setOrder(order).setUrl("").setStatus(StatusContent.DOWNLOADED).setAbsolutePath(f.getAbsolutePath()); + images.add(img); + } + content.addImageFiles(images); + ObjectBoxDB.getInstance(HentoidApp.getAppContext()).insertContent(content); + } + @WorkerThread @Nullable private static Content postLoadProcessing(@Nonnull Context context, @Nonnull Content content) { From 448aa0f78590a8f93f4602f2e4ed793b69d424d4 Mon Sep 17 00:00:00 2001 From: Robb <35880555+RobbWatershed@users.noreply.github.com> Date: Thu, 25 Jul 2019 23:18:14 +0200 Subject: [PATCH 07/11] Fix progress indicator staying on screen when download fails after its preparation (e.g. no network) --- .../main/java/me/devsaki/hentoid/fragments/QueueFragment.java | 1 + 1 file changed, 1 insertion(+) diff --git a/app/src/main/java/me/devsaki/hentoid/fragments/QueueFragment.java b/app/src/main/java/me/devsaki/hentoid/fragments/QueueFragment.java index 55a0fc0115..c2c96872fa 100644 --- a/app/src/main/java/me/devsaki/hentoid/fragments/QueueFragment.java +++ b/app/src/main/java/me/devsaki/hentoid/fragments/QueueFragment.java @@ -129,6 +129,7 @@ public void onDownloadEvent(DownloadEvent event) { break; case DownloadEvent.EV_COMPLETE: mAdapter.removeFromQueue(event.content); + dlPreparationProgressBar.setVisibility(View.GONE); if (0 == mAdapter.getCount()) btnStats.setVisibility(View.GONE); update(event.eventType); break; From 378e3ed7c83e854164fa4a137968e78dc3219feb Mon Sep 17 00:00:00 2001 From: Robb <35880555+RobbWatershed@users.noreply.github.com> Date: Thu, 25 Jul 2019 23:39:46 +0200 Subject: [PATCH 08/11] CLEAR button clears displayed search query --- .../java/me/devsaki/hentoid/abstracts/DownloadsFragment.java | 1 + 1 file changed, 1 insertion(+) diff --git a/app/src/main/java/me/devsaki/hentoid/abstracts/DownloadsFragment.java b/app/src/main/java/me/devsaki/hentoid/abstracts/DownloadsFragment.java index 06b4f8b14e..c0cf7f4358 100644 --- a/app/src/main/java/me/devsaki/hentoid/abstracts/DownloadsFragment.java +++ b/app/src/main/java/me/devsaki/hentoid/abstracts/DownloadsFragment.java @@ -557,6 +557,7 @@ protected void attachOnClickListeners(View rootView) { filterClearButton.setOnClickListener(v -> { setQuery(""); + mainSearchView.setQuery("", false); searchManager.clearSelectedSearchTags(); filterBar.setVisibility(View.GONE); searchLibrary(); From f3b7c64abb9ccab175136abcc87b56f8de0f1d2a Mon Sep 17 00:00:00 2001 From: Robb <35880555+RobbWatershed@users.noreply.github.com> Date: Thu, 25 Jul 2019 23:47:06 +0200 Subject: [PATCH 09/11] Attempt to fix #346 --- .../me/devsaki/hentoid/fragments/viewer/ImagePagerFragment.java | 1 + 1 file changed, 1 insertion(+) diff --git a/app/src/main/java/me/devsaki/hentoid/fragments/viewer/ImagePagerFragment.java b/app/src/main/java/me/devsaki/hentoid/fragments/viewer/ImagePagerFragment.java index ed82aac086..aee290326e 100644 --- a/app/src/main/java/me/devsaki/hentoid/fragments/viewer/ImagePagerFragment.java +++ b/app/src/main/java/me/devsaki/hentoid/fragments/viewer/ImagePagerFragment.java @@ -137,6 +137,7 @@ public void onSaveInstanceState(@NonNull Bundle outState) { super.onSaveInstanceState(outState); outState.putInt(KEY_HUD_VISIBLE, controlsOverlay.getVisibility()); outState.putBoolean(KEY_GALLERY_SHOWN, hasGalleryBeenShown); + viewModel.setStartingIndex(imageIndex); // Memorize the current page viewModel.onSaveState(outState); } From e1938a3744894de7a3089e5fb6de3733874fe1d8 Mon Sep 17 00:00:00 2001 From: Robb <35880555+RobbWatershed@users.noreply.github.com> Date: Fri, 26 Jul 2019 00:35:04 +0200 Subject: [PATCH 10/11] Consistent display of the page number controls with the current image list --- .../me/devsaki/hentoid/fragments/viewer/ImagePagerFragment.java | 1 + 1 file changed, 1 insertion(+) diff --git a/app/src/main/java/me/devsaki/hentoid/fragments/viewer/ImagePagerFragment.java b/app/src/main/java/me/devsaki/hentoid/fragments/viewer/ImagePagerFragment.java index aee290326e..0752783489 100644 --- a/app/src/main/java/me/devsaki/hentoid/fragments/viewer/ImagePagerFragment.java +++ b/app/src/main/java/me/devsaki/hentoid/fragments/viewer/ImagePagerFragment.java @@ -391,6 +391,7 @@ private void onImagesChanged(List images) { maxPosition = images.size() - 1; seekBar.setMax(maxPosition); + updatePageDisplay(); } /** From 5e825c4747dd818aefc736217e404176080632df Mon Sep 17 00:00:00 2001 From: Robb <35880555+RobbWatershed@users.noreply.github.com> Date: Fri, 26 Jul 2019 00:48:42 +0200 Subject: [PATCH 11/11] v1.8.5 --- app/build.gradle | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/build.gradle b/app/build.gradle index 535370a2ec..636188ec19 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -19,7 +19,7 @@ android { //noinspection ExpiringTargetSdkVersion targetSdkVersion 28 versionCode 110 // is updated automatically by BitRise; only used when building locally - versionName '1.8.4' + versionName '1.8.5' def fkToken = '\"' + (System.getenv("FK_TOKEN")?: "")+'\"' def includeObjectBoxBrowser = System.getenv("INCLUDE_OBJECTBOX_BROWSER")?:"false"