00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025 #include "stdafx.h"
00026 #include "mplayerc.h"
00027 #include "FileDropTarget.h"
00028
00029
00030
00031
00032
00033 CFileDropTarget::CFileDropTarget(CDropTarget* pDropTarget)
00034 : m_pDropTarget(pDropTarget)
00035 {
00036 ASSERT(m_pDropTarget);
00037 }
00038
00039 CFileDropTarget::~CFileDropTarget()
00040 {
00041 }
00042
00043 DROPEFFECT CFileDropTarget::OnDragEnter(CWnd* pWnd, COleDataObject* pDataObject, DWORD dwKeyState, CPoint point)
00044 {
00045 return m_pDropTarget ? m_pDropTarget->OnDragEnter(pDataObject, dwKeyState, point) : DROPEFFECT_NONE;
00046 }
00047
00048 DROPEFFECT CFileDropTarget::OnDragOver(CWnd* pWnd, COleDataObject* pDataObject, DWORD dwKeyState, CPoint point)
00049 {
00050 return m_pDropTarget ? m_pDropTarget->OnDragOver(pDataObject, dwKeyState, point) : DROPEFFECT_NONE;
00051 }
00052
00053 BOOL CFileDropTarget::OnDrop(CWnd* pWnd, COleDataObject* pDataObject, DROPEFFECT dropEffect, CPoint point)
00054 {
00055 return m_pDropTarget ? m_pDropTarget->OnDrop(pDataObject, dropEffect, point) : DROPEFFECT_NONE;
00056 }
00057
00058 DROPEFFECT CFileDropTarget::OnDropEx(CWnd* pWnd, COleDataObject* pDataObject, DROPEFFECT dropDefault, DROPEFFECT dropList, CPoint point)
00059 {
00060 return m_pDropTarget ? m_pDropTarget->OnDropEx(pDataObject, dropDefault, dropList, point) : DROPEFFECT_NONE;
00061 }
00062
00063 void CFileDropTarget::OnDragLeave(CWnd* pWnd)
00064 {
00065 if(m_pDropTarget) m_pDropTarget->OnDragLeave();
00066 }
00067
00068 DROPEFFECT CFileDropTarget::OnDragScroll(CWnd* pWnd, DWORD dwKeyState, CPoint point)
00069 {
00070 return m_pDropTarget ? m_pDropTarget->OnDragScroll(dwKeyState, point) : DROPEFFECT_NONE;
00071 }
00072
00073 BEGIN_MESSAGE_MAP(CFileDropTarget, COleDropTarget)
00074 END_MESSAGE_MAP()
00075
00076
00077
00078