1
// Copyright (c) AlphaSierraPapa for the SharpDevelop Team (for details please see \doc\copyright.txt)
2
// This code is distributed under the GNU LGPL (for details please see \doc\license.txt)
5
using ICSharpCode.SharpDevelop;
6
using ICSharpCode.SharpDevelop.Editor;
7
using ICSharpCode.SharpDevelop.Gui;
9
namespace ICSharpCode.WixBinding
11
public class WixDialogDesignerDisplayBinding : ISecondaryDisplayBinding
13
public WixDialogDesignerDisplayBinding()
17
public bool ReattachWhenParserServiceIsReady {
22
/// Wix dialog designer can attach to Wix source files (.wxs) and
23
/// Wix include files (.wxi).
25
public bool CanAttachTo(IViewContent view)
27
if (IsViewTextEditorProvider(view)) {
28
return WixFileName.IsWixFileName(view.PrimaryFileName);
33
public IViewContent[] CreateSecondaryViewContent(IViewContent view)
35
return new IViewContent[] {new WixDialogDesigner(view)};
38
bool IsViewTextEditorProvider(IViewContent view)
40
ITextEditorProvider textEditorProvider = view as ITextEditorProvider;
41
return textEditorProvider != null;