ReactOS  0.4.15-dev-985-gd905dd5
CMyDocsDropHandler.hpp
Go to the documentation of this file.
1 /*
2  * PROJECT: mydocs
3  * LICENSE: LGPL-2.1+ (https://spdx.org/licenses/LGPL-2.1+)
4  * PURPOSE: MyDocs implementation
5  * COPYRIGHT: Copyright 2020 Katayama Hirofumi MZ (katayama.hirofumi.mz@gmail.com)
6  */
7 
8 #pragma once
9 
10 #include "resource.h"
11 
13  public CComCoClass<CMyDocsDropHandler, &CLSID_MyDocsDropHandler>,
14  public CComObjectRootEx<CComMultiThreadModelNoCS>,
15  public IDropTarget,
16  public IPersistFile
17 {
18 public:
21 
22  // IDropTarget
23  STDMETHODIMP DragEnter(IDataObject *pDataObject, DWORD dwKeyState,
24  POINTL pt, DWORD *pdwEffect);
25  STDMETHODIMP DragOver(DWORD dwKeyState, POINTL pt, DWORD *pdwEffect);
27  STDMETHODIMP Drop(IDataObject *pDataObject, DWORD dwKeyState, POINTL pt,
28  DWORD *pdwEffect);
29 
30  // IPersist
31  STDMETHODIMP GetClassID(CLSID *lpClassId);
32 
33  // IPersistFile
34  STDMETHODIMP GetCurFile(LPOLESTR *ppszFileName);
36  STDMETHODIMP Load(LPCOLESTR pszFileName, DWORD dwMode);
37  STDMETHODIMP Save(LPCOLESTR pszFileName, BOOL fRemember);
39 
42 
44 
48  COM_INTERFACE_ENTRY_IID(IID_IDropTarget, IDropTarget)
49  END_COM_MAP()
50 };
STDMETHODIMP DragLeave()
#define pt(x, y)
Definition: drawing.c:79
const GUID IID_IPersist
Definition: proxy.cpp:14
#define DECLARE_NOT_AGGREGATABLE(x)
Definition: atlcom.h:611
STDMETHODIMP Load(LPCOLESTR pszFileName, DWORD dwMode)
static LPOLESTR
Definition: stg_prop.c:27
unsigned int BOOL
Definition: ntddk_ex.h:94
WORD WORD PSZ PSZ pszFileName
Definition: vdmdbg.h:41
#define STDMETHODIMP
Definition: basetyps.h:43
STDMETHODIMP Save(LPCOLESTR pszFileName, BOOL fRemember)
#define BEGIN_COM_MAP(x)
Definition: atlcom.h:541
STDMETHODIMP DragEnter(IDataObject *pDataObject, DWORD dwKeyState, POINTL pt, DWORD *pdwEffect)
STDMETHODIMP DragOver(DWORD dwKeyState, POINTL pt, DWORD *pdwEffect)
STDMETHODIMP GetCurFile(LPOLESTR *ppszFileName)
unsigned long DWORD
Definition: ntddk_ex.h:95
#define DECLARE_REGISTRY_RESOURCEID(x)
Definition: atlcom.h:605
STDMETHODIMP GetClassID(CLSID *lpClassId)
#define COM_INTERFACE_ENTRY_IID(iid, x)
Definition: atlcom.h:561
#define DECLARE_PROTECT_FINAL_CONSTRUCT()
Definition: atlcom.h:639
const GUID IID_IPersistFile
STDMETHODIMP SaveCompleted(LPCOLESTR pszFileName)
STDMETHODIMP Drop(IDataObject *pDataObject, DWORD dwKeyState, POINTL pt, DWORD *pdwEffect)
#define END_COM_MAP()
Definition: atlcom.h:552
#define IDR_MYDOCS
Definition: resource.h:11