Backed out changeset 6114d21c87ca (bug 1320809) for android reftest failures a=backout
authorWes Kocher <wkocher@mozilla.com>
Tue, 29 Nov 2016 14:04:53 -0800
changeset 324736 a544ec8cb49864b7c8ff2921e47c9b64160ac1e7
parent 324735 f6961e572571fa8b018fc972c34de3b0671b91f4
child 324737 a69583d2dbc6fdc18f63761a89cf539c356668be
child 324739 28e269b5ab120e15b7cf22f082befb1ed00cd5d5
push id24
push usermaklebus@msu.edu
push dateTue, 20 Dec 2016 03:11:33 +0000
reviewersbackout
bugs1320809
milestone53.0a1
backs out6114d21c87ca58bc1d40dab0a0ddc275775d3700
Backed out changeset 6114d21c87ca (bug 1320809) for android reftest failures a=backout
layout/forms/nsGfxCheckboxControlFrame.cpp
layout/forms/nsGfxCheckboxControlFrame.h
--- a/layout/forms/nsGfxCheckboxControlFrame.cpp
+++ b/layout/forms/nsGfxCheckboxControlFrame.cpp
@@ -42,8 +42,27 @@ nsGfxCheckboxControlFrame::~nsGfxCheckbo
 
 #ifdef ACCESSIBILITY
 a11y::AccType
 nsGfxCheckboxControlFrame::AccessibleType()
 {
   return a11y::eHTMLCheckboxType;
 }
 #endif
+
+//------------------------------------------------------------
+bool
+nsGfxCheckboxControlFrame::IsChecked()
+{
+  nsCOMPtr<nsIDOMHTMLInputElement> elem(do_QueryInterface(mContent));
+  bool retval = false;
+  elem->GetChecked(&retval);
+  return retval;
+}
+
+bool
+nsGfxCheckboxControlFrame::IsIndeterminate()
+{
+  nsCOMPtr<nsIDOMHTMLInputElement> elem(do_QueryInterface(mContent));
+  bool retval = false;
+  elem->GetIndeterminate(&retval);
+  return retval;
+}
--- a/layout/forms/nsGfxCheckboxControlFrame.h
+++ b/layout/forms/nsGfxCheckboxControlFrame.h
@@ -20,12 +20,17 @@ public:
   virtual nsresult GetFrameName(nsAString& aResult) const override {
     return MakeFrameName(NS_LITERAL_STRING("CheckboxControl"), aResult);
   }
 #endif
 
 #ifdef ACCESSIBILITY
   virtual mozilla::a11y::AccType AccessibleType() override;
 #endif
+
+protected:
+
+  bool IsChecked();
+  bool IsIndeterminate();
 };
 
 #endif