diff options
author | Matthew Barnes <mbarnes@redhat.com> | 2011-01-13 23:54:58 +0800 |
---|---|---|
committer | Matthew Barnes <mbarnes@redhat.com> | 2011-01-15 03:58:29 +0800 |
commit | 0af3ff804c0d71c76fd63f0a2a152cac7de64863 (patch) | |
tree | e80b7e357654f0dcc3cef08e1d2d459b9cf45d85 /widgets/table | |
parent | 7087e222f8422470c44ce2ecd5c598fefd2315fc (diff) | |
download | gsoc2013-evolution-0af3ff804c0d71c76fd63f0a2a152cac7de64863.tar.gz gsoc2013-evolution-0af3ff804c0d71c76fd63f0a2a152cac7de64863.tar.zst gsoc2013-evolution-0af3ff804c0d71c76fd63f0a2a152cac7de64863.zip |
Fudge gtk_widget_get_preferred_size() for gtk2.
Easy enough to fake gtk_widget_get_preferred_size() in gtk2 using
gtk_widget_size_request(). Reduces diff noise with gtk3 branch.
Diffstat (limited to 'widgets/table')
-rw-r--r-- | widgets/table/e-cell-combo.c | 2 | ||||
-rw-r--r-- | widgets/table/e-cell-date-edit.c | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/widgets/table/e-cell-combo.c b/widgets/table/e-cell-combo.c index d4ba4f31e3..6e1eb5ca80 100644 --- a/widgets/table/e-cell-combo.c +++ b/widgets/table/e-cell-combo.c @@ -447,7 +447,7 @@ e_cell_combo_get_popup_pos (ECellCombo *ecc, widget = gtk_scrolled_window_get_vscrollbar (popup); gtk_widget_get_child_requisition (widget, &requisition); - gtk_widget_size_request (ecc->popup_tree_view, &list_requisition); + gtk_widget_get_preferred_size (ecc->popup_tree_view, &list_requisition, NULL); min_height = MIN (list_requisition.height, requisition.height); if (!gtk_tree_model_iter_n_children (gtk_tree_view_get_model (GTK_TREE_VIEW (ecc->popup_tree_view)), NULL)) list_requisition.height += E_CELL_COMBO_LIST_EMPTY_HEIGHT; diff --git a/widgets/table/e-cell-date-edit.c b/widgets/table/e-cell-date-edit.c index 73a5d946b2..005f7a63e4 100644 --- a/widgets/table/e-cell-date-edit.c +++ b/widgets/table/e-cell-date-edit.c @@ -688,7 +688,7 @@ e_cell_date_edit_get_popup_pos (ECellDateEdit *ecde, the vertical scrollbar in case we need to show that. */ screen_width = gdk_screen_width (); - gtk_widget_size_request (ecde->popup_window, &popup_requisition); + gtk_widget_get_preferred_size (ecde->popup_window, &popup_requisition, NULL); /* Calculate the desired width. */ *width = popup_requisition.width; |