gtk3 support
authorJean-Philippe Orsini <jeanfi@gmail.com>
Sun, 8 May 2011 14:54:04 +0000 (14:54 +0000)
committerJean-Philippe Orsini <jeanfi@gmail.com>
Sun, 8 May 2011 14:54:04 +0000 (14:54 +0000)
src/ui_sensorlist.c

index af830ae..53235fb 100644 (file)
@@ -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++;
        }