Also run formatter and address some deprecation warnings.
(cherry picked from commit 26a42ba9c01c670f60bedfca41bd72c99aa2a278)
# Conflicts:
# core/src/main/java/eu/kanade/tachiyomi/network/NetworkHelper.kt
Also add POST_NOTIFICATIONS permissions to make Android Studio stop complaining about it.
(cherry picked from commit b37b3767f3c55a74bede78d11300249ab419a4c7)
* Use 1.x preference abstraction
- Uses SharedPreferences compared to 1.x impl which uses DataStore but it breaks all settings screens currently
- Move PreferencesHelper to new PreferenceStore
- PreferencesHelper should be split into smaller preference stores and be in core or domain
- Remove flow preferences as new PreferenceStore handles changes for us
Co-authored-by: inorichi <3521738+inorichi@users.noreply.github.com>
* Fix PreferenceMutableState not updating
* Fix changes not emitting on first subscription
Co-authored-by: inorichi <3521738+inorichi@users.noreply.github.com>
(cherry picked from commit 0086743a5311c22fb8c07f596ab5de384862a68a)
# Conflicts:
# app/src/main/java/eu/kanade/domain/source/interactor/GetEnabledSources.kt
# app/src/main/java/eu/kanade/tachiyomi/App.kt
# app/src/main/java/eu/kanade/tachiyomi/AppModule.kt
# app/src/main/java/eu/kanade/tachiyomi/data/library/LibraryUpdateNotifier.kt
# app/src/main/java/eu/kanade/tachiyomi/data/preference/PreferencesHelper.kt
# app/src/main/java/eu/kanade/tachiyomi/ui/main/MainActivity.kt
# app/src/main/java/eu/kanade/tachiyomi/ui/reader/ReaderActivity.kt
# app/src/main/java/eu/kanade/tachiyomi/ui/reader/ReaderPresenter.kt
# app/src/main/java/eu/kanade/tachiyomi/ui/setting/SettingsAdvancedController.kt
# core/src/main/java/eu/kanade/tachiyomi/network/NetworkHelper.kt
Item list is not changed as currently there is no fitting Compose component to
replace the drag-drop behavior.
(cherry picked from commit fb9791f5976b9a877adeb656e2decfc4d77420ff)
# Conflicts:
# app/build.gradle.kts
# app/src/main/java/eu/kanade/tachiyomi/ui/download/DownloadHeaderItem.kt
* Fix stucked downloads when service not started
* Fix chapter download restart even if should be deleted
(cherry picked from commit a70b8486468ce8b57ae7a7ddc3ac845337789d45)
Pulling out some of the smaller changes that aren't related to the manga controller changes in #7244
(cherry picked from commit 7fdbf40cd23132915bd90cf623e4a69fb560dd26)
# Conflicts:
# app/src/main/java/eu/kanade/tachiyomi/data/library/LibraryUpdateService.kt
# app/src/main/java/eu/kanade/tachiyomi/ui/browse/migration/MigrationFlags.kt
# app/src/main/java/eu/kanade/tachiyomi/ui/browse/migration/search/SearchPresenter.kt
# app/src/main/java/eu/kanade/tachiyomi/ui/manga/chapter/ChaptersSettingsSheet.kt
* Fixes:
- spliiting fails when the page was already been split and processed before
- Moved CBZ logic a little earlier to avoid marking a download as complete before the CBZ compression was completed
* Added a single space for readablity
* Added 2 spaces for readability
* Moved the splitting logic to happen inside getOrDownloadImage()
* Minor cleanup
* - Improved error handling when splitting fails due to OOM exception caused by BitmapFactory.decodeFile. - Changed logic from throwing error to only notify to allow the download to complete even if splitting failed.
* reverted auto formatting changes
* removed an extra loop
* Merged to Upstream, cleaned up
* Removed unused localized string
* Minor cleanup
(cherry picked from commit f75d63274089c5a0cfe0e1afde8703017b521870)
* Fix download splitter potentially throwing OOM on huge images
Also move the splitting to ImageUtil
* Change variable name and logcat output
(cherry picked from commit 9f655e0d41a690752ac440d9bc8fb56188d4ef0c)
# Conflicts:
# app/src/main/java/eu/kanade/tachiyomi/util/system/ImageUtil.kt
- Remove some unused StorIO queries
- Clean up tall image splitting a bit (no need for creating an unscaled scaled bitmap copy, or tracking coordinates)
- Clean up library updater a bit (still needs a lot of work though)
# Conflicts:
# app/src/main/java/eu/kanade/tachiyomi/data/database/queries/ChapterQueries.kt
# app/src/main/java/eu/kanade/tachiyomi/data/database/queries/HistoryQueries.kt
# app/src/main/java/eu/kanade/tachiyomi/data/database/queries/MangaQueries.kt
# app/src/main/java/eu/kanade/tachiyomi/data/library/LibraryUpdateService.kt
# app/src/main/java/eu/kanade/tachiyomi/util/system/ImageUtil.kt
* Auto split long images to improve performance of reader
* Auto split long images to improve performance of reader - fixed the sorting
* Improved performance of splitting by getting rid of 1 extra loop
* Cleaned up code and moved the functionality to work during the downloading process (unsure how this affects download speed)
* Replaced the import .* with the actual used imports
* Fixes for Bugs discovered during my testing
* Fixed last split missing bug.
* Reordered the download progress to be updated before splitting instead of after to reflect more meaningful progress of download
* Reverted last commit since it had no effect
* Improved progress tracking when a download is paused then resumed.
* Implemented the recommended changes to enhance the feature.
* Apply suggestions from code review
Co-authored-by: arkon <arkon@users.noreply.github.com>
* Update app/src/main/res/values/strings.xml
Co-authored-by: arkon <arkon@users.noreply.github.com>
Co-authored-by: arkon <arkon@users.noreply.github.com>
* Notify user of error during a page download failure
* Included the manga title in the error notification
(cherry picked from commit 5763201307551bcd6a1f25ca81c8125f6f434c0a)