Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(215)

Unified Diff: components/exo/wayland/server.cc

Issue 2110553002: exo: Implement version 7 of remote shell interface. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@wayland-protocols-remote-shell-7
Patch Set: Created 4 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/exo/wayland/server.cc
diff --git a/components/exo/wayland/server.cc b/components/exo/wayland/server.cc
index d67da96ef1fbac542ffe2cfb0186d8e7dbf3bb0c..e6368d98980c5f4df9244f5faf6f38815d121a82 100644
--- a/components/exo/wayland/server.cc
+++ b/components/exo/wayland/server.cc
@@ -1686,25 +1686,35 @@ void HandleRemoteSurfaceStateChangedCallback(
default:
break;
}
+
+ uint32_t state_type = ZWP_REMOTE_SHELL_V1_STATE_TYPE_NORMAL;
switch (new_state_type) {
case ash::wm::WINDOW_STATE_TYPE_MINIMIZED:
+ state_type = ZWP_REMOTE_SHELL_V1_STATE_TYPE_MINIMIZED;
if (wl_resource_get_version(resource) >= 2)
zwp_remote_surface_v1_send_set_minimized(resource);
break;
case ash::wm::WINDOW_STATE_TYPE_MAXIMIZED:
+ state_type = ZWP_REMOTE_SHELL_V1_STATE_TYPE_MAXIMIZED;
if (wl_resource_get_version(resource) >= 2)
zwp_remote_surface_v1_send_set_maximized(resource);
break;
case ash::wm::WINDOW_STATE_TYPE_FULLSCREEN:
+ state_type = ZWP_REMOTE_SHELL_V1_STATE_TYPE_FULLSCREEN;
zwp_remote_surface_v1_send_set_fullscreen(resource);
break;
case ash::wm::WINDOW_STATE_TYPE_PINNED:
+ state_type = ZWP_REMOTE_SHELL_V1_STATE_TYPE_PINNED;
if (wl_resource_get_version(resource) >= 3)
zwp_remote_surface_v1_send_set_pinned(resource);
break;
default:
break;
}
+
+ if (wl_resource_get_version(resource) >= 7)
+ zwp_remote_surface_v1_send_state_type_changed(resource, state_type);
+
wl_client_flush(wl_resource_get_client(resource));
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698