This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project wmaker-crm.git.
The branch, next has been updated
via ae91ee4b0a6238b12d60bfdc8ada38ba326bd1e3 (commit)
via a6b1833b41dc44b6fa1327996d579024ed9ba72d (commit)
via 4c7d0025dd36470231e7e31a89810ecd8e1e6332 (commit)
from 420fcb2819ff5bc2e8eb9e80ac3467bd418e5e04 (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 -----------------------------------------------------------------
http://repo.or.cz/w/wmaker-crm.git/commit/ae91ee4b0a6238b12d60bfdc8ada38ba326bd1e3
commit ae91ee4b0a6238b12d60bfdc8ada38ba326bd1e3
Author: Iain Patterson <[email protected]>
Date: Thu May 30 15:57:42 2013 +0100
Handle Return in switchpanel.
Explicitly match a Return keypress in the switchpanel, so that the
currently selected window is focused without the keypress event being
handled elsewhere.
Pressing Return to commit the window selection is intuitive but other
shortcuts may bind Return. Any keypress not explicitly handled in the
switchpanel code will be passed through to other shortcut processing.
If, for example, alt+return were mapped to Select Window and the
switchpanel is open, pressing return while holding alt would both commit
the window change AND select the window, which is not intuitive.
diff --git a/src/cycling.c b/src/cycling.c
index 78449b4..3414ae2 100644
--- a/src/cycling.c
+++ b/src/cycling.c
@@ -92,6 +92,7 @@ void StartWindozeCycle(WWindow * wwin, XEvent * event, Bool
next, Bool class_onl
KeyCode shiftLKey = XKeysymToKeycode(dpy, XK_Shift_L);
KeyCode shiftRKey = XKeysymToKeycode(dpy, XK_Shift_R);
KeyCode escapeKey = XKeysymToKeycode(dpy, XK_Escape);
+ KeyCode returnKey = XKeysymToKeycode(dpy, XK_Return);
Bool esc_cancel = False;
Bool somethingElse = False;
Bool done = False;
@@ -189,6 +190,11 @@ void StartWindozeCycle(WWindow * wwin, XEvent * event,
Bool next, Bool class_onl
esc_cancel = True;
done = True;
+ } else if (ev.xkey.keycode == returnKey) {
+
+ /* Close the switchpanel without eating the
keypress */
+ done = True;
+
} else if (ev.xkey.keycode != shiftLKey &&
ev.xkey.keycode != shiftRKey) {
somethingElse = True;
@@ -202,6 +208,9 @@ void StartWindozeCycle(WWindow * wwin, XEvent * event, Bool
next, Bool class_onl
if (wPreferences.strict_windoze_cycle)
break;
+ if (ev.xkey.keycode == XK_Return)
+ break;
+
for (i = 0; i < 8 * keymap->max_keypermod; i++) {
int mask = 1 << (i / keymap->max_keypermod);
http://repo.or.cz/w/wmaker-crm.git/commit/a6b1833b41dc44b6fa1327996d579024ed9ba72d
commit a6b1833b41dc44b6fa1327996d579024ed9ba72d
Author: Iain Patterson <[email protected]>
Date: Sun Jun 2 15:33:27 2013 +0100
Preference to open the switchpanel without selecting a window.
If the new preference SwitchPanelOnlyOpen is set to YES, pressing
alt-tab or similar shortcut will only open the panel without
automatically switching to the next window. Shortcuts will continue to
function normally once the panel is open.
Users can enable the new preference if they find themselves regularly
opening the switchpanel just to visualise which windows are open, or to
initiate same-class cycling.
The default value of the new preference is NO. Behaviour is unchanged
unless the preference is explicitly enabled with the following command:
$ wdwrite WindowMaker SwitchPanelOnlyOpen YES
diff --git a/NEWS b/NEWS
index ed03cf0..499c3c0 100644
--- a/NEWS
+++ b/NEWS
@@ -81,6 +81,12 @@ command:
$ wdwrite WindowMaker StrictWindozeCycling NO
+If you find yourself regularly opening the switchpanel just to visualise open
+windows, you can run the following command to force the first "FocusNextKey"
+or similar shortcut to open the panel without switching to a new window.
+
+$ wdwrite WindowMaker SwitchPanelOnlyOpen YES
+
--- 0.95.2
diff --git a/src/WindowMaker.h b/src/WindowMaker.h
index bc034d9..100f75b 100644
--- a/src/WindowMaker.h
+++ b/src/WindowMaker.h
@@ -419,6 +419,7 @@ typedef struct WPreferences {
char cycle_active_head_only; /* Cycle only windows on the active
head */
char cycle_ignore_minimized; /* Ignore minimized windows when
cycling */
char strict_windoze_cycle; /* don't close switchpanel when shift
is released */
+ char panel_only_open; /* Only open the switchpanel; don't
switch */
/* All delays here are in ms. 0 means instant auto-action. */
int clip_auto_raise_delay; /* Delay after which the clip will be
raised when entered */
diff --git a/src/cycling.c b/src/cycling.c
index bae12be..78449b4 100644
--- a/src/cycling.c
+++ b/src/cycling.c
@@ -129,7 +129,7 @@ void StartWindozeCycle(WWindow * wwin, XEvent * event, Bool
next, Bool class_onl
if (swpanel) {
- if (wwin->flags.mapped)
+ if (wwin->flags.mapped && !wPreferences.panel_only_open)
newFocused = wSwitchPanelSelectNext(swpanel, !next,
True, False);
else
newFocused = wSwitchPanelSelectFirst(swpanel, False);
diff --git a/src/defaults.c b/src/defaults.c
index 50db1d4..dde87b5 100644
--- a/src/defaults.c
+++ b/src/defaults.c
@@ -478,6 +478,8 @@ WDefaultEntry optionList[] = {
&wPreferences.single_click, getBool, NULL, NULL, NULL},
{"StrictWindozeCycle", "YES", NULL,
&wPreferences.strict_windoze_cycle, getBool, NULL, NULL, NULL},
+ {"SwitchPanelOnlyOpen", "NO", NULL,
+ &wPreferences.panel_only_open, getBool, NULL, NULL, NULL},
/* style options */
http://repo.or.cz/w/wmaker-crm.git/commit/4c7d0025dd36470231e7e31a89810ecd8e1e6332
commit 4c7d0025dd36470231e7e31a89810ecd8e1e6332
Author: Iain Patterson <[email protected]>
Date: Fri Jun 7 19:00:06 2013 +0100
Compiler food.
WMArray elements are stored as pointers. We only need to store chars
for switchpanel flags.
diff --git a/src/switchpanel.c b/src/switchpanel.c
index 60afb41..758c09d 100644
--- a/src/switchpanel.c
+++ b/src/switchpanel.c
@@ -20,6 +20,7 @@
#include "wconfig.h"
+#include <stdint.h>
#include <stdlib.h>
#include <string.h>
#include <sys/time.h>
@@ -113,7 +114,7 @@ static void changeImage(WSwitchPanel *panel, int idecks,
int selected, Bool dim,
{
WMFrame *icon = WMGetFromArray(panel->icons, idecks);
RImage *image = WMGetFromArray(panel->images, idecks);
- char flags = (char) WMGetFromArray(panel->flags, idecks);
+ char flags = (char) (uintptr_t) WMGetFromArray(panel->flags, idecks);
char desired = 0;
if (selected)
@@ -124,7 +125,7 @@ static void changeImage(WSwitchPanel *panel, int idecks,
int selected, Bool dim,
if (flags == desired && !force)
return;
- WMReplaceInArray(panel->flags, idecks, desired);
+ WMReplaceInArray(panel->flags, idecks, (void *) (uintptr_t) desired);
if (!panel->bg && !panel->tile && !selected)
WMSetFrameRelief(icon, WRFlat);
@@ -223,7 +224,7 @@ static void scrollIcons(WSwitchPanel *panel, int delta)
for (i = panel->firstVisible; i < panel->firstVisible +
panel->visibleCount; i++) {
if (i == panel->current)
continue;
- dim = ((char) WMGetFromArray(panel->flags, i) & ICON_DIM);
+ dim = ((char) (uintptr_t) WMGetFromArray(panel->flags, i) &
ICON_DIM);
changeImage(panel, i, 0, dim, True);
}
}
-----------------------------------------------------------------------
Summary of changes:
NEWS | 6 ++++++
src/WindowMaker.h | 1 +
src/cycling.c | 11 ++++++++++-
src/defaults.c | 2 ++
src/switchpanel.c | 7 ++++---
5 files changed, 23 insertions(+), 4 deletions(-)
repo.or.cz automatic notification. Contact project admin [email protected]
if you want to unsubscribe, or site admin [email protected] if you receive
no reply.
--
wmaker-crm.git ("The Window Maker window manager")
--
To unsubscribe, send mail to [email protected].