Packagecom.afcomponents.umap.styles
Classpublic class MediaStyle
InheritanceMediaStyle Inheritance Style

Specifies media display style for InfoWindow's Image Panel.



Public Properties
 PropertyDefined by
  align : Align
Specifies Align object that will be used to align the media inside container.
MediaStyle
  colorTransform : ColorTransform = null
Specifies the color transform object that should be applied to the media.
MediaStyle
  scaleMode : String = "maintainAspectRatio"
Specifies scaling mode of the media.
MediaStyle
Public Methods
 MethodDefined by
  
MediaStyle(param:Object = null)
MediaStyle contructor.
MediaStyle
  
applyTo(media:DisplayObject, size:Size):void
Applies the style to a DisplayObject.
MediaStyle
 Inherited
Creates a copy of the Style object.
Style
 Inherited
concat(param:Object):Style
Creates a clone of this Style, copies the properties from specified object and returns the new style.
Style
 Inherited
copy(object:Object):void
Copies all the properties from the specified object into the Style object.
Style
 Inherited
copyStyle(dest:Object, src:Object):void
[static] Copies all properties of one object into another.
Style
 Inherited
[static] Returns new Style object, from the source XML object.
Style
 Inherited
getXMLFromStyle(style:Style, name:String = ""):XML
[static] Returns an XML object that represents all the style's properties.
Style
 Inherited
toString():String
Returns a String that represents all the style's properties.
Style
 Inherited
toXML(afcTags:Boolean = false):XML
Abstract function.
Style
Property detail
alignproperty
public var align:Align

Specifies Align object that will be used to align the media inside container.

The default value is bottom-center alignment.

See also

colorTransformproperty 
public var colorTransform:ColorTransform = null

Specifies the color transform object that should be applied to the media.

The default value is No color transformation..

scaleModeproperty 
public var scaleMode:String = "maintainAspectRatio"

Specifies scaling mode of the media. MediaScaleMode class defines possible values for this property: EXACT_FIT, MAINTAIN_ASPECT_RATIO, or NO_SCALE

The default value is MediaScaleMode.MAINTAIN_ASPECT_RATIO.

See also

Constructor detail
MediaStyle()constructor
public function MediaStyle(param:Object = null)

MediaStyle contructor.

Creates new MediaStyle object with the default parameters. Properties defined in param object will override the default values.

By default, mdeia will be aligned middle-center with scale mode set to MAINTAIN_ASPECT_RATIO, and no color transformation applied.

Parameters
param:Object (default = null) — Object that holds all the properites of a style you wish to override upon its creation.
Method detail
applyTo()method
public function applyTo(media:DisplayObject, size:Size):void

Applies the style to a DisplayObject.

Parameters
media:DisplayObject — DisplayObject that needs to be resized & aligned.
 
size:Size — Size of the container to which we are aligning and resizing.

See also