IVsSccProject2::SccGlyphChanged Method (Int32, array<UInt32>^, array<VsStateIcon>^, array<UInt32>^)
This method is called by the source control portion of the environment to inform the project of changes to the source control glyph on various nodes.
Assembly: Microsoft.VisualStudio.Shell.Interop (in Microsoft.VisualStudio.Shell.Interop.dll)
int SccGlyphChanged( int cAffectedNodes, array<unsigned int>^ rgitemidAffectedNodes, array<VsStateIcon>^ rgsiNewGlyphs, array<unsigned int>^ rgdwNewSccStatus )
Parameters
- cAffectedNodes
-
Type:
System::Int32
[in] Count of changed nodes.
- rgitemidAffectedNodes
-
Type:
array<System::UInt32>^
[in] An array of VSITEMID identifiers of the changed nodes.
- rgsiNewGlyphs
-
Type:
array<Microsoft.VisualStudio.Shell.Interop::VsStateIcon>^
[in] An array of VsStateIcon glyphs representing the new state of the corresponding item in rgitemidAffectedNodes.
- rgdwNewSccStatus
-
Type:
array<System::UInt32>^
[in] An array of status flags from the File Status Code Enumerator (SccStatus) corresponding to rgitemidAffectedNodes.
Return Value
Type: System::Int32If the method succeeds, it returns S_OK. If it fails, it returns an error code.
From ivssccproject2.idl
HRESULT SccGlyphChanged( [in] int cAffectedNodes, [in, size_is(cAffectedNodes)] const VSITEMID rgitemidAffectedNodes[], [in, size_is(cAffectedNodes)] const VsStateIcon rgsiNewGlyphs[], [in, size_is(cAffectedNodes)] const DWORD rgdwNewSccStatus[] );
The source control glyph is a small icon adjacent to the project item's icon; it indicates the source control status of the item. The glyphs are denoted by the shell's icon index (the VsStateIcon enumeration).
If all of the parameters are null and the count equals zero (cAffectedNodes == 0), then all of the associated project files will be updated. In this case, the project must call GetSccGlyph on the SVsSccManager service to retrieve the glyphs for its files. Otherwise, do not call this method.
When the project receives the GetProperty(VSHPROPID_StateIconIndex) call from the environment, it should call GetSccGlyph for the appropriate file or files for the VSITEMID specified in that call. The project does not need to store the returned state icon—the environment stores it. It is important to note that a project can call GetSccGlyph when the environment calls GetProperty on the project, but when the environment calls IVsSccProject2::SccGlyphChanged on the project, the project is handed the glyphs and does not need to call GetSccGlyph again. The project can immediately pass the given glyphs to the environment using SetProperty unless the parameters to IVsSccProject2::SccGlyphChanged are null, in which case, the project should call the environment for all of the VSITEMIDs in the project.