Пример #1
0
        public RemoteControl()
        {
            int quantity = 7;

            onCommands   = new ICommand[quantity];
            offCommands  = new ICommand[quantity];
            lastCommands = new Stack <ICommand>(10);
            for (int i = 0; i < quantity; i++)
            {
                onCommands[i]  = new NoCommand();
                offCommands[i] = new NoCommand();
            }
        }
Пример #2
0
        public Remote()
        {
            onCommands  = new Command[7];
            offCommands = new Command[7];

            Command noCommand = new NoCommand();

            for (int i = 0; i < 7; i++)
            {
                onCommands[i]  = noCommand;
                offCommands[i] = noCommand;
            }
        }
Пример #3
0
        public Remote()
        {
            _onCommands  = new ICommand[7];
            _offCommands = new ICommand[7];

            ICommand noCommand = new NoCommand();

            for (int i = 0; i < _onCommands.Length; i++)
            {
                _onCommands[i]  = noCommand;
                _offCommands[i] = noCommand;
            }
        }
Пример #4
0
        public RemoteControl()
        {
            onCommands  = new ICommand[Settings.SlotCount];
            offCommands = new ICommand[Settings.SlotCount];
            var noCommand = new NoCommand();

            for (int i = 0; i < Settings.SlotCount; i++)
            {
                onCommands[i]  = noCommand;
                offCommands[i] = noCommand;
            }

            undoCommands = new Stack <ICommand>();
        }
Пример #5
0
        public RemoteControlWithUndo()
        {
            _onCommands  = new ICommand[7];
            _offCommands = new ICommand[7];

            ICommand noCommand = new NoCommand();

            for (int i = 0; i < 7; i++)
            {
                _onCommands[i]  = noCommand;
                _offCommands[i] = noCommand;
            }

            _undoCommand = noCommand;
        }