Bug 145281 - Add an "initiated by user gesture" flag to ResourceRequest
Summary: Add an "initiated by user gesture" flag to ResourceRequest
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebCore Misc. (show other bugs)
Version: 528+ (Nightly build)
Hardware: All All
: P2 Normal
Assignee: Brady Eidson
URL:
Keywords:
Depends on:
Blocks: 145280
  Show dependency treegraph
 
Reported: 2015-05-21 13:20 PDT by Brady Eidson
Modified: 2015-05-22 11:58 PDT (History)
3 users (show)

See Also:


Attachments
Patch v1 (17.41 KB, patch)
2015-05-21 13:55 PDT, Brady Eidson
no flags Details | Formatted Diff | Diff
Patch v2 - Less WK1 test crashing (18.89 KB, patch)
2015-05-21 14:36 PDT, Brady Eidson
no flags Details | Formatted Diff | Diff
Patch v3 - More iOS building (19.45 KB, patch)
2015-05-21 15:01 PDT, Brady Eidson
achristensen: review+
Details | Formatted Diff | Diff
Patch for landing. (19.37 KB, patch)
2015-05-21 16:46 PDT, Brady Eidson
no flags Details | Formatted Diff | Diff
Followup to fix WCSI/WSI misusage - v1 (9.16 KB, patch)
2015-05-22 10:11 PDT, Brady Eidson
mitz: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Brady Eidson 2015-05-21 13:20:56 PDT
Add an "initiated by user gesture" flag to ResourceRequest

This is in support of https://bugs.webkit.org/show_bug.cgi?id=145280, and will be tested along with that bug.
Comment 1 Brady Eidson 2015-05-21 13:55:07 PDT
Created attachment 253540 [details]
Patch v1
Comment 2 Brady Eidson 2015-05-21 14:36:31 PDT
Created attachment 253544 [details]
Patch v2 - Less WK1 test crashing
Comment 3 Brady Eidson 2015-05-21 15:01:19 PDT
Created attachment 253546 [details]
Patch v3 - More iOS building
Comment 4 Alex Christensen 2015-05-21 16:41:22 PDT
Comment on attachment 253546 [details]
Patch v3 - More iOS building

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

> Source/WebCore/platform/mac/WebCoreSystemInterface.h:321
> +#if PLATFORM(COCOA)

PLATFORM(COCOA) shouldn't be needed in platform/mac

> Source/WebCore/platform/mac/WebCoreSystemInterface.mm:173
> +#if PLATFORM(COCOA)

shouldn't be needed.

> Source/WebKit2/WebProcess/WebCoreSupport/mac/WebSystemInterface.mm:211
> +#if PLATFORM(COCOA)

shouldn't be needed.
Comment 5 Brady Eidson 2015-05-21 16:46:58 PDT
Created attachment 253552 [details]
Patch for landing.
Comment 6 WebKit Commit Bot 2015-05-21 17:36:04 PDT
Comment on attachment 253552 [details]
Patch for landing.

Clearing flags on attachment: 253552

Committed r184741: <http://trac.webkit.org/changeset/184741>
Comment 7 mitz 2015-05-22 08:46:08 PDT
Comment on attachment 253546 [details]
Patch v3 - More iOS building

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

> Source/WebKit2/WebProcess/WebCoreSupport/mac/WebSystemInterface.mm:31
>  

WebSystemInterface exists solely for binding symbols from libWebKitSystemInterface. It’s unnecessary and inappropriate to use it for this.
Comment 8 Brady Eidson 2015-05-22 09:06:22 PDT
(In reply to comment #7)
> Comment on attachment 253546 [details]
> Patch v3 - More iOS building
> 
> View in context:
> https://bugs.webkit.org/attachment.cgi?id=253546&action=review
> 
> > Source/WebKit2/WebProcess/WebCoreSupport/mac/WebSystemInterface.mm:31
> >  
> 
> WebSystemInterface exists solely for binding symbols from
> libWebKitSystemInterface. It’s unnecessary and inappropriate to use it for
> this.

I was not aware that it was inappropriate, as I haven't seen that documented anywhere.

I would like to here the obviously better alternative that makes it unnecessary, as I was unable to figure another obvious way for WebCore to have access to a static string provided by WebKit.

There might *be* an obvious way, I just don't know what it is off hand.
Comment 9 Brady Eidson 2015-05-22 09:34:21 PDT
(In reply to comment #8)
> (In reply to comment #7)
> > Comment on attachment 253546 [details]
> > Patch v3 - More iOS building
> > 
> > View in context:
> > https://bugs.webkit.org/attachment.cgi?id=253546&action=review
> > 
> > > Source/WebKit2/WebProcess/WebCoreSupport/mac/WebSystemInterface.mm:31
> > >  
> > 
> > WebSystemInterface exists solely for binding symbols from
> > libWebKitSystemInterface. It’s unnecessary and inappropriate to use it for
> > this.
> 
> I was not aware that it was inappropriate, as I haven't seen that documented
> anywhere.
> 
> I would like to here the obviously better alternative that makes it
> unnecessary, as I was unable to figure another obvious way for WebCore to
> have access to a static string provided by WebKit.
> 
> There might *be* an obvious way, I just don't know what it is off hand.

I realize now that I shifted strategies partway through my patch in a way that no longer required the string to be WebKit provided, and in fact it can live in WebCore.

Will fix.
Comment 10 Brady Eidson 2015-05-22 10:11:56 PDT
Created attachment 253594 [details]
Followup to fix WCSI/WSI misusage - v1
Comment 11 Brady Eidson 2015-05-22 10:24:32 PDT
http://trac.webkit.org/changeset/184775
Comment 12 Alexey Proskuryakov 2015-05-22 11:58:43 PDT
Trying to fix the build in r184783.