summaryrefslogtreecommitdiff
path: root/buffer.c
diff options
context:
space:
mode:
Diffstat (limited to 'buffer.c')
-rw-r--r--buffer.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/buffer.c b/buffer.c
index b947b4b..008de6b 100644
--- a/buffer.c
+++ b/buffer.c
@@ -2343,8 +2343,8 @@ u32 buffer_last_rendered_line(TextBuffer *buffer) {
// returns true if the buffer "used" this event
bool buffer_handle_click(Ted *ted, TextBuffer *buffer, v2 click, u8 times) {
BufferPos buffer_pos;
- if (ted->autocomplete) {
- if (rect_contains_point(ted->autocomplete_rect, click))
+ if (ted->autocomplete.open) {
+ if (rect_contains_point(ted->autocomplete.rect, click))
return false; // don't look at clicks in the autocomplete menu
else
autocomplete_close(ted); // close autocomplete menu if user clicks outside of it