Bug 605124 (1/5) - Add :-moz-ui-invalid pseudo-class. r=bz a=bsmedberg
authorMounir Lamouri <mounir.lamouri@gmail.com>
Wed, 24 Nov 2010 00:48:18 +0100
changeset 58143 80c5a5c971b9889a55576d5eeb2d008d59f6c283
parent 58142 0dccfde3b86c1e7d1aae75b0f941675c3d82412e
child 58144 f88a334e605e9aab7eda0d14d69788d4ac3c5c15
push id17175
push usermlamouri@mozilla.com
push dateWed, 24 Nov 2010 10:15:50 +0000
treeherderautoland@7f5cd850578e [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersbz, bsmedberg
bugs605124
milestone2.0b8pre
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 605124 (1/5) - Add :-moz-ui-invalid pseudo-class. r=bz a=bsmedberg
content/events/public/nsEventStates.h
layout/style/nsCSSPseudoClassList.h
--- a/content/events/public/nsEventStates.h
+++ b/content/events/public/nsEventStates.h
@@ -254,15 +254,17 @@ private:
 // Handler for the content has crashed
 #define NS_EVENT_STATE_HANDLER_CRASHED NS_DEFINE_EVENT_STATE_MACRO(28)
 // Content has focus and should show a ring.
 #define NS_EVENT_STATE_FOCUSRING     NS_DEFINE_EVENT_STATE_MACRO(29)
 // Content shows its placeholder
 #define NS_EVENT_STATE_MOZ_PLACEHOLDER NS_DEFINE_EVENT_STATE_MACRO(30)
 // Content is a submit control and the form isn't valid.
 #define NS_EVENT_STATE_MOZ_SUBMITINVALID NS_DEFINE_EVENT_STATE_MACRO(31)
+// UI friendly version of :invalid pseudo-class.
+#define NS_EVENT_STATE_MOZ_UI_INVALID NS_DEFINE_EVENT_STATE_MACRO(32)
 
 /**
  * NOTE: do not go over 63 without updating nsEventStates::InternalType!
  */
 
 #endif // nsEventStates_h__
 
--- a/layout/style/nsCSSPseudoClassList.h
+++ b/layout/style/nsCSSPseudoClassList.h
@@ -177,13 +177,15 @@ CSS_STATE_PSEUDO_CLASS(defaultPseudo, ":
 CSS_STATE_PSEUDO_CLASS(mozReadOnly, ":-moz-read-only",
                        NS_EVENT_STATE_MOZ_READONLY)
 CSS_STATE_PSEUDO_CLASS(mozReadWrite, ":-moz-read-write",
                        NS_EVENT_STATE_MOZ_READWRITE)
 CSS_STATE_PSEUDO_CLASS(mozPlaceholder, ":-moz-placeholder",
                        NS_EVENT_STATE_MOZ_PLACEHOLDER)
 CSS_STATE_PSEUDO_CLASS(mozSubmitInvalid, ":-moz-submit-invalid",
                        NS_EVENT_STATE_MOZ_SUBMITINVALID)
+CSS_STATE_PSEUDO_CLASS(mozUIInvalid, ":-moz-ui-invalid",
+                       NS_EVENT_STATE_MOZ_UI_INVALID)
 
 #ifdef DEFINED_CSS_STATE_PSEUDO_CLASS
 #undef DEFINED_CSS_STATE_PSEUDO_CLASS
 #undef CSS_STATE_PSEUDO_CLASS
 #endif