...if we are resizing. The configure message
is the result from telling the client that resizing
has stopped and therefore not include the resizing
state. The current state is safe to use because
AckConfigure will move the state to last_acked
and the current state will be set on the next surface commit.
move fullscreen output geometry calculation to
a helper function
rename with_outputs to with_client_outputs and
take client instead of generic resource
the positioning of outputs, tracks
the surfaces on the outputs and
sends enter/leave for the surfaces
Additionally the output_map will
handle re-location of windows if
a output mode is changed, an output is
added or removed.
The shell has been updated to use the
primary output for the initial placement.
The fullscreen/maximize requests will now
handle the shell part correctly. For real
fullscreen output the rendering has to be
changed.
The output name is considered unique
and an output can be retrieved from
the map by location, output or name.
This can be used as the base for HiDPI
handling.
Removes the notion of Seats from `InputBackend` and replaces it with
`DeviceAdded` and `DeviceRemoved` events allowing compositors to
descriminate between single devices.
A new abstraction to model multiple seats on a single input backend
may be be added separately at a later time.
This changes the state handling logic of wl_surface to automatically
track subsurface pending in the form of transactions. The role enum
(and the associated type parameter) is no more, and replaced by a
general-purpose typemap-like container on surfaces.
The new logic is introduced in the files:
- `src/wayland/compositor/cache.rs`
- `src/wayland/compositor/transaction.rs`
The rest of the PR is the fallout of these changes, as well as a few
trivial clippy fixes.
Removes the renderer from the `DrmRenderSurface` allowing anvil
to use just one renderer per backend.
Since the old `DrmRenderSurface` was dependant on gbm anyway to import
buffers, the new `GbmBufferedSurface` does now only supports gbm as an allocator,
which hugely simplifies the code and also skips some unnecessary imports/exports.
* rework xdg_shell
use distinct surface roles for xdg_toplevel and
xdg_popup using a xdg_role! macro
* fix clippy warnings in shell
* added a generic DeadResource error and...
...added a result to xdg with_pending_state
Renamed the ToplevelState to ToplevelStateSet
Tracking of Frames, so that only one unique one can exist at a time
(gles does not allow multiple frames being rendered in parallel)
lead to very unfriendly lifetime-heavy code. A renderer is already
*unique*, just move the code there and add an error variant to catch
misuses.
- Since a lot of functionality is now in smithay's rendering module
we can get rid of shm_load, shaders and the glium dependency.
- glium_drawer becomes drawing and only features some code to get from surfaces
to textures for any(!) renderer.
(Should probably moved into smithay at some point as well.)
- buffer_utils is only necessary to query the buffer size anymore.
- disable egl-buffer support temporarily
Xwayland gives us a mapping between X11 window and WlSurface IDs via
special WL_SURFACE_ID messages. This commit uses these messages to find
the corresponding WlSurface. For this, the new client.get_resource API
from wayland-server is needed.
Signed-off-by: Uli Schlachter <psychon@znc.in>
This commits adds the necessary magic incantations to become the X11 WM
after Xwayland starts.
This uses the pure-Rust implementation from x11rb, but any other X11
crate could be used as well.
Signed-off-by: Uli Schlachter <psychon@znc.in>
This commit adds an xwayland feature to anvil. Right now, this feature
doesn't do much. anvil uses the smithay code to start XWayland, but does
not do anything with it once it is running.
Signed-off-by: Uli Schlachter <psychon@znc.in>
libinput provides sub-pixel precision for pointer motion & touch events.
Keep this precision by switching all coordinates values from input
events to f64 (rather than i32 or u32). Otherwise, values are rounded
and part of the movment is lost.
Potentially fixes#224
Change the session backend to rely on Signaler to propagate its
signals. Also introduce the Linkable trait to allow generic composition
of objects needing to listen for signals.
Introduce the `backend_session_elogind` cargo feature which pulls
`backend_session_logind` and makes the logind session backend seek
`libelogind.so` instead of `libsystemd.so`.
Fixes#127
Rework the Session Notifiers so that they are calloop event sources
by themselves, allowing them to be inserted by the user without the
`bind_session` dance.
Also update the logind backend to use the current dbus-rs API, rather
than the deprecated one.