summaryrefslogtreecommitdiff
path: root/xmake/core/ui/boxdialog.lua
diff options
context:
space:
mode:
authorruki <[email protected]>2018-01-13 00:37:36 +0800
committerruki <[email protected]>2018-01-12 21:45:36 +0800
commit788f52e46e4333be8522f80cd033eba206fda3ff (patch)
treeac4db1a6452e489f817ae3a37b280840e916b8c9 /xmake/core/ui/boxdialog.lua
parentbcb58d536cb131be4358d8893cfd1db77f72d942 (diff)
add resize state
Diffstat (limited to 'xmake/core/ui/boxdialog.lua')
-rw-r--r--xmake/core/ui/boxdialog.lua6
1 files changed, 3 insertions, 3 deletions
diff --git a/xmake/core/ui/boxdialog.lua b/xmake/core/ui/boxdialog.lua
index 74b32b685..d46b2ed09 100644
--- a/xmake/core/ui/boxdialog.lua
+++ b/xmake/core/ui/boxdialog.lua
@@ -41,14 +41,14 @@ function boxdialog:init(name, bounds, title)
-- insert box
self:panel():insert(self:box())
- -- resize text bounds
- self:text():bounds():resize(self:panel():width(), math.floor(self:panel():height() / 4))
+ -- resize text
+ self:text():bounds().ey = 3
end
-- get box
function boxdialog:box()
if not self._BOX then
- self._BOX = window:new("boxdialog.box", rect{0, math.floor(self:panel():height() / 4), self:panel():width(), self:panel():height() - 1})
+ self._BOX = window:new("boxdialog.box", rect{0, 3, self:panel():width(), self:panel():height() - 1})
self._BOX:border():cornerattr_set("black", "white")
end
return self._BOX