Add 6 desktop features: workspace shortcuts, Exposé, deskbar icons, notifications, screen lock, move-to-desktop
- Super+1-4: switch virtual desktop; Super+Shift+1-4: move focused window to desktop N - Super+Space: Exposé window overview (tiled grid), click to select, Escape to cancel - wm/src/expose.c: expose_show/expose_hide using ceil(sqrt) grid layout with saved/restored geometry - client_move_to_desktop(): moves window between desktops, fires _NET_WM_DESKTOP update - on_client_message: handles _NET_WM_DESKTOP to move windows from external requests - deskbar: optional imlib2 app icon rendering (Papirus-Dark → Papirus → hicolor → pixmaps fallback) - deskbar: XGetClassHint populates cls field for better icon lookup - deskbar: context menu extended with separator + "→ Desktop 1-4" items via _NET_WM_DESKTOP - orionnotify/: freedesktop.org notification daemon (libdbus-1), stacks up to 5 popups top-right - orionlock/: PAM-authenticated fullscreen screen lock with clock, date, password dots - Lock Screen menu item wired to orionlock - Root Makefile includes orionnotify and orionlock targets Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01GHiBQKPfUoaJgCKuA9op1H
This commit is contained in:
14 files changed
+977
-31
No files matched your search
@@ -328,6 +328,34 @@ void client_snap_left(WM *wm, Client *c) {
|
||||
frame_draw(wm, c);
|
||||
}
|
||||
|
||||
void client_move_to_desktop(WM *wm, Client *c, int new_desk) {
|
||||
if (new_desk < 0 || new_desk >= 4 || c->desktop == new_desk) return;
|
||||
|
||||
/* hide frame if it's on the current (now-active) desktop */
|
||||
if (c->desktop == wm->cur_desktop && !c->minimized)
|
||||
XUnmapWindow(wm->dpy, c->frame);
|
||||
|
||||
c->desktop = new_desk;
|
||||
|
||||
/* update _NET_WM_DESKTOP */
|
||||
long desk = new_desk;
|
||||
XChangeProperty(wm->dpy, c->win, wm->net_wm_desktop, XA_CARDINAL, 32,
|
||||
PropModeReplace, (unsigned char *)&desk, 1);
|
||||
|
||||
/* if we moved the focused window away, re-focus another */
|
||||
if (wm->focused == c) {
|
||||
wm->focused->focused = 0;
|
||||
frame_draw(wm, wm->focused);
|
||||
wm->focused = NULL;
|
||||
for (Client *n = wm->clients; n; n = n->next) {
|
||||
if (!n->minimized && n->desktop == wm->cur_desktop) {
|
||||
client_focus(wm, n);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void client_snap_right(WM *wm, Client *c) {
|
||||
if (c->maximized) client_unmaximize(wm, c);
|
||||
int sw = DisplayWidth(wm->dpy, wm->screen);
|
||||
|
||||
Reference in new issue
Block a user