修改系统进入文本输入状态时机
This commit is contained in:
@@ -590,6 +590,9 @@ local textBox={
|
||||
}
|
||||
function textBox:reset()
|
||||
self.ATV=0
|
||||
if not MOBILE then
|
||||
kb.setTextInput(true)
|
||||
end
|
||||
end
|
||||
function textBox:isAbove(x,y)
|
||||
return
|
||||
@@ -665,13 +668,14 @@ end
|
||||
WIDGET.active={}--Table contains all active widgets
|
||||
WIDGET.sel=nil--Selected widget
|
||||
function WIDGET.set(L)
|
||||
kb.setTextInput(false)
|
||||
WIDGET.sel=nil
|
||||
WIDGET.active=L or{}
|
||||
|
||||
--Reset all widgets
|
||||
if L then
|
||||
for _,W in next,L do
|
||||
if W.reset then W:reset()end
|
||||
for i=1,#L do
|
||||
L[i]:reset()
|
||||
end
|
||||
end
|
||||
end
|
||||
@@ -724,7 +728,7 @@ function WIDGET.press(x,y)
|
||||
end
|
||||
end
|
||||
elseif W.type=="textBox"then
|
||||
if SYSTEM=="Android"then
|
||||
if MOBILE then
|
||||
local _,y=xOy:transformPoint(0,W.y+W.h)
|
||||
kb.setTextInput(true,0,y,1,1)
|
||||
end
|
||||
|
||||
@@ -1,5 +1,10 @@
|
||||
local rnd=math.random
|
||||
local mobileHide=(SYSTEM=="Android"or SYSTEM=="iOS")and function()return true end
|
||||
local mobileHide,mobileShow
|
||||
if MOBILE then
|
||||
function mobileHide()return true end
|
||||
else
|
||||
function mobileShow()return true end
|
||||
end
|
||||
local function BACK()SCN.back()end
|
||||
local virtualkeySet={
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user