weston/libweston
Emmanuel Gil Peyrot 6b58ea8c43 xwm: Add icon support to the frame
This fetches the _NET_WM_ICON property of the X11 window, and use the
first image found as the frame icon.

This has been tested with various X11 programs, and improves usability
and user-friendliness a bit.

Changes since v1:
- Changed frame_button_create() to use
  frame_button_create_from_surface() internally.
- Removed a check that should never have been commited.

Changes since v2:
- Request UINT32_MAX items instead of 2048, to avoid cutting valid
  icons.
- Strengthen checks against malformed input.
- Handle XCB_PROPERTY_DELETE to remove the icon.
- Schedule a repaint if the icon changed.

Changes since v3:
- Keep the previous Cairo surface until the new one has been
  successfully loaded.
- Use uint32_t for cardinals.  Unsigned is the same type except on
  16-bit machines, but uint32_t is clearer.
- Declare length as uint32_t too, like in xcb_get_property_reply_t.

Signed-off-by: Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
Reviewed-by: Quentin Glidic <sardemff7+git@sardemff7.net>
2018-01-18 12:24:19 +00:00
..
animation.c build,libweston: Use struct timespec for animations 2017-11-27 11:41:17 +02:00
bindings.c libweston: Use struct timespec for touch down events 2017-11-27 11:42:07 +02:00
clipboard.c include stdint.h for int32_t/uint32_t 2016-07-26 16:26:08 -07:00
compositor-drm.c compositor-drm: Add to_drm_mode helper 2018-01-18 12:11:11 +00:00
compositor-drm.h compositor-drm: add specific_device configuration option 2017-12-18 13:50:41 +02:00
compositor-fbdev.c compositor-drm, compositor-fbdev: stop suggesting root 2017-11-28 10:24:12 +02:00
compositor-fbdev.h weston: Port fbdev backend to new output handling API 2016-10-03 14:24:08 +03:00
compositor-headless.c libweston: set backend pointer earlier 2017-10-04 16:18:06 +03:00
compositor-headless.h weston: Port headless backend to new output handling API 2016-10-03 14:24:08 +03:00
compositor-rdp.c libweston: Use struct timespec for compositor time 2017-11-27 11:42:07 +02:00
compositor-rdp.h weston: Port RDP backend to new output handling API 2016-10-03 14:24:08 +03:00
compositor-wayland.c xwm: Add icon support to the frame 2018-01-18 12:24:19 +00:00
compositor-wayland.h compositor-wayland: Convert fullscreen flag to bool 2016-10-14 10:42:17 +02:00
compositor-x11.c compositor-x11: Implement mode switching 2017-12-04 20:51:08 +00:00
compositor-x11.h weston: Port X11 backend to new output handling API 2016-10-05 14:59:09 +03:00
compositor.c compositor: Implement runtime output transform changes 2018-01-18 11:26:09 +00:00
compositor.h libweston: drop return type from ::query_dmabuf_{formats, modifiers} 2017-12-11 09:36:18 +00:00
data-device.c libweston: Use struct timespec for touch motion events 2017-11-27 11:42:07 +02:00
dbus.c include stdint.h for int32_t/uint32_t 2016-07-26 16:26:08 -07:00
dbus.h
gl-renderer.c gl-renderer: return conservative format list if dmabuf import modifiers unsupported 2018-01-18 11:24:27 +00:00
gl-renderer.h gl-renderer: Add <platform_attribs> param to gl_renderer_display_create 2016-11-07 17:06:44 +02:00
input.c input: Do not override keyboard focus on restore 2017-12-04 21:07:38 +00:00
launcher-direct.c configure.ac: use AC_HEADER_MAJOR to detect major()/minor() 2017-12-04 19:38:14 +00:00
launcher-impl.h libweston/launcher: annotate iface(s) as constant data 2017-02-27 21:55:02 +00:00
launcher-logind.c configure.ac: use AC_HEADER_MAJOR to detect major()/minor() 2017-12-04 19:38:14 +00:00
launcher-util.c libweston: Use struct timespec for key events 2017-11-27 11:42:07 +02:00
launcher-util.h
launcher-weston-launch.c configure.ac: use AC_HEADER_MAJOR to detect major()/minor() 2017-12-04 19:38:14 +00:00
libbacklight.c Switch to use safe_strtoint instead of strtol 2016-08-06 18:19:22 -07:00
libbacklight.h
libinput-device.c libweston: Use struct timespec for touch down events 2017-11-27 11:42:07 +02:00
libinput-device.h
libinput-seat.c input: Stop leaking libinput event source on session deactivation 2017-07-27 14:44:49 +03:00
libinput-seat.h
libweston-uninstalled.pc.in buildsystem: add missing pkg-config stub for libweston uninstalled 2017-11-10 12:50:41 -06:00
libweston.pc.in libweston: fix major in libweston.pc 2016-08-02 14:19:11 +03:00
linux-dmabuf.c linux-dmabuf: send deprecated format events 2018-01-18 11:24:19 +00:00
linux-dmabuf.h linux-dmabuf: send deprecated format events 2018-01-18 11:24:19 +00:00
log.c
noop-renderer.c include stdint.h for int32_t/uint32_t 2016-07-26 16:26:08 -07:00
pixel-formats.c libweston: Add pixel-format helpers 2017-04-07 12:28:36 +03:00
pixel-formats.h libweston: Add pixel-format helpers 2017-04-07 12:28:36 +03:00
pixman-renderer.c libweston: Use struct timespec for key events 2017-11-27 11:42:07 +02:00
pixman-renderer.h
plugin-registry.c compositor: add plugin-registry 2016-07-01 14:10:26 +03:00
plugin-registry.h compositor: add plugin-registry 2016-07-01 14:10:26 +03:00
screenshooter.c libweston: Use struct timespec for the output presentation timestamp 2017-11-27 11:42:07 +02:00
spring-tool.c build,libweston: Use struct timespec for animations 2017-11-27 11:41:17 +02:00
timeline-object.h
timeline.c timeline: Add GPU timestamp timepoint argument 2017-09-29 10:20:42 +03:00
timeline.h timeline: Add GPU timestamp timepoint argument 2017-09-29 10:20:42 +03:00
vaapi-recorder.c
vaapi-recorder.h
version.h.in
vertex-clipping.c
vertex-clipping.h
weston-launch.c configure.ac: use AC_HEADER_MAJOR to detect major()/minor() 2017-12-04 19:38:14 +00:00
weston-launch.h
weston-sync-file.h libweston: Add check and fallback for linux/sync_file.h 2017-09-29 10:20:42 +03:00
windowed-output-api.h libweston: Add initial output API for windowed outputs configuration 2016-10-03 13:51:24 +03:00
zoom.c build,libweston: Use struct timespec for animations 2017-11-27 11:41:17 +02:00