Typo: 'asyncronous' -> 'asynchronous'.
[synfig.git] / synfig-studio / trunk / src / gtkmm / dockbook.cpp
index 290d48f..a7f0b6a 100644 (file)
@@ -2,7 +2,7 @@
 /*!    \file dockbook.cpp
 **     \brief Template File
 **
-**     $Id: dockbook.cpp,v 1.1.1.1 2005/01/07 03:34:36 darco Exp $
+**     $Id$
 **
 **     \legal
 **     Copyright (c) 2002-2005 Robert B. Quattlebaum Jr., Adrian Bentley
@@ -79,9 +79,7 @@ void
 DockBook::clear()
 {
        while(get_n_pages())
-       {
                remove(static_cast<Dockable&>(*get_nth_page(get_n_pages()-1)));
-       }
 }
 
 void
@@ -240,6 +238,7 @@ DockBook::tab_button_pressed(GdkEventButton* event, Dockable* dockable)
                return false;
 
        Gtk::Menu *tabmenu=manage(new class Gtk::Menu());
+       tabmenu->signal_hide().connect(sigc::bind(sigc::ptr_fun(&delete_widget), tabmenu));
 
        tabmenu->items().push_back(
                Gtk::Menu_Helpers::StockMenuElem(Gtk::StockID("gtk-close"),