summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* Bump version to 3.35.903.35.90Florian Müllner2020-02-062-1/+35
| | | | Update NEWS.
* wayland-pointer: Bail unconditionally if without native backendDaniel van Vugt2020-02-051-7/+2
| | | | | | | | | | Using `-Dnative_backend=false` caused build failure due to a missing (implicit) definition of `META_IS_BACKEND_X11`. But if we define it properly then that just leaves some of the function's locals uninitialized and it will never work anyway. Just return unconditionally if there's no native backend to initialize the variables. Closes: https://gitlab.gnome.org/GNOME/mutter/issues/1025
* background: Scale monitor_area after texture creationDaniel van Vugt2020-02-041-6/+20
| | | | | | | | | | | | | | | | | Scaling the `monitor_area` before texture creation was just wasting megabytes of memory on resolution that the monitor can't display. This was also hurting runtime performance. Example: Monitor is natively 1920x1080 and scale set to 3. Before: The monitor texture allocated was 5760x3250x4 = 74.6 MB After: The monitor texture allocated is 1920x1080x4 = 8.3 MB Closes: https://gitlab.gnome.org/GNOME/gnome-shell/issues/2118 https://gitlab.gnome.org/GNOME/mutter/merge_requests/1004
* backends/native: Emit signals for virtual devicesOlivier Fourdan2020-02-041-0/+8
| | | | | | | | | | | | | | | | | | | | | When creating a virtual device for the native backend, no "device-added" is emitted. Similarly, no "device-removed" signal is emitted either when the virtual device is disposed. However, the backend plugs into the "device-added" signal to set the monitor device. Without the "device-added" signal being emitted, the monitor associated with a virtual device remains NULL. That later will cause a crash in `meta_idle_monitor_reset_idlettime()` called from `handle_idletime_for_event()` when processing events from a virtual device because the device monitor is NULL. Make sure to emit the "device-added" signal when creating a virtual device, and the "device-removed" when the virtual device is disposed. https://gitlab.gnome.org/GNOME/mutter/merge_requests/1037
* window: Ignore requests to be placed on non-existent workspacesFlorian Müllner2020-02-041-1/+4
| | | | | | | | | | | | | | | When an X11 window requests an initial workspace, we currently trust it that the workspace actually exists. However dynamic workspaces make this easy to get wrong for applications: They make it likely for the number of workspaces to change between application starts, and if the app blindly applies its saved state on startup, it will trigger an assertion. Make sure that we pass valid parameters to set_workspace_state(), and simply let the workspace assignment fall through to the default handling otherwise. https://gitlab.gnome.org/GNOME/mutter/issues/1029
* core: Extend list of image formats to be stored in the clipboard managerRobert Mader2020-02-031-0/+4
| | | | | | | | | These types are probably common enough to support. See also: https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/MIME_types/Complete_list_of_MIME_types https://gitlab.gnome.org/GNOME/mutter/merge_requests/1034
* core: Define specific image formats to be stored in the clipboard managerCarlos Garnacho2020-02-031-1/+3
| | | | | | | | And order those preferences in order of lossiness (jpeg < png < bmp). This avoids us from prefering other formats that are not useful or widely recognized. https://gitlab.gnome.org/GNOME/mutter/merge_requests/939
* core: Demote image formats' priority from preservation in clipboard managerCarlos Garnacho2020-02-031-1/+1
| | | | | | | | | | | | Most usually, applications either expose clipboard content either as text or as images, so the prioritization here is pointless. However there's some outliers like LibreOffice Calc which exports content as both image and text formats (besides other internal ones). In that mixed case, we probably prefer to keep text formats, rather than image based ones. Closes: https://gitlab.gnome.org/GNOME/mutter/issues/919
* backends/x11: Fix use after free on device removalSebastian Keller2020-02-011-3/+2
| | | | | | | | | The devices_by_id hash table is responsible for managing the reference to the devices. In remove_device however, for non-core devices there are additional calls to dispose/unref, after the last reference has already been dropped by the hash table. https://gitlab.gnome.org/GNOME/mutter/merge_requests/1032
* wayland: Handle dragging from/dropping to v1 data device usersCarlos Garnacho2020-02-011-2/+15
| | | | | | | | Interoperation between wl_data_device_manager v1 and v3 got broken at some point. Ensure that we resort to the "copy" action if either the drop site or the drag source are from a client that requested v1. Closes: https://gitlab.gnome.org/GNOME/mutter/issues/965
* clutter/actor: Fix GValue leak when overwriting transition valuesSebastian Keller2020-02-011-9/+2
| | | | | | | | When the 'initial'/'final' values of an existing transition were being overwritten, the GValues used in _clutter_actor_create_transition() were not being unset. https://gitlab.gnome.org/GNOME/mutter/merge_requests/1033
* core: Fix task leak in meta_selection_source_memory_read_asyncSebastian Keller2020-02-011-1/+1
| | | | https://gitlab.gnome.org/GNOME/mutter/merge_requests/1001
* selection: Fix task leak in error case of source_read_cbSebastian Keller2020-02-011-0/+1
| | | | | Fixes the last part of https://gitlab.gnome.org/GNOME/mutter/issues/1006 https://gitlab.gnome.org/GNOME/mutter/merge_requests/1001
* x11-selection: Unref owners and cancellables on shutdownSebastian Keller2020-02-011-0/+12
| | | | | | | | | | | Selection owners are set using g_set_object in source_new_cb, but that reference is never removed on shutdown. Similarly the cancellables created in handle_xfixes_selection_notify are never freed on shutdown. Fixes parts of https://gitlab.gnome.org/GNOME/mutter/issues/1006 https://gitlab.gnome.org/GNOME/mutter/merge_requests/1001
* display: Unref selection on shutdownSebastian Keller2020-02-011-0/+1
| | | | | | | | Otherwise it will be leaked and the dispose method added in the previous commit would never be run. Fixes parts of https://gitlab.gnome.org/GNOME/mutter/issues/1006 https://gitlab.gnome.org/GNOME/mutter/merge_requests/1001
* selection: Unref selection owners on disposeSebastian Keller2020-02-011-0/+18
| | | | | | | | Selection owners are set using g_set_object, which adds a reference to the owner, which then never was removed on shutdown. Fixes parts of https://gitlab.gnome.org/GNOME/mutter/issues/1006 https://gitlab.gnome.org/GNOME/mutter/merge_requests/1001
* x11-selection: Don't store copies of strings that are not being usedSebastian Keller2020-02-011-16/+4
| | | | | | | | | MetaX11SelectionOutputStream was storing copies of strings only to use them in init and then free them in finalize. This was also causing a small leak, because one of these strings was not freed. Instead of doing that just don't create these unnecessary copies in the first place. https://gitlab.gnome.org/GNOME/mutter/merge_requests/1001
* x11-selection: Plug potential GInputStream leakSebastian Keller2020-02-011-0/+1
| | | | | | | The stream was not freed in the error case. I have never observed this one in practice though. https://gitlab.gnome.org/GNOME/mutter/merge_requests/1001
* x11-selection: Plug MetaSelectionSourceX11 leakSebastian Keller2020-02-011-0/+1
| | | | | | | | meta_selection_source_x11_new_finish() transfers the ownership of the selection source, but source_new_cb() was not freeing it. Fixes https://gitlab.gnome.org/GNOME/mutter/issues/998 https://gitlab.gnome.org/GNOME/mutter/merge_requests/1001
* clipboard-manager: Plug mimetypes list leakSebastian Keller2020-02-011-2/+6
| | | | | Fixes https://gitlab.gnome.org/GNOME/mutter/issues/1005 https://gitlab.gnome.org/GNOME/mutter/merge_requests/1001
* cogl: Inline cogl_use_program into its one callerAdam Jackson2020-01-313-23/+12
| | | | https://gitlab.gnome.org/GNOME/mutter/merge_requests/1015
* cogl: Inline _cogl_framebuffer_remove_all_dependencies into its one callerAdam Jackson2020-01-312-14/+4
| | | | https://gitlab.gnome.org/GNOME/mutter/merge_requests/1015
* cogl: Remove unused _cogl_pipeline_get_layersAdam Jackson2020-01-312-48/+0
| | | | https://gitlab.gnome.org/GNOME/mutter/merge_requests/1015
* cogl: Remove unused cogl_program_use and friendsAdam Jackson2020-01-314-196/+2
| | | | https://gitlab.gnome.org/GNOME/mutter/merge_requests/1015
* cogl: Remove unused _cogl_framebuffer_set_clip_stackAdam Jackson2020-01-312-23/+1
| | | | https://gitlab.gnome.org/GNOME/mutter/merge_requests/1015
* cogl: Remove unused _cogl_framebuffer_{push,pop}_projectionAdam Jackson2020-01-312-30/+0
| | | | https://gitlab.gnome.org/GNOME/mutter/merge_requests/1015
* cogl: Remove unused p-axis texture wrap modeAdam Jackson2020-01-3117-200/+29
| | | | | | Unused since removing 3D textures. https://gitlab.gnome.org/GNOME/mutter/merge_requests/1015
* cogl: Mark _cogl_buffer_access_to_gl_enum staticAdam Jackson2020-01-312-4/+1
| | | | https://gitlab.gnome.org/GNOME/mutter/merge_requests/1015
* cogl: Remove unused _cogl_framebuffer_try_creating_gl_fboAdam Jackson2020-01-312-34/+0
| | | | | | Unused since the cogl-gles2 removal in 7e8a8649. https://gitlab.gnome.org/GNOME/mutter/merge_requests/1015
* cogl: Remove unused cogl.symbolsAdam Jackson2020-01-311-934/+0
| | | | https://gitlab.gnome.org/GNOME/mutter/merge_requests/1015
* wayland/data-device: Small style fixesRobert Mader2020-01-311-2/+2
| | | | https://gitlab.gnome.org/GNOME/mutter/merge_requests/1031
* wayland/data-device: Guard against a potential crashRobert Mader2020-01-311-1/+2
| | | | https://gitlab.gnome.org/GNOME/mutter/merge_requests/1031
* wayland/data-device: Cancel drag source when the drag finished unsuccessfullyRobert Mader2020-01-311-4/+26
| | | | | | | | | | When a drag was performed but did not finish successfully, e.g. because no mimetype was accepted, we need to send the source cancel event so clients know they can destroy the drag source (since version 3). Fixes https://gitlab.gnome.org/GNOME/mutter/issues/740 https://gitlab.gnome.org/GNOME/mutter/merge_requests/1031
* backends/native: Use proper method for getting core idle monitorSebastian Keller2020-01-301-1/+1
| | | | | | | | | e9fbbd5853 changed meta_backend_get_idle_monitor() to use ClutterInputDevice pointers instead of device IDs, but did not adjust the call in meta_backend_native_resume() which was still using 0 to get the core idle monitor resulting in a NULL pointer dereference. https://gitlab.gnome.org/GNOME/mutter/merge_requests/1029
* clutter: Fix input device node path leakSebastian Keller2020-01-301-0/+1
| | | | https://gitlab.gnome.org/GNOME/mutter/merge_requests/1030
* clutter/actor: Use the new shallow relayout APIDaniel van Vugt2020-01-301-2/+30
| | | | | | | | | | | | | | | | | | | | If an actor sets flag `CLUTTER_ACTOR_NO_LAYOUT` then that means it is (or should be) unaffected by `queue_relayout` calls in its children. So we can avoid propagating `queue_relayout` all the way up to the stage and avoid a full stage relayout each time. But those children whose parent has `CLUTTER_ACTOR_NO_LAYOUT` still need to be allocated at some point. So we do it at the same point where it happened before. Only we now queue a *shallow* relayout so the `allocate` run on the next frame doesn't need to descend the whole actor tree anymore. Only a subtree and hopefully very small. For free-floating and top-level actors this provides a measurable performance benefit. According to Google Profiler, calls to `_clutter_stage_maybe_relayout` are now so cheap that they no longer show up in performance profiles. https://gitlab.gnome.org/GNOME/mutter/merge_requests/575
* clutter/stage: Add an API for shallow relayoutsDaniel van Vugt2020-01-302-34/+74
| | | | | | | Where "shallow" means you can specify any actor instead of every relayout having to start from the stage. https://gitlab.gnome.org/GNOME/mutter/merge_requests/575
* backends: Use latest pointer position if no pointer constrain existsCarlos Garnacho2020-01-301-2/+2
| | | | | | | | | | | | | The meta_seat_native_constrain_pointer() function receives the current pointer position, and the new pointer position as in/out parameters. We were however calculating the new coordinates based on the last pointer position if there was no pointer constrain in place. Fortunately to us, this didn't use to happen often/ever, as a pointer constrain function is set on MetaBackend initialization. This behavior did also exist previously in MetaDeviceManagerNative. https://gitlab.gnome.org/GNOME/mutter/merge_requests/1028
* backends: Move warp_pointer() to ClutterSeatCarlos Garnacho2020-01-3012-92/+67
| | | | | | | The onscreen pointer sprite is a per-seat element, so it makes sense to move pointer warping over there too. https://gitlab.gnome.org/GNOME/mutter/merge_requests/852
* backends: Set pointer constrain/relative motion hooks before backend initCarlos Garnacho2020-01-301-2/+2
| | | | | | | | The backend being initialized triggers a pointer warp (and motion event) where we want to observe the callbacks put in place. So ensure we set up the hooks before that could happen. https://gitlab.gnome.org/GNOME/mutter/merge_requests/852
* backends: Drop get_relative_motion_deltas() vfuncCarlos Garnacho2020-01-304-58/+10
| | | | | | | | | Just go ATM through backend checks, and looking up directly the native event data, pretty much like the rest of the places do that... Eventually would be nice to have this information in ClutterEvent, but let's not have it clutter the MetaBackend class. https://gitlab.gnome.org/GNOME/mutter/merge_requests/852
* backends: Do not use device IDs on idle monitorsCarlos Garnacho2020-01-308-56/+56
| | | | | | | | Device IDs are somewhat x11 specific, seems better to avoid those on public API. We can rely everywhere on ClutterInputDevice, so use it instead. https://gitlab.gnome.org/GNOME/mutter/merge_requests/852
* clutter: Drop ClutterDeviceManagerCarlos Garnacho2020-01-3025-1446/+292
| | | | | | | This is mostly replaced by ClutterSeat, which offers a per-seat instead of a global device abstraction. https://gitlab.gnome.org/GNOME/mutter/merge_requests/852
* tests: Replace ClutterDeviceManager usage in favor of ClutterSeatCarlos Garnacho2020-01-303-18/+23
| | | | https://gitlab.gnome.org/GNOME/mutter/merge_requests/852
* backends: Replace ClutterDeviceManager usage in favor of ClutterSeatCarlos Garnacho2020-01-3011-105/+114
| | | | https://gitlab.gnome.org/GNOME/mutter/merge_requests/852
* clutter: Replace ClutterDeviceManager usage in favor of ClutterSeatCarlos Garnacho2020-01-303-20/+15
| | | | https://gitlab.gnome.org/GNOME/mutter/merge_requests/852
* backends: Make meta_backend_update_last_device() take a clutter deviceCarlos Garnacho2020-01-304-28/+22
| | | | | | | Instead of a pretty x11 specific device ID. This also updates the argument of the ::last-device-changed signal to be a ClutterInputDevice. https://gitlab.gnome.org/GNOME/mutter/merge_requests/852
* backends: Move native keymap manipulation functions to MetaSeatNativeCarlos Garnacho2020-01-307-237/+204
| | | | | | | Since the ClutterKeymap is obtained through the ClutterSeat, it makes sense to have these manipulation functions in the ClutterSeat impl. https://gitlab.gnome.org/GNOME/mutter/merge_requests/852
* core: Replace ClutterDeviceManager usage in favor of ClutterSeatCarlos Garnacho2020-01-301-3/+3
| | | | https://gitlab.gnome.org/GNOME/mutter/merge_requests/852
* wayland: Replace ClutterDeviceManager usage in favor of ClutterSeatCarlos Garnacho2020-01-307-44/+38
| | | | https://gitlab.gnome.org/GNOME/mutter/merge_requests/852