Age | Commit message (Collapse) | Author | Files | Lines |
|
Add some inline information, what the macro is used for, why it came to
be and what we shouldn't do if we consider further deprecation in the future
deprecation.
Cc: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Signed-off-by: Emil Velikov <emil.velikov@collabora.com>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
|
|
I've heard some complaints that wl_display.get_registry "leaks"
server memory because wl_registry has no destructor. While this isn't
strictly true - all those resources are freed when the client
disconnects - it's a bit of a gotcha for neophytes.
Since wl_registry's version is not requested in any way through
wl_display.get_registry, we can't add a destructor request without
breaking ABI. So let's be a little more clear about the result
of getting too many wl_registry objects.
Signed-off-by: Derek Foreman <derekf@osg.samsung.com>
Reviewed-by: Daniel Stone <daniels@collabora.com>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
|
|
All the foo.in files are in the tarball, as long as their foo
counterparts are listed in AC_CONFIG_FILES
For example - *.pc.in, Makefile.in files, etc.
Signed-off-by: Emil Velikov <emil.velikov@collabora.com>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
|
|
This documents all the public API related to wl_event_loop and
wl_event_source objects.
Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Reviewed-by: Yong Bakos <ybakos@humanoriented.com>
[Pekka: fixed typos pointed by Yong]
[Pekka: fixed typos pointed by Christopher]
Reviewed-By: Christopher James Halse Rogers <christopher.halse.rogers@canonical.com>
|
|
When input/output files are passed as arguments to wayland-scanner,
instead of using stdin/stdout, warning and error messages will contain
the file name, together with line number, of the warning/error. Doing
this helps IDEs jump to the correct line.
Signed-off-by: Jonas Ådahl <jadahl@gmail.com>
Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
[Pekka: dropped the src/scanner.mk hunk, file deleted]
Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
|
|
File uses tabs, barring the few instances fixed with this patch.
Signed-off-by: Emil Velikov <emil.velikov@collabora.com>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
|
|
Nothing in the existing codebase references the file.
Signed-off-by: Emil Velikov <emil.velikov@collabora.com>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
|
|
A 1.14 branch has been established for stable release work.
|
|
|
|
|
|
With recent versions of graphviz, generation of the diagrams in the documentation
fails with:
/usr/bin/dot -Tpng -oxml/x-architecture.png dot/x-architecture.gv
Warning: flat edge between adjacent nodes one of which has a record shape - replace records with HTML-like labels
Edge xserver -> comp
Error: getsplinepoints: no spline points available for edge (xserver,comp)
Error: lost xserver comp edge
Error: lost xserver comp edge
Error: lost comp xserver edge
Error: lost comp xserver edge
http://www.graphviz.org/content/i-havent-been-able-render-these-files-graphviz-226 indicates
that the error message basically means that the authors of graphviz consider record-style
labels to be deprecated and are no longer fixing errors with them. This patch changes
the labels to be in the HTML style, which seems to require duplicating style between all
the nodes, but it's not like these files are often edited.
The result is not exactly the same but is quite similar.
Reviewed-by: Armin Krezović <krezovic.armin@gmail.com>
Tested-by: Armin Krezović <krezovic.armin@gmail.com>
|
|
|
|
|
|
All fd.o projects are now covered by the Contributor Covenant. Include a
reference to this in the Contributing doc, making it clear that we are
all expected to behave like human beings.
Signed-off-by: Daniel Stone <daniels@collabora.com>
Reviewed-by: Yong Bakos <ybakos@humanoriented.com>
Acked-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Acked-by: Jonas Ådahl <jadahl@gmail.com>
|
|
GCC 7 now requires an explicit comment noting that case statements
without a break fall through. We already had one of those in the
scanner, but GCC wasn't smart enough to pick it up.
Quiet the warning by making the comment less elaborate.
Signed-off-by: Daniel Stone <daniels@collabora.com>
Reviewed-by: Yong Bakos <ybakos@humanoriented.com>
|
|
Signed-off-by: Eric Engestrom <eric.engestrom@imgtec.com>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
|
|
Used only internally and explicitly marked as such with commit
cf04b0a18f2 ("Move private definitions and prototypes to new
zwayland-private.h")
Signed-off-by: Emil Velikov <emil.velikov@collabora.com>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
|
|
Those struct members are no longer used so we can remove them.
Signed-off-by: Sergi Granell <xerpi.g.12@gmail.com>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
|
|
New IDs are internally dealt with as objects, however this test
expected to deal with 'n' as the uint32_t type that's just seen
through the wire. We should give it an object instead, and
expect an object from it.
https://bugs.freedesktop.org/show_bug.cgi?id=99899
Signed-off-by: Carlos Garnacho <carlosg@gnome.org>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Tested-by: Kalev Lember <kalevlember@gmail.com>
Reviewed-by: Yong Bakos <ybakos@humanoriented.com>
|
|
Signed-off-by: Bryce Harrington <bryce@osg.samsung.com>
|
|
|
|
|
|
|
|
Fix this set of warnings appearing three times during a build:
/home/pq/git/wayland/src/wayland-server.c:1868: warning: class
`wl_priv_signal' for related function `wl_priv_signal_init' is not
documented.
/home/pq/git/wayland/src/wayland-server.c:1884: warning: class
`wl_priv_signal' for related function `wl_priv_signal_add' is not
documented.
/home/pq/git/wayland/src/wayland-server.c:1899: warning: class
`wl_priv_signal' for related function `wl_priv_signal_get' is not
documented.
Our Wayland docbook don't include private things, so make sure these do
not end up there. This removes the mention of wl_priv_signal_emit from
the Server API docbook. I have no idea why the other functions did not
appear there.
Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Reviewed-by: Yong Bakos <ybakos@humanoriented.com>
|
|
connection-test.c did not cover wl_argument_from_va_list, so add one
test that specifically tests this method.
Signed-off-by: Yong Bakos <ybakos@humanoriented.com>
Reviewed-by: Daniel Stone <daniels@collabora.com>
|
|
Signed-off-by: Yong Bakos <ybakos@humanoriented.com>
Reviewed-by: Daniel Stone <daniels@collabora.com>
|
|
Check that all the objects in an event belong to the same client as
the resource posting it. This prevents a compositor from accidentally
mixing client objects and posting an event that causes a client to
abort with a cryptic message.
Instead the client will now be disconnected as it is when the compositor
tries to send a null for a non-nullable object, and a log message
will be printed by the compositor.
Reviewed-by: Yong Bakos <ybakos@humanoriented.com>
Reviewed-by: Bryce Harrington <bryce@osg.samsung.com>
Signed-off-by: Derek Foreman <derekf@osg.samsung.com>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
|
|
Until now, we haven't done anything to prevent sending additional
events to clients after posting an error.
Acked-by: Daniel Stone <daniels@collabora.com>
Signed-off-by: Derek Foreman <derekf@osg.samsung.com>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
|
|
These have grown a little in size but are almost identical, factor
out the common code.
Signed-off-by: Derek Foreman <derekf@osg.samsung.com>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
|
|
The old wl_signal is kept for backwards compatibility, as that is also
present in the deprecated public wl_resource struct, and that must be
kept working.
Signed-off-by: Giulio Camuffo <giulio.camuffo@kdab.com>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
|
|
Signed-off-by: Giulio Camuffo <giulio.camuffo@kdab.com>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
|
|
wl_list_for_each_safe, which is used by wl_signal_emit is not really
safe. If a signal has two listeners, and the first one removes and
re-inits the second one, it would enter an infinite loop, which was hit
in weston on resource destruction, which emits a signal.
This commit adds a new version of wl_signal, called wl_priv_signal,
which is private in wayland-server.c and which does not have this problem.
The old wl_signal cannot be improved without breaking backwards compatibility.
Signed-off-by: Giulio Camuffo <giulio.camuffo@kdab.com>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
|
|
Test if the global filter is effectively filtering out the global when
the filter returns false.
Signed-off-by: Olivier Fourdan <ofourdan@redhat.com>
|
|
|
|
When using a wl_global, a server may need to retrieve the associated
wl_interface and user data.
Add a couple of convenient functions wl_global_get_interface() and
wl_global_get_user_data() for this purpose.
Signed-off-by: Olivier Fourdan <ofourdan@redhat.com>
Reviewed-by: Yong Bakos <ybakos@humanoriented.com>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
|
|
Add a new API to let compositor decide whether or not a wl_global
should be advertised to the clients via wl_registry_bind() or
display_get_registry()
By using its own filter, the compositor can decide which wl_global would
be listed to clients.
Compositors can use this mechanism to hide their own private interfaces
that regular clients should not use.
- Hiding interfaces that expose compositor implementation details
makes it harder for clients to identify the compositor. Therefore
clients are a little less likely to develop compositor-specific
workarounds instead of reporting problems upstream.
- Hiding can be used to diminish the problems from missing namespacing:
if two compositors happen to use the same named global with
different interfaces for their special-purpose clients, the client
expecting the different interface would probably never see it
advertised.
Signed-off-by: Olivier Fourdan <ofourdan@redhat.com>
Reviewed-by: Jonas Ådahl <jadahl@gmail.com>
Reviewed-by: Yong Bakos <ybakos@humanoriented.com>
Acked-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
|
|
Unlike a wheel rotation, a wheel tilt is a discrete-only axis. Wheel rotations
are mapped to degrees in libinput but that that does not apply to wheel tilt
axes where there is no physical equivalent.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Jonas Ådahl <jadahl@gmail.com>
Acked-by: Daniel Stone <daniels@collabora.com>
Reviewed-by: Daniel Stone <daniels@collabora.com>
Reviewed-by: Yong Bakos <ybakos@humanoriented.com>
|
|
This was already in the DTD but not supported by the scanner.
The check for ever-increasing "since" tags is not strictly required for enum
entries as we control the binary value. But it keeps the xml file in
good order, preventing things like:
<entry name="first" value="…" />
<entry name="second" value="…" since="3"/>
<entry name="third" value="…" since="2"/>
<entry name="fourth" value="…" since="3"/>
If this is undesirable in the future the check can be removed without
side-effects.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
|
|
Same code we already had, just moved into a helper function
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Yong Bakos <ybakos@humanoriented.com>
Reviewed-by: Daniel Stone <daniels@collabora.com>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
|
|
These are the protocol.xml changes from:
66a26aeb2a: protocol: Remove inconsistent line breaks
a26ed0949e: protocol: indentation fixes
6a18a87727: protocol: Extend wl_touch with touchpoint shape and orientation
and a few other, smaller ones.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Daniel Stone <daniels@collabora.com>
Reviewed-by: Yong Bakos <ybakos@humanoriented.com>
Tested-by: Yong Bakos <ybakos@humanoriented.com>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
|
|
Despite their clear names, wl_array and wl_list members are undocumented,
resulting in doxygen warnings[1] when building documentation.
Document these members, suppressing the warnings.
[1] Warnings are visible when EXTRACT_ALL = NO.
Signed-off-by: Yong Bakos <ybakos@humanoriented.com>
Reviewed-by: Daniel Stone <daniels@collabora.com>
|
|
Documentation generation via doxygen includes wayland-util.c in its file
list. Although functions are documented in wayland-util.h, doxygen is
not automatically using the same documentation for functions in
wayland-util.c. In addition, everything listed in the doxygen page for
wayland-util.c is documented in the page for wayland-util.h and the
pages for corresponding structures. As such, the doxygen page for
wayland-util.c has no value, and is redundant.
Remove the doxygen page for wayland-util.c.
Signed-off-by: Yong Bakos <ybakos@humanoriented.com>
Acked-by: Peter Hutterer <peter.hutterer@who-t.net>
|
|
Doxygen truncates a WL_PRINTF function attribute, and there does not
seem to be any workaround[1]. When using the attribute like this:
typedef void (*wl_log_func_t)(const char *, va_list) WL_PRINTF(1, 0);
Doxygen generates something that looks like this:
typedef void (*wl_log_func_t)(const char *, va_list) WL_PRINTF(1,
Configure doxygen to consider WL_PRINTF(x,y) as predefined, so it does
not display the attribute at all in the generated documentation.
[1] https://bugzilla.gnome.org/show_bug.cgi?id=774741
Signed-off-by: Yong Bakos <ybakos@humanoriented.com>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
|
|
Add tests that ensure that wayland-scanner output for a given input does
not change unexpectedly. This makes it very easy to review
wayland-scanner patches.
Before, when patches were proposed for wayland-scanner, I had to
build wayland without the patches, save the generated files into a
temporary directory, apply the patches, build again, and diff the old
vs. new generated file.
No more. Now whenever someone makes intentional changes to
wayland-scanner's output, he will also have to patch the example output
files to match. That means that reviewers see the diff of the generated
files straight from the patch itself. Verifying the diff is true is as
easy as 'make check'.
The tests use separate example XML files instead of wayland.xml
directly, so that wayland.xml can be updated without fixing scanner
tests, avoiding the churn.
example.xml starts as a copy of wayland.xml. If wayland.xml starts using
new wayland-scanner features, they should be copied into example.xml
again to be covered by the tests.
This patch relies on the previous patch to actually add all the data
files for input and reference output.
The scanner output is fed through sed to remove parts that are allowed
to vary: the scanner version string.
v2: no need for scanner-test.sh to depend on the test data
Task: https://phabricator.freedesktop.org/T3313
Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Reviewed-by: Emilio Pozuelo Monfort <emilio.pozuelo@collabora.co.uk> (v1)
Reviewed-by: Yong Bakos <ybakos@humanoriented.com>
Tested-by: Yong Bakos <ybakos@humanoriented.com>
|
|
This patch adds the input and reference output data files for the
wayland-scanner tests to be added by the following patch.
The data files are split into their own patch because they are extremely
uninteresting to review:
- example.xml is just a copy wayland.xml from 1.12.0
- small.xml is a tiny dummy definition used for testing scanner
variations without causing lots of big output files
- the other files are wayland-scanner products from the xml files
Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Reviewed-by: Emilio Pozuelo Monfort <emilio.pozuelo@collabora.co.uk>
v2: update output due to 2c6350beb92816eb9213c4944d197485e788ef6d
Acked-by: Yong Bakos <ybakos@humanoriented.com>
|
|
Adjust the brief, clarify the behavior and arguments, correct a grammar
error, document the parameters, and document the return type.
Signed-off-by: Yong Bakos <ybakos@humanoriented.com>
Reviewed-by: Bryce Harrington <bryce@osg.samsung.com>
Reviewed-by: Daniel Stone <daniels@collabora.com>
|
|
8 spaces changed to one tab
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Daniel Stone <daniels@collabora.com>
Acked-by: Bryce Harrington <bryce@osg.samsung.com>
|
|
The third arg to strtol() specifies the base to assume for the number.
When 0 is passed, as is currently done in wayland-client.c, hexadecimal
and octal numbers are permitted and automatically detected and
converted.
I can find no indication that we would ever expect use of hexadecimal or
octal for socket fd's. So be explicit about what base we're assuming
here and avoid any potential surprises.
Signed-off-by: Bryce Harrington <bryce@osg.samsung.com>
Reviewed-by: Yong Bakos <ybakos@humanoriented.com>
Reviewed-by: Daniel Stone <daniels@collabora.com>
|
|
Add a doxygen comment for wl_log_func_t.
Signed-off-by: Yong Bakos <ybakos@humanoriented.com>
Reviewed-by: Daniel Stone <daniels@collabora.com>
|
|
Add missing protocol dir to uninstalled include path.
Signed-off-by: Reynaldo H. Verdejo Pinochet <reynaldo@osg.samsung.com>
Reviewed-by: Derek Foreman <derekf@osg.samsung.com>
Signed-off-by: Derek Foreman <derekf@osg.samsung.com>
Acked-by: Bryce Harrington <bryce@osg.samsung.com>
Signed-off-by: Daniel Stone <daniels@collabora.com>
|