[libpeas] Use gtk_size_request_get_size when possible.
- From: Ignacio Casal Quinteiro <icq src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [libpeas] Use gtk_size_request_get_size when possible.
- Date: Sat, 18 Sep 2010 17:45:15 +0000 (UTC)
commit 71233ec2ca09ff599d4f0bf885307786d244a671
Author: Ignacio Casal Quinteiro <icq gnome org>
Date: Sat Sep 18 19:45:01 2010 +0200
Use gtk_size_request_get_size when possible.
libpeas-gtk/peas-gtk-plugin-manager-view.c | 10 ++++++++++
1 files changed, 10 insertions(+), 0 deletions(-)
---
diff --git a/libpeas-gtk/peas-gtk-plugin-manager-view.c b/libpeas-gtk/peas-gtk-plugin-manager-view.c
index ca8e875..f4340a0 100644
--- a/libpeas-gtk/peas-gtk-plugin-manager-view.c
+++ b/libpeas-gtk/peas-gtk-plugin-manager-view.c
@@ -361,7 +361,12 @@ menu_position_under_tree_view (GtkMenu *menu,
if (gtk_widget_get_direction (GTK_WIDGET (tree_view)) == GTK_TEXT_DIR_RTL)
{
GtkRequisition requisition;
+#if !GTK_CHECK_VERSION(2,90,7)
gtk_widget_size_request (GTK_WIDGET (menu), &requisition);
+#else
+ gtk_size_request_get_size (GTK_SIZE_REQUEST (menu), &requisition,
+ NULL);
+#endif
*x += rect.width - requisition.width;
}
}
@@ -375,7 +380,12 @@ menu_position_under_tree_view (GtkMenu *menu,
if (gtk_widget_get_direction (GTK_WIDGET (tree_view)) == GTK_TEXT_DIR_RTL)
{
GtkRequisition requisition;
+#if !GTK_CHECK_VERSION(2,90,7)
gtk_widget_size_request (GTK_WIDGET (menu), &requisition);
+#else
+ gtk_size_request_get_size (GTK_SIZE_REQUEST (menu), &requisition,
+ NULL);
+#endif
*x += allocation.width - requisition.width;
}
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]