From ee42be45e376e9be700247aefdea61f9d4bd4ff7 Mon Sep 17 00:00:00 2001 From: Jean-Philippe Orsini Date: Sun, 8 May 2011 14:54:04 +0000 Subject: [PATCH] gtk3 support --- src/ui_sensorlist.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/ui_sensorlist.c b/src/ui_sensorlist.c index af830ae..53235fb 100644 --- a/src/ui_sensorlist.c +++ b/src/ui_sensorlist.c @@ -129,10 +129,11 @@ static int get_col_index_at_pos(GtkTreeView *view, int x) for (node = columns; node; node = node->next) { GtkTreeViewColumn *checkcol = (GtkTreeViewColumn *) node->data; - if (x >= colx && x < (colx + checkcol->width)) + if (x >= colx && + x < (colx + gtk_tree_view_column_get_width(checkcol))) return coli; else - colx += checkcol->width; + colx += gtk_tree_view_column_get_width(checkcol); coli++; } -- 2.7.4