21#include <com/sun/star/lang/XInitialization.hpp>
22#include <com/sun/star/datatransfer/dnd/XDropTarget.hpp>
23#include <com/sun/star/datatransfer/dnd/DropTargetDragEnterEvent.hpp>
24#include <com/sun/star/lang/XServiceInfo.hpp>
29#include <osl/mutex.hxx>
35class XComponentContext;
53 public WeakComponentImplHelper<XInitialization, XDropTarget, XServiceInfo>
104 explicit DropTarget(
const Reference<XComponentContext>& rxContext);
114 virtual void SAL_CALL
initialize(
const Sequence<Any>& aArguments)
override;
118 virtual void SAL_CALL
133 IDataObject* pDataObj,
145 virtual HRESULT STDMETHODCALLTYPE
Drop(
146 IDataObject* pDataObj,
155 void _rejectDrop(
const Reference<XDropTargetDropContext>& context);
156 void _dropComplete(
bool success,
const Reference<XDropTargetDropContext>& context);
160 void _rejectDrag(
const Reference<XDropTargetDragContext>& context);
void fire_dragEnter(const DropTargetDragEnterEvent &dtde)
virtual sal_Bool SAL_CALL isActive() override
void fire_dragOver(const DropTargetDragEvent &dtde)
virtual sal_Bool SAL_CALL supportsService(const OUString &ServiceName) override
void _rejectDrop(const Reference< XDropTargetDropContext > &context)
virtual HRESULT DragEnter(IDataObject *pDataObj, DWORD grfKeyState, POINTL pt, DWORD *pdwEffect)
Reference< XDropTargetDropContext > m_currentDropContext
virtual HRESULT STDMETHODCALLTYPE Drop(IDataObject *pDataObj, DWORD grfKeyState, POINTL pt, DWORD *pdwEffect)
sal_Int8 m_nDefaultActions
sal_Int8 m_nLastDropAction
void _rejectDrag(const Reference< XDropTargetDragContext > &context)
void _acceptDrop(sal_Int8 dropOperation, const Reference< XDropTargetDropContext > &context)
DropTarget(DropTarget const &)=delete
virtual void SAL_CALL disposing() override
sal_Int8 m_nCurrentDropAction
void fire_dropActionChanged(const DropTargetDragEvent &dtde)
virtual sal_Int8 SAL_CALL getDefaultActions() override
virtual HRESULT STDMETHODCALLTYPE DragLeave()
virtual Sequence< OUString > SAL_CALL getSupportedServiceNames() override
Reference< XComponentContext > m_xContext
friend DWORD WINAPI DndTargetOleSTAFunc(LPVOID pParams)
sal_Int8 getFilteredActions(DWORD grfKeyState)
virtual void SAL_CALL setActive(sal_Bool isActive) override
void _acceptDrag(sal_Int8 dragOperation, const Reference< XDropTargetDragContext > &context)
DropTarget(const Reference< XComponentContext > &rxContext)
Reference< XDropTargetDragContext > m_currentDragContext
IDropTarget * m_pDropTarget
void fire_drop(const DropTargetDropEvent &dte)
virtual OUString SAL_CALL getImplementationName() override
virtual ~DropTarget() override
virtual HRESULT STDMETHODCALLTYPE DragOver(DWORD grfKeyState, POINTL pt, DWORD *pdwEffect)
sal_Int8 getFilteredActions(DWORD grfKeyState, DWORD sourceActions)
virtual void SAL_CALL setDefaultActions(sal_Int8 actions) override
Reference< XTransferable > m_currentData
virtual void SAL_CALL addDropTargetListener(const Reference< XDropTargetListener > &dtl) override
DropTarget & operator=(DropTarget const &)=delete
void _dropComplete(bool success, const Reference< XDropTargetDropContext > &context)
void fire_dragExit(const DropTargetEvent &dte)
virtual void SAL_CALL removeDropTargetListener(const Reference< XDropTargetListener > &dtl) override
virtual void SAL_CALL initialize(const Sequence< Any > &aArguments) override