示例#1
0
 public void OnTextViewCreated(TextView view)
 {
     if (this._control is CodeBehindView)
     {
         if (this._codeTextControlHost == null)
         {
             IDocumentDesignerHost service = this._serviceProvider.GetService(typeof(IDocumentDesignerHost)) as IDocumentDesignerHost;
             IDocumentWithCode document = service.Document as IDocumentWithCode;
             if (document.Code != null)
             {
                 ITextLanguage language = document.Code.Language;
                 this._codeTextControlHost = language.GetTextControlHost(this._control, this._serviceProvider);
             }
         }
         if (this._codeTextControlHost != null)
         {
             this._codeTextControlHost.OnTextViewCreated(view);
         }
     }
     else if (this._control is WebFormsSourceView)
     {
         this.HandlerList.Add(new BlockIndentTextViewCommandHandler(view));
         this.HandlerList.Add(new WebFormsTextViewCommandHandler(view));
     }
     else if (this._control is WebFormsAllView)
     {
         this.HandlerList.Add(new BlockIndentTextViewCommandHandler(view));
     }
 }
 public PlainTextViewCommandHandler(TextView view, TextBuffer buffer)
 {
     this._view = view;
     this._buffer = buffer;
     this._newLineTextList = new ArrayList(2);
     this._newLineTextList.Add(new char[0]);
     this._newLineTextList.Add(new char[0]);
 }
示例#3
0
 public void OnTextViewCreated(TextView view)
 {
     if (this._codeTextControlHost == null)
     {
         IDocumentDesignerHost service = this._serviceProvider.GetService(typeof(IDocumentDesignerHost)) as IDocumentDesignerHost;
         IDocumentWithCode document = service.Document as IDocumentWithCode;
         if (document.Code != null)
         {
             ITextLanguage language = document.Code.Language;
             if (language != null)
             {
                 this._codeTextControlHost = language.GetTextControlHost(this._control, this._serviceProvider);
             }
         }
     }
     if (this._codeTextControlHost != null)
     {
         this._codeTextControlHost.OnTextViewCreated(view);
     }
 }
 public void OnTextViewCreated(TextView view)
 {
     this.HandlerList.Add(new BlockIndentTextViewCommandHandler(view));
     this.HandlerList.Add(new VisualBasicTextViewCommandHandler(view));
 }
 public void Dispose()
 {
     this._view = null;
 }
 public void Dispose()
 {
     this._view.RemoveCommandHandler(this._nextHandler);
     this._view = null;
 }
 public VisualBasicTextViewCommandHandler(TextView view)
 {
     this._view = view;
     this._nextHandler = view.AddCommandHandler(this);
 }
 public HtmlTextViewCommandHandler(TextView view)
 {
     this._view = view;
     this._nextHandler = view.AddCommandHandler(this);
 }
 public BlockIndentTextViewCommandHandler(TextView view)
 {
     this._view = view;
     this._nextHandler = view.AddCommandHandler(this);
 }
 public JSharpTextViewCommandHandler(TextView view)
 {
     this._view = view;
     this._textList = new ArrayList();
     this._nextHandler = view.AddCommandHandler(this);
 }
示例#11
0
 public TextViewEventArgs(TextView view)
 {
     this._view = view;
 }
 public WebFormsTextViewCommandHandler(TextView view)
 {
     this._view = view;
     this._nextHandler = view.AddCommandHandler(this);
 }