Commit Graph

297 Commits

Author SHA1 Message Date
hius07
7e6e8b3615 File browser: make the Plus menu user-patchable (#14197) 2025-08-23 09:28:29 +03:00
hius07
18621018fd File browser Plus: fix add/remove folder shortcut (#14032) 2025-07-07 08:17:41 +02:00
Artjoms Rizihs
89f7f5ac2d Change random document to open any random document, long-press for any unopened document (#13160) 2025-04-23 15:07:13 +02:00
hius07
7453c786de Selected files: more actions (#13510) 2025-04-07 12:56:37 +03:00
hius07
93ee0a1415 File browser: sort by metadata (#13437) 2025-03-24 19:12:46 +02:00
hius07
e8ccd922d8 Open previous file in last book folder (#13424) 2025-03-18 07:50:48 +02:00
hius07
b707d0f593 Menu widget: "Go to letter" everywhere (#13405) 2025-03-16 08:03:14 +02:00
hius07
f1726a9e5d FileSearcher: consistent results window (#13298) 2025-02-27 18:45:52 +02:00
hius07
70fcc90a3c Highlights: quicker Style and Note marker dialogs (#13223) 2025-02-12 09:14:03 +02:00
hius07
17504993ae CoverBrowser info_cache: move to core (#13018) 2025-01-18 10:08:18 +02:00
hius07
15f5dbef83 Reader: inspect zip file content to choose provider (#12902) 2024-12-19 09:41:19 +02:00
hius07
157c03c42d FileManager: Plus dialog button from CoverBrowser (#12857) 2024-12-07 09:18:18 +02:00
hius07
cd8ef3ceb5 FileManager, History, Collections: expose file dialog buttons (#12845) 2024-12-05 18:54:32 +02:00
hius07
c2d1099976 Profiles: more auto-exec triggers 2 (#12691) 2024-10-31 20:26:21 +02:00
hius07
97a7ebefb9 Text editor: rotate (#12658) 2024-10-29 20:49:43 +02:00
NiLuJe
7e52c15de2 FileManager: Handle the FlushSettings event (#12425)
It's used on Android when we're murdered by the task switcher, and when doing an OTA update.

Fix #12124
2024-08-29 11:28:16 +02:00
NiLuJe
9cd305177e FocusManager: Fix focus_flags check in moveFocusTo, and deal with the fallout (#12361)
* FocusManager: Fix `focus_flags` check in `moveFocusTo` (0 is truthy in Lua, can't do AND checks like in C ;).)
* FileManager+FileChooser: Pass our custom title bar directly to FileChooser (which also means we can now use FC's FocusManager layout directly).
* FileChooser/Menu: Get rid of the weird `outer_title_bar` hack, and simply take a `custom_title_bar` pointer to an actual TitleBar instance instead.
* FileManager/Menu/ListMenu/CoverMenu: Fix content height computations in `_recalculateDimen` (all the non-FM cases were including an old and now unused padding value, `self.header_padding`, leading to more blank space at the bottom than necessary, and, worse, leading to different item heights between FM views, possibly leading to unnecessary thumbnail scaling !)
* ButtonDialog: Proper focus management when the ButtonTable is wrapped in a ScrollableContainer.
* ConfigDialog: Implement a stupid workaround for a weird FocusManager issue when going back from `[⋮]` buttons.
* ConfigDialog: Don't move the visual focus in `update` (i.e., we use `NOT_FOCUS` now that it works as intended).
* DictQuickLookup: Ensures the `Menu` key bind does the exact same thing as the hamburger icon.
* DictQuickLookup: Ensure we refocus after having mangled the FocusManager layout (prevents an old focus highlight from lingering on the wrong button).
* FileChooser: Stop flagging it as no_title, because it is *never* without a title. (This behavior was a remnant of the previous FM-specific title bar hacks, which are no longer a thing).
* FileChooser: Stop calling `mergeTitleBarIntoLayout` twice in `updateItems`. We already call Menu's, which handles it. (Prevents the title bar from being added twice to the FocusManager layout).
* FocusManager: Relax the `Unfocus` checks in `moveFocusTo` to ensure we *always* unfocus something (if unfocusing was requested), even if we have to blast the whole widget tree to do so. This ensures callers that mangle self.layout can expect things to work after calling it regardless of how borked the current focus is.
* FocusManager: Allow passing `focus_flags` to `refocusWidget`, so that it can be forwarded to the internal `moveFocusTo` call.
* FocusManager: The above also allows us to enforce a default that ensures we do *not* send a Focus event on Touch devices, even if they have the hasDPad devcap. This essentially restores the previous/current behavior of not showing the visual feedback from such focus "events" sent programmatically, given the `focus_flags` check fix at the root of this PR ;).
* InputDialog: Fix numerous issues relating to double/ghost instances of both InputText and VirtualKeyboard, ensuring we only ever have a single InputText & VK instance live.
* InputDialog: Make sure every way we have of hiding the VK play nice together, especially when the `toggleKeyboard` button (shown w/ `add_nav_bar`) is at play. And doubly so when we're `fullscreen`, as hiding the VK implies resizing the widget.
* InputText: Make sure we're flagged as in-focus when tapping inside the text field.
* InputText: Make sure we don't attempt to show an already-visible VK in the custom `hasDPad` `onFocus` handler.
* Menu: Get rid of an old and no longer used (nor meaningful) hack in `onFocus` about the initial/programmatically-sent Focus event.
* Menu: Get rid of the unused `header_padding` field mentioned earlier in the FM/FC fixes.
* Menu: Use `FOCUS_ONLY_ON_NT` in the explicit `moveFocusTo` call in `updatePageInfo`, so as to keep the current behavior of not showing the visual feedback of this focus on Touch devices.
* Menu: Make sure *all* the `moveFocusTo` calls are gated behind the `hasDPad` devcap (previously, that was only the case for `updatePageInfo`, but not `mergeTitleBarIntoLayout` (which is called by `updateItems`).
* MultiInputDialog: Actively get rid of the InputText & VK instances from the base class's constructor that we do not use.
* MultiInputDialog: Ensure the FocusManager layout is *slightly* less broken (password fields can still be a bit weird, though).
* TextViewer: Get rid of the unfocus -> layout mangling -> refocus hack now that `refocusWidget` handles this case sanely.
* VirtualKeyboard: Notify our parent InputDialog when we get closed, so it can act accordingly (e.g., resize itself when `fullscreen`).
* ScrollableContainer: Implement the necessary machinery for focus handling inside ButtonDialog (specifically, when scrolling via PgUp/PgDwn).
* TextEditor: Given the above fixes, the plugin is no longer disabled on non-touch devices.
* ReaderBookMark: Make sure we request a full refresh when closing the "Edit note" dialog, as CRe highlights may extend past its dimensions, and if it's closed separately from VK, the refresh would have been limited to its own dimensions, leaving a neat InputDialog-sized hole in the highlights ;).
2024-08-25 19:34:31 +02:00
hius07
27e2efcbd2 Annotations: fix page numbers (#12324) 2024-08-13 22:18:24 +03:00
hius07
c46578aece BookInfo: rating, review (#12313) 2024-08-11 17:01:15 +03:00
David
2900eef276 Show/Hide Virtual keyboard and more keyboard shortcuts (#12162) 2024-08-07 18:09:40 +02:00
hius07
41191513c9 Filemanager: fix OpenWith without config (#12095)
Closes #12094.
2024-06-26 09:05:45 +02:00
David
9bff98034f ReaderHighlight: minor bug fixes (#12033)
Fixes bug reported in https://github.com/koreader/koreader/pull/11916#issuecomment-2170605117 and an issue where back button would not close widget in file manager.
2024-06-16 10:38:02 +02:00
hius07
585afda4be File searcher: group operations (#11980) 2024-06-06 11:44:03 +03:00
hius07
14519bc076 Dispatcher: add File browser actions 'Set display mode', 'Sort By' (#11921) 2024-06-01 10:33:14 +03:00
Frans de Jonge
8f2bd5420d Introduce Device:useDPadAsActionKeys() (#11900)
1. Non-Kindle-specific `hasFiveWay` behavior is changed to `hasDPad and useDPadAsActionKeys`. For now they remain Kindle-specific in practice, unless one sets `useDPadAsActionKeys = yes` in a user patch.
2. With that disambiguation out of the way, `hasFiveWay` itself is further disambiguated into `hasScreenKB` and `hasSymKey`, as per the actual property being used, rather than something that tends to correlate with it. (It needn't be Kindle-specific per se, but non-Kindle devices have equivalent shortcuts with for example `Shift`.)
  Running the emulator with `DISABLE_TOUCH=1` will set `hasSymKey = yes`, which can be tested with right shift.

Closes #11887.
2024-05-26 21:25:54 +02:00
hius07
076f77282b FileManager copy/move: do not paste to itself (#11878) 2024-05-26 08:19:45 +03:00
hius07
c6e6d72cf3 Collections: add collection mark to books (#11868) 2024-05-26 08:18:44 +03:00
SomeGuy
577c5d454f Non-touch DPad improvements (#11749)
Closes #11295.
2024-05-20 21:20:50 +02:00
yparitcher
59fb906921 NetworkListener: fix FM integration & properly gate behind hasWifiToggle (#11858) 2024-05-20 08:37:40 +02:00
hius07
db63db11b2 FileManager: safe initial path (#11774)
We do not like trailing slash in the path (except root).
Closes #11772.
2024-05-16 20:42:08 +02:00
hius07
6b0d97bf22 Multiple collections (#11693) 2024-05-01 09:01:59 +03:00
hius07
72a6fa1e64 FileManager: less lfs calls when selecting files (#11476) 2024-02-19 08:03:12 +02:00
hius07
5d4747c593 FileManager: less lfs calls (#11452)
Use item info provided by FileChooser.
Also fix showing PathChooser with invalid path,
and fix issue when opening non-supported files.
2024-02-17 01:17:59 +01:00
hius07
b8090c641c Minimize DocSettings:open() calls (#11437) 2024-02-07 10:35:52 +02:00
hius07
d94b819eb1 CoverBrowser: use bookinfo cache in Classic mode (#11404)
Getting bookinfo from the cache db is much faster than opening a book, let's use it in Classic mode too.

With fallback if no metadata available.
2024-01-26 22:01:45 +01:00
hius07
aabd6d7a26 File browser, Collection: improve group actions (#11178)
Maintain correct records in History and Favorites when moving/deleting folders or group of files.
Optimize Collection module to minimize storage requests.
2023-12-10 08:05:34 +02:00
hius07
88d6613fed Folder shortcuts: new markers, buttons (#11108)
Buttons to add/remove folder shortcut from Plus menu and from folder popup dialog.
A marker ("empty star") for folders with shortcuts.
2023-11-16 07:48:10 +02:00
hius07
4044c81a5a History: update on deleting a folder (#11090) 2023-11-10 07:50:39 +02:00
hius07
68aa209a6c Open with... improvement (#11056)
Allows associating filetypes with non-document providers (like ImageViewer or TextViewer) to "open" (view) these files by a tap in file browser.
2023-11-05 07:24:18 +02:00
hius07
b70f866656 DocSettings (again) (#11020)
Cleaning and optimizing Docsettings code.
2023-10-31 07:30:39 +02:00
hius07
6ccf19b99f History: update on renaming/moving a folder (#10999) 2023-10-13 07:54:35 +03:00
hius07
e577c79d95 File search, FileChooser and others (#10994) 2023-10-12 08:58:52 +03:00
François Gannaz
128302873d New menu option and filemanager filter to hide finished books #7158 (#10895)
* New menu option and filemanager filter to hide finished books #7158

The default behavior is to display the finished books (no change on
upgrade). For consistency with the two similar options, it represented
by a checkbox "Show hidden books" that is checked by default.

The implementation is straightforward, meaning that, when the option is
unchecked, each file will require a call to `filemanagerutil.getStatus`
that checks its status.

For clarity, the code uses the "finished books" expression because the
condition is relevant to the *book* metadata, while the other settings
are about *file* attributes.
2023-10-04 19:04:07 +03:00
hius07
e4ba8c7909 Custom metadata: event (#10869) 2023-09-06 09:41:10 +03:00
hius07
33467098dd filemanager: minor tweaks (#10821) 2023-08-18 08:11:43 +03:00
hius07
1544ca28af FileManager: truncate left in selected files list (#10783)
Truncate the path to view the filename in full. Closes #10760.
2023-08-10 17:01:07 +02:00
hius07
dee1c902ec ReaderUI: minor optimization (#10634) 2023-07-03 17:43:13 +03:00
hius07
54ab0a04f8 Archive viewer (#10584) 2023-06-21 07:32:24 +03:00
hius07
46933035c5 Open with: images (#10561) 2023-06-12 09:08:56 +03:00
hius07
01e6593dd4 File popup dialog buttons (#10537) 2023-06-08 08:27:52 +03:00