summaryrefslogtreecommitdiff
path: root/openbox/actions.c
diff options
context:
space:
mode:
Diffstat (limited to 'openbox/actions.c')
-rw-r--r--openbox/actions.c13
1 files changed, 11 insertions, 2 deletions
diff --git a/openbox/actions.c b/openbox/actions.c
index 7087f37d..00563a70 100644
--- a/openbox/actions.c
+++ b/openbox/actions.c
@@ -19,6 +19,7 @@
#include "actions.h"
#include "gettext.h"
#include "grab.h"
+#include "screen.h"
static void actions_definition_ref(ObActionsDefinition *def);
static void actions_definition_unref(ObActionsDefinition *def);
@@ -54,12 +55,12 @@ static GSList *registered = NULL;
void actions_startup(gboolean reconfig)
{
if (reconfig) return;
-
-
}
void actions_shutdown(gboolean reconfig)
{
+ actions_interactive_cancel_act();
+
if (reconfig) return;
/* free all the registered actions */
@@ -205,6 +206,14 @@ void actions_run_acts(GSList *acts,
{
GSList *it;
+ /* Don't allow saving the initial state when running things from the
+ menu */
+ if (uact == OB_USER_ACTION_MENU_SELECTION)
+ state = 0;
+ /* If x and y are < 0 then use the current pointer position */
+ if (x < 0 && y < 0)
+ screen_pointer_pos(&x, &y);
+
for (it = acts; it; it = g_slist_next(it)) {
ObActionsData data;
ObActionsAct *act = it->data;