@eht16 commented on this pull request.

Could you describe in a bit more detail the exact problem?
I see the overflow menu appears "somewhere" on the screen but it still works basically. It's just offsetted.

Your changes seems to fix this quite fine, just want to know if there are more problems than the mispositioning.


In addons/src/ao_doclist.c:

> -		wy += allocation.y;
+	if (priv->in_overflow_menu) {
+		/* The button was added to the toolbar overflow menu (since the toolbar
+		 * isn't wide enough to contain the button), so use the toolbar window
+		 * instead
+		 */
+
+		/* Get the root coordinates of the toolbar's window */
+		int wx_root, wy_root, width;
+		window = gtk_widget_get_window (gtk_widget_get_ancestor(widget, GTK_TYPE_TOOLBAR));
+#if GTK_CHECK_VERSION(3, 0, 0)
+		gdk_window_get_geometry(window, &wx, &wy, &width, NULL);
+#else
+		gdk_window_get_geometry(window, &wx, &wy, &width, NULL, NULL);
+#endif
+		gdk_window_get_root_coords(window, wx, wy, &wx_root, &wy_root);

Not completely sure but can't we move the gdk_window_get_root_coords call below the others and so merge the two GTK version check blocks?


In addons/src/ao_doclist.c:

> +		/* Approximate the horizontal location of the overflow menu button */
+		/* TODO: See if there's a way to find the exact location */
+		wx = wx_root + width - (int) (widget_req.width * 1.5);
+		wy = wy_root;
+
+		/* This will be set TRUE if the overflow menu is open again and includes
+		 * the doclist menu item
+		 */
+		priv->in_overflow_menu = FALSE;
+
+	} else {
+		/* Retrieve size and position of both widget and menu */
+		window = gtk_widget_get_window(widget);
+		if (! gtk_widget_get_has_window(widget))
+		{
+

Is this empty line on purpose?


You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub, or mute the thread.