[SCM] WebKit Debian packaging branch, debian/experimental, updated. upstream/1.3.3-9427-gc2be6fc

morrita at google.com morrita at google.com
Wed Dec 22 15:14:26 UTC 2010


The following commit has been merged in the debian/experimental branch:
commit 2611bce4f72c9cbcca2e995bdc0ab9b8d55d8042
Author: morrita at google.com <morrita at google.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Fri Oct 29 09:47:03 2010 +0000

    2010-10-28  MORITA Hajime  <morrita at google.com>
    
            Reviewed by Kent Tamura.
    
            <meter min=0 max=100 value=100> should be optimum.
            https://bugs.webkit.org/show_bug.cgi?id=48613
    
            * fast/dom/HTMLMeterElement/meter-boundary-values.html: Added.
            * platform/mac/fast/dom/HTMLMeterElement/meter-appearances-capacity-expected.checksum:
            * platform/mac/fast/dom/HTMLMeterElement/meter-appearances-capacity-expected.png:
            * platform/mac/fast/dom/HTMLMeterElement/meter-boundary-values-expected.checksum: Added.
            * platform/mac/fast/dom/HTMLMeterElement/meter-boundary-values-expected.png: Added.
            * platform/mac/fast/dom/HTMLMeterElement/meter-boundary-values-expected.txt: Added.
            * platform/mac/fast/dom/HTMLMeterElement/meter-optimums-expected.checksum:
            * platform/mac/fast/dom/HTMLMeterElement/meter-optimums-expected.png:
    2010-10-28  MORITA Hajime  <morrita at google.com>
    
            Reviewed by Kent Tamura.
    
            <meter min=0 max=100 value=100> should be optimum.
            https://bugs.webkit.org/show_bug.cgi?id=48613
    
            Changed to make the condition inclusive for better case consistently.
            - Values on the border between optimum and subsequntial go optimum.
            - Values on the border between suboptimal and even-less-than-good go suboptimal.
    
            Test: fast/dom/HTMLMeterElement/meter-boundary-values.html
    
            * html/HTMLMeterElement.cpp:
            (WebCore::HTMLMeterElement::gaugeRegion):
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@70856 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/LayoutTests/ChangeLog b/LayoutTests/ChangeLog
index ee5cb65..25fd79f 100644
--- a/LayoutTests/ChangeLog
+++ b/LayoutTests/ChangeLog
@@ -1,3 +1,19 @@
+2010-10-28  MORITA Hajime  <morrita at google.com>
+
+        Reviewed by Kent Tamura.
+
+        <meter min=0 max=100 value=100> should be optimum.
+        https://bugs.webkit.org/show_bug.cgi?id=48613
+
+        * fast/dom/HTMLMeterElement/meter-boundary-values.html: Added.
+        * platform/mac/fast/dom/HTMLMeterElement/meter-appearances-capacity-expected.checksum:
+        * platform/mac/fast/dom/HTMLMeterElement/meter-appearances-capacity-expected.png:
+        * platform/mac/fast/dom/HTMLMeterElement/meter-boundary-values-expected.checksum: Added.
+        * platform/mac/fast/dom/HTMLMeterElement/meter-boundary-values-expected.png: Added.
+        * platform/mac/fast/dom/HTMLMeterElement/meter-boundary-values-expected.txt: Added.
+        * platform/mac/fast/dom/HTMLMeterElement/meter-optimums-expected.checksum:
+        * platform/mac/fast/dom/HTMLMeterElement/meter-optimums-expected.png:
+
 2010-10-29  Mikhail Naganov  <mnaganov at chromium.org>
 
         [Chromium] Unreviewed test expectations update after r70843.
diff --git a/LayoutTests/fast/dom/HTMLMeterElement/meter-boundary-values.html b/LayoutTests/fast/dom/HTMLMeterElement/meter-boundary-values.html
new file mode 100644
index 0000000..3fad754
--- /dev/null
+++ b/LayoutTests/fast/dom/HTMLMeterElement/meter-boundary-values.html
@@ -0,0 +1,26 @@
+<html>
+<head>
+</head>
+<body>
+  <h1>Meters with border values</h1>
+  <ul>
+    <li>min,low,optimal,high,max</li>
+    <li><b>9</b>|10,20,30,40,50: <meter min="10" low="20" optimum="30" high="40" max="50" value="9" ></meter></li>
+    <li><b>10</b>,20,30,40,50: <meter min="10" low="20" optimum="30" high="40" max="50" value="10" ></meter></li>
+    <li>10,<b>20</b>,30,40,50: <meter min="10" low="20" optimum="30" high="40" max="50" value="20" ></meter>(should be green)</li>
+    <li>10,20,<b>30</b>,40,50: <meter min="10" low="20" optimum="30" high="40" max="50" value="30" ></meter>(should be green)</li>
+    <li>10,20,30,<b>40</b>,50: <meter min="10" low="20" optimum="30" high="40" max="50" value="40" ></meter>(should be green)</li>
+    <li>10,20,30,40,<b>50</b>: <meter min="10" low="20" optimum="30" high="40" max="50" value="50" ></meter>(should be yellow)</li>
+    <li>10,20,30,40,50|<b>51</b>: <meter min="10" low="20" optimum="30" high="40" max="50" value="51" ></meter>(should be yellow)</li>
+
+    <li>10,<b>10</b>,30,40,50: <meter min="10" low="10" optimum="30" high="40" max="50" value="10" ></meter></li>
+    <li>10,20,30,<b>40</b>,40: <meter min="10" low="20" optimum="30" high="40" max="40" value="40" ></meter>(should be green)</li>
+
+    <li><b>9</b>|10,10,10,20,30: <meter min="10" low="10" optimum="10" high="20" max="30" value="9" ></meter></li>
+    <li>10,10,<b>10</b>,20,30: <meter min="10" low="10" optimum="10" high="20" max="30" value="10" ></meter></li>
+    <li>10,20,<b>30</b>,30,30: <meter min="10" low="20" optimum="30" high="30" max="30" value="30" ></meter>(should be green)</li>
+    <li>10,20,30,30,30|<b>31</b>: <meter min="10" low="20" optimum="30" high="30" max="30" value="31" ></meter>(should be green)</li>
+    <li>10,20,<b>20</b>,20,30: <meter min="10" low="20" optimum="20" high="20" max="30" value="20" ></meter>(should be green)</li>
+  </ul>
+</body>
+</html>
diff --git a/LayoutTests/platform/mac/fast/dom/HTMLMeterElement/meter-appearances-capacity-expected.checksum b/LayoutTests/platform/mac/fast/dom/HTMLMeterElement/meter-appearances-capacity-expected.checksum
index f8fc61f..8cea7b1 100644
--- a/LayoutTests/platform/mac/fast/dom/HTMLMeterElement/meter-appearances-capacity-expected.checksum
+++ b/LayoutTests/platform/mac/fast/dom/HTMLMeterElement/meter-appearances-capacity-expected.checksum
@@ -1 +1 @@
-46e2fa5e215820fcbb9e81907bd5ceae
\ No newline at end of file
+314ea34798b15729e0e257ce25f1128e
\ No newline at end of file
diff --git a/LayoutTests/platform/mac/fast/dom/HTMLMeterElement/meter-appearances-capacity-expected.png b/LayoutTests/platform/mac/fast/dom/HTMLMeterElement/meter-appearances-capacity-expected.png
index 8c63735..47ff0f7 100644
Binary files a/LayoutTests/platform/mac/fast/dom/HTMLMeterElement/meter-appearances-capacity-expected.png and b/LayoutTests/platform/mac/fast/dom/HTMLMeterElement/meter-appearances-capacity-expected.png differ
diff --git a/LayoutTests/platform/mac/fast/dom/HTMLMeterElement/meter-boundary-values-expected.checksum b/LayoutTests/platform/mac/fast/dom/HTMLMeterElement/meter-boundary-values-expected.checksum
new file mode 100644
index 0000000..9b0164e
--- /dev/null
+++ b/LayoutTests/platform/mac/fast/dom/HTMLMeterElement/meter-boundary-values-expected.checksum
@@ -0,0 +1 @@
+4f220d49011c4516ba3c79d5d567d0cf
\ No newline at end of file
diff --git a/LayoutTests/platform/mac/fast/dom/HTMLMeterElement/meter-boundary-values-expected.png b/LayoutTests/platform/mac/fast/dom/HTMLMeterElement/meter-boundary-values-expected.png
new file mode 100644
index 0000000..3f66a47
Binary files /dev/null and b/LayoutTests/platform/mac/fast/dom/HTMLMeterElement/meter-boundary-values-expected.png differ
diff --git a/LayoutTests/platform/mac/fast/dom/HTMLMeterElement/meter-boundary-values-expected.txt b/LayoutTests/platform/mac/fast/dom/HTMLMeterElement/meter-boundary-values-expected.txt
new file mode 100644
index 0000000..a09df68
--- /dev/null
+++ b/LayoutTests/platform/mac/fast/dom/HTMLMeterElement/meter-boundary-values-expected.txt
@@ -0,0 +1,165 @@
+layer at (0,0) size 800x600
+  RenderView at (0,0) size 800x600
+layer at (0,0) size 800x600
+  RenderBlock {HTML} at (0,0) size 800x600
+    RenderBody {BODY} at (8,8) size 784x576
+      RenderBlock {H1} at (0,0) size 784x37
+        RenderText {#text} at (0,0) size 359x37
+          text run at (0,0) width 359: "Meters with border values"
+      RenderBlock {UL} at (0,58) size 784x270
+        RenderListItem {LI} at (40,0) size 744x18
+          RenderListMarker at (-17,0) size 7x18: bullet
+          RenderText {#text} at (0,0) size 166x18
+            text run at (0,0) width 166: "min,low,optimal,high,max"
+        RenderListItem {LI} at (40,18) size 744x18
+          RenderListMarker at (-17,0) size 7x18: bullet
+          RenderInline {B} at (0,0) size 8x18
+            RenderText {#text} at (0,0) size 8x18
+              text run at (0,0) width 8: "9"
+          RenderText {#text} at (8,0) size 107x18
+            text run at (8,0) width 107: "|10,20,30,40,50: "
+          RenderMeter {METER} at (115,1) size 80x16
+        RenderListItem {LI} at (40,36) size 744x18
+          RenderListMarker at (-17,0) size 7x18: bullet
+          RenderInline {B} at (0,0) size 16x18
+            RenderText {#text} at (0,0) size 16x18
+              text run at (0,0) width 16: "10"
+          RenderText {#text} at (16,0) size 88x18
+            text run at (16,0) width 88: ",20,30,40,50: "
+          RenderMeter {METER} at (104,1) size 80x16
+        RenderListItem {LI} at (40,54) size 744x18
+          RenderListMarker at (-17,0) size 7x18: bullet
+          RenderText {#text} at (0,0) size 20x18
+            text run at (0,0) width 20: "10,"
+          RenderInline {B} at (0,0) size 16x18
+            RenderText {#text} at (20,0) size 16x18
+              text run at (20,0) width 16: "20"
+          RenderText {#text} at (36,0) size 68x18
+            text run at (36,0) width 68: ",30,40,50: "
+          RenderMeter {METER} at (104,1) size 80x16
+          RenderText {#text} at (184,0) size 110x18
+            text run at (184,0) width 110: "(should be green)"
+        RenderListItem {LI} at (40,72) size 744x18
+          RenderListMarker at (-17,0) size 7x18: bullet
+          RenderText {#text} at (0,0) size 40x18
+            text run at (0,0) width 40: "10,20,"
+          RenderInline {B} at (0,0) size 16x18
+            RenderText {#text} at (40,0) size 16x18
+              text run at (40,0) width 16: "30"
+          RenderText {#text} at (56,0) size 48x18
+            text run at (56,0) width 48: ",40,50: "
+          RenderMeter {METER} at (104,1) size 80x16
+          RenderText {#text} at (184,0) size 110x18
+            text run at (184,0) width 110: "(should be green)"
+        RenderListItem {LI} at (40,90) size 744x18
+          RenderListMarker at (-17,0) size 7x18: bullet
+          RenderText {#text} at (0,0) size 60x18
+            text run at (0,0) width 60: "10,20,30,"
+          RenderInline {B} at (0,0) size 16x18
+            RenderText {#text} at (60,0) size 16x18
+              text run at (60,0) width 16: "40"
+          RenderText {#text} at (76,0) size 28x18
+            text run at (76,0) width 28: ",50: "
+          RenderMeter {METER} at (104,1) size 80x16
+          RenderText {#text} at (184,0) size 110x18
+            text run at (184,0) width 110: "(should be green)"
+        RenderListItem {LI} at (40,108) size 744x18
+          RenderListMarker at (-17,0) size 7x18: bullet
+          RenderText {#text} at (0,0) size 80x18
+            text run at (0,0) width 80: "10,20,30,40,"
+          RenderInline {B} at (0,0) size 16x18
+            RenderText {#text} at (80,0) size 16x18
+              text run at (80,0) width 16: "50"
+          RenderText {#text} at (96,0) size 8x18
+            text run at (96,0) width 8: ": "
+          RenderMeter {METER} at (104,1) size 80x16
+          RenderText {#text} at (184,0) size 118x18
+            text run at (184,0) width 118: "(should be yellow)"
+        RenderListItem {LI} at (40,126) size 744x18
+          RenderListMarker at (-17,0) size 7x18: bullet
+          RenderText {#text} at (0,0) size 99x18
+            text run at (0,0) width 99: "10,20,30,40,50|"
+          RenderInline {B} at (0,0) size 16x18
+            RenderText {#text} at (99,0) size 16x18
+              text run at (99,0) width 16: "51"
+          RenderText {#text} at (115,0) size 8x18
+            text run at (115,0) width 8: ": "
+          RenderMeter {METER} at (123,1) size 80x16
+          RenderText {#text} at (203,0) size 118x18
+            text run at (203,0) width 118: "(should be yellow)"
+        RenderListItem {LI} at (40,144) size 744x18
+          RenderListMarker at (-17,0) size 7x18: bullet
+          RenderText {#text} at (0,0) size 20x18
+            text run at (0,0) width 20: "10,"
+          RenderInline {B} at (0,0) size 16x18
+            RenderText {#text} at (20,0) size 16x18
+              text run at (20,0) width 16: "10"
+          RenderText {#text} at (36,0) size 68x18
+            text run at (36,0) width 68: ",30,40,50: "
+          RenderMeter {METER} at (104,1) size 80x16
+        RenderListItem {LI} at (40,162) size 744x18
+          RenderListMarker at (-17,0) size 7x18: bullet
+          RenderText {#text} at (0,0) size 60x18
+            text run at (0,0) width 60: "10,20,30,"
+          RenderInline {B} at (0,0) size 16x18
+            RenderText {#text} at (60,0) size 16x18
+              text run at (60,0) width 16: "40"
+          RenderText {#text} at (76,0) size 28x18
+            text run at (76,0) width 28: ",40: "
+          RenderMeter {METER} at (104,1) size 80x16
+          RenderText {#text} at (184,0) size 110x18
+            text run at (184,0) width 110: "(should be green)"
+        RenderListItem {LI} at (40,180) size 744x18
+          RenderListMarker at (-17,0) size 7x18: bullet
+          RenderInline {B} at (0,0) size 8x18
+            RenderText {#text} at (0,0) size 8x18
+              text run at (0,0) width 8: "9"
+          RenderText {#text} at (8,0) size 107x18
+            text run at (8,0) width 107: "|10,10,10,20,30: "
+          RenderMeter {METER} at (115,1) size 80x16
+        RenderListItem {LI} at (40,198) size 744x18
+          RenderListMarker at (-17,0) size 7x18: bullet
+          RenderText {#text} at (0,0) size 40x18
+            text run at (0,0) width 40: "10,10,"
+          RenderInline {B} at (0,0) size 16x18
+            RenderText {#text} at (40,0) size 16x18
+              text run at (40,0) width 16: "10"
+          RenderText {#text} at (56,0) size 48x18
+            text run at (56,0) width 48: ",20,30: "
+          RenderMeter {METER} at (104,1) size 80x16
+        RenderListItem {LI} at (40,216) size 744x18
+          RenderListMarker at (-17,0) size 7x18: bullet
+          RenderText {#text} at (0,0) size 40x18
+            text run at (0,0) width 40: "10,20,"
+          RenderInline {B} at (0,0) size 16x18
+            RenderText {#text} at (40,0) size 16x18
+              text run at (40,0) width 16: "30"
+          RenderText {#text} at (56,0) size 48x18
+            text run at (56,0) width 48: ",30,30: "
+          RenderMeter {METER} at (104,1) size 80x16
+          RenderText {#text} at (184,0) size 110x18
+            text run at (184,0) width 110: "(should be green)"
+        RenderListItem {LI} at (40,234) size 744x18
+          RenderListMarker at (-17,0) size 7x18: bullet
+          RenderText {#text} at (0,0) size 99x18
+            text run at (0,0) width 99: "10,20,30,30,30|"
+          RenderInline {B} at (0,0) size 16x18
+            RenderText {#text} at (99,0) size 16x18
+              text run at (99,0) width 16: "31"
+          RenderText {#text} at (115,0) size 8x18
+            text run at (115,0) width 8: ": "
+          RenderMeter {METER} at (123,1) size 80x16
+          RenderText {#text} at (203,0) size 110x18
+            text run at (203,0) width 110: "(should be green)"
+        RenderListItem {LI} at (40,252) size 744x18
+          RenderListMarker at (-17,0) size 7x18: bullet
+          RenderText {#text} at (0,0) size 40x18
+            text run at (0,0) width 40: "10,20,"
+          RenderInline {B} at (0,0) size 16x18
+            RenderText {#text} at (40,0) size 16x18
+              text run at (40,0) width 16: "20"
+          RenderText {#text} at (56,0) size 48x18
+            text run at (56,0) width 48: ",20,30: "
+          RenderMeter {METER} at (104,1) size 80x16
+          RenderText {#text} at (184,0) size 110x18
+            text run at (184,0) width 110: "(should be green)"
diff --git a/LayoutTests/platform/mac/fast/dom/HTMLMeterElement/meter-optimums-expected.checksum b/LayoutTests/platform/mac/fast/dom/HTMLMeterElement/meter-optimums-expected.checksum
index 6ffca5b..8dc5dae 100644
--- a/LayoutTests/platform/mac/fast/dom/HTMLMeterElement/meter-optimums-expected.checksum
+++ b/LayoutTests/platform/mac/fast/dom/HTMLMeterElement/meter-optimums-expected.checksum
@@ -1 +1 @@
-851e15761e9707f58957d7cc99012925
\ No newline at end of file
+d97d0ea3825f3e94e6f80b8cc6613810
\ No newline at end of file
diff --git a/LayoutTests/platform/mac/fast/dom/HTMLMeterElement/meter-optimums-expected.png b/LayoutTests/platform/mac/fast/dom/HTMLMeterElement/meter-optimums-expected.png
index ed3fbd0..725d1e4 100644
Binary files a/LayoutTests/platform/mac/fast/dom/HTMLMeterElement/meter-optimums-expected.png and b/LayoutTests/platform/mac/fast/dom/HTMLMeterElement/meter-optimums-expected.png differ
diff --git a/WebCore/ChangeLog b/WebCore/ChangeLog
index addeac8..0ba2be4 100644
--- a/WebCore/ChangeLog
+++ b/WebCore/ChangeLog
@@ -1,3 +1,19 @@
+2010-10-28  MORITA Hajime  <morrita at google.com>
+
+        Reviewed by Kent Tamura.
+
+        <meter min=0 max=100 value=100> should be optimum.
+        https://bugs.webkit.org/show_bug.cgi?id=48613
+
+        Changed to make the condition inclusive for better case consistently.
+        - Values on the border between optimum and subsequntial go optimum.
+        - Values on the border between suboptimal and even-less-than-good go suboptimal.
+
+        Test: fast/dom/HTMLMeterElement/meter-boundary-values.html
+
+        * html/HTMLMeterElement.cpp:
+        (WebCore::HTMLMeterElement::gaugeRegion):
+
 2010-10-29  Kenichi Ishibashi  <bashi at google.com>
 
         Reviewed by Kent Tamura.
diff --git a/WebCore/html/HTMLMeterElement.cpp b/WebCore/html/HTMLMeterElement.cpp
index 5419a22..3de69df 100644
--- a/WebCore/html/HTMLMeterElement.cpp
+++ b/WebCore/html/HTMLMeterElement.cpp
@@ -172,7 +172,7 @@ HTMLMeterElement::GaugeRegion HTMLMeterElement::gaugeRegion() const
     double theValue = value();
     double optimumValue = optimum();
 
-    if (optimumValue <= lowValue) {
+    if (optimumValue < lowValue) {
         // The optimum range stays under low
         if (theValue <= lowValue)
             return GaugeRegionOptimum;
@@ -181,7 +181,7 @@ HTMLMeterElement::GaugeRegion HTMLMeterElement::gaugeRegion() const
         return GaugeRegionEvenLessGood;
     }
     
-    if (highValue <= optimumValue) {
+    if (highValue < optimumValue) {
         // The optimum range stays over high
         if (highValue <= theValue)
             return GaugeRegionOptimum;
@@ -190,11 +190,11 @@ HTMLMeterElement::GaugeRegion HTMLMeterElement::gaugeRegion() const
         return GaugeRegionEvenLessGood;
     }
 
-    // The optimum range stays between high and low
-    if (lowValue < theValue && theValue < highValue)
+    // The optimum range stays between high and low.
+    // According to the standard, <meter> never show GaugeRegionEvenLessGood in this case
+    // because the value is never less or greater than min or max.
+    if (lowValue <= theValue && theValue <= highValue)
         return GaugeRegionOptimum;
-    if (theValue == min() || max() == theValue)
-        return GaugeRegionEvenLessGood;
     return GaugeRegionSuboptimal;
 }
 

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list