Bug 130654

Summary: Simplify the HTMLConverter interface
Product: WebKit Reporter: Sam Weinig <sam>
Component: New BugsAssignee: Sam Weinig <sam>
Status: RESOLVED FIXED    
Severity: Normal    
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Part 1
none
Part 2 darin: review+

Description Sam Weinig 2014-03-23 13:09:19 PDT
Simplify the HTMLConverter interface
Comment 1 Sam Weinig 2014-03-23 13:12:26 PDT
Created attachment 227615 [details]
Part 1
Comment 2 mitz 2014-03-23 13:15:46 PDT
Comment on attachment 227615 [details]
Part 1

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

> Source/WebCore/platform/mac/HTMLConverter.h:83
> ++ (NSAttributedString *)attributedStringFromRange:(WebCore::Range*)range;

Why not make the argument a reference?
Comment 3 Sam Weinig 2014-03-23 13:17:01 PDT
(In reply to comment #2)
> (From update of attachment 227615 [details])
> View in context: https://bugs.webkit.org/attachment.cgi?id=227615&action=review
> 
> > Source/WebCore/platform/mac/HTMLConverter.h:83
> > ++ (NSAttributedString *)attributedStringFromRange:(WebCore::Range*)range;
> 
> Why not make the argument a reference?

I'll see about doing that in a bit.
Comment 4 Sam Weinig 2014-03-23 13:18:16 PDT
Committed r166143: <http://trac.webkit.org/changeset/166143>
Comment 5 Sam Weinig 2014-03-23 14:25:05 PDT
Created attachment 227617 [details]
Part 2
Comment 6 Darin Adler 2014-03-23 14:28:14 PDT
Comment on attachment 227617 [details]
Part 2

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

> Source/WebKit/mac/WebView/WebHTMLView.mm:6667
> +                attributedString = [[[NSAttributedString alloc] init] autorelease];

I think you can just write [NSAttributedString string] for this.
Comment 7 Sam Weinig 2014-03-23 14:41:40 PDT
Committed r166145: <http://trac.webkit.org/changeset/166145>