colorValueChanged method Null safety

  1. @override
void colorValueChanged(
  1. int from,
  2. int to


void colorValueChanged(int from, int to) {
  // Since all we need to do is set the color on the paint, we can just do
  // this whenever it changes as it's such a lightweight operation. We don't
  // need to schedule it for the next update cycle, which saves us from adding
  // SolidColor to the dependencies graph.

  // Since we're not in the dependency tree, chuck dirt onto the shape, which
  // is. This just ensures we'll paint as soon as possible to show the updated
  // color.