]> jspc29.x-matter.uni-frankfurt.de Git - daqtools.git/commitdiff
Chagen CTS GUI js to work in Chrome
authorJan Michel <j.michel@gsi.de>
Tue, 20 Sep 2016 11:22:22 +0000 (13:22 +0200)
committerJan Michel <j.michel@gsi.de>
Tue, 20 Sep 2016 11:22:38 +0000 (13:22 +0200)
web/htdocs/scripts/cts.js

index 5bb59aab2bbbf573f470d49ea414952306a84293..453dd2bc1824524fe17105f60a1c934f7da770c7 100644 (file)
@@ -95,6 +95,25 @@ var CTS = new Class({
       this.initAutoUpdate();
       this.dataUpdate();
       
+/* Flash groups */
+      $$('*[flashgroup]').addEvents({
+          'mouseenter': function(e) {
+            var t = $(e.target);
+
+            while(!t.get('flashgroup')) {
+                if (t.get('id') == 'content-area') return;
+                t = t.getParent();
+            }
+
+            $$('*[flashgroup="' + t.get('flashgroup') + '"]').addClass('flash');
+          }, 
+          
+          'mouseleave': function(e) {
+            $$('.flash').removeClass('flash');
+          }
+      });
+    
+      
       $('rate-plot').set('src', this.monitorPrefix + 'plot.png');
       this.addEvent('dataUpdate', function() {
          $('rate-plot').set('src', $('rate-plot').get('src').split('?')[0] + "?" + new Date().getTime());
@@ -1039,24 +1058,7 @@ window.addEvent('load', function() {
    window.addEvent('resize', caption.reposition);
 });
    
-/* Flash groups */
-window.addEvent('load', function() {
-   $$('*[flashgroup]').addEvents({
-      'mouseenter': function(e) {
-         var t = $(e.target);
-         while(!t.get('flashgroup')) {
-            if (t.get('id') == 'content-area') return;
-            t = t.getParent();
-         }
-         
-         $$('*[flashgroup="' + t.get('flashgroup') + '"]').addClass('flash');
-      }, 
-      
-      'mouseleave': function(e) {
-         $$('.flash').removeClass('flash');
-      }
-   });
-});
+
 
 function id(x) {return x;}