Added EventListener for graying corpus statistic(plus renaming)
Change-Id: I41da48f92a9f5abccb6a64a9a4f2c1192e713327
(cherry picked from commit b990f6ad18afb79e10e4c88b505e4429aeaa07e2)
diff --git a/dev/js/src/vc.js b/dev/js/src/vc.js
index af09132..4bc5e13 100644
--- a/dev/js/src/vc.js
+++ b/dev/js/src/vc.js
@@ -367,7 +367,9 @@
*/
update : function() {
this._root.update();
- this.checkGrayingStat();
+ var vcchevent = new CustomEvent('vcChange', {'detail':this});
+ document.dispatchEvent(vcchevent);
+
return this;
},
/**
@@ -485,12 +487,12 @@
},
/**
- * Checks if corpus statistic has to be greyOut,
+ * Checks if corpus statistic has to be disabled,
* and to be updated after clicking at the "reload-button"
*/
- checkGrayingStat : function(){
+ checkStatActive : function(){
if(this.panel !== undefined && this.panel.statView !==undefined){
- this.panel.statView.checkGrayingStatistic();
+ this.panel.statView.checkStatActive();
}
}
};