Commit 95483044 authored by Pierre Wieser's avatar Pierre Wieser

Remove New menu and Preferences cross-references

parent 44fc870d
2009-10-19 Pierre Wieser <pwieser@trychlos.org>
* src/nact/nact-imenubar.c:
Remove New menu and Preferences cross-references.
* src/nact/nact-window.c (nact_window_signal_connect):
Check GObject validity.
2009-10-14 Pierre Wieser <pwieser@trychlos.org>
* src/nact/nact-window.c (instance_dispose):
......
......@@ -178,13 +178,11 @@ typedef struct {
static const MenuActionStruct menu_actions[] = {
{ "FileMenu", "NewActionItem" },
{ "FileMenu", "NewProfileItem" },
{ "FileMenu", "NewMenuItem" },
{ "FileMenu", "SaveItem" },
{ "FileMenu", "QuitItem" },
{ "EditMenu", "DuplicateItem" },
{ "EditMenu", "DeleteItem" },
{ "EditMenu", "ReloadActionsItem" },
{ "EditMenu", "PreferencesItem" },
{ "ToolsMenu", "ImportItem" },
{ "ToolsMenu", "ExportItem" },
{ "HelpMenu", "HelpItem" },
......@@ -321,6 +319,7 @@ nact_imenubar_init( NactMainWindow *window )
GtkAction *action = gtk_ui_manager_get_action( ui_manager, path );
GtkWidget *widget = gtk_ui_manager_get_widget( ui_manager, path );
g_object_set_data( G_OBJECT( widget ), "nact-imenubar-action", action );
g_debug( "path=%s, widget=%p", path, ( void * ) widget );
nact_window_signal_connect( NACT_WINDOW( window ), G_OBJECT( widget ), "select", G_CALLBACK( on_menu_item_selected ));
nact_window_signal_connect( NACT_WINDOW( window ), G_OBJECT( widget ), "deselect", G_CALLBACK( on_menu_item_deselected ));
g_free( path );
......
......@@ -355,10 +355,13 @@ void
nact_window_signal_connect( NactWindow *window, GObject *instance, const gchar *signal, GCallback fn )
{
static const gchar *thisfn = "nact_window_signal_connect";
gulong handler_id;
NactWindowRecordedSignal *str;
gulong handler_id = g_signal_connect( instance, signal, fn, window );
g_return_if_fail( instance );
handler_id = g_signal_connect( instance, signal, fn, window );
NactWindowRecordedSignal *str = g_new0( NactWindowRecordedSignal, 1 );
str = g_new0( NactWindowRecordedSignal, 1 );
str->instance = instance;
str->handler_id = handler_id;
window->private->signals = g_slist_prepend( window->private->signals, str );
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment