Updating to the latest Dromaeo.

Review URL: http://codereview.chromium.org/519009



Cr-Mirrored-From: https://chromium.googlesource.com/chromium/src
Cr-Mirrored-Commit: c2c1d9a9c1643fdda7ee0335d7d9b0e9a4a92420
diff --git a/webrunner.js b/webrunner.js
index 3a09b4a..655bcc0 100644
--- a/webrunner.js
+++ b/webrunner.js
@@ -234,7 +234,7 @@
 	var post_json = false;
 	
 	// Query String Parsing
-	var search = (window.location.search || "?").substr(1);
+	var search = window.limitSearch || (window.location.search || "?").substr(1);
 
 	search = search.replace(/&runStyle=([^&]+)/, function(all, type){
 		runStyle = type;
@@ -365,8 +365,25 @@
 			
 			$("#overview input").remove();
 			updateTimebar();
+
+			if ( window.limitSearch ) {
+				var summary = (runStyle === "runs/s" ? Math.pow(Math.E, maxTotal / maxTotalNum) : maxTotal).toFixed(2);
+
+				if ( typeof tpRecordTime !== "undefined" ) {
+					tpRecordTime( summary );
+
+				} else {
+					var pre = document.createElement("pre");
+					pre.style.display = "none";
+					pre.innerHTML = "__start_report" + summary + "__end_report";
+					document.body.appendChild( pre );
+				}
+
+				if ( typeof goQuitApplication !== "undefined" ) {
+					goQuitApplication();
+				}
 	
-			if ( dataStore && dataStore.length ) {
+			} else if ( dataStore && dataStore.length ) {
 				if (!automated || post_json) {
 					$("body").addClass("alldone");
 					var div = jQuery("<div class='results'>Saving...</div>").insertBefore("#overview");
@@ -422,6 +439,10 @@
 			interval = true;
 			dequeue();
 		}
+
+		if ( window.limitSearch ) {
+			$("#pause").click();
+		}
 	}
 
 	function initTest(curID){