Hi all, I am starting with a small app which will handle documents. I want this app has two different menubars : - a first one when there is no document - another one when the document is opened.
I have tried to use gtk_application_set_menubar with two different GMenuModel, but no luck: the GtkApplicationWindow menubar never changes. After having searched in the sources, I found that the GtkWidget menubar is automatically rebuilt from a GMenu menubar_section. But the menubar_section itself is initially built in real_realize, thenonly rebuilt when some gtk-shell settings changes (notify::gtk-shell-shows-menubar exactly, but this not relevant here). So it appears to me that it is just impossible to replace the menubar. Am I right ? Is it the expected behavior ? As a side effect, I do not understand the rationale behind gtk_application_set_menubar: why are we allowed to change the GMenuModel if the visible GtkWidget is not updated ? Thanks for some explanations.. Regards Pierre _______________________________________________ gtk-app-devel-list mailing list gtk-app-devel-list@gnome.org https://mail.gnome.org/mailman/listinfo/gtk-app-devel-list