Jump to content
Search Community

Problem with LiquidArea

bruno.swf test
Moderator Tag

Recommended Posts

Hello

I'm trying to use the LiquidArea to position an object, without sizing it, but I can not.

The object is not in the correct position when I set ScaleMode.NONE, but if I set any kind of ScaleMode it aligns properly.

 

Below the code I'm using.

 

import com.greensock.layout.LiquidStage;
import com.greensock.layout.LiquidArea;
import com.greensock.layout.ScaleMode;
import com.greensock.layout.AlignMode;

var _ls:LiquidStage = new LiquidStage(this.stage, 1000, 590);
var _la:LiquidArea = new LiquidArea(this, 760, 75, 200, 200, 0x990000, 200, 200, 200, 200);
_la.preview = true;

_la.pinCorners(_ls.TOP_RIGHT, _ls.BOTTOM_RIGHT);
_la.update();
_la.attach(mc, ScaleMode.NONE, AlignMode.RIGHT, AlignMode.TOP);

_ls.update();

 

Thank you.

 

Ps.: Translated by Google Translate.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...