diff options
Diffstat (limited to 'src/libwindowmanager.cpp')
-rw-r--r-- | src/libwindowmanager.cpp | 30 |
1 files changed, 20 insertions, 10 deletions
diff --git a/src/libwindowmanager.cpp b/src/libwindowmanager.cpp index 2357252..55e5ed6 100644 --- a/src/libwindowmanager.cpp +++ b/src/libwindowmanager.cpp @@ -70,8 +70,8 @@ class LibWindowmanager::Impl { // WM API int requestSurface(json_object *object); int requestSurfaceXDG(json_object *object); - int activateSurface(json_object *object); - int deactivateSurface(json_object *object); + int activateWindow(json_object *object); + int deactivateWindow(json_object *object); int endDraw(json_object *object); int getDisplayInfo(json_object *object); @@ -337,12 +337,12 @@ int LibWindowmanager::Impl::requestSurfaceXDG(json_object *object) { return rc; } -int LibWindowmanager::Impl::activateSurface(json_object *object) { +int LibWindowmanager::Impl::activateWindow(json_object *object) { TRACE(); HMI_DEBUG("libwm", "called"); - return this->api_call("ActivateSurface", object, [](bool ok, json_object *j) { + return this->api_call("ActivateWindow", object, [](bool ok, json_object *j) { if (!ok) { - HMI_ERROR("libwm", "API Call activate_surface() failed: %s", + HMI_ERROR("libwm", "API Call activateWindow() failed: %s", j != nullptr ? json_object_to_json_string_ext( j, JSON_C_TO_STRING_PRETTY) : "no-info"); @@ -350,12 +350,12 @@ int LibWindowmanager::Impl::activateSurface(json_object *object) { }); } -int LibWindowmanager::Impl::deactivateSurface(json_object *object) { +int LibWindowmanager::Impl::deactivateWindow(json_object *object) { TRACE(); HMI_DEBUG("libwm", "called"); - return this->api_call("DeactivateSurface", object, [](bool ok, json_object *j) { + return this->api_call("DeactivateWindow", object, [](bool ok, json_object *j) { if (!ok) { - HMI_ERROR("libwm", "API Call deactivate_surface() failed: %s", + HMI_ERROR("libwm", "API Call deactivateWindow() failed: %s", j != nullptr ? json_object_to_json_string_ext( j, JSON_C_TO_STRING_PRETTY) : "no-info"); @@ -737,12 +737,22 @@ int LibWindowmanager::requestSurfaceXDG(json_object *object) { return this->d->requestSurfaceXDG(object); } +int LibWindowmanager::activateWindow(json_object *object) { + return this->d->activateWindow(object); +} + +int LibWindowmanager::deactivateWindow(json_object *object) { + return this->d->deactivateWindow(object); +} + +// This API is deprecated, please use new API int LibWindowmanager::activateSurface(json_object *object) { - return this->d->activateSurface(object); + return this->activateWindow(object); } +// This API is deprecated, please use new API int LibWindowmanager::deactivateSurface(json_object *object) { - return this->d->deactivateSurface(object); + return this->deactivateWindow(object); } int LibWindowmanager::endDraw(json_object *object) { |