RE: [Flashcoders] Javascript Flash resizing
Hi Ashim, Thanks. I have it already working with StageDisplayMode.FULLSCREEN, but this still needs a user interaction. And I would like to open my app fullscreen without any browser visuals, and even better if the user is not able to switch to any other display mode. Kind regards cor -Original Message- From: flashcoders-boun...@chattyfig.figleaf.com [mailto:flashcoders-boun...@chattyfig.figleaf.com] On Behalf Of Ashim D'Silva Sent: donderdag 19 februari 2009 11:23 To: flashcoders@chattyfig.figleaf.com Subject: Re: [Flashcoders] Javascript Flash resizing Hey Cor, I'm just putting this back on the list because I actually don't really know javascript. I write basic stuff because it resembles actionscript (ECMA). Specific stuff I'd look up. I'd imagine you'll need to launch a new window for that but maybe somebody else will know. You could also go fullscreen from flash by setting the stage.displayMode property to StageDisplayMode.FULLSCREEN (check that, gmail doesn't have intellisense). Ashim 2009/2/18 Cor c...@chello.nl Hello Ashim, I am not familiair with JS. I hope I may ask you a question. Is it possible to set my index.htm maximized, so only my Flash is showing maximized? So there will be no browser items, like the menubar, browser buttons, etc.? Kind regards Cor van Dooren -Original Message- From: flashcoders-boun...@chattyfig.figleaf.com [mailto:flashcoders-boun...@chattyfig.figleaf.com] On Behalf Of Ashim D'Silva Sent: woensdag 18 februari 2009 1:14 To: Flash Coders List Subject: Re: [Flashcoders] Javascript Flash resizing Javascript and flash can do some interesting things together. I built a flash gallery that would load up images and depending on how much space it needed, resize the div the flash was sitting in so browser scroll-bars came into effect if necessary. Then, when a certain image is displayed large, scrolling in the browser would move the large image inside the flash so it's always centred within the browser window. Here's my javascript, the flash should be simple to work out: script type=text/javascript if (window.addEventListener) { window.addEventListener('scroll',scrollingDetector,false); window.addEventListener('resize',resizeDetector,false); } else if (document.addEventListener) { document.addEventListener('scroll',scrollingDetector,false); document.addEventListener('resize',resizeDetector,false); } function scrollingDetector() { var scrollY; if (navigator.appName == Microsoft Internet Explorer) { scrollY = document.body.scrollTop; } else { scrollY = window.pageYOffset; } getFlashMovie(excl).setScrollY(scrollY); } function resizeDetector() { var height; if (navigator.appName == Microsoft Internet Explorer) { height = documentbody.offsetHeight; } else { height = window.innerHeight; } getFlashMovie(excl).setHeight(height); } function runFirst() { scrollingDetector(); resizeDetector(); } function getFlashMovie(movieName) { var isIE = navigator.appName.indexOf(Microsoft) != -1; return (isIE) ? window[movieName] : document[movieName]; } function setFlashHeight(newH) { gid = document.getElementById(flashHolder); //gid.style.width = 965px; gid.style.height = newH +px; } /script 2009/2/18 Matt S. mattsp...@gmail.com Have you guys had experience with dynamic resizing of the flash via Javascript in order to use the browser scrollbar to scroll, eg with http://swffit.millermedeiros.com/ or something similar? any recommendations? thx, .m ___ Flashcoders mailing list Flashcoders@chattyfig.figleaf.com http://chattyfig.figleaf.com/mailman/listinfo/flashcoders -- The Random Lines My online portfolio www.therandomlines.com ___ Flashcoders mailing list Flashcoders@chattyfig.figleaf.com http://chattyfig.figleaf.com/mailman/listinfo/flashcoders No virus found in this incoming message. Checked by AVG - www.avg.com Version: 8.0.237 / Virus Database: 270.10.25/1956 - Release Date: 02/16/09 18:31:00 -- The Random Lines My online portfolio www.therandomlines.com ___ Flashcoders mailing list Flashcoders@chattyfig.figleaf.com http://chattyfig.figleaf.com/mailman/listinfo/flashcoders No virus found in this incoming message. Checked by AVG - www.avg.com Version: 8.0.237 / Virus Database: 270.10.25/1957 - Release Date: 02/17/09 07:07:00 ___ Flashcoders mailing list Flashcoders@chattyfig.figleaf.com http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
[Flashcoders] Display Object Container refresh ...
You have a class with a public DOC (DisplayObjectContainer). This DOC contains all the visual assets of your class. In you refresh/reset/constructor method, do you use either: container = null; or a loop to manually remove all display objects within the container, eg: if (container != null) { if (container.numChildren 0) { for (var i = 0; i container.numChildren; i++) { container.removeChildAt(i); } } } Um ... that's it. ___ Flashcoders mailing list Flashcoders@chattyfig.figleaf.com http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
Re: [Flashcoders] Javascript Flash resizing
I wouldn't really like that as a user, a webpage that takes my screen without asking.If it's an app, try AIR, that might have something. You should be able to launch a window with javascript without interaction (window.open - look it up) Other than that, I'm really not sure. 2009/2/20 Cor c...@chello.nl Hi Ashim, Thanks. I have it already working with StageDisplayMode.FULLSCREEN, but this still needs a user interaction. And I would like to open my app fullscreen without any browser visuals, and even better if the user is not able to switch to any other display mode. Kind regards cor -Original Message- From: flashcoders-boun...@chattyfig.figleaf.com [mailto:flashcoders-boun...@chattyfig.figleaf.com] On Behalf Of Ashim D'Silva Sent: donderdag 19 februari 2009 11:23 To: flashcoders@chattyfig.figleaf.com Subject: Re: [Flashcoders] Javascript Flash resizing Hey Cor, I'm just putting this back on the list because I actually don't really know javascript. I write basic stuff because it resembles actionscript (ECMA). Specific stuff I'd look up. I'd imagine you'll need to launch a new window for that but maybe somebody else will know. You could also go fullscreen from flash by setting the stage.displayMode property to StageDisplayMode.FULLSCREEN (check that, gmail doesn't have intellisense). Ashim 2009/2/18 Cor c...@chello.nl Hello Ashim, I am not familiair with JS. I hope I may ask you a question. Is it possible to set my index.htm maximized, so only my Flash is showing maximized? So there will be no browser items, like the menubar, browser buttons, etc.? Kind regards Cor van Dooren -Original Message- From: flashcoders-boun...@chattyfig.figleaf.com [mailto:flashcoders-boun...@chattyfig.figleaf.com] On Behalf Of Ashim D'Silva Sent: woensdag 18 februari 2009 1:14 To: Flash Coders List Subject: Re: [Flashcoders] Javascript Flash resizing Javascript and flash can do some interesting things together. I built a flash gallery that would load up images and depending on how much space it needed, resize the div the flash was sitting in so browser scroll-bars came into effect if necessary. Then, when a certain image is displayed large, scrolling in the browser would move the large image inside the flash so it's always centred within the browser window. Here's my javascript, the flash should be simple to work out: script type=text/javascript if (window.addEventListener) { window.addEventListener('scroll',scrollingDetector,false); window.addEventListener('resize',resizeDetector,false); } else if (document.addEventListener) { document.addEventListener('scroll',scrollingDetector,false); document.addEventListener('resize',resizeDetector,false); } function scrollingDetector() { var scrollY; if (navigator.appName == Microsoft Internet Explorer) { scrollY = document.body.scrollTop; } else { scrollY = window.pageYOffset; } getFlashMovie(excl).setScrollY(scrollY); } function resizeDetector() { var height; if (navigator.appName == Microsoft Internet Explorer) { height = documentbody.offsetHeight; } else { height = window.innerHeight; } getFlashMovie(excl).setHeight(height); } function runFirst() { scrollingDetector(); resizeDetector(); } function getFlashMovie(movieName) { var isIE = navigator.appName.indexOf(Microsoft) != -1; return (isIE) ? window[movieName] : document[movieName]; } function setFlashHeight(newH) { gid = document.getElementById(flashHolder); //gid.style.width = 965px; gid.style.height = newH +px; } /script 2009/2/18 Matt S. mattsp...@gmail.com Have you guys had experience with dynamic resizing of the flash via Javascript in order to use the browser scrollbar to scroll, eg with http://swffit.millermedeiros.com/ or something similar? any recommendations? thx, .m ___ Flashcoders mailing list Flashcoders@chattyfig.figleaf.com http://chattyfig.figleaf.com/mailman/listinfo/flashcoders -- The Random Lines My online portfolio www.therandomlines.com ___ Flashcoders mailing list Flashcoders@chattyfig.figleaf.com http://chattyfig.figleaf.com/mailman/listinfo/flashcoders No virus found in this incoming message. Checked by AVG - www.avg.com Version: 8.0.237 / Virus Database: 270.10.25/1956 - Release Date: 02/16/09 18:31:00 -- The Random Lines My online portfolio www.therandomlines.com ___ Flashcoders mailing list Flashcoders@chattyfig.figleaf.com http://chattyfig.figleaf.com/mailman/listinfo/flashcoders No virus found in this incoming message. Checked by AVG - www.avg.com Version: 8.0.237 / Virus Database: 270.10.25/1957 - Release Date: 02/17/09 07:07:00
RE: [Flashcoders] Javascript Flash resizing
I know, its not for websites but company learningapps. I can't use AIR. All my apps are to be launched from Moodle. Thanks! -Original Message- From: flashcoders-boun...@chattyfig.figleaf.com [mailto:flashcoders-boun...@chattyfig.figleaf.com] On Behalf Of Ashim D'Silva Sent: vrijdag 20 februari 2009 12:53 To: Flash Coders List Subject: Re: [Flashcoders] Javascript Flash resizing I wouldn't really like that as a user, a webpage that takes my screen without asking.If it's an app, try AIR, that might have something. You should be able to launch a window with javascript without interaction (window.open - look it up) Other than that, I'm really not sure. 2009/2/20 Cor c...@chello.nl Hi Ashim, Thanks. I have it already working with StageDisplayMode.FULLSCREEN, but this still needs a user interaction. And I would like to open my app fullscreen without any browser visuals, and even better if the user is not able to switch to any other display mode. Kind regards cor -Original Message- From: flashcoders-boun...@chattyfig.figleaf.com [mailto:flashcoders-boun...@chattyfig.figleaf.com] On Behalf Of Ashim D'Silva Sent: donderdag 19 februari 2009 11:23 To: flashcoders@chattyfig.figleaf.com Subject: Re: [Flashcoders] Javascript Flash resizing Hey Cor, I'm just putting this back on the list because I actually don't really know javascript. I write basic stuff because it resembles actionscript (ECMA). Specific stuff I'd look up. I'd imagine you'll need to launch a new window for that but maybe somebody else will know. You could also go fullscreen from flash by setting the stage.displayMode property to StageDisplayMode.FULLSCREEN (check that, gmail doesn't have intellisense). Ashim 2009/2/18 Cor c...@chello.nl Hello Ashim, I am not familiair with JS. I hope I may ask you a question. Is it possible to set my index.htm maximized, so only my Flash is showing maximized? So there will be no browser items, like the menubar, browser buttons, etc.? Kind regards Cor van Dooren -Original Message- From: flashcoders-boun...@chattyfig.figleaf.com [mailto:flashcoders-boun...@chattyfig.figleaf.com] On Behalf Of Ashim D'Silva Sent: woensdag 18 februari 2009 1:14 To: Flash Coders List Subject: Re: [Flashcoders] Javascript Flash resizing Javascript and flash can do some interesting things together. I built a flash gallery that would load up images and depending on how much space it needed, resize the div the flash was sitting in so browser scroll-bars came into effect if necessary. Then, when a certain image is displayed large, scrolling in the browser would move the large image inside the flash so it's always centred within the browser window. Here's my javascript, the flash should be simple to work out: script type=text/javascript if (window.addEventListener) { window.addEventListener('scroll',scrollingDetector,false); window.addEventListener('resize',resizeDetector,false); } else if (document.addEventListener) { document.addEventListener('scroll',scrollingDetector,false); document.addEventListener('resize',resizeDetector,false); } function scrollingDetector() { var scrollY; if (navigator.appName == Microsoft Internet Explorer) { scrollY = document.body.scrollTop; } else { scrollY = window.pageYOffset; } getFlashMovie(excl).setScrollY(scrollY); } function resizeDetector() { var height; if (navigator.appName == Microsoft Internet Explorer) { height = documentbody.offsetHeight; } else { height = window.innerHeight; } getFlashMovie(excl).setHeight(height); } function runFirst() { scrollingDetector(); resizeDetector(); } function getFlashMovie(movieName) { var isIE = navigator.appName.indexOf(Microsoft) != -1; return (isIE) ? window[movieName] : document[movieName]; } function setFlashHeight(newH) { gid = document.getElementById(flashHolder); //gid.style.width = 965px; gid.style.height = newH +px; } /script 2009/2/18 Matt S. mattsp...@gmail.com Have you guys had experience with dynamic resizing of the flash via Javascript in order to use the browser scrollbar to scroll, eg with http://swffit.millermedeiros.com/ or something similar? any recommendations? thx, .m ___ Flashcoders mailing list Flashcoders@chattyfig.figleaf.com http://chattyfig.figleaf.com/mailman/listinfo/flashcoders -- The Random Lines My online portfolio www.therandomlines.com ___ Flashcoders mailing list Flashcoders@chattyfig.figleaf.com http://chattyfig.figleaf.com/mailman/listinfo/flashcoders No virus found in this incoming message. Checked by AVG - www.avg.com Version: 8.0.237 / Virus Database: 270.10.25/1956 - Release Date: 02/16/09 18:31:00 -- The Random Lines My
Re: [Flashcoders] Javascript Flash resizing
As I'm sure you've discovered, Flash Player security model will block you from doing this directly: The ActionScript that initiates full-screen mode can be called only in response to a mouse event or keyboard event. If it is called in other situations, Flash Player throws an exception. Users cannot enter text in text input fields while in full-screen mode. All keyboard input and keyboard-related ActionScript is disabled while in full-screen mode, with the exception of the keyboard shortcuts (such as pressing the Esc key) that return the application to normal mode. So I take it that you are trying to fake it somehow by forcing the browser itself into fullscreen mode and then javascripting the Flash window to the entire size of the window? Sounds pretty tricky. -jonathan On Fri, Feb 20, 2009 at 7:32 AM, Cor c...@chello.nl wrote: I know, its not for websites but company learningapps. I can't use AIR. All my apps are to be launched from Moodle. Thanks! -Original Message- From: flashcoders-boun...@chattyfig.figleaf.com [mailto:flashcoders-boun...@chattyfig.figleaf.com] On Behalf Of Ashim D'Silva Sent: vrijdag 20 februari 2009 12:53 To: Flash Coders List Subject: Re: [Flashcoders] Javascript Flash resizing I wouldn't really like that as a user, a webpage that takes my screen without asking.If it's an app, try AIR, that might have something. You should be able to launch a window with javascript without interaction (window.open - look it up) Other than that, I'm really not sure. 2009/2/20 Cor c...@chello.nl Hi Ashim, Thanks. I have it already working with StageDisplayMode.FULLSCREEN, but this still needs a user interaction. And I would like to open my app fullscreen without any browser visuals, and even better if the user is not able to switch to any other display mode. Kind regards cor -Original Message- From: flashcoders-boun...@chattyfig.figleaf.com [mailto:flashcoders-boun...@chattyfig.figleaf.com] On Behalf Of Ashim D'Silva Sent: donderdag 19 februari 2009 11:23 To: flashcoders@chattyfig.figleaf.com Subject: Re: [Flashcoders] Javascript Flash resizing Hey Cor, I'm just putting this back on the list because I actually don't really know javascript. I write basic stuff because it resembles actionscript (ECMA). Specific stuff I'd look up. I'd imagine you'll need to launch a new window for that but maybe somebody else will know. You could also go fullscreen from flash by setting the stage.displayMode property to StageDisplayMode.FULLSCREEN (check that, gmail doesn't have intellisense). Ashim 2009/2/18 Cor c...@chello.nl Hello Ashim, I am not familiair with JS. I hope I may ask you a question. Is it possible to set my index.htm maximized, so only my Flash is showing maximized? So there will be no browser items, like the menubar, browser buttons, etc.? Kind regards Cor van Dooren -Original Message- From: flashcoders-boun...@chattyfig.figleaf.com [mailto:flashcoders-boun...@chattyfig.figleaf.com] On Behalf Of Ashim D'Silva Sent: woensdag 18 februari 2009 1:14 To: Flash Coders List Subject: Re: [Flashcoders] Javascript Flash resizing Javascript and flash can do some interesting things together. I built a flash gallery that would load up images and depending on how much space it needed, resize the div the flash was sitting in so browser scroll-bars came into effect if necessary. Then, when a certain image is displayed large, scrolling in the browser would move the large image inside the flash so it's always centred within the browser window. Here's my javascript, the flash should be simple to work out: script type=text/javascript if (window.addEventListener) { window.addEventListener('scroll',scrollingDetector,false); window.addEventListener('resize',resizeDetector,false); } else if (document.addEventListener) { document.addEventListener('scroll',scrollingDetector,false); document.addEventListener('resize',resizeDetector,false); } function scrollingDetector() { var scrollY; if (navigator.appName == Microsoft Internet Explorer) { scrollY = document.body.scrollTop; } else { scrollY = window.pageYOffset; } getFlashMovie(excl).setScrollY(scrollY); } function resizeDetector() { var height; if (navigator.appName == Microsoft Internet Explorer) { height = documentbody.offsetHeight; } else { height = window.innerHeight; } getFlashMovie(excl).setHeight(height); } function runFirst() { scrollingDetector(); resizeDetector(); } function getFlashMovie(movieName) { var isIE = navigator.appName.indexOf(Microsoft) != -1; return (isIE) ? window[movieName] : document[movieName]; } function setFlashHeight(newH) { gid = document.getElementById(flashHolder);
Re: [Flashcoders] Display Object Container refresh ...
var n: Number = container.numChildren; while ( n-- ) { container.removeChildAt(n); } sounds better ;) less problems when you start from the bottom is my experience. You have a class with a public DOC (DisplayObjectContainer). This DOC contains all the visual assets of your class. In you refresh/reset/constructor method, do you use either: container = null; or a loop to manually remove all display objects within the container, eg: if (container != null) { if (container.numChildren 0) { for (var i = 0; i container.numChildren; i++) { container.removeChildAt(i); } } } Um ... that's it. ___ Flashcoders mailing list Flashcoders@chattyfig.figleaf.com http://chattyfig.figleaf.com/mailman/listinfo/flashcoders ___ Flashcoders mailing list Flashcoders@chattyfig.figleaf.com http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
RE: [Flashcoders] Javascript Flash resizing
Jonathan, Thank you! I did know about the blocking directly. This is what I am trying to overcome. BUT, I didn't know it is not possible to use keyboard input And that is surely something I need. If no one comes up with some kind of sulotion, I guess I have to run it in the browser window? Thanks again!!! Cor -Original Message- From: flashcoders-boun...@chattyfig.figleaf.com [mailto:flashcoders-boun...@chattyfig.figleaf.com] On Behalf Of jonathan howe Sent: vrijdag 20 februari 2009 14:09 To: Flash Coders List Subject: Re: [Flashcoders] Javascript Flash resizing As I'm sure you've discovered, Flash Player security model will block you from doing this directly: The ActionScript that initiates full-screen mode can be called only in response to a mouse event or keyboard event. If it is called in other situations, Flash Player throws an exception. Users cannot enter text in text input fields while in full-screen mode. All keyboard input and keyboard-related ActionScript is disabled while in full-screen mode, with the exception of the keyboard shortcuts (such as pressing the Esc key) that return the application to normal mode. So I take it that you are trying to fake it somehow by forcing the browser itself into fullscreen mode and then javascripting the Flash window to the entire size of the window? Sounds pretty tricky. -jonathan ___ Flashcoders mailing list Flashcoders@chattyfig.figleaf.com http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
RE: [Flashcoders] Display Object Container refresh ...
Nice(r) -Original Message- From: flashcoders-boun...@chattyfig.figleaf.com [mailto:flashcoders-boun...@chattyfig.figleaf.com] On Behalf Of Weyert de Boer Sent: vrijdag 20 februari 2009 14:35 To: Flash Coders List Subject: Re: [Flashcoders] Display Object Container refresh ... var n: Number = container.numChildren; while ( n-- ) { container.removeChildAt(n); } sounds better ;) less problems when you start from the bottom is my experience. You have a class with a public DOC (DisplayObjectContainer). This DOC contains all the visual assets of your class. In you refresh/reset/constructor method, do you use either: container = null; or a loop to manually remove all display objects within the container, eg: if (container != null) { if (container.numChildren 0) { for (var i = 0; i container.numChildren; i++) { container.removeChildAt(i); } } } Um ... that's it. ___ Flashcoders mailing list Flashcoders@chattyfig.figleaf.com http://chattyfig.figleaf.com/mailman/listinfo/flashcoders ___ Flashcoders mailing list Flashcoders@chattyfig.figleaf.com http://chattyfig.figleaf.com/mailman/listinfo/flashcoders No virus found in this incoming message. Checked by AVG - www.avg.com Version: 8.0.237 / Virus Database: 270.10.25/1957 - Release Date: 02/19/09 18:45:00 ___ Flashcoders mailing list Flashcoders@chattyfig.figleaf.com http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
Re: [Flashcoders] Javascript Flash resizing ...
awesome - thanks On Thu, Feb 19, 2009 at 8:15 AM, SJF sjf...@gmail.com wrote: Try this - http://code.google.com/p/resizetoolkit/downloads/detail?name=ResizeToolkit_v.95.zipcan=2q = Haven't used it myself yet, but it looks like a robust technique/set of classes. ___ Flashcoders mailing list Flashcoders@chattyfig.figleaf.com http://chattyfig.figleaf.com/mailman/listinfo/flashcoders ___ Flashcoders mailing list Flashcoders@chattyfig.figleaf.com http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
[Flashcoders] Re: xml and e4x searching question
Thank you very much Taka and Kenneth - that answers my question. The question, and my example, was academic; I was wondering how is it supposed to work since it didn't seem to follow the pattern for children at a second level. I usually have a healthy amount of attributes in use however, I thought I'd read that future versions of XML were moving away from the use of attributes - any truth to that rumor? ___ Flashcoders mailing list Flashcoders@chattyfig.figleaf.com http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
[Flashcoders] Capture sound from computer speakers?
I am looking at the docs, and it almost seems like I can't capture the sound that is playing through the speakers (itunes/web/application). Which seems odd to me given that we can capture the camera and microphone but not just sound that is not played within the flash player. I did a soft search within Adobe Air but I haven't found information in there either(yet) Anyone has any suggestions? TIA ___ Flashcoders mailing list Flashcoders@chattyfig.figleaf.com http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
Re: [Flashcoders] Capture sound from computer speakers?
What you hear, in your speakers is audio output... not audio input. So to do what you want, you need to somehow turn your audio output into an input. Here are few ideas: - I used to have a Sound Blaster sound card that had a driver that would loop the audio out back into the input. There was a sound setting to select What you hear as an option. - Use Soundflower on the mac - http://code.google.com/p/soundflower/ - Simply run a sound wire from your computer's audio out into the audio in (microphone) jack. Keep in mind, that anyone who wants to record audio output using your flash / air application is going to have to do one of these things above as well. HTH, Nate On Fri, Feb 20, 2009 at 1:05 PM, Helmut Granda cont...@helmutgranda.comwrote: I am looking at the docs, and it almost seems like I can't capture the sound that is playing through the speakers (itunes/web/application). Which seems odd to me given that we can capture the camera and microphone but not just sound that is not played within the flash player. I did a soft search within Adobe Air but I haven't found information in there either(yet) Anyone has any suggestions? TIA ___ Flashcoders mailing list Flashcoders@chattyfig.figleaf.com http://chattyfig.figleaf.com/mailman/listinfo/flashcoders -- Cheers, Nate http://blog.natebeck.net ___ Flashcoders mailing list Flashcoders@chattyfig.figleaf.com http://chattyfig.figleaf.com/mailman/listinfo/flashcoders