[nautilus/rendering-cleanup: 14/15] Port to rendering-cleanup-next
- From: Christian Persch <chpe src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [nautilus/rendering-cleanup: 14/15] Port to rendering-cleanup-next
- Date: Sun, 26 Sep 2010 18:14:22 +0000 (UTC)
commit 389301bda1164d39e363b968ec96d48cd13104fe
Author: Christian Persch <chpe gnome org>
Date: Thu Sep 16 18:34:35 2010 +0200
Port to rendering-cleanup-next
src/file-manager/fm-desktop-icon-view.c | 2 +-
src/nautilus-pathbar.c | 21 +++++++++------------
src/nautilus-side-pane.c | 3 +--
3 files changed, 11 insertions(+), 15 deletions(-)
---
diff --git a/src/file-manager/fm-desktop-icon-view.c b/src/file-manager/fm-desktop-icon-view.c
index aa380f9..af0ef20 100644
--- a/src/file-manager/fm-desktop-icon-view.c
+++ b/src/file-manager/fm-desktop-icon-view.c
@@ -221,7 +221,7 @@ net_workarea_changed (FMDesktopIconView *icon_view,
nautilus_icon_container_set_margins (icon_container,
0, 0, 0, 0);
} else {
- screen = gdk_drawable_get_screen (GDK_DRAWABLE (window));
+ screen = gdk_window_get_screen (window);
icon_container_set_workarea (
icon_container, screen, workareas, length_returned / sizeof (long));
diff --git a/src/nautilus-pathbar.c b/src/nautilus-pathbar.c
index e4eb76e..06579de 100644
--- a/src/nautilus-pathbar.c
+++ b/src/nautilus-pathbar.c
@@ -575,14 +575,13 @@ nautilus_path_bar_size_allocate (GtkWidget *widget,
width = 0;
}
- gtk_size_request_get_size (GTK_SIZE_REQUEST (BUTTON_DATA (path_bar->button_list->data)->button),
- &child_requisition, NULL);
+ gtk_widget_get_preferred_size (BUTTON_DATA (path_bar->button_list->data)->button,
+ &child_requisition, NULL);
width += child_requisition.width;
for (list = path_bar->button_list->next; list; list = list->next) {
child = BUTTON_DATA (list->data)->button;
- gtk_size_request_get_size (GTK_SIZE_REQUEST (child),
- &child_requisition, NULL);
+ gtk_widget_get_preferred_size (child, &child_requisition, NULL);
width += child_requisition.width + path_bar->spacing;
if (list == path_bar->fake_root) {
@@ -614,14 +613,13 @@ nautilus_path_bar_size_allocate (GtkWidget *widget,
* button, then count backwards.
*/
/* Count down the path chain towards the end. */
- gtk_size_request_get_size (GTK_SIZE_REQUEST (BUTTON_DATA (first_button->data)->button),
- &child_requisition, NULL);
+ gtk_widget_get_preferred_size (BUTTON_DATA (first_button->data)->button,
+ &child_requisition, NULL);
width = child_requisition.width;
list = first_button->prev;
while (list && !reached_end) {
child = BUTTON_DATA (list->data)->button;
- gtk_size_request_get_size (GTK_SIZE_REQUEST (child),
- &child_requisition, NULL);
+ gtk_widget_get_preferred_size (child, &child_requisition, NULL);
if (width + child_requisition.width + path_bar->spacing + slider_space > allocation_width) {
reached_end = TRUE;
@@ -640,8 +638,7 @@ nautilus_path_bar_size_allocate (GtkWidget *widget,
while (first_button->next && ! reached_end) {
child = BUTTON_DATA (first_button->next->data)->button;
- gtk_size_request_get_size (GTK_SIZE_REQUEST (child),
- &child_requisition, NULL);
+ gtk_widget_get_preferred_size (child, &child_requisition, NULL);
if (width + child_requisition.width + path_bar->spacing + slider_space > allocation_width) {
reached_end = TRUE;
@@ -675,8 +672,8 @@ nautilus_path_bar_size_allocate (GtkWidget *widget,
for (list = first_button; list; list = list->prev) {
child = BUTTON_DATA (list->data)->button;
- gtk_size_request_get_size (GTK_SIZE_REQUEST (child),
- &child_requisition, NULL);
+
+ gtk_widget_get_preferred_size (child, &child_requisition, NULL);
gtk_widget_get_allocation (widget, &widget_allocation);
diff --git a/src/nautilus-side-pane.c b/src/nautilus-side-pane.c
index e4da802..a2cbf6b 100644
--- a/src/nautilus-side-pane.c
+++ b/src/nautilus-side-pane.c
@@ -140,8 +140,7 @@ nautilus_side_pane_size_allocate (GtkWidget *widget,
frame = pane->details->title_frame;
hbox = pane->details->title_hbox;
- gtk_size_request_get_size (GTK_SIZE_REQUEST (hbox),
- &child_requisition, NULL);
+ gtk_widget_get_preferred_size (hbox, &child_requisition, NULL);
width = child_requisition.width;
gtk_widget_get_allocation (frame, &frame_allocation);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]