[nautilus-actions] Let the About dialog get the toplevel window



commit 148d868b6edbb78689e94d405216ad97a6ad8312
Author: Pierre Wieser <pwieser trychlos org>
Date:   Thu Jan 6 23:46:46 2011 +0100

    Let the About dialog get the toplevel window

 ChangeLog                   |    3 +++
 src/nact/nact-main-window.c |   13 ++++++++++++-
 2 files changed, 15 insertions(+), 1 deletions(-)
---
diff --git a/ChangeLog b/ChangeLog
index b0160d6..527e5cf 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,8 @@
 2011-01-06 Pierre Wieser <pwieser trychlos org>
 
+	* src/nact/nact-main-window.c (iabout_get_toplevel):
+	Let the About dialog get the toplevel window.
+
 	* src/nact/nact-preferences.ui:
 	* src/nact/nautilus-actions-config-tool.ui:
 	Apply patch provided by Christian Kirbach. Fix #638548.
diff --git a/src/nact/nact-main-window.c b/src/nact/nact-main-window.c
index 259c75d..69cada7 100644
--- a/src/nact/nact-main-window.c
+++ b/src/nact/nact-main-window.c
@@ -192,7 +192,8 @@ static void     ipivot_consumer_on_mandatory_prefs_changed( NAIPivotConsumer *in
 static void     update_ui_after_provider_change( NactMainWindow *window );
 static void     reload( NactMainWindow *window );
 
-static gchar   *iabout_get_application_name( NAIAbout *instance );
+static gchar     *iabout_get_application_name( NAIAbout *instance );
+static GtkWindow *iabout_get_toplevel( NAIAbout *instance );
 
 GType
 nact_main_window_get_type( void )
@@ -601,6 +602,7 @@ iabout_iface_init( NAIAboutInterface *iface )
 	g_debug( "%s: iface=%p", thisfn, ( void * ) iface );
 
 	iface->get_application_name = iabout_get_application_name;
+	iface->get_toplevel = iabout_get_toplevel;
 }
 
 static void
@@ -1633,3 +1635,12 @@ iabout_get_application_name( NAIAbout *instance )
 	application = base_window_get_application( BASE_WINDOW( instance ));
 	return( base_application_get_application_name( application ));
 }
+
+static GtkWindow *
+iabout_get_toplevel( NAIAbout *instance )
+{
+	g_return_val_if_fail( NA_IS_IABOUT( instance ), NULL );
+	g_return_val_if_fail( BASE_IS_WINDOW( instance ), NULL );
+
+	return( base_window_get_toplevel( BASE_WINDOW( instance )));
+}



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