/**
 * @author alteredq / http://alteredqualia.com/
 */

THREE.Clock = function ( autoStart ) {

	this.autoStart = ( autoStart !== undefined ) ? autoStart : true;

	this.startTime = 0;
	this.oldTime = 0;
	this.elapsedTime = 0;

	this.running = false;

};

THREE.Clock.prototype = {

	constructor: THREE.Clock,

	start: function () {

		this.startTime = this._getNow();

		this.oldTime = this.startTime;
		this.running = true;

	},

	stop: function () {

		this.getElapsedTime();
		this.running = false;

	},

	getElapsedTime: function () {

		this.getDelta();
		return this.elapsedTime;

	},

	getDelta: function () {

		var diff = 0;

		if ( this.autoStart && ! this.running ) {

			this.start();

		}

		if ( this.running ) {

			var newTime = this._getNow();

			diff = 0.001 * ( newTime - this.oldTime );
			this.oldTime = newTime;

			this.elapsedTime += diff;

		}

		return diff;

	},

	_getNow: function () {
		var now = self.performance !== undefined && self.performance.now !== undefined
			? self.performance.now()
			: Date.now();

		return now;
	}

};

@@ -304,16 +304,168 @@
 Clock,%0A%0A
+%09_now: function () %7B%0A%0A%09 %09return self.performance !== undefined && self.performance.now !== undefined%0A%09%09%09? self.performance.now()%0A%09%09%09: Date.now();%0A%0A%09%7D,%0A%0A
 %09start: 
@@ -496,36 +496,33 @@
 artTime = this._
-getN
+n
 ow();%0A%0A%09%09this.ol
@@ -894,20 +894,17 @@
 = this._
-getN
+n
 ow();%0A%0A%09
@@ -1031,178 +1031,8 @@
 f;%0A%0A
-%09%7D,%0A%0A%09_getNow: function () %7B%0A%09%09var now = self.performance !== undefined && self.performance.now !== undefined%0A%09%09%09? self.performance.now()%0A%09%09%09: Date.now();%0A%0A%09%09return now;%0A
 %09%7D%0A%0A

Clean up.