Bug 116009

Summary: [Mac] Move writeRange/PlainText/URL from ClipboardMac to PasteboardMac
Product: WebKit Reporter: Darin Adler <darin>
Component: PlatformAssignee: Darin Adler <darin>
Status: RESOLVED FIXED    
Severity: Normal CC: commit-queue, esprehn+autocc
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Mac   
OS: All   
Bug Depends on:    
Bug Blocks: 115980    
Attachments:
Description Flags
Patch kling: review+, darin: commit-queue-

Description Darin Adler 2013-05-12 22:39:36 PDT
[Mac] Move writeRange/PlainText/URL from ClipboardMac to PasteboardMac
Comment 1 Darin Adler 2013-05-12 22:47:57 PDT
Created attachment 201529 [details]
Patch
Comment 2 Andreas Kling 2013-05-13 07:43:41 PDT
Comment on attachment 201529 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=201529&action=review

r=me

> Source/WebCore/dom/Clipboard.cpp:321
> +void Clipboard::writeRange(Range* range, Frame* frame)
> +{
> +    ASSERT(range);
> +    ASSERT(frame);

I'm starting to wonder why we bother with things like this instead of passing things by reference where they are always supposed to be non-null.

> Source/WebCore/dom/Clipboard.cpp:322
> +    // FIXME: This is design mistake, a layering violation that should be fixed.

a* design mistake

> Source/WebCore/dom/Clipboard.cpp:336
> +    // FIXME: This is design mistake, a layering violation that should be fixed.

*a design mistake
Comment 3 Darin Adler 2013-05-13 07:53:34 PDT
Comment on attachment 201529 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=201529&action=review

>> Source/WebCore/dom/Clipboard.cpp:321
>> +    ASSERT(frame);
> 
> I'm starting to wonder why we bother with things like this instead of passing things by reference where they are always supposed to be non-null.

I agree, but it’s a bit of a deep subject since it’s about idiom, not just null-ness.
Comment 4 Darin Adler 2013-05-13 08:28:56 PDT
Committed r150016: <http://trac.webkit.org/changeset/150016>