diff options
author | Anatoly Spektor <aspektor@redhat.com> | 2012-10-15 10:50:57 -0400 |
---|---|---|
committer | Arun Thondapu <arunkumar.thondapu@in.ibm.com> | 2012-10-15 23:08:35 +0530 |
commit | b76a3210e5e0d07a0578d9ae225b51140c25db20 (patch) | |
tree | 2885905801e06ffb9b66d7e7554a09b1b83df0e7 /bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/Table.java | |
parent | 90beec4af69432d76fc877e39fc80aef43f9b1ce (diff) | |
download | eclipse.platform.swt-b76a3210e5e0d07a0578d9ae225b51140c25db20.tar.gz eclipse.platform.swt-b76a3210e5e0d07a0578d9ae225b51140c25db20.tar.xz eclipse.platform.swt-b76a3210e5e0d07a0578d9ae225b51140c25db20.zip |
Use gtk_cell_renderer_get_preferred_size() for GTK+ 3
This patch replaces gtk_cell_renderer_get_size wth
gtk_cell_renderer_get_preferred_size for GTK+ 3
Diffstat (limited to 'bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/Table.java')
-rw-r--r-- | bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/Table.java | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/Table.java b/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/Table.java index f078527b24..a02b2ed3b7 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/Table.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/Table.java @@ -334,7 +334,7 @@ int calculateWidth (long /*int*/ column, long /*int*/ iter) { while (temp != 0) { long /*int*/ renderer = OS.g_list_data (temp); if (renderer != 0) { - OS.gtk_cell_renderer_get_size (renderer, handle, null, null, null, w, null); + gtk_cell_renderer_get_preferred_size (renderer, handle, w, null); width += w [0]; } temp = OS.g_list_next (temp); @@ -2590,7 +2590,7 @@ long /*int*/ rendererRenderProc (long /*int*/ cell, long /*int*/ window, long /* //send out measure before erase long /*int*/ textRenderer = getTextRenderer (columnHandle); - if (textRenderer != 0) OS.gtk_cell_renderer_get_size (textRenderer, handle, null, null, null, null, null); + if (textRenderer != 0) gtk_cell_renderer_get_preferred_size (textRenderer, handle, null, null); if (hooks (SWT.EraseItem)) { @@ -2664,8 +2664,8 @@ long /*int*/ rendererRenderProc (long /*int*/ cell, long /*int*/ window, long /* OS.gtk_tree_view_get_background_area (handle, path, columnHandle, rect); OS.gtk_tree_path_free (path); ignoreSize = true; - int [] contentX = new int [1], contentWidth = new int [1]; - OS.gtk_cell_renderer_get_size (cell, handle, null, null, null, contentWidth, null); + int [] contentX = new int [1], contentWidth = new int [1]; + gtk_cell_renderer_get_preferred_size (cell, handle, contentWidth, null); OS.gtk_tree_view_column_cell_get_position (columnHandle, cell, contentX, null); ignoreSize = false; Image image = item.getImage (columnIndex); |