Flex Accordion headerRendererʵÏÖchildÊÕËõ
ÓÃAccordion×é¼þµÄʱºò·¢ÏÖ,childÕ¹¿ªÖ®ºóÔÙµã»÷µÄʱºòûÓÐÏàÓ¦.
È»ºóϰ¹ßÐÔµÄGoogle·¢ÏÖ½â¾ö·½·¨´óÖÂÊÇ×Ô¶¨ÒåÒ»¸ö×é¼þ...
¸Ð¾õΪÁËÒ»¸öС¹¦ÄÜÖØÐ´Óеã ɱ¼¦ÓÃÅ£µ¶µÄ¸Ð¾õ.
ÓÚÊÇ×ÐϸÏëÁËÏÂ,·¢ÏÖÆäʵֻÐèÒªÖ¸¶¨headerµÄitemRenderer¼´¿É:
ÉÏ´úÂë headerRenderer="com.MyAccHeader"
MyAccHeader:
package com
{
import flash.events.MouseEvent;
import mx.controls.Alert;
import mx.containers.Accordion;
import mx.containers.accordionClasses.AccordionHeader;
public class MyAccHeader extends AccordionHeader
{
public function MyAccHeader()
{
super();
this.addEventListener(MouseEvent.CLICK,fun);
}
private function fun(evt:MouseEvent):void
{
(this.parent as Accordion).selectedIndex = (this.parent as Accordion).selectedIndex+1;
}
}
}
Ïà¹ØÎĵµ£º
·þÎñÆ÷¶Ë´úÂë,amfphpµÄservicesĿ¼Ï½¨Á¢readData.phpÎļþ,´úÂëÈçÏÂ
<?php
class ReadDB
{
function getData()
&nb ......
ÕâÀï·ÖÁ½ÖÖÇé¿ö£¬Ò»ÖÖÊÇÊý¾ÝÔ´ÔÚMXMLÎļþÖУ¬È磺
<mx:XML id="treeXML"
format="e4x">
<root>
<node label="֪ͨͨ¸æ¹ÜÀí"
data="0">
......
1£¬½¨Ò»¸öuserdb¿â£¬ÔÙ½¨userinfo±í£¬×ֶΣºid(int),username(varchar),password(varchar)¡£
2£¬DBConnection.java
package com.datainfo;
import java.sql.Connection;
import java.sql.DriverManager;
import java.sql.SQ ......
1.ǰ¶ËflexµÄ¶ÔÏóºÍjava¶ËµÄ¶ÔÏóÃû×ÖÒªÒ»Ö£¬java¶ËµÄ¶ÔÏó±ØÐëÐòÁл¯£¬·ñÔòÎÞ·¨±»flex¶Ëµ÷ÓÃת»¯
javaºǫ́´«»ØµÄlistÀï±ßµÄ¶ÔÏ󣬱ØÐëflex¶ËÒ²Óд˶ÔÏ󣬶øÇÒÁ½¸ö¶ÔÏóµÄÊôÐÔÒªÒ»Ö£¬·ñÔò£¬²»Äܻص÷
2.»Øµ÷º¯Êý²»Æð×÷Óã¬ÓпÉÄÜÊÇÒòΪ»Øµ÷º¯ÊýÃû×ÖÒýÆðµÄ
flex´Ójava¶ËÈ¡¶à¸ölist·â×°µÄ¶ÔÏóʱ£¬¶Ô¸÷¸ödatagridÒªÓÃÊý¾Ý° ......
flexÖб³¾°Í¼Æ¬Æ½ÆÌ
ÎÒÃÇÐèÒªÒ»¸ö degrafa µÄ×é¼þ
ÒѾÉÏ´«ºÃÁË.
È»ºó°ÑÏÂÔØµÄswc·Åµ½ÏîÄ¿µÄlibsÖÐ
ÔÚÒ³ÃæcssÖÖÕâÑùд¾Í¿ÉÒÔÁË
Application {
background-image: Embed("assets/images/the_image_goes_here.png");
background-r ......