Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(708)

Unified Diff: third_party/WebKit/Source/devtools/front_end/platform/utilities.js

Issue 1403373013: DevTools: move ui messages from SourceFrame to UISourceCodeFrame (step2) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: review comments addressed Created 5 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/devtools/front_end/platform/utilities.js
diff --git a/third_party/WebKit/Source/devtools/front_end/platform/utilities.js b/third_party/WebKit/Source/devtools/front_end/platform/utilities.js
index 7e972bf8de041cd79b1ddb4dc9ee099be5d599ba..93e797abd1d5ee7e7e4ea2debb883f2aea17a9b3 100644
--- a/third_party/WebKit/Source/devtools/front_end/platform/utilities.js
+++ b/third_party/WebKit/Source/devtools/front_end/platform/utilities.js
@@ -481,6 +481,7 @@ Object.defineProperty(Array.prototype, "remove",
/**
* @param {!T} value
* @param {boolean=} firstOnly
+ * @return {boolean}
* @this {Array.<!T>}
* @template T
*/
@@ -488,16 +489,17 @@ Object.defineProperty(Array.prototype, "remove",
{
var index = this.indexOf(value);
if (index === -1)
- return;
+ return false;
if (firstOnly) {
this.splice(index, 1);
- return;
+ return true;
}
for (var i = index + 1, n = this.length; i < n; ++i) {
if (this[i] !== value)
this[index++] = this[i];
}
this.length = index;
+ return true;
}
});

Powered by Google App Engine
This is Rietveld 408576698