📄 _test5watchersetuputil.as
字号:
package
{
import flash.display.Sprite;
import mx.core.IFlexModuleFactory;
import mx.binding.ArrayElementWatcher;
import mx.binding.FunctionReturnWatcher;
import mx.binding.IWatcherSetupUtil;
import mx.binding.PropertyWatcher;
import mx.binding.RepeaterComponentWatcher;
import mx.binding.RepeaterItemWatcher;
import mx.binding.XMLWatcher;
import mx.binding.Watcher;
[ExcludeClass]
[Mixin]
public class _test5WatcherSetupUtil extends Sprite
implements mx.binding.IWatcherSetupUtil
{
public function _test5WatcherSetupUtil()
{
super();
}
public static function init(fbs:IFlexModuleFactory):void
{
import test5;
(test5).watcherSetupUtil = new _test5WatcherSetupUtil();
}
public function setup(target:Object,
propertyGetter:Function,
bindings:Array,
watchers:Array):void
{
import mx.core.DeferredInstanceFromFunction;
import flash.events.EventDispatcher;
import mx.controls.TextArea;
import mx.controls.Button;
import mx.utils.UIDUtil;
import flash.events.MouseEvent;
import mx.validators.StringValidator;
import mx.core.IDeferredInstance;
import mx.core.Application;
import mx.core.ClassFactory;
import mx.validators.EmailValidator;
import mx.core.UIComponentDescriptor;
import mx.core.mx_internal;
import mx.events.PropertyChangeEvent;
import mx.controls.TextInput;
import mx.controls.Text;
import flash.events.Event;
import mx.core.IFactory;
import mx.core.IPropertyChangeNotifier;
import mx.core.DeferredInstanceFromClass;
import mx.utils.ObjectProxy;
import mx.binding.BindingManager;
import flash.events.IEventDispatcher;
var tempWatcher:mx.binding.Watcher;
// writeWatcher id=1 shouldWriteSelf=true class=flex2.compiler.as3.binding.PropertyWatcher shouldWriteChildren=true
watchers[1] = new mx.binding.PropertyWatcher("email",
{
propertyChange: true
}
);
// writeWatcherBottom id=1 shouldWriteSelf=true class=flex2.compiler.as3.binding.PropertyWatcher
// writePropertyWatcherBottom id=1 size=2
tempWatcher = watchers[1];
tempWatcher.addListener(bindings[1]);
tempWatcher.addListener(bindings[0]);
watchers[1].propertyGetter = propertyGetter;
watchers[1].updateParent(target);
bindings[0].uiComponentWatcher = 1;
bindings[0].execute();
bindings[1].uiComponentWatcher = 1;
bindings[1].execute();
}
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -