sample/app: Allow to set-up the onscreenapp as pop-up
[apps/onscreenapp.git] / sample / app / eventhandler.cpp
index 58f99fc..3a61887 100644 (file)
@@ -242,3 +242,14 @@ EventHandler::is_running(const QString &app_id)
 
        return false;
 }
+
+void
+EventHandler::set_window_popup(const QString &app_id, int x, int y)
+{
+       struct wl_output *output = getWlOutput(qApp->screens().first());
+
+       if (shell_desktop)
+               agl_shell_desktop_set_app_property(shell_desktop,
+                               app_id.toStdString().c_str(),
+                               AGL_SHELL_DESKTOP_APP_ROLE_POPUP, x, y, output);
+}