[PATCH 1/6 weston] shell: use transient flags for activate or not new surfaces

Tiago Vignatti tiago.vignatti at intel.com
Mon May 21 06:47:45 PDT 2012


Inactive surfaces doesn't set keyboard focus, so it can be used for tooltips,
toolbars and some other type of windows.

This requires protocol side changes.

Signed-off-by: Tiago Vignatti <tiago.vignatti at intel.com>
---
 src/shell.c |    3 +++
 1 file changed, 3 insertions(+)

diff --git a/src/shell.c b/src/shell.c
index 52c21e5..e925a66 100644
--- a/src/shell.c
+++ b/src/shell.c
@@ -2101,6 +2101,9 @@ map(struct desktop_shell *shell, struct weston_surface *surface,
 	switch (surface_type) {
 	case SHELL_SURFACE_TOPLEVEL:
 	case SHELL_SURFACE_TRANSIENT:
+		if (shsurf->transient.flags ==
+				WL_SHELL_SURFACE_TRANSIENT_INACTIVE)
+			break;
 	case SHELL_SURFACE_FULLSCREEN:
 	case SHELL_SURFACE_MAXIMIZED:
 		if (!shell->locked)
-- 
1.7.9.5



More information about the wayland-devel mailing list