コード例 #1
0
        public RHistoryViewModelTest(IServiceContainer services, ContainerHostMethodFixture containerHost)
        {
            _containerHost = containerHost;
            _history       = (IRHistoryVisual)services.GetService <IRInteractiveWorkflowVisualProvider>().GetOrCreate().History;

            var containerFactory = services.GetService <IRHistoryVisualComponentContainerFactory>();

            _historyVisualComponent = UIThreadHelper.Instance.Invoke(() => _history.GetOrCreateVisualComponent(containerFactory));
        }
コード例 #2
0
        public SendHistoryToSourceCommand(ITextView textView, IRHistoryProvider historyProvider, IRInteractiveWorkflowVisual interactiveWorkflow, IContentTypeRegistryService contentTypeRegistry, IActiveWpfTextViewTracker textViewTracker)
            : base(textView, RGuidList.RCmdSetGuid, RPackageCommandId.icmdSendHistoryToSource, false)
        {
            _textViewTracker     = textViewTracker;
            _interactiveWorkflow = interactiveWorkflow;
            _history             = historyProvider.GetAssociatedRHistory(textView);

            _contentTypes.Add(contentTypeRegistry.GetContentType(RContentTypeDefinition.ContentType));
            _contentTypes.Add(contentTypeRegistry.GetContentType(MdProjectionContentTypeDefinition.ContentType));
        }
コード例 #3
0
ファイル: RHistoryFiltering.cs プロジェクト: skrutsick/RTVS
        public RHistoryFiltering(IRHistoryVisual history, IRHistoryWindowVisualComponent visualComponent, IRSettings settings, ITextSearchService2 textSearchService)
        {
            _history = history;
            _history.HistoryChanging += HistoryChanging;
            _history.HistoryChanged  += HistoryChanged;

            _settings          = settings;
            _textSearchService = textSearchService;
            _textView          = visualComponent.TextView;
            _textBuffer        = _textView.TextDataModel.DataBuffer;

            IElisionBuffer elisionBuffer;

            _textView.TextViewModel.Properties.TryGetProperty(IntraTextAdornmentBufferKey, out elisionBuffer);
            _elisionBuffer = elisionBuffer;
        }
コード例 #4
0
        public HistorySelectionTextAdornment(IWpfTextView textView, IEditorFormatMapService editorFormatMapService, IRHistoryProvider historyProvider)
        {
            _textView = textView;
            _layer    = textView.GetAdornmentLayer("HistorySelectionTextAdornment");

            _editorFormatMap = editorFormatMapService.GetEditorFormatMap(_textView);
            _history         = historyProvider.GetAssociatedRHistory(_textView);

            // Advise to events
            _editorFormatMap.FormatMappingChanged     += OnFormatMappingChanged;
            _textView.VisualElement.GotKeyboardFocus  += OnGotKeyboardFocus;
            _textView.VisualElement.LostKeyboardFocus += OnLostKeyboardFocus;
            _textView.LayoutChanged   += OnLayoutChanged;
            _textView.Closed          += OnClosed;
            _history.SelectionChanged += OnSelectionChanged;

            _activeVisualToolset   = CreateVisualToolset(ActiveSelectionPropertiesName, SystemColors.HighlightColor);
            _inactiveVisualToolset = CreateVisualToolset(InactiveSelectionPropertiesName, SystemColors.GrayTextColor);
            Redraw();
        }
コード例 #5
0
 public HistoryWindowPaneMouseProcessor(IRHistoryVisual history)
 {
     _history = history;
 }