diff options
| author | Dana Jansens <danakj@orodu.net> | 2007-07-09 16:40:49 +0000 |
|---|---|---|
| committer | Dana Jansens <danakj@orodu.net> | 2007-07-09 16:40:49 +0000 |
| commit | 007a84323f7c3445683fb189c00b7952cdd7d988 (patch) | |
| tree | 645e0218a5db57a6d575973d460ebb6724387ea7 /openbox | |
| parent | b32181ac69d3aa18756348991028f809cb2ee046 (diff) | |
hm..
Diffstat (limited to 'openbox')
| -rw-r--r-- | openbox/actions/cyclewindows.c | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/openbox/actions/cyclewindows.c b/openbox/actions/cyclewindows.c index ed2a4d0b..555417e2 100644 --- a/openbox/actions/cyclewindows.c +++ b/openbox/actions/cyclewindows.c @@ -14,6 +14,8 @@ typedef struct { GSList *actions; } Options; +static gboolean cycling = FALSE; + static gpointer setup_func(ObParseInst *i, xmlDocPtr doc, xmlNodePtr node); static void free_func(gpointer options); static gboolean run_func(ObActionsData *data, gpointer options); @@ -92,6 +94,7 @@ static gboolean run_func(ObActionsData *data, gpointer options) TRUE, o->dialog, FALSE, FALSE); + cycling = TRUE; return TRUE; } @@ -129,7 +132,10 @@ static gboolean i_input_func(guint initial_state, static void i_cancel_func(gpointer options) { - end_cycle(TRUE, 0, options); + /* we get cancelled when we move focus, but we're not cycling anymore, so + just ignore that */ + if (cycling) + end_cycle(TRUE, 0, options); } static void end_cycle(gboolean cancel, guint state, Options *o) @@ -149,4 +155,5 @@ static void end_cycle(gboolean cancel, guint state, Options *o) actions_run_acts(o->actions, OB_USER_ACTION_KEYBOARD_KEY, state, -1, -1, 0, OB_FRAME_CONTEXT_NONE, ft); } + cycling = FALSE; } |
