File tree Expand file tree Collapse file tree 2 files changed +14
-3
lines changed
Expand file tree Collapse file tree 2 files changed +14
-3
lines changed Original file line number Diff line number Diff line change 5252 $ ( ".modules a" ) . each ( function ( ) {
5353 modules . push ( new ModuleButton ( this , app ) ) ;
5454 } ) ;
55-
56-
57-
5855 }
5956
6057 // Bind reference to the open project handler
8683 {
8784 this . closeProject ( ) ;
8885 }
86+
87+ // Listen for a new project being created
88+ $ ( window ) . on ( 'storage' , function ( event ) {
89+ if ( event . key == 'project' && / n e w \. h t m l / . test ( event . url ) )
90+ {
91+ var project = event . newValue ;
92+ if ( project )
93+ {
94+ console . log ( "New project created " + project ) ;
95+ this . openProject ( project ) ;
96+ }
97+ }
98+ } ) ;
8999 } ;
90100
91101 // Reference to the prototype
Original file line number Diff line number Diff line change 268268 p . _onCompleted = function ( )
269269 {
270270 alert ( this . name . val ( ) + " created successfully" ) ;
271+ localStorage . setItem ( 'project' , this . folder . data ( 'folder' ) ) ;
271272 localStorage . setItem ( 'width' , this . appWidth . val ( ) ) ;
272273 localStorage . setItem ( 'height' , this . appHeight . val ( ) ) ;
273274 localStorage . setItem ( 'namespace' , this . namespace . val ( ) ) ;
You can’t perform that action at this time.
0 commit comments