Reviewed by Tim Hatcher.
authordarin <darin@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 31 Jul 2006 07:07:12 +0000 (07:07 +0000)
committerdarin <darin@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 31 Jul 2006 07:07:12 +0000 (07:07 +0000)
        * WebInspector/webInspector/inspector.js: Fix bug where a null property value
        leads to an empty style pane.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@15703 268f45cc-cd09-0410-ab3c-d52691b4dbfc

WebKit/ChangeLog
WebKit/WebInspector/webInspector/inspector.js

index 2623356..df6ea54 100644 (file)
@@ -2,6 +2,13 @@
 
         Reviewed by Tim Hatcher.
 
+        * WebInspector/webInspector/inspector.js: Fix bug where a null property value
+        leads to an empty style pane.
+
+2006-07-30  Darin Adler  <darin@apple.com>
+
+        Reviewed by Tim Hatcher.
+
         - some improvements for the inspector
 
         * WebInspector/WebInspector.m:
index 3c8b6bf..f4154fe 100644 (file)
@@ -641,13 +641,15 @@ function styleRuleSelect(event)
 
 function populateStyleListItem(li, prop, name)
 {
-    var value = prop.style.getPropertyValue(name);
-
     var span = document.createElement("span");
     span.className = "property";
     span.textContent = name;
     li.appendChild(span);
 
+    var value = prop.style.getPropertyValue(name);
+    if (!value)
+        return;
+
     span = document.createElement("span");
     span.className = "value";
     var textValue = valueNickname[value] ? valueNickname[value] : value;