Consolatis [Fri, 3 Jun 2022 20:40:26 +0000 (22:40 +0200)]
src/config/keybind.c: fix keybind insertion order
This restores the intended behavior of keybinds set by `<default />`
to be overwritten by manually configured keybinds which come later in
the config.
In `src/keyboard.c`, `handle_keybinding()` is going backwards through
the list of keybindings and breaks after the first match.
`wl_list_insert(&list_node, item)` will insert the new item *after* the
list_node so if its called multiple times with the same list_node as
fist argument the result will be a reversed list. Using `list_node.prev`
instead will result in a non-reversed list.
Consolatis [Thu, 2 Jun 2022 09:44:35 +0000 (11:44 +0200)]
IRC notifications: disable push notifications
They were also called for the 'master' and 'v0.5' branches of forks and are
not that helpful anyway because they just post the compare link and not the
title of the commits.
Additionally, they were also called whenever a PR was merged which already
has its own notification including a link to the PR.
Johan Malm [Tue, 17 May 2022 17:10:29 +0000 (18:10 +0100)]
xwayland: call foreign-toplevel-destroy on unmap
Some xwayland clients leave unmapped child views around, typically when a
dialog window is closed. Although handle_destroy() is not called for
these, we have to call foreign-toplevel-destroy to avoid panels and the
like incorrecly showing them.
Johan Malm [Tue, 24 May 2022 16:49:21 +0000 (17:49 +0100)]
cursor: offset xdg invisible border when dragging outside view
Note: view->padding was deleted in commit b279550 as the wlroots
scene-graph xdg-surface commit handler offsets the CSD invisible border.
If view->padding still existed, we could have used that, but considering
that this is probably the only place where this offset will now be
needed (because we're generating surface local coordinates), it's simpler
to just do it locally.
Consolatis [Tue, 24 May 2022 11:02:51 +0000 (13:02 +0200)]
src/cursor.c: Fix branch condition for out-of-view selecting/dragging
Instead of using the stored view for comparison use the actual surface.
Before this patch, there were situations where the branch intended for
out-of-window text selection / scrollbar dragging was used even though
the cursor never left the surface.
Consolatis [Tue, 17 May 2022 12:33:12 +0000 (14:33 +0200)]
src/xwayland.c: keep SSD state on unmap/map cycle
Move SSD related map() work into the !view->been_mapped branch,
similar to src/xdg.c.
Without this patch following series of events restores the initial
state of the SSD when activating the view:
- spawn xcalc
- observe it shows the SSD
- toggleDecorations to hide the SSD (via keybinding or window menu)
- minimize xcalc (via some panel or A-Space)
- activate xcalc (via some panel or A-Tab)
- observe the SSD is back visible
Eli Schwartz [Mon, 9 May 2022 21:44:47 +0000 (17:44 -0400)]
meson: use proper dependency fallback for wlroots
Make the subproject wrap file declare the dependencies it provides.
Remove the manual subproject invocation and allow Meson to select
whichever wlroots it finds which satisfies the version requirement --
either a system one via pkg-config, or the subproject fallback.
Use a dependency-generic method of acquiring wlroots configuration info
-- enabled features are present in the pkg-config file and additionally
exported as declare_dependency() variables, so there is no need to do C
preprocessor checks for it.
This ensures that Meson best practices are followed, and also...
Johan Malm [Fri, 6 May 2022 20:55:46 +0000 (21:55 +0100)]
menu: support <action name="Execute"> option <execute>
<exectue> is a deprecated name for <command>.
See: http://openbox.org/wiki/Help:Actions#Action_syntax
But some openbox3 menu generators still use it, for example
https://wiki.archlinux.org/title/xdg-menu - so let's support it for
backward compatibility.
Johan Malm [Wed, 4 May 2022 20:52:20 +0000 (21:52 +0100)]
docs/autostart: use wlopm with *
With swayidle timeout/resume, use wlopm --off/--on with * instead of
specifying output names. When * is given as parameter to an operation
wlopm will do the operation for all discovered outputs.
01micko [Sun, 1 May 2022 04:38:45 +0000 (14:38 +1000)]
nls: add native language support
- adds labwc.pot and po files for de, es, it and sv
- added notes in NEWS.md and CONTRIBUTING.md
- addresses #269
- conditional upon `msgfmt` being installed
- can be disabled at build time
Johan Malm [Sun, 24 Apr 2022 21:24:47 +0000 (22:24 +0100)]
layer: handle output_destroy.notify without crash
Steps to reproduce crash:
- run nested with two outputs (e.g. WLR_WL_OUTPUTS=2 ./build/labwc)
- start panel on one output (e.g. waybar)
- close that output
Backtrace pointed to output_destroy_notify() at ../src/layers.c:92
Johan Malm [Fri, 22 Apr 2022 16:52:01 +0000 (17:52 +0100)]
config: support <mouse><default />
This loads default mousebinds and provides a way to keep config files
simpler whilst allowing user specific binds.
Note that if no rc.xml is found, or if no <mouse><mousebind> entries
exist, the same default mousebinds will be loaded even if the <default />
element is not provided.
Consolidates all of the view destruction code for xwl + xdg into one function.
Fixes several notable bugs along the way:
- Fixes a crash when alt tabbing when a selected view gets destroyed.
- Fixes the OSD not updating to reflect a view has been destroyed.
Add soft deprecation warning to highlight future intent of removing the
code which drops SUID privileges. libseat now has a better alternative in
the form of seatd-launch which uses the normal seatd daemon & libseat
backend and takes care of SUID.
Johan Malm [Fri, 8 Apr 2022 21:13:45 +0000 (22:13 +0100)]
wlroots.wrap: set revision to latest commit
This is better than `revision = master` because:
- It enables labwc commits to be checked out and build without manually
having to find the right wlroots commit to build with
- The labwc master is always buildable without user intervention even
if there are breaking changes in the wlroots master branch
John Lindgren [Sun, 3 Apr 2022 01:34:51 +0000 (21:34 -0400)]
cursor: Fix "jumping opposite edges" issue when resizing
Commit 08c537e ("xwayland: Honor size increments from
WM_SIZE_HINTS") adjusted only the window width/height according
to the size hints. If resizing from the top or left edge of the
window, we also need to adjust the window position to keep the
bottom or right edge from jumping around.
Johan Malm [Sat, 19 Mar 2022 11:34:11 +0000 (11:34 +0000)]
Chase wlroots wlr-device-input refactoring
Rename wlroots input device events, for example
's/wlr_event_pointer_motion/wlr_pointer_motion_event/'
seat.c:
- In configure_libinput() use wlr_input_device->type rather than width_mm
- In new_pointer() use wlr_input_device->type rather than output_name to
check that device is pointer.