- Add CefDragHandler to support examination of drag data and cancellation of drag requests (issue #297).

- Mac: Fix dragging of URLs by providing a default image if no drag image is supplied.

git-svn-id: https://chromiumembedded.googlecode.com/svn/trunk@279 5089003a-bbd8-11dd-ad1f-f1f9622dbc98
This commit is contained in:
Marshall Greenblatt
2011-08-22 01:31:55 +00:00
parent 88a46e0b44
commit 1b1255c92d
26 changed files with 1192 additions and 30 deletions

View File

@ -12,6 +12,7 @@
#include "libcef_dll/cpptoc/client_cpptoc.h"
#include "libcef_dll/cpptoc/display_handler_cpptoc.h"
#include "libcef_dll/cpptoc/drag_handler_cpptoc.h"
#include "libcef_dll/cpptoc/find_handler_cpptoc.h"
#include "libcef_dll/cpptoc/focus_handler_cpptoc.h"
#include "libcef_dll/cpptoc/jsbinding_handler_cpptoc.h"
@ -207,6 +208,21 @@ cef_render_handler_t* CEF_CALLBACK client_get_render_handler(
return NULL;
}
cef_drag_handler_t* CEF_CALLBACK client_get_drag_handler(
struct _cef_client_t* self)
{
DCHECK(self);
if (!self)
return NULL;
CefRefPtr<CefDragHandler> handlerPtr =
CefClientCppToC::Get(self)->GetDragHandler();
if(handlerPtr.get())
return CefDragHandlerCppToC::Wrap(handlerPtr);
return NULL;
}
// CONSTRUCTOR - Do not edit by hand.
@ -225,6 +241,7 @@ CefClientCppToC::CefClientCppToC(CefClient* cls)
struct_.struct_.get_jsdialog_handler = client_get_jsdialog_handler;
struct_.struct_.get_jsbinding_handler = client_get_jsbinding_handler;
struct_.struct_.get_render_handler = client_get_render_handler;
struct_.struct_.get_drag_handler = client_get_drag_handler;
}
#ifndef NDEBUG