Expand description
The time running, in the system’s notifications (docs/tasks.md): while a
focus session runs, one notification says its task and since when, with
Pause (Go on, while paused) and Stop, which do what the focus window’s own
buttons do. It follows the session from wherever it changes: the window,
the notification itself, another device (the sharing brings
time/running.toml), the command line. On a computer, the desktop’s
(sioul_sync::notify::ongoing), while Sioul runs. On a phone, Android’s
own, with a chronometer (android/main.cpp, TimeNote.java): it stays while
Sioul is away, and its buttons reach here without the window
(sioul_time_action, docs/android.md).
Structs§
Statics§
- ACTING 🔒
- Buttons pressed one at a time: two in a row act in their order.
- SHOWN 🔒
- WINDOW 🔒
- Sioul’s window, when it runs in this process: a phone’s buttons then act as its own, and it follows.
Functions§
- act 🔒
- A button pressed, “pause”, “resume” or “stop”: with the window, as its own
buttons (
work::focus_pause,work::focus_stop); without, on the session’s file. A button a moment behind (another device paused the session meanwhile) changes nothing: “pause” pauses only what runs, “resume” goes on only with what is paused. Returns whether it changed. - act_in 🔒
- A button pressed without the window: the session’s file in
dirchanged as the window’s buttons change it; Stop keeps the line left at a pause of this session (stopped), as the window’s Stop with no word does. - closing 🔒
- Sioul quits: the computer’s notification goes with it, its buttons having nothing left to reach. A phone’s stays: its buttons reach Sioul without the window.
- follow 🔒
- The notification made to follow the session as it is now: put up, changed or taken away. After each reading of the tasks, and at the window’s minute (what changed elsewhere: another device, the command line).
- note_of 🔒
- The notification for the session running, if one is:
titlenames its task,zonetells the time it started. - post 🔒
- The note made again from the session on disk, and put up if it changed; one at a time, so that the one put up last is the latest. Returns it.
- pressed 🔒
- A button of the desktop’s notification, on its thread: as the focus window’s own; a click on it brings Sioul forward, on the task.
- put 🔒
- The note put up, changed, or taken away: the desktop’s notification, made with the window, whose buttons it reaches.
- sioul_
time_ ⚠action - A button of Android’s notification, “pause”, “resume” or “stop”, pressed, Sioul’s window running or not (TimeReceiver.java): done here first, as the window would, so that nothing slow can lose it (Android lets the button go after a few seconds, and may stop Sioul then); then sent at once, with what your other devices did, in an exchange without notes and papers; the notification then put up as it follows, in the order the buttons were pressed. Answers that note as JSON, “” when no session is left. Blocks while the sharing exchanges: never on Android’s main thread.
- title_
now 🔒 - The title of the task
uid: from the tasks the window read last; without them (a phone’s button, the window not running), from the task lists themselves, once per task. - title_
of 🔒 - The task’s title, else its first project’s; “” when neither is known here (a task not synced to this device yet).