f94cc160cf
- Add parseAppFlagsString() in AppManifestParsing.cpp to parse comma-separated flags (HideStatusBar, Hidden, None) - Parse [app]flags in V1 and app.flags in V2 manifests - Loader already supports HideStatusBar, GuiService hides statusbarWidget when set - Enables fullscreen for ELF apps (e.g. BibleVerse, BookPlayer) without firmware recompilation of internal manifests - Add tests for flag parsing (38 tests passing) - Tested on es3c28p /dev/cu.usbmodem1101 @ 192.168.68.133 with HelloWorld app
27 lines
943 B
C++
27 lines
943 B
C++
#pragma once
|
|
|
|
#include <Tactility/app/AppManifest.h>
|
|
|
|
#include <map>
|
|
#include <string>
|
|
|
|
namespace tt::app {
|
|
|
|
bool getValueFromManifest(const std::map<std::string, std::string>& map, const std::string& key, std::string& output);
|
|
|
|
bool isValidManifestVersion(const std::string& version);
|
|
bool isValidAppVersionName(const std::string& version);
|
|
bool isValidAppVersionCode(const std::string& version);
|
|
bool isValidName(const std::string& name);
|
|
|
|
/** Parses a comma-separated flags string (e.g. "HideStatusBar,Hidden") into appFlags bitmask. */
|
|
uint16_t parseAppFlagsString(const std::string& raw);
|
|
|
|
/** Parses a V1 (sectioned INI, e.g. "[app]versionName=...") manifest map. */
|
|
bool parseManifestV1(const std::map<std::string, std::string>& map, AppManifest& manifest);
|
|
|
|
/** Parses a V2 (flat dot-notation, e.g. "app.version.name=...") manifest map. */
|
|
bool parseManifestV2(const std::map<std::string, std::string>& map, AppManifest& manifest);
|
|
|
|
}
|