Bug 973344, part 2 for beta only - Disable the input[type=number] forms.css rule (the pref is off) and the tests that break as a result. r=heycam, a=lsblakk
authorJonathan Watt <jwatt@jwatt.org>
Tue, 18 Feb 2014 16:37:01 +0000
changeset 176332 f66b06faac65ecb2756f32e7a6888df2e4c14f1d
parent 176331 e8f98bacb0b2420efa8c8855af309ce16d3f859d
child 176333 3b8f899c873f665d1dcc6c692085001845567670
child 176335 2985d92ccf723538408c9774e9f55bbb031507c0
child 176337 fb3a5c0013689dd681cfd477ffaf975baddc9834
push id445
push userffxbld
push dateMon, 10 Mar 2014 22:05:19 +0000
treeherdermozilla-release@dc38b741b04e [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersheycam, lsblakk
bugs973344
milestone28.0
Bug 973344, part 2 for beta only - Disable the input[type=number] forms.css rule (the pref is off) and the tests that break as a result. r=heycam, a=lsblakk
accessible/tests/mochitest/elm/test_HTMLSpec.html
accessible/tests/mochitest/tree/test_formctrl.html
content/html/content/reftests/autofocus/reftest.list
content/html/content/test/forms/mochitest.ini
layout/reftests/forms/input/reftest.list
layout/style/forms.css
--- a/accessible/tests/mochitest/elm/test_HTMLSpec.html
+++ b/accessible/tests/mochitest/elm/test_HTMLSpec.html
@@ -700,17 +700,18 @@
             actions: "press"
           },
           {
             role: ROLE_PUSHBUTTON,
             actions: "press"
           }
         ]
       };
-      testElm("input_number", obj);
+      // number is disabled in v28
+      //testElm("input_number", obj);
 
       //////////////////////////////////////////////////////////////////////////
       // HTML:input@type="text" and etc
 
       obj = {
         role: ROLE_ENTRY,
         extraStates: EXT_STATE_EDITABLE | EXT_STATE_SINGLE_LINE,
         actions: "activate",
--- a/accessible/tests/mochitest/tree/test_formctrl.html
+++ b/accessible/tests/mochitest/tree/test_formctrl.html
@@ -65,17 +65,18 @@
 
       // input@type="number"
       accTree =
         { SPINBUTTON: [
           { ENTRY: [ ] },
           { PUSHBUTTON: [ ] },
           { PUSHBUTTON: [ ] }
         ] };
-      testAccessibleTree("number", accTree);
+      // number is disabled in v28
+      //testAccessibleTree("number", accTree);
 
       // output
       accTree = {
         role: ROLE_SECTION,
         children: [
           {
             role: ROLE_TEXT_LEAF
           }
--- a/content/html/content/reftests/autofocus/reftest.list
+++ b/content/html/content/reftests/autofocus/reftest.list
@@ -1,12 +1,13 @@
 default-preferences pref(dom.forms.number,true)
 needs-focus == input-load.html input-ref.html
 needs-focus == input-create.html input-ref.html
-needs-focus == input-number.html input-number-ref.html
+# number is disabled in v28
+#needs-focus == input-number.html input-number-ref.html
 needs-focus == button-load.html button-ref.html
 needs-focus == button-create.html button-ref.html
 needs-focus == textarea-load.html textarea-ref.html
 needs-focus == textarea-create.html textarea-ref.html
 needs-focus == select-load.html select-ref.html
 needs-focus == select-create.html select-ref.html
 needs-focus == autofocus-after-load.html autofocus-after-load-ref.html
 needs-focus == autofocus-leaves-iframe.html autofocus-leaves-iframe-ref.html
--- a/content/html/content/test/forms/mochitest.ini
+++ b/content/html/content/test/forms/mochitest.ini
@@ -18,22 +18,23 @@ support-files =
 [test_input_color_input_change_events.html]
 [test_input_color_picker_initial.html]
 [test_input_color_picker_popup.html]
 [test_input_color_picker_update.html]
 [test_input_email.html]
 [test_input_event.html]
 [test_input_file_picker.html]
 [test_input_list_attribute.html]
-[test_input_number_key_events.html]
-[test_input_number_mouse_events.html]
+# number is disabled in v28
+#[test_input_number_key_events.html]
+#[test_input_number_mouse_events.html]
 # Not run on Firefox OS and Firefox for Android where the spin buttons are hidden:
-skip-if = os == "android" || appname == "b2g"
-[test_input_number_rounding.html]
-skip-if = os == "android"
+#skip-if = os == "android" || appname == "b2g"
+#[test_input_number_rounding.html]
+#skip-if = os == "android"
 [test_input_range_attr_order.html]
 [test_input_range_key_events.html]
 [test_input_range_mouse_and_touch_events.html]
 [test_input_range_rounding.html]
 [test_input_sanitization.html]
 [test_input_textarea_set_value_no_scroll.html]
 [test_input_typing_sanitization.html]
 [test_input_untrusted_key_events.html]
--- a/layout/reftests/forms/input/reftest.list
+++ b/layout/reftests/forms/input/reftest.list
@@ -1,13 +1,14 @@
 include checkbox/reftest.list
 include email/reftest.list
 include tel/reftest.list
 include search/reftest.list
 include url/reftest.list
-include number/reftest.list
+# number is disabled in v28
+#include number/reftest.list
 include file/reftest.list
 include radio/reftest.list
 include range/reftest.list
 include text/reftest.list
 include percentage/reftest.list
 include hidden/reftest.list
 include color/reftest.list
--- a/layout/style/forms.css
+++ b/layout/style/forms.css
@@ -880,22 +880,25 @@ input[type=range]::-moz-range-thumb {
   height: 1em;
   border: 0.1em solid grey;
   border-radius: 0.5em;
   background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg'><linearGradient id='g' x2='0' y2='100%'><stop stop-color='%23ddd'/><stop offset='100%' stop-color='white'/></linearGradient><rect fill='url(%23g)' width='100%' height='100%'/></svg>");
   /* Prevent nsFrame::HandlePress setting mouse capture to this element. */
   -moz-user-select: none ! important;
 }
 
+/* the pref doesn't work properly in v28 - we just disable this on non-mobile */
+%if defined(ANDROID) || defined(MOZ_WIDGET_GONK)
 input[type="number"] {
   -moz-appearance: number-input;
   /* Has to revert some properties applied by the generic input rule. */
   -moz-binding: none;
   width: 149px; /* to match type=text */
 }
+%endif
 
 input[type=number]::-moz-number-wrapper {
   /* Prevent styling that would change the type of frame we construct. */
   display: flex;
   float: none !important;
   position: static !important;
   height: 100%;
 }