internal CommandMarginController(IVimBuffer buffer, CommandMarginControl control) { _buffer = buffer; _margin = control; _buffer.SwitchedMode += OnSwitchMode; _buffer.KeyInputProcessed += OnKeyInputProcessed; _buffer.KeyInputReceived += OnKeyInputReceived; }
internal CommandMarginController(IVimBuffer buffer, CommandMarginControl control, IEnumerable<Lazy<IOptionsProviderFactory>> optionsProviderFactory) { _buffer = buffer; _margin = control; _optionsProviderFactory = optionsProviderFactory.ToList().AsReadOnly(); _buffer.SwitchedMode += OnSwitchMode; _buffer.KeyInputProcessed += OnKeyInputProcessed; _buffer.KeyInputReceived += OnKeyInputReceived; _buffer.StatusMessage += OnStatusMessage; _buffer.ErrorMessage += OnErrorMessage; _margin.OptionsClicked += OnOptionsClicked; }
internal CommandMarginController(IVimBuffer buffer, CommandMarginControl control, IEnumerable<Lazy<IOptionsProviderFactory>> optionsProviderFactory) { _buffer = buffer; _margin = control; _optionsProviderFactory = optionsProviderFactory.ToList().AsReadOnly(); _buffer.SwitchedMode += OnSwitchMode; _buffer.KeyInputStart += OnKeyInputStart; _buffer.KeyInputEnd += OnKeyInputEnd; _buffer.StatusMessage += OnStatusMessage; _buffer.StatusMessageLong += OnStatusMessageLong; _buffer.ErrorMessage += OnErrorMessage; _buffer.WarningMessage += OnWarningMessage; _buffer.Vim.MacroRecorder.RecordingStarted += delegate { UpdateForRecordingChanged(); }; _buffer.Vim.MacroRecorder.RecordingStopped += delegate { UpdateForRecordingChanged(); }; _margin.OptionsClicked += OnOptionsClicked; UpdateForRecordingChanged(); }
internal CommandMarginController(IVimBuffer buffer, CommandMarginControl control, IEnumerable <Lazy <IOptionsProviderFactory> > optionsProviderFactory) { _buffer = buffer; _margin = control; _optionsProviderFactory = optionsProviderFactory.ToList().AsReadOnly(); _buffer.SwitchedMode += OnSwitchMode; _buffer.KeyInputStart += OnKeyInputStart; _buffer.KeyInputEnd += OnKeyInputEnd; _buffer.StatusMessage += OnStatusMessage; _buffer.StatusMessageLong += OnStatusMessageLong; _buffer.ErrorMessage += OnErrorMessage; _buffer.WarningMessage += OnWarningMessage; _buffer.Vim.MacroRecorder.RecordingStarted += delegate { UpdateForRecordingChanged(); }; _buffer.Vim.MacroRecorder.RecordingStopped += delegate { UpdateForRecordingChanged(); }; _margin.OptionsClicked += OnOptionsClicked; UpdateForRecordingChanged(); }