Skip to content
This repository has been archived by the owner on Oct 8, 2021. It is now read-only.

Commit

Permalink
Pagecontainer: Pass triggerData with load event
Browse files Browse the repository at this point in the history
Fixes gh-7580
Closes gh-7581

(cherry picked from commit af08283)
  • Loading branch information
Rob DiCiuccio authored and arschmitz committed Aug 26, 2014
1 parent 62695d4 commit d1bb77f
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion js/widgets/pagecontainer.js
Expand Up @@ -538,7 +538,7 @@ define( [
// Note that it is the responsibility of the listener/handler
// that called preventDefault(), to resolve/reject the
// deferred object within the triggerData.
if ( this._triggerWithDeprecated( "load" ).event.isDefaultPrevented() ) {
if ( this._triggerWithDeprecated( "load", triggerData ).event.isDefaultPrevented() ) {
return;
}

Expand Down
4 changes: 2 additions & 2 deletions tests/integration/pagecontainer/page_event_sequence_core.js
Expand Up @@ -98,11 +98,11 @@ asyncTest( "Event sequence during navigation to another page", function() {

// Deprecated as of 1.4.0
{ type: "pageload", target: "the-body",
data: { prevPage: undefined, nextPage: undefined, toPage: undefined } },
data: { prevPage: "start-page", nextPage: undefined, toPage: "other-page" } },

// Valid
{ type: "pagecontainerload", target: "the-body",
data: { prevPage: undefined, nextPage: undefined, toPage: undefined } },
data: { prevPage: "start-page", nextPage: undefined, toPage: "other-page" } },

// Valid - page widget events
{ type: "pagebeforecreate", target: "other-page",
Expand Down

0 comments on commit d1bb77f

Please sign in to comment.