doc, protocol: Clarify that serial numbers are opaque

Specification does not tell anything about behavior of
serial numbers, except that their values increase. It is
silent about wraparounds, and therefore does not restrict
compositors at all:

- a compositor that returns constant values may claim
  that it increases them by 2**32,
- a compositor that returns decreasing values may claim
  that it increases them by 2**32-1,
- a compositor that returns random values may claim that
  it increases them by 2**32+rand32().

Therefore:
- drop the useless wording about increasing numbers,
- do not specify that wl_display::sync returns the
  event serial number. This serial number cannot be
  passed to any request and hence is useless.

Signed-off-by: Mikhail Gusarov <dottedmag@dottedmag.net>
This commit is contained in:
Mikhail Gusarov 2022-01-13 17:43:15 +01:00
parent 985ab55d59
commit 1aa210fd29
2 changed files with 3 additions and 3 deletions

View file

@ -367,8 +367,8 @@
trigger further requests (such as button presses, key events,
pointer motions) carry serial numbers, and requests such as
wl_surface.set_popup require that the serial number of the
triggering event is specified. The server maintains a
monotonically increasing counter for these serial numbers.
triggering event is specified. Serial numbers are opaque,
clients should not assign any meaning to them.
</para>
<para>
Input events also carry timestamps with millisecond granularity.

View file

@ -46,7 +46,7 @@
compositor after the callback is fired and as such the client must not
attempt to use it after that point.
The callback_data passed in the callback is the event serial.
The callback_data passed in the callback is not specified.
</description>
<arg name="callback" type="new_id" interface="wl_callback"
summary="callback object for the sync request"/>