|
/**
* @name makeDir.h
* @purpose Make a directory
* @date 11 May 2003
* @author S.Deckers
*/
#ifndef _MAKEDIR_H_
#define _MAKEDIR_H_
#include "resource.h" // main symbols
#include <shlobj.h>
#include <comdef.h>
/////////////////////////////////////////////////////////////////////////////
// CMakeDir
class ATL_NO_VTABLE CMakeDir :
public CComObjectRootEx<CComSingleThreadModel>,
public CComCoClass<CMakeDir, &CLSID_MakeDir>,
public IDispatchImpl<IMakeDir, &IID_IMakeDir, &LIBID_sdeExtensions>,
public IShellExtInit,
public IContextMenu
{
public: // --- Ctor
/**
* @name CMakeDir
* @Purpose ctor
*/
CMakeDir( )
{
AtlTrace( "CMakeDir ctor\n");
m_hBmp = LoadBitmap ( _Module.GetModuleInstance(),MAKEINTRESOURCE( IDB_MAKEDIR) );
}
public: // --- COM Macros
DECLARE_REGISTRY_RESOURCEID ( IDR_MAKEDIR)
DECLARE_PROTECT_FINAL_CONSTRUCT ( )
BEGIN_COM_MAP ( CMakeDir)
COM_INTERFACE_ENTRY ( IMakeDir)
COM_INTERFACE_ENTRY ( IDispatch)
COM_INTERFACE_ENTRY ( IShellExtInit)
COM_INTERFACE_ENTRY ( IContextMenu)
END_COM_MAP ( )
public: // --- Implemented interfaces
// --- IShellExtInit
STDMETHOD( Initialize) ( LPCITEMIDLIST, LPDATAOBJECT, HKEY);
// --- IContextMenu : interface for interacting with the context menu
STDMETHOD( GetCommandString) ( UINT, UINT, UINT*, LPSTR, UINT);
STDMETHOD( InvokeCommand) ( LPCMINVOKECOMMANDINFO);
STDMETHOD( QueryContextMenu) ( HMENU, UINT, UINT, UINT, UINT);
private: // --- Protected members
TCHAR m_szDirClickedIn [MAX_PATH];
HBITMAP m_hBmp;
};
#endif //_MAKEDIR_H_
|
By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.
If a file you wish to view isn't highlighted, and is a text file (not binary), please
let us know and we'll add colourisation support for it.