1
0
Fork 0
mirror of https://github.com/hyprwm/Hyprland synced 2025-04-08 21:52:19 +02:00
Commit graph

5980 commits

Author SHA1 Message Date
nyx
ea852965ff
xdg-shell: fix some null refs () 2025-04-08 19:43:15 +02:00
Vaxry
260d8e1f71
Permission Manager: add permission management for screencopy () 2025-04-08 19:39:53 +02:00
nyx
642f394eb3
xwayland: sync primary selection with wayland () 2025-04-08 17:36:29 +02:00
Vaxry
b15c2bfff6
CursorManager: Store cursor pixel data retrieved from X/HC as a copy ()
Instead of storing pointers as refs (which could randomly get invalid very easily) copy the data.
2025-04-07 21:08:16 +02:00
Ikalco
da86db43d4
core: refactor and improve surface commit ()
* make CHLBufferReference not a SP anymore

* copy over release and acquire points in CHLBufferReference

* use CHLBufferReference in screencopy and toplevel export

TODO: use CHLBufferReference in direct scanout properly
      the only problem is the scanout buffer release timing,
      specifically the onBackendRelease mechanism

* cleanup SSurfaceState and surface pending commit tracking

* move surface code from DRMSyncobj, and move acquire to SSurfaceState

* use queue for comitted pending surface states like proto says

"The content update is placed in a queue until it becomes active." - wl_surface::commit

* drop, not release, prev buffer if 2nd buffer wl_surface.attach is sent

"A wl_buffer that has been attached and then replaced by another attach instead of committed will not receive a release event, and is not used by the compositor." - wl_surface::attach
2025-04-07 21:03:27 +02:00
Vaxry
70ae99f521
input/layers: Fix exclusive LS focus / refocus after unmap () 2025-04-07 20:52:11 +02:00
Jan Beich
a8eda7f978
helpers: add missing include for BSDs after 3c128679ee ()
src/helpers/AsyncDialogBox.cpp:47:23: error: use of undeclared identifier 'read'
   47 |         while ((ret = read(m_pipeReadFd.get(), buf.data(), 1023)) > 0) {
      |                       ^
src/helpers/AsyncDialogBox.cpp:83:9: error: use of undeclared identifier 'pipe'
   83 |     if (pipe(outPipe)) {
      |         ^
src/helpers/AsyncDialogBox.cpp:110:5: error: use of undeclared identifier 'close'
  110 |     close(outPipe[1]);
      |     ^
2025-04-07 20:36:01 +02:00
kerty0
8a8f394da7
swipe: fix swiping onto a new workspace bound to another monitor () ()
The previous code didn't check if the chosen new workspace was bound to another monitor, causing buggy behavior where workspace was simultaneously open and not.

The fix simply uses `r+1` for new workspace selection.

Also, the previous code would select rightmost workspace + 1, creating large gaps in workspace IDs in some scenarios. Example (`()` and `[]` indicate workspaces on different monitors):

`(1), 2, 3, 4, 5, 6, 7, 8, 9, [10]`

Swipe right on `()` monitor would create:

`(1), 2, 3, 4, 5, 6, 7, 8, 9, [10], (11)`

But with this commit:

`(1), (2), 3, 4, 5, 6, 7, 8, 9, [10]`
2025-04-07 14:46:31 +02:00
Virt
51838fb5f5
layout: properly track floating window position () 2025-04-06 23:41:27 +02:00
85f874d10f swipe: fix prev workspace remembering
fixes 
2025-04-06 22:35:26 +01:00
nyx
9b3925009a
DataDevice: position icon at cursor hotspot ()
* DataDevice: position icon at cursor hotspot

ref: https://wayland.app/protocols/wayland#wl_data_device:request:start_drag
2025-04-06 23:24:14 +02:00
Vaxry
3c128679ee
helpers: Add an async dialog box impl ()
Adds an async dialog box, way safer than our previous local solution for ANR
2025-04-06 17:31:58 +02:00
e96b8ce4cc window: send fractional scale on updateScaleTransform
fixes 
2025-04-06 00:30:13 +01:00
Maximilian Seidler
433b7881a3
compositor: fix crash when moving a workspace to a monitor with size 0x0 () 2025-04-06 00:54:29 +02:00
ed05f14300 ci: nuke stalebot 2025-04-05 19:28:42 +01:00
c62fb08da6 github: remove issue templates 2025-04-05 18:45:52 +01:00
8ba20fcae1 compositor: avoid crash on null window monitor move
ref 
2025-04-05 00:30:33 +01:00
ff97d18c4c
flake.lock: update 2025-04-03 18:08:55 +00:00
Maximilian Seidler
5e8bb71785
ctm: fix crash when finishing ctm progress with a destroyed monitor () 2025-04-03 16:40:59 +02:00
Amadej Kastelic
b496e2c718
nix/module: load plugins using exec-once () 2025-04-03 10:43:06 +03:00
Arkady Buryakov
a41b8d5e97
groupbar: add text offset and upper gap settings ()
* Groupbar: add keep_upper_gap setting to apply/remove outer gap offset to the upper side of groupbar

* Groupbar: add text_offset setting to adjust text vertical position in a group header
2025-04-02 22:26:46 +02:00
Armin
8654029f86
versionkeeper: create version file if not present () 2025-04-02 22:21:05 +02:00
nyx
a4e6c5d678
window: don't deactivate unfocused xwayland windows in groups ()
* window: don't deactivate unfocused xwayland windows in groups

we dont want to deactivate unfocused xwayland windows because X is weird, keep the behavior for wayland windows
2025-04-02 00:51:37 +02:00
nyx
3a47c73f34
layout: center floating window at cursor when picked up from fullscreen ()
* layout: center floating window at cursor when picked up from fullscreen

when picking up a floating window after it had been fullscreened before it would return to its previous position which looked ugly because the cursor could be no where near the windows original position, this patch makes it so that the window is returned to the users current cursor position

* E
2025-04-02 00:45:51 +02:00
X2E4VXpZKv
1f0fd79b91
internal: Don't force default cursor on config reload/monitor reconfigure () 2025-04-01 16:20:38 +02:00
d1a59ec39e renderer: render tiled fading out above other tiled windows
fixes 

closes 
2025-04-01 00:25:09 +01:00
4c987b20e2 makefile: fix find command in installheaders
fixes 
2025-03-31 17:13:27 +01:00
nyx
2309270752
anr: add config for ping number before popup shows up ()
* anr: make pings configurable

makes the pings of the dialog popup configurable
2025-03-31 18:06:17 +02:00
79b526a041 socket2: add minimized event for foreign-wlr
ref 
2025-03-30 22:38:30 +01:00
nyx
075bbecabd
core: fix artifacts when fullscreening ()
* core: fix artifacts when fullscreening

fixes an issue where fullscreening a floating window that is between two monitors causes artifacts to appear on the monitor where it did not become fullscreened on

* e
2025-03-30 23:28:12 +02:00
nyx
8aaffda969
core: fix null ref when resuming system ()
* core: fix null ref when resuming system

* e
2025-03-30 23:18:04 +02:00
Shockingly Good
10a335631e
solitary: Fix the non-working tearing ()
Fixes the non-working tearing by removing the incorrect
opaqueness check for the windows.

Fixes 
2025-03-30 20:29:39 +02:00
Emad Elsaid
da2d7c3971
config: Fix matching monitor by description to allow space prefix () 2025-03-30 03:12:15 +02:00
LeviVanDerMaas
05eb0aa43d
workspaces: Add binds:hide_special_on_workspace_change () 2025-03-30 03:11:39 +02:00
Tom Englund
fc7223edc0
synctimeline: check if fd is readable before wait ()
a lot of the time the fd is already readable, and done. so just call the
waiter directly instead of making a waiter and adding it to the
eventloop.
2025-03-30 01:53:23 +01:00
Lee Bousfield
86c279d7d0
protocols: Don't update hdr metadata if image description is unchanged () 2025-03-30 01:25:27 +01:00
micha4w
46b00a4a86
makefile: add new shaders to make installheaders () 2025-03-30 01:25:02 +01:00
Tom Englund
4a79eea6dc
opengl: check for g_pHyprOpengl pointer ()
restore the pointer check to avoid null ptr dereference on compositor
destruction.
2025-03-29 21:52:27 +01:00
UjinT34
7374a023ef
renderer/opengl: Extract shaders from source ()
---------

Co-authored-by: Mihai Fufezan <mihai@fufexan.net>
2025-03-29 01:19:35 +01:00
Lee Bousfield
a46576afc3
xwayland: Cleanup server startup and FDs () 2025-03-28 17:12:25 +01:00
Lee Bousfield
10035a85cc
core: Don't damage the entire surface every frame ()
* core: Don't damage the entire surface every frame

* core: Damage buffer on dims or transform change

* core: Use guards for scale and tr equality checks
2025-03-28 17:00:39 +01:00
c93140a5f1 surfacestate: reset buffer bit before applying to current
fixes 
2025-03-28 12:32:07 +00:00
5380cbcdda workspaces: minor fixes to persistence
fixes 
2025-03-27 14:00:29 +00:00
Tom Englund
9ea76428b6
internal: fix minor ubsan errors ()
* opengl: check if g_pHyprOpengl exist

on compositor destruction we can hit a race where a CEGLSync destructs
and tries to call eglDestroySyncKHR on a null g_pHyprOpengl.

/src/render/OpenGL.cpp:3019:32: runtime error: member access within null pointer of type 'struct CHyprOpenGLImpl'
      0x555565eed979 in CEGLSync::~CEGLSync() /src/render/OpenGL.cpp:3019
      0x555565f6271e in std::default_delete<CEGLSync>::operator()(CEGLSync*)
     const /usr/lib/gcc/x86_64-pc-linux-gnu/14/include/g++-v14/bits/unique_ptr.h:93

* xdgshell: dont apply state on empty states

setsize can be called before a state has been added to pending,
resulting in calling ApplyState with a empty state.

/src/protocols/XDGShell.cpp:323:11: runtime error: null pointer passed as argument 2, which is declared to never be null
      0x5555659bf67e in CXDGToplevelResource::applyState() /src/protocols/XDGShell.cpp:323
      0x5555659bcedc in CXDGToplevelResource::setSize(Hyprutils::Math::Vector2D const&) /src/protocols/XDGShell.cpp:  256
      0x555563eed0ef in Events::listener_commitWindow(void*, void*) /src/events/Windows.cpp:841
2025-03-26 18:22:44 +01:00
0cd04bd666 surfacestate: track and apply updated state
fixes 
2025-03-26 17:22:21 +00:00
1c2b9a9ce3 opengl: don't attempt to compile cm on gles3.0
also disable the error for the cm shader

fixes 
2025-03-26 14:28:19 +00:00
cec084c178 pass/rect: include clipBox in opaque calculations
ref  ref 
2025-03-26 11:47:04 +00:00
c2ef8fcc00 groupbar: round boxes 2025-03-26 11:44:38 +00:00
Tom Englund
3fc3521a97
pass: remove unusued timeline in texpass ()
remove unused timeline and waitpoint in texpass and especially remove
the passing it to renderTextureInternalWithDamage that implicitly
converted it to bool. setting discardActive and allowCustomUV
2025-03-26 02:22:09 +01:00
Arkady Buryakov
9a67354fa2
Groupbar: apply scaling factor to text () 2025-03-26 02:07:56 +01:00