8000 Getting LWF.Bounds of a LWF.Movie immediately · Issue #144 · gree/lwf · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
Getting LWF.Bounds of a LWF.Movie immediately #144
Open
@DelSystem32

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

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0