                 
                 // Add event listeners
 //                navigator.addEventListener(Event.COMPLETE, persistViewData);
-                navigator.addEventListener(ViewNavigatorEvent.VIEW_ADD, navigator_viewAddHandler);
+                navigator.addEventListener(ElementExistenceEvent.ELEMENT_ADD, navigator_viewAddHandler);
             }
         }
         

    import flash.events.StageOrientationEvent;
    import flash.net.registerClassAlias;
    import flash.system.Capabilities;
    import flash.system.System;
    import flash.ui.Keyboard;
    
    import mx.core.IVisualElement;

        }
        
        
        protected function navigator_viewAddHandler(event:ElementExistenceEvent):void
        {
            var view:View = event.element as View;
            
            if (view)
                view.setCurrentState(view.getCurrentViewState(isLandscape), false);
