Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Images created with MXML tags are not resized correctly #19769

Open
cy-polo opened this issue Mar 10, 2025 · 0 comments
Open

Images created with MXML tags are not resized correctly #19769

cy-polo opened this issue Mar 10, 2025 · 0 comments
Labels
A-avm2 Area: AVM2 (ActionScript 3) bug Something isn't working security-sandbox Issues related to Flash Player security sandboxes

Comments

@cy-polo
Copy link
Contributor

cy-polo commented Mar 10, 2025

Describe the bug

Currently, when creating an image in MXML, width and height are not taken into account.

This is caused by the fact that the contentHolderWith and contentHolderHeight getters in mx.controls.SWFLoader are waiting to pass into the catch.
This part is never triggered, as flash.display.Loader().content does not return an error. A security sandbox should be implemented to raise properly the error.

Here's a snippet to reproduce the bug:

<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="vertical">
    <mx:Label text="Look at my beautiful icon:" fontWeight="bold" fontSize="16"/>
    <mx:Image x="82.5" y="62" source="Favorites.png" width="30" height="30" />
</mx:Application>

Expected behavior

The image should be resized to the requested size.

Here's what's happening now:
Image

Here's the expected result:
Image

Content Location

ScalingIssue.zip

Affected platform

Self-hosted version

Operating system

macOS Sequoia 15.3.1

Browser

Mozilla Firefox 136.0

Additional information

No response

@cy-polo cy-polo added the bug Something isn't working label Mar 10, 2025
@kjarosh kjarosh added A-avm2 Area: AVM2 (ActionScript 3) security-sandbox Issues related to Flash Player security sandboxes labels Mar 10, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-avm2 Area: AVM2 (ActionScript 3) bug Something isn't working security-sandbox Issues related to Flash Player security sandboxes
Projects
None yet
Development

No branches or pull requests

2 participants