handleBackgroundModeChanged method

void handleBackgroundModeChanged(
  1. LayerBackgroundMode newMode
)

Handles the background mode change event.

This method calls the onBackgroundModeChanged callback with the provided newMode and then calls handleUpdateUI.

Implementation

void handleBackgroundModeChanged(LayerBackgroundMode newMode) {
  onBackgroundModeChanged?.call(newMode);
  handleUpdateUI();
}