mirror of
https://github.com/electron/electron.git
synced 2026-01-24 14:57:58 -05:00
add ValidatedUrl to did-fail-load event
This commit is contained in:
@@ -388,7 +388,7 @@ void WebContents::DidFailProvisionalLoad(
|
||||
int error_code,
|
||||
const base::string16& error_description,
|
||||
bool was_ignored_by_handler) {
|
||||
Emit("did-fail-load", error_code, error_description);
|
||||
Emit("did-fail-load", error_code, error_description, validated_url);
|
||||
}
|
||||
|
||||
void WebContents::DidFailLoad(content::RenderFrameHost* render_frame_host,
|
||||
@@ -396,7 +396,7 @@ void WebContents::DidFailLoad(content::RenderFrameHost* render_frame_host,
|
||||
int error_code,
|
||||
const base::string16& error_description,
|
||||
bool was_ignored_by_handler) {
|
||||
Emit("did-fail-load", error_code, error_description);
|
||||
Emit("did-fail-load", error_code, error_description, validated_url);
|
||||
}
|
||||
|
||||
void WebContents::DidStartLoading() {
|
||||
|
||||
@@ -6,7 +6,7 @@ requestId = 0
|
||||
WEB_VIEW_EVENTS =
|
||||
'load-commit': ['url', 'isMainFrame']
|
||||
'did-finish-load': []
|
||||
'did-fail-load': ['errorCode', 'errorDescription']
|
||||
'did-fail-load': ['errorCode', 'errorDescription', 'validatedUrl']
|
||||
'did-frame-finish-load': ['isMainFrame']
|
||||
'did-start-loading': []
|
||||
'did-stop-loading': []
|
||||
|
||||
@@ -32,6 +32,7 @@ Returns:
|
||||
* `event` Event
|
||||
* `errorCode` Integer
|
||||
* `errorDescription` String
|
||||
* `validatedUrl` String
|
||||
|
||||
This event is like `did-finish-load` but emitted when the load failed or was
|
||||
cancelled, e.g. `window.stop()` is invoked.
|
||||
|
||||
@@ -384,6 +384,7 @@ Returns:
|
||||
|
||||
* `errorCode` Integer
|
||||
* `errorDescription` String
|
||||
* `validatedUrl` String
|
||||
|
||||
This event is like `did-finish-load`, but fired when the load failed or was
|
||||
cancelled, e.g. `window.stop()` is invoked.
|
||||
|
||||
Reference in New Issue
Block a user