Bug 45214

Summary: Rename SecurityOrigin::canLoad to canDisplay
Product: WebKit Reporter: Adam Barth <abarth>
Component: New BugsAssignee: Adam Barth <abarth>
Status: RESOLVED FIXED    
Severity: Normal CC: commit-queue, darin, eric, sam
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Other   
OS: OS X 10.5   
Attachments:
Description Flags
Patch
none
Patch for landing none

Description Adam Barth 2010-09-03 16:24:00 PDT
Rename SecurityOrigin::canLoad to canDisplay
Comment 1 Adam Barth 2010-09-03 16:27:51 PDT
Created attachment 66563 [details]
Patch
Comment 2 Darin Adler 2010-09-03 16:41:24 PDT
Comment on attachment 66563 [details]
Patch

> +    // Returns true if |document| can dispaly content from the given URL (e.g.,

dispaly

> +    // in an iframe or as an image).  For example, web sites generally cannot
> +    // display content from the user's files system.  If |document| is 0,
> +    // |referrer| is used to make this determination.

Are we going to have to go out into the alley and have a throw down over the two spaces vs. one space after period issue? ;-)

In the programming world I am part of, the word "display" usually means "paint into a window", so I think the word display here is not perfect. Is there some terminology from the HTML5 specification or some other technical document that we can borrow here to find a phrase better than "display the contents"?
Comment 3 Adam Barth 2010-09-03 17:02:45 PDT
Thanks for the review.

> Are we going to have to go out into the alley and have a throw down over the two spaces vs. one space after period issue? ;-)

Sorry.  Almost all the prose I write uses two-space indent.  :(

> In the programming world I am part of, the word "display" usually means "paint into a window", so I think the word display here is not perfect. Is there some terminology from the HTML5 specification or some other technical document that we can borrow here to find a phrase better than "display the contents"?

canShow?  canRender?  My main beef with canLoad is that it's too similar to canRequest.  Actually, "paint into a window" is pretty accurate here.  For example, that's pretty much what the image element does with the URL...
Comment 4 Adam Barth 2010-09-05 23:41:57 PDT
Created attachment 66614 [details]
Patch for landing
Comment 5 WebKit Commit Bot 2010-09-06 00:59:59 PDT
Comment on attachment 66614 [details]
Patch for landing

Clearing flags on attachment: 66614

Committed r66815: <http://trac.webkit.org/changeset/66815>
Comment 6 WebKit Commit Bot 2010-09-06 01:00:04 PDT
All reviewed patches have been landed.  Closing bug.