[evolution/gtk3] Use GtkScrollable API instead of GtkLayout API's
- From: Vibha Yadav <yvibha src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [evolution/gtk3] Use GtkScrollable API instead of GtkLayout API's
- Date: Mon, 13 Dec 2010 11:24:56 +0000 (UTC)
commit 9c8daf2832435236a90908a64f3a7b956eebbf89
Author: Vibha Yadav <yvibha novell com>
Date: Mon Dec 13 16:53:31 2010 +0530
Use GtkScrollable API instead of GtkLayout API's
Using gtk_scrollable_get_vadjustment instead of
gtk_layout_get_vadjustment and
gtk_scrollable_get_hadjustment instead of gtk_layout_get_hadjustment
calendar/gui/e-day-view.c | 22 +++++++++++-----------
calendar/gui/e-meeting-time-sel.c | 16 ++++++++--------
libgnomecanvas/gnome-canvas.c | 32 ++++++++++++++++----------------
widgets/misc/e-canvas-utils.c | 8 ++++----
widgets/table/e-cell-combo.c | 4 ++--
widgets/table/e-cell-date-edit.c | 2 +-
widgets/table/e-table-field-chooser.c | 4 ++--
widgets/table/e-table-header-item.c | 14 +++++++-------
widgets/table/e-table.c | 22 +++++++++++-----------
widgets/table/e-tree.c | 24 ++++++++++++------------
widgets/text/e-reflow.c | 20 ++++++++++----------
11 files changed, 84 insertions(+), 84 deletions(-)
---
diff --git a/calendar/gui/e-day-view.c b/calendar/gui/e-day-view.c
index a3ccc42..e1d0889 100644
--- a/calendar/gui/e-day-view.c
+++ b/calendar/gui/e-day-view.c
@@ -1171,7 +1171,7 @@ e_day_view_init (EDayView *day_view)
*/
day_view->time_canvas = e_canvas_new ();
layout = GTK_LAYOUT (day_view->main_canvas);
- adjustment = gtk_layout_get_vadjustment (layout);
+ adjustment = gtk_scrollable_get_vadjustment (GTK_SCROLLABLE (layout));
layout = GTK_LAYOUT (day_view->time_canvas);
gtk_layout_set_vadjustment (layout, adjustment);
gtk_table_attach (GTK_TABLE (day_view), day_view->time_canvas,
@@ -1193,20 +1193,20 @@ e_day_view_init (EDayView *day_view)
* Scrollbar.
*/
layout = GTK_LAYOUT (day_view->main_canvas);
- adjustment = gtk_layout_get_hadjustment (layout);
+ adjustment = gtk_scrollable_get_hadjustment (GTK_SCROLLABLE (layout));
day_view->mc_hscrollbar = gtk_hscrollbar_new (adjustment);
gtk_table_attach (GTK_TABLE (day_view), day_view->mc_hscrollbar, 1, 2, 2, 3, GTK_FILL, 0, 0, 0);
gtk_widget_show (day_view->mc_hscrollbar);
layout = GTK_LAYOUT (day_view->top_canvas);
- adjustment = gtk_layout_get_vadjustment (layout);
+ adjustment = gtk_scrollable_get_vadjustment (GTK_SCROLLABLE (layout));
day_view->tc_vscrollbar = gtk_vscrollbar_new (adjustment);
gtk_table_attach (GTK_TABLE (day_view), day_view->tc_vscrollbar,
2, 3, 0, 1, 0, GTK_FILL, 0, 0);
/* gtk_widget_show (day_view->tc_vscrollbar); */
layout = GTK_LAYOUT (day_view->main_canvas);
- adjustment = gtk_layout_get_vadjustment (layout);
+ adjustment = gtk_scrollable_get_vadjustment (GTK_SCROLLABLE (layout));
day_view->vscrollbar = gtk_vscrollbar_new (adjustment);
gtk_table_attach (GTK_TABLE (day_view), day_view->vscrollbar,
2, 3, 1, 2, 0, GTK_EXPAND | GTK_FILL, 0, 0);
@@ -1578,7 +1578,7 @@ e_day_view_style_set (GtkWidget *widget,
MAX (day_view->row_height,
E_DAY_VIEW_ICON_HEIGHT + E_DAY_VIEW_ICON_Y_PAD + 2);
- adjustment = gtk_layout_get_vadjustment (GTK_LAYOUT (day_view->main_canvas));
+ adjustment = gtk_scrollable_get_vadjustment (GTK_SCROLLABLE (day_view->main_canvas));
gtk_adjustment_set_step_increment (adjustment, day_view->row_height);
day_view->top_row_height =
@@ -1591,7 +1591,7 @@ e_day_view_style_set (GtkWidget *widget,
E_DAY_VIEW_ICON_HEIGHT + E_DAY_VIEW_ICON_Y_PAD + 2 +
E_DAY_VIEW_TOP_CANVAS_Y_GAP);
- adjustment = gtk_layout_get_vadjustment (GTK_LAYOUT (day_view->top_canvas));
+ adjustment = gtk_scrollable_get_vadjustment (GTK_SCROLLABLE (day_view->top_canvas));
gtk_adjustment_set_step_increment (adjustment, day_view->top_row_height);
gtk_widget_set_size_request (day_view->top_dates_canvas, -1, day_view->top_row_height - 2);
@@ -5908,7 +5908,7 @@ e_day_view_scroll (EDayView *day_view,
gdouble value;
layout = GTK_LAYOUT (day_view->main_canvas);
- adjustment = gtk_layout_get_vadjustment (layout);
+ adjustment = gtk_scrollable_get_vadjustment (GTK_SCROLLABLE (layout));
page_size = gtk_adjustment_get_page_size (adjustment);
lower = gtk_adjustment_get_lower (adjustment);
@@ -5933,7 +5933,7 @@ e_day_view_top_scroll (EDayView *day_view,
gdouble value;
layout = GTK_LAYOUT (day_view->top_canvas);
- adjustment = gtk_layout_get_vadjustment (layout);
+ adjustment = gtk_scrollable_get_vadjustment (GTK_SCROLLABLE (layout));
page_size = gtk_adjustment_get_page_size (adjustment);
lower = gtk_adjustment_get_lower (adjustment);
@@ -5958,7 +5958,7 @@ e_day_view_ensure_rows_visible (EDayView *day_view,
gdouble value;
layout = GTK_LAYOUT (day_view->main_canvas);
- adjustment = gtk_layout_get_vadjustment (layout);
+ adjustment = gtk_scrollable_get_vadjustment (GTK_SCROLLABLE (layout));
value = gtk_adjustment_get_value (adjustment);
page_size = gtk_adjustment_get_page_size (adjustment);
@@ -6619,7 +6619,7 @@ e_day_view_on_editing_started (EDayView *day_view,
GtkAdjustment *adjustment;
layout = GTK_LAYOUT (day_view->top_canvas);
- adjustment = gtk_layout_get_vadjustment (layout);
+ adjustment = gtk_scrollable_get_vadjustment (GTK_SCROLLABLE (layout));
/* and ensure it's visible too */
/*item_y = (event_num * (day_view->top_row_height + 1)) - 1;*/
@@ -6974,7 +6974,7 @@ e_day_view_auto_scroll_handler (gpointer data)
&scroll_x, &scroll_y);
layout = GTK_LAYOUT (day_view->main_canvas);
- adjustment = gtk_layout_get_vadjustment (layout);
+ adjustment = gtk_scrollable_get_vadjustment (GTK_SCROLLABLE (layout));
step_increment = gtk_adjustment_get_step_increment (adjustment);
page_size = gtk_adjustment_get_page_size (adjustment);
diff --git a/calendar/gui/e-meeting-time-sel.c b/calendar/gui/e-meeting-time-sel.c
index 142927f..9107616 100644
--- a/calendar/gui/e-meeting-time-sel.c
+++ b/calendar/gui/e-meeting-time-sel.c
@@ -507,11 +507,11 @@ e_meeting_time_selector_construct (EMeetingTimeSelector * mts, EMeetingStore *em
layout = GTK_LAYOUT (mts->display_main);
- adjustment = gtk_layout_get_vadjustment (layout);
+ adjustment = gtk_scrollable_get_vadjustment (GTK_SCROLLABLE (layout));
gtk_scrolled_window_set_vadjustment (
GTK_SCROLLED_WINDOW (sw), adjustment);
- adjustment = gtk_layout_get_hadjustment (layout);
+ adjustment = gtk_scrollable_get_hadjustment (GTK_SCROLLABLE (layout));
mts->hscrollbar = gtk_hscrollbar_new (adjustment);
gtk_adjustment_set_step_increment (adjustment, mts->day_width);
gtk_table_attach (
@@ -519,7 +519,7 @@ e_meeting_time_selector_construct (EMeetingTimeSelector * mts, EMeetingStore *em
1, 4, 2, 3, GTK_EXPAND | GTK_FILL, 0, 0, 0);
gtk_widget_show (mts->hscrollbar);
- adjustment = gtk_layout_get_vadjustment (layout);
+ adjustment = gtk_scrollable_get_vadjustment (GTK_SCROLLABLE (layout));
mts->vscrollbar = gtk_vscrollbar_new (adjustment);
gtk_adjustment_set_step_increment (adjustment, mts->row_height);
gtk_table_attach (
@@ -840,11 +840,11 @@ e_meeting_time_selector_construct (EMeetingTimeSelector * mts, EMeetingStore *em
/* Connect handlers to the adjustments scroll the other items. */
layout = GTK_LAYOUT (mts->display_main);
- adjustment = gtk_layout_get_hadjustment (layout);
+ adjustment = gtk_scrollable_get_hadjustment (GTK_SCROLLABLE (layout));
g_signal_connect (
adjustment, "value_changed",
G_CALLBACK (e_meeting_time_selector_hadjustment_changed), mts);
- adjustment = gtk_layout_get_vadjustment (layout);
+ adjustment = gtk_scrollable_get_vadjustment (GTK_SCROLLABLE (layout));
g_signal_connect (
adjustment, "value_changed",
G_CALLBACK (e_meeting_time_selector_vadjustment_changed), mts);
@@ -1178,10 +1178,10 @@ style_change_idle_func (EMeetingTimeSelector *mts)
widget = mts->display_main;
- adjustment = gtk_layout_get_hadjustment (GTK_LAYOUT (widget));
+ adjustment = gtk_scrollable_get_hadjustment (GTK_SCROLLABLE (widget));
gtk_adjustment_set_step_increment (adjustment, mts->day_width);
- adjustment = gtk_layout_get_vadjustment (GTK_LAYOUT (widget));
+ adjustment = gtk_scrollable_get_vadjustment (GTK_SCROLLABLE (widget));
gtk_adjustment_set_step_increment (adjustment, mts->row_height);
g_object_unref (layout);
@@ -1259,7 +1259,7 @@ e_meeting_time_selector_hadjustment_changed (GtkAdjustment *adjustment,
gdouble value;
layout = GTK_LAYOUT (mts->display_top);
- hadjustment = gtk_layout_get_hadjustment (layout);
+ hadjustment = gtk_scrollable_get_hadjustment (GTK_SCROLLABLE (layout));
value = gtk_adjustment_get_value (adjustment);
gtk_adjustment_set_value (hadjustment, value);
diff --git a/libgnomecanvas/gnome-canvas.c b/libgnomecanvas/gnome-canvas.c
index a03cf0f..52798f6 100644
--- a/libgnomecanvas/gnome-canvas.c
+++ b/libgnomecanvas/gnome-canvas.c
@@ -1749,8 +1749,8 @@ gnome_canvas_paint_rect (GnomeCanvas *canvas,
layout = GTK_LAYOUT (canvas);
bin_window = gtk_layout_get_bin_window (layout);
- hadjustment = gtk_layout_get_hadjustment (layout);
- vadjustment = gtk_layout_get_vadjustment (layout);
+ hadjustment = gtk_scrollable_get_hadjustment (GTK_SCROLLABLE (layout));
+ vadjustment = gtk_scrollable_get_vadjustment (GTK_SCROLLABLE (layout));
hadjustment_value = gtk_adjustment_get_value (hadjustment);
vadjustment_value = gtk_adjustment_get_value (vadjustment);
@@ -2147,8 +2147,8 @@ scroll_to (GnomeCanvas *canvas, gint cx, gint cy)
gtk_widget_get_allocation (widget, &allocation);
layout = GTK_LAYOUT (canvas);
- hadjustment = gtk_layout_get_hadjustment (layout);
- vadjustment = gtk_layout_get_vadjustment (layout);
+ hadjustment = gtk_scrollable_get_hadjustment (GTK_SCROLLABLE (layout));
+ vadjustment = gtk_scrollable_get_vadjustment (GTK_SCROLLABLE (layout));
gtk_layout_get_size (layout, &layout_width, &layout_height);
canvas_width = allocation.width;
@@ -2240,8 +2240,8 @@ gnome_canvas_size_allocate (GtkWidget *widget, GtkAllocation *allocation)
(* GTK_WIDGET_CLASS (canvas_parent_class)->size_allocate) (widget, allocation);
layout = GTK_LAYOUT (widget);
- hadjustment = gtk_layout_get_hadjustment (layout);
- vadjustment = gtk_layout_get_vadjustment (layout);
+ hadjustment = gtk_scrollable_get_hadjustment (GTK_SCROLLABLE (layout));
+ vadjustment = gtk_scrollable_get_vadjustment (GTK_SCROLLABLE (layout));
/* Recenter the view, if appropriate */
@@ -2910,8 +2910,8 @@ gnome_canvas_set_scroll_region (GnomeCanvas *canvas,
g_return_if_fail (GNOME_IS_CANVAS (canvas));
layout = GTK_LAYOUT (canvas);
- hadjustment = gtk_layout_get_hadjustment (layout);
- vadjustment = gtk_layout_get_vadjustment (layout);
+ hadjustment = gtk_scrollable_get_hadjustment (GTK_SCROLLABLE (layout));
+ vadjustment = gtk_scrollable_get_vadjustment (GTK_SCROLLABLE (layout));
hadjustment_value = gtk_adjustment_get_value (hadjustment);
vadjustment_value = gtk_adjustment_get_value (vadjustment);
@@ -3001,8 +3001,8 @@ gnome_canvas_set_center_scroll_region (GnomeCanvas *canvas,
g_return_if_fail (GNOME_IS_CANVAS (canvas));
layout = GTK_LAYOUT (canvas);
- hadjustment = gtk_layout_get_hadjustment (layout);
- vadjustment = gtk_layout_get_vadjustment (layout);
+ hadjustment = gtk_scrollable_get_hadjustment (GTK_SCROLLABLE (layout));
+ vadjustment = gtk_scrollable_get_vadjustment (GTK_SCROLLABLE (layout));
hadjustment_value = gtk_adjustment_get_value (hadjustment);
vadjustment_value = gtk_adjustment_get_value (vadjustment);
@@ -3059,8 +3059,8 @@ gnome_canvas_set_pixels_per_unit (GnomeCanvas *canvas, gdouble n)
g_return_if_fail (n > GNOME_CANVAS_EPSILON);
layout = GTK_LAYOUT (canvas);
- hadjustment = gtk_layout_get_hadjustment (layout);
- vadjustment = gtk_layout_get_vadjustment (layout);
+ hadjustment = gtk_scrollable_get_hadjustment (GTK_SCROLLABLE (layout));
+ vadjustment = gtk_scrollable_get_vadjustment (GTK_SCROLLABLE (layout));
if (canvas->center_scroll_region) {
GtkAllocation allocation;
@@ -3145,12 +3145,12 @@ gnome_canvas_get_scroll_offsets (GnomeCanvas *canvas, gint *cx, gint *cy)
layout = GTK_LAYOUT (canvas);
if (cx) {
- adjustment = gtk_layout_get_hadjustment (layout);
+ adjustment = gtk_scrollable_get_hadjustment (GTK_SCROLLABLE (layout));
*cx = (gint) gtk_adjustment_get_value (adjustment);
}
if (cy) {
- adjustment = gtk_layout_get_vadjustment (layout);
+ adjustment = gtk_scrollable_get_vadjustment (GTK_SCROLLABLE (layout));
*cy = (gint) gtk_adjustment_get_value (adjustment);
}
}
@@ -3210,8 +3210,8 @@ get_visible_rect (GnomeCanvas *canvas, GdkRectangle *visible)
gtk_widget_get_allocation (GTK_WIDGET (canvas), &allocation);
layout = GTK_LAYOUT (canvas);
- hadjustment = gtk_layout_get_hadjustment (layout);
- vadjustment = gtk_layout_get_vadjustment (layout);
+ hadjustment = gtk_scrollable_get_hadjustment (GTK_SCROLLABLE (layout));
+ vadjustment = gtk_scrollable_get_vadjustment (GTK_SCROLLABLE (layout));
hadjustment_value = gtk_adjustment_get_value (hadjustment);
vadjustment_value = gtk_adjustment_get_value (vadjustment);
diff --git a/widgets/misc/e-canvas-utils.c b/widgets/misc/e-canvas-utils.c
index 8189dc1..fda5cd8 100644
--- a/widgets/misc/e-canvas-utils.c
+++ b/widgets/misc/e-canvas-utils.c
@@ -75,7 +75,7 @@ e_canvas_show_area (GnomeCanvas *canvas, gdouble x1, gdouble y1, gdouble x2, gdo
g_return_if_fail (canvas != NULL);
g_return_if_fail (GNOME_IS_CANVAS (canvas));
- h = gtk_layout_get_hadjustment (GTK_LAYOUT (canvas));
+ h = gtk_scrollable_get_hadjustment (GTK_SCROLLABLE (canvas));
page_size = gtk_adjustment_get_page_size (h);
lower = gtk_adjustment_get_lower (h);
upper = gtk_adjustment_get_upper (h);
@@ -84,7 +84,7 @@ e_canvas_show_area (GnomeCanvas *canvas, gdouble x1, gdouble y1, gdouble x2, gdo
if (dx)
gtk_adjustment_set_value (h, CLAMP (value + dx, lower, upper - page_size));
- v = gtk_layout_get_vadjustment (GTK_LAYOUT (canvas));
+ v = gtk_scrollable_get_vadjustment (GTK_SCROLLABLE (canvas));
page_size = gtk_adjustment_get_page_size (v);
lower = gtk_adjustment_get_lower (v);
upper = gtk_adjustment_get_upper (v);
@@ -119,7 +119,7 @@ e_canvas_area_shown (GnomeCanvas *canvas, gdouble x1, gdouble y1, gdouble x2, gd
g_return_val_if_fail (canvas != NULL, FALSE);
g_return_val_if_fail (GNOME_IS_CANVAS (canvas), FALSE);
- h = gtk_layout_get_hadjustment (GTK_LAYOUT (canvas));
+ h = gtk_scrollable_get_hadjustment (GTK_SCROLLABLE (canvas));
page_size = gtk_adjustment_get_page_size (h);
lower = gtk_adjustment_get_lower (h);
upper = gtk_adjustment_get_upper (h);
@@ -128,7 +128,7 @@ e_canvas_area_shown (GnomeCanvas *canvas, gdouble x1, gdouble y1, gdouble x2, gd
if (CLAMP (value + dx, lower, upper - page_size) - value != 0)
return FALSE;
- v = gtk_layout_get_vadjustment (GTK_LAYOUT (canvas));
+ v = gtk_scrollable_get_vadjustment (GTK_SCROLLABLE (canvas));
page_size = gtk_adjustment_get_page_size (v);
lower = gtk_adjustment_get_lower (v);
upper = gtk_adjustment_get_upper (v);
diff --git a/widgets/table/e-cell-combo.c b/widgets/table/e-cell-combo.c
index 6e1eb5c..503339a 100644
--- a/widgets/table/e-cell-combo.c
+++ b/widgets/table/e-cell-combo.c
@@ -426,8 +426,8 @@ e_cell_combo_get_popup_pos (ECellCombo *ecc,
/* The ETable positions don't include the grid lines, I think, so we add 1. */
*y += y1 + 1
- (gint)gtk_adjustment_get_value (
- gtk_layout_get_vadjustment (
- &((GnomeCanvas *)canvas)->layout))
+ gtk_scrollable_get_vadjustment (GTK_SCROLLABLE (
+ &((GnomeCanvas *)canvas)->layout)))
+ ((GnomeCanvas *)canvas)->zoom_yofs;
widget = gtk_scrolled_window_get_vscrollbar (popup);
diff --git a/widgets/table/e-cell-date-edit.c b/widgets/table/e-cell-date-edit.c
index 005f7a6..ef8d258 100644
--- a/widgets/table/e-cell-date-edit.c
+++ b/widgets/table/e-cell-date-edit.c
@@ -678,7 +678,7 @@ e_cell_date_edit_get_popup_pos (ECellDateEdit *ecde,
/* The ETable positions don't include the grid lines, I think, so we
add 1. */
layout = &GNOME_CANVAS (canvas)->layout;
- adjustment = gtk_layout_get_vadjustment (layout);
+ adjustment = gtk_scrollable_get_vadjustment (GTK_SCROLLABLE (layout));
value = (gint) gtk_adjustment_get_value (adjustment);
*y += y1 + 1 - value + ((GnomeCanvas *)canvas)->zoom_yofs;
diff --git a/widgets/table/e-table-field-chooser.c b/widgets/table/e-table-field-chooser.c
index f0e3ece..b7bddc4 100644
--- a/widgets/table/e-table-field-chooser.c
+++ b/widgets/table/e-table-field-chooser.c
@@ -86,8 +86,8 @@ ensure_nonzero_step_increments (ETableFieldChooser *etfc)
{
GtkAdjustment *va, *ha;
- va = gtk_layout_get_vadjustment (GTK_LAYOUT (etfc->canvas));
- ha = gtk_layout_get_hadjustment (GTK_LAYOUT (etfc->canvas));
+ va = gtk_scrollable_get_vadjustment (GTK_SCROLLABLE (etfc->canvas));
+ ha = gtk_scrollable_get_hadjustment (GTK_SCROLLABLE (etfc->canvas));
/*
it looks pretty complicated to get height of column header
diff --git a/widgets/table/e-table-header-item.c b/widgets/table/e-table-header-item.c
index 857d50c..4a52274 100644
--- a/widgets/table/e-table-header-item.c
+++ b/widgets/table/e-table-header-item.c
@@ -500,10 +500,10 @@ ethi_add_drop_marker (ETableHeaderItem *ethi, gint col, gboolean recreate)
window = gtk_widget_get_window (GTK_WIDGET (canvas));
gdk_window_get_origin (window, &rx, &ry);
- adjustment = gtk_layout_get_hadjustment (GTK_LAYOUT (canvas));
+ adjustment = gtk_scrollable_get_hadjustment (GTK_SCROLLABLE (canvas));
rx -= gtk_adjustment_get_value (adjustment);
- adjustment = gtk_layout_get_vadjustment (GTK_LAYOUT (canvas));
+ adjustment = gtk_scrollable_get_vadjustment (GTK_SCROLLABLE (canvas));
ry -= gtk_adjustment_get_value (adjustment);
gtk_window_move (
@@ -635,15 +635,15 @@ scroll_timeout (gpointer data)
layout = GTK_LAYOUT (GNOME_CANVAS_ITEM (ethi)->canvas);
- adjustment = gtk_layout_get_hadjustment (layout);
+ adjustment = gtk_scrollable_get_hadjustment (GTK_SCROLLABLE (layout));
hadjustment_value = gtk_adjustment_get_value (adjustment);
- adjustment = gtk_layout_get_vadjustment (layout);
+ adjustment = gtk_scrollable_get_vadjustment (GTK_SCROLLABLE (layout));
vadjustment_value = gtk_adjustment_get_value (adjustment);
value = hadjustment_value;
- adjustment = gtk_layout_get_hadjustment (layout);
+ adjustment = gtk_scrollable_get_hadjustment (GTK_SCROLLABLE (layout));
page_size = gtk_adjustment_get_page_size (adjustment);
lower = gtk_adjustment_get_lower (adjustment);
upper = gtk_adjustment_get_upper (adjustment);
@@ -753,10 +753,10 @@ ethi_drag_motion (GtkWidget *widget,
ethi->last_drop_context = context;
context_connect (ethi, context);
- adjustment = gtk_layout_get_hadjustment (GTK_LAYOUT (widget));
+ adjustment = gtk_scrollable_get_hadjustment (GTK_SCROLLABLE (widget));
hadjustment_value = gtk_adjustment_get_value (adjustment);
- adjustment = gtk_layout_get_vadjustment (GTK_LAYOUT (widget));
+ adjustment = gtk_scrollable_get_hadjustment (GTK_SCROLLABLE (widget));
vadjustment_value = gtk_adjustment_get_value (adjustment);
do_drag_motion (
diff --git a/widgets/table/e-table.c b/widgets/table/e-table.c
index 7a1c5a6..43dbec8 100644
--- a/widgets/table/e-table.c
+++ b/widgets/table/e-table.c
@@ -851,7 +851,7 @@ group_key_press (ETableGroup *etg, gint row, gint col, GdkEvent *event, ETable *
gdouble value;
layout = GTK_LAYOUT (et->table_canvas);
- adjustment = gtk_layout_get_vadjustment (layout);
+ adjustment = gtk_scrollable_get_vadjustment (GTK_SCROLLABLE (layout));
switch (key->keyval) {
case GDK_KEY_Page_Down:
@@ -1698,10 +1698,10 @@ et_real_construct (ETable *e_table, ETableModel *etm, ETableExtras *ete,
layout = GTK_LAYOUT (e_table->table_canvas);
- adjustment = gtk_layout_get_vadjustment (layout);
+ adjustment = gtk_scrollable_get_vadjustment (GTK_SCROLLABLE (layout));
gtk_adjustment_set_step_increment (adjustment, 20);
- adjustment = gtk_layout_get_hadjustment (layout);
+ adjustment = gtk_scrollable_get_hadjustment (GTK_SCROLLABLE (layout));
gtk_adjustment_set_step_increment (adjustment, 20);
if (!specification->no_headers) {
@@ -2487,10 +2487,10 @@ e_table_get_cell_at (ETable *table,
layout = GTK_LAYOUT (table->table_canvas);
- adjustment = gtk_layout_get_hadjustment (layout);
+ adjustment = gtk_scrollable_get_hadjustment (GTK_SCROLLABLE (layout));
x += gtk_adjustment_get_value (adjustment);
- adjustment = gtk_layout_get_vadjustment (layout);
+ adjustment = gtk_scrollable_get_vadjustment (GTK_SCROLLABLE (layout));
y += gtk_adjustment_get_value (adjustment);
e_table_group_compute_location (
@@ -2531,13 +2531,13 @@ e_table_get_cell_geometry (ETable *table,
width_return, height_return);
if (x_return && table->table_canvas) {
- adjustment = gtk_layout_get_hadjustment (layout);
+ adjustment = gtk_scrollable_get_hadjustment (GTK_SCROLLABLE (layout));
(*x_return) -= gtk_adjustment_get_value (adjustment);
}
if (y_return) {
if (table->table_canvas) {
- adjustment = gtk_layout_get_vadjustment (layout);
+ adjustment = gtk_scrollable_get_vadjustment (GTK_SCROLLABLE (layout));
(*y_return) -= gtk_adjustment_get_value (adjustment);
}
@@ -2716,11 +2716,11 @@ e_table_drag_highlight (ETable *table,
width = allocation.width;
} else {
e_table_get_cell_geometry (table, row, col, &x, &y, &width, &height);
- adjustment = gtk_layout_get_hadjustment (layout);
+ adjustment = gtk_scrollable_get_hadjustment (GTK_SCROLLABLE (layout));
x += gtk_adjustment_get_value (adjustment);
}
- adjustment = gtk_layout_get_vadjustment (layout);
+ adjustment = gtk_scrollable_get_vadjustment (GTK_SCROLLABLE (layout));
y += gtk_adjustment_get_value (adjustment);
if (table->drop_highlight == NULL) {
@@ -3050,7 +3050,7 @@ scroll_timeout (gpointer data)
layout = GTK_LAYOUT (et->table_canvas);
- adjustment = gtk_layout_get_hadjustment (layout);
+ adjustment = gtk_scrollable_get_hadjustment (GTK_SCROLLABLE (layout));
lower = gtk_adjustment_get_lower (adjustment);
upper = gtk_adjustment_get_upper (adjustment);
@@ -3061,7 +3061,7 @@ scroll_timeout (gpointer data)
gtk_adjustment_set_value (adjustment, new_h_value);
- adjustment = gtk_layout_get_vadjustment (layout);
+ adjustment = gtk_scrollable_get_vadjustment (GTK_SCROLLABLE (layout));
lower = gtk_adjustment_get_lower (adjustment);
upper = gtk_adjustment_get_upper (adjustment);
diff --git a/widgets/table/e-tree.c b/widgets/table/e-tree.c
index b411e07..4025293 100644
--- a/widgets/table/e-tree.c
+++ b/widgets/table/e-tree.c
@@ -780,7 +780,7 @@ scroll_to_cursor (ETree *e_tree)
}
layout = GTK_LAYOUT (e_tree->priv->table_canvas);
- adjustment = gtk_layout_get_vadjustment (layout);
+ adjustment = gtk_scrollable_get_vadjustment (GTK_SCROLLABLE (layout));
page_size = gtk_adjustment_get_page_size (adjustment);
lower = gtk_adjustment_get_lower (adjustment);
@@ -934,7 +934,7 @@ item_key_press (ETableItem *eti, gint row, gint col, GdkEvent *event, ETree *et)
gdouble value;
layout = GTK_LAYOUT (et->priv->table_canvas);
- adjustment = gtk_layout_get_vadjustment (layout);
+ adjustment = gtk_scrollable_get_vadjustment (GTK_SCROLLABLE (layout));
page_size = gtk_adjustment_get_page_size (adjustment);
upper = gtk_adjustment_get_upper (adjustment);
@@ -1568,10 +1568,10 @@ et_real_construct (ETree *e_tree, ETreeModel *etm, ETableExtras *ete,
layout = GTK_LAYOUT (e_tree->priv->table_canvas);
- adjustment = gtk_layout_get_vadjustment (layout);
+ adjustment = gtk_scrollable_get_vadjustment (GTK_SCROLLABLE (layout));
gtk_adjustment_set_step_increment (adjustment, 20);
- adjustment = gtk_layout_get_hadjustment (layout);
+ adjustment = gtk_scrollable_get_hadjustment (GTK_SCROLLABLE (layout));
gtk_adjustment_set_step_increment (adjustment, 20);
if (!specification->no_headers) {
@@ -2502,11 +2502,11 @@ e_tree_drag_highlight (ETree *tree,
width = allocation.width;
} else {
e_tree_get_cell_geometry (tree, row, col, &x, &y, &width, &height);
- adjustment = gtk_layout_get_hadjustment (layout);
+ adjustment = gtk_scrollable_get_hadjustment (GTK_SCROLLABLE (layout));
x += gtk_adjustment_get_value (adjustment);
}
- adjustment = gtk_layout_get_vadjustment (layout);
+ adjustment = gtk_scrollable_get_vadjustment (GTK_SCROLLABLE (layout));
y += gtk_adjustment_get_value (adjustment);
if (tree->priv->drop_highlight == NULL) {
@@ -2744,10 +2744,10 @@ e_tree_get_cell_at (ETree *tree,
layout = GTK_LAYOUT (tree->priv->table_canvas);
- adjustment = gtk_layout_get_hadjustment (layout);
+ adjustment = gtk_scrollable_get_hadjustment (GTK_SCROLLABLE (layout));
x += gtk_adjustment_get_value (adjustment);
- adjustment = gtk_layout_get_vadjustment (layout);
+ adjustment = gtk_scrollable_get_vadjustment (GTK_SCROLLABLE (layout));
y += gtk_adjustment_get_value (adjustment);
e_table_item_compute_location (
@@ -2793,12 +2793,12 @@ e_tree_get_cell_geometry (ETree *tree,
layout = GTK_LAYOUT (tree->priv->table_canvas);
if (x_return) {
- adjustment = gtk_layout_get_hadjustment (layout);
+ adjustment = gtk_scrollable_get_hadjustment (GTK_SCROLLABLE (layout));
(*x_return) -= gtk_adjustment_get_value (adjustment);
}
if (y_return) {
- adjustment = gtk_layout_get_vadjustment (layout);
+ adjustment = gtk_scrollable_get_vadjustment (GTK_SCROLLABLE (layout));
(*y_return) -= gtk_adjustment_get_value (adjustment);
}
}
@@ -2933,7 +2933,7 @@ scroll_timeout (gpointer data)
layout = GTK_LAYOUT (et->priv->table_canvas);
- adjustment = gtk_layout_get_hadjustment (layout);
+ adjustment = gtk_scrollable_get_hadjustment (GTK_SCROLLABLE (layout));
page_size = gtk_adjustment_get_page_size (adjustment);
lower = gtk_adjustment_get_lower (adjustment);
@@ -2944,7 +2944,7 @@ scroll_timeout (gpointer data)
gtk_adjustment_set_value (adjustment, new_h_value);
- adjustment = gtk_layout_get_vadjustment (layout);
+ adjustment = gtk_scrollable_get_vadjustment (GTK_SCROLLABLE (layout));
page_size = gtk_adjustment_get_page_size (adjustment);
lower = gtk_adjustment_get_lower (adjustment);
diff --git a/widgets/text/e-reflow.c b/widgets/text/e-reflow.c
index 7f891c4..87f034f 100644
--- a/widgets/text/e-reflow.c
+++ b/widgets/text/e-reflow.c
@@ -180,7 +180,7 @@ do_adjustment (gpointer user_data)
return FALSE;
layout = GTK_LAYOUT (GNOME_CANVAS_ITEM (reflow)->canvas);
- adjustment = gtk_layout_get_hadjustment (layout);
+ adjustment = gtk_scrollable_get_hadjustment (GTK_SCROLLABLE (layout));
value = gtk_adjustment_get_value (adjustment);
page_size = gtk_adjustment_get_page_size (adjustment);
@@ -254,7 +254,7 @@ incarnate (EReflow *reflow)
gdouble page_size;
layout = GTK_LAYOUT (GNOME_CANVAS_ITEM (reflow)->canvas);
- adjustment = gtk_layout_get_hadjustment (layout);
+ adjustment = gtk_scrollable_get_hadjustment (GTK_SCROLLABLE (layout));
value = gtk_adjustment_get_value (adjustment);
page_size = gtk_adjustment_get_page_size (adjustment);
@@ -758,7 +758,7 @@ e_reflow_set_property (GObject *object, guint prop_id, const GValue *value, GPar
gdouble page_size;
layout = GTK_LAYOUT (item->canvas);
- adjustment = gtk_layout_get_hadjustment (layout);
+ adjustment = gtk_scrollable_get_hadjustment (GTK_SCROLLABLE (layout));
page_size = gtk_adjustment_get_page_size (adjustment);
reflow->column_width = g_value_get_double (value);
@@ -882,7 +882,7 @@ e_reflow_realize (GnomeCanvasItem *item)
reflow->need_reflow_columns = TRUE;
e_canvas_item_request_reflow (item);
- adjustment = gtk_layout_get_hadjustment (GTK_LAYOUT (item->canvas));
+ adjustment = gtk_scrollable_get_hadjustment (GTK_SCROLLABLE (item->canvas));
#if 0
connect_set_adjustment (reflow);
@@ -1011,7 +1011,7 @@ e_reflow_event (GnomeCanvasItem *item, GdkEvent *event)
gdouble new_value;
layout = GTK_LAYOUT (item->canvas);
- adjustment = gtk_layout_get_hadjustment (layout);
+ adjustment = gtk_scrollable_get_hadjustment (GTK_SCROLLABLE (layout));
new_value = gtk_adjustment_get_value (adjustment);
new_value -= gtk_adjustment_get_step_increment (adjustment);
gtk_adjustment_set_value (adjustment, new_value);
@@ -1026,7 +1026,7 @@ e_reflow_event (GnomeCanvasItem *item, GdkEvent *event)
gdouble upper;
layout = GTK_LAYOUT (item->canvas);
- adjustment = gtk_layout_get_hadjustment (layout);
+ adjustment = gtk_scrollable_get_hadjustment (GTK_SCROLLABLE (layout));
new_value = gtk_adjustment_get_value (adjustment);
new_value += gtk_adjustment_get_step_increment (adjustment);
upper = gtk_adjustment_get_upper (adjustment);
@@ -1047,7 +1047,7 @@ e_reflow_event (GnomeCanvasItem *item, GdkEvent *event)
gdouble value;
layout = GTK_LAYOUT (item->canvas);
- adjustment = gtk_layout_get_hadjustment (layout);
+ adjustment = gtk_scrollable_get_hadjustment (GTK_SCROLLABLE (layout));
value = gtk_adjustment_get_value (adjustment);
reflow->temp_column_width = reflow->column_width +
@@ -1087,7 +1087,7 @@ e_reflow_event (GnomeCanvasItem *item, GdkEvent *event)
gdouble value;
layout = GTK_LAYOUT (item->canvas);
- adjustment = gtk_layout_get_hadjustment (layout);
+ adjustment = gtk_scrollable_get_hadjustment (GTK_SCROLLABLE (layout));
value = gtk_adjustment_get_value (adjustment);
reflow->temp_column_width = reflow->column_width +
@@ -1227,7 +1227,7 @@ e_reflow_draw (GnomeCanvasItem *item,
gint start_line;
layout = GTK_LAYOUT (item->canvas);
- adjustment = gtk_layout_get_hadjustment (layout);
+ adjustment = gtk_scrollable_get_hadjustment (GTK_SCROLLABLE (layout));
value = gtk_adjustment_get_value (adjustment);
start_line = e_reflow_pick_line (reflow, value);
@@ -1311,7 +1311,7 @@ e_reflow_update (GnomeCanvasItem *item, const cairo_matrix_t *i2c, gint flags)
gdouble value;
layout = GTK_LAYOUT (item->canvas);
- adjustment = gtk_layout_get_hadjustment (layout);
+ adjustment = gtk_scrollable_get_hadjustment (GTK_SCROLLABLE (layout));
value = gtk_adjustment_get_value (adjustment);
start_line = e_reflow_pick_line (reflow, value);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]