void OnUpdateUI(object sender, EventArgs e) { Command command = CreateCommand(); if (command != null) { CommandButtonUIState state = new CommandButtonUIState(this); command.UpdateUIState(state); } }
void OnUpdateUI(object sender, EventArgs e) { if (button == null) { return; } Command command = CreateCommand(); if (command != null) { CommandButtonUIState state = new CommandButtonUIState(button); command.UpdateUIState(state); } }