Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
tomhuda
committed
Dec 30, 2012
1 parent
7da1b29
commit ca9968a
Showing
10 changed files
with
10,310 additions
and
9,844 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Original file line | Diff line number | Diff line change |
---|---|---|---|
@@ -0,0 +1,14 @@ | |||
var DeferredMixin = Ember.DeferredMixin, // ember-runtime/mixins/deferred | |||
Evented = Ember.Evented, // ember-runtime/mixins/evented | |||
run = Ember.run; // ember-metal/run-loop | |||
|
|||
var LoadPromise = Ember.Mixin.create(Evented, DeferredMixin, { | |||
init: function() { | |||
this._super.apply(this, arguments); | |||
this.one('didLoad', function() { | |||
run(this, 'resolve', this); | |||
This comment has been minimized.
Sorry, something went wrong.
This comment has been minimized.
Sorry, something went wrong.
stefanpenner
Member
|
|||
}); | |||
} | |||
}); | |||
|
|||
DS.LoadPromise = LoadPromise; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
1 comment
on commit ca9968a
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
DS.LoadPromise includes Ember.Evented so DS.Model and DS.RecordArray don't need to include it again.
Ember.run should be in the adapter in the ajax event handler, not here, this causes a lot of nested run loops. cc @stefanpenner