Why window.opener crashes!!!??? -WTF 2004-03-05 - By Justin Watkins
Back I've narrowed it down to the camera... But can't explain why (or figure out a way around this). I've seen it here before, and the answer was always, clean up your connections. Well, unless I'm just being a complete idiot that doesn't work for me either.
This happens in IE 6, haven't tested any other versions as doing this is painful enough.
Here's the code....
onUnload = function () { vid.attachVideo(null); vid.clear(); vid.unloadMovie(); vid.removeMovieClip(); this.unloadMovie(); this.removeMovieClip(); myCam = null; delete myCam; } myCam = Camera.get(); vid.attachVideo(myCam);
Simple enough, you can even download the fla http://www.justin-watkins.com/wtf/Test.fla
You can see the crash with http://www.justin-watkins.com/wtf/Launcher.html
Repro steps.. 1. Open the Launcher.html link above. 2. Accept camera permission (or deny, doesn't matter crashes for me either way) 3. Close the popup (Don't close the opener first, that works fine) 4. Try to close the opener
Now you can see that the onUnload function clears out everything, but yet still a crash on the window.opener. If I'm missing something, PLEASE make me feel stupid, hanging my head in shame would actually be a better feeling right now :). BTW, this happens even if you just have Camera.get() in the code and don't attach the Camera stream to anything. Why isn't there a clear way to close the connection to the camera?
-justin
-- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ------ Supported by Fig Leaf Software -- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ------ Lower Prices for Certified Training! Check out new lower prices for Certified Macromedia Training from Fig Leaf Software. Expand your skill set with courses in ColdFusion, Flash, Rich Internet Applications and .NET in the new year. Fig Leaf Software provides the highest caliber instruction at our training centers in Washington D.C., Atlanta, Chicago, Baltimore, Northern Virginia, or on-site at your location.
Get the details at http://training.figleaf.com/ -- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ------ To unsubscribe, e-mail: flashcomm-unsubscribe@(protected) For additional commands, e-mail: flashcomm-help@(protected)
|
|