[passepartout] added a signal handler to show the streams window



commit 72b4ed1c02e584d321166842eacea5a2fd6f54b0
Author: Sven Herzberg <herzi lanedo com>
Date:   Sat May 2 10:52:22 2009 +0200

    added a signal handler to show the streams window
    
    * src/pptout/window.cc,
    * src/pptout/window.h,
    * src/pptout/windowmenus.cc: create the streams window when the user requests
      it, not when he's waiting for the main window to show up
---
 src/pptout/window.cc      |    9 +++++++++
 src/pptout/window.h       |    1 +
 src/pptout/windowmenus.cc |    3 +--
 3 files changed, 11 insertions(+), 2 deletions(-)

diff --git a/src/pptout/window.cc b/src/pptout/window.cc
index 1cb3b21..cbd1ad7 100644
--- a/src/pptout/window.cc
+++ b/src/pptout/window.cc
@@ -374,6 +374,15 @@ FrameWindow::show_properties (void)
   dialog.show_raise ();
 }
 
+void
+FrameWindow::show_streams (void)
+{
+  StreamDialog& dialog = StreamDialog::instance ();
+  dialog.set_transient_for (*this);
+  dialog.set_modal (false);
+  dialog.show_raise ();
+}
+
 bool FrameWindow::on_delete_event(GdkEventAny *event) {
   close();
   return true;
diff --git a/src/pptout/window.h b/src/pptout/window.h
index 4814ecf..86904c6 100644
--- a/src/pptout/window.h
+++ b/src/pptout/window.h
@@ -72,6 +72,7 @@ private:
 
   void show_about (void);
   void show_properties (void);
+  void show_streams (void);
 
   void create_menus (Gtk::RecentFilter& filter);
   void show_preferences ();
diff --git a/src/pptout/windowmenus.cc b/src/pptout/windowmenus.cc
index b0447d3..67a77c1 100644
--- a/src/pptout/windowmenus.cc
+++ b/src/pptout/windowmenus.cc
@@ -324,8 +324,7 @@ FrameWindow::create_menus (Gtk::RecentFilter& f)
   
   doc_group->add(Action::create("ViewStreams", StockID("streams"),
                                 _("_Streams"), _("Show Streams window")),
-                 mem_fun(StreamDialog::instance(),
-                         &StreamDialog::show_raise));
+                 mem_fun(*this, &FrameWindow::show_streams));
   
   {
     Glib::RefPtr<Gtk::ToggleAction> action =



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]