Skip to content

Getting LWF.Bounds of a LWF.Movie immediately #144

Description

@DelSystem32

Right now it seems like the only way to get the bounds of a LWF.Movie is to do this:

private LWF.Bounds theBounds;
private void BoundsFetcher(LWF.Movie m) {
    theBounds = m.GetBounds();
}
public LWF.Bounds GetBounds (string mcInstanceName = null) {
    lwf.SearchMovieInstance ("instancename").RequestCalculateBounds(BoundsFetcher);
    lwf.Exec (-1);
    return theBounds;
}

However this means you have to update the flash once. Is there a better way to do it, without using RequestCalculateBounds()?

Or using RequestCalculateBounds() but not having to call Exec(-1)?

Edit: Changed the incorrect 0 to the correct -1.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions