public void NotifyDestinationFound(CurrentDestinationName destinationName) { if (destinationName == currentDestination) { ChangeCurrentDestination(); UpdateDestination(); } }
private void ChangeCurrentDestination() { int currentIndex = (((int)currentDestination) + 1) % Enum.GetValues(typeof(CurrentDestinationName)).Length; currentDestination = (CurrentDestinationName)currentIndex; }