diff -ru openbox-3.4.7.2/data/rc.xml openbox-3.4.7.2-patched/data/rc.xml --- openbox-3.4.7.2/data/rc.xml 2008-04-14 01:22:11.000000000 +0200 +++ openbox-3.4.7.2-patched/data/rc.xml 2008-11-30 20:55:08.000000000 +0100 @@ -123,6 +123,9 @@ 875 + no + diff -ru openbox-3.4.7.2/data/rc.xsd openbox-3.4.7.2-patched/data/rc.xsd --- openbox-3.4.7.2/data/rc.xsd 2008-02-29 22:18:07.000000000 +0100 +++ openbox-3.4.7.2-patched/data/rc.xsd 2008-11-30 20:55:08.000000000 +0100 @@ -91,6 +91,7 @@ + diff -ru openbox-3.4.7.2/openbox/config.c openbox-3.4.7.2-patched/openbox/config.c --- openbox-3.4.7.2/openbox/config.c 2008-04-15 18:18:09.000000000 +0200 +++ openbox-3.4.7.2-patched/openbox/config.c 2008-11-30 20:57:39.000000000 +0100 @@ -55,10 +55,11 @@ RrFont *config_font_menutitle; RrFont *config_font_osd; -guint config_desktops_num; -GSList *config_desktops_names; -guint config_screen_firstdesk; -guint config_desktop_popup_time; +guint config_desktops_num; +GSList *config_desktops_names; +guint config_screen_firstdesk; +guint config_desktop_popup_time; +gboolean config_desktop_goto_on_activate; gboolean config_resize_redraw; gint config_resize_popup_show; @@ -660,6 +661,8 @@ } if ((n = parse_find_node("popupTime", node))) config_desktop_popup_time = parse_int(doc, n); + if ((n = parse_find_node("gotoOnActivate", node))) + config_desktop_goto_on_activate = parse_bool(doc, n); } static void parse_resize(ObParseInst *i, xmlDocPtr doc, xmlNodePtr node, @@ -948,6 +951,7 @@ config_screen_firstdesk = 1; config_desktops_names = NULL; config_desktop_popup_time = 875; + config_desktop_goto_on_activate = FALSE; parse_register(i, "desktops", parse_desktops, NULL); diff -ru openbox-3.4.7.2/openbox/config.h openbox-3.4.7.2-patched/openbox/config.h --- openbox-3.4.7.2/openbox/config.h 2008-04-14 01:22:11.000000000 +0200 +++ openbox-3.4.7.2-patched/openbox/config.h 2008-11-30 20:55:08.000000000 +0100 @@ -153,6 +153,9 @@ extern GSList *config_desktops_names; /*! Amount of time to show the desktop switch dialog */ extern guint config_desktop_popup_time; +/*! Go to the desktop of a window when it is activated */ +extern gboolean config_desktop_goto_on_activate; + /*! The keycode of the key combo which resets the keybaord chains */ extern guint config_keyboard_reset_keycode; diff -ru openbox-3.4.7.2/openbox/event.c openbox-3.4.7.2-patched/openbox/event.c --- openbox-3.4.7.2/openbox/event.c 2008-04-14 01:22:11.000000000 +0200 +++ openbox-3.4.7.2-patched/openbox/event.c 2008-11-30 20:59:42.000000000 +0100 @@ -1335,7 +1335,7 @@ ob_debug_type(OB_DEBUG_APP_BUGS, "_NET_ACTIVE_WINDOW message for window %s is " "missing source indication\n"); - client_activate(client, TRUE, TRUE, TRUE, + client_activate(client, !config_desktop_goto_on_activate, TRUE, TRUE, (e->xclient.data.l[0] == 0 || e->xclient.data.l[0] == 2)); } else if (msgtype == prop_atoms.net_wm_moveresize) {