summaryrefslogtreecommitdiff
path: root/src/perl/ui
diff options
context:
space:
mode:
authorTimo Sirainen <cras@irssi.org>2002-03-14 21:59:16 +0000
committercras <cras@dbcabf3a-b0e7-0310-adc4-f8d773084564>2002-03-14 21:59:16 +0000
commit2a1b4c0a170bf18944b4b15905194c62aafd7472 (patch)
tree12335a81bab6e067b746aa7e1f7980393965332f /src/perl/ui
parente0c8f5d5025c7de41cb0d6050a3565e7090fda38 (diff)
downloadirssi-2a1b4c0a170bf18944b4b15905194c62aafd7472.zip
$window->command() changed active window temporarily to wanted one and then
back to old one. This wasn't very good idea if the old window was destroyed by the command.. git-svn-id: http://svn.irssi.org/repos/irssi/trunk@2613 dbcabf3a-b0e7-0310-adc4-f8d773084564
Diffstat (limited to 'src/perl/ui')
-rw-r--r--src/perl/ui/Window.xs3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/perl/ui/Window.xs b/src/perl/ui/Window.xs
index ac65480e..cadff1ab 100644
--- a/src/perl/ui/Window.xs
+++ b/src/perl/ui/Window.xs
@@ -158,7 +158,8 @@ CODE:
old = active_win;
active_win = window;
perl_command(cmd, window->active_server, window->active);
- active_win = old;
+ if (g_slist_find(windows, old) != NULL)
+ active_win = old;
void
window_item_add(window, item, automatic)