zoukankan      html  css  js  c++  java
  • 鼠标悬浮效果-串行效果和并行效果

    <?xml version="1.0" encoding="utf-8"?>
    <s:Application xmlns:fx="http://ns.adobe.com/mxml/2009" 
                   xmlns:s="library://ns.adobe.com/flex/spark"
                   xmlns:mx="library://ns.adobe.com/flex/mx"
                   minWidth="955" minHeight="600"
                   creationComplete="init()"
                   >
       <fx:Declarations>
           <s:Sequence id="effect" target="{boxes}">
               <s:Fade alphaFrom="{boxes.alpha}" alphaTo="1"/>
               <s:Scale scaleXTo="1" scaleXFrom="{boxes.scaleX}"
                        scaleYTo="1" scaleYFrom="{boxes.scaleY}"/>
           </s:Sequence>
       </fx:Declarations>
        <s:Group id="boxes" alpha=".2" x="20" y="20" scaleX=".5" scaleY=".5" rollOverEffect="{effect}">
            <s:Rect width="200" height="200">
                <s:fill>
                    <s:SolidColor color="black"/>
                </s:fill>
            </s:Rect>
            
        </s:Group>
    </s:Application> 
    View Code

     以上为串行效果,使用Sequence

    一下为并行效果,使用Parallel

    <?xml version="1.0" encoding="utf-8"?>
    <s:Application xmlns:fx="http://ns.adobe.com/mxml/2009" 
                   xmlns:s="library://ns.adobe.com/flex/spark"
                   xmlns:mx="library://ns.adobe.com/flex/mx"
                   minWidth="955" minHeight="600"
                   creationComplete="init()"
                   >
       <fx:Declarations>
           <s:Parallel id="effect" target="{boxes}">
               <s:Fade alphaFrom="{boxes.alpha}" alphaTo="1"/>
               <s:Scale scaleXTo="1" scaleXFrom="{boxes.scaleX}"
                        scaleYTo="1" scaleYFrom="{boxes.scaleY}"/>
           </s:Parallel>
       </fx:Declarations>
        <s:Group id="boxes" alpha=".2" x="20" y="20" scaleX=".5" scaleY=".5" rollOverEffect="{effect}">
            <s:Rect width="200" height="200">
                <s:fill>
                    <s:SolidColor color="black"/>
                </s:fill>
            </s:Rect>
            
        </s:Group>
    </s:Application> 
    View Code
    <?xml version="1.0" encoding="utf-8"?>
    <s:Application xmlns:fx="http://ns.adobe.com/mxml/2009" 
                   xmlns:s="library://ns.adobe.com/flex/spark"
                   xmlns:mx="library://ns.adobe.com/flex/mx"
                   minWidth="955" minHeight="600"
                   creationComplete="init()"
                   >
       <fx:Declarations>
           <s:Parallel id="effect" target="{boxes}">
               <s:Fade alphaFrom="{boxes.alpha}" alphaTo="1"/>
               <s:Scale scaleXTo="1" scaleXFrom="{boxes.scaleX}"
                        scaleYTo="1" scaleYFrom="{boxes.scaleY}"/>
           </s:Parallel>
       </fx:Declarations>
        <s:Group id="boxes" alpha=".2" x="20" y="20" scaleX=".5" scaleY=".5" rollOverEffect="{effect}">
            <s:Rect width="200" height="200">
                <s:fill>
                    <s:SolidColor color="black"/>
                </s:fill>
            </s:Rect>
            
        </s:Group>
    </s:Application> 
    View Code
  • 相关阅读:
    Python 正则表达式匹配两个指定字符串中间的内容
    Switch Case 和 If Else
    MYSQL LETT/RIGHT/INNER/FUll JOIN 注意事项
    MYSQL 批处理 Packet for query is too large
    Junit单元测试不支持多线程
    postman中 form-data、x-www-form-urlencoded、raw、binary的区别
    一个项目中:只能存在一个 WebMvcConfigurationSupport (添加swagger坑)
    Nginx 转发特点URL到指定服务
    基于UDP协议的程序设计
    TcpClient类与TcpListener类
  • 原文地址:https://www.cnblogs.com/zhugexiaobei/p/3244608.html
Copyright © 2011-2022 走看看