Commit graph

1761 commits

Author SHA1 Message Date
Moustapha Kodjo Amadou
b53e869258 feat: add DNS-over-HTTPS (DoH) support (experimental) 2026-01-20 14:38:46 +01:00
Moustapha Kodjo Amadou
b6fc3edd23 Update 2026-01-16 15:58:07 +01:00
NBA2K1
8b1f7fc581 Add service disposal and lifecycle cleanup
This commit improves memory management, reduces redundant interpreter
instantiation, and standardizes service usage patterns.

- Add `dispose()` to `ExtensionService` interface and implement it across
  Dart, JS, LNReader, and Mihon services.
- Replace repeated interpreter creation in `DartExtensionService` with a
  persistent `_interpreter` instance initialized once in the constructor.
- Add disposal logic for JS DOM selector and Cheerio instances to prevent
  memory leaks.
- Introduce `withExtensionService()` helper to ensure services are always
  disposed after use.
- Update call sites across the codebase to use `withExtensionService()`
  or manual try/finally disposal.
- Improve isolate service message handling by extracting `responsePort`
  earlier.
- Ensure safer defaults (e.g., returning empty lists, const lists) when
  service calls fail.
2026-01-13 01:11:19 +01:00
GitHub Action
89dd50dc25 source update: v0.7.0 2026-01-09 11:15:37 +00:00
Moustapha Kodjo Amadou
1f3fe65945 v0.7.0 2026-01-09 11:55:13 +01:00
Moustapha Kodjo Amadou
88f8d7b4be - 2026-01-09 11:54:10 +01:00
Moustapha Kodjo Amadou
83b7d31e0a Increase isolate pool size to enhance concurrent download capabilities 2026-01-09 11:48:23 +01:00
NBA2K1
267f2d12df dedupe page and video lists using LinkedHashSet
- Replace list→set→list conversions with LinkedHashSet for stable ordering
- Ensure PageUrl uniqueness based on URL
- Ensure Video uniqueness based on url + originalUrl
- Add null‑safety checks when building PageUrl and Video objects
- Improve readability and reduce unnecessary allocations
2026-01-08 23:52:31 +01:00
NBA2K1
ffda1ce1dc add locale caching, and improve WebView cleanup
- Added _initializedLocales to prevent repeated locale initialization
- Improved evaluateJavascriptViaWebview with safer lifecycle handling (try/finally + null checks)
- Minor cleanup and consistency improvements across MBridge utilities
2026-01-08 23:43:40 +01:00
NBA2K1
f4f344ce29 add log buffer and replace direct list mutation
- Introduce _addLog() helper to manage log insertion
- Enforce a maximum log history of 200 entries to prevent unbounded memory growth
- Replace direct _logsNotifier.value.add(event) with safe, immutable-style list update
- Improve log handling consistency and avoid mutating notifier state in place
2026-01-08 22:48:34 +01:00
NBA2K1
09684a2641 improve isolate lifecycle and add timeouts
- Add StreamSubscription to manage ReceivePort listener lifecycle
- Introduce handshake timeout when waiting for isolate SendPort to prevent hangs
- Add response timeout in get<T>() to avoid indefinitely waiting for isolate replies
- Replace direct ReceivePort.listen with tracked subscription for safer cleanup
- Improve error handling for invalid or missing isolate responses
- Strengthen isolate startup reliability and shutdown consistency
2026-01-08 22:41:14 +01:00
NBA2K1
8444e308ad Fix Riverpod lifecycle error
By moving provider-dependent init to didChangeDependencies. (dependOnInheritedWidget)
2026-01-08 21:47:51 +01:00
NBA2K1
ee2d42fa4b categories screen clean up 2026-01-08 18:56:23 +01:00
Moustapha Kodjo Amadou
40fdfc2592 v0.6.95 2026-01-08 14:36:38 +01:00
Moustapha Kodjo Amadou
74b194602c update dependencies & update riverpod provider declarations 2026-01-08 14:27:08 +01:00
Moustapha Kodjo Amadou
b9f9a8398f Refactor download management with shared isolate pool and optimize concurrent downloads 2026-01-08 13:01:15 +01:00
Moustapha Kodjo Amadou
9458ae120b fix #637 2026-01-07 13:07:55 +01:00
Moustapha Kodjo Amadou
701a696820 Enhance category management with animation 2026-01-05 12:38:30 +01:00
Moustapha Kodjo Amadou
db24951673 Add localization 2026-01-05 12:15:14 +01:00
Moustapha Kodjo Amadou
7c4c8d8a20 + 2026-01-05 12:12:56 +01:00
Moustapha Kodjo Amadou
6b70fff6cc
Merge pull request #638 from 686udjie/main
add a force landscapre mode on mobile
2026-01-05 12:11:33 +01:00
Moustapha Kodjo Amadou
2365e28a1a
Merge pull request #636 from NBA2K1/main
Fix "Show extensions" Button AND Fix category rearrange bug AND hide ItemType from calendar
2026-01-05 11:55:33 +01:00
NBA2K1
922582b270 Fix share params to avoid Text file
- avoids extra text file
- simplify RenderBox lookup
2026-01-04 20:25:13 +01:00
686udjie
79ee4b4fc8 add a force landscapre mode on mobile 2026-01-01 19:48:57 +02:00
NBA2K1
c8328fa347 improve performance of helper method
- compare integers instead of Strings
- cache results per day
2025-12-30 02:44:45 +01:00
NBA2K1
a63f0d67bd Extract helper methods
for better readability
2025-12-30 02:41:47 +01:00
NBA2K1
2c92d74a03 Fix invalid selection
Don't show manga calendar if manga is hidden.
2025-12-30 02:04:06 +01:00
NBA2K1
a2a10a799d Hide items in Calendar
When the user has hidden Manga or Anime or Novel, hide the buttons in the calendar.
2025-12-30 01:37:30 +01:00
NBA2K1
ba77c5baea Reduce Code Duplication
And add comments
2025-12-30 01:15:36 +01:00
NBA2K1
4e2d8b0038 Fix category rearrange bug
When rearranging categories in the Manga library, all categories in Anime and Novel were being deleted.
2025-12-30 00:27:49 +01:00
NBA2K1
821cbfa0dd Make function async
_updateCategoriesOrder() is now async
2025-12-29 23:38:17 +01:00
NBA2K1
4fb9f0a9df remove redundant things 2025-12-29 23:20:08 +01:00
NBA2K1
1ac605e30a Use the localized extension 2025-12-29 23:20:08 +01:00
NBA2K1
9efd76581f Group related functions using an extension
- new file item_type_filters.dart for the hiddenItemTypes function.
- reduces code duplication in statistics_screen, categories_screen and base_library_tab_screen
2025-12-29 23:19:31 +01:00
NBA2K1
7664e38cfd Fix "Show extensions" Button
The "Show extensions" Button was not working properly when categories were hidden.
An Exception would throw:
```
_AssertionError ('package:flutter/src/material/tab_controller.dart': Failed assertion: line 202 pos 12: 'value >= 0 && (value < length || length == 0)': is not true.)
```
And jump to the end of the tab list regardless of where you clicked the button.
2025-12-29 05:02:43 +01:00
NBA2K1
42f1dcff92 Reduce Code Duplication
- Extract localizedItemType() from `base_library_tab_screen.dart`
- Add localizedSources() and localizedExtensions() for browse_screen.dart
- Reduce if-statements in statistics_screen.dart
- Reduce if-statements in categories_screen.dart
- Reduce if-statements in browse_screen.dart
2025-12-29 04:59:06 +01:00
NBA2K1
86fb19ecb2 Refactor tabbed screens into base class
Reduce duplication
2025-12-29 03:28:04 +01:00
NBA2K1
bdcd28488e Same with history_screen.dart
- remove hideItems parameter
- Make TabBar and TabBarView cleaner
2025-12-29 01:58:49 +01:00
NBA2K1
30e6d50210 Make TabBar and TabBarView cleaner
Use the _visibleTabTypes list instead of the repeated if-statements.
2025-12-29 01:34:05 +01:00
NBA2K1
66b508d65d Cleanup
- Change _tabList String-list to be a list of ItemType
- Change its name to _visibleTabTypes
- Use that list in getCurrentItemType(), instead of creating a new list
2025-12-29 01:13:26 +01:00
NBA2K1
004885d557 Return library updater if library empty 2025-12-29 01:00:01 +01:00
NBA2K1
e463cce61a Make getCurrentItemType() readable
The previous version was just unnecessarily complicated, hard to read.
New version is very easy to read.
2025-12-29 00:38:33 +01:00
NBA2K1
67a83c0e6a Cleanup
Use getCurrentItemType() method to determine the ItemType of the current tab instead of the conditional with `_tabBarController.index`, which doesn't take into account that there could be hidden tabs.
2025-12-28 23:42:45 +01:00
NBA2K1
da566d3d0b remove hideItems parameter
No need to pass hideItems down, they all can use the top hideItems variable. It's never changed.
2025-12-28 23:16:29 +01:00
NBA2K1
c911594e73 Add logging and detailed botToast, remove doWhile
- Use the logger to log failed updates

- After the update-botToast another botToast is being spawned to show exactly which manga(s) couldn't be updated.

- Remove the doWhile loop because it is unnecessary. The condition of mangaList.length == numbers is always true, meaning it only runs once.
2025-12-28 23:08:54 +01:00
NBA2K1
9bd8a62d31 Reduce Code Duplication
Extract the `_updateLibrary()` function from `updates_screen.dart` and `library_screen.dart` to a top-level function in `libray_updater.dart`.
2025-12-28 22:59:44 +01:00
GitHub Action
53cd2101f4 source update: v0.6.90 2025-12-28 03:21:33 +00:00
Moustapha Kodjo Amadou
4e18e18489 Update 2025-12-24 20:26:51 +01:00
Moustapha Kodjo Amadou
481deb1344 v0.6.90 2025-12-23 19:20:00 +01:00
Moustapha Kodjo Amadou
344533aeb1 fix: show chanded source preference for mihon source 2025-12-23 19:18:18 +01:00