Browse Source

helios:
- adds a loader on page load
- changes the inspector label

Nicolas Petton 11 years ago
parent
commit
b172463a0c

+ 4 - 2
helios.html

@@ -14,8 +14,10 @@
   </head> 
   <body> 
     
-    <script type='text/javascript'> loadAmber({packages: ['Spaces', 'Helios-Core', 'Helios-Commands-Core','Helios-Commands-Browser', 'Helios-Layout','Helios-KeyBindings', 'Helios-Browser', 'Helios-Workspace', 'Helios-Inspector', 'Helios-Announcements']}) </script> 
-    <link rel="stylesheet" type="text/css" href='css/helios.css' /> 
+    <script type='text/javascript'> loadAmber({packages: ['Spaces', 'Helios-Core', 'Helios-Commands-Core','Helios-Commands-Browser', 'Helios-Layout','Helios-KeyBindings', 'Helios-Browser', 'Helios-Workspace', 'Helios-Inspector', 'Helios-Announcements']}) </script>
+    <link rel="stylesheet" type="text/css" href='css/helios.css' />
     
+    <div id="helper">Loading Helios...</div>
+
   </body> 
 </html> 

+ 2 - 4
js/Helios-Inspector.deploy.js

@@ -347,11 +347,9 @@ selector: "tabLabel",
 fn: function (){
 var self=this;
 return smalltalk.withContext(function($ctx1) { 
-var $1;
-$1=_st(self)._label();
-return $1;
+return "Inspector";
 }, function($ctx1) {$ctx1.fill(self,"tabLabel",{},smalltalk.HLInspector)})},
-messageSends: ["label"]}),
+messageSends: []}),
 smalltalk.HLInspector);
 
 smalltalk.addMethod(

+ 3 - 5
js/Helios-Inspector.js

@@ -468,13 +468,11 @@ category: 'accessing',
 fn: function (){
 var self=this;
 return smalltalk.withContext(function($ctx1) { 
-var $1;
-$1=_st(self)._label();
-return $1;
+return "Inspector";
 }, function($ctx1) {$ctx1.fill(self,"tabLabel",{},smalltalk.HLInspector)})},
 args: [],
-source: "tabLabel\x0a    ^ self label",
-messageSends: ["label"],
+source: "tabLabel\x0a    ^ 'Inspector'",
+messageSends: [],
 referencedClasses: []
 }),
 smalltalk.HLInspector);

+ 2 - 1
js/Helios-KeyBindings.deploy.js

@@ -1360,6 +1360,7 @@ fn: function (){
 var self=this;
 return smalltalk.withContext(function($ctx1) { 
 var $1,$2;
+_st(_st(window)._jQuery_("#helper"))._remove();
 _st((function(html){
 return smalltalk.withContext(function($ctx2) {
 $1=_st(html)._div();
@@ -1372,7 +1373,7 @@ return smalltalk.withContext(function($ctx2) {
 return _st(_st(window)._jQuery_("#helper"))._fadeOut_((1000));
 }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}))._valueWithTimeout_((2000));
 return self}, function($ctx1) {$ctx1.fill(self,"renderStart",{},smalltalk.HLKeyBinderHelper)})},
-messageSends: ["appendToJQuery:", "asJQuery", "id:", "div", "with:", ",", "activationKeyLabel", "keyBinder", "valueWithTimeout:", "fadeOut:", "jQuery:"]}),
+messageSends: ["remove", "jQuery:", "appendToJQuery:", "asJQuery", "id:", "div", "with:", ",", "activationKeyLabel", "keyBinder", "valueWithTimeout:", "fadeOut:"]}),
 smalltalk.HLKeyBinderHelper);
 
 smalltalk.addMethod(

+ 3 - 2
js/Helios-KeyBindings.js

@@ -1791,6 +1791,7 @@ fn: function (){
 var self=this;
 return smalltalk.withContext(function($ctx1) { 
 var $1,$2;
+_st(_st(window)._jQuery_("#helper"))._remove();
 _st((function(html){
 return smalltalk.withContext(function($ctx2) {
 $1=_st(html)._div();
@@ -1804,8 +1805,8 @@ return _st(_st(window)._jQuery_("#helper"))._fadeOut_((1000));
 }, function($ctx2) {$ctx2.fillBlock({},$ctx1)})}))._valueWithTimeout_((2000));
 return self}, function($ctx1) {$ctx1.fill(self,"renderStart",{},smalltalk.HLKeyBinderHelper)})},
 args: [],
-source: "renderStart\x0a\x09[ :html |\x0a\x09\x09html div \x0a\x09\x09\x09id: 'helper';\x0a\x09\x09\x09with: 'Press ', self keyBinder activationKeyLabel, ' to start' ] appendToJQuery: 'body' asJQuery.\x0a\x09\x0a\x09[ (window jQuery: '#helper') fadeOut: 1000 ] \x0a\x09\x09valueWithTimeout: 2000",
-messageSends: ["appendToJQuery:", "asJQuery", "id:", "div", "with:", ",", "activationKeyLabel", "keyBinder", "valueWithTimeout:", "fadeOut:", "jQuery:"],
+source: "renderStart\x0a\x09(window jQuery: '#helper') remove.\x0a\x0a\x09[ :html |\x0a\x09\x09html div \x0a\x09\x09\x09id: 'helper';\x0a\x09\x09\x09with: 'Press ', self keyBinder activationKeyLabel, ' to start' ] appendToJQuery: 'body' asJQuery.\x0a\x09\x0a\x09[ (window jQuery: '#helper') fadeOut: 1000 ] \x0a\x09\x09valueWithTimeout: 2000",
+messageSends: ["remove", "jQuery:", "appendToJQuery:", "asJQuery", "id:", "div", "with:", ",", "activationKeyLabel", "keyBinder", "valueWithTimeout:", "fadeOut:"],
 referencedClasses: []
 }),
 smalltalk.HLKeyBinderHelper);

+ 4 - 4
js/Kernel-Objects.deploy.js

@@ -1821,13 +1821,13 @@ smalltalk.method({
 selector: "systemAnnouncer",
 fn: function (){
 var self=this;
-function $SystemAnnouncer(){return smalltalk.SystemAnnouncer||(typeof SystemAnnouncer=="undefined"?nil:SystemAnnouncer)}
+function $Smalltalk(){return smalltalk.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
 return smalltalk.withContext(function($ctx1) { 
 var $1;
-$1=_st($SystemAnnouncer())._current();
+$1=_st(_st(_st($Smalltalk())._current())._at_("SystemAnnouncer"))._current();
 return $1;
-}, function($ctx1) {$ctx1.fill(self,"systemAnnouncer",{},smalltalk.HLEnvironment)})},
-messageSends: ["current"]}),
+}, function($ctx1) {$ctx1.fill(self,"systemAnnouncer",{},smalltalk.Environment)})},
+messageSends: ["current", "at:"]}),
 smalltalk.Environment);
 
 

+ 6 - 6
js/Kernel-Objects.js

@@ -2516,16 +2516,16 @@ selector: "systemAnnouncer",
 category: 'accessing',
 fn: function (){
 var self=this;
-function $SystemAnnouncer(){return smalltalk.SystemAnnouncer||(typeof SystemAnnouncer=="undefined"?nil:SystemAnnouncer)}
+function $Smalltalk(){return smalltalk.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
 return smalltalk.withContext(function($ctx1) { 
 var $1;
-$1=_st($SystemAnnouncer())._current();
+$1=_st(_st(_st($Smalltalk())._current())._at_("SystemAnnouncer"))._current();
 return $1;
-}, function($ctx1) {$ctx1.fill(self,"systemAnnouncer",{},smalltalk.HLEnvironment)})},
+}, function($ctx1) {$ctx1.fill(self,"systemAnnouncer",{},smalltalk.Environment)})},
 args: [],
-source: "systemAnnouncer\x0a\x09^ SystemAnnouncer current",
-messageSends: ["current"],
-referencedClasses: ["SystemAnnouncer"]
+source: "systemAnnouncer\x0a\x09^ (Smalltalk current at: #SystemAnnouncer) current",
+messageSends: ["current", "at:"],
+referencedClasses: ["Smalltalk"]
 }),
 smalltalk.Environment);
 

+ 1 - 1
st/Helios-Inspector.st

@@ -49,7 +49,7 @@ model: aModel
 !
 
 tabLabel
-    ^ self label
+    ^ 'Inspector'
 !
 
 variablesWidget

+ 2 - 0
st/Helios-KeyBindings.st

@@ -568,6 +568,8 @@ renderSelectionOn: html
 !
 
 renderStart
+	(window jQuery: '#helper') remove.
+
 	[ :html |
 		html div 
 			id: 'helper';