[repo.or.cz] wmaker-crm.git branch master updated: wmaker-0.96.0-122-g78b58d441855

8 views
Skip to first unread message

crmafra

unread,
Aug 19, 2026, 6:00:03 PMAug 19
to wmake...@googlegroups.com
This is an automated email generated because a ref change occurred in the
git repository for project wmaker-crm.git.

The branch, master has been updated
via 78b58d4418550b1349eb5d6820731d9c8aaafb08 (commit)
via c7ab42e1837197e67704f8a710e59e5b5de2cf7a (commit)
from 17d44e15033ada29b0100954e6fa8fd7fe76b220 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 78b58d4418550b1349eb5d6820731d9c8aaafb08
Author: David Maciejak <david.m...@gmail.com>
Date: Tue, 18 Aug 2026 21:48:12 -0400
URL: <https://repo.or.cz/wmaker-crm.git/78b58d4418550b13>

wmaker: cycle ScreenSwitchKey across Xinerama/RandR heads

ScreenSwitchKey only looped over w_global.screen_count, which stays 1
on a single-screen multi-head display driven by Xinerama or RandR, so
the binding did nothing on such multi-monitor setups.

Treat monitors as the heads of all managed screens in (screen, head)
order and warp the pointer from the head it is on to the next one.
With one head per screen this behaves exactly as before.
---
TODO | 2 --
src/event.c | 78 +++++++++++++++++++++++++++++++++++++++--------------
2 files changed, 58 insertions(+), 22 deletions(-)

diff --git a/TODO b/TODO
index 31f3b16b4d43..ab4891136479 100644
--- a/TODO
+++ b/TODO
@@ -47,8 +47,6 @@ Never: (so, dont even bother to ask)
======
- different themes for each workspace. Unless you give us a SGI/Power Onyx
with 2 CPUs ;).
-- anything that requires the mouse pointer to be jumped by WindowMaker to
- somewhere. This is *terrible* behaviour. And it's not just IMO.
- rewrite to use Gtk... I wont even bother to explain why...


diff --git a/src/event.c b/src/event.c
index ecd1c9bab3a6..897b848b1312 100644
--- a/src/event.c
+++ b/src/event.c
@@ -1476,6 +1476,63 @@ static void startMarkCapture(WScreen *scr, Display *dpy, WMarkCaptureMode mode)
XGrabKeyboard(dpy, scr->root_win, False, GrabModeAsync, GrabModeAsync, CurrentTime);
}

+/*
+ * Warp pointer to the center of the next monitor, cycling.
+ *
+ * Monitors are the Xinerama/RandR heads of every managed screen,
+ * visited in (screen, head) order starting from the head the pointer
+ * is on. With one head per screen this reduces to hopping from X11
+ * screen to X11 screen as before.
+ */
+static void warpPointerToNextMonitor(WScreen *scr)
+{
+ WMRect rect;
+ WScreen *target;
+ int total, current, next;
+ int i, h;
+
+ total = 0;
+ for (i = 0; i < w_global.screen_count; i++)
+ total += wXineramaHeads(wScreenWithNumber(i));
+
+ if (total <= 1)
+ return;
+
+ /* flat index of the monitor the pointer is currently on */
+ current = 0;
+ for (i = 0; i < w_global.screen_count; i++) {
+ if (wScreenWithNumber(i) == scr) {
+ h = wGetHeadForPointerLocation(scr);
+ if (h < 0 || h >= wXineramaHeads(scr))
+ h = 0;
+ current += h;
+ break;
+ }
+ current += wXineramaHeads(wScreenWithNumber(i));
+ }
+
+ next = (current + 1) % total;
+
+ /* map the flat index back to a (screen, head) pair */
+ target = NULL;
+ for (i = 0; i < w_global.screen_count; i++) {
+ target = wScreenWithNumber(i);
+ h = wXineramaHeads(target);
+ if (next < h)
+ break;
+ next -= h;
+ target = NULL;
+ }
+ if (!target)
+ return;
+
+ rect = wGetRectForHead(target, next);
+ XWarpPointer(dpy, None, target->root_win, 0, 0, 0, 0,
+ rect.pos.x + (int)rect.size.width / 2,
+ rect.pos.y + (int)rect.size.height / 2);
+ XFlush(dpy);
+}
+
static void dispatchWKBDCommand(int command, WScreen *scr, WWindow *wwin, XEvent *event)
{
short widx;
@@ -1898,26 +1955,7 @@ static void dispatchWKBDCommand(int command, WScreen *scr, WWindow *wwin, XEvent
break;

case WKBD_SWITCH_SCREEN:
- if (w_global.screen_count > 1) {
- WScreen *scr2;
- int i;
-
- /* find index of this screen */
- for (i = 0; i < w_global.screen_count; i++) {
- if (wScreenWithNumber(i) == scr)
- break;
- }
- i++;
- if (i >= w_global.screen_count) {
- i = 0;
- }
- scr2 = wScreenWithNumber(i);
-
- if (scr2) {
- XWarpPointer(dpy, scr->root_win, scr2->root_win, 0, 0, 0, 0,
- scr2->scr_width / 2, scr2->scr_height / 2);
- }
- }
+ warpPointerToNextMonitor(scr);
break;

case WKBD_RUN:

commit c7ab42e1837197e67704f8a710e59e5b5de2cf7a
Author: Andreas Metzler <amet...@bebt.de>
Date: Mon, 17 Aug 2026 18:10:32 +0200
URL: <https://repo.or.cz/wmaker-crm.git/c7ab42e1837197e6>

Drop ./configure-generated date (Makefile) from tarball.

---
WINGs/Makefile.am | 4 ++++
wrlib/Makefile.am | 3 +++
2 files changed, 7 insertions(+)

diff --git a/WINGs/Makefile.am b/WINGs/Makefile.am
index 60875dab7542..fe62ebcf9b6c 100644
--- a/WINGs/Makefile.am
+++ b/WINGs/Makefile.am
@@ -5,6 +5,10 @@ AUTOMAKE_OPTIONS =
SUBDIRS = WINGs . po Documentation Resources
DIST_SUBDIRS = $(SUBDIRS) Tests Examples Extras

+dist-hook:
+ rm -f $(distdir)/Examples/Makefile $(distdir)/Extras/Makefile \
+ $(distdir)/Test/Makefile
+
libWINGs_la_LDFLAGS = -version-info @WINGS_VERSION@
libWUtil_la_LDFLAGS = -version-info @WUTIL_VERSION@

diff --git a/wrlib/Makefile.am b/wrlib/Makefile.am
index 68f045ce06e9..a120551f63b9 100644
--- a/wrlib/Makefile.am
+++ b/wrlib/Makefile.am
@@ -3,6 +3,9 @@
SUBDIRS = . po
DIST_SUBDIRS = $(SUBDIRS) tests

+dist-hook:
+ rm -f $(distdir)/tests/Makefile
+
AUTOMAKE_OPTIONS =

EXTRA_DIST = tests

-----------------------------------------------------------------------

Summary of changes:
TODO | 2 --
WINGs/Makefile.am | 4 +++
src/event.c | 78 +++++++++++++++++++++++++++++++++++------------
wrlib/Makefile.am | 3 ++
4 files changed, 65 insertions(+), 22 deletions(-)


repo.or.cz automatic notification. Contact project admin crm...@gmail.com
if you want to unsubscribe, or site admin ad...@repo.or.cz if you receive
no reply.
--
wmaker-crm.git ("The Window Maker window manager")
Reply all
Reply to author
Forward
0 new messages