Skip to content

Commit efcac2d

Browse files
committed
Callback functions improved on Hins
1 parent 7c116af commit efcac2d

File tree

2 files changed

+9
-3
lines changed

2 files changed

+9
-3
lines changed

popForm/Hints.as

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -177,7 +177,9 @@
177177
{
178178
if(_onClose!=null)
179179
{
180-
_onClose.call();
180+
var cahsedhCloseFunc:Function = _onClose ;
181+
_onClose = null ;
182+
cahsedhCloseFunc();
181183
}
182184
}
183185

popForm/PopField.as

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -234,9 +234,10 @@
234234
}
235235
}
236236

237-
public function onEdited(func:Function):void
237+
public function onEdited(func:Function):PopField
238238
{
239239
onEditedFunc = func ;
240+
return this ;
240241
}
241242

242243
public function setUp(tagName:String,defaultText:String,KeyBordType:String = SoftKeyboardType.DEFAULT,isPass:Boolean = false,editable:Boolean = true,isAraic:Boolean=true,numLines:uint = 1,color:uint=1,frame:uint=1,maxChar:uint=0,otherOptions:Array=null,deleteDefautlText:Boolean=false,activateRadioSwitcher:Boolean=false,returnKey:String=ReturnKeyLabel.DEFAULT,onTypedFunction:Function=null,justShowNativeText:Boolean=false,multiLineTag:Boolean=false,justify:Boolean=true,selectAllCharchter:Boolean=false):PopField
@@ -505,7 +506,10 @@
505506
private function callOnEditedFunc():void
506507
{
507508
clearTimeout(onEditeFuncCalDelay);
508-
onEditeFuncCalDelay = setTimeout(callOnEditedNow,100);
509+
if(onEditedFunc!=null)
510+
{
511+
onEditeFuncCalDelay = setTimeout(callOnEditedNow,100);
512+
}
509513
}
510514
private function callOnEditedNow():void
511515
{

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy