equal
deleted
inserted
replaced
|
1 |
|
2 $( window ).ready( function() { |
|
3 if ( D.getBoolPref('fullscreen') ) D.window.main.setFullscreen( true ); |
|
4 |
|
5 // If we're in development mode, just display the main window, |
|
6 // the inpector, and stop here. |
|
7 // |
|
8 if ( D.getBoolPref('devmode') ) { |
|
9 D.window.main.showInspector( true ); |
|
10 return; |
|
11 } |
|
12 |
|
13 // "Regular" behavior. Hide the main window, show splash. |
|
14 // |
|
15 if ( ! D.getBoolPref('hidesplash') ) { |
|
16 D.window.main.hide(); |
|
17 D.window.splash = D.window.main.createWindow( 'app://window/splash.html' ); |
|
18 D.window.splash.setTopMost( true ); |
|
19 D.window.splash.open(); |
|
20 } |
|
21 |
|
22 var server_uri = D.getPref( 'server_uri' ); |
|
23 if ( server_uri ) D.checkServer( server_uri ); |
|
24 |
|
25 |
|
26 // Show the main window after a few moments. |
|
27 // |
|
28 D.delay(function() { |
|
29 if ( ! D.getBoolPref('hidesplash') ) { |
|
30 D.window.main.show(); |
|
31 D.window.splash.close(); |
|
32 } |
|
33 |
|
34 // Throw up the prefs window if this is the first time. |
|
35 // |
|
36 if ( D.firstrun ) { |
|
37 D.window.prefs = D.window.main.createWindow( 'app://window/prefs.html#server' ); |
|
38 D.window.prefs.open(); |
|
39 D.notify( 'Initial setup', 'Please point me to a Thingfish server!' ); |
|
40 } |
|
41 }, 3000 ); |
|
42 }); |
|
43 |