Actionscript 3 :: Flex - Impossible To Resize The External Loaded SWF's Content?

May 11, 2011

I have an application where I try to load an external SWF. So, we have:My application: The Stage's dimensions are 768x1280. ScaleMode = EXACT_FIT. External SWF: It's another application where its stage is: 800x600. ScaleMode = EXACT_FIT.The problem is that the external SWF does not modify its size although I apply "scaleX, scaleY", change its width and so on.I also tried to insert it into a Canvas container (as "How to resize an external SWF to fit into a container?" ) but it didn't solve my problem.The interesting piece of code is when the external SWF is loaded by my application:

private function onLoadedApp( evt:Event ):void{
stage.scaleMode = StageScaleMode.EXACT_FIT;
trace("Loading Application..");

[code].....

View 2 Replies


Similar Posts:


Flex :: Impossible To Resize External Loaded SWF Content

May 11, 2011

I have an application where I try to load an external SWF. So, we have:
My application: The Stage's dimensions are 768x1280. ScaleMode = EXACT_FIT.
External SWF: It's another application where its stage is: 800x600. ScaleMode = EXACT_FIT.

The problem is that the external SWF does not modify its size although I apply "scaleX, scaleY", change its width and so on. I also tried to insert it into a Canvas container (as "How to resize an external SWF to fit into a container?" ) but it didn't solve my problem.

The interesting piece of code is when the external SWF is loaded by my application:
private function onLoadedApp( evt:Event ):void{
stage.scaleMode = StageScaleMode.EXACT_FIT;
trace("Loading Application..");
var loaderInfo:LoaderInfo = evt.target as LoaderInfo;
loaderInfo.removeEventListener( Event.COMPLETE, onLoadedApp);
[Code] .....

I also tried to do it through SWFLoader, but the external.swf's content doesn't change its original size although I add the "scaleContent" parameter.

Visual results I got:
The external SWF is loaded on the suitable position and it "seems" to have 320x240 dim. But its width is a bit cropped, since if I stretch the Flash Player I achieve to see the rest of the external swf's stage. Besides, the external SWF never is resized although I shrink/stretch the Flash Player. It always remains fixed (if I trace its dimensions, I always get 800x600, although I visually see 320x240)- If I increase the stage's width of the main application, this little clip disappear.

I know the original Stage's dimensions are 800, and this is greater than the original stage of my application (768), but I think, when I do the resizing, external SWF's Stage have to be fitted in the container. It is fitted, but a part of the external SWF is not seen. It's like Flash Player remembered that the external SWF Stage's width were greater than my application's one...

View 2 Replies

Flex :: Alternatives To Create Swf Files (which Has External Content Loaded Into Them) Dynamically?

Jul 2, 2009

I'm about to start a project where there will be a Flash application where the visitor customizes a profile with externally loaded images and texts. Then the visitor needs to be able to download that profile as a dynamically created swf with all that external content baked into the swf.

View 2 Replies

ActionScript 3.0 :: Impossible To Instantiate A Loaded .png Image

Mar 16, 2011

No matter how much I try, nothing works.

1. Moving a loader instance to a movieclip containter returns a coercion error.

2. Moving the loaded image object to a MC container does not produce any errors, but remains as a bitmap object.

3. bitmapdata.draw() method seems to require either a bitmap or bitmapdata destination object.

View 7 Replies

Flex :: Have A Mx:Window Automatically Resize To Its Content?

Mar 17, 2010

I'm creating windows in a Flex application (AIR) using the mx:Window component. I'd like the window to be automatically sized to its content (because it will be dynamic), in the same way that an mx:Panel or mx:Box would be.I've customized components before, so I'm somewhat familiar with the UIComponent lifecycle, but I'm not quite sure how best to do the logic for auto-sizing a container.If it makes it easier, I'm not expecting that the window auto-size to its content at any time, thought that would be a bonus!

View 1 Replies

ActionScript 3.0 :: Resize External Images Loaded Into UiLoader?

Aug 18, 2011

Please help I've been researching this topic for like 2 days straight and it is driving me insane because I can't seem to find a specific answer for what I'm trying to achieve and I know it can be done because I've seen end results on the web. Here is what I'm doing:

1. I created a simple museum gallery with 3 portraits hanging on the wall
2. Inside the museum portraits I created 3 different uiLoaders with a black background
3. I gave all 3 uiLoaders their own unique movieClip names
3. Inside each uiLoader will be a loaded external image via a URL
4. I DO NOT want to resize the uiLoaders - I want to scale the external images proportionately to fit inside the entire contents of the uiLoaders and still remain centered

URL...As you can see currently the 3 random external images are loaded perfectly inside the uiLoaders but you see black background and I want the photos to fit the entire contents of the uiLoaders yet still remain proportionate.[code]

View 6 Replies

Flex :: Automaticaly Resize The Button Based On Content?

May 3, 2010

I would like to automaticaly resize my button (spark button) according it content (label text) ?

View 3 Replies

Flex :: Automatically Resize Width Of DataGridCoulmn To Fit Content

May 21, 2010

I want that the DataGridColumn or AdvancedDataGridColumn would automatically resize it's width so as to fit the content within. I'm new to flex. I want to implement something like HTML tables. The Data Rendered is simple Text. Some Rows have little longer Text, in that case I would like to automatically extend the width of DataGridColumn.

View 3 Replies

ActionScript 3.0 :: External Swf Could Not Use Loaded Content

Aug 23, 2010

I have main preloader that loading external swf into it. external swf call method load picture from url. when event complete picture does not appear. but if external swf is the main swf it will appear nomally. I tried to use init but it still not working When I debug loader.contentLoaderInfo.content that call from external is gone.

View 1 Replies

Flex :: 3 - Auto-sizing - Automatically Resize To Fit The Length Of The Content And Positioning

Jan 4, 2010

I am working on a flex app that uses XML templates to dynamically create DisplayObjects. These templates define different layouts that can be used for each page of content in the app (ie , 2 columns, 3 columns etc etc). The administrator can select from one of these and populate each area with their content.

The templates add one of 3 types of DisplayObject - HBox, VBox or a third component - LibraryContentContainer (an mxml component that is defined as part of the app) - which is effectively a canvas element with a TextArea inside. The problem that I am getting is that I need each of these areas to automatically resize to fit the length of the content but don't seem to be able to find an effective way to do so.

In the LibraryContentContainer, when the value of the TextArea is set, I am calling .validateNow() on the LibraryContentContainer. I then set the height property on both the TextArea and LibraryContentContainer to match the textHeight property of the TextArea. In the following example, this is the LibraryContentContainer, viewer is the TextArea and the value property of the TextArea is bound to this.__Value. v is the variable containing the content for the textarea

[Code]...

View 1 Replies

ActionScript 2.0 :: Resize Stage To Dynamically Match External Movieclip Loaded Into Empty?

Nov 15, 2004

Does anyone know how I can resize the stage to match the size of an external graphic/movieclip which is loaded into an empty movieclip

View 3 Replies

Flex :: Resize Loaded SWF To Fit In Canvas

Jul 29, 2009

a .fla is 500 x 300. Inside, content moves OUT of the 500 x 300 stage so that it appears like it hides or moves off of the screen. .fla complied... loaded into Flex via SWFLoader:

<mx:Conainer width="500" height="300">
<mx:SWFLoader width="100%" height="100%" />
</mx:Conainer>

Loaded .swf file shows outside of the 500 x 300 Container in Flex. How can i get it so that only what is INSIDE of the Container is visible?

View 3 Replies

Flex :: Resize Layout After A Loaded Image Gets Resized?

Jun 2, 2011

So I'm loading a really big pic in this mx:Image manteinAspectRatio enabled with a height constraint and as usual it doesn't work (Flex is definitely not for me):

<?xml version="1.0" encoding="utf-8"?>
<s:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:s="library://ns.adobe.com/flex/spark"

[code].....

View 1 Replies

ActionScript 2.0 :: Resize Stage To Dynamically Match External Movieclip Loaded Into Empty Movieclip?

Nov 15, 2004

know how I can resize the stage to match the size of an external graphic/movieclip which is loaded into an empty movieclip,

View 3 Replies

ActionScript 2.0 :: If Resize The Window Before The Swf Is Loaded - It Misaligns Until Resize

Jan 4, 2009

I have a main movie here that loads in an external swf through a container mc. everything is aligned and positioned to where it should be, and they are also set to that value onresize. the problem is, when my swf is loaded in, it works fine and is in the right position, same when you resize it. BUT, if you resize the window before the swf is loaded, it misaligns, until you resize!!

View 2 Replies

ActionScript 2.0 :: Resize External Loaded Movie To Main Movie

Jan 9, 2010

my problem is that i need to make a reisze, cause the screen resolution for other users. My main and news movie works perfect, but the others movies re-scale everything bigger. The problem of the external loaded movie is: this movie needs the funktion:

Stage.scaleMode = "noScale";
Stage.align = "TL";

If i dont have this code inside the movie is not going to resize fullscreen into the main movie. Inside this movie im scalling photos and some mc's You can take a look what i mean under: [URL]

If you take a look to the bar where the Number of pictures (30) are you will see that the lower bar and the pictures is not going to scale to fill the full screen if i delete the this code;

Stage.scaleMode = "noScale";
Stage.align = "TL";

View 3 Replies

Flex :: Air HTMLLoader Blank Pop Up Window When Flash Content Is Loaded?

Jun 25, 2009

I have a flex Air program that loads external content with the HTMLLoader.Now for some reason whenever I load a page that has any flash content a blank system window pops up outside of my program. It's completely blank, all white with min, max and close buttons.If I close it any flash content I loaded stops working. For the life of my I can't figure out what's happening and there's no messages in the console and no title for the window.

private var webPage:HTMLLoader;
private function registerEvents():void
{

[code]......

View 3 Replies

Flex :: FLVPlayback Component Freezes When Seeking Beyond Loaded Content?

Mar 12, 2010

I'm creating a flex-based video player, using the FLVPlayback component (imported from Flash Pro CS3). I've reskinned all of the player controls and linked them in, and it's all working really well...However, if you try to seek beyond the point where the video has loaded (it's using progressive download), the video completely freezes. You can no longer pause, play, seek to somewhere else, or anything. I understand it can't actually play a point in the video that hasn't been downloaded, but the whole thing seems to just become unresponsive

View 1 Replies

ActionScript 3.0 :: Flex - How To Remove / Disable Link From Loaded SWF Content

Dec 4, 2009

How to remove/disable link from loaded swf content? In flex I have an image component, which loads swf through "source". This loaded swf contains "clickable" links. I want to this loaded swf a simple image behave.

View 2 Replies

Flex :: Accessing Content From External Illustrator SWF

Jul 12, 2011

I have problem accessing content from an Illustrator SWF(I create the swf using illustrator, I export I Save layers as symbols). When I create my swf file using flash i can access shapes and symbols using this code. I am trying to get and change the color of a symbols in my swf file.
var flashMovie:Sprite = this.content as Sprite;
for (var i:int = 0; i < flashMovie.numChildren; i++) {
flashMovie.getChildAt(i).name;
flashMovie.getChildAt(i).transform.colorTransform.color;
}
But when I create my swf file using Illustrator it return nothing. How can can I access the content and change the color of an Illustrator SWF

View 1 Replies

ActionScript 3.0 :: Remove The Loader But Its Content Still Playing I Know That From The Sound Of The Content Was Loaded?

Apr 20, 2009

How to remove a loader and its content using removeChild or any other way, I had removed the loader but its content still playing in the background i know that from the sound of the content.this is the my code for removing:

removeChild(getChildByName("SampleLoader"));

View 9 Replies

ActionScript 3.0 :: Flash - Loading External Content On Top Of Main Content?

Jan 28, 2011

I'm loading one SWF into another but the internal one is coming over the main content and that can't happen.here is the part of my code where the external content is being loaded anyone hason what I can do to fix this? here is my code:

Code:
var loadAnimBox:Loader = new Loader();
var vid_mc:MovieClip;

[code].....

View 2 Replies

IDE :: Content Box Resize Effect Name?

Aug 9, 2009

i am trying to find a tutorial or even the name of a very common flash effect.The effect involves a button being pressed and a box growing and content being loaded into it. Then when another button is pressed the box changes shape and different content is loaded.

My friend did give this effect a name but for the life of me I cant remember it.

View 1 Replies

ActionScript 2.0 :: How To Resize With Content

Mar 22, 2005

I have a problem! I'm trying to make a resize effect with actionscript, it all work fine but the problem is that the contents should follow the resize.. example bottons, text and so on... If you know what I mean

View 9 Replies

Flex :: Flex 3 Resize The Label And Text When Resize The Window?

May 11, 2010

i am creating flex 3 component when i re size the window i need to re size the labels and text.how to do this?

View 1 Replies

ActionScript 3.0 :: Resize Container's Content To Fit?

Apr 14, 2011

I have a stage with Top, Middle & Bottom Movieclip's set on it. On resize the content is scaled to fit and maintain the correct proportions.I am loading each content (page) in as external SWF files into the Middle container using a Loader and URLRequest.Here is my onCompleteHandler function:

Actionscript Code:
function onCompleteHandler(loadEvent:Event){ // Remove Preloader  middle.removeChild(preload);  content =

[code].....

View 2 Replies

Professional :: Get FlexContentHolder Content To Resize?

Sep 24, 2010

I'm creating a Flash SWC for use in an AIR project.
 
I created a component which I tweened from big to small.
 
I tried sampling the width/height at different keyframes (using both flash actions and the flex debugger) and the object always reports itself to be the original width/height.
 
The result is that any content I assign to the SWC container does not resize when the tween happens.
 
Is there another way to put dynamic flex content into a SWC?

View 1 Replies

Resize HBox Width To Fit Content?

Aug 8, 2009

I have an HBox with a fixed Width and Height and a Border. In that HBox I have a viewStack with a few different views.When the viewStack changes views, I want the HBox container to keep resizing to its content. Currently it stays at the fixed width.Is there any way to do that with an HBox setting?

View 2 Replies

Actionscript 3 :: Can't Resize Content To Fit A New NativeWindow In AIR

Dec 20, 2010

I'm trying to make a popup window class which will get a content DisaplyObject, and popup and display it in itself, but I'm cracking my head with matching the size of the content to the window or vise versa... I think that maybe the window is not display all of the stage or something ?[code]...

View 1 Replies

Resize Your Stage And Scale Content?

Mar 9, 2012

I have to adjust to a new size and my objects have to adjust accordingly. Is there a way to select multiple objects on separate frames and resize as a group?

View 1 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved