a question about native.newTextField API ?

When I use  native.newTextField API, the keyboard shot out, after writing, but not hide, according to done (enter) is not valid, what is the case, the code is as follows:

nuliinput = native.newTextField( x\_m+220\*wb, y\_m, 140, 60 )   nuliinput:resizeFontToFitHeight() nuliinput.align = "left" nuliinput.inputType = "default" nuliinput.placeholder = "dog" nuliinput:setTextColor(0,0,1) nuliinput:setReturnKey("done") function nulievent( event ) local phase = event.phase  if event.phase == "began" then audio.play(inputmusic) elseif ( event.phase == "editing" ) then nuliname = event.text  elseif ( event.phase == "ended" or event.phase == "submitted" ) then nuliname = event.target.text  end return true end nuliinput:addEventListener( "userInput", nulievent )