Specifications

349
CHAPTER 30
The Source Control Integration API
The Source Control Integration API lets you write shared libraries to extend the Macromedia
Dreamweaver MX Check in/Check out feature using source control systems (such as Sourcesafe,
CVS, or Sitespring).
You must support a minimum set of API functions that you must support for Dreamweaver to
integrate with a source control system.
Your library resides in the Configuration\SourceControl folder.
When Dreamweaver starts, it loads each library. Dreamweaver determines which features the
library supports by calling
GetProcAddress() for each API function. If an address does not exist,
Dreamweaver assumes the library does not support the API. If the address exists, Dreamweaver
uses the librarys version of the function to support the functionality. When a Dreamweaver user
defines or edits a site and then chooses the Web Server SCS tab, the choices that correspond to
the DLLs that loaded from the Configuration/SourceControl folder appear (in addition to the
standard items) on the tab.
To add custom items to the Site > Source Control menu, add the following code in the Site menu
in the menus.xml file:
<menu name="Source Control" id="DWMenu_MainSite_Site_Source¬
Control"><menuitem dynamic name="None"file="Menus/MM/¬
File_SCSItems.htm" id="DWMenu_MainSite_Site_NewFeatures_¬
Default" />
</menu>
Integration with Dreamweaver
When a Dreamweaver user chooses server connection, file transfer, or Design Notes features,
Dreamweaver calls the DLLs version of the corresponding API function (
Connect(),
Disconnect(), Get(), Put(), Checkin(), Checkout(), Undocheckout(), and
Synchronize()). The DLL is responsible for handling the request, including displaying dialog
boxes that gather information or let the user interact with the DLL. The DLL is also responsible
for displaying information or error messages.
The source control system can optionally support Design Notes and Check In/Check Out. The
Dreamweaver user enables Design Notes in source control systems by choosing the Design Notes
tab in the Edit Sites dialog box and checking the box that enables the feature; this is the same way
to enable Design Notes with FTP and LAN. If the source control system does not support Design
Notes and the user wants to use this feature, Dreamweaver transports Design Note (.mno) files to
maintain the Design Notes (as it does with FTP and LAN).