WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
51969
WebKit2: Should be able to call into injected bundle to ask if we should allow resource loads
https://bugs.webkit.org/show_bug.cgi?id=51969
Summary
WebKit2: Should be able to call into injected bundle to ask if we should allo...
Brian Weinstein
Reported
2011-01-05 16:42:00 PST
WebKit2 needs a way to call into the injected bundle to ask whether or not we should load resources, and if the injected bundle says we should, we should cancel the resource load.
Attachments
[PATCH] Fix
(5.45 KB, patch)
2011-01-05 17:00 PST
,
Brian Weinstein
no flags
Details
Formatted Diff
Diff
[PATCH] Fix + WebKitTestRunner
(9.11 KB, patch)
2011-01-05 17:39 PST
,
Brian Weinstein
adachan
: review+
Details
Formatted Diff
Diff
Show Obsolete
(1)
View All
Add attachment
proposed patch, testcase, etc.
Brian Weinstein
Comment 1
2011-01-05 17:00:58 PST
Created
attachment 78069
[details]
[PATCH] Fix
WebKit Review Bot
Comment 2
2011-01-05 17:02:54 PST
Attachment 78069
[details]
did not pass style-queue: Failed to run "['Tools/Scripts/check-webkit-style', '--diff-files', u'WebKit2/ChangeLog', u'WebKit2/WebProcess/InjectedBundle/API/c/WKBundlePage.h', u'WebKit2/WebProcess/InjectedBundle/InjectedBundlePageLoaderClient.cpp', u'WebKit2/WebProcess/InjectedBundle/InjectedBundlePageLoaderClient.h', u'WebKit2/WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp']" exit_code: 1 WebKit2/WebProcess/InjectedBundle/API/c/WKBundlePage.h:90: The parameter name "page" adds no information, so it should be removed. [readability/parameter_name] [5] WebKit2/WebProcess/InjectedBundle/API/c/WKBundlePage.h:90: The parameter name "frame" adds no information, so it should be removed. [readability/parameter_name] [5] WebKit2/WebProcess/InjectedBundle/API/c/WKBundlePage.h:90: The parameter name "url" adds no information, so it should be removed. [readability/parameter_name] [5] Total errors found: 3 in 5 files If any of these errors are false positives, please file a bug against check-webkit-style.
Early Warning System Bot
Comment 3
2011-01-05 17:25:04 PST
Attachment 78069
[details]
did not build on qt: Build output:
http://queues.webkit.org/results/7289428
Brian Weinstein
Comment 4
2011-01-05 17:39:26 PST
Created
attachment 78080
[details]
[PATCH] Fix + WebKitTestRunner
Ada Chan
Comment 5
2011-01-06 10:52:08 PST
Comment on
attachment 78080
[details]
[PATCH] Fix + WebKitTestRunner Typo: // FIXME: We should problably ...
Alexey Proskuryakov
Comment 6
2011-01-06 13:25:04 PST
+bool InjectedBundlePageLoaderClient::shouldLoadResourceForFrame(WebPage* page, WebFrame* frame, const String& subResourceURL) +{ + if (!m_client.shouldLoadResourceForFrame) + return true; + + return m_client.shouldLoadResourceForFrame(toAPI(page), toAPI(frame), toURLRef(subResourceURL.impl()), m_client.clientInfo); Is it subResourceURL, or just resourceURL?
Brian Weinstein
Comment 7
2011-01-06 13:56:39 PST
Landed in
r75174
.
Brian Weinstein
Comment 8
2011-01-06 13:56:57 PST
(In reply to
comment #6
)
> +bool InjectedBundlePageLoaderClient::shouldLoadResourceForFrame(WebPage* page, WebFrame* frame, const String& subResourceURL) > +{ > + if (!m_client.shouldLoadResourceForFrame) > + return true; > + > + return m_client.shouldLoadResourceForFrame(toAPI(page), toAPI(frame), toURLRef(subResourceURL.impl()), m_client.clientInfo); > > Is it subResourceURL, or just resourceURL?
It should be resourceURL. I will fix this in a follow-up.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug