修复文本框控件new属性在清空后仍保留
This commit is contained in:
@@ -741,7 +741,6 @@ function inputBox:reset()
|
||||
end
|
||||
function inputBox:clear()
|
||||
self.value=""
|
||||
self.new=false
|
||||
end
|
||||
function inputBox:isAbove(x,y)
|
||||
return
|
||||
@@ -883,6 +882,7 @@ function textBox:press(x,y)
|
||||
if not self.fix and x>self.x+self.w-40 and y<self.y+40 then
|
||||
if self.sure>0 then
|
||||
self:clear()
|
||||
self.new=false
|
||||
self.sure=0
|
||||
else
|
||||
self.sure=60
|
||||
@@ -908,6 +908,7 @@ end
|
||||
function textBox:clear()
|
||||
self.texts={}
|
||||
self.scrollPos=0
|
||||
self.new=false
|
||||
SFX.play('fall')
|
||||
end
|
||||
function textBox:draw()
|
||||
|
||||
Reference in New Issue
Block a user