Merge pull request #407 from Samangan/master

renamed ReactOnDOMReady module to ReactMountReady
This commit is contained in:
Paul O’Shannessy
2013-10-08 15:12:29 -07:00
3 changed files with 19 additions and 19 deletions
+2 -2
View File
@@ -579,7 +579,7 @@ var ReactCompositeComponentMixin = {
mountDepth + 1
);
if (this.componentDidMount) {
transaction.getReactOnDOMReady().enqueue(this, this.componentDidMount);
transaction.getReactMountReady().enqueue(this, this.componentDidMount);
}
return markup;
}
@@ -765,7 +765,7 @@ var ReactCompositeComponentMixin = {
this.updateComponent(transaction, prevProps, prevState);
if (this.componentDidUpdate) {
transaction.getReactOnDOMReady().enqueue(
transaction.getReactMountReady().enqueue(
this,
this.componentDidUpdate.bind(this, prevProps, prevState)
);
@@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*
* @providesModule ReactOnDOMReady
* @providesModule ReactMountReady
*/
"use strict";
@@ -27,18 +27,18 @@ var mixInto = require('mixInto');
* be notified when their DOM representations are available for use.
*
* This implements `PooledClass`, so you should never need to instantiate this.
* Instead, use `ReactOnDOMReady.getPooled()`.
* Instead, use `ReactMountReady.getPooled()`.
*
* @param {?array<function>} initialCollection
* @class ReactOnDOMReady
* @class ReactMountReady
* @implements PooledClass
* @internal
*/
function ReactOnDOMReady(initialCollection) {
function ReactMountReady(initialCollection) {
this._queue = initialCollection || null;
}
mixInto(ReactOnDOMReady, {
mixInto(ReactMountReady, {
/**
* Enqueues a callback to be invoked when `notifyAll` is invoked. This is used
@@ -90,6 +90,6 @@ mixInto(ReactOnDOMReady, {
});
PooledClass.addPoolingTo(ReactOnDOMReady);
PooledClass.addPoolingTo(ReactMountReady);
module.exports = ReactOnDOMReady;
module.exports = ReactMountReady;
+10 -10
View File
@@ -23,7 +23,7 @@ var ExecutionEnvironment = require('ExecutionEnvironment');
var PooledClass = require('PooledClass');
var ReactEventEmitter = require('ReactEventEmitter');
var ReactInputSelection = require('ReactInputSelection');
var ReactOnDOMReady = require('ReactOnDOMReady');
var ReactMountReady = require('ReactMountReady');
var Transaction = require('Transaction');
var mixInto = require('mixInto');
@@ -69,7 +69,7 @@ var EVENT_SUPPRESSION = {
};
/**
* Provides a `ReactOnDOMReady` queue for collecting `onDOMReady` callbacks
* Provides a `ReactMountReady` queue for collecting `onDOMReady` callbacks
* during the performing of the transaction.
*/
var ON_DOM_READY_QUEUEING = {
@@ -77,14 +77,14 @@ var ON_DOM_READY_QUEUEING = {
* Initializes the internal `onDOMReady` queue.
*/
initialize: function() {
this.reactOnDOMReady.reset();
this.reactMountReady.reset();
},
/**
* After DOM is flushed, invoke all registered `onDOMReady` callbacks.
*/
close: function() {
this.reactOnDOMReady.notifyAll();
this.reactMountReady.notifyAll();
}
};
@@ -115,7 +115,7 @@ var TRANSACTION_WRAPPERS = [
*/
function ReactReconcileTransaction() {
this.reinitializeTransaction();
this.reactOnDOMReady = ReactOnDOMReady.getPooled(null);
this.reactMountReady = ReactMountReady.getPooled(null);
}
var Mixin = {
@@ -136,10 +136,10 @@ var Mixin = {
/**
* @return {object} The queue to collect `onDOMReady` callbacks with.
* TODO: convert to ReactOnDOMReady
* TODO: convert to ReactMountReady
*/
getReactOnDOMReady: function() {
return this.reactOnDOMReady;
getReactMountReady: function() {
return this.reactMountReady;
},
/**
@@ -147,8 +147,8 @@ var Mixin = {
* instance to be resused.
*/
destructor: function() {
ReactOnDOMReady.release(this.reactOnDOMReady);
this.reactOnDOMReady = null;
ReactMountReady.release(this.reactMountReady);
this.reactMountReady = null;
}
};