aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorokan2011-06-24 06:09:26 +0000
committerokan2011-06-24 06:09:26 +0000
commitfeff015aa1ac96d5c2ef8cc9b6413f4aa8ed2b8a (patch)
tree71c0934876b7eb9860aa0dc5db3a6ce44d2ab347
parentab4a3c9a9f59f702603e19f3eb3508a815521d6c (diff)
downloadcwm-feff015aa1ac96d5c2ef8cc9b6413f4aa8ed2b8a.tar.gz
New option to raise a client via the mouse (unbound by default);
opposing action, lower, already exists and bound. Both keyboard mappings already exist. 'no opinion either way' oga@
Diffstat (limited to '')
-rw-r--r--calmwm.h3
-rw-r--r--conf.c3
-rw-r--r--cwmrc.54
-rw-r--r--mousefunc.c8
4 files changed, 14 insertions, 4 deletions
diff --git a/calmwm.h b/calmwm.h
index 75ef1df..bb6aa86 100644
--- a/calmwm.h
+++ b/calmwm.h
@@ -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: calmwm.h,v 1.131 2011/06/24 06:06:24 okan Exp $
+ * $OpenBSD: calmwm.h,v 1.132 2011/06/24 06:09:26 okan Exp $
*/
#ifndef _CALMWM_H_
@@ -405,6 +405,7 @@ void mousefunc_window_grouptoggle(struct client_ctx *,
void mousefunc_window_hide(struct client_ctx *, void *);
void mousefunc_window_lower(struct client_ctx *, void *);
void mousefunc_window_move(struct client_ctx *, void *);
+void mousefunc_window_raise(struct client_ctx *, void *);
void mousefunc_window_resize(struct client_ctx *, void *);
struct menu *menu_filter(struct screen_ctx *, struct menu_q *,
diff --git a/conf.c b/conf.c
index db40051..a87ef8d 100644
--- a/conf.c
+++ b/conf.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: conf.c,v 1.84 2011/06/24 06:06:24 okan Exp $
+ * $OpenBSD: conf.c,v 1.85 2011/06/24 06:09:26 okan Exp $
*/
#include <sys/param.h>
@@ -554,6 +554,7 @@ static struct {
{ "window_grouptoggle", mousefunc_window_grouptoggle,
MOUSEBIND_CTX_WIN },
{ "window_lower", mousefunc_window_lower, MOUSEBIND_CTX_WIN },
+ { "window_raise", mousefunc_window_raise, MOUSEBIND_CTX_WIN },
{ "window_hide", mousefunc_window_hide, MOUSEBIND_CTX_WIN },
{ "menu_group", mousefunc_menu_group, MOUSEBIND_CTX_ROOT },
{ "menu_unhide", mousefunc_menu_unhide, MOUSEBIND_CTX_ROOT },
diff --git a/cwmrc.5 b/cwmrc.5
index 1d8b64b..24f3e52 100644
--- a/cwmrc.5
+++ b/cwmrc.5
@@ -1,4 +1,4 @@
-.\" $OpenBSD: cwmrc.5,v 1.36 2011/06/24 06:06:24 okan Exp $
+.\" $OpenBSD: cwmrc.5,v 1.37 2011/06/24 06:09:26 okan Exp $
.\"
.\" Copyright (c) 2004,2005 Marius Aamodt Eriksen <marius@monkey.org>
.\"
@@ -402,6 +402,8 @@ Move current window.
Resize current window.
.It window_lower
Lower current window.
+.It window_raise
+Raise current window.
.It window_hide
Hide current window.
.It window_grouptoggle
diff --git a/mousefunc.c b/mousefunc.c
index e38873e..c296d75 100644
--- a/mousefunc.c
+++ b/mousefunc.c
@@ -16,7 +16,7 @@
* ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*
- * $OpenBSD: mousefunc.c,v 1.29 2011/06/24 06:06:24 okan Exp $
+ * $OpenBSD: mousefunc.c,v 1.30 2011/06/24 06:09:26 okan Exp $
*/
#include <sys/param.h>
@@ -197,6 +197,12 @@ mousefunc_window_lower(struct client_ctx *cc, void *arg)
}
void
+mousefunc_window_raise(struct client_ctx *cc, void *arg)
+{
+ client_raise(cc);
+}
+
+void
mousefunc_window_hide(struct client_ctx *cc, void *arg)
{
client_hide(cc);