SccDirDiff Function

 

The new home for Visual Studio documentation is Visual Studio 2017 Documentation on docs.microsoft.com.

The latest version of this topic can be found at SccDirDiff Function.

This function displays the differences between the current local directory on the client disk and the corresponding project under source control.

SCCRTN SccDirDiff(  
   LPVOID    pContext,  
   HWND      hWnd,  
   LPCSTR    lpDirName,  
   LONG      dwFlags,  
   LPCMDOPTS pvOptions  
);  

Parameters

pContext
[in] The source control plug-in context structure.

hWnd
[in] A handle to the IDE window that the source control plug-in can use as a parent for any dialog boxes that it provides.

lpDirName
[in] Fully qualified path to the local directory for which to show a visual difference.

dwFlags
[in] Command flags (see Remarks section).

pvOptions
[in] Source control plug-in-specific options.

The source control plug-in implementation of this function is expected to return one of the following values:

ValueDescription
SCC_OKThe directory on disk is the same as the project in source code control.
SCC_I_FILESDIFFERThe directory on disk is different from the project in source code control.
SCC_I_RELOADFILEA file or project needs to be reloaded.
SCC_E_FILENOTCONTROLLEDThe directory is not under source code control.
SCC_E_NOTAUTHORIZEDThe user is not allowed to perform this operation.
SCC_E_ACCESSFAILUREThere was a problem accessing the source control system, probably due to network or contention issues. A retry is recommended.
SCC_E_NONSPECIFICERROR

SCC_E_UNKNOWNERROR
Nonspecific failure.
SCC_E_FILENOTEXISTLocal directory could not be found.

This function is used to instruct the source control plug-in to display to the user a list of changes to a specified directory. The plug-in opens its own window, in a format of its choice, to display the differences between the user's directory on disk and the corresponding project under version control.

If a plug-in supports comparison of directories at all, it must support comparison of directories on a file-name basis even if the "quick-diff" options are not supported.

dwFlagsInterpretation
SCC_DIFF_IGNORECASECase-insensitive comparison (may be used for either quick diff or visual).
SCC_DIFF_IGNORESPACEIgnores white space (may be used for either quick-diff or visual).
SCC_DIFF_QD_CONTENTSIf supported by the source control plug-in, silently compares the directory, byte by byte.
SCC_DIFF_QD_CHECKSUMIf supported by plug-in, silently compares the directory via a checksum, or, if not supported, falls back to SCC_DIFF_QD_CONTENTS.
SCC_DIFF_QD_TIMEIf supported by plug-in, silently compares the directory via its timestamp, or, if not supported, falls back on SCC_DIFF_QD_CHECKSUM or SCC_DIFF_QD_CONTENTS.
System_CAPS_ICON_note.jpg Note

This function uses the same command flags as the SccDiff. However, a source control plug-in may choose to not support the "quick-diff" operation for directories.

Source Control Plug-in API Functions

Show: