internal static void InitializeMarkerIds(PlvsPackage package) { #if !VS2010 // Retrieve the Text Marker IDs. We need them to be able to create instances. IVsTextManager textManager = (IVsTextManager)package.GetService(typeof(SVsTextManager)); try { int markerId; Guid markerGuid = GuidList.JiraLinkMarginMarker; textManager.GetRegisteredMarkerTypeID(ref markerGuid, out markerId); JiraLinkMarginMarkerType.Id = markerId; markerGuid = GuidList.JiraLinkTextMarker; textManager.GetRegisteredMarkerTypeID(ref markerGuid, out markerId); JiraLinkTextMarkerType.Id = markerId; } catch (COMException e) { Debug.WriteLine("JiraLinkMarkerTypeProvider.InitializeMarkerids() - COMException: " + e.Message); } #endif }
public int OnAfterOpenSolution(object pUnkReserved, int fNewSolution) { PlvsLogger.log("SolutionEventSink.OnAfterOpenSolution()"); try { GlobalSettings.checkFirstRun(); JiraServerModel.Instance.clear(); JiraServerModel.Instance.load(); BambooServerModel.Instance.clear(); BambooServerModel.Instance.load(); RecentlyViewedIssuesModel.Instance.load(); JiraCustomFilter.load(); DTE dte = (DTE)package.GetService(typeof(DTE)); PlvsUtils.Dte = dte; ToolWindowManager.Instance.AtlassianWindow = createAtlassianWindow(); AtlassianPanel.Instance.reinitialize(dte, package); ToolWindowManager.Instance.IssueDetailsWindow = createIssueDetailsWindow(); ToolWindowManager.Instance.BuildDetailsWindow = createBuildDetailsWindow(); IssueDetailsWindow.Instance.Solution = dte.Solution; BuildDetailsWindow.Instance.Solution = dte.Solution; JiraEditorLinkManager.OnSolutionOpened(); Autoupdate.Instance.initialize(); } catch (Exception e) { Debug.WriteLine(e); new ExceptionViewer("Failed to initialize Atlassian tool windows", e).ShowDialog(); } return(VSConstants.S_OK); }