Commit graph

1635 commits

Author SHA1 Message Date
56230f0ade fix: keep tokio runtime available for compositor 2026-05-24 16:08:29 +02:00
Niklas Herder
28258e5a5f cursor: Add idle-hide timeout
Adds a cursor_hide_timeout config key (Option<u32> seconds) to
CosmicCompConfig. When set, the cursor is hidden after the configured
period of pointer inactivity and revealed again by any pointer event.
Touch input does not count as activity (no visible cursor to surface).

Implementation:
- Per-seat hidden flag, calloop timer token, and last-armed Instant on
  CursorStateInner.
- notify_cursor_activity called from each pointer-related input branch
  (motion, button, axis, tablet) resets the flag and reschedules the
  timer; rapid successive calls are coalesced behind a 100ms throttle
  so high-frequency mice don't churn the calloop timer source.
- On timer fire, the hidden flag is set, draw_cursor short-circuits to
  an empty element list, and a render is scheduled. Active pointer
  grabs (drags, resizes) suppress the hide.
- Config reload arms or cancels the timer immediately; None as the
  configured value collapses the cancel path into the same function.

Closes #2231.

Drafted with Claude (Anthropic); reviewed and tested by the committer.
2026-05-22 14:14:17 +02:00
Hojjat
451b8319d6 fix: ignore configure requests from fullscreen windows
Fixes steam big picture mode full screen not taking the whole screen
2026-05-20 19:19:21 -06:00
Hojjat
200074e580 fix: fullscreen x11 games opening as floating/tiled windows 2026-05-20 18:30:03 -06:00
Levi Portenier
8450e89de4
Merge pull request #2381 from dra11y/fix-magnifier-scroll
fix(magnifier): smooth mouse wheel zoom and respect natural scroll direction
2026-05-20 11:39:42 -06:00
Tom Grushka
c776eeac03 change a11y zoom easing function from EaseInOutCubic to Linear to avoid lagging mouse wheel scroll 2026-05-19 17:46:21 -06:00
Tom Grushka
657f0aeddf revert self.update_zoom to update with wheel 2026-05-19 16:30:46 -06:00
Victoria Brekenfeld
61e677e39f kms: Try to re-open the device on permission errors after resume 2026-05-19 19:26:25 +02:00
Victoria Brekenfeld
23b198f30b kms: Fix surface drop_and_join 2026-05-19 19:26:25 +02:00
Victoria Brekenfeld
61149d95d0 xwm: Reflect sticky state 2026-05-19 19:26:25 +02:00
Victoria Brekenfeld
85630236fa xwm: Support sticky requests for unmapped windows 2026-05-19 19:26:25 +02:00
Victoria Brekenfeld
6e4551a200 shell/element: Drop minimize/mapping X11 workaround 2026-05-19 19:26:25 +02:00
Victoria Brekenfeld
9defbe7b13 shell/element: Throttle X11 resizes as well via sync-req 2026-05-19 19:26:25 +02:00
Ian Douglas Scott
4106904a7e chore: Update smithay with Dispatch2 2026-05-19 19:26:25 +02:00
Tom Grushka
92fcceba54 fix(magnifier): smooth mouse wheel zoom and respect natural scroll direction
- Disable animation for mouse wheel zoom to eliminate the timing race
  that causes lag and sudden jumps. Each wheel tick now zooms instantly.
- Invert zoom direction when natural scrolling is enabled so that
  forward scroll zooms in, matching macOS/Windows behavior.
2026-05-15 15:51:24 -06:00
Hojjat
b5186ef21a fix: restore snapped windows as snapped after maximize/minimize 2026-05-13 12:43:02 +02:00
Hojjat
7c02df250e fix: restore the window to where it was before the drag
Restoring a window after snapping it to a corner, or maximizing it
should restore to where the window was before the drag, not after the
drop.
2026-05-13 12:43:02 +02:00
Peter Krull
b955789a4e (fix) Reject resize_request on surfaces which are already being resized 2026-05-07 15:00:38 -06:00
KENZ
677be79635 Unconstrain the IME popup when it appeared, resized, requested to
repositioned

- places the IME popup correctly.
- adjusts its position to considering the output (screen) rect.
  - offset if right edge overflows
  - flip vertically if bottom edge overflows
2026-05-07 15:00:24 -06:00
KENZ
7a10fb1cc8 refactor: change PopupSurface args to PopupKind of position_popup_within_rect() paths
- to support InputMethod popup kind in later commit
2026-05-07 15:00:24 -06:00
KENZ
f62c88a3d9 refactor: unify popup positioning logic for tiled layout into
position_popup_within_rect()
2026-05-07 15:00:24 -06:00
KENZ
1a57c104f6 refactor: extract positioning popups within global rect logic
- preparation to make unconstrain_popup() PopupKind agnostic
2026-05-07 15:00:24 -06:00
KENZ
977d4c2dca refactor: make get_popup_toplevel() PopupKind agnostic
- for preparation to make unconstrain_popup() PopupKind agnostic.
2026-05-07 15:00:24 -06:00
Victoria Brekenfeld
b5a1a6d317 kms: Recreate graphics contexts on resume 2026-05-05 14:44:13 -06:00
Victoria Brekenfeld
9b89a1cc77 kms: Wipe dpms state on resume 2026-05-05 14:44:13 -06:00
Ian Douglas Scott
a5474e8c76 Fix clippy lints
Like Smithay, disable `clippy::collapsible_match`. It seems prone to
offering dubious suggestions.
2026-04-27 14:51:46 -07:00
Ian Douglas Scott
826ad9a91a chore: Update smithay 2026-04-27 14:51:46 -07:00
Ian Douglas Scott
472ffa5f30 image-copy: Don't panic if ImageCaptureSourceKind udata is undefined
We want to merge this when updating Smithay to have
https://github.com/Smithay/smithay/pull/1961, so that we don't panic the
the output/toplevel already has no strong references when the source is
created.
2026-04-27 14:51:46 -07:00
Victoria Brekenfeld
53e0db28ac chore: Update smithay 2026-04-27 14:51:46 -07:00
ZeusCraft10
21679f215a fix: Prevent system hang on double Caps Lock press 2026-04-20 12:10:07 -06:00
Hojjat
fdf015cbcf fix: consider SSD/tab height when calculating last server size 2026-04-20 12:08:47 -06:00
Victoria Brekenfeld
769ca13647 session: Make sure to mark the socket as CLOEXEC early 2026-04-20 19:24:19 +02:00
olekawaii
4df95190db Add setting to toggle workspace wrapping 2026-04-14 17:42:57 +02:00
Hojjat
3e84968dac fix: clean up pending_windows for surfaces that were never mapped 2026-04-07 16:14:52 +02:00
Victoria Brekenfeld
b1f59bd108 state: call image-copy cleanup on refresh 2026-03-27 12:45:43 +01:00
Victoria Brekenfeld
e1ff0309c7 wayland/image-copy-capture: Break toplevel reference cycle 2026-03-27 12:45:43 +01:00
Victoria Brekenfeld
615789cb14 surface: Introduce WeakCosmicSurface 2026-03-27 12:45:43 +01:00
Salvatore Gabriele La Greca
9ad5c916f3
layout/floating: allow size altering if window was maximized (#2038) 2026-03-27 11:56:34 +01:00
Ilia Malanin
06ece0fdcd shell: Return surface from take_fullscreen for symmetry with remove_fullscreen 2026-03-27 11:56:04 +01:00
Ilia Malanin
07d584dadd shell: Simplify early return with take_if 2026-03-27 11:56:04 +01:00
Ilia Malanin
90ce9cab90 shell: Preserve fullscreen state when moving window between workspaces 2026-03-27 11:56:04 +01:00
Ashley Wulber
1dab42ed56 fix: break from loop instead of unwrapping 2026-03-26 14:32:32 -04:00
Ian Douglas Scott
7fa5bd6b91 image-copy: Do not panic on ImageCaptureSourceKind::Destroyed
The way this was handled previously is incorrect. We should still handle
creation of a capture session, just send `stopped` when it is created.

This can be tested by creating a capture source and session for a
workspace that has been removed. Toplevel and output sources have a
different issue in `smithay`: https://github.com/Smithay/smithay/pull/1961

Should fix https://github.com/pop-os/cosmic-epoch/issues/3319.
2026-03-26 18:23:20 +01:00
Victoria Brekenfeld
5216eb50ba chore: Fix remaining clippy lints 2026-03-24 16:23:43 +01:00
Victoria Brekenfeld
3a0b1ae5d2 Partially revert "x11: stop remapping minimized windows on restore"
This re-introduces the xwayland remap on un-minimize hack, but limited
to fullscreen applications.
2026-03-19 16:47:45 +01:00
Vukašin Vojinović
edc7758967 chore: update libcosmic
Improves header bar widget behavior.
2026-03-18 18:19:03 +01:00
Vukašin Vojinović
89a50197d2 refactor: use jiff instead of time 2026-03-18 18:19:03 +01:00
Vukašin Vojinović
2ca99c670a chore: clippy 2026-03-18 18:19:03 +01:00
Vukašin Vojinović
d02051d16a chore: remove unneeded dependencies 2026-03-18 18:19:03 +01:00
Ian Douglas Scott
40c7eb26cd image-copy: Store offscreen buffer for shm capture in session
Avoid allocating a GPU buffer every frame, and avoid re-rendering
everything.
2026-03-18 01:34:33 +01:00