added some development tools
[windows-sources.git] / developer / VSSDK / VisualStudioIntegration / Common / IDL / IVsSccManager2.idl
blobbe169b02be2b429586f0aa24cacd0dc3a254294a
1 /*-----------------------------------------------------------------------------
2 Copyright (c) Microsoft Corporation. All rights reserved.
4 @doc
5 @module IVsSccManager2.idl - Interface into the Source-Control package |
7 This interface allows projects and hierarchies to register themselves with
8 the source-control package, and obtain information on source-control
9 status.
10 -----------------------------------------------------------------------------*/
11 #if !defined(CTC_INVOKED) && !defined(RGS_INVOKED)
13 cpp_quote("#if _MSC_VER > 1000")
14 cpp_quote("#pragma once")
15 cpp_quote("#endif")
17 //----------------------------
18 // Includes
19 //----------------------------
20 #include "SCGuids.h"
22 //----------------------------
23 // Imports
24 //----------------------------
25 #ifndef INTEROPLIB
27 import "objidl.idl";
28 import "IVsSccProject2.idl";
30 #endif
33 /*-----------------------------------------------------------------------------
34 Interface: IVsSccManager2
36 Projects use this interface to retrieve information from SCC, or to register
37 themselves with SCC.
39 @base public | IUnknown
41 @hung scm2
42 -----------------------------------------------------------------------------*/
43 [ uuid(uuid_IVsSccManager2) ]
44 interface IVsSccManager2 : IUnknown
46 /////////////////////////////////////////////////////////////////////
47 // RegisterSccProject
48 /////////////////////////////////////////////////////////////////////
49 // This method is called by projects that are under source-control.
50 // Projects call this method when they are opened.
52 // The project must pass to this method the same four opaque source-
53 // control strings that were given to it via IVsSccProject2::SetSccLocation
54 // before the project was last closed.
56 HRESULT RegisterSccProject
58 [in] IVsSccProject2 *pscp2Project, // Project pointer
59 [in] LPCOLESTR pszSccProjectName, // opaque setting
60 [in] LPCOLESTR pszSccAuxPath, // opaque setting
61 [in] LPCOLESTR pszSccLocalPath, // opaque setting
62 [in] LPCOLESTR pszProvider // opaque setting
65 /////////////////////////////////////////////////////////////////////
66 // UnregisterSccProject
67 /////////////////////////////////////////////////////////////////////
68 // This method is called by registered projects before they are closed
70 HRESULT UnregisterSccProject
72 [in] IVsSccProject2 *pscp2Project
75 /////////////////////////////////////////////////////////////////////
76 // GetSccGlyph
77 /////////////////////////////////////////////////////////////////////
78 // This method is called by projects to discover the source-control glyphs
79 // to use on files. The glyphs are denoted by the shell's icon index, i.e.
80 // the VsStateIcon enumeration.
82 // NOTE: the source control status per file is also (optionally) returned,
83 // However, projects are encouraged to NOT use these status bits, and to only
84 // look at the glyphs. However:
85 // 1) if a file is under source control, the SCC_STATUS_CONTROLLED flag will
86 // be set
87 // 2) if a file is checked out by the current user into the designated
88 // working directory, the SCC_STATUS_CHECKEDOUT flag will be set (in
89 // addition to the above flag)
91 // This method returns S_OK if at least one of the files is controlled;
92 // returns S_FALSE if none of them are.
94 HRESULT GetSccGlyph
96 [in] int cFiles, // Number of files: should be > 0
97 [in, size_is(cFiles)] const LPCOLESTR rgpszFullPaths[], // Array of paths: cannot be NULL
98 [out, size_is(cFiles)] VsStateIcon rgsiGlyphs[], // Array of icons: cannot be NULL
99 [out, size_is(cFiles)] DWORD rgdwSccStatus[] // Status bits: can be NULL
102 /////////////////////////////////////////////////////////////////////
103 // GetSccGlyphFromStatus
104 /////////////////////////////////////////////////////////////////////
105 // If a project does know the status of a file, this method will return the appropriate glyph.
106 // However projects are encouraged not to cache source-control status, but instead to call
107 // GetSccGlyph when they need the glyph.
109 HRESULT GetSccGlyphFromStatus
111 [in] DWORD dwSccStatus,
112 [out, retval] VsStateIcon *psiGlyph
115 /////////////////////////////////////////////////////////////////////
116 // IsInstalled
117 /////////////////////////////////////////////////////////////////////
118 // This method indicates if source-control is available
120 HRESULT IsInstalled
122 [out, retval] BOOL *pbInstalled
125 /////////////////////////////////////////////////////////////////////
126 // BrowseForProject
127 /////////////////////////////////////////////////////////////////////
128 // Deprecated: returns E_NOTIMPL
130 HRESULT BrowseForProject
132 [out] BSTR *pbstrDirectory,
133 [out] BOOL *pfOK
136 /////////////////////////////////////////////////////////////////////
137 // CancelAfterBrowseForProject
138 /////////////////////////////////////////////////////////////////////
139 // Deprecated: returns E_NOTIMPL
141 HRESULT CancelAfterBrowseForProject();
144 /*-----------------------------------------------------------------------------
145 UI Context: ISccManagerLoaded
147 Defines when the SccManager is loaded
148 -----------------------------------------------------------------------------*/
149 [ uuid(795635A0-4522-11d1-8DCE-00AA00A3F593) ]
150 interface ISccManagerLoaded : IUnknown {};
152 /*-----------------------------------------------------------------------------
153 UI Context Define: UICONTEXT_SccManagerLoaded
155 This is used to determine when the main source-control package is loaded.
157 By default on startup, only the "stub" Visual Studio Team Core package is
158 loaded. When this context is loaded, the main source-control package has
159 been loaded.
160 -----------------------------------------------------------------------------*/
161 cpp_quote("#define UICONTEXT_SccManagerLoaded IID_ISccManagerLoaded")
163 /*-----------------------------------------------------------------------------
164 UI Context Define: UICONTEXT_EnlistingInProject
166 The UI context can be used to determine when SCC package is in the process
167 of enlisting in a solution or a project.
168 -----------------------------------------------------------------------------*/
169 [ uuid(F59FD070-0063-4256-8212-E5DB6FC22253) ]
170 interface IEnlistingInProject : IUnknown {};
171 cpp_quote("#define UICONTEXT_EnlistingInProject IID_IEnlistingInProject")
173 ///////////////////////////////////////////////////////////
175 // SID_SVsSccManager Defined
177 [ uuid(uuid_SVsSccManager) ]
178 interface SVsSccManager : IUnknown {};
179 cpp_quote("#define SID_SVsSccManager IID_SVsSccManager")
181 #endif