GtkMenuButton: Support popovers

Add api to allow explicitly setting a GtkPopover instead of
a GtkMenu as the popup of a GtkMenuButton. Also, add api to
instruct the menu button to construct a popover when given
a menu model.

We set the style class "menu-button" on the button only when
it pops up a menu, to allow different treatment for the active
state of the button in the two cases.

https://bugzilla.gnome.org/show_bug.cgi?id=723878
This commit is contained in:
Matthias Clasen
2014-02-07 19:21:49 -05:00
parent 552c29b488
commit 9822d510a6
3 changed files with 365 additions and 101 deletions

View File

@ -2241,8 +2241,12 @@ GtkMenuButton
gtk_menu_button_new
gtk_menu_button_set_popup
gtk_menu_button_get_popup
gtk_menu_button_set_popover
gtk_menu_button_get_popover
gtk_menu_button_set_menu_model
gtk_menu_button_get_menu_model
gtk_menu_button_set_use_popover
gtk_menu_button_get_use_popover
gtk_menu_button_set_direction
gtk_menu_button_get_direction
gtk_menu_button_set_align_widget