Sat, 15 Aug 2015 19:09:49 -0400
Only update the chat input box size and print debug info when the size actually changes. Otherwise, the debug log gets spammed with an entry on every keystroke. Discussed with grim.
| pidgin/gtkconv.c | file | annotate | diff | comparison | revisions |
--- a/pidgin/gtkconv.c Fri Aug 14 17:44:44 2015 -0400 +++ b/pidgin/gtkconv.c Sat Aug 15 19:09:49 2015 -0400 @@ -4940,6 +4940,8 @@ gint total_height; gint height; gint toolbar_size; + gint old_w; + gint old_h; GtkAllocation webview_allocation; GtkAllocation entry_allocation; @@ -4977,8 +4979,11 @@ height += toolbar_size; /* Actually set the size of the gtkconv entry widget. */ - gtk_widget_set_size_request(gtkconv->lower_hbox, -1, height); - purple_debug_info("pidgin", "resizing to %d, %d lines\n", height, min_lines); + gtk_widget_get_size_request(gtkconv->lower_hbox, &old_w, &old_h); + if (old_w != -1 || old_h != height) { + gtk_widget_set_size_request(gtkconv->lower_hbox, -1, height); + purple_debug_info("pidgin", "resizing to %d, %d lines\n", height, min_lines); + } return FALSE; }