summaryrefslogtreecommitdiff
path: root/xmake/core/ui/program.lua
diff options
context:
space:
mode:
Diffstat (limited to 'xmake/core/ui/program.lua')
-rw-r--r--xmake/core/ui/program.lua5
1 files changed, 4 insertions, 1 deletions
diff --git a/xmake/core/ui/program.lua b/xmake/core/ui/program.lua
index d8a5664a4..765d95732 100644
--- a/xmake/core/ui/program.lua
+++ b/xmake/core/ui/program.lua
@@ -380,7 +380,7 @@ function program:_refresh_cursor()
end
-- get the cursor position
- local cursor = focused_view and focused_view:cursor() or point{0, 0}
+ local cursor = focused_view and focused_view:cursor()() or point{0, 0}
if cursor_state ~= 0 then
local v = focused_view
while v:parent() do
@@ -405,6 +405,9 @@ function program:_refresh_cursor()
-- get main window
local main_window = curses.main_window()
+ -- trace
+ log:print("cursor(%s): %s, %d", focused_view, cursor, cursor_state)
+
-- move cursor position
if cursor_state ~= 0 then
main_window:move(cursor.y, cursor.x)