aboutsummaryrefslogtreecommitdiff
path: root/include
AgeCommit message (Collapse)Author
2018-12-05rootston: use box for views positionLouis Taylor
2018-12-05rootston: use int for width, heightLouis Taylor
2018-12-04xdg-shell: emit xdg_surface destroy when role object is destroyedemersion
Fixes https://github.com/swaywm/wlroots/issues/1407
2018-12-03Install wlr_pointer_constraints_v1.hDuncaen
2018-12-02Merge pull request #1403 from emersion/swap-buffers-damage-coordsDrew DeVault
output: switch swap_buffers damage to output-buffer-local coords
2018-12-01output: switch swap_buffers damage to output-buffer-local coordsemersion
This is one more step towards [1]. This gives more freedom to the compositor wrt. how it handles damage. [1]: https://github.com/swaywm/wlroots/issues/1363
2018-11-29primary-selection: introduce wlr_primary_selection_sourceemersion
This is a common interface that can be used for all primary selection protocols, as discussed in [1]. A new function wlr_seat_set_primary_selection is added to set the primary selection for all protocols. The seat now owns again the source, and resets the selection to NULL when destroyed. [1]: https://github.com/swaywm/wlroots/issues/1367#issuecomment-442403454
2018-11-27gtk-primary-selection: use impl pattern for sourcesemersion
2018-11-27gtk-primary-selection: remove offer structemersion
We don't need it, we can use the device instead.
2018-11-27gtk-primary-selection: refactor everything, untie from seatemersion
This commits completely refactors wlr_gtk_primary_selection. The goal is to remove gtk-primary-selection state from the seat and better handle inert resources where it makes sense. wlr_seat_client.primary_selection_devices has been removed and replaced by wlr_gtk_primary_selection_device. This allows us to make offers inert when the current selection is replaced. wlr_seat_set_primary_selection has been removed because it relied on wlr_seat instead of wlr_gtk_primary_selection_device_manager. A new function, wlr_gtk_primary_selection_device_manager_set_selection (candidate for the longest function name in wlroots) has been added. It doesn't take a serial anymore as serial checking only makes sense for set_selection requests coming from Wayland clients (serial checking is now done in the Wayland interface implementation). Since wlr_gtk_primary_selection_device_manager is now required to set the selection, a new function wlr_xwayland_set_gtk_primary_selection_device_manager (candidate number two for longest function name) has been added. Devices are now made inert when the seat goes away. Future work includes removing the last primary selection bits from the seat, mainly wlr_seat.primary_selection_source and wlr_seat.events.primary_selection, replacing those with new fields in wlr_gtk_primary_selection_device. Or maybe we could keep those in the seat and replace them with a re-usable interface (for future zwp_primary_selection_v1 support). We need to think how we'll sync these three protocols (GTK, X11 and wayland-protocols). See https://github.com/swaywm/wlroots/issues/1388
2018-11-26Merge pull request #1387 from emersion/rename-gtk-primary-selectionDrew DeVault
Rename wlr_primary_selection to wlr_gtk_primary_selection
2018-11-26Merge pull request #1384 from emersion/data-multiple-devicesDrew DeVault
data-device: allow multiple devices for the same seat
2018-11-26surface: fix destroyed subsurfaces handlingemersion
wlr_subsurface_from_wlr_surface can return NULL if the wl_surface is still alive and if the wl_subsurface has been destroyed. Make sure we check for NULL. Fixes https://github.com/swaywm/sway/issues/3195
2018-11-26data-device: allow multiple devices for the same seatemersion
This commit makes it possible for a single client to have multiple data devices for the same seat. This fixes issues with Firefox. This mainly removes wlr_data_source.offer. We make sure we create one data offer per device. We now make the offer inert when the source is destroyed. Fixes the second half of https://github.com/swaywm/wlroots/issues/1041
2018-11-25Merge pull request #1375 from emersion/tablet-segfaultDrew DeVault
tablet-v2: fix segfault on display destroy
2018-11-24output: add wlr_output_preferred_read_format()Ilia Bozhinov
The read format is dependent on the output, so we first need to make it current. This fixes a race condition in wlr-screencopy-v1 where a dmabuf client would cause EGL_NO_SURFACE to be bound at the time when screencopy needs to query for the preferred format, causing GL errors.
2018-11-23Rename wlr_primary_selection to wlr_gtk_primary_selectionemersion
2018-11-21gtk-primary-selection: track resourcesemersion
2018-11-21gtk-primary-selection: support multiple devicesemersion
When a client was creating multiple data devices for the same seat, we were only creating one resource. This is a protocol error. Instead, create one offer per data device. This commit also makes offers inert when their source is destroyed. Fixes part of https://github.com/swaywm/wlroots/issues/1041 Supersedes https://github.com/swaywm/wlroots/pull/1113
2018-11-13output: add wlr_output_render_software_cursorsemersion
Rendering in wlr_output_swap_buffers has unfortunate side-effects.
2018-11-13output: remove wlr_output_set_fullscreen_surfaceemersion
This wasn't using direct scan-out. Direct scan-out will probably work differently with @ascent12's work anyway.
2018-11-13backend/x11: Hide cursor with XfixesScott Anderson
2018-11-13backend/x11: Remove old input functionsScott Anderson
This also allows us to remove xcb-xkb, since Xinput will now give us the appropriate XKB modifiers with each event.
2018-11-13backend/x11: Add new Xinput eventsScott Anderson
2018-11-13backend/x11: Check for xinput extensionScott Anderson
2018-11-13backend/x11: Make header order consistentScott Anderson
2018-11-13backend/x11: Rename xcb_conn to xcbScott Anderson
When the Xlib connection is removed, this _conn suffix is going to be pointless. I'm removing this preemtively for that.
2018-11-12Merge pull request #1372 from emersion/config10Drew DeVault
Use #if instead of #ifdef for wlroots config data
2018-11-12tablet-v2: fix segfault on display destroyemersion
2018-11-12Use #if instead of #ifdef for wlroots config dataemersion
This prevents some annoying issues when e.g. not including wlr/config.h or making a typo in the guard name.
2018-11-11backend/wayland: Make header order consistentScott Anderson
2018-11-11backend/wayland: Move initilisation code earlierScott Anderson
The renderer redesign is going to need the render fd before the backend is fully started, so we have to move the wl registry code to when the backend is created instead of when it is started. We also need to stash the wl_keyboard and emit it to library users later, once they've added their listeners and started the backend.
2018-11-11backend/wayland: Move registry into backendScott Anderson
Registry was a very small file, and is heavily related to the backend, so there is not point in keeping them separate.
2018-11-09Tell Mesa not to attempt X11 headersCedric Sodhi
If no X11 related things are being built, tell Mesa's eglplatform.h not to attempt inclusion of associated X11 header.
2018-11-09Remove WLR_HAS_POSIX_FALLOCATE from build systemsghctoma
2018-11-04Merge pull request #1261 from arandomhuman/damage-controlDrew DeVault
Fix damage tracking for surfaces with transforms
2018-11-04surface: fix wlr_surface_get_effective_damage to give surface coordsemersion
Transforms were applied, but scale wasn't.
2018-11-04render/gles2: check for GL_OES_EGL_image_externalemersion
2018-11-04render/gles2: remove assumptions about supported formatsemersion
We were assuming GL_BGRA_EXT was always supported. We now check that it's supported for rendering. We fail if it isn't because this format is specified as "always supported" by the Wayland protocol. We also check if it's supported for reading pixels. A new preferred_read_format function returns the preferred format that can be used to read pixels. This is used by the screencopy protocol.
2018-10-29backend/drm: fix frame scheduling on secondary GPUsemersion
There was a missing copy_drm_surface_mgpu call in drm_connector_schedule_frame so we asked for a pageflip with an unknown BO, resulting in ENOENT. Additionally, this commit makes schedule_frame return a bool indicating failures. This allows schedule_frame_handle_idle_timer to only set frame_pending to true if a frame has been successfully scheduled. Thus, if a pageflip fails, rendering won't be blocked forever anymore. In case a pageflip is already pending, true is returned because a frame has already been scheduled and will be sent sometime soon.
2018-10-28util: use shm_open for in-memory filesemersion
shm_open is a POSIX function creating an in-memory file. Using it simplifies the code and removes the dependency on XDG_RUNTIME_DIR. The only downside is that we need to generate a random name for the shm file.
2018-10-28render: on Wayland, make eglSwapBuffers non-blockingemersion
2018-10-27xwayland: fix typo to enable transparencyemersion
We spent literally hours trying to debug this. Turns out it's a typo. Kill me.
2018-10-19Merge pull request #1287 from emersion/source-seat-clientDrew DeVault
data-device: remove wlr_data_source.seat_client
2018-10-16Use enum wl_shm_format for gles2 texture formatsnyorain
Also rephrase the write_pixels comment.
2018-10-15Remove fmt parameter from wlr_texture_write_pixelsnyorain
It's not allowed to change the format of a texture so remove the confusing parameter.
2018-10-12Support older wlr_linux_dmabuf_v1 clientsnyorain
If a client uses an older version of the dmabuf protocol, use the `formats` event instead of `modifiers` (since that didn't exist in older versions). With a bit of necessary guessing, support dmabuf importing even when EGL_EXT_image_dma_buf_import_modifiers isn't present instead of failing up front.
2018-10-12input-method-v2: fix include guard nameemersion
2018-10-12Merge pull request #1203 from dcz-purism/inputDrew DeVault
Support input method and text input
2018-10-12Include wlr/config.h in x11.hScott Anderson
This fixes a warning from the linker when using LTO, due to mismatched types.