aboutsummaryrefslogtreecommitdiffstats
path: root/mousefunc.c
diff options
context:
space:
mode:
Diffstat (limited to 'mousefunc.c')
-rw-r--r--mousefunc.c17
1 files changed, 11 insertions, 6 deletions
diff --git a/mousefunc.c b/mousefunc.c
index bee700d..828ad83 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.
*
- * $Id: mousefunc.c,v 1.16 2009/12/08 16:52:17 okan Exp $
+ * $Id: mousefunc.c,v 1.17 2009/12/10 17:16:51 oga Exp $
*/
#include "headers.h"
@@ -198,11 +198,13 @@ mousefunc_menu_group(struct client_ctx *cc, void *arg)
void
mousefunc_menu_unhide(struct client_ctx *cc, void *arg)
{
+ struct screen_ctx *sc;
struct client_ctx *old_cc;
struct menu *mi;
struct menu_q menuq;
char *wname;
+ sc = cc->sc;
old_cc = client_current();
TAILQ_INIT(&menuq);
@@ -221,7 +223,7 @@ mousefunc_menu_unhide(struct client_ctx *cc, void *arg)
if (TAILQ_EMPTY(&menuq))
return;
- mi = menu_filter(&menuq, NULL, NULL, 0, NULL, NULL);
+ mi = menu_filter(sc, &menuq, NULL, NULL, 0, NULL, NULL);
if (mi != NULL) {
cc = (struct client_ctx *)mi->ctx;
client_unhide(cc);
@@ -240,9 +242,12 @@ mousefunc_menu_unhide(struct client_ctx *cc, void *arg)
void
mousefunc_menu_cmd(struct client_ctx *cc, void *arg)
{
- struct menu *mi;
- struct menu_q menuq;
- struct cmd *cmd;
+ struct screen_ctx *sc;
+ struct menu *mi;
+ struct menu_q menuq;
+ struct cmd *cmd;
+
+ sc = cc->sc;
TAILQ_INIT(&menuq);
TAILQ_FOREACH(cmd, &Conf.cmdq, entry) {
@@ -254,7 +259,7 @@ mousefunc_menu_cmd(struct client_ctx *cc, void *arg)
if (TAILQ_EMPTY(&menuq))
return;
- mi = menu_filter(&menuq, NULL, NULL, 0, NULL, NULL);
+ mi = menu_filter(sc, &menuq, NULL, NULL, 0, NULL, NULL);
if (mi != NULL)
u_spawn(((struct cmd *)mi->ctx)->image);
else