onMaterialDispose method
Implementation
void onMaterialDispose(Event event) {
var material = event.target;
material.removeEventListener('dispose', onMaterialDispose);
deallocateMaterial(material);
}
void onMaterialDispose(Event event) {
var material = event.target;
material.removeEventListener('dispose', onMaterialDispose);
deallocateMaterial(material);
}