FLEX实践—默认弹出窗口
本例中将实现当应用运行时不进行任何操作就先弹出窗口,点击关闭/点击窗口任一位置 时将关闭窗口
1)创建Component—DefaultWin.mxml (目录结构src/components/DefaultWin.mxml)
<?xml version="1.0" encoding="utf-8"?>
<mx:TitleWindow xmlns:mx="http://www.adobe.com/2006/mxml"
click="{this.visible=false}"
showCloseButton="true"
close="{this.visible=false}"
width="450"
height="253"
borderAlpha="0.8"
fontWeight="normal"
headerHeight="20"
borderColor="#EED9FB"
backgroundColor="#070707"
color="#FFFFFF"
cornerRadius="8"
creationComplete="init()">
<mx:Script>
<![CDATA[
private function init():void
{
move_up.yfrom=can.height - 6;
move_up.yTo=0 - content.height + 6;
move_up.repeatCount=0; //loop
move_up.repeatDelay=0; //loop time
move_up.duration=6000; //the time of scroll once
move_up.play();
}
private function move_pause():void
{
move_up.pause(); //pause
}
private function move_resume():void
{
move_up.resume(); //start from the pause position
}
]]>
</mx:Script>
<mx:Move id="move_up"
target="{content}"/>
<mx:VBox width="100%"
height="100%"
horizontalAlign="center">
<mx:HBox width="100%"
&n
相关文档:
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="horizontal">
<mx:Panel width="458" height="313" layout="absolute">
<mx:Label id="lbl" x="19" y="10" text="" width="171" height="20"/>
<mx:DataGrid id="dg" x="19" y="58" dataProvider="{arr}" editable="true" ......
Flex Builder 3.0正式版:
http://download.macromedia.com/pub/flex/flex_builder/FB3_win.exe
或
http://www.adobe.com/cfusion/tdrc/index.cfm?product=flex
或
http://trials.adobe.com/Applications/Flex/FlexBuilder/3/FB3_WWEJ_Plugin.exe
AIR1.0 正式版:
http://airdownload.adobe.com/air ... ob ......
自定义类(BroadCastMarquee.as):
package marquee
{
import flash.events.MouseEvent;
import flash.events.TimerEvent;
import flash.geom.Rectangle;
import flash.text.TextField;
import flash.text.TextFiel ......
flash和flex针对不同的目的,提供了3种不同的坐标系。
全局的就是(stage级别的)
本地坐标系(组件级别的)
内容坐标系(相对于本地坐标系说的 ......
用FLEX来开发应用难免不了要使用到Module,FLEX组件提供了ModuleLoader组件,该组件使用方式类似与swfLoader,但是通常仅仅使用该组件并不能满足我们的需求,这时FLEX为我们提供了ModuleManager,可以实现动态的载入不同的模块。
module分为两种,一种是完整的,一种是关联到主程序的,在新建Module时可以选择module swf s ......