示例#1
0
            private void OnSourceBuffersChanged(object sender, ProjectionSourceBuffersChangedEventArgs e)
            {
                BufferGraph targetGraph = this.GetTargetGraph();

                if (targetGraph != null)
                {
                    targetGraph.SourceBuffersChanged(sender, e);
                }
            }
示例#2
0
            private void OnSourceBufferContentTypeChanged(object sender, ContentTypeChangedEventArgs e)
            {
                BufferGraph targetGraph = this.GetTargetGraph();

                if (targetGraph != null)
                {
                    targetGraph.ContentTypeChanged(sender, e);
                }
            }
示例#3
0
            public WeakEventHookForBufferGraph(BufferGraph targetGraph, ITextBuffer sourceBuffer)
            {
                _targetGraph  = new WeakReference <BufferGraph>(targetGraph);
                _sourceBuffer = sourceBuffer;

                sourceBuffer.ContentTypeChanged += OnSourceBufferContentTypeChanged;
                ProjectionBuffer projectionBuffer = sourceBuffer as ProjectionBuffer;

                if (projectionBuffer != null)
                {
                    projectionBuffer.SourceBuffersChangedImmediate += OnSourceBuffersChanged;
                }
            }
示例#4
0
 public GraphEventRaiser(BufferGraph graph, GraphBuffersChangedEventArgs args)
 {
     this.graph = graph;
     this.args  = args;
 }