Changeset 31320 in webkit


Ignore:
Timestamp:
Mar 26, 2008 10:49:32 AM (16 years ago)
Author:
Adam Roben
Message:

Fix Bug 17768: REGRESSION (r30146): Inspector no longer shows elements properties

<http://bugs.webkit.org/show_bug.cgi?id=17768>

We were throwing an exception from Object.describe because of some
undefined variables.

Reviewed by Tim Hatcher.

  • page/inspector/utilities.js: (Object.describe): Reinstate the type1 and type2 variables that were removed in r30146. They're still used when formatting a function.
Location:
trunk/WebCore
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/WebCore/ChangeLog

    r31317 r31320  
     12008-03-26  Adam Roben  <aroben@apple.com>
     2
     3        Fix Bug 17768: REGRESSION (r30146): Inspector no longer shows elements
     4        properties
     5
     6        <http://bugs.webkit.org/show_bug.cgi?id=17768>
     7
     8        We were throwing an exception from Object.describe because of some
     9        undefined variables.
     10
     11        Reviewed by Tim Hatcher.
     12
     13        * page/inspector/utilities.js:
     14        (Object.describe): Reinstate the type1 and type2 variables that were
     15        removed in r30146. They're still used when formatting a function.
     16
    1172008-03-26  Eric Seidel  <eric@webkit.org>
    218
  • trunk/WebCore/page/inspector/utilities.js

    r31159 r31320  
    5555Object.describe = function(obj, abbreviated)
    5656{
    57     switch (Object.type(obj)) {
     57    var type1 = Object.type(obj);
     58    var type2 = Object.prototype.toString.call(obj).replace(/^\[object (.*)\]$/i, "$1");
     59
     60    switch (type1) {
    5861    case "object":
    59         return Object.prototype.toString.call(obj).replace(/^\[object (.*)\]$/i, "$1");
     62        return type2;
    6063    case "array":
    6164        return "[" + obj.toString() + "]";
Note: See TracChangeset for help on using the changeset viewer.