summaryrefslogtreecommitdiff
path: root/xmake/core/ui/textarea.lua
diff options
context:
space:
mode:
authorruki <[email protected]>2018-01-18 23:14:40 +0800
committerruki <[email protected]>2018-01-18 13:28:01 +0800
commit7d42cff795e9600a837fc0e595baa4d76ac0838e (patch)
tree2204f7beacf64ecdb488daea5dfa831ccad3303a /xmake/core/ui/textarea.lua
parentc4bdc1b82cc058e29eb3dc9ad335fdc6333e465e (diff)
add textedit
Diffstat (limited to 'xmake/core/ui/textarea.lua')
-rw-r--r--xmake/core/ui/textarea.lua5
1 files changed, 4 insertions, 1 deletions
diff --git a/xmake/core/ui/textarea.lua b/xmake/core/ui/textarea.lua
index fe9f6c083..4ef3bd878 100644
--- a/xmake/core/ui/textarea.lua
+++ b/xmake/core/ui/textarea.lua
@@ -83,14 +83,17 @@ function textarea:event_on(e)
if self._STARTLINE < 0 then
self._STARTLINE = 0
end
+ self:invalidate()
+ return true
elseif e.key_name == "Down" then
self._STARTLINE = self._STARTLINE + 5
if self._LINECOUNT - self._STARTLINE < self:height() then
self._STARTLINE = self._LINECOUNT - self:height()
end
+ self:invalidate()
+ return true
end
end
- self:invalidate()
end
-- return module