Adobe FLEX 2-MIGRATING APPLICATIONS TO FLEX 2 Manual page 133

Migrating applications to flex 2
Table of Contents

Advertisement

Change to the range of several effect properties
For the Zoom, Fade and Dissolve effects, the range of the
,
zoomHeightFrom
zoomWidthFrom
changed. You used to set these values as percentages using integer values, where 0
corresponded to 0%, and 100 to 100%. You now specify them as decimal values, where 0.0
corresponded to 0%, and to 1.0 corresponded to 100%.
Flex 1.5:
<mx:Effect>
<mx:Zoom name="big" zoomTo="105" duration="100"/>
<mx:Zoom name="small" zoomTo="100" duration="100"/>
</mx:Effect>
Flex 2:
<mx:Zoom id="big" zoomHeightTo="1.05" zoomWidthTo="1.05"duration="100"/>
<mx:Zoom id="small" zoomHeightTo="1.0" zoomWidthTo="1.0" duration="100"/>
Using the setStyle() method to set effects
The return value to the
trigger properties for behaviors are implemented as styles, you can use the
methods to manipulate triggers and their associated effects. The
getStyle()
method has the following signature:
setStyle("trigger_name", effect)
where:
String indicating the name of the trigger property; for example,
trigger_name
or
mouseDownEffect
The effect associated with the trigger. The data type of
effect
the name of the effect, an Effect object, or an object of a subclass of the Effect class.
The
method has the following signature:
getStyle()
return_type getStyle("trigger_name")
where:
String indicating the name of the trigger property.
trigger_name
An Effect object, or an object of a subclass of the Effect class.
return_type
For detailed information, see Chapter 17, "Using Behaviors," in the Flex 2 Developer's Guide.
,
zoomHeightTo
method has changed when used with a behavior. Because
getStyle()
.
focusInEffect
,
alpha
scaleX
, and
properties have
zoomWidthTo
is a String containing
effect
New Behaviors syntax
,
,
scaleY
and
setStyle()
setStyle()
133

Advertisement

Table of Contents
loading

This manual is also suitable for:

Flex 2

Table of Contents