structure has no member name 'table'



hello,

I am trying to create menus with the GtkMenuFactory and am using the
get_main_menu() function from the GTK Tutorial:

void get_main_menu(GtkWidget *window, GtkWidget ** menubar)
{
         int nmenu_items = sizeof(menu_items) / sizeof(menu_items[0]);
         GtkMenuFactory *factory;
         GtkMenuFactory *subfactory;

         factory = gtk_menu_factory_new(GTK_MENU_FACTORY_MENU_BAR);
         subfactory = gtk_menu_factory_new(GTK_MENU_FACTORY_MENU_BAR);

         gtk_menu_factory_add_subfactory(factory, subfactory, "<Main>");

         gtk_menu_factory_add_entries(factory, menu_items, nmenu_items);

         gtk_window_add_accelerator_table(GTK_WINDOW(window),
subfactory->table);

         if (menubar)
             *menubar = subfactory->widget;
}

When I try to compile this, it says:

structure has no member name 'table'

It is talking about this line:

gtk_window_add_accelerator_table(GTK_WINDOW(window), subfactory->table);

Has there been an API change or am I doing something wrong?
If there has been an API change, and that structure no longer has
the 'table' member, what replaced it?

thanks for the help,

--
Aaron Walker
aaron@iconmedia.com
http://iconmedia.com/aaron/





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