Refactor app access (#205)
- Use `tt::app::` functions to start/stop apps and get current app(context) instead of using loader everywhere - Removed `tt_service_loader.*` from TactilityC - Created `tt_app_stop()` for TactilityC - Bumped version to 0.3.0 to prepare for upcoming release
This commit is contained in:
committed by
GitHub
parent
68e34ca740
commit
6337458992
@@ -20,7 +20,7 @@ Gui* gui = nullptr;
|
||||
void onLoaderMessage(const void* message, TT_UNUSED void* context) {
|
||||
auto* event = static_cast<const loader::LoaderEvent*>(message);
|
||||
if (event->type == loader::LoaderEventTypeApplicationShowing) {
|
||||
auto app_instance = service::loader::getCurrentAppContext();
|
||||
auto app_instance = app::getCurrentAppContext();
|
||||
showApp(app_instance);
|
||||
} else if (event->type == loader::LoaderEventTypeApplicationHiding) {
|
||||
hideApp();
|
||||
|
||||
@@ -87,7 +87,7 @@ void ScreenshotTask::taskMain() {
|
||||
}
|
||||
}
|
||||
} else if (work.type == TASK_WORK_TYPE_APPS) {
|
||||
auto appContext = loader::getCurrentAppContext();
|
||||
auto appContext = app::getCurrentAppContext();
|
||||
if (appContext != nullptr) {
|
||||
const app::AppManifest& manifest = appContext->getManifest();
|
||||
if (manifest.id != last_app_id) {
|
||||
|
||||
Reference in New Issue
Block a user