[nautilus-actions] Initialize the main window with XML UI properties
- From: Pierre Wieser <pwieser src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [nautilus-actions] Initialize the main window with XML UI properties
- Date: Fri, 21 Jan 2011 18:49:04 +0000 (UTC)
commit 350690461f5685bf8efcc948764ce02bb6a3882e
Author: Pierre Wieser <pwieser trychlos org>
Date: Fri Jan 21 12:04:25 2011 +0100
Initialize the main window with XML UI properties
ChangeLog | 3 +++
src/nact/nact-main-window.c | 16 +++++++++++++---
2 files changed, 16 insertions(+), 3 deletions(-)
---
diff --git a/ChangeLog b/ChangeLog
index 872d5d6..d163133 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,8 @@
2011-01-21 Pierre Wieser <pwieser trychlos org>
+ * src/nact/nact-main-window.c (nact_main_window_new):
+ Initialize the main window with XML UI properties.
+
* src/nact/base-window.c:
* src/nact/base-window.h: Rename initialization properties.
diff --git a/src/nact/nact-main-window.c b/src/nact/nact-main-window.c
index 8faff91..649671c 100644
--- a/src/nact/nact-main-window.c
+++ b/src/nact/nact-main-window.c
@@ -135,7 +135,10 @@ enum {
LAST_SIGNAL
};
-static NactWindowClass *st_parent_class = NULL;
+static const gchar *st_xmlui_filename = PKGDATADIR "/nautilus-actions-config-tool.ui";
+static const gchar *st_xmlui_toplevel = "MainWindow";
+
+static NactWindowClass *st_parent_class = NULL;
static gint st_signals[ LAST_SIGNAL ] = { 0 };
static GType register_type( void );
@@ -824,10 +827,17 @@ instance_finalize( GObject *window )
NactMainWindow *
nact_main_window_new( const NactApplication *application )
{
+ NactMainWindow *window;
+
g_return_val_if_fail( NACT_IS_APPLICATION( application ), NULL );
- return( g_object_new( NACT_MAIN_WINDOW_TYPE,
- BASE_PROP_APPLICATION, application, NULL ));
+ window = g_object_new( NACT_MAIN_WINDOW_TYPE,
+ BASE_PROP_APPLICATION, application,
+ BASE_PROP_XMLUI_FILENAME, st_xmlui_filename,
+ BASE_PROP_TOPLEVEL_NAME, st_xmlui_toplevel,
+ NULL );
+
+ return( window );
}
/**
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]