[Webkit-unassigned] [Bug 35811] [chromium] need DragImage implementation

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Mon Mar 8 15:27:42 PST 2010


https://bugs.webkit.org/show_bug.cgi?id=35811





--- Comment #13 from Evan Stade <estade at chromium.org>  2010-03-08 15:27:42 PST ---
(In reply to comment #12)
> (From update of attachment 50241 [details])
> > Index: WebCore/platform/chromium/DragImageChromium.cpp
> ...
> > +#if OS(DARWIN)
> > +#include "skia/ext/skia_utils_mac.h"
> > +#endif
> 
> Can you use CG in the Mac port instead?  We should really avoid using
> skia/ext in WebCore.  It introduces a circular dependency between the
> repositories!

we can use CG for Mac, but then we have to implement DragImageChromium twice,
and fork a lot of code on the chrome side of this patch.

> 
> 
> > +DragImageRef createDragImageFromImage(Image* image)
> > +{
> > +#if OS(DARWIN)
> > +    SkBitmap bitmap = gfx::CGImageToSkBitmap(image->getCGImageRef());
> 
> please avoid adding gfx:: namespace stuff to WebCore!  that stuff is
> chromium only.

After talking to several mac people, this is the only way I could find to
convert CG to SkBitmap. Is there a better way? If not I can leave the mac side
unimplemented for the time being.

> 
> 
> > Index: WebKit/chromium/ChangeLog
> ...
> > +        * public/WebDragImageRef.h: Added.
> > +        * src/DragClientImpl.cpp:
> > +        (WebKit::DragClientImpl::startDrag):
> > +        * src/WebViewImpl.cpp:
> > +        (WebKit::WebViewImpl::startDragging):
> > +        * src/WebViewImpl.h:
> 
> is there some other public interface change missing?  I don't see
> any public API that uses WebDragImageRef.
> 
> also, please see WebImage.h to note how things differ between
> WEBKIT_USING_SKIA and WEBKIT_USING_CG.
> 
> It seems like WebDragImageRef should be made consistent with
> WebImage.

Yes, the change to WebViewClient::StartDragging is missing (see FIXME in
WebViewImpl). That is not part of this patch because I am breaking it up into
multiple pieces.

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list