diff --git a/plugins/gtkgui/config.py b/plugins/gtkgui/config.py
index d9169c2fd015a33dcda1f85a44928fc77278ac55..2c84da85493c155e4f99151f61652976bd82c328 100644
--- a/plugins/gtkgui/config.py
+++ b/plugins/gtkgui/config.py
@@ -1365,13 +1365,12 @@ class Account_modification_window:
 
 class Accounts_window:
 	"""Class for accounts window: lists of accounts"""
-	def on_delete_event(self, widget, event):
-		self.window.hide()  
-		return True # do NOT destory the window 
+	def on_accounts_window_destroy(self, widget):
+		del self.plugin.windows['accounts'] 
 
 	def on_close_button_clicked(self, widget):
-		self.window.hide()
-		
+		widget.get_toplevel().destroy()
+
 	def init_accounts(self):
 		"""initialize listStore with existing accounts"""
 		self.modify_button.set_sensitive(False)
diff --git a/plugins/gtkgui/gtkgui.glade b/plugins/gtkgui/gtkgui.glade
index 9419761cecec02eb89b1e731a0aeacf977a09535..a653cbd45e057f0c837e512bb8cc9598b4485b91 100644
--- a/plugins/gtkgui/gtkgui.glade
+++ b/plugins/gtkgui/gtkgui.glade
@@ -310,6 +310,7 @@
   <property name="border_width">4</property>
   <property name="width_request">420</property>
   <property name="height_request">160</property>
+  <property name="visible">True</property>
   <property name="title" translatable="yes">Accounts</property>
   <property name="type">GTK_WINDOW_TOPLEVEL</property>
   <property name="window_position">GTK_WIN_POS_NONE</property>
@@ -321,7 +322,7 @@
   <property name="skip_pager_hint">False</property>
   <property name="type_hint">GDK_WINDOW_TYPE_HINT_NORMAL</property>
   <property name="gravity">GDK_GRAVITY_NORTH_WEST</property>
-  <signal name="delete_event" handler="on_delete_event" last_modification_time="Sun, 27 Mar 2005 18:58:04 GMT"/>
+  <signal name="destroy" handler="on_accounts_window_destroy" last_modification_time="Sat, 02 Apr 2005 20:34:04 GMT"/>
 
   <child>
     <widget class="GtkVBox" id="vbox5">
diff --git a/plugins/gtkgui/gtkgui.py b/plugins/gtkgui/gtkgui.py
index 5af5ee2a66e4692d469dd919f19af44d9be5948b..995a9bac48c45ac6b441dac4b4be091cbe386698 100644
--- a/plugins/gtkgui/gtkgui.py
+++ b/plugins/gtkgui/gtkgui.py
@@ -934,7 +934,6 @@ class plugin:
 		# get instances for windows/dialogs that will show_all()/hide()
 		self.windows['preferences'] = Preferences_window(self)
 		self.windows['roster'] = self.roster
-		self.windows['accounts'] = Accounts_window(self)
 
 		gtk.gdk.threads_enter()
 		gobject.timeout_add(100, self.autoconnect)
diff --git a/plugins/gtkgui/roster_window.py b/plugins/gtkgui/roster_window.py
index 513fff48c9ecfcd979e9fef8956b01e1678a10fb..c44dd99eb1b3aa85c39669d65f454c69a338f2f3 100644
--- a/plugins/gtkgui/roster_window.py
+++ b/plugins/gtkgui/roster_window.py
@@ -908,10 +908,8 @@ class Roster_window:
 		About_dialog(self.plugin)
 
 	def on_accounts_menuitem_activate(self, widget):
-		if	self.plugin.windows['accounts'].window.get_property('visible'):
-			self.plugin.windows['accounts'].window.present() # give focus
-		else:
-			self.plugin.windows['accounts'].window.show_all()
+		if not self.plugin.windows.has_key('accounts'):
+			self.plugin.windows['accounts'] = Accounts_window(self.plugin) 
 
 	def close_all(self, dic):
 		"""close all the windows in the given dictionary"""