hius07
hius07
(after reading the `UIManager:sendEvent` code) This issue can be fixed by setting FM and Reader `is_always_active = true`.
> With broadcastEvent all registered handlers will fire and the event wont be swallowed by the first handler, so some events may have surprising side efects. I think that any...
ToC is the top widget, `Menu:onNextPage` stops propagation. https://github.com/koreader/koreader/blob/c2d41f2c41df6e742a188d62eb8abf5a512c86e1/frontend/ui/uimanager.lua#L896-L898
The example with ToC (and my reply) are not correct. ToC turns pages not via sendEvent. A tap calls onNextPage directly, key_event calls handleEvent. `is_always_active` affects sendEvent only.
History doesn't use file attributes, it saves the last read date in koreader/history.lua.
"folder path contains" accepts comma separated multiple strings. "folder path is equal" one string only.
TL;DR: the event sent by Dispatcher is handled when closing Reader for FM and is not handled when switching documents. In details: a profile is triggered by the `CloseDocument` event....
To reproduce quickly: create a profile with one action: Set night mode on. Set auto-exec the profile: on document closing - always. Set night mode off - open a document...
History is closed at the moment, the difference is in ReaderUi: `onHome` or `switchDocument`.
Got it. When we call `onHome()` (i.e. close Reader), the top widget to handle the event fired by the profile, is FM, and it handles the event well. When we...