summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* NOTE! Default branch is now mainmasterDaniel Stone2021-04-270-0/+0
| | | | | | | | | | | | To update your local repository to use the new default branch, these commands may help: $ git fetch origin $ git checkout master $ git branch -m main $ git branch --set-upstream-to=origin/main Signed-off-by: Daniel Stone <daniels@collabora.com>
* cursor: add one more directory to XCURSORPATHAlexander Dunaev2021-04-271-8/+42
| | | | | | | | | | | | | | | | The user may install cursor themes manually, and the desktop environment may provide a special directory for storing them. For instance, GTK puts those themes into ~/.local/share/icons, and many Linux distributions suggest using that directory for user-specific themes. However, users of libwayland-cursor cannot load these themes using the API provided by the library because the latter does not look into that directory. This patch adds ~/.local/share/icons to the search path, so user-specific themes can be loaded through the API provided by libwayland-cursor. Signed-off-by: Alexander Dunaev <adunaev@igalia.com> Reviewed-by: Emmanuel Gil Peyrot <linkmauve@linkmauve.fr> Reviewed-by: Simon Ser <contact@emersion.fr>
* build: add option to disable testsJames Hilliard2021-04-162-1/+7
| | | | | | | | | | | | | When building for a product, tests are not needed. Besides, one test requires a C++ compiler, which is not always available. So, add an option to configure to disable building tests altogether. Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com> Signed-off-by: James Hilliard <james.hilliard1@gmail.com>
* meson: only require cpp for testsJames Hilliard2021-04-162-8/+10
| | | | Signed-off-by: James Hilliard <james.hilliard1@gmail.com>
* Change wl_os_dupfd_cloexec minfd to be intAlex Richardson2021-04-152-2/+2
| | | | | | | | | | The fcntl() argument is defined to be an int and not a long. This does not matter on most architectures since the value is passed in registers, but it causes issues on big-endian architectures that pass variadic arguments on the stack. Signed-off-by: Alex Richardson <Alexander.Richardson@cl.cam.ac.uk> Reviewed-by: Simon Ser <contact@emersion.fr>
* os-wrappers-test.c: Correctly forward arguments to fcntlAlex Richardson2021-04-151-6/+22
| | | | | | | | | | | | | | | | | | We can't just unconditionally read the optional arguments (and also read it as a void* despite actually being an int). While this happens to work on most architectures because the first few variadic arguments are passed in registers, this is non-portable and causes a crash on architectures that set bounds on variadic function arguments (for example CHERI-enabled architectures). It could also cause problems on big-endian architectures that pass variadic arguments on the stack rather than in registers. For CHERI-MIPS, reading sizeof(void*) causes a read of 16 bytes from the bounded varargs capability. This always crashes since even calls with the optional argument only have 4 bytes available. Signed-off-by: Alex Richardson <Alexander.Richardson@cl.cam.ac.uk> Reviewed-by: Simon Ser <contact@emersion.fr>
* meson: Only require expat when building wayland-scannerMichael Weiss2021-04-022-8/+9
| | | | | | | | This code is only required for building wayland-scanner so it should be scoped accordingly. libxml-2.0 will only be required if both "scanner" and "dtd_validation" are set to true. Signed-off-by: Michael Weiss <dev.primeos@gmail.com>
* ci: Use ci-fairy to check for Signed-off-byJonas Ådahl2021-03-261-1/+19
| | | | Signed-off-by: Jonas Ådahl <jadahl@gmail.com>
* Use MAP_FAILED instead of (void *) -1Alex Richardson2021-03-221-4/+2
| | | | | | | | While MAP_FAILED is generally defined to that value, we should not be relying on implementation details of system headers. Signed-off-by: Alex Richardson <Alexander.Richardson@cl.cam.ac.uk> Reviewed-by: Simon Ser <contact@emersion.fr>
* build: drop autotoolsSimon Ser2021-03-0522-1049/+10
| | | | | | Meson now replaces autotools. Signed-off-by: Simon Ser <contact@emersion.fr>
* server: add wl_display getter for wl_globalVlad Zahorodnii2021-03-052-0/+17
| | | | | | | | This can be useful if the compositor wants to call wl_global_destroy() with some delay but it doesn't have the wl_display object associated with the global, which is needed to get access to the event loop. Signed-off-by: Vlad Zahorodnii <vlad.zahorodnii@kde.org>
* client: assert queue display matches proxySimon Ser2021-02-251-2/+4
| | | | | | | | | | In wl_proxy_set_queue, passing a wl_event_queue from a completely unrelated wl_display could lead to object IDs mismatches. Add an assertion to catch this case. It's always a user bug if this happens. Signed-off-by: Simon Ser <contact@emersion.fr>
* server: remove duplicate includesheepwall2021-02-221-1/+0
| | | | Signed-off-by: August Svensson <a.sve@live.se>
* protocol: Specify wl_callback::done to be a destructor eventTadeo Kondrak2021-01-271-1/+1
| | | | | | | It's the only destructor event in the core protocol, and destructor events were previously unannotated. Signed-off-by: Tadeo Kondrak <me@tadeo.ca>
* protocol: Add type attribute to eventsTadeo Kondrak2021-01-271-0/+1
| | | | | | | This allows specifying events to be destructors, which is useful for non-C language bindings. It is unused in wayland-scanner. Signed-off-by: Tadeo Kondrak <me@tadeo.ca>
* build: re-open master for regular developmentSimon Ser2021-01-272-2/+2
|
* build: bump to version 1.19.0 for the official release1.19.0Simon Ser2021-01-272-3/+3
|
* build: bump to 1.18.93 for the RC1 release1.18.93Simon Ser2021-01-202-2/+2
|
* protocol: sync wl_shm.format with libdrm 2.4.104Simon Ser2021-01-191-0/+4
| | | | | | | | This adds 4 new formats. Signed-off-by: Simon Ser <contact@emersion.fr> Reviewed-by: Jonas Ådahl <jadahl@gmail.com> Acked-by: Daniel Stone <daniels@collabora.com>
* server: Allow absolute paths in WAYLAND_DISPLAYLoïc Yhuel2021-01-131-18/+25
| | | | | | | | | | The compositor should handle absolute paths in WAYLAND_DISPLAY like the clients, ie not adding the XDG_RUNTIME_DIR prefix if it's an absolute path. This allows to create the wayland socket in a separate directory for system compositors if desired. Clients could then directly inherit the environment variable. Signed-off-by: Loïc Yhuel <loic.yhuel@softathome.com>
* build: bump to version 1.18.92 for the beta release1.18.92Simon Ser2021-01-062-2/+2
|
* Remove TODOSimon Ser2020-12-281-146/+0
| | | | | | | These TODO items are outdated (either done or not applicable anymore). Let's migrate items that we want to keep to GitLab issues. Signed-off-by: Simon Ser <contact@emersion.fr>
* meson: link with -lrt if needed for clock_gettimeLoïc Yhuel2020-12-233-3/+12
| | | | | | This is already done in autotools, and fixes the build with glibc < 2.17. Signed-off-by: Loïc Yhuel <loic.yhuel@softathome.com>
* build: bump to version 1.18.91 for the alpha release1.18.91Simon Ser2020-12-212-2/+2
|
* server: fix typosMaxime Roussin-Bélanger2020-12-172-9/+9
|
* egl: fix typo "Backards"Maxime Roussin-Bélanger2020-12-171-6/+6
|
* cursor: fix typo "insufficent"Maxime Roussin-Bélanger2020-12-171-1/+1
|
* CONTRIBUTING: fix typo "excercising"Maxime Roussin-Bélanger2020-12-171-1/+1
|
* tests: fix typosMaxime Roussin-Bélanger2020-12-172-2/+2
|
* doc: fix typosMaxime Roussin-Bélanger2020-12-174-6/+6
|
* protocol: deprecate non-current wl_output.modeSimon Ser2020-10-291-0/+4
| | | | | | | | | | | | | | | | | | | | | The current wl_output.mode event has several issues when used to advertise modes that aren't current: - It's not possible to remove some modes. This is an issue for virtual outputs and when the kernel prunes some modes because of link limitations. - wl_output.mode fails to carry metadata such as aspect ratio, which results in duplicated or missing modes. - It's not clear, given the current set of protocols, how non-current modes are useful to clients. Xwayland ignores non-current modes. GNOME and wlroots already only advertise the current mode because of these issues. If a protocol needs the clients to know about all available modes, it should advertise these modes itself instead of relying on wl_output.mode. Signed-off-by: Simon Ser <contact@emersion.fr> Closes: https://gitlab.freedesktop.org/wayland/wayland/-/issues/92
* protocol: make it clear wl_surface.enter/leave are not for frame throttlingSimon Ser2020-10-291-0/+6
| | | | | | | | | | | | | | | | | Some clients rely on wl_surface.enter/leave to start/stop their rendering loop. There are cases where this doesn't work: - Some compositors don't send wl_surface.leave when a toplevel is hidden. For instance Sway doesn't send this event when a toplevel is on an inactive workspace (but doesn't send wl_surface.frame events). - Some compositors might still want applications to continue to render even if away from outputs. For instance a compositor that allows to screen record individual toplevels might not send a wl_surface.enter event for hidden toplevels. Signed-off-by: Simon Ser <contact@emersion.fr>
* cursor/convert_font.c: malloc cannot guarantee that the memory allocated is ↵ganjing2020-10-291-0/+5
| | | | always successful
* doc: make reproducibleAlyssa Ross2020-10-291-0/+1
| | | | | | | This setting makes Docbook section IDs consistent, and should allow Wayland builds that include documentation to be fully reproducible. Signed-off-by: Alyssa Ross <hi@alyssa.is>
* protocol: Clarify how clients can cancel a drag operationNick Diego Yamane2020-10-291-1/+2
| | | | | | | | | | Explicitly say that destroying a wl_data_source previously used in a wl_data_device::start_drag request will cancel the DND session. This is currently the only way to do it from client side (besides those "indirect" ones already documented) and all compositors work like that but it is not clear spec-wise it is the expected behaviour. Signed-off-by: Nick Diego Yamane <nickdiego@igalia.com>
* Fix undefined behaviorValentin2020-09-041-4/+5
| | | | | | | | Without the casts the bytes accesses get converted to int. but int is not guaranteed to be 4 bytes large. Even when it is 4 bytes large `bytes[3] << 24` does not fit because int is signed. Signed-off-by: Valentin Kettner <vakevk@gmail.com>
* Use fixed size integer typeValentin2020-09-041-1/+3
| | | | | | | | This type is meant to be 4 bytes large as seen in _XcursorReadUInt which always reads 4 bytes. An unsigned int is often 4 bytes large but this isnt' guaranteed so it is cleaner to use the exact type we want. Signed-off-by: Valentin Kettner <vakevk@gmail.com>
* Add a basic gitlab issue templatePeter Hutterer2020-08-181-0/+8
| | | | | | | | | | | This makes the Bug template available in the new issues form. Ideally a majority of users will select this template and then realize that they're in the wrong repo. Making this a default is a feature of the enterprise gitlab version only, see https://docs.gitlab.com/ce/user/project/description_templates.html#overview Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
* protocol: Minor gramatical fix.Christopher James Halse Rogers2020-08-141-1/+1
| | | | Signed-off-by: Christopher James Halse Rogers <christopher.halse.rogers@canonical.com>
* protocol: disambiguate key codes in wl_keyboard.keySimon Ser2020-06-161-0/+3
| | | | | | | | | | | Explain that wl_keyboard.key yields platform-specific key codes. Some compositors use Linux key codes (defined in the linux/input-event-codes.h header file, e.g. KEY_ESC), however clients should not assume that this is always the case. The only reliable way for clients to interpret key codes is to feed them into a keyboard mapping. Signed-off-by: Simon Ser <contact@emersion.fr>
* Clarify clients behavior on wl_keyboard.leaveKirill Chibisov2020-06-121-0/+3
| | | | | | | | | Clients must assume that every key, including modifiers, are lifted after getting wl_keyboard.leave event, not doing so could lead to key repeat keep going after the user changes focus, or stuck modifiers, when the user interacts with client without keyboard focus. Signed-off-by: Kirill Chibisov <contact@kchibisov.com>
* Clarify the order of wl_keyboard.modifiersKirill Chibisov2020-06-121-0/+6
| | | | | | | | | | | | | | | | Consider that we set the modifier for the modifier key as well, and that you have the option to change your layout when both shifts pressed. This realized by making the shift keys produce 'Group_switch' when you press the shift key and the shift modifier is already active. So sending modifier before the key event will result in 'Group_switch' each time you press shift. That being said, the order of modifiers should be updated after the key/enter event, so it'll only affect future keypresses, not the current one. See: https://lists.x.org/archives/xorg-devel/2014-July/043110.html Signed-off-by: Kirill Chibisov <contact@kchibisov.com>
* doc: Document libwayland-cursor with mesonEmmanuel Gil Peyrot2020-06-052-1/+12
| | | | Signed-off-by: Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
* doc: Document libwayland-cursor with autotoolsEmmanuel Gil Peyrot2020-06-051-1/+10
| | | | Signed-off-by: Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
* cursor: Properly document wl_cursor_image and wl_cursorEmmanuel Gil Peyrot2020-06-051-5/+24
| | | | Signed-off-by: Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
* cursor: Use spaces for alignment in the headerEmmanuel Gil Peyrot2020-06-051-5/+5
| | | | Signed-off-by: Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
* protocol: add seat missing_capability errorSimon Ser2020-06-051-3/+14
| | | | | | | | | | | | The protocol says: > It is a protocol violation to issue this request on a seat that > has never had the pointer capability. But never defines an error code. Signed-off-by: Simon Ser <contact@emersion.fr> Closes: https://gitlab.freedesktop.org/wayland/wayland/-/issues/165
* gitlab CI: update to use the fdo ci templatesPeter Hutterer2020-06-051-10/+45
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Instead of building a new debian image every time we build the repo, let's build it once and re-use it. This way we're more likely to spot actual bugs vs issues with the distribution (or mirrors). This is the same approach mesa, gstreamer, libinput, etc. already use. The pipeline consists of two parts: container-build and distribution-image. Both use the FDO_DISTRIBUTION_... variables to do their thing, the former to build an image, the latter to use that image. The container-build step is a noop if an image with that tag already exists in the registry, the templates take care of all that. The .debian.buster section groups the variables needed to easily extend all jobs requiring buster. Not all variables are used by all jobs but meh. The grouping is slightly odd because some debian-specific variables are in the global variables and others in the .debian.buster section. This grouping will make things easier if we extend to build on other distributions - then we have all packages and tags in one place. Because buster doesn't have a recent-enough version of meson, we install that from pip. Fixes #79 Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net> Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.com>
* editorconfig: add settings for the .gitlab-ci.yml filePeter Hutterer2020-06-051-0/+5
| | | | | | | | Different indentation and we don't want a fixed line length here, wrapping yaml is prone to introduce bugs. Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net> Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.com>
* doc: fix and clarify pointer image behaviourYann Dirson2020-06-031-4/+8
| | | | Signed-off-by: Yann Dirson <ydirson@free.fr>