Наследование: IRHistory
Пример #1
0
 public IRHistory CreateRHistory(IRInteractiveWorkflow interactiveWorkflow) {
     var contentType = _contentTypeRegistryService.GetContentType(RHistoryContentTypeDefinition.ContentType);
     var textBuffer = _textBufferFactory.CreateTextBuffer(contentType);
     var history = new RHistory(interactiveWorkflow, textBuffer, new FileSystem(), _settings, _editorOperationsFactory, _rtfBuilderService, () => RemoveRHistory(textBuffer));
     _histories[textBuffer] = history;
     return history;
 }
Пример #2
0
        public IRHistory CreateRHistory(IRInteractiveWorkflow interactiveWorkflow)
        {
            var textBuffer = _textBufferFactory.CreateTextBuffer(_contentType);
            var history    = new RHistory(interactiveWorkflow, textBuffer, _fileSystem, _settings, _editorOperationsFactory, _rtfBuilderService, () => RemoveRHistory(textBuffer));

            _histories[textBuffer] = history;
            return(history);
        }
Пример #3
0
        public IRHistory CreateRHistory(IRInteractiveWorkflowVisual interactiveWorkflow)
        {
            var contentType = _contentTypeRegistryService.GetContentType(RHistoryContentTypeDefinition.ContentType);
            var textBuffer  = _textBufferFactory.CreateTextBuffer(contentType);
            var history     = new RHistory(interactiveWorkflow, textBuffer, _fs, _settings, _editorOperationsFactory, _rtfBuilderService, () => RemoveRHistory(textBuffer));

            _histories[textBuffer] = history;
            return(history);
        }
Пример #4
0
        public void AddToHistory(string[] inputs, string expected) {
            var history = new RHistory(_interactiveWorkflow, _textBuffer, null, new RSettingsStub(), null, null, () => { });

            foreach (var input in inputs) {
                history.AddToHistory(input);
            }

            _textBuffer.CurrentSnapshot.GetText().Should().Be(expected);
        }
 public RangeEntrySelector(RHistory history, bool isUp)
 {
     _history = history;
     _isUp    = isUp;
 }
Пример #6
0
        public void SelectHistoryEntry(bool isMultiline, string[] inputs, int lineToSelect, string expected) {
            var settings = new RSettingsStub { MultilineHistorySelection = isMultiline };
            var history = new RHistory(_interactiveWorkflow, _textBuffer, null, settings, null, null, () => { });

            foreach (var input in inputs) {
                history.AddToHistory(input);
            }

            history.SelectHistoryEntry(lineToSelect);

            history.GetSelectedText().Should().Be(expected);
            history.GetSelectedHistoryEntrySpans().Should().ContainSingle()
                .Which.GetText().Should().Be(expected);
        }
 public SingleEntrySelector(RHistory history, bool isReversed)
 {
     _history    = history;
     _isReversed = isReversed;
 }
Пример #8
0
 public IRHistory CreateRHistory(IRInteractiveWorkflow interactiveWorkflow) {
     var textBuffer = _textBufferFactory.CreateTextBuffer(_contentType);
     var history = new RHistory(interactiveWorkflow, textBuffer, _fileSystem, _settings, _editorOperationsFactory, _rtfBuilderService, () => RemoveRHistory(textBuffer));
     _histories[textBuffer] = history;
     return history;
 }