⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 copiermenu.h

📁 一个不同目录中多个文件拷贝的助手程序
💻 H
字号:
//-----------------------------------------------------------------------//
// This is a part of the Multicopier.									 //	
// Autor  :  Ahmed Ismaiel Zakaria										 //
// (C) 2002 FCIS Egypt  All rights reserved								 //
// This code is provided "as is", with absolutely no warranty expressed  //
// or implied. Any use is at your own risk.								 //		
// You must obtain the author's consent before you can include this code //
// in a software library.												 //
// If the source code in  this file is used in any application			 //
// then acknowledgement must be made to the author of this program		 //	
// ahmed_ismaiel@hotmail.com											 //
//-----------------------------------------------------------------------//

// CopierMenu.h : Declaration of the CCopierMenu

#ifndef __COPIERMENU_H_
#define __COPIERMENU_H_

#include "resource.h"       // main symbols

#pragma comment(lib, "comctl32.lib")


#include <comdef.h>
#include <shlobj.h>
#include <string>
#include <list> 

using namespace std;

#ifdef _UNICODE
#define string wstring
#endif

typedef list<string> STRINGLIST;

/////////////////////////////////////////////////////////////////////////////
// CCopierMenu
class ATL_NO_VTABLE CCopierMenu : 
	public CComObjectRootEx<CComSingleThreadModel>,
	public CComCoClass<CCopierMenu, &CLSID_CopierMenu>,
	public IShellExtInit,
	public IContextMenu
{
public:
	CCopierMenu()
	{
	}

DECLARE_REGISTRY_RESOURCEID(IDR_COPIERMENU)

DECLARE_PROTECT_FINAL_CONSTRUCT()

BEGIN_COM_MAP(CCopierMenu)
	COM_INTERFACE_ENTRY(IShellExtInit)
	COM_INTERFACE_ENTRY(IContextMenu)
END_COM_MAP()

public:
//	STRINGLIST m_listPaths; // use m_listPaths.front().c_str() to get the first file in the list
	CStringArray m_listPaths;
// IShellExtInit
public:
	STDMETHOD(Initialize)(LPCITEMIDLIST pidlFolder,LPDATAOBJECT lpdobj,HKEY hkeyProgID);

// IContextMenu
public:
    STDMETHOD(QueryContextMenu)(HMENU hmenu, UINT indexMenu, UINT idCmdFirst, UINT idCmdLast, UINT uFlags);
    STDMETHOD(InvokeCommand)(LPCMINVOKECOMMANDINFO lpici);
    STDMETHOD(GetCommandString)(UINT idCmd, UINT uType,UINT* pwReserved,LPSTR pszName,UINT cchMax);

// ICopierMenu
public:
	CStringArray source;
};

#endif //__COPIERMENU_H_

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -