Log Message
Web Inspector: Improve native parameter lists a bit https://bugs.webkit.org/show_bug.cgi?id=145338
Patch by Joseph Pecoraro <[email protected]> on 2015-05-23 Reviewed by Timothy Hatcher. * UserInterface/Models/NativeFunctionParameters.js: * UserInterface/Views/ObjectTreePropertyTreeElement.js: (WebInspector.ObjectTreePropertyTreeElement.prototype._functionParameterString):
Modified Paths
Diff
Modified: trunk/Source/WebInspectorUI/ChangeLog (184822 => 184823)
--- trunk/Source/WebInspectorUI/ChangeLog 2015-05-23 15:01:59 UTC (rev 184822)
+++ trunk/Source/WebInspectorUI/ChangeLog 2015-05-23 15:03:43 UTC (rev 184823)
@@ -1,5 +1,16 @@
2015-05-23 Joseph Pecoraro <[email protected]>
+ Web Inspector: Improve native parameter lists a bit
+ https://bugs.webkit.org/show_bug.cgi?id=145338
+
+ Reviewed by Timothy Hatcher.
+
+ * UserInterface/Models/NativeFunctionParameters.js:
+ * UserInterface/Views/ObjectTreePropertyTreeElement.js:
+ (WebInspector.ObjectTreePropertyTreeElement.prototype._functionParameterString):
+
+2015-05-23 Joseph Pecoraro <[email protected]>
+
Web Inspector: Update CSS Autocompletion properties and values
https://bugs.webkit.org/show_bug.cgi?id=145341
Modified: trunk/Source/WebInspectorUI/UserInterface/Models/NativeFunctionParameters.js (184822 => 184823)
--- trunk/Source/WebInspectorUI/UserInterface/Models/NativeFunctionParameters.js 2015-05-23 15:01:59 UTC (rev 184822)
+++ trunk/Source/WebInspectorUI/UserInterface/Models/NativeFunctionParameters.js 2015-05-23 15:03:43 UTC (rev 184823)
@@ -30,19 +30,21 @@
Object: {
assign: "target, ...sources",
create: "prototype, [propertiesObject]",
+ defineProperties: "object, properties",
defineProperty: "object, propertyName, descriptor",
- defineProperties: "object, properties",
freeze: "object",
getOwnPropertyDescriptor: "object, propertyName",
getOwnPropertyNames: "object",
getOwnPropertySymbols: "object",
getPrototypeOf: "object",
+ is: "value1, value2",
isExtensible: "object",
isFrozen: "object",
isSealed: "object",
keys: "object",
preventExtensions: "object",
seal: "object",
+ setPrototypeOf: "object, prototype",
__proto__: null,
},
@@ -75,11 +77,12 @@
acosh: "x",
asin: "x",
asinh: "x",
+ atan2: "y, x",
atan: "x",
- atan2: "y, x",
atanh: "x",
cbrt: "x",
ceil: "x",
+ clz32: "x",
cos: "x",
cosh: "x",
exp: "x",
@@ -96,6 +99,7 @@
min: "[...x]",
pow: "x, y",
round: "x",
+ sign: "x",
sin: "x",
sinh: "x",
sqrt: "x",
@@ -126,7 +130,9 @@
},
String: {
- fromCharCode: "code, [...codes]",
+ fromCharCode: "...codeUnits",
+ fromCodePoint: "...codePoints",
+ raw: "template, ...substitutions",
__proto__: null,
},
@@ -300,12 +306,14 @@
String: {
charAt: "index",
charCodeAt: "index",
+ codePoints: "index",
concat: "string, ...",
includes: "searchValue, [startIndex=0]",
indexOf: "searchValue, [startIndex=0]",
lastIndexOf: "searchValue, [startIndex=length]",
localeCompare: "string",
match: "regex",
+ repeat: "count",
replace: "regex|string, replaceString|replaceHandler, [flags]",
search: "regex",
slice: "startIndex, [endIndex=length]",
@@ -733,6 +741,7 @@
},
DocumentFragment: {
+ getElementById: "id",
querySelector: "selectors",
querySelectorAll: "selectors",
__proto__: null,
Modified: trunk/Source/WebInspectorUI/UserInterface/Views/ObjectTreePropertyTreeElement.js (184822 => 184823)
--- trunk/Source/WebInspectorUI/UserInterface/Views/ObjectTreePropertyTreeElement.js 2015-05-23 15:01:59 UTC (rev 184822)
+++ trunk/Source/WebInspectorUI/UserInterface/Views/ObjectTreePropertyTreeElement.js 2015-05-23 15:03:43 UTC (rev 184823)
@@ -257,9 +257,11 @@
}
}
+ var parentDescription = this._propertyPath.object.description;
+
// Native function property on a native function is likely a "Foo.method".
- if (isFunctionStringNativeCode(this._propertyPath.object.description)) {
- var match = this._propertyPath.object.description.match(/^function\s+([^)]+?)\(/);
+ if (isFunctionStringNativeCode(parentDescription)) {
+ var match = parentDescription.match(/^function\s+([^)]+?)\(/);
if (match) {
var name = match[1];
if (WebInspector.NativeConstructorFunctionParameters[name]) {
@@ -269,9 +271,9 @@
}
}
- // Native DOM constructor.
- if (this._propertyPath.object.description.endsWith("Constructor")) {
- var name = this._propertyPath.object.description;
+ // Native DOM constructor or on native objects that are not functions.
+ if (parentDescription.endsWith("Constructor") || parentDescription === "Math" || parentDescription === "JSON") {
+ var name = parentDescription;
if (WebInspector.NativeConstructorFunctionParameters[name]) {
var params = WebInspector.NativeConstructorFunctionParameters[name][this._property.name];
return params ? "(" + params + ")" : "()";
_______________________________________________ webkit-changes mailing list [email protected] https://lists.webkit.org/mailman/listinfo/webkit-changes
