Index: lams_central/src/flash/org/lamsfoundation/lams/authoring/Application.as =================================================================== diff -u -r838488753c0cd859c12f16296c7f0179449c59ea -r0c2b50ae32b1ba09e4c921e0b711d010e71d5541 --- lams_central/src/flash/org/lamsfoundation/lams/authoring/Application.as (.../Application.as) (revision 838488753c0cd859c12f16296c7f0179449c59ea) +++ lams_central/src/flash/org/lamsfoundation/lams/authoring/Application.as (.../Application.as) (revision 0c2b50ae32b1ba09e4c921e0b711d010e71d5541) @@ -67,6 +67,7 @@ private static var WORKSPACE_W:Number = 300; private static var WORKSPACE_H:Number = 200; + private static var LOADING_ROOT_DEPTH:Number = 1000; //depth of the loading movie private static var APP_ROOT_DEPTH:Number = 10; //depth of the application root private static var DIALOGUE_DEPTH:Number = 20; //depth of the cursors private static var TOOLTIP_DEPTH:Number = 30; //depth of the cursors @@ -91,6 +92,8 @@ public static var CUT_TYPE:Number = 0; public static var COPY_TYPE:Number = 1; + + private static var COMPONENT_NO = 9; private var _uiLoadCheckCount = 0; // instance counter for number of times we have checked to see if theme and dict are loaded private var _dataLoadCheckCount = 0; @@ -103,7 +106,6 @@ private var _PI:PropertyInspectorNew; private var _debugDialog:MovieClip; //Reference to the debug dialog - private var _dialogueContainer_mc:MovieClip; //Dialog container private var _tooltipContainer_mc:MovieClip; //Tooltip container private var _cursorContainer_mc:MovieClip; //Cursor container @@ -144,6 +146,7 @@ _toolbarLoaded = false; _piLoaded = false; _module = Application.MODULE; + //Mouse.addListener(someListener); } @@ -163,14 +166,17 @@ public function main(container_mc:MovieClip){ _container_mc = container_mc; _UILoaded = false; - + + loader.start(COMPONENT_NO); + //add the cursors: Cursor.addCursor(C_HOURGLASS); Cursor.addCursor(C_OPTIONAL); Cursor.addCursor(C_TRANSITION); Cursor.addCursor(C_GATE); Cursor.addCursor(C_GROUP); + //Get the instance of config class _config = Config.getInstance(); @@ -189,7 +195,8 @@ private function configLoaded(){ //Now that the config class is ready setup the UI and data, call to setupData() first in //case UI element constructors use objects instantiated with setupData() - setupData(); + loader.complete(); + setupData(); checkDataLoaded(); } @@ -222,6 +229,7 @@ * Periodically checks if data has been loaded */ private function checkDataLoaded() { + // first time through set interval for method polling if(!_DataLoadCheckIntervalID) { _DataLoadCheckIntervalID = setInterval(Proxy.create(this, checkDataLoaded), DATA_LOAD_CHECK_INTERVAL); @@ -230,7 +238,6 @@ // if dictionary and theme data loaded setup UI if(_dictionaryLoaded && _themeLoaded) { clearInterval(_DataLoadCheckIntervalID); - setupUI(); checkUILoaded(); @@ -324,6 +331,8 @@ break; default: } + + loader.complete(); //If all of them are loaded set UILoad accordingly if(_toolkitLoaded && _canvasLoaded && _menuLoaded && _toolbarLoaded){ @@ -390,7 +399,7 @@ //Create screen elements _dialogueContainer_mc = _container_mc.createEmptyMovieClip('_dialogueContainer_mc',DIALOGUE_DEPTH); _tooltipContainer_mc = _container_mc.createEmptyMovieClip('_tooltipContainer_mc',TOOLTIP_DEPTH); - _cursorContainer_mc = _container_mc.createEmptyMovieClip('_cursorContainer_mc',CURSOR_DEPTH); + _cursorContainer_mc = _container_mc.createEmptyMovieClip('_cursorContainer_mc',CURSOR_DEPTH); _toolbarContainer_mc = _container_mc.createEmptyMovieClip('_toolbarContainer_mc',TOOLBAR_DEPTH); _pi_mc = _container_mc.createEmptyMovieClip('_pi_mc',PI_DEPTH); @@ -427,14 +436,17 @@ * work with the application */ private function start(){ - //TODO: Remove the loading screen //Fire off a resize to set up sizes onResize(); - //TODO Remove loading screen + + //Remove the loading screen + loader.stop(); + if(SHOW_DEBUGGER){ showDebugger(); } + } /** @@ -487,7 +499,7 @@ //Canvas _toolkit.setSize(_toolkit.width,h-TOOLKIT_Y); _canvas.setSize(w-_toolkit.width,h-(CANVAS_Y+_canvas.model.getPIHeight())); - //Toolbar + //Toolbar _toolbar.setSize(w, TOOLBAR_HEIGHT); //Property Inspector _pi_mc.setSize(w-_toolkit.width,_pi_mc._height) @@ -733,4 +745,5 @@ } } + } \ No newline at end of file Index: lams_central/src/flash/org/lamsfoundation/lams/monitoring/Application.as =================================================================== diff -u -ra1bdcc85010af16ec86cc4c303829cdfb58769af -r0c2b50ae32b1ba09e4c921e0b711d010e71d5541 --- lams_central/src/flash/org/lamsfoundation/lams/monitoring/Application.as (.../Application.as) (revision a1bdcc85010af16ec86cc4c303829cdfb58769af) +++ lams_central/src/flash/org/lamsfoundation/lams/monitoring/Application.as (.../Application.as) (revision 0c2b50ae32b1ba09e4c921e0b711d010e71d5541) @@ -87,6 +87,8 @@ private static var Z_KEY:Number = 90; private static var Y_KEY:Number = 89; + private static var COMPONENT_NO = 5; + private var _uiLoadCheckCount = 0; // instance counter for number of times we have checked to see if theme and dict are loaded private var _dataLoadCheckCount = 0; @@ -163,6 +165,8 @@ _container_mc = container_mc; _UILoaded = false; + loader.start(COMPONENT_NO); + //add the cursors: Cursor.addCursor(C_HOURGLASS); //Cursor.addCursor(C_OPTIONAL); @@ -194,7 +198,8 @@ private function configLoaded(){ //Now that the config class is ready setup the UI and data, call to setupData() first in //case UI element constructors use objects instantiated with setupData() - setupData(); + loader.complete(); + setupData(); checkDataLoaded(); } @@ -352,6 +357,8 @@ break; default: } + + loader.complete(); //If all of them are loaded set UILoad accordingly if(_menuLoaded && _monitorLoaded){ @@ -456,15 +463,16 @@ * work with the application */ private function start(){ - //TODO: Remove the loading screen //Fire off a resize to set up sizes onResize(); - //TODO Remove loading screen + + // Remove the loading screen + loader.stop(); + if(SHOW_DEBUGGER){ showDebugger(); } - } /** Index: lams_central/src/flash/org/lamsfoundation/lams/wizard/Application.as =================================================================== diff -u -rb5e3682859b7a1ad0cc04297c55ccc1f24ec3d0c -r0c2b50ae32b1ba09e4c921e0b711d010e71d5541 --- lams_central/src/flash/org/lamsfoundation/lams/wizard/Application.as (.../Application.as) (revision b5e3682859b7a1ad0cc04297c55ccc1f24ec3d0c) +++ lams_central/src/flash/org/lamsfoundation/lams/wizard/Application.as (.../Application.as) (revision 0c2b50ae32b1ba09e4c921e0b711d010e71d5541) @@ -51,6 +51,7 @@ private static var WIZARD_W:Number = 584; private static var WIZARD_H:Number = 550; + private static var LOADING_ROOT_DEPTH:Number = 1000; //depth of the loading movie private static var APP_ROOT_DEPTH:Number = 10; //depth of the application root private static var DIALOGUE_DEPTH:Number = 20; //depth of the cursors private static var TOOLTIP_DEPTH:Number = 30; //depth of the cursors @@ -70,7 +71,7 @@ private static var Z_KEY:Number = 90; private static var Y_KEY:Number = 89; - + private static var COMPONENT_NO = 3; private var _uiLoadCheckCount = 0; // instance counter for number of times we have checked to see if theme and dict are loaded private var _dataLoadCheckCount = 0; @@ -138,6 +139,8 @@ _container_mc = container_mc; _UILoaded = false; + loader.start(COMPONENT_NO); + //add the cursors: Cursor.addCursor(C_HOURGLASS); @@ -165,7 +168,9 @@ private function configLoaded(){ //Now that the config class is ready setup the UI and data, call to setupData() first in //case UI element constructors use objects instantiated with setupData() - setupData(); + + loader.complete(); + setupData(); checkDataLoaded(); } @@ -314,6 +319,8 @@ default: } + loader.complete(); + //If all of them are loaded set UILoad accordingly if(_wizardLoaded){ _UILoaded=true; @@ -396,15 +403,16 @@ * work with the application */ private function start(){ - //TODO: Remove the loading screen //Fire off a resize to set up sizes onResize(); - //TODO Remove loading screen + + //Remove the loading screen + loader.stop(); + if(SHOW_DEBUGGER){ showDebugger(); } - } /** Index: lams_central/web/lams_authoring.swf =================================================================== diff -u -reba22b54ee5171a08a2002f3942682348bb03067 -r0c2b50ae32b1ba09e4c921e0b711d010e71d5541 Binary files differ