* Replace deprecated rememberPlainTooltipPositionProvider
* Remove superfluous when branch
This when is marked as exhaustive.
* Replace deprecated LibrariesContainer call
AboutLibraries now wants us to produce the libraries ourselves.
* Replace deprecated ClipboardManager with Clipboard
Clipboard uses suspend functions, hence the coroutine scope addition.
* Use multi-dollar strs to simplify GraphQL queries
These have been available since Kotlin 2.1.
* Remove various redundant casts & conversions
- WebViewScreenContent: loadingState is in the LoadingState.Loading
branch, no need to cast at all
- Bangumi: username is not modified, make val
- Kavita: token is already a String
- PagerViewerAdapter: insertPageLastPage is already null-checked
- PagerViewerAdapter: use reified filterIsInstance
- ReaderViewModel: chapter IDs are already Longs
- CloudflareInterceptor: webview is smart-cast to non-null here
* Replace deprecated MenuAnchorType
Literally just a typealias for ExposedDropdownMenuAnchorType anyway.
* OptimizeNonSkippingGroups is enabled by default
* Suppress shadowing warning
This is explicitly intentional according to the KDocs.
* Migrate Context Receivers to Context Parameters
Requires changing the compiler arg, but that is part of the migration:
https://blog.jetbrains.com/kotlin/2025/04/update-on-context-parameters
Apparently, the only visible change is that names are required now.
"_" can be used for anonymous context parameters.
* Fix expression bodies with explicit return
Naming conflict resolved by aliasing.
From 2.4/2.5 onward, these will only be allowed with explicit return
types, or have to be turned into a block body. I opted for the latter
since the function is reasonably dense already.
see: https://youtrack.jetbrains.com/issue/KTLC-288
* Suppress deprecation of non-AutoMirrored icons
We use these arrows for navigation in the Upcoming screen.
I strongly doubt the AutoMirrored versions would make sense for our
use-case.
* Explicitly opt-in to new annotation default rules
affects the following annotated value-parameters:
- Preference.SliderPreference.steps (`@IntRange`)
- ReaderViewModel.State.brightnessOverlayValue (`@IntRange`)
- ReadingMode.iconRes (`@DrawableRes`)
- MigrationListScreenModel.Dialog.Progress.progress (`@FloatRange`)
see: https://youtrack.jetbrains.com/issue/KT-73255
see: https://github.com/Kotlin/KEEP/blob/change-defaulting-rule/proposals/annotation-target-in-properties.md
Warning message was the following:
This annotation is currently applied to the value parameter only, but in the future it will also be applied to field.
- To opt in to applying to both value parameter and field, add '-Xannotation-default-target=param-property' to your compiler arguments.
- To keep applying to the value parameter only, use the '@param:' annotation target.
(cherry picked from commit b543bc089a442c5e93b0fb6c83bc4037740b1eb5)
# Conflicts:
# app/src/main/java/eu/kanade/tachiyomi/ui/reader/viewer/pager/PagerViewerAdapter.kt
# core/common/src/main/kotlin/eu/kanade/tachiyomi/network/interceptor/CloudflareInterceptor.kt
# core/common/src/main/kotlin/mihon/core/common/archive/ArchiveInputStream.kt
There is no way to trigger mass migration at the moment. The functionality will be added in a follow up PR.
Co-authored-by: AntsyLich <59261191+AntsyLich@users.noreply.github.com>
(cherry picked from commit ee19050cc00b0a787af65b641624d07bb194e155)
* Add dependency com.journeyapps:zxing-android-embedded:4.3.0
* Add widget parameter to EditTextPreferenceWidget
* Add QR code scanner icon button to sync API key preference which launches a ScanContract
* Remove screenOrientation property from CaptureActivity manifest
* Allow scanning both normal and inverted codes
* store values and make code more concise
Co-authored-by: jobobby04 <jobobby04@users.noreply.github.com>
* Import local context
---------
Co-authored-by: jobobby04 <jobobby04@users.noreply.github.com>
* Remove detekt (mihonapp/mihon#1130)
Annoying. More annoying in this project.
(cherry picked from commit 777ae2461e1eb277a3aa0c998ff69e4f100387a1)
* Add spotless (with ktlint) (mihonapp/mihon#1136)
(cherry picked from commit 5ae8095ef1ed2ae9f98486f9148e933c77a28692)
* Address spotless lint errors (mihonapp/mihon#1138)
* Add spotless (with ktlint)
* Run spotlessApply
* screaming case screaming case screaming case
* Update PagerViewerAdapter.kt
* Update ReaderTransitionView.kt
(cherry picked from commit d6252ab7703d52ecf9f43de3ee36fd63e665a31f)
* Generate locales_config.xml in build dir
(cherry picked from commit ac41bffdc97b4cfed923de6b9e8e01cccf3eb6eb)
* Address more spotless lint errors in SY
* some more missed
* more missed
* still missing, not sure while it won't report error when running locally
* one more
* more
* more
* correct comment
---------
Co-authored-by: AntsyLich <59261191+AntsyLich@users.noreply.github.com>
* Refactor archive support with libarchive
* Refactor archive support with libarchive
* Revert string resource changs
* Only mark archive formats as supported
Comic book archives should not be compressed.
* Fixup
* Remove epub from archive format list
* Move to mihon package
* Format
* Cleanup
Co-authored-by: Shamicen <84282253+Shamicen@users.noreply.github.com>
(cherry picked from commit 239c38982c4fd55d4d86b37fd9c3c51c3b47d098)
* handle incorrect passwords
* lint
* fixed broken encryption detection + small tweaks
* Add safeguard to prevent ArchiveInputStream from being closed twice (#967)
* fix: Add safeguard to prevent ArchiveInputStream from being closed twice
* detekt
* lint: Make detekt happy
---------
Co-authored-by: AntsyLich <59261191+AntsyLich@users.noreply.github.com>
(cherry picked from commit e620665dda9eb5cc39f09e6087ea4f60a3cbe150)
* fixed ArchiveReaderMode CACHE_TO_DISK
* Added some missing SY --> comments
---------
Co-authored-by: FooIbar <118464521+fooibar@users.noreply.github.com>
Co-authored-by: Ahmad Ansori Palembani <46041660+null2264@users.noreply.github.com>
Also remove a leftover of scoped storage adaptation.
(cherry picked from commit f27ca3b1b2f92258c213bca6b27d8eff4c7363ad)
# Conflicts:
# app/src/main/java/eu/kanade/presentation/manga/components/MangaBottomActionMenu.kt
* Work in progress upcoming feature
* Checkpointing WIP upcoming feature
* Functional Upcoming Screen
* Rename UpdateCalendar to UpdateUpcoming
* Converted Strings to resources
* Cleanup
* Fixed detekt issues
* Removed Link icon per @AntsyLich's suggestion.
* Detekt
* Fixed Calendar display on wide form factor devices
* Added Key to upcoming lazycolumn
* Updated tablet mode UI to support two column view
* Updated header creation logic
* Updated header creation logic... again
* Moved stray string to resources
* Fixed PR Comments and query refactor
* Tweaks to query, refactored to flow, comments on calendar
* Switched to Date Formatter
* Cleaned up date formatter
* More Refactor work
* Updated Calendar to support localized week formats
* Fixed year format
* Refactored Header animation
* Moved upcoming FAQ
* Completed YearMonth Migration
* Replaced currentYearMonth with delegate
* Even more cleanup
* cleaned up alignment modifiers
* Click Handler and other refactors
* Removed Wrapped Content Height/Size/extra clips
* Huge Refactor for CalendarDay
* Another cleanup attempt
* Migrated to new mihon.feature.* module pattern
* changed access modifier
* A Bunch of changes from the next round of reviews
* Cleanups
* Cleanup 2
---------
Co-authored-by: AntsyLich <59261191+AntsyLich@users.noreply.github.com>
(cherry picked from commit 72222ad86d6fb328d20eead86c6357833d08c061)
# Conflicts:
# app/src/main/java/eu/kanade/domain/DomainModule.kt
# gradle/libs.versions.toml
* Migrated from Accompanist Webview to KevinZou WebView to preempt deprecation
* Removed old webview from version library
(cherry picked from commit ba9cfd867c028551c0b0740922c5130b14455c9f)