dispose method

  1. @override
void dispose()
override

Release any resources held by this node.

Implementation

@override
void dispose() {
  super.dispose();
  // If not getContext and element is disposed that context is not existed.
  if (painter.context != null) {
    painter.context!.dispose();
  }
}