From: Hwankyu Jhun Date: Fri, 15 Mar 2024 05:56:35 +0000 (+0900) Subject: Use wl_display_flush() X-Git-Tag: accepted/tizen/unified/20240318.071243~1 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=refs%2Fchanges%2F93%2F307993%2F1;p=platform%2Fcore%2Fappfw%2Fapp-core.git Use wl_display_flush() To avoid blocking main thread, app-core uses wl_display_flush() instead of wl_display_roundtrip(). Change-Id: I06ad4661858e1b6839ccb35e91e515dc94899508 Signed-off-by: Hwankyu Jhun --- diff --git a/tizen-cpp/app-core-ui-cpp/wayland_handler_private.cc b/tizen-cpp/app-core-ui-cpp/wayland_handler_private.cc index 3d89b70..e1d3ff6 100644 --- a/tizen-cpp/app-core-ui-cpp/wayland_handler_private.cc +++ b/tizen-cpp/app-core-ui-cpp/wayland_handler_private.cc @@ -88,7 +88,7 @@ void WaylandHandler::SetBgState() { return; tizen_policy_set_background_state(tz_policy_, getpid()); - wl_display_roundtrip(dsp_); + wl_display_flush(dsp_); _D("Set Background State"); } @@ -97,7 +97,7 @@ void WaylandHandler::UnsetBgState() { return; tizen_policy_unset_background_state(tz_policy_, getpid()); - wl_display_roundtrip(dsp_); + wl_display_flush(dsp_); _D("Unset Background State"); } @@ -106,7 +106,7 @@ void WaylandHandler::SetAppId(const std::string& app_id) { return; tizen_policy_set_appid(tz_policy_, getpid(), app_id.c_str()); - wl_display_roundtrip(dsp_); + wl_display_flush(dsp_); _D("Set AppId: %s", app_id.c_str()); }