[gtk/kill-tree-menu: 12/52] notebook: Remove menu remnants
- From: Matthias Clasen <matthiasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk/kill-tree-menu: 12/52] notebook: Remove menu remnants
- Date: Sun, 29 Dec 2019 03:03:50 +0000 (UTC)
commit 6996e661d22d9b5135a80820ce6e822cd75845a7
Author: Matthias Clasen <mclasen redhat com>
Date: Fri Dec 27 08:47:12 2019 -0500
notebook: Remove menu remnants
gtk/gtknotebook.c | 38 +-------------------------------------
1 file changed, 1 insertion(+), 37 deletions(-)
---
diff --git a/gtk/gtknotebook.c b/gtk/gtknotebook.c
index 9ce49dd93e..c2dd98e900 100644
--- a/gtk/gtknotebook.c
+++ b/gtk/gtknotebook.c
@@ -2555,46 +2555,10 @@ gtk_notebook_popup_menu (GtkWidget *widget)
{
GtkNotebook *notebook = GTK_NOTEBOOK (widget);
GtkNotebookPrivate *priv = notebook->priv;
- GtkNotebookPage *page;
- GtkWidget *tab_label = NULL;
if (priv->menu)
{
- if (priv->focus_tab)
- {
- page = priv->focus_tab->data;
- tab_label = page->tab_label;
- }
-
- if (tab_label)
- {
- g_object_set (priv->menu,
- "anchor-hints", (GDK_ANCHOR_FLIP_Y |
- GDK_ANCHOR_SLIDE |
- GDK_ANCHOR_RESIZE),
- NULL);
-
- gtk_menu_popup_at_widget (GTK_MENU (priv->menu),
- tab_label,
- GDK_GRAVITY_SOUTH_WEST,
- GDK_GRAVITY_NORTH_WEST,
- NULL);
- }
- else
- {
- g_object_set (priv->menu,
- "anchor-hints", (GDK_ANCHOR_SLIDE |
- GDK_ANCHOR_RESIZE),
- NULL);
-
- gtk_menu_popup_at_widget (GTK_MENU (priv->menu),
- widget,
- GDK_GRAVITY_NORTH_WEST,
- GDK_GRAVITY_NORTH_WEST,
- NULL);
- }
-
- gtk_menu_shell_select_first (GTK_MENU_SHELL (priv->menu), FALSE);
+ gtk_popover_popup (GTK_POPOVER (priv->menu));
return TRUE;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]