The same result with this code. In full screen I see blank screen. That means it is not code problem. I reinstalled Flash Player but that does not help. Can you please give me link with this code from you?
2011/2/24 Karl DeSaulniers <[email protected]>: > Try this natalia... > > import flash.geom.Rectangle; > > Stage["fullScreenSourceRect"] = new Rectangle( 0, 0, Stage.width/2, > Stage.height/2); > Stage.scaleMode = "maintainAspectRatio"; > > function goFullScreen() > { > Stage["displayState"] = "fullScreen"; > } > > function exitFullScreen() > { > Stage["displayState"] = "normal"; > } > > function menuHandler(obj, menuObj) > { > if (Stage["displayState"] == "normal") > { > menuObj.customItems[0].enabled = true; > menuObj.customItems[1].enabled = false; > } > else > { > menuObj.customItems[0].enabled = false; > menuObj.customItems[1].enabled = true; > } > } > > this.onFullScreen = function(bFullScreen:Boolean):Void { > if (bFullScreen){ > Stage.showMenu = true; > } > } > > var fullscreenCM:ContextMenu = new ContextMenu(menuHandler); > > fullscreenCM.hideBuiltInItems(); > > var fs:ContextMenuItem = new ContextMenuItem("Go Full Screen", > goFullScreen); > fullscreenCM.customItems.push( fs ); > > var xfs:ContextMenuItem = new ContextMenuItem("Exit Full Screen", > exitFullScreen); > fullscreenCM.customItems.push( xfs ); > > Stage.addListener(Stage["displayState"] == "fullScreen", onFullScreen); > _root.menu = fullscreenCM; > > > Works for me.. :) > > Best, > Karl > > > > On Feb 24, 2011, at 3:48 AM, natalia Vikhtinskaya wrote: > >> Hi >> I am trying to use full screen mode. I tested this example for AS2 >> http://www.adobe.com/devnet/flashplayer/articles/full_screen_mode.html >> >> Here is a test html with goScaledFullScreen function >> http://www.mightybook.com/test/adobeAS2.html >> >> As you can see in full mode content disappears. >> The same if I use goFullScreen function. >> What is wrong in my adaptation? >> >> Code with custom context menu from this article >> >> import flash.geom.Rectangle; >> >> function goFullScreen() >> { >> Stage["displayState"] = "fullScreen"; >> } >> >> function goScaledFullScreen(){ >> var screenRectangle:Rectangle = new Rectangle(); >> screenRectangle.x = 0; >> screenRectangle.y = 0; >> screenRectangle.width=Stage.width/2; >> screenRectangle.height=Stage.height/2; >> Stage["fullScreenSourceRect"] = screenRectangle; >> Stage["displayState"] = "fullScreen"; >> } >> >> function exitFullScreen() >> { >> Stage["displayState"] = "normal"; >> } >> >> function menuHandler(obj, menuObj) >> { >> if (Stage["displayState"] == "normal") >> { >> menuObj.customItems[0].enabled = true; >> menuObj.customItems[1].enabled = false; >> } >> else >> { >> menuObj.customItems[0].enabled = false; >> menuObj.customItems[1].enabled = true; >> } >> } >> var fullscreenCM:ContextMenu = new ContextMenu(menuHandler); >> >> fullscreenCM.hideBuiltInItems(); >> >> var fs:ContextMenuItem = new ContextMenuItem("Go Full >> Screen",goScaledFullScreen); >> fullscreenCM.customItems.push( fs ); >> >> var xfs:ContextMenuItem = new ContextMenuItem("Exit Full Screen", >> exitFullScreen); >> fullscreenCM.customItems.push( xfs ); >> >> _root.menu = fullscreenCM; >> >> >> Thank you in advance. >> _______________________________________________ >> Flashcoders mailing list >> [email protected] >> http://chattyfig.figleaf.com/mailman/listinfo/flashcoders > > Karl DeSaulniers > Design Drumm > http://designdrumm.com > > _______________________________________________ > Flashcoders mailing list > [email protected] > http://chattyfig.figleaf.com/mailman/listinfo/flashcoders > _______________________________________________ Flashcoders mailing list [email protected] http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

