summaryrefslogtreecommitdiff
path: root/wintable/main.c
diff options
context:
space:
mode:
authorPietro Gagliardi <[email protected]>2014-10-20 22:35:37 -0400
committerPietro Gagliardi <[email protected]>2014-10-20 22:35:37 -0400
commit0dd4a07456557cdba067feb8284e433e7459d72b (patch)
tree7b16da7a8c36c992e42c4b143551071f02ea8efc /wintable/main.c
parentb4695182de18881f44fde0805b79e67050856611 (diff)
Fixed click to select for the header bar.
Diffstat (limited to 'wintable/main.c')
-rw-r--r--wintable/main.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/wintable/main.c b/wintable/main.c
index de8c35c..248cf17 100644
--- a/wintable/main.c
+++ b/wintable/main.c
@@ -127,6 +127,7 @@ static void selectItem(struct table *t, WPARAM wParam, LPARAM lParam)
y = GET_Y_LPARAM(lParam);
h = rowHeight(t);
y += t->firstVisible * h;
+ y -= t->headerHeight;
y /= h;
t->selected = y;
if (t->selected >= t->count)