this.useCreateElement = true;
  this.reinitializeTransaction();
  this.reactMountReady = CallbackQueue.getPooled(null);
}

const Mixin = {
  getTransactionWrappers: function() {
    return [ON_READY_QUEUEING];
  },
  getReactMountReady: function() {
    return this.reactMountReady;
  },
  destructor: function() {
    CallbackQueue.release(this.reactMountReady);
    this.reactMountReady = null;
  },
  getUpdateQueue: function () {
    return ReactUpdateQueue;
  }
};

Object.assign(
  ReactWWReconcileTransaction.prototype,
  Transaction.Mixin,
  Mixin
);

PooledClass.addPoolingTo(ReactWWReconcileTransaction);

export default ReactWWReconcileTransaction;
Example #2
0

'use strict';

var PooledClass = require('react/lib/PooledClass');

var twoArgumentPooler = PooledClass.twoArgumentPooler;

function Position(left, top) {
  this.left = left;
  this.top = top;
}

Position.prototype.destructor = function () {
  this.left = null;
  this.top = null;
};

PooledClass.addPoolingTo(Position, twoArgumentPooler);

module.exports = Position;
  }
};

function ReactBlessedReconcileTransaction() {
  this.reinitializeTransaction();
  this.reactMountReady = CallbackQueue.getPooled(null);
}

const Mixin = {
  getTransactionWrappers: function() {
    return [ON_BLESSED_READY_QUEUEING];
  },
  getReactMountReady: function() {
    return this.reactMountReady;
  },
  destructor: function() {
    CallbackQueue.release(this.reactMountReady);
    this.reactMountReady = null;
  }
};

extend(
  ReactBlessedReconcileTransaction.prototype,
  Transaction.Mixin,
  Mixin
);

PooledClass.addPoolingTo(ReactBlessedReconcileTransaction);

export default ReactBlessedReconcileTransaction;
  },

  /**
   * @return {object} The queue to collect `ready` callbacks with.
   */
  getReactMountReady: function() {
    return this.reactMountReady;
  },

  /**
   * `PooledClass` looks for this, and will invoke this before allowing this
   * instance to be reused.
   */
  destructor: function() {
    CallbackQueue.release(this.reactMountReady);
    this.reactMountReady = null;
  },
};

Object.assign(
  TinyRendererReconcileTransaction.prototype,
  Transaction.Mixin,
  TinyRendererReconcileTransaction,
  Mixin
);

PooledClass.addPoolingTo(TinyRendererReconcileTransaction);

module.exports = TinyRendererReconcileTransaction;







function BoundingDimensions(width,height){
this.width=width;
this.height=height;
}

BoundingDimensions.prototype.destructor=function(){
this.width=null;
this.height=null;
};





BoundingDimensions.getPooledFromElement=function(element){
return BoundingDimensions.getPooled(
element.offsetWidth,
element.offsetHeight);

};

PooledClass.addPoolingTo(BoundingDimensions,twoArgumentPooler);

module.exports=BoundingDimensions;
  this.reinitializeTransaction();
  this.renderToStaticMarkup = false;
  this.reactMountReady = CallbackQueue.getPooled(null);
  this.useCreateElement = false;
};

var Mixin = {
  getTransactionWrappers: function getTransactionWrappers() {
    return [{
      initialize: function initialize() {
        this.reactMountReady.reset();
      },
      close: function close() {
        this.reactMountReady.notifyAll();
      }
    }];
  },
  getReactMountReady: function getReactMountReady() {
    return this.reactMountReady;
  },
  destructor: function destructor() {
    CallbackQueue.release(this.reactMountReady);
    this.reactMountReady = null;
  }
};

assign(JSONReconcileTransaction.prototype, Transaction.Mixin, Mixin);

PooledClass.addPoolingTo(JSONReconcileTransaction);

module.exports = JSONReconcileTransaction;
import EventEmitter from 'eventemitter3';
import ReactUpdates from 'react/lib/ReactUpdates';
import ReactReconcileTransaction from 'react/lib/ReactReconcileTransaction';
import CallbackQueue from 'react/lib/CallbackQueue';
import PooledClass from 'react/lib/PooledClass';

let afterComponentDidUpdate = new EventEmitter();

class CallbackQueueWithNotifier extends CallbackQueue {
    notifyAll() {
        super.notifyAll();
        afterComponentDidUpdate.emit('update');
    }
}
PooledClass.addPoolingTo(CallbackQueueWithNotifier);

class ReactReconcileTransactionWithNotifier extends ReactReconcileTransaction {
    constructor() {
        super();
        this.reactMountReady = CallbackQueueWithNotifier.getPooled(null);
    }

    destructor() {
        CallbackQueueWithNotifier.release(this.reactMountReady);
        this.reactMountReady = null;
    }
}
PooledClass.addPoolingTo(ReactReconcileTransactionWithNotifier);

/**
 * Accumulates react dom changes using request animation frame