½ÌÄã7²½ÊµÏÖflex×Ô¶¨ÒåEvent¼°²ÎÊý´«µÝ
¡¡¡¡FlexÓ¦Óÿª·¢¹ý³ÌÖÐÈçÐèÒªÁé»îµÄÔÚ²»Í¬×é¼þ£¨ÈçAÓëB£¬¸¸Óë×Ó£©Ö®¼äÏìӦʼþ£¬´«µÝ²ÎÊýµÈ¹¦ÄÜʱ¾Í»áʹÓÃ×Ô¶¨Òåʼþ£¨Event£©»úÖÆ,ÏÂÃæÍ¨¹ýÒ»¸öÊÂÀý·ÖÆß²½,ͨ¹ý×Ô¶¨ÒåEventºÍEventDispatcherÁ½ÖÖ»úÖÆÊµÏÖʼþ½»»¥ºÍ²ÎÊý´«µÝ;
ÊÂÀýÃèÊö:¡¡ÓÐÒ»¸ö¸¸ÇדparentApp.mxml”ÓÐÁ½¸ö¶ù×Ó“comBrotherA.mxml”ºÍ"comBrotherB.mxml",ÐÂÄê½µÖÁ£¬Á½¸ö¶ù×ÓΪ±íТÐÄ·Ö±ð¸øËûÃÇÀϰִæÈë(ʼþ)Ò»±Ê¹ý½Ú·Ñ(ʼþ²ÎÊý),²¢Í¨ÖªÀϰÖÎÒ´æÇ®½øÈ¥ÁË£¬ÀϰÖÔÚÊÕµ½Á½¸ö¶ù×ÓµÄÇ®ºó»ã×ܺóͬʱ¸æËß(ʼþ)Á½¸ö¶ù×ÓÇ®ÎÒÒÑÊÕµ½×ÜÊý(ʼþ²ÎÊý)ÊǶàÉÙ...
1¡¢µÚÒ»²½£ºÒýÈë×Ô¶¨Òå×¢²áʼþ²ÎÊý´«µÝÀ©Õ¹Àà(À´×ÔÍøÂç)
package myeventhelper
{
//×Ô¶¨Òå×¢²áʼþ²ÎÊý´«µÝÀ©Õ¹Àà
public class EventArgExtend
{
public function EventArgExtend()
{
}
public static function create(f:Function,...arg):Function //¶¯Ì¬²ÎÊý´´½¨
{
var F:Boolean = false;
var _f:Function = function(e:*,..._arg)
{
_arg = arg;
if(!F)
{
F = true;
_arg.unshift(e);
}
f.apply(null,_arg);
};
return _f;
}
public static function toString():String
{
return "Class JEventDelegate";
}
}
}
2¡¢µÚ¶þ²½£º×Ô¶¨Òåʼþ´¥·¢Àࣺ
package myeventhelper
{
import flash.events.EventDispatcher;
import mx.core.UIComponent;
//×Ô¶¨Òåʼþ´¥·¢Àà
public class MyEventDispatcher extends EventDispatcher
{
private static var _instance:MyEventDispatcher;
public static const EXEC_PARENT_METHOD:String="ExecParentMethod"; //Ö´ÐÐParent·½·¨
public static function getI
Ïà¹ØÎĵµ£º
-----------------ex4_01_solution------------------Creating an event and dispatching the event object
<s:Application ...
creationComplete="employeeService.send()">
»á´¥·¢£º
<!-- Declarations ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
& ......
flex3 ÖеÄÖÐÎÄ×ÖÌåÖ»Ö§³ÖÓÐÏ޵ļ¸ÖÖ£¬ÒªÃ´Ç¶Èë×ÖÌ壬Ҫô¾ÍʹÓÃÕ⼸ÖÖ£º
Ö§³ÖһЩĬÈϵÄÓ¢ÎÄ×ÖÌå,ÈçArial¡¢Times New Roman¡¢Courier New¡¢Georgia¡¢VerdanaµÈ¡£
Ö§³ÖµÄÖÐÎÄ×ÖÌ壺ËÎÌå¡¢»ªÎÄ¿¬Ìå¡¢»ªÎÄϸºÚ¡¢»ªÎÄ·ÂËΡ¢»ªÎÄÖÐËΡ£
Flex3 Öм´Ê¹¿Í»§¶Ë×°Á˺ܶà×ÖÌ壬ÄÜʹÓõÄÒ²Ö»ÄÜÊÇÉÏÃæ¼¸ÖÖ×ÖÌ壬³ý·ÇǶÈë×ÖÌå¡£
µ«ÊÇ ......
flex repeater¿Ø¼þ×¢Òâ
Repeater ¹ËÃû˼Ò壬Repeat¾ÍÊÇÖØ¸´µÄÒâ˼£¬ Repeater ¾ÍÊÇÓÃÀ´Öظ´µÄ¿Ø¼þ
Repeater »á¸ù¾ÝÊý¾ÝÔ´ÖжÔÏóµÄ¶àÉÙÀ´²úÉú¶àÉÙ¸ö×ÓÏÉú³ÉµÄ×ÓÏîÈ«²¿ÊÇÒÔÊý×éÐÎʽ´æÔÚµÄ
<mx:Repeater id="myRepeater" dataProvider="{myArray}">
<mx:HBox> ......
1¡¢as3ebaylib
http://code.google.com/p/as3ebaylib/
2¡¢as3youtubelib
http://code.google.com/p/as3youtubelib/
3¡¢as3flickrlib
http://code.google.com/p/as3flickrlib/
4¡¢Yahoo ASTRA Flash Components
http://developer.yahoo.com/flash/astra-flash/
5¡¢facebook-as3
http://code.google.com/p/faceboo ......
1¡¢ÔÚflexÖУ¬²»ÄÜÖØÐ¶¨Òåinput()»òunput()£¬µ«ÊÇÄÜÖØÐ¶¨ÒåYY_INPUT£¬ËüÊÇflexµ÷ÓõĴÓÊäÈëÎļþÖжÁÈ¡Îı¾µÄºê¡£flex»º³åÇø£¬±»¶¨ÒåΪYY_BUFFER_STATEÀàÐÍ¡£Àý³Ìyy_create_buffer(FILE*,size0)Éú³ÉÖ¸¶¨´óСµÄflex»º³åÇø£¬Í¨³£ÊÇYY_BUF_SIZE£¬ÓÃÓÚ¶ÁÈ¡stdioFILE¡£¶Ôyy_swithc_to_buffer(flexbuf)µÄµ÷ÓøæËßɨÃè³ÌÐò¶ÁÈ¡ÏàÓ ......