Update docs and fix bugs (#149)

Improved the docs for the 3 main Tactility projects. I also fixed some inaccuracies and bugs in certain APIs as I went through the code.
This commit is contained in:
Ken Van Hoeylandt
2025-01-07 20:45:23 +01:00
committed by GitHub
parent ff4287e2ce
commit 415096c3b2
62 changed files with 503 additions and 517 deletions
+13 -29
View File
@@ -11,7 +11,8 @@ namespace tt::app {
class AppContext;
typedef enum {
/** Application types */
enum Type {
/** Boot screen, shown before desktop is launched. */
TypeBoot,
/** A desktop app sits at the root of the app stack managed by the Loader service */
@@ -24,8 +25,9 @@ typedef enum {
TypeSettings,
/** User-provided apps. */
TypeUser
} Type;
};
/** Result status code for application result callback. */
typedef enum {
ResultOk,
ResultCancelled,
@@ -39,49 +41,31 @@ typedef void (*AppOnHide)(AppContext& app);
typedef void (*AppOnResult)(AppContext& app, Result result, const Bundle& resultData);
struct AppManifest {
/**
* The identifier by which the app is launched by the system and other apps.
*/
/** The identifier by which the app is launched by the system and other apps. */
std::string id;
/**
* The user-readable name of the app. Used in UI.
*/
/** The user-readable name of the app. Used in UI. */
std::string name;
/**
* Optional icon.
*/
/** Optional icon. */
std::string icon = {};
/**
* App type affects launch behaviour.
*/
/** App type affects launch behaviour. */
Type type = TypeUser;
/**
* Non-blocking method to call when app is started.
*/
/** Non-blocking method to call when app is started. */
AppOnStart onStart = nullptr;
/**
* Non-blocking method to call when app is stopped.
*/
/** Non-blocking method to call when app is stopped. */
AppOnStop _Nullable onStop = nullptr;
/**
* Non-blocking method to create the GUI
*/
/** Non-blocking method to create the GUI. */
AppOnShow _Nullable onShow = nullptr;
/**
* Non-blocking method, called before gui is destroyed
*/
/** Non-blocking method, called before gui is destroyed. */
AppOnHide _Nullable onHide = nullptr;
/**
* Handle the result for apps that are launched
*/
/** Handle the result for apps that are launched. */
AppOnResult _Nullable onResult = nullptr;
};