public static NodeTabSaver TryCreate(IFileTreeNodeDecompiler fileTreeNodeDecompiler, IFileTab tab, IMessageBoxManager messageBoxManager) { if (tab.IsAsyncExecInProgress) { return(null); } var uiContext = tab.UIContext as IDocumentViewer; if (uiContext == null) { return(null); } var decompiler = (tab.Content as IDecompilerTabContent)?.Decompiler; if (decompiler == null) { return(null); } var nodes = tab.Content.Nodes.ToArray(); if (nodes.Length == 0) { return(null); } return(new NodeTabSaver(messageBoxManager, tab, fileTreeNodeDecompiler, decompiler, uiContext, nodes)); }
DecompileFileTabContentFactory(IFileManager fileManager, IFileTreeNodeDecompiler fileTreeNodeDecompiler, ILanguageManager languageManager, IDecompilationCache decompilationCache, IMethodAnnotations methodAnnotations) { this.fileManager = fileManager; this.fileTreeNodeDecompiler = fileTreeNodeDecompiler; this.languageManager = languageManager; this.decompilationCache = decompilationCache; this.methodAnnotations = methodAnnotations; }
public static NodeTabSaver TryCreate(IFileTreeNodeDecompiler fileTreeNodeDecompiler, IFileTab tab, IMessageBoxManager messageBoxManager) { if (tab.IsAsyncExecInProgress) { return(null); } var uiContext = tab.UIContext as ITextEditorUIContext; if (uiContext == null) { return(null); } var langContent = tab.Content as ILanguageTabContent; var lang = langContent == null ? null : langContent.Language; if (lang == null) { return(null); } var nodes = tab.Content.Nodes.ToArray(); if (nodes.Length == 0) { return(null); } return(new NodeTabSaver(messageBoxManager, tab, fileTreeNodeDecompiler, lang, uiContext, nodes)); }
NodeTabSaver(IMessageBoxManager messageBoxManager, IFileTab tab, IFileTreeNodeDecompiler fileTreeNodeDecompiler, IDecompiler decompiler, IDocumentViewer documentViewer, IFileTreeNodeData[] nodes) { this.messageBoxManager = messageBoxManager; this.tab = tab; this.fileTreeNodeDecompiler = fileTreeNodeDecompiler; this.decompiler = decompiler; this.documentViewer = documentViewer; this.nodes = nodes; }
NodeTabSaver(IMessageBoxManager messageBoxManager, IFileTab tab, IFileTreeNodeDecompiler fileTreeNodeDecompiler, ILanguage language, ITextEditorUIContext uiContext, IFileTreeNodeData[] nodes) { this.messageBoxManager = messageBoxManager; this.tab = tab; this.fileTreeNodeDecompiler = fileTreeNodeDecompiler; this.language = language; this.uiContext = uiContext; this.nodes = nodes; }
DecompileFileTabContentFactory(IFileManager fileManager, IFileTreeNodeDecompiler fileTreeNodeDecompiler, ILanguageManager languageManager, IDecompilationCache decompilationCache, IMethodAnnotations methodAnnotations, IContentTypeRegistryService contentTypeRegistryService, [ImportMany] IEnumerable <Lazy <IDocumentViewerCustomDataProvider, IDocumentViewerCustomDataProviderMetadata> > documentViewerCustomDataProviders) { this.FileManager = fileManager; this.FileTreeNodeDecompiler = fileTreeNodeDecompiler; this.LanguageManager = languageManager; this.DecompilationCache = decompilationCache; this.MethodAnnotations = methodAnnotations; this.ContentTypeRegistryService = contentTypeRegistryService; this.DocumentViewerCustomDataProviders = documentViewerCustomDataProviders.OrderBy(a => a.Metadata.Order).ToArray(); }
NodeTabSaverProvider(IFileTreeNodeDecompiler fileTreeNodeDecompiler, IMessageBoxManager messageBoxManager) { this.fileTreeNodeDecompiler = fileTreeNodeDecompiler; this.messageBoxManager = messageBoxManager; }
public static NodeTabSaver TryCreate(IFileTreeNodeDecompiler fileTreeNodeDecompiler, IFileTab tab, IMessageBoxManager messageBoxManager) { if (tab.IsAsyncExecInProgress) return null; var uiContext = tab.UIContext as ITextEditorUIContext; if (uiContext == null) return null; var langContent = tab.Content as ILanguageTabContent; var lang = langContent == null ? null : langContent.Language; if (lang == null) return null; var nodes = tab.Content.Nodes.ToArray(); if (nodes.Length == 0) return null; return new NodeTabSaver(messageBoxManager, tab, fileTreeNodeDecompiler, lang, uiContext, nodes); }
NodeTabSaverCreator(IFileTreeNodeDecompiler fileTreeNodeDecompiler, IMessageBoxManager messageBoxManager) { this.fileTreeNodeDecompiler = fileTreeNodeDecompiler; this.messageBoxManager = messageBoxManager; }