summaryrefslogtreecommitdiff
path: root/app/cwm/kbfunc.c
diff options
context:
space:
mode:
authorOkan Demirmen <okan@cvs.openbsd.org>2015-05-21 00:37:05 +0000
committerOkan Demirmen <okan@cvs.openbsd.org>2015-05-21 00:37:05 +0000
commita8cce8398e2cba5668fa7dd35b9c117dc3747033 (patch)
tree908f31be4140a1fa86b3bc59a18d01e99cbea1d6 /app/cwm/kbfunc.c
parentd585a16f482b1d0eec1f8f6589e5faf48bca946f (diff)
merge kbd and mouse grouptoggle
Diffstat (limited to 'app/cwm/kbfunc.c')
-rw-r--r--app/cwm/kbfunc.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/app/cwm/kbfunc.c b/app/cwm/kbfunc.c
index e6798f940..161578892 100644
--- a/app/cwm/kbfunc.c
+++ b/app/cwm/kbfunc.c
@@ -15,7 +15,7 @@
* ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*
- * $OpenBSD: kbfunc.c,v 1.105 2015/01/19 14:54:16 okan Exp $
+ * $OpenBSD: kbfunc.c,v 1.106 2015/05/21 00:37:04 okan Exp $
*/
#include <sys/types.h>
@@ -435,9 +435,11 @@ kbfunc_client_nogroup(struct client_ctx *cc, union arg *arg)
void
kbfunc_client_grouptoggle(struct client_ctx *cc, union arg *arg)
{
- /* XXX for stupid X apps like xpdf and gvim */
- XGrabKeyboard(X_Dpy, cc->win, True,
- GrabModeAsync, GrabModeAsync, CurrentTime);
+ if (arg->i == 0) {
+ /* XXX for stupid X apps like xpdf and gvim */
+ XGrabKeyboard(X_Dpy, cc->win, True,
+ GrabModeAsync, GrabModeAsync, CurrentTime);
+ }
group_toggle_membership_enter(cc);
}