dispose method

  1. @override
void dispose()
override

Implementation

@override
void dispose() {
  dispatchEvent(Event({"type": "dispose"}));
  if(texture != null){
    texture?.dispose();
  }
}