What a client shell reports, and how it starts.
More...
#include <shell.hpp>
|
| std::string | startScreen |
| | The screen mounted first; empty for the first the source lists.
|
| ui::ParamMap | startParams |
| | The start screen's params.
|
| std::function< void(std::string const &problem)> | onProblem |
| | Called with each problem: why the source did not open, a document that did not load, a refused mount, an interpreter diagnostic. Empty ignores them; the shell shows the first three either way.
|
| std::function< void(std::string const &screenId)> | onMounted |
| | Called with the id of each screen once it is mounted.
|
| std::filesystem::path | downloads |
| | Where a screen's download saves a file, under the name the screen suggests; the working directory when empty.
|
| ui::IHistory * | history = nullptr |
| | The history the shown screen's route is kept in (spec 3 §10), such as the browser's: back and forward open the route of the entry moved to, and the route it holds at start is opened once the session has the screen. Borrowed: it outlives the shell; null keeps no history.
|
| bool | dev = false |
| | Development mode (spec 5 §12): every second the shell polls the source's ui-hello digest, and when it changed, remounts every open tab whose document changed, keeping its state. A shell built without the development tools never polls. A production client leaves it off: the digest is then read once.
|
| std::function< void(std::vector< std::string > const &remounted)> | onReloaded |
| | Called after each development reload with the ids of the screens it remounted; empty ignores it.
|
| SignInMapper | signIn = defaultSignIn |
| | Maps a sign-in mutation's reply to the principal and token the shell installs. Required.
|
What a client shell reports, and how it starts.
Definition at line 131 of file shell.hpp.
◆ startScreen
| std::string morph::client::ShellOptions::startScreen |
The screen mounted first; empty for the first the source lists.
Definition at line 133 of file shell.hpp.
◆ startParams
The start screen's params.
Definition at line 135 of file shell.hpp.
◆ onProblem
| std::function<void(std::string const& problem)> morph::client::ShellOptions::onProblem |
Called with each problem: why the source did not open, a document that did not load, a refused mount, an interpreter diagnostic. Empty ignores them; the shell shows the first three either way.
Definition at line 138 of file shell.hpp.
◆ onMounted
| std::function<void(std::string const& screenId)> morph::client::ShellOptions::onMounted |
Called with the id of each screen once it is mounted.
Definition at line 140 of file shell.hpp.
◆ downloads
| std::filesystem::path morph::client::ShellOptions::downloads |
Where a screen's download saves a file, under the name the screen suggests; the working directory when empty.
Definition at line 143 of file shell.hpp.
◆ history
| ui::IHistory* morph::client::ShellOptions::history = nullptr |
The history the shown screen's route is kept in (spec 3 §10), such as the browser's: back and forward open the route of the entry moved to, and the route it holds at start is opened once the session has the screen. Borrowed: it outlives the shell; null keeps no history.
Definition at line 147 of file shell.hpp.
◆ dev
| bool morph::client::ShellOptions::dev = false |
Development mode (spec 5 §12): every second the shell polls the source's ui-hello digest, and when it changed, remounts every open tab whose document changed, keeping its state. A shell built without the development tools never polls. A production client leaves it off: the digest is then read once.
Definition at line 151 of file shell.hpp.
◆ onReloaded
| std::function<void(std::vector<std::string> const& remounted)> morph::client::ShellOptions::onReloaded |
Called after each development reload with the ids of the screens it remounted; empty ignores it.
Definition at line 153 of file shell.hpp.
◆ signIn
Maps a sign-in mutation's reply to the principal and token the shell installs. Required.
Definition at line 155 of file shell.hpp.
The documentation for this struct was generated from the following file: