jan_flanders

Untitled

Aug 28th, 2012
71
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. private function videoDisplay_creationComplete():void
  2. {
  3.     //titleWindow = PopUpManager.createPopUp(this, Dialog, true) as TitleWindow;
  4.     //PopUpManager.centerPopUp(titleWindow);
  5.    
  6.     var cam:Camera = Camera.getCamera();
  7.     if (cam != null)
  8.     {
  9.         cam.addEventListener(StatusEvent.STATUS, statusHandler);
  10.     }
  11. }
  12. function statusHandler(event:StatusEvent):void
  13. {
  14.     if(event.code == "Camera.Unmuted") // "Camera.Muted" or "Camera.Unmuted"
  15.     trace("OK");// good to go
  16.     else
  17.     trace("NOK");// permission denied        
  18.     titleWindow = PopUpManager.createPopUp(this, Dialog2, true) as TitleWindow;
  19.     PopUpManager.centerPopUp(titleWindow);
  20. }
  21. Security.showSettings(SecurityPanel.PRIVACY);
Advertisement
Add Comment
Please, Sign In to add comment