diff options
author | David Robillard <d@drobilla.net> | 2014-03-15 22:35:18 +0000 |
---|---|---|
committer | David Robillard <d@drobilla.net> | 2014-03-15 22:35:18 +0000 |
commit | 3b63d9fa3114f0292561484f299d9d45ec451c17 (patch) | |
tree | b45de3ba8d2eded5731908cf6842b4bb6392863f /src/group.c | |
parent | ba34221e0ee4c32ced4770563638f472860e0a16 (diff) | |
download | ganv-3b63d9fa3114f0292561484f299d9d45ec451c17.tar.gz ganv-3b63d9fa3114f0292561484f299d9d45ec451c17.tar.bz2 ganv-3b63d9fa3114f0292561484f299d9d45ec451c17.zip |
Clean up public canvas interface.
Eliminate thin C wrappers around C++ methods (move actual implementation into C).
git-svn-id: http://svn.drobilla.net/lad/trunk/ganv@5338 a436a847-0d15-0410-975c-d299462d15a1
Diffstat (limited to 'src/group.c')
-rw-r--r-- | src/group.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/group.c b/src/group.c index 58f5007..607adcf 100644 --- a/src/group.c +++ b/src/group.c @@ -242,10 +242,10 @@ ganv_group_point(GanvItem* item, double x, double y, int cx, int cy, group = GANV_GROUP(item); - x1 = cx - item->canvas->close_enough; - y1 = cy - item->canvas->close_enough; - x2 = cx + item->canvas->close_enough; - y2 = cy + item->canvas->close_enough; + x1 = cx - GANV_CLOSE_ENOUGH; + y1 = cy - GANV_CLOSE_ENOUGH; + x2 = cx + GANV_CLOSE_ENOUGH; + y2 = cy + GANV_CLOSE_ENOUGH; best = 0.0; *actual_item = NULL; @@ -278,8 +278,8 @@ ganv_group_point(GanvItem* item, double x, double y, int cx, int cy, if (has_point && point_item - && ((int)(dist * item->canvas->pixels_per_unit + 0.5) - <= item->canvas->close_enough)) { + && ((int)(dist * ganv_canvas_get_zoom(item->canvas) + 0.5) + <= GANV_CLOSE_ENOUGH)) { best = dist; *actual_item = point_item; } |