Actionscript 3 :: Bug Apparent In Browser But Not In Flash CS5?

Jan 27, 2011

I have a custom "StagedSprite" class that extends Sprite. Its purpose is to automatically align itself to the stage's border whenever the stage gets resized.NOW, I load a PNG file "ybmp" (Bitmap) and add it as child to "loadingIcon" (StagedSprite). In Flash CS5, the PNG is shown correctly on screen (aligned too). But if I publish and run the SWF from within Firefox or IE, the PNG IS NOT SHOWN!

What is even MORE strange is what the following code produces :

//var ybmp:Bitmap = the loaded bitmap
//loadingIcon is a StagedSprite
loadingIcon.addChild(ybmp);
trace(ybmp.bitmapData.width,ybmp.bitmapData.height);
trace(ybmp.width,ybmp.height);
trace(loadingIcon.width,loadingIcon.height,loadingIcon.getChildAt(0),loadingIcon.stage);

I put the "trace" results in a TextField on screen. In CS5, the code above produces :

215 200
215 200
215 200 [object Bitmap] [object Stage]

In Firefox and IE, the code above produces :

215 200
215 200
0 0 [object Bitmap] [object Stage]

What on earth is that?!? In the browsers, the Bitmap IS added in "loadingIcon" but "loadingIcon" still has its width and height set to zero. ?I could paste the StagedSprite code here too, but it's a little big and has no scrollRect property. After all, what could be the reason for it running in the Flash authoring tool but NOT in the browsers..?

View 1 Replies


Similar Posts:


ActionScript 3.0 :: Use Apparent To Optimize SWF Files?

Oct 16, 2011

I'm just installing Apparat, and I'm interested in using it to optimize my SWFs.

On its google code page some optimizations are listed out .. sliding window, flowgraph ... so is it possible to make use of these optimizations? how?

I have heard of the -reducer command, does it perform the optimizations? are there other commands you can use? or do you have to build apparat yourself and access it via scala?

View 0 Replies

ActionScript 3.0 :: SWF Behaviour Changes For No Apparent Reason

Sep 30, 2010

I have several two-sided ecards made with Papervision and TweenLite to flip them over.A couple of days ago the "flip" animation changed behaviour. This is in ecards I made several months ago. The ecards work OK but the PPV object is not positioned correctly.On the server, in IE the object is displaced to right and down by about 20 px. In FF it is displaced to up and left by about 10 px.In Chrome and Safari the display is OK.(Just to confuse you further, the display in FF is OK on my localhost).This effect seems to be local to my PC.

I have scanned for malware etc twice but nothing. I have the latest Flash player and browsers.

View 1 Replies

ActionScript 2.0 :: Attaching Movie Clips With Apparent Delay

Jul 20, 2005

I've been trying to figger this one out. How do you create a delay effect when dynamically attaching mc's to another mc, the stage, whatever.

say you're building an xml driven menu which is essentially a stack of mc's attached to another. how do you make them appear to fade in one by one, starting at the top and working toward the bottom? (i can create the effect, just not sure how to script it).

it's gotta be fairly straightforward since i see it lots of places. I tried creating it with frames but that doesn't work since the mc's get attached so quickly.

View 7 Replies

ActionScript 1/2 :: F8as2 - Headscratcher!  += Incrementation Stops For No Apparent Reason?

Jul 8, 2009

In trying to respond to a question I wrote a bit of code that just adds 0.01 to a number.  It is displayed in a dynamic text field.  If I start counting from 0 it only counts to 0.06.  The counting stops but the onEnterFrame keeps running.
 
The Code:
 
var num:Number = 0;this.onEnterFrame = function() {      num += .01;      trace(num);      num = Math.floor(num*100)/100;      trace("           "+num);};
 
The Output:
 
0.01
0.01
0.02
0.02

[code].....
 
Why did the code stop incrementing after 0.07?

View 3 Replies

Linux :: Intercept A Request To Read A Particular File And Instead Generate The Apparent Output Of That File Read Programatically

Mar 31, 2010

A friend of mine has a Flash Action script running on a LAMP server that currently reads an xml config file. He's asked me if it's possible to remove the xml file, and replace it somehow with a system (lets call it an 'auto xml generator') that intercepts the request to read that file and generates an output, so it appears to all intents and purposes as if the file still exists and contains the contents that has actually been returned from our auto xml generator'

View 3 Replies

Flex :: Make A Flash Browser App That Could Receive Data From Browser Plugin Or Other Windows App?

Dec 18, 2009

in other words, suppose I want to send data, like text, programmatically from a Windows app (such as a browser plugin) to a Flash app running in the browser. Well, conceptually, an example of this might be a Flash instant messenger with a textbox and button "Send"; so let's say I want to be able to programmatically paste the text and press Send or otherwise activate it. That's NOT what I am trying to do here in reality (i.e., no,I am not trying to spam other people's chat rooms or anything)but just an illustration of a similar situation.I can include in it whatever widget or hack that may be necessary.The reason why this problem is arising for me is that AFAIK the SDK that is providing me the data I want cannot be directly accessed from Flash, so I need a way to pipe the data from a regular app into Flash. can I have the Flash app interact with other apps through localhost IP? Or are there draconian restrictions on which server Flash in browser can and cannot interact?

View 1 Replies

Actionscript 3 - Flex / Flash - Open The Swf In A Browser Window That Doesn't Have The Browser Control Bar Or Menu?

Oct 27, 2010

The title essentially is the question, how do I open the .swf without the browser's control bar junk? and maximize the window?

View 2 Replies

ActionScript 2.0 :: Opening Browser Windows From A Flash Movie With Browser?

Jan 17, 2006

I have a PHP mailer form on my site which needs to be published in action script2 to work, but I also have a script set up to open browser windows of a certain size & location which needs actionscript 1 to work? The PHP mailer form has a "Name" field, "Email" field & "Message" field, theses can all be reset with a button. The button clears off any text in the 3 boxes to wipe them clean. The script on the reset button is:

on(release) {
_root.myForm.formNameField.txt = ""
_root.myForm.formEmailField.txt = ""[code].....

This works fine with section script 2 but not with as1. Does anyone know of a script that resets the .text field on as1 Alternatively is there any way of opening browser windows from a flash movie with browser win controls, eg. centre win, no scrollbars.

View 2 Replies

Flash :: Full Browser Detecting Browser Size?

May 8, 2007

[URL].. Anyone know the AS to make it automatically check the size of the browser for the listeners_notice when you resize the browser it works perfectly...but not when it first loads up.

[Code]...

View 11 Replies

ActionScript 1/2 :: Fit Browser To Flash, Without Fitting Flash To Browser?

May 11, 2009

I've figured out how to tell my flash website not to scale itself (which degrades the quality of the buttons i've created as .gifs). And then how to keep it centered within the browser. But this leads to unwanted white, negative space on all sides, since i'm keeping my site small enough for everyone to view (at 800 x 600). So what code can I add that will scale the browser to the set dimensions of the site? Rather than vice versa.

View 1 Replies

ActionScript 2.0 :: Full Screen Browser - Browser Window Is Opening At The Size It Was Last Used?

Apr 14, 2005

I have a standalone Flash projector running off CD. Currently, I use

getURL("http:url....);

to open the page on default browser. Only problem is the browser window is opening at the size it was last used. I like to see it opens full screen.

View 2 Replies

ActionScript 3.0 :: Detecting Browser Close Event And Send Data To Database / When User Closes Browser Window

May 24, 2010

Trying to detect a browser close event and send some data to the database when the user closes the browser window...but can't seem to get it to work.[code]

View 6 Replies

ActionScript 2.0 ::closing A Browser Window In All Types Of Browser?

Nov 9, 2009

I have looked around for this and haven't found a way that clearly explains how to do this. More often than not the button will close the browser window in one but not another browser.

Is the a simple way of closing a browser window in all types of browser ( Or mainly Firefox, IE and safari on both Mac and PC ) with actionscript?

View 0 Replies

ActionScript 3.0 :: Remote Access Varies From Browser To Browser?

Jul 17, 2010

I created a photo album viewer which grabs an XML file from my web site, and then parses the XML to get the paths to all the photos to be displayed by the album viewer. The code makes use of the URLLoader class to fetch the XML. The problem, though, is that in google Chrome it works-- but in IE8, it doesn't work. For example, the XML code and the image fetching code work seemlessly on Chrome. But in IE8 and in IE6, it seems to not be able to fetch such information.

I've read somewhere that you need a crossdomain.xml file at the root directory of your server. But I'm not crossing any domains! It's all coming from my server where the swf is being hosted!

View 1 Replies

ActionScript 2.0 :: Closing A Browser Window In All Types Of Browser?

Nov 9, 2009

often than not the button will close the browser window in one but not another browser.Is the a simple way of closing a browser window in all types of browser( Or mainly Firefox, IE and safari on both Mac and PC ) with actionscript?

View 5 Replies

Java :: Do Websockets Allow For P2p (browser To Browser) Communication

Nov 7, 2010

To clarify when I ask about browser to browser communication I mean without a server in between forwarding message. I would like to implement something like this for a game. If p2p in websockets isn't possible are there similar alternatives?

View 1 Replies

Ajax :: Browser Inside Of A Browser?

Sep 1, 2010

I am not trying to track clicks or anything like other people - I just want to put a browser within a browser that can go back, forward, refresh, accept user-entered URLs, and store bookmarks. Can flash/silverlight/ajax/whatever do this? If so, how?

View 4 Replies

ActionScript 2.0 :: Activate Flash Fullscreen Mode When Flash Movie Loads In The Browser

Oct 5, 2007

I want to activate Flash Fullscreen mode when flash movie loads in the browser. Without activating it through button clicks. I tried for this using this type of code:

function goFullScreen()
{
Stage["displayState"] = "fullScreen";
}
goFullScreen();

But it is not working this way, it is working when I put this type of code:

function goFullScreen()
{
Stage["displayState"] = "fullScreen";

[Code]....

View 3 Replies

ActionScript 3.0 :: Tilt Flash Object In Browser Window Without Altering Anything In Flash?

May 29, 2009

I apologize beforehand but this probably isn't directly related to flash. However I'm not sure exactly which front-end code would deal with this and thought flash developers might know something about it.Is it possible to tilt a flash object in the browser window without altering anything in flash?I've tried googling it but I've either word it badly or received more hits on cellphones than on flash.

View 4 Replies

Javascript :: Put Silverlight Application Inside Flash File(swf - Browser Independet Which Run With Flash Player)

Sep 30, 2010

i have created a silverlight application , but i need to embed it to a Flash file(swf) which it runs with Flash Player ( whithout using browser), I had found a solutions to call it using javascript, but it still needs my flash file run inside the browser, dose any one can help me, Either to run js inside swf (without need of browser) or any other way that i can embed my Silverlight application inside Flash.

View 1 Replies

Internet Explorer - IE 9 Flash Loads But Only Half Seen - IE Flash Does Not Load - Every Other Browser Works Great

Dec 2, 2011

look @ the source for this page [URL] It works great in all Webkit/Mozilla browers but in IE 9 we can only see the top half of the swf and in IE 8 it doesnt load @ all. I searched all the other threads and nothing seems to work

View 1 Replies

Actionscript 3 :: Flash Frame-rate Is Different In Browser Than It Is In Flash Player

May 17, 2011

I am using Flash CS4 and when testing my application my frame rate changes as it is programmed to do so. When I try to run the application in a browser (tried Firefox 4, Opera 10.5 and IE 8) the frame rate does not change.

Why does the frame-rate not change?

View 2 Replies

Actionscript 3 :: Flash Frame-rate Is Different In Browser Than It Is In Flash Player?

Jan 22, 2009

I am using Flash CS4 and when testing my application my frame rate changes as it is programmed to do so. When I try to run the application in a browser (tried Firefox 4, Opera 10.5 and IE 8) the frame rate does not chang

View 6 Replies

Flash 9 :: FLV On Some Browser

Sep 3, 2008

I'm embedding in a swf a flv video, with the classic "FLVPlayback", a flv of 500kbps...duration 10 seconds, total size 700kb and start buffering at 0.5... The swf is embedded in the html with swfoject:

[Code]...

On mac everything is fine, but on ie(6,7) and ff PC version, the flv doesn't seem to work fine. Sometimes it just stops....sometimes it stops definitively.

View 0 Replies

Actionscript 2 :: Clickable Links In A Scrolling HTML Enabled Dynamic Textfield In Flash Movie - Works In Flash Pro Not In Browser?

Dec 13, 2010

I have developed a rolling credits style movieclip in Flash using Actionscript 2. Text is loaded from an XML file and parsed into a dynamic textfield. This text includes hyperlinks to webpages defined by a url node in the xml so Flash can add the appropriate a href to the dynamic text field and make the link clickable.

In my first attempts to do this the textfield stayed still and all the links worked fine both testing locally and when I run it in a browser on my website.Then I wanted to make things move ... which I achieved easily enough and tested locally (from within Flash Professional) and the links remained clickable, a browser window opened and the webpage i was expecting to see opened... great

However, when I export the swf, upload it and run it from my website suddenly the links are not working. So I tried to test the movie in a browser from Flash Pro - same problem, it must be something to do with Flash Player and the moving dynamic textfield.

a couple of observations - the cursor will change to a hand icon when over the links as you would expect, and if I right click on the link and click open in a new window the link works ok, just not when I left click. If I stop the scrolling then the links become clickable again, it is only when the textfield is moving... actually its not technically scrolling, im moving the whole textfield.

View 1 Replies

SWF Works Great In Flash, Not In Flash Player Or Web Browser?

Oct 15, 2009

I have numerous swf files which work except one that is rather complex. When I debug the FLA of this problem file in flash CS4, it works fine. When I publish the FLA and open the subsequent SWF in Flash, it works fine. I open the same file in Flash Player or when I open it on a browser, the screen is white and nothing happens. When a right click on the browser frame and it offers me all the possibilities of a fully loaded movie, except that there is just a blank screen

View 1 Replies

Flash 10 :: Continue Flash Animation Despite Inactive Browser Tab?

Jan 11, 2012

I have an issue with Flash optimization (I guess). The thing is, when you switch to another browser tab/window, scroll down it's window... anything that makes Flash disappear stops its runtime. I've found out that this optimization system was introduced in Flash Player 10.1 - it slows down Flash Player to 2fps in order to lower it's CPU and memory usage. My question is - how do I skip it? I want my animation to play even when it's not visible by all means whatsoever. Is it in the embed code? Publish Settings? Or maybe I need to insert some AS into my timeline? Each site has a Flash content (mostly banners) which behave in the normal way - they run in the background - but everything I publish and upload freezes (it actually plays at 2fps, but the effect is pretty much the same). Here's an example: when I open any flash site, a preloader appears, so I switch to another tab to do something in the mean time, when I assume it has loaded, I switch back and there it is - a loaded Flash site. But when I open MY Flash site or animation, switch tabs and wait for it to load, and after a while when I come back, the preloader is still at the beginning and continues doing its stuff from the very moment it shows up again. This is not how thing suppose to work. I can open directly the simplest animation there can be - a simple motion tween of a ball from one side of a screen to another, when the tab holding it becomes active after a while, the animation is still at the beginning, but the animation is short/fast and it supposed to have finished already. I've found out something about Activate and Deactivate Events, but they are used in Flash games - so it would pause when the game loses focus. But this works on the Flash object, not whole browser itself.

View 1 Replies

ActionScript 2.0 :: Fullscreen Browser With Flash Embed Using Flash 8

Nov 10, 2009

I need some insight in to weather it is possible to use stage["diaplayState"]="fullscreen" in flash 8.. if not any way to open the browser in fullscreenmode with flash embed in it..

But i have done this in flash cs3 but using flash player 8 for publishing

also publishing an html in flash 8 does not show "allowfullscreen" value="true" in embed or object tags ..

View 4 Replies

Getting Flash To Center In Web Browser?

Jun 4, 2009

Just upgraded to Flash CS4. Published .swf/.html files... Trying to get the .swf to display in the center (horizontally) of the .html page / browser window. Previously I used <div align="center"><object>...</object></div> but that no longer works! It displays centered from within Dreamweaver but not in any browsers I've tried. Can't for the life of me figure out why!!

I noticed Flash CS4 now spits out a whole lotta code in the generated .html file and I'm assuming the source of the problem is somewhere within.The only workaround I've found so far is to publish just the .swf and manually embed it into a new .html page... but then I no longer have all the (detection) code.

View 5 Replies







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