Commit 161b0a5c authored by Michael Natterer's avatar Michael Natterer Committed by Michael Natterer

bail out if there is no need for scrolling (more obvious than adding

2006-03-27  Michael Natterer  <mitch@imendio.com>

	* gtk/gtkmenu.c (gtk_menu_scroll_by): bail out if there is no need
	for scrolling (more obvious than adding additional conditions to
	the scroll offset calculation). Fixes bug #335912.
parent f09810e0
2006-03-27 Michael Natterer <mitch@imendio.com>
* gtk/gtkmenu.c (gtk_menu_scroll_by): bail out if there is no need
for scrolling (more obvious than adding additional conditions to
the scroll offset calculation). Fixes bug #335912.
2006-03-27 Anders Carlsson <andersca@imendio.com>
* gtk/Makefile.am:
......
2006-03-27 Michael Natterer <mitch@imendio.com>
* gtk/gtkmenu.c (gtk_menu_scroll_by): bail out if there is no need
for scrolling (more obvious than adding additional conditions to
the scroll offset calculation). Fixes bug #335912.
2006-03-27 Anders Carlsson <andersca@imendio.com>
* gtk/Makefile.am:
......
......@@ -2983,6 +2983,10 @@ gtk_menu_scroll_by (GtkMenu *menu,
gdk_drawable_get_size (widget->window, &view_width, &view_height);
if (menu->scroll_offset == 0 &&
view_height >= widget->requisition.height)
return;
/* Don't scroll past the bottom if we weren't before: */
if (menu->scroll_offset > 0)
view_height -= MENU_SCROLL_ARROW_HEIGHT;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment