View Full Version : Ext.override doesn't always work on all cases.

4 Jul 2012, 10:58 PM
Hi, I have found this issue a couple of times so I found this rather annoying. My current solution is I had to (gulp!) edit the core files directly, I wonder if there is another way to override some classes that just doesn't work with Ext.override.

I found that both Ext.chart.Highlight and Ext.core.Element cannot be overridden.


// Stop charts from animating on mouse over.
Ext.override(Ext.chart.Highlight, {
highlightItem: function(item) {
console.log('this isn't get called');

5 Jul 2012, 11:03 AM
You will need override prototype in cases of element, etc.

Ext.core.Element.prototype.functionToOverride = function ( .. ) { .. }