Ejemplo n.º 1
0
 protected virtual void OnShifterStateChanged(ShifterState shifterState)
 {
     var shifterStateChanged = _shifterStateChanged;
     if (null != shifterStateChanged)
     {
         shifterStateChanged(shifterState);
     }
 }
Ejemplo n.º 2
0
 public virtual void ToggleShifter()
 {
     switch (ShifterState)
     {
         case ShifterState.On:
             ShifterState = ShifterState.Off;
             break;
         case ShifterState.Off:
             ShifterState = ShifterState.On;
             break;
         default:
             throw new ArgumentOutOfRangeException();
     }
 }
Ejemplo n.º 3
0
        private void ManageVisibility(ShifterState state)
        {
            switch (state)
            {
                case ShifterState.On:
                    Console.WriteLine("ContentFormPresenter.ManageVisibility(visible)");
                    break;
                case ShifterState.Off:
                    Console.WriteLine("ContentFormPresenter.ManageVisibility(invisible)");

                    CleanUp();
                    break;
                default:
                    throw new ArgumentOutOfRangeException("state");
            }
        }
Ejemplo n.º 4
0
 public virtual void SetShifterState(ShifterState state)
 {
     Checked = ShifterState.On == state;
 }
Ejemplo n.º 5
0
 private void ManageFormSubsystem(ShifterState state)
 {
     switch (state)
     {
         case ShifterState.On:
             ConstructSystem();
             break;
         case ShifterState.Off:
             DestroySystem();
             break;
         default:
             throw new ArgumentOutOfRangeException("state");
     }
 }
Ejemplo n.º 6
0
 protected void SetButtonShifterState(ShifterState state)
 {
     _view.SetShifterState(state);
 }
Ejemplo n.º 7
0
 public void SetShifterState(ShifterState shifterState)
 {
     m_checked = ShifterState.On == shifterState;
 }