Bug 1273424 - Rename -moz-appearance keyword constants to be more consistent with CSS keywords. r=bholley
authorKeith Yeung <kungfukeith11@gmail.com>
Wed, 18 May 2016 10:29:56 -0700
changeset 298015 9c7f405a2cb66df61c264a972e019233d55eef1e
parent 298014 e995b22f325e0c017ac667080be2c6520b7c0032
child 298016 e5349d525d9d3e60e6992d619a6cf56a270051e8
push id19301
push userryanvm@gmail.com
push dateThu, 19 May 2016 16:50:51 +0000
treeherderfx-team@8e23df32697c [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersbholley
bugs1273424
milestone49.0a1
Bug 1273424 - Rename -moz-appearance keyword constants to be more consistent with CSS keywords. r=bholley
gfx/src/nsThemeConstants.h
layout/forms/nsMeterFrame.cpp
layout/forms/nsNumberControlFrame.cpp
layout/forms/nsProgressFrame.cpp
layout/style/nsCSSProps.cpp
widget/cocoa/nsNativeThemeCocoa.mm
widget/gtk/nsNativeThemeGTK.cpp
widget/nsNativeTheme.cpp
widget/windows/nsNativeThemeWin.cpp
--- a/gfx/src/nsThemeConstants.h
+++ b/gfx/src/nsThemeConstants.h
@@ -23,124 +23,124 @@
 
 // The toolbox that contains the toolbars.
 #define NS_THEME_TOOLBOX                                   11
 
 // A toolbar in an application window.
 #define NS_THEME_TOOLBAR                                   12
 
 // A single toolbar button (with no associated dropdown)
-#define NS_THEME_TOOLBAR_BUTTON                            13
+#define NS_THEME_TOOLBARBUTTON                             13
 
 // A dual toolbar button (e.g., a Back button with a dropdown)
-#define NS_THEME_TOOLBAR_DUAL_BUTTON                       14
+#define NS_THEME_DUALBUTTON                                14
 
 // The dropdown portion of a toolbar button
-#define NS_THEME_TOOLBAR_BUTTON_DROPDOWN                   15
+#define NS_THEME_TOOLBARBUTTON_DROPDOWN                    15
 
 // Various arrows that go in buttons
 #define NS_THEME_BUTTON_ARROW_UP                           16
 #define NS_THEME_BUTTON_ARROW_DOWN                         17
 #define NS_THEME_BUTTON_ARROW_NEXT                         18
 #define NS_THEME_BUTTON_ARROW_PREVIOUS                     19
 
 // A separator.  Can be horizontal or vertical.
-#define NS_THEME_TOOLBAR_SEPARATOR                         20
+#define NS_THEME_SEPARATOR                                 20
 
 // The gripper for a toolbar.
-#define NS_THEME_TOOLBAR_GRIPPER                           21
+#define NS_THEME_TOOLBARGRIPPER                            21
 
 // A splitter.  Can be horizontal or vertical.
 #define NS_THEME_SPLITTER                                  22
 
 // A status bar in a main application window.
 #define NS_THEME_STATUSBAR                                 23
 
 // A single pane of a status bar.
-#define NS_THEME_STATUSBAR_PANEL                           24
+#define NS_THEME_STATUSBARPANEL                            24
 
 // The resizer background area in a status bar 
 // for the resizer widget in the corner of a window.
-#define NS_THEME_STATUSBAR_RESIZER_PANEL                   25
+#define NS_THEME_RESIZER_PANEL                             25
 
 // The resizer itself.
 #define NS_THEME_RESIZER                                   26
 
 // List boxes
 #define NS_THEME_LISTBOX                                   31
 
 // A listbox item
-#define NS_THEME_LISTBOX_LISTITEM                          32
+#define NS_THEME_LISTITEM                                  32
 
 // A tree widget
 #define NS_THEME_TREEVIEW                                  41
 
 // A tree item
-#define NS_THEME_TREEVIEW_TREEITEM                         42
+#define NS_THEME_TREEITEM                                  42
 
 // A tree widget twisty
-#define NS_THEME_TREEVIEW_TWISTY                           43
+#define NS_THEME_TREETWISTY                                43
 
 // A tree widget branch line
-#define NS_THEME_TREEVIEW_LINE                             44
+#define NS_THEME_TREELINE                                  44
 
 // A listbox or tree widget header
-#define NS_THEME_TREEVIEW_HEADER                           45
+#define NS_THEME_TREEHEADER                                45
 
 // An individual header cell
-#define NS_THEME_TREEVIEW_HEADER_CELL                      46
+#define NS_THEME_TREEHEADERCELL                            46
 
 // The sort arrow for a header.
-#define NS_THEME_TREEVIEW_HEADER_SORTARROW                 47
+#define NS_THEME_TREEHEADERSORTARROW                       47
 
 // Open tree widget twisty
-#define NS_THEME_TREEVIEW_TWISTY_OPEN                      48
+#define NS_THEME_TREETWISTYOPEN                            48
 
 // A horizontal progress bar.
 #define NS_THEME_PROGRESSBAR                               51
 
 // The progress bar's progress indicator
-#define NS_THEME_PROGRESSBAR_CHUNK                         52
+#define NS_THEME_PROGRESSCHUNK                             52
 
 // A vertical progress bar.
 #define NS_THEME_PROGRESSBAR_VERTICAL                      53
 
 // A vertical progress chunk
-#define NS_THEME_PROGRESSBAR_CHUNK_VERTICAL                54
+#define NS_THEME_PROGRESSCHUNK_VERTICAL                    54
 
 // A horizontal meter bar.
 #define NS_THEME_METERBAR                                  55
 
 // The meter bar's meter indicator
-#define NS_THEME_METERBAR_CHUNK                            56
+#define NS_THEME_METERCHUNK                                56
 
 // A single tab in a tab widget.
 #define NS_THEME_TAB                                       61
 
 // A single pane (inside the tabpanels container)
-#define NS_THEME_TAB_PANEL                                 62
+#define NS_THEME_TABPANEL                                  62
 
 // The tab panels container.
-#define NS_THEME_TAB_PANELS                                65
+#define NS_THEME_TABPANELS                                 65
 
 // The tabs scroll arrows (left/right)
-#define NS_THEME_TAB_SCROLLARROW_BACK                      66
-#define NS_THEME_TAB_SCROLLARROW_FORWARD                   67
+#define NS_THEME_TAB_SCROLL_ARROW_BACK                     66
+#define NS_THEME_TAB_SCROLL_ARROW_FORWARD                  67
 
 // A tooltip
 #define NS_THEME_TOOLTIP                                   71
 
 // A spin control (up/down control for time/date pickers)
 #define NS_THEME_SPINNER                                   72
 
 // The up button of a spin control
-#define NS_THEME_SPINNER_UP_BUTTON                         73
+#define NS_THEME_SPINNER_UPBUTTON                          73
 
 // The down button of a spin control
-#define NS_THEME_SPINNER_DOWN_BUTTON                       74
+#define NS_THEME_SPINNER_DOWNBUTTON                        74
 
 // The textfield of a spin control
 #define NS_THEME_SPINNER_TEXTFIELD                         75
 
 // For HTML's <input type=number>
 #define NS_THEME_NUMBER_INPUT                              76
 
 // A scrollbar.
@@ -149,28 +149,28 @@
 // A small scrollbar.
 #define NS_THEME_SCROLLBAR_SMALL                           81
 
 // The scrollbar slider
 #define NS_THEME_SCROLLBAR_HORIZONTAL                      82
 #define NS_THEME_SCROLLBAR_VERTICAL                        83
 
 // A scrollbar button (up/down/left/right)
-#define NS_THEME_SCROLLBAR_BUTTON_UP                       84
-#define NS_THEME_SCROLLBAR_BUTTON_DOWN                     85
-#define NS_THEME_SCROLLBAR_BUTTON_LEFT                     86
-#define NS_THEME_SCROLLBAR_BUTTON_RIGHT                    87
+#define NS_THEME_SCROLLBARBUTTON_UP                        84
+#define NS_THEME_SCROLLBARBUTTON_DOWN                      85
+#define NS_THEME_SCROLLBARBUTTON_LEFT                      86
+#define NS_THEME_SCROLLBARBUTTON_RIGHT                     87
 
 // The scrollbar track
-#define NS_THEME_SCROLLBAR_TRACK_HORIZONTAL                88
-#define NS_THEME_SCROLLBAR_TRACK_VERTICAL                  89
+#define NS_THEME_SCROLLBARTRACK_HORIZONTAL                 88
+#define NS_THEME_SCROLLBARTRACK_VERTICAL                   89
 
 // The scrollbar thumb
-#define NS_THEME_SCROLLBAR_THUMB_HORIZONTAL                90
-#define NS_THEME_SCROLLBAR_THUMB_VERTICAL                  91
+#define NS_THEME_SCROLLBARTHUMB_HORIZONTAL                 90
+#define NS_THEME_SCROLLBARTHUMB_VERTICAL                   91
 
 // A non-disappearing scrollbar.
 #define NS_THEME_SCROLLBAR_NON_DISAPPEARING                92
 
 // A textfield or text area
 #define NS_THEME_TEXTFIELD                                 95
 
 // The caret of a text area
@@ -178,46 +178,46 @@
 
 // A multiline text field
 #define NS_THEME_TEXTFIELD_MULTILINE                       97
 
 // A searchfield
 #define NS_THEME_SEARCHFIELD                               98
 
 // A dropdown list.
-#define NS_THEME_DROPDOWN                                  101
+#define NS_THEME_MENULIST                                  101
 
 // The dropdown button(s) that open up a dropdown list.
-#define NS_THEME_DROPDOWN_BUTTON                           102
+#define NS_THEME_MENULIST_BUTTON                           102
 
 // The text part of a dropdown list, to left of button
-#define NS_THEME_DROPDOWN_TEXT                             103
+#define NS_THEME_MENULIST_TEXT                             103
 
 // An editable textfield with a dropdown list (a combobox)
-#define NS_THEME_DROPDOWN_TEXTFIELD                        104
+#define NS_THEME_MENULIST_TEXTFIELD                        104
 
 // A slider
-#define NS_THEME_SCALE_HORIZONTAL                         111
-#define NS_THEME_SCALE_VERTICAL                           112
+#define NS_THEME_SCALE_HORIZONTAL                          111
+#define NS_THEME_SCALE_VERTICAL                            112
 
 // A slider's thumb
-#define NS_THEME_SCALE_THUMB_HORIZONTAL                   113
-#define NS_THEME_SCALE_THUMB_VERTICAL                     114
+#define NS_THEME_SCALETHUMB_HORIZONTAL                     113
+#define NS_THEME_SCALETHUMB_VERTICAL                       114
 
 // If the platform supports it, the left/right chunks
 // of the slider thumb
-#define NS_THEME_SCALE_THUMB_START                        115
-#define NS_THEME_SCALE_THUMB_END                          116
+#define NS_THEME_SCALETHUMBSTART                           115
+#define NS_THEME_SCALETHUMBEND                             116
 
 // The ticks for a slider.
-#define NS_THEME_SCALE_TICK                               117
+#define NS_THEME_SCALETHUMBTICK                            117
 
 // nsRangeFrame and its subparts
-#define NS_THEME_RANGE                                    120
-#define NS_THEME_RANGE_THUMB                              121
+#define NS_THEME_RANGE                                     120
+#define NS_THEME_RANGE_THUMB                               121
 
 // A groupbox
 #define NS_THEME_GROUPBOX                                  149
 
 // A generic container that always repaints on state
 // changes.  This is a hack to make checkboxes and
 // radio buttons work.
 #define NS_THEME_CHECKBOX_CONTAINER                        150
@@ -252,23 +252,23 @@
 // An image in the menu gutter, like in bookmarks or history
 #define NS_THEME_MENUIMAGE                                 219
 // For text on non-iconic menuitems only
 #define NS_THEME_MENUITEMTEXT                              220
 
 // Vista Rebars
 #define NS_THEME_WIN_COMMUNICATIONS_TOOLBOX                221
 #define NS_THEME_WIN_MEDIA_TOOLBOX                         222
-#define NS_THEME_WIN_BROWSER_TAB_BAR_TOOLBOX               223
+#define NS_THEME_WIN_BROWSERTABBAR_TOOLBOX                 223
 
 // Titlebar elements on the Mac
-#define NS_THEME_MOZ_MAC_FULLSCREEN_BUTTON                 226
+#define NS_THEME_MAC_FULLSCREEN_BUTTON                     226
 
 // Mac help button
-#define NS_THEME_MOZ_MAC_HELP_BUTTON                       227
+#define NS_THEME_MAC_HELP_BUTTON                           227
 
 // Vista glass
 #define NS_THEME_WIN_BORDERLESS_GLASS                      229
 #define NS_THEME_WIN_GLASS                                 230
 
 // Windows themed window frame elements
 #define NS_THEME_WINDOW_TITLEBAR                           231
 #define NS_THEME_WINDOW_TITLEBAR_MAXIMIZED                 232
--- a/layout/forms/nsMeterFrame.cpp
+++ b/layout/forms/nsMeterFrame.cpp
@@ -276,17 +276,17 @@ nsMeterFrame::ShouldUseNativeStyle() con
   // Use the native style if these conditions are satisfied:
   // - both frames use the native appearance;
   // - neither frame has author specified rules setting the border or the
   //   background.
   return StyleDisplay()->mAppearance == NS_THEME_METERBAR &&
          !PresContext()->HasAuthorSpecifiedRules(this,
                                                  NS_AUTHOR_SPECIFIED_BORDER | NS_AUTHOR_SPECIFIED_BACKGROUND) &&
          barFrame &&
-         barFrame->StyleDisplay()->mAppearance == NS_THEME_METERBAR_CHUNK &&
+         barFrame->StyleDisplay()->mAppearance == NS_THEME_METERCHUNK &&
          !PresContext()->HasAuthorSpecifiedRules(barFrame,
                                                  NS_AUTHOR_SPECIFIED_BORDER | NS_AUTHOR_SPECIFIED_BACKGROUND);
 }
 
 Element*
 nsMeterFrame::GetPseudoElement(CSSPseudoElementType aType)
 {
   if (aType == CSSPseudoElementType::mozMeterBar) {
--- a/layout/forms/nsNumberControlFrame.cpp
+++ b/layout/forms/nsNumberControlFrame.cpp
@@ -700,21 +700,21 @@ nsNumberControlFrame::ShouldUseNativeSty
 {
   MOZ_ASSERT(mSpinUp && mSpinDown,
              "We should not be called when we have no spinner");
 
   nsIFrame* spinUpFrame = mSpinUp->GetPrimaryFrame();
   nsIFrame* spinDownFrame = mSpinDown->GetPrimaryFrame();
 
   return spinUpFrame &&
-    spinUpFrame->StyleDisplay()->mAppearance == NS_THEME_SPINNER_UP_BUTTON &&
+    spinUpFrame->StyleDisplay()->mAppearance == NS_THEME_SPINNER_UPBUTTON &&
     !PresContext()->HasAuthorSpecifiedRules(spinUpFrame,
                                             STYLES_DISABLING_NATIVE_THEMING) &&
     spinDownFrame &&
-    spinDownFrame->StyleDisplay()->mAppearance == NS_THEME_SPINNER_DOWN_BUTTON &&
+    spinDownFrame->StyleDisplay()->mAppearance == NS_THEME_SPINNER_DOWNBUTTON &&
     !PresContext()->HasAuthorSpecifiedRules(spinDownFrame,
                                             STYLES_DISABLING_NATIVE_THEMING);
 }
 
 void
 nsNumberControlFrame::AppendAnonymousContentTo(nsTArray<nsIContent*>& aElements,
                                                uint32_t aFilter)
 {
--- a/layout/forms/nsProgressFrame.cpp
+++ b/layout/forms/nsProgressFrame.cpp
@@ -284,17 +284,17 @@ nsProgressFrame::ShouldUseNativeStyle() 
   // Use the native style if these conditions are satisfied:
   // - both frames use the native appearance;
   // - neither frame has author specified rules setting the border or the
   //   background.
   return StyleDisplay()->mAppearance == NS_THEME_PROGRESSBAR &&
          !PresContext()->HasAuthorSpecifiedRules(this,
                                                  NS_AUTHOR_SPECIFIED_BORDER | NS_AUTHOR_SPECIFIED_BACKGROUND) &&
          barFrame &&
-         barFrame->StyleDisplay()->mAppearance == NS_THEME_PROGRESSBAR_CHUNK &&
+         barFrame->StyleDisplay()->mAppearance == NS_THEME_PROGRESSCHUNK &&
          !PresContext()->HasAuthorSpecifiedRules(barFrame,
                                                  NS_AUTHOR_SPECIFIED_BORDER | NS_AUTHOR_SPECIFIED_BACKGROUND);
 }
 
 Element*
 nsProgressFrame::GetPseudoElement(CSSPseudoElementType aType)
 {
   if (aType == CSSPseudoElementType::mozProgressBar) {
--- a/layout/style/nsCSSProps.cpp
+++ b/layout/style/nsCSSProps.cpp
@@ -749,86 +749,86 @@ const KTableEntry nsCSSProps::kAnimation
 const KTableEntry nsCSSProps::kAppearanceKTable[] = {
   { eCSSKeyword_none,                   NS_THEME_NONE },
   { eCSSKeyword_button,                 NS_THEME_BUTTON },
   { eCSSKeyword_radio,                  NS_THEME_RADIO },
   { eCSSKeyword_checkbox,               NS_THEME_CHECKBOX },
   { eCSSKeyword_button_bevel,           NS_THEME_BUTTON_BEVEL },
   { eCSSKeyword_toolbox,                NS_THEME_TOOLBOX },
   { eCSSKeyword_toolbar,                NS_THEME_TOOLBAR },
-  { eCSSKeyword_toolbarbutton,          NS_THEME_TOOLBAR_BUTTON },
-  { eCSSKeyword_toolbargripper,         NS_THEME_TOOLBAR_GRIPPER },
-  { eCSSKeyword_dualbutton,             NS_THEME_TOOLBAR_DUAL_BUTTON },
-  { eCSSKeyword_toolbarbutton_dropdown, NS_THEME_TOOLBAR_BUTTON_DROPDOWN },
+  { eCSSKeyword_toolbarbutton,          NS_THEME_TOOLBARBUTTON },
+  { eCSSKeyword_toolbargripper,         NS_THEME_TOOLBARGRIPPER },
+  { eCSSKeyword_dualbutton,             NS_THEME_DUALBUTTON },
+  { eCSSKeyword_toolbarbutton_dropdown, NS_THEME_TOOLBARBUTTON_DROPDOWN },
   { eCSSKeyword_button_arrow_up,        NS_THEME_BUTTON_ARROW_UP },
   { eCSSKeyword_button_arrow_down,      NS_THEME_BUTTON_ARROW_DOWN },
   { eCSSKeyword_button_arrow_next,      NS_THEME_BUTTON_ARROW_NEXT },
   { eCSSKeyword_button_arrow_previous,  NS_THEME_BUTTON_ARROW_PREVIOUS },
   { eCSSKeyword_meterbar,               NS_THEME_METERBAR },
-  { eCSSKeyword_meterchunk,             NS_THEME_METERBAR_CHUNK },
+  { eCSSKeyword_meterchunk,             NS_THEME_METERCHUNK },
   { eCSSKeyword_number_input,           NS_THEME_NUMBER_INPUT },
-  { eCSSKeyword_separator,              NS_THEME_TOOLBAR_SEPARATOR },
+  { eCSSKeyword_separator,              NS_THEME_SEPARATOR },
   { eCSSKeyword_splitter,               NS_THEME_SPLITTER },
   { eCSSKeyword_statusbar,              NS_THEME_STATUSBAR },
-  { eCSSKeyword_statusbarpanel,         NS_THEME_STATUSBAR_PANEL },
-  { eCSSKeyword_resizerpanel,           NS_THEME_STATUSBAR_RESIZER_PANEL },
+  { eCSSKeyword_statusbarpanel,         NS_THEME_STATUSBARPANEL },
+  { eCSSKeyword_resizerpanel,           NS_THEME_RESIZER_PANEL },
   { eCSSKeyword_resizer,                NS_THEME_RESIZER },
   { eCSSKeyword_listbox,                NS_THEME_LISTBOX },
-  { eCSSKeyword_listitem,               NS_THEME_LISTBOX_LISTITEM },
+  { eCSSKeyword_listitem,               NS_THEME_LISTITEM },
   { eCSSKeyword_treeview,               NS_THEME_TREEVIEW },
-  { eCSSKeyword_treeitem,               NS_THEME_TREEVIEW_TREEITEM },
-  { eCSSKeyword_treetwisty,             NS_THEME_TREEVIEW_TWISTY },
-  { eCSSKeyword_treetwistyopen,         NS_THEME_TREEVIEW_TWISTY_OPEN },
-  { eCSSKeyword_treeline,               NS_THEME_TREEVIEW_LINE },
-  { eCSSKeyword_treeheader,             NS_THEME_TREEVIEW_HEADER },
-  { eCSSKeyword_treeheadercell,         NS_THEME_TREEVIEW_HEADER_CELL },
-  { eCSSKeyword_treeheadersortarrow,    NS_THEME_TREEVIEW_HEADER_SORTARROW },
+  { eCSSKeyword_treeitem,               NS_THEME_TREEITEM },
+  { eCSSKeyword_treetwisty,             NS_THEME_TREETWISTY },
+  { eCSSKeyword_treetwistyopen,         NS_THEME_TREETWISTYOPEN },
+  { eCSSKeyword_treeline,               NS_THEME_TREELINE },
+  { eCSSKeyword_treeheader,             NS_THEME_TREEHEADER },
+  { eCSSKeyword_treeheadercell,         NS_THEME_TREEHEADERCELL },
+  { eCSSKeyword_treeheadersortarrow,    NS_THEME_TREEHEADERSORTARROW },
   { eCSSKeyword_progressbar,            NS_THEME_PROGRESSBAR },
-  { eCSSKeyword_progresschunk,          NS_THEME_PROGRESSBAR_CHUNK },
+  { eCSSKeyword_progresschunk,          NS_THEME_PROGRESSCHUNK },
   { eCSSKeyword_progressbar_vertical,   NS_THEME_PROGRESSBAR_VERTICAL },
-  { eCSSKeyword_progresschunk_vertical, NS_THEME_PROGRESSBAR_CHUNK_VERTICAL },
+  { eCSSKeyword_progresschunk_vertical, NS_THEME_PROGRESSCHUNK_VERTICAL },
   { eCSSKeyword_tab,                    NS_THEME_TAB },
-  { eCSSKeyword_tabpanels,              NS_THEME_TAB_PANELS },
-  { eCSSKeyword_tabpanel,               NS_THEME_TAB_PANEL },
-  { eCSSKeyword_tab_scroll_arrow_back,  NS_THEME_TAB_SCROLLARROW_BACK },
-  { eCSSKeyword_tab_scroll_arrow_forward, NS_THEME_TAB_SCROLLARROW_FORWARD },
+  { eCSSKeyword_tabpanels,              NS_THEME_TABPANELS },
+  { eCSSKeyword_tabpanel,               NS_THEME_TABPANEL },
+  { eCSSKeyword_tab_scroll_arrow_back,  NS_THEME_TAB_SCROLL_ARROW_BACK },
+  { eCSSKeyword_tab_scroll_arrow_forward, NS_THEME_TAB_SCROLL_ARROW_FORWARD },
   { eCSSKeyword_tooltip,                NS_THEME_TOOLTIP },
   { eCSSKeyword_spinner,                NS_THEME_SPINNER },
-  { eCSSKeyword_spinner_upbutton,       NS_THEME_SPINNER_UP_BUTTON },
-  { eCSSKeyword_spinner_downbutton,     NS_THEME_SPINNER_DOWN_BUTTON },
+  { eCSSKeyword_spinner_upbutton,       NS_THEME_SPINNER_UPBUTTON },
+  { eCSSKeyword_spinner_downbutton,     NS_THEME_SPINNER_DOWNBUTTON },
   { eCSSKeyword_spinner_textfield,      NS_THEME_SPINNER_TEXTFIELD },
   { eCSSKeyword_scrollbar,              NS_THEME_SCROLLBAR },
   { eCSSKeyword_scrollbar_small,        NS_THEME_SCROLLBAR_SMALL },
   { eCSSKeyword_scrollbar_horizontal,   NS_THEME_SCROLLBAR_HORIZONTAL },
   { eCSSKeyword_scrollbar_vertical,     NS_THEME_SCROLLBAR_VERTICAL },
-  { eCSSKeyword_scrollbarbutton_up,     NS_THEME_SCROLLBAR_BUTTON_UP },
-  { eCSSKeyword_scrollbarbutton_down,   NS_THEME_SCROLLBAR_BUTTON_DOWN },
-  { eCSSKeyword_scrollbarbutton_left,   NS_THEME_SCROLLBAR_BUTTON_LEFT },
-  { eCSSKeyword_scrollbarbutton_right,  NS_THEME_SCROLLBAR_BUTTON_RIGHT },
-  { eCSSKeyword_scrollbartrack_horizontal,    NS_THEME_SCROLLBAR_TRACK_HORIZONTAL },
-  { eCSSKeyword_scrollbartrack_vertical,      NS_THEME_SCROLLBAR_TRACK_VERTICAL },
-  { eCSSKeyword_scrollbarthumb_horizontal,    NS_THEME_SCROLLBAR_THUMB_HORIZONTAL },
-  { eCSSKeyword_scrollbarthumb_vertical,      NS_THEME_SCROLLBAR_THUMB_VERTICAL },
+  { eCSSKeyword_scrollbarbutton_up,     NS_THEME_SCROLLBARBUTTON_UP },
+  { eCSSKeyword_scrollbarbutton_down,   NS_THEME_SCROLLBARBUTTON_DOWN },
+  { eCSSKeyword_scrollbarbutton_left,   NS_THEME_SCROLLBARBUTTON_LEFT },
+  { eCSSKeyword_scrollbarbutton_right,  NS_THEME_SCROLLBARBUTTON_RIGHT },
+  { eCSSKeyword_scrollbartrack_horizontal,    NS_THEME_SCROLLBARTRACK_HORIZONTAL },
+  { eCSSKeyword_scrollbartrack_vertical,      NS_THEME_SCROLLBARTRACK_VERTICAL },
+  { eCSSKeyword_scrollbarthumb_horizontal,    NS_THEME_SCROLLBARTHUMB_HORIZONTAL },
+  { eCSSKeyword_scrollbarthumb_vertical,      NS_THEME_SCROLLBARTHUMB_VERTICAL },
   { eCSSKeyword_textfield,              NS_THEME_TEXTFIELD },
   { eCSSKeyword_textfield_multiline,    NS_THEME_TEXTFIELD_MULTILINE },
   { eCSSKeyword_caret,                  NS_THEME_TEXTFIELD_CARET },
   { eCSSKeyword_searchfield,            NS_THEME_SEARCHFIELD },
-  { eCSSKeyword_menulist,               NS_THEME_DROPDOWN },
-  { eCSSKeyword_menulist_button,        NS_THEME_DROPDOWN_BUTTON },
-  { eCSSKeyword_menulist_text,          NS_THEME_DROPDOWN_TEXT },
-  { eCSSKeyword_menulist_textfield,     NS_THEME_DROPDOWN_TEXTFIELD },
+  { eCSSKeyword_menulist,               NS_THEME_MENULIST },
+  { eCSSKeyword_menulist_button,        NS_THEME_MENULIST_BUTTON },
+  { eCSSKeyword_menulist_text,          NS_THEME_MENULIST_TEXT },
+  { eCSSKeyword_menulist_textfield,     NS_THEME_MENULIST_TEXTFIELD },
   { eCSSKeyword_range,                  NS_THEME_RANGE },
   { eCSSKeyword_range_thumb,            NS_THEME_RANGE_THUMB },
   { eCSSKeyword_scale_horizontal,       NS_THEME_SCALE_HORIZONTAL },
   { eCSSKeyword_scale_vertical,         NS_THEME_SCALE_VERTICAL },
-  { eCSSKeyword_scalethumb_horizontal,  NS_THEME_SCALE_THUMB_HORIZONTAL },
-  { eCSSKeyword_scalethumb_vertical,    NS_THEME_SCALE_THUMB_VERTICAL },
-  { eCSSKeyword_scalethumbstart,        NS_THEME_SCALE_THUMB_START },
-  { eCSSKeyword_scalethumbend,          NS_THEME_SCALE_THUMB_END },
-  { eCSSKeyword_scalethumbtick,         NS_THEME_SCALE_TICK },
+  { eCSSKeyword_scalethumb_horizontal,  NS_THEME_SCALETHUMB_HORIZONTAL },
+  { eCSSKeyword_scalethumb_vertical,    NS_THEME_SCALETHUMB_VERTICAL },
+  { eCSSKeyword_scalethumbstart,        NS_THEME_SCALETHUMBSTART },
+  { eCSSKeyword_scalethumbend,          NS_THEME_SCALETHUMBEND },
+  { eCSSKeyword_scalethumbtick,         NS_THEME_SCALETHUMBTICK },
   { eCSSKeyword_groupbox,               NS_THEME_GROUPBOX },
   { eCSSKeyword_checkbox_container,     NS_THEME_CHECKBOX_CONTAINER },
   { eCSSKeyword_radio_container,        NS_THEME_RADIO_CONTAINER },
   { eCSSKeyword_checkbox_label,         NS_THEME_CHECKBOX_LABEL },
   { eCSSKeyword_radio_label,            NS_THEME_RADIO_LABEL },
   { eCSSKeyword_button_focus,           NS_THEME_BUTTON_FOCUS },
   { eCSSKeyword_window,                 NS_THEME_WINDOW },
   { eCSSKeyword_dialog,                 NS_THEME_DIALOG },
@@ -840,21 +840,21 @@ const KTableEntry nsCSSProps::kAppearanc
   { eCSSKeyword_menucheckbox,           NS_THEME_MENUCHECKBOX },
   { eCSSKeyword_menuradio,              NS_THEME_MENURADIO },
   { eCSSKeyword_menuseparator,          NS_THEME_MENUSEPARATOR },
   { eCSSKeyword_menuarrow,              NS_THEME_MENUARROW },
   { eCSSKeyword_menuimage,              NS_THEME_MENUIMAGE },
   { eCSSKeyword_menuitemtext,           NS_THEME_MENUITEMTEXT },
   { eCSSKeyword__moz_win_media_toolbox, NS_THEME_WIN_MEDIA_TOOLBOX },
   { eCSSKeyword__moz_win_communications_toolbox, NS_THEME_WIN_COMMUNICATIONS_TOOLBOX },
-  { eCSSKeyword__moz_win_browsertabbar_toolbox,  NS_THEME_WIN_BROWSER_TAB_BAR_TOOLBOX },
+  { eCSSKeyword__moz_win_browsertabbar_toolbox,  NS_THEME_WIN_BROWSERTABBAR_TOOLBOX },
   { eCSSKeyword__moz_win_glass,         NS_THEME_WIN_GLASS },
   { eCSSKeyword__moz_win_borderless_glass,      NS_THEME_WIN_BORDERLESS_GLASS },
-  { eCSSKeyword__moz_mac_fullscreen_button,     NS_THEME_MOZ_MAC_FULLSCREEN_BUTTON },
-  { eCSSKeyword__moz_mac_help_button,           NS_THEME_MOZ_MAC_HELP_BUTTON },
+  { eCSSKeyword__moz_mac_fullscreen_button,     NS_THEME_MAC_FULLSCREEN_BUTTON },
+  { eCSSKeyword__moz_mac_help_button,           NS_THEME_MAC_HELP_BUTTON },
   { eCSSKeyword__moz_window_titlebar,           NS_THEME_WINDOW_TITLEBAR },
   { eCSSKeyword__moz_window_titlebar_maximized, NS_THEME_WINDOW_TITLEBAR_MAXIMIZED },
   { eCSSKeyword__moz_window_frame_left,         NS_THEME_WINDOW_FRAME_LEFT },
   { eCSSKeyword__moz_window_frame_right,        NS_THEME_WINDOW_FRAME_RIGHT },
   { eCSSKeyword__moz_window_frame_bottom,       NS_THEME_WINDOW_FRAME_BOTTOM },
   { eCSSKeyword__moz_window_button_close,       NS_THEME_WINDOW_BUTTON_CLOSE },
   { eCSSKeyword__moz_window_button_minimize,    NS_THEME_WINDOW_BUTTON_MINIMIZE },
   { eCSSKeyword__moz_window_button_maximize,    NS_THEME_WINDOW_BUTTON_MAXIMIZE },
--- a/widget/cocoa/nsNativeThemeCocoa.mm
+++ b/widget/cocoa/nsNativeThemeCocoa.mm
@@ -1221,25 +1221,25 @@ nsNativeThemeCocoa::DrawPushButton(CGCon
                                    nsIFrame* aFrame)
 {
   NS_OBJC_BEGIN_TRY_ABORT_BLOCK;
 
   BOOL isActive = FrameIsInActiveWindow(aFrame);
   BOOL isDisabled = IsDisabled(aFrame, inState);
 
   NSButtonCell* cell = (aWidgetType == NS_THEME_BUTTON) ? mPushButtonCell :
-    (aWidgetType == NS_THEME_MOZ_MAC_HELP_BUTTON) ? mHelpButtonCell : mDisclosureButtonCell;
+    (aWidgetType == NS_THEME_MAC_HELP_BUTTON) ? mHelpButtonCell : mDisclosureButtonCell;
   [cell setEnabled:!isDisabled];
   [cell setHighlighted:isActive &&
                        inState.HasAllStates(NS_EVENT_STATE_ACTIVE | NS_EVENT_STATE_HOVER)];
   [cell setShowsFirstResponder:inState.HasState(NS_EVENT_STATE_FOCUS) && !isDisabled && isActive];
 
   if (aWidgetType != NS_THEME_BUTTON) { // Help button or disclosure button.
     NSSize buttonSize = NSMakeSize(0, 0);
-    if (aWidgetType == NS_THEME_MOZ_MAC_HELP_BUTTON) {
+    if (aWidgetType == NS_THEME_MAC_HELP_BUTTON) {
       buttonSize = kHelpButtonSize;
     } else { // Disclosure button.
       buttonSize = kDisclosureButtonSize;
       [cell setState:(aWidgetType == NS_THEME_MAC_DISCLOSURE_BUTTON_CLOSED) ? NSOffState : NSOnState];
     }
 
     DrawCellWithScaling(cell, cgContext, inBoxRect, NSRegularControlSize,
                         NSZeroSize, buttonSize, NULL, mCellDrawView,
@@ -1512,17 +1512,17 @@ void
 nsNativeThemeCocoa::DrawDropdown(CGContextRef cgContext, const HIRect& inBoxRect,
                                  EventStates inState, uint8_t aWidgetType,
                                  nsIFrame* aFrame)
 {
   NS_OBJC_BEGIN_TRY_ABORT_BLOCK;
 
   [mDropdownCell setPullsDown:(aWidgetType == NS_THEME_BUTTON)];
 
-  BOOL isEditable = (aWidgetType == NS_THEME_DROPDOWN_TEXTFIELD);
+  BOOL isEditable = (aWidgetType == NS_THEME_MENULIST_TEXTFIELD);
   NSCell* cell = isEditable ? (NSCell*)mComboBoxCell : (NSCell*)mDropdownCell;
 
   [cell setEnabled:!IsDisabled(aFrame, inState)];
   [cell setShowsFirstResponder:(IsFocused(aFrame) || inState.HasState(NS_EVENT_STATE_FOCUS))];
   [cell setHighlighted:IsOpenButton(aFrame)];
   [cell setControlTint:(FrameIsInActiveWindow(aFrame) ? [NSColor currentControlTint] : NSClearControlTint)];
 
   const CellRenderSettings& settings = isEditable ? editableMenulistSettings : dropdownSettings;
@@ -1588,18 +1588,18 @@ nsNativeThemeCocoa::DrawSpinButton(CGCon
                                    ThemeDrawState inDrawState,
                                    ThemeButtonAdornment inAdornment,
                                    EventStates inState,
                                    nsIFrame* aFrame,
                                    uint8_t aWidgetType)
 {
   NS_OBJC_BEGIN_TRY_ABORT_BLOCK;
 
-  MOZ_ASSERT(aWidgetType == NS_THEME_SPINNER_UP_BUTTON ||
-             aWidgetType == NS_THEME_SPINNER_DOWN_BUTTON);
+  MOZ_ASSERT(aWidgetType == NS_THEME_SPINNER_UPBUTTON ||
+             aWidgetType == NS_THEME_SPINNER_DOWNBUTTON);
 
   HIThemeButtonDrawInfo bdi;
   bdi.version = 0;
   bdi.kind = inKind;
   bdi.value = kThemeButtonOff;
   bdi.adornment = inAdornment;
 
   if (IsDisabled(aFrame, inState))
@@ -1608,17 +1608,17 @@ nsNativeThemeCocoa::DrawSpinButton(CGCon
     bdi.state = FrameIsInActiveWindow(aFrame) ? inDrawState : kThemeStateActive;
 
   // Cocoa only allows kThemeIncDecButton to paint the up and down spin buttons
   // together as a single unit (presumably because when one button is active,
   // the appearance of both changes (in different ways)). Here we have to paint
   // both buttons, using clip to hide the one we don't want to paint.
   HIRect drawRect = inBoxRect;
   drawRect.size.height *= 2;
-  if (aWidgetType == NS_THEME_SPINNER_DOWN_BUTTON) {
+  if (aWidgetType == NS_THEME_SPINNER_DOWNBUTTON) {
     drawRect.origin.y -= inBoxRect.size.height;
   }
 
   // Shift the drawing a little to the left, since cocoa paints with more
   // blank space around the visual buttons than we'd like:
   drawRect.origin.x -= 1;
 
   CGContextSaveGState(cgContext);
@@ -2614,17 +2614,17 @@ nsNativeThemeCocoa::DrawWidgetBackground
         DrawPushButton(cgContext, macRect, eventState, aWidgetType, aFrame);
       }
       break;
 
     case NS_THEME_FOCUS_OUTLINE:
       DrawFocusOutline(cgContext, macRect, eventState, aWidgetType, aFrame);
       break;
 
-    case NS_THEME_MOZ_MAC_HELP_BUTTON:
+    case NS_THEME_MAC_HELP_BUTTON:
     case NS_THEME_MAC_DISCLOSURE_BUTTON_OPEN:
     case NS_THEME_MAC_DISCLOSURE_BUTTON_CLOSED:
       DrawPushButton(cgContext, macRect, eventState, aWidgetType, aFrame);
       break;
 
     case NS_THEME_BUTTON_BEVEL:
       DrawButton(cgContext, kThemeMediumBevelButton, macRect,
                  IsDefaultButton(aFrame), kThemeButtonOff, kThemeAdornmentNone,
@@ -2649,38 +2649,38 @@ nsNativeThemeCocoa::DrawWidgetBackground
         state = kThemeStatePressedDown;
       }
 
       DrawSpinButtons(cgContext, kThemeIncDecButton, macRect, state,
                       kThemeAdornmentNone, eventState, aFrame);
     }
       break;
 
-    case NS_THEME_SPINNER_UP_BUTTON:
-    case NS_THEME_SPINNER_DOWN_BUTTON: {
+    case NS_THEME_SPINNER_UPBUTTON:
+    case NS_THEME_SPINNER_DOWNBUTTON: {
       nsNumberControlFrame* numberControlFrame =
         nsNumberControlFrame::GetNumberControlFrameForSpinButton(aFrame);
       if (numberControlFrame) {
         ThemeDrawState state = kThemeStateActive;
         if (numberControlFrame->SpinnerUpButtonIsDepressed()) {
           state = kThemeStatePressedUp;
         } else if (numberControlFrame->SpinnerDownButtonIsDepressed()) {
           state = kThemeStatePressedDown;
         }
         DrawSpinButton(cgContext, kThemeIncDecButtonMini, macRect, state,
                        kThemeAdornmentNone, eventState, aFrame, aWidgetType);
       }
     }
       break;
 
-    case NS_THEME_TOOLBAR_BUTTON:
+    case NS_THEME_TOOLBARBUTTON:
       DrawSegment(cgContext, macRect, eventState, aFrame, toolbarButtonRenderSettings);
       break;
 
-    case NS_THEME_TOOLBAR_SEPARATOR: {
+    case NS_THEME_SEPARATOR: {
       HIThemeSeparatorDrawInfo sdi = { 0, kThemeStateActive };
       HIThemeDrawSeparator(&macRect, &sdi, cgContext, HITHEME_ORIENTATION);
     }
       break;
 
     case NS_THEME_TOOLBAR: {
       NSWindow* win = NativeWindowForFrame(aFrame);
       if (ToolbarCanBeUnified(cgContext, macRect, win)) {
@@ -2714,22 +2714,22 @@ nsNativeThemeCocoa::DrawWidgetBackground
       DrawNativeTitlebar(cgContext, macRect, unifiedToolbarHeight, isMain, YES);
     }
       break;
 
     case NS_THEME_STATUSBAR: 
       DrawStatusBar(cgContext, macRect, aFrame);
       break;
 
-    case NS_THEME_DROPDOWN:
-    case NS_THEME_DROPDOWN_TEXTFIELD:
+    case NS_THEME_MENULIST:
+    case NS_THEME_MENULIST_TEXTFIELD:
       DrawDropdown(cgContext, macRect, eventState, aWidgetType, aFrame);
       break;
 
-    case NS_THEME_DROPDOWN_BUTTON:
+    case NS_THEME_MENULIST_BUTTON:
       DrawButton(cgContext, kThemeArrowButton, macRect, false, kThemeButtonOn,
                  kThemeAdornmentArrowDownArrow, eventState, aFrame);
       break;
 
     case NS_THEME_GROUPBOX: {
       HIThemeGroupBoxDrawInfo gdi = { 0, kThemeStateActive, kHIThemeGroupBoxKindPrimary };
       HIThemeDrawGroupBox(&macRect, &gdi, cgContext, HITHEME_ORIENTATION);
       break;
@@ -2779,54 +2779,54 @@ nsNativeThemeCocoa::DrawWidgetBackground
                    false, GetProgressValue(aFrame),
                    GetProgressMaxValue(aFrame), aFrame);
       break;
 
     case NS_THEME_METERBAR:
       DrawMeter(cgContext, macRect, aFrame);
       break;
 
-    case NS_THEME_PROGRESSBAR_CHUNK:
-    case NS_THEME_PROGRESSBAR_CHUNK_VERTICAL:
-    case NS_THEME_METERBAR_CHUNK:
+    case NS_THEME_PROGRESSCHUNK:
+    case NS_THEME_PROGRESSCHUNK_VERTICAL:
+    case NS_THEME_METERCHUNK:
       // Do nothing: progress and meter bars cases will draw chunks.
       break;
 
-    case NS_THEME_TREEVIEW_TWISTY:
+    case NS_THEME_TREETWISTY:
       DrawButton(cgContext, kThemeDisclosureButton, macRect, false,
                  kThemeDisclosureRight, kThemeAdornmentNone, eventState, aFrame);
       break;
 
-    case NS_THEME_TREEVIEW_TWISTY_OPEN:
+    case NS_THEME_TREETWISTYOPEN:
       DrawButton(cgContext, kThemeDisclosureButton, macRect, false,
                  kThemeDisclosureDown, kThemeAdornmentNone, eventState, aFrame);
       break;
 
-    case NS_THEME_TREEVIEW_HEADER_CELL: {
+    case NS_THEME_TREEHEADERCELL: {
       TreeSortDirection sortDirection = GetTreeSortDirection(aFrame);
       DrawButton(cgContext, kThemeListHeaderButton, macRect, false,
                  sortDirection == eTreeSortDirection_Natural ? kThemeButtonOff : kThemeButtonOn,
                  sortDirection == eTreeSortDirection_Ascending ?
                  kThemeAdornmentHeaderButtonSortUp : kThemeAdornmentNone, eventState, aFrame);
     }
       break;
 
-    case NS_THEME_TREEVIEW_TREEITEM:
+    case NS_THEME_TREEITEM:
     case NS_THEME_TREEVIEW:
       // HIThemeSetFill is not available on 10.3
       // HIThemeSetFill(kThemeBrushWhite, NULL, cgContext, HITHEME_ORIENTATION);
       CGContextSetRGBFillColor(cgContext, 1.0, 1.0, 1.0, 1.0);
       CGContextFillRect(cgContext, macRect);
       break;
 
-    case NS_THEME_TREEVIEW_HEADER:
+    case NS_THEME_TREEHEADER:
       // do nothing, taken care of by individual header cells
-    case NS_THEME_TREEVIEW_HEADER_SORTARROW:
+    case NS_THEME_TREEHEADERSORTARROW:
       // do nothing, taken care of by treeview header
-    case NS_THEME_TREEVIEW_LINE:
+    case NS_THEME_TREELINE:
       // do nothing, these lines don't exist on macos
       break;
 
     case NS_THEME_SCALE_HORIZONTAL:
     case NS_THEME_SCALE_VERTICAL: {
       int32_t curpos = CheckIntAttr(aFrame, nsGkAtoms::curpos, 0);
       int32_t minpos = CheckIntAttr(aFrame, nsGkAtoms::minpos, 0);
       int32_t maxpos = CheckIntAttr(aFrame, nsGkAtoms::maxpos, 100);
@@ -2837,18 +2837,18 @@ nsNativeThemeCocoa::DrawWidgetBackground
         AttrValueIs(kNameSpaceID_None, nsGkAtoms::dir,
                     NS_LITERAL_STRING("reverse"), eCaseMatters);
       DrawScale(cgContext, macRect, eventState,
                 (aWidgetType == NS_THEME_SCALE_VERTICAL), reverse,
                 curpos, minpos, maxpos, aFrame);
     }
       break;
 
-    case NS_THEME_SCALE_THUMB_HORIZONTAL:
-    case NS_THEME_SCALE_THUMB_VERTICAL:
+    case NS_THEME_SCALETHUMB_HORIZONTAL:
+    case NS_THEME_SCALETHUMB_VERTICAL:
       // do nothing, drawn by scale
       break;
 
     case NS_THEME_RANGE: {
       nsRangeFrame *rangeFrame = do_QueryFrame(aFrame);
       if (!rangeFrame) {
         break;
       }
@@ -2865,21 +2865,21 @@ nsNativeThemeCocoa::DrawWidgetBackground
     }
 
     case NS_THEME_SCROLLBAR_SMALL:
     case NS_THEME_SCROLLBAR:
       if (!ScrollbarTrackAndThumbDrawSeparately()) {
         DrawScrollbar(cgContext, macRect, aFrame);
       }
       break;
-    case NS_THEME_SCROLLBAR_THUMB_VERTICAL:
-    case NS_THEME_SCROLLBAR_THUMB_HORIZONTAL:
+    case NS_THEME_SCROLLBARTHUMB_VERTICAL:
+    case NS_THEME_SCROLLBARTHUMB_HORIZONTAL:
       if (ScrollbarTrackAndThumbDrawSeparately()) {
         BOOL isOverlay = nsLookAndFeel::UseOverlayScrollbars();
-        BOOL isHorizontal = (aWidgetType == NS_THEME_SCROLLBAR_THUMB_HORIZONTAL);
+        BOOL isHorizontal = (aWidgetType == NS_THEME_SCROLLBARTHUMB_HORIZONTAL);
         BOOL isRolledOver = IsParentScrollbarRolledOver(aFrame);
         nsIFrame* scrollbarFrame = GetParentScrollbarFrame(aFrame);
         bool isSmall = (scrollbarFrame && scrollbarFrame->StyleDisplay()->mAppearance == NS_THEME_SCROLLBAR_SMALL);
         if (isOverlay && (!nsCocoaFeatures::OnMountainLionOrLater() || !isRolledOver)) {
           if (isHorizontal) {
             macRect.origin.y += 4;
             macRect.size.height -= 4;
           } else {
@@ -2902,36 +2902,36 @@ nsNativeThemeCocoa::DrawWidgetBackground
                   (isOnTopOfDarkBackground ? @"kCUIVariantWhite" : @""), @"kCUIVariantKey",
                   [NSNumber numberWithBool:YES], @"indiconly",
                   [NSNumber numberWithBool:YES], @"kCUIThumbProportionKey",
                   [NSNumber numberWithBool:YES], @"is.flipped",
                   nil],
                 true);
       }
       break;
-    case NS_THEME_SCROLLBAR_BUTTON_UP:
-    case NS_THEME_SCROLLBAR_BUTTON_LEFT:
+    case NS_THEME_SCROLLBARBUTTON_UP:
+    case NS_THEME_SCROLLBARBUTTON_LEFT:
 #if SCROLLBARS_VISUAL_DEBUG
       CGContextSetRGBFillColor(cgContext, 1.0, 0, 0, 0.6);
       CGContextFillRect(cgContext, macRect);
 #endif
     break;
-    case NS_THEME_SCROLLBAR_BUTTON_DOWN:
-    case NS_THEME_SCROLLBAR_BUTTON_RIGHT:
+    case NS_THEME_SCROLLBARBUTTON_DOWN:
+    case NS_THEME_SCROLLBARBUTTON_RIGHT:
 #if SCROLLBARS_VISUAL_DEBUG
       CGContextSetRGBFillColor(cgContext, 0, 1.0, 0, 0.6);
       CGContextFillRect(cgContext, macRect);
 #endif
     break;
-    case NS_THEME_SCROLLBAR_TRACK_HORIZONTAL:
-    case NS_THEME_SCROLLBAR_TRACK_VERTICAL:
+    case NS_THEME_SCROLLBARTRACK_HORIZONTAL:
+    case NS_THEME_SCROLLBARTRACK_VERTICAL:
       if (ScrollbarTrackAndThumbDrawSeparately()) {
         BOOL isOverlay = nsLookAndFeel::UseOverlayScrollbars();
         if (!isOverlay || IsParentScrollbarRolledOver(aFrame)) {
-          BOOL isHorizontal = (aWidgetType == NS_THEME_SCROLLBAR_TRACK_HORIZONTAL);
+          BOOL isHorizontal = (aWidgetType == NS_THEME_SCROLLBARTRACK_HORIZONTAL);
           nsIFrame* scrollbarFrame = GetParentScrollbarFrame(aFrame);
           bool isSmall = (scrollbarFrame && scrollbarFrame->StyleDisplay()->mAppearance == NS_THEME_SCROLLBAR_SMALL);
           if (isOverlay && !nsCocoaFeatures::OnMountainLionOrLater()) {
             // On OSX 10.7, scrollbars don't grow when hovered.
             // The adjustments below were obtained by trial and error.
             if (isHorizontal) {
               macRect.origin.y += 2.0;
             } else {
@@ -3031,17 +3031,17 @@ nsNativeThemeCocoa::DrawWidgetBackground
       }
     }
       break;
     
     case NS_THEME_TAB:
       DrawSegment(cgContext, macRect, eventState, aFrame, tabRenderSettings);
       break;
 
-    case NS_THEME_TAB_PANELS:
+    case NS_THEME_TABPANELS:
       DrawTabPanel(cgContext, macRect, aFrame);
       break;
 
     case NS_THEME_RESIZER:
       DrawResizer(cgContext, macRect, aFrame);
       break;
 
     case NS_THEME_MAC_VIBRANCY_LIGHT:
@@ -3097,37 +3097,37 @@ nsNativeThemeCocoa::GetWidgetBorder(nsDe
       if (IsButtonTypeMenu(aFrame)) {
         *aResult = DirectionAwareMargin(kAquaDropdownBorder, aFrame);
       } else {
         *aResult = DirectionAwareMargin(nsIntMargin(1, 7, 3, 7), aFrame);
       }
       break;
     }
 
-    case NS_THEME_TOOLBAR_BUTTON:
+    case NS_THEME_TOOLBARBUTTON:
     {
       *aResult = DirectionAwareMargin(nsIntMargin(1, 4, 1, 4), aFrame);
       break;
     }
 
     case NS_THEME_CHECKBOX:
     case NS_THEME_RADIO:
     {
       // nsFormControlFrame::GetIntrinsicWidth and nsFormControlFrame::GetIntrinsicHeight
       // assume a border width of 2px.
       aResult->SizeTo(2, 2, 2, 2);
       break;
     }
 
-    case NS_THEME_DROPDOWN:
-    case NS_THEME_DROPDOWN_BUTTON:
+    case NS_THEME_MENULIST:
+    case NS_THEME_MENULIST_BUTTON:
       *aResult = DirectionAwareMargin(kAquaDropdownBorder, aFrame);
       break;
 
-    case NS_THEME_DROPDOWN_TEXTFIELD:
+    case NS_THEME_MENULIST_TEXTFIELD:
       *aResult = DirectionAwareMargin(kAquaComboboxBorder, aFrame);
       break;
 
     case NS_THEME_NUMBER_INPUT:
     case NS_THEME_TEXTFIELD:
     {
       SInt32 frameOutset = 0;
       ::GetThemeMetric(kThemeMetricEditTextFrameOutset, &frameOutset);
@@ -3152,20 +3152,20 @@ nsNativeThemeCocoa::GetWidgetBorder(nsDe
     case NS_THEME_LISTBOX:
     {
       SInt32 frameOutset = 0;
       ::GetThemeMetric(kThemeMetricListBoxFrameOutset, &frameOutset);
       aResult->SizeTo(frameOutset, frameOutset, frameOutset, frameOutset);
       break;
     }
 
-    case NS_THEME_SCROLLBAR_TRACK_HORIZONTAL:
-    case NS_THEME_SCROLLBAR_TRACK_VERTICAL:
+    case NS_THEME_SCROLLBARTRACK_HORIZONTAL:
+    case NS_THEME_SCROLLBARTRACK_VERTICAL:
     {
-      bool isHorizontal = (aWidgetType == NS_THEME_SCROLLBAR_TRACK_HORIZONTAL);
+      bool isHorizontal = (aWidgetType == NS_THEME_SCROLLBARTRACK_HORIZONTAL);
 
       // On Lion and later, scrollbars have no arrows.
       if (!nsCocoaFeatures::OnLionOrLater()) {
         // There's only an endcap to worry about when both arrows are on the bottom
         NSString *buttonPlacement = [[NSUserDefaults standardUserDefaults] objectForKey:@"AppleScrollBarVariant"];
         if (!buttonPlacement || [buttonPlacement isEqualToString:@"DoubleMax"]) {
           nsIFrame *scrollbarFrame = GetParentScrollbarFrame(aFrame);
           if (!scrollbarFrame) return NS_ERROR_FAILURE;
@@ -3235,26 +3235,26 @@ bool
 nsNativeThemeCocoa::GetWidgetOverflow(nsDeviceContext* aContext, nsIFrame* aFrame,
                                       uint8_t aWidgetType, nsRect* aOverflowRect)
 {
   int32_t p2a = aFrame->PresContext()->AppUnitsPerDevPixel();
   switch (aWidgetType) {
     case NS_THEME_BUTTON:
     case NS_THEME_MAC_DISCLOSURE_BUTTON_OPEN:
     case NS_THEME_MAC_DISCLOSURE_BUTTON_CLOSED:
-    case NS_THEME_MOZ_MAC_HELP_BUTTON:
-    case NS_THEME_TOOLBAR_BUTTON:
+    case NS_THEME_MAC_HELP_BUTTON:
+    case NS_THEME_TOOLBARBUTTON:
     case NS_THEME_NUMBER_INPUT:
     case NS_THEME_TEXTFIELD:
     case NS_THEME_TEXTFIELD_MULTILINE:
     case NS_THEME_SEARCHFIELD:
     case NS_THEME_LISTBOX:
-    case NS_THEME_DROPDOWN:
-    case NS_THEME_DROPDOWN_BUTTON:
-    case NS_THEME_DROPDOWN_TEXTFIELD:
+    case NS_THEME_MENULIST:
+    case NS_THEME_MENULIST_BUTTON:
+    case NS_THEME_MENULIST_TEXTFIELD:
     case NS_THEME_CHECKBOX:
     case NS_THEME_RADIO:
     case NS_THEME_TAB:
     {
       // We assume that the above widgets can draw a focus ring that will be less than
       // or equal to 4 pixels thick.
       nsIntMargin extraSize = nsIntMargin(kMaxFocusRingWidth,
                                           kMaxFocusRingWidth,
@@ -3325,32 +3325,32 @@ nsNativeThemeCocoa::GetMinimumWidgetSize
     case NS_THEME_MAC_DISCLOSURE_BUTTON_OPEN:
     case NS_THEME_MAC_DISCLOSURE_BUTTON_CLOSED:
     {
       aResult->SizeTo(kDisclosureButtonSize.width, kDisclosureButtonSize.height);
       *aIsOverridable = false;
       break;
     }
 
-    case NS_THEME_MOZ_MAC_HELP_BUTTON:
+    case NS_THEME_MAC_HELP_BUTTON:
     {
       aResult->SizeTo(kHelpButtonSize.width, kHelpButtonSize.height);
       *aIsOverridable = false;
       break;
     }
 
-    case NS_THEME_TOOLBAR_BUTTON:
+    case NS_THEME_TOOLBARBUTTON:
     {
       aResult->SizeTo(0, toolbarButtonHeights[miniControlSize]);
       break;
     }
 
     case NS_THEME_SPINNER:
-    case NS_THEME_SPINNER_UP_BUTTON:
-    case NS_THEME_SPINNER_DOWN_BUTTON:
+    case NS_THEME_SPINNER_UPBUTTON:
+    case NS_THEME_SPINNER_DOWNBUTTON:
     {
       SInt32 buttonHeight = 0, buttonWidth = 0;
       if (aFrame->GetContent()->IsXULElement()) {
         ::GetThemeMetric(kThemeMetricLittleArrowsWidth, &buttonWidth);
         ::GetThemeMetric(kThemeMetricLittleArrowsHeight, &buttonHeight);
       } else {
         NSSize size =
           spinnerSettings.minimumSizes[EnumSizeForCocoaSize(NSMiniControlSize)];
@@ -3361,18 +3361,18 @@ nsNativeThemeCocoa::GetMinimumWidgetSize
           buttonHeight /= 2;
         }
       }
       aResult->SizeTo(buttonWidth, buttonHeight);
       *aIsOverridable = true;
       break;
     }
 
-    case NS_THEME_DROPDOWN:
-    case NS_THEME_DROPDOWN_BUTTON:
+    case NS_THEME_MENULIST:
+    case NS_THEME_MENULIST_BUTTON:
     {
       SInt32 popupHeight = 0;
       ::GetThemeMetric(kThemeMetricPopupButtonHeight, &popupHeight);
       aResult->SizeTo(0, popupHeight);
       break;
     }
 
     case NS_THEME_NUMBER_INPUT:
@@ -3389,17 +3389,17 @@ nsNativeThemeCocoa::GetMinimumWidgetSize
 
     case NS_THEME_WINDOW_BUTTON_BOX: {
       NSSize size = WindowButtonsSize(aFrame);
       aResult->SizeTo(size.width, size.height);
       *aIsOverridable = false;
       break;
     }
 
-    case NS_THEME_MOZ_MAC_FULLSCREEN_BUTTON: {
+    case NS_THEME_MAC_FULLSCREEN_BUTTON: {
       if ([NativeWindowForFrame(aFrame) respondsToSelector:@selector(toggleFullScreen:)] &&
           !nsCocoaFeatures::OnYosemiteOrLater()) {
         // This value is hardcoded because it's needed before we can measure the
         // position and size of the fullscreen button.
         aResult->SizeTo(16, 17);
       }
       *aIsOverridable = false;
       break;
@@ -3408,29 +3408,29 @@ nsNativeThemeCocoa::GetMinimumWidgetSize
     case NS_THEME_PROGRESSBAR:
     {
       SInt32 barHeight = 0;
       ::GetThemeMetric(kThemeMetricNormalProgressBarThickness, &barHeight);
       aResult->SizeTo(0, barHeight);
       break;
     }
 
-    case NS_THEME_TREEVIEW_TWISTY:
-    case NS_THEME_TREEVIEW_TWISTY_OPEN:   
+    case NS_THEME_TREETWISTY:
+    case NS_THEME_TREETWISTYOPEN:   
     {
       SInt32 twistyHeight = 0, twistyWidth = 0;
       ::GetThemeMetric(kThemeMetricDisclosureButtonWidth, &twistyWidth);
       ::GetThemeMetric(kThemeMetricDisclosureButtonHeight, &twistyHeight);
       aResult->SizeTo(twistyWidth, twistyHeight);
       *aIsOverridable = false;
       break;
     }
     
-    case NS_THEME_TREEVIEW_HEADER:
-    case NS_THEME_TREEVIEW_HEADER_CELL:
+    case NS_THEME_TREEHEADER:
+    case NS_THEME_TREEHEADERCELL:
     {
       SInt32 headerHeight = 0;
       ::GetThemeMetric(kThemeMetricListHeaderHeight, &headerHeight);
       aResult->SizeTo(0, headerHeight - 1); // We don't need the top border.
       break;
     }
 
     case NS_THEME_TAB:
@@ -3481,36 +3481,36 @@ nsNativeThemeCocoa::GetMinimumWidgetSize
     {
       SInt32 scaleWidth = 0;
       ::GetThemeMetric(kThemeMetricVSliderWidth, &scaleWidth);
       aResult->SizeTo(scaleWidth, scaleWidth);
       *aIsOverridable = false;
       break;
     }
 
-    case NS_THEME_SCROLLBAR_THUMB_HORIZONTAL:
-    case NS_THEME_SCROLLBAR_THUMB_VERTICAL:
+    case NS_THEME_SCROLLBARTHUMB_HORIZONTAL:
+    case NS_THEME_SCROLLBARTHUMB_VERTICAL:
     {
       // Find our parent scrollbar frame in order to find out whether we're in
       // a small or a large scrollbar.
       nsIFrame *scrollbarFrame = GetParentScrollbarFrame(aFrame);
       if (!scrollbarFrame)
         return NS_ERROR_FAILURE;
 
       bool isSmall = (scrollbarFrame->StyleDisplay()->mAppearance == NS_THEME_SCROLLBAR_SMALL);
-      bool isHorizontal = (aWidgetType == NS_THEME_SCROLLBAR_THUMB_HORIZONTAL);
+      bool isHorizontal = (aWidgetType == NS_THEME_SCROLLBARTHUMB_HORIZONTAL);
       int32_t& minSize = isHorizontal ? aResult->width : aResult->height;
       minSize = isSmall ? kSmallScrollbarThumbMinSize : kRegularScrollbarThumbMinSize;
       break;
     }
 
     case NS_THEME_SCROLLBAR:
     case NS_THEME_SCROLLBAR_SMALL:
-    case NS_THEME_SCROLLBAR_TRACK_VERTICAL:
-    case NS_THEME_SCROLLBAR_TRACK_HORIZONTAL:
+    case NS_THEME_SCROLLBARTRACK_VERTICAL:
+    case NS_THEME_SCROLLBARTRACK_HORIZONTAL:
     {
       *aIsOverridable = false;
 
       if (nsLookAndFeel::UseOverlayScrollbars()) {
         nsIFrame* scrollbarFrame = GetParentScrollbarFrame(aFrame);
         if (scrollbarFrame &&
             scrollbarFrame->StyleDisplay()->mAppearance ==
               NS_THEME_SCROLLBAR_SMALL) {
@@ -3557,33 +3557,33 @@ nsNativeThemeCocoa::GetMinimumWidgetSize
       }
 
       SInt32 scrollbarWidth = 0;
       ::GetThemeMetric(themeMetric, &scrollbarWidth);
       aResult->SizeTo(scrollbarWidth, scrollbarWidth);
       break;
     }
 
-    case NS_THEME_SCROLLBAR_BUTTON_UP:
-    case NS_THEME_SCROLLBAR_BUTTON_DOWN:
-    case NS_THEME_SCROLLBAR_BUTTON_LEFT:
-    case NS_THEME_SCROLLBAR_BUTTON_RIGHT:
+    case NS_THEME_SCROLLBARBUTTON_UP:
+    case NS_THEME_SCROLLBARBUTTON_DOWN:
+    case NS_THEME_SCROLLBARBUTTON_LEFT:
+    case NS_THEME_SCROLLBARBUTTON_RIGHT:
     {
       nsIFrame *scrollbarFrame = GetParentScrollbarFrame(aFrame);
       if (!scrollbarFrame) return NS_ERROR_FAILURE;
 
-      // Since there is no NS_THEME_SCROLLBAR_BUTTON_UP_SMALL we need to ask the parent what appearance style it has.
+      // Since there is no NS_THEME_SCROLLBARBUTTON_UP_SMALL we need to ask the parent what appearance style it has.
       int32_t themeMetric = (scrollbarFrame->StyleDisplay()->mAppearance == NS_THEME_SCROLLBAR_SMALL) ?
                             kThemeMetricSmallScrollBarWidth :
                             kThemeMetricScrollBarWidth;
       SInt32 scrollbarWidth = 0;
       ::GetThemeMetric(themeMetric, &scrollbarWidth);
 
       // It seems that for both sizes of scrollbar, the buttons are one pixel "longer".
-      if (aWidgetType == NS_THEME_SCROLLBAR_BUTTON_LEFT || aWidgetType == NS_THEME_SCROLLBAR_BUTTON_RIGHT)
+      if (aWidgetType == NS_THEME_SCROLLBARBUTTON_LEFT || aWidgetType == NS_THEME_SCROLLBARBUTTON_RIGHT)
         aResult->SizeTo(scrollbarWidth+1, scrollbarWidth);
       else
         aResult->SizeTo(scrollbarWidth, scrollbarWidth+1);
  
       *aIsOverridable = false;
       break;
     }
     case NS_THEME_RESIZER:
@@ -3617,30 +3617,30 @@ nsNativeThemeCocoa::WidgetStateChanged(n
                                        const nsAttrValue* aOldValue)
 {
   // Some widget types just never change state.
   switch (aWidgetType) {
     case NS_THEME_WINDOW_TITLEBAR:
     case NS_THEME_TOOLBOX:
     case NS_THEME_TOOLBAR:
     case NS_THEME_STATUSBAR:
-    case NS_THEME_STATUSBAR_PANEL:
-    case NS_THEME_STATUSBAR_RESIZER_PANEL:
+    case NS_THEME_STATUSBARPANEL:
+    case NS_THEME_RESIZER_PANEL:
     case NS_THEME_TOOLTIP:
-    case NS_THEME_TAB_PANELS:
-    case NS_THEME_TAB_PANEL:
+    case NS_THEME_TABPANELS:
+    case NS_THEME_TABPANEL:
     case NS_THEME_DIALOG:
     case NS_THEME_MENUPOPUP:
     case NS_THEME_GROUPBOX:
-    case NS_THEME_PROGRESSBAR_CHUNK:
-    case NS_THEME_PROGRESSBAR_CHUNK_VERTICAL:
+    case NS_THEME_PROGRESSCHUNK:
+    case NS_THEME_PROGRESSCHUNK_VERTICAL:
     case NS_THEME_PROGRESSBAR:
     case NS_THEME_PROGRESSBAR_VERTICAL:
     case NS_THEME_METERBAR:
-    case NS_THEME_METERBAR_CHUNK:
+    case NS_THEME_METERCHUNK:
     case NS_THEME_MAC_VIBRANCY_LIGHT:
     case NS_THEME_MAC_VIBRANCY_DARK:
       *aShouldRepaint = false;
       return NS_OK;
   }
 
   // XXXdwh Not sure what can really be done here.  Can at least guess for
   // specific widgets that they're highly unlikely to have certain states.
@@ -3694,109 +3694,109 @@ nsNativeThemeCocoa::ThemeSupportsWidget(
 {
   // We don't have CSS set up to render non-native scrollbars on Mac OS X so we
   // render natively even if native theme support is disabled.
   if (aWidgetType != NS_THEME_SCROLLBAR &&
       aPresContext && !aPresContext->PresShell()->IsThemeSupportEnabled())
     return false;
 
   // if this is a dropdown button in a combobox the answer is always no
-  if (aWidgetType == NS_THEME_DROPDOWN_BUTTON) {
+  if (aWidgetType == NS_THEME_MENULIST_BUTTON) {
     nsIFrame* parentFrame = aFrame->GetParent();
     if (parentFrame && (parentFrame->GetType() == nsGkAtoms::comboboxControlFrame))
       return false;
   }
 
   switch (aWidgetType) {
     // Combobox dropdowns don't support native theming in vertical mode.
-    case NS_THEME_DROPDOWN:
-    case NS_THEME_DROPDOWN_BUTTON:
-    case NS_THEME_DROPDOWN_TEXT:
-    case NS_THEME_DROPDOWN_TEXTFIELD:
+    case NS_THEME_MENULIST:
+    case NS_THEME_MENULIST_BUTTON:
+    case NS_THEME_MENULIST_TEXT:
+    case NS_THEME_MENULIST_TEXTFIELD:
       if (aFrame && aFrame->GetWritingMode().IsVertical()) {
         return false;
       }
       MOZ_FALLTHROUGH;
 
     case NS_THEME_LISTBOX:
 
     case NS_THEME_DIALOG:
     case NS_THEME_WINDOW:
     case NS_THEME_WINDOW_BUTTON_BOX:
     case NS_THEME_WINDOW_TITLEBAR:
     case NS_THEME_CHECKMENUITEM:
     case NS_THEME_MENUPOPUP:
     case NS_THEME_MENUARROW:
     case NS_THEME_MENUITEM:
     case NS_THEME_MENUSEPARATOR:
-    case NS_THEME_MOZ_MAC_FULLSCREEN_BUTTON:
+    case NS_THEME_MAC_FULLSCREEN_BUTTON:
     case NS_THEME_TOOLTIP:
     
     case NS_THEME_CHECKBOX:
     case NS_THEME_CHECKBOX_CONTAINER:
     case NS_THEME_RADIO:
     case NS_THEME_RADIO_CONTAINER:
     case NS_THEME_GROUPBOX:
-    case NS_THEME_MOZ_MAC_HELP_BUTTON:
+    case NS_THEME_MAC_HELP_BUTTON:
     case NS_THEME_MAC_DISCLOSURE_BUTTON_OPEN:
     case NS_THEME_MAC_DISCLOSURE_BUTTON_CLOSED:
     case NS_THEME_BUTTON:
     case NS_THEME_BUTTON_ARROW_UP:
     case NS_THEME_BUTTON_ARROW_DOWN:
     case NS_THEME_BUTTON_BEVEL:
-    case NS_THEME_TOOLBAR_BUTTON:
+    case NS_THEME_TOOLBARBUTTON:
     case NS_THEME_SPINNER:
-    case NS_THEME_SPINNER_UP_BUTTON:
-    case NS_THEME_SPINNER_DOWN_BUTTON:
+    case NS_THEME_SPINNER_UPBUTTON:
+    case NS_THEME_SPINNER_DOWNBUTTON:
     case NS_THEME_TOOLBAR:
     case NS_THEME_STATUSBAR:
     case NS_THEME_NUMBER_INPUT:
     case NS_THEME_TEXTFIELD:
     case NS_THEME_TEXTFIELD_MULTILINE:
     case NS_THEME_SEARCHFIELD:
     case NS_THEME_TOOLBOX:
-    //case NS_THEME_TOOLBAR_BUTTON:
+    //case NS_THEME_TOOLBARBUTTON:
     case NS_THEME_PROGRESSBAR:
     case NS_THEME_PROGRESSBAR_VERTICAL:
-    case NS_THEME_PROGRESSBAR_CHUNK:
-    case NS_THEME_PROGRESSBAR_CHUNK_VERTICAL:
+    case NS_THEME_PROGRESSCHUNK:
+    case NS_THEME_PROGRESSCHUNK_VERTICAL:
     case NS_THEME_METERBAR:
-    case NS_THEME_METERBAR_CHUNK:
-    case NS_THEME_TOOLBAR_SEPARATOR:
+    case NS_THEME_METERCHUNK:
+    case NS_THEME_SEPARATOR:
     
-    case NS_THEME_TAB_PANELS:
+    case NS_THEME_TABPANELS:
     case NS_THEME_TAB:
     
-    case NS_THEME_TREEVIEW_TWISTY:
-    case NS_THEME_TREEVIEW_TWISTY_OPEN:
+    case NS_THEME_TREETWISTY:
+    case NS_THEME_TREETWISTYOPEN:
     case NS_THEME_TREEVIEW:
-    case NS_THEME_TREEVIEW_HEADER:
-    case NS_THEME_TREEVIEW_HEADER_CELL:
-    case NS_THEME_TREEVIEW_HEADER_SORTARROW:
-    case NS_THEME_TREEVIEW_TREEITEM:
-    case NS_THEME_TREEVIEW_LINE:
+    case NS_THEME_TREEHEADER:
+    case NS_THEME_TREEHEADERCELL:
+    case NS_THEME_TREEHEADERSORTARROW:
+    case NS_THEME_TREEITEM:
+    case NS_THEME_TREELINE:
     case NS_THEME_MAC_SOURCE_LIST:
 
     case NS_THEME_RANGE:
 
     case NS_THEME_SCALE_HORIZONTAL:
-    case NS_THEME_SCALE_THUMB_HORIZONTAL:
+    case NS_THEME_SCALETHUMB_HORIZONTAL:
     case NS_THEME_SCALE_VERTICAL:
-    case NS_THEME_SCALE_THUMB_VERTICAL:
+    case NS_THEME_SCALETHUMB_VERTICAL:
 
     case NS_THEME_SCROLLBAR:
     case NS_THEME_SCROLLBAR_SMALL:
-    case NS_THEME_SCROLLBAR_BUTTON_UP:
-    case NS_THEME_SCROLLBAR_BUTTON_DOWN:
-    case NS_THEME_SCROLLBAR_BUTTON_LEFT:
-    case NS_THEME_SCROLLBAR_BUTTON_RIGHT:
-    case NS_THEME_SCROLLBAR_THUMB_HORIZONTAL:
-    case NS_THEME_SCROLLBAR_THUMB_VERTICAL:
-    case NS_THEME_SCROLLBAR_TRACK_VERTICAL:
-    case NS_THEME_SCROLLBAR_TRACK_HORIZONTAL:
+    case NS_THEME_SCROLLBARBUTTON_UP:
+    case NS_THEME_SCROLLBARBUTTON_DOWN:
+    case NS_THEME_SCROLLBARBUTTON_LEFT:
+    case NS_THEME_SCROLLBARBUTTON_RIGHT:
+    case NS_THEME_SCROLLBARTHUMB_HORIZONTAL:
+    case NS_THEME_SCROLLBARTHUMB_VERTICAL:
+    case NS_THEME_SCROLLBARTRACK_VERTICAL:
+    case NS_THEME_SCROLLBARTRACK_HORIZONTAL:
     case NS_THEME_SCROLLBAR_NON_DISAPPEARING:
       return !IsWidgetStyled(aPresContext, aFrame, aWidgetType);
 
     case NS_THEME_RESIZER:
     {
       nsIFrame* parentFrame = aFrame->GetParent();
       if (!parentFrame || parentFrame->GetType() != nsGkAtoms::scrollFrame)
         return true;
@@ -3822,37 +3822,37 @@ nsNativeThemeCocoa::ThemeSupportsWidget(
   return false;
 }
 
 bool
 nsNativeThemeCocoa::WidgetIsContainer(uint8_t aWidgetType)
 {
   // flesh this out at some point
   switch (aWidgetType) {
-   case NS_THEME_DROPDOWN_BUTTON:
+   case NS_THEME_MENULIST_BUTTON:
    case NS_THEME_RADIO:
    case NS_THEME_CHECKBOX:
    case NS_THEME_PROGRESSBAR:
    case NS_THEME_METERBAR:
    case NS_THEME_RANGE:
-   case NS_THEME_MOZ_MAC_HELP_BUTTON:
+   case NS_THEME_MAC_HELP_BUTTON:
    case NS_THEME_MAC_DISCLOSURE_BUTTON_OPEN:
    case NS_THEME_MAC_DISCLOSURE_BUTTON_CLOSED:
     return false;
   }
   return true;
 }
 
 bool
 nsNativeThemeCocoa::ThemeDrawsFocusForWidget(uint8_t aWidgetType)
 {
-  if (aWidgetType == NS_THEME_DROPDOWN ||
-      aWidgetType == NS_THEME_DROPDOWN_TEXTFIELD ||
+  if (aWidgetType == NS_THEME_MENULIST ||
+      aWidgetType == NS_THEME_MENULIST_TEXTFIELD ||
       aWidgetType == NS_THEME_BUTTON ||
-      aWidgetType == NS_THEME_MOZ_MAC_HELP_BUTTON ||
+      aWidgetType == NS_THEME_MAC_HELP_BUTTON ||
       aWidgetType == NS_THEME_MAC_DISCLOSURE_BUTTON_OPEN ||
       aWidgetType == NS_THEME_MAC_DISCLOSURE_BUTTON_CLOSED ||
       aWidgetType == NS_THEME_RADIO ||
       aWidgetType == NS_THEME_RANGE ||
       aWidgetType == NS_THEME_CHECKBOX)
     return true;
 
   return false;
@@ -3865,34 +3865,34 @@ nsNativeThemeCocoa::ThemeNeedsComboboxDr
 }
 
 bool
 nsNativeThemeCocoa::WidgetAppearanceDependsOnWindowFocus(uint8_t aWidgetType)
 {
   switch (aWidgetType) {
     case NS_THEME_DIALOG:
     case NS_THEME_GROUPBOX:
-    case NS_THEME_TAB_PANELS:
+    case NS_THEME_TABPANELS:
     case NS_THEME_BUTTON_ARROW_UP:
     case NS_THEME_BUTTON_ARROW_DOWN:
     case NS_THEME_CHECKMENUITEM:
     case NS_THEME_MENUPOPUP:
     case NS_THEME_MENUARROW:
     case NS_THEME_MENUITEM:
     case NS_THEME_MENUSEPARATOR:
     case NS_THEME_TOOLTIP:
     case NS_THEME_SPINNER:
-    case NS_THEME_SPINNER_UP_BUTTON:
-    case NS_THEME_SPINNER_DOWN_BUTTON:
-    case NS_THEME_TOOLBAR_SEPARATOR:
+    case NS_THEME_SPINNER_UPBUTTON:
+    case NS_THEME_SPINNER_DOWNBUTTON:
+    case NS_THEME_SEPARATOR:
     case NS_THEME_TOOLBOX:
     case NS_THEME_NUMBER_INPUT:
     case NS_THEME_TEXTFIELD:
     case NS_THEME_TREEVIEW:
-    case NS_THEME_TREEVIEW_LINE:
+    case NS_THEME_TREELINE:
     case NS_THEME_TEXTFIELD_MULTILINE:
     case NS_THEME_LISTBOX:
     case NS_THEME_RESIZER:
       return false;
     default:
       return true;
   }
 }
@@ -3977,17 +3977,17 @@ nsNativeThemeCocoa::ThemeGeometryTypeFor
     case NS_THEME_WINDOW_TITLEBAR:
       return eThemeGeometryTypeTitlebar;
     case NS_THEME_TOOLBAR:
       return eThemeGeometryTypeToolbar;
     case NS_THEME_TOOLBOX:
       return eThemeGeometryTypeToolbox;
     case NS_THEME_WINDOW_BUTTON_BOX:
       return eThemeGeometryTypeWindowButtons;
-    case NS_THEME_MOZ_MAC_FULLSCREEN_BUTTON:
+    case NS_THEME_MAC_FULLSCREEN_BUTTON:
       return eThemeGeometryTypeFullscreenButton;
     case NS_THEME_MAC_VIBRANCY_LIGHT:
       return eThemeGeometryTypeVibrancyLight;
     case NS_THEME_MAC_VIBRANCY_DARK:
       return eThemeGeometryTypeVibrancyDark;
     case NS_THEME_TOOLTIP:
       return eThemeGeometryTypeTooltip;
     case NS_THEME_MENUPOPUP:
--- a/widget/gtk/nsNativeThemeGTK.cpp
+++ b/widget/gtk/nsNativeThemeGTK.cpp
@@ -175,20 +175,20 @@ nsNativeThemeGTK::GetTabMarginPixels(nsI
   return std::min<gint>(MOZ_GTK_TAB_MARGIN_MASK,
                 std::max(0,
                        aFrame->PresContext()->AppUnitsToDevPixels(-margin)));
 }
 
 static bool ShouldScrollbarButtonBeDisabled(int32_t aCurpos, int32_t aMaxpos,
                                             uint8_t aWidgetType)
 {
-  return ((aCurpos == 0 && (aWidgetType == NS_THEME_SCROLLBAR_BUTTON_UP ||
-                            aWidgetType == NS_THEME_SCROLLBAR_BUTTON_LEFT))
-      || (aCurpos == aMaxpos && (aWidgetType == NS_THEME_SCROLLBAR_BUTTON_DOWN ||
-                                 aWidgetType == NS_THEME_SCROLLBAR_BUTTON_RIGHT)));
+  return ((aCurpos == 0 && (aWidgetType == NS_THEME_SCROLLBARBUTTON_UP ||
+                            aWidgetType == NS_THEME_SCROLLBARBUTTON_LEFT))
+      || (aCurpos == aMaxpos && (aWidgetType == NS_THEME_SCROLLBARBUTTON_DOWN ||
+                                 aWidgetType == NS_THEME_SCROLLBARBUTTON_RIGHT)));
 }
 
 bool
 nsNativeThemeGTK::GetGtkWidgetAndState(uint8_t aWidgetType, nsIFrame* aFrame,
                                        WidgetNodeType& aGtkWidgetType,
                                        GtkWidgetState* aState,
                                        gint* aWidgetFlags)
 {
@@ -235,18 +235,18 @@ nsNativeThemeGTK::GetGtkWidgetAndState(u
               if (isHTMLChecked)
                 *aWidgetFlags |= MOZ_GTK_WIDGET_CHECKED;
             }
 
             if (GetIndeterminate(aFrame))
               *aWidgetFlags |= MOZ_GTK_WIDGET_INCONSISTENT;
           }
         }
-      } else if (aWidgetType == NS_THEME_TOOLBAR_BUTTON_DROPDOWN ||
-                 aWidgetType == NS_THEME_TREEVIEW_HEADER_SORTARROW ||
+      } else if (aWidgetType == NS_THEME_TOOLBARBUTTON_DROPDOWN ||
+                 aWidgetType == NS_THEME_TREEHEADERSORTARROW ||
                  aWidgetType == NS_THEME_BUTTON_ARROW_PREVIOUS ||
                  aWidgetType == NS_THEME_BUTTON_ARROW_NEXT ||
                  aWidgetType == NS_THEME_BUTTON_ARROW_UP ||
                  aWidgetType == NS_THEME_BUTTON_ARROW_DOWN) {
         // The state of an arrow comes from its parent.
         stateFrame = aFrame = aFrame->GetParent();
       }
 
@@ -265,60 +265,60 @@ nsNativeThemeGTK::GetGtkWidgetAndState(u
         aState->active  = FALSE;
         aState->inHover = FALSE;
         aState->isDefault = FALSE;
         aState->canDefault = FALSE;
 
         aState->focused = TRUE;
         aState->depressed = TRUE; // see moz_gtk_entry_paint()
       } else if (aWidgetType == NS_THEME_BUTTON ||
-                 aWidgetType == NS_THEME_TOOLBAR_BUTTON ||
-                 aWidgetType == NS_THEME_TOOLBAR_DUAL_BUTTON ||
-                 aWidgetType == NS_THEME_TOOLBAR_BUTTON_DROPDOWN ||
-                 aWidgetType == NS_THEME_DROPDOWN ||
-                 aWidgetType == NS_THEME_DROPDOWN_BUTTON) {
+                 aWidgetType == NS_THEME_TOOLBARBUTTON ||
+                 aWidgetType == NS_THEME_DUALBUTTON ||
+                 aWidgetType == NS_THEME_TOOLBARBUTTON_DROPDOWN ||
+                 aWidgetType == NS_THEME_MENULIST ||
+                 aWidgetType == NS_THEME_MENULIST_BUTTON) {
         aState->active &= aState->inHover;
       }
 
       if (IsFrameContentNodeInNamespace(aFrame, kNameSpaceID_XUL)) {
         // For these widget types, some element (either a child or parent)
         // actually has element focus, so we check the focused attribute
         // to see whether to draw in the focused state.
         if (aWidgetType == NS_THEME_NUMBER_INPUT ||
             aWidgetType == NS_THEME_TEXTFIELD ||
             aWidgetType == NS_THEME_TEXTFIELD_MULTILINE ||
-            aWidgetType == NS_THEME_DROPDOWN_TEXTFIELD ||
+            aWidgetType == NS_THEME_MENULIST_TEXTFIELD ||
             aWidgetType == NS_THEME_SPINNER_TEXTFIELD ||
             aWidgetType == NS_THEME_RADIO_CONTAINER ||
             aWidgetType == NS_THEME_RADIO_LABEL) {
           aState->focused = IsFocused(aFrame);
         } else if (aWidgetType == NS_THEME_RADIO ||
                    aWidgetType == NS_THEME_CHECKBOX) {
           // In XUL, checkboxes and radios shouldn't have focus rings, their labels do
           aState->focused = FALSE;
         }
 
-        if (aWidgetType == NS_THEME_SCROLLBAR_THUMB_VERTICAL ||
-            aWidgetType == NS_THEME_SCROLLBAR_THUMB_HORIZONTAL) {
+        if (aWidgetType == NS_THEME_SCROLLBARTHUMB_VERTICAL ||
+            aWidgetType == NS_THEME_SCROLLBARTHUMB_HORIZONTAL) {
           // for scrollbars we need to go up two to go from the thumb to
           // the slider to the actual scrollbar object
           nsIFrame *tmpFrame = aFrame->GetParent()->GetParent();
 
           aState->curpos = CheckIntAttr(tmpFrame, nsGkAtoms::curpos, 0);
           aState->maxpos = CheckIntAttr(tmpFrame, nsGkAtoms::maxpos, 100);
 
           if (CheckBooleanAttr(aFrame, nsGkAtoms::active)) {
             aState->active = TRUE;
           }
         }
 
-        if (aWidgetType == NS_THEME_SCROLLBAR_BUTTON_UP ||
-            aWidgetType == NS_THEME_SCROLLBAR_BUTTON_DOWN ||
-            aWidgetType == NS_THEME_SCROLLBAR_BUTTON_LEFT ||
-            aWidgetType == NS_THEME_SCROLLBAR_BUTTON_RIGHT) {
+        if (aWidgetType == NS_THEME_SCROLLBARBUTTON_UP ||
+            aWidgetType == NS_THEME_SCROLLBARBUTTON_DOWN ||
+            aWidgetType == NS_THEME_SCROLLBARBUTTON_LEFT ||
+            aWidgetType == NS_THEME_SCROLLBARBUTTON_RIGHT) {
           // set the state to disabled when the scrollbar is scrolled to
           // the beginning or the end, depending on the button type.
           int32_t curpos = CheckIntAttr(aFrame, nsGkAtoms::curpos, 0);
           int32_t maxpos = CheckIntAttr(aFrame, nsGkAtoms::maxpos, 100);
           if (ShouldScrollbarButtonBeDisabled(curpos, maxpos, aWidgetType)) {
             aState->disabled = true;
           }
 
@@ -326,17 +326,17 @@ nsNativeThemeGTK::GetGtkWidgetAndState(u
           // we set the active attribute on the element to true if it's
           // pressed with any mouse button.
           // This allows us to show that it's active without setting :active
           else if (CheckBooleanAttr(aFrame, nsGkAtoms::active))
             aState->active = true;
 
           if (aWidgetFlags) {
             *aWidgetFlags = GetScrollbarButtonType(aFrame);
-            if (aWidgetType - NS_THEME_SCROLLBAR_BUTTON_UP < 2)
+            if (aWidgetType - NS_THEME_SCROLLBARBUTTON_UP < 2)
               *aWidgetFlags |= MOZ_GTK_STEPPER_VERTICAL;
           }
         }
 
         // menu item state is determined by the attribute "_moz-menuactive",
         // and not by the mouse hovering (accessibility).  as a special case,
         // menus which are children of a menu bar are only marked as prelight
         // if they are open, not on normal hover.
@@ -371,88 +371,88 @@ nsNativeThemeGTK::GetGtkWidgetAndState(u
                             nsGkAtoms::_true, eIgnoreCase);
             }
           }
         }
 
         // A button with drop down menu open or an activated toggle button
         // should always appear depressed.
         if (aWidgetType == NS_THEME_BUTTON ||
-            aWidgetType == NS_THEME_TOOLBAR_BUTTON ||
-            aWidgetType == NS_THEME_TOOLBAR_DUAL_BUTTON ||
-            aWidgetType == NS_THEME_TOOLBAR_BUTTON_DROPDOWN ||
-            aWidgetType == NS_THEME_DROPDOWN ||
-            aWidgetType == NS_THEME_DROPDOWN_BUTTON) {
+            aWidgetType == NS_THEME_TOOLBARBUTTON ||
+            aWidgetType == NS_THEME_DUALBUTTON ||
+            aWidgetType == NS_THEME_TOOLBARBUTTON_DROPDOWN ||
+            aWidgetType == NS_THEME_MENULIST ||
+            aWidgetType == NS_THEME_MENULIST_BUTTON) {
           bool menuOpen = IsOpenButton(aFrame);
           aState->depressed = IsCheckedButton(aFrame) || menuOpen;
           // we must not highlight buttons with open drop down menus on hover.
           aState->inHover = aState->inHover && !menuOpen;
         }
 
         // When the input field of the drop down button has focus, some themes
         // should draw focus for the drop down button as well.
-        if (aWidgetType == NS_THEME_DROPDOWN_BUTTON && aWidgetFlags) {
+        if (aWidgetType == NS_THEME_MENULIST_BUTTON && aWidgetFlags) {
           *aWidgetFlags = CheckBooleanAttr(aFrame, nsGkAtoms::parentfocused);
         }
       }
     }
   }
 
   switch (aWidgetType) {
   case NS_THEME_BUTTON:
     if (aWidgetFlags)
       *aWidgetFlags = GTK_RELIEF_NORMAL;
     aGtkWidgetType = MOZ_GTK_BUTTON;
     break;
-  case NS_THEME_TOOLBAR_BUTTON:
-  case NS_THEME_TOOLBAR_DUAL_BUTTON:
+  case NS_THEME_TOOLBARBUTTON:
+  case NS_THEME_DUALBUTTON:
     if (aWidgetFlags)
       *aWidgetFlags = GTK_RELIEF_NONE;
     aGtkWidgetType = MOZ_GTK_TOOLBAR_BUTTON;
     break;
   case NS_THEME_FOCUS_OUTLINE:
     aGtkWidgetType = MOZ_GTK_ENTRY;
     break;
   case NS_THEME_CHECKBOX:
   case NS_THEME_RADIO:
     aGtkWidgetType = (aWidgetType == NS_THEME_RADIO) ? MOZ_GTK_RADIOBUTTON : MOZ_GTK_CHECKBUTTON;
     break;
-  case NS_THEME_SCROLLBAR_BUTTON_UP:
-  case NS_THEME_SCROLLBAR_BUTTON_DOWN:
-  case NS_THEME_SCROLLBAR_BUTTON_LEFT:
-  case NS_THEME_SCROLLBAR_BUTTON_RIGHT:
+  case NS_THEME_SCROLLBARBUTTON_UP:
+  case NS_THEME_SCROLLBARBUTTON_DOWN:
+  case NS_THEME_SCROLLBARBUTTON_LEFT:
+  case NS_THEME_SCROLLBARBUTTON_RIGHT:
     aGtkWidgetType = MOZ_GTK_SCROLLBAR_BUTTON;
     break;
   case NS_THEME_SCROLLBAR_VERTICAL:
     aGtkWidgetType = MOZ_GTK_SCROLLBAR_VERTICAL;
     if (GetWidgetTransparency(aFrame, aWidgetType) == eOpaque)
         *aWidgetFlags = MOZ_GTK_TRACK_OPAQUE;
     else
         *aWidgetFlags = 0;
     break;
   case NS_THEME_SCROLLBAR_HORIZONTAL:
     aGtkWidgetType = MOZ_GTK_SCROLLBAR_HORIZONTAL;
     if (GetWidgetTransparency(aFrame, aWidgetType) == eOpaque)
         *aWidgetFlags = MOZ_GTK_TRACK_OPAQUE;
     else
         *aWidgetFlags = 0;
     break;
-  case NS_THEME_SCROLLBAR_THUMB_VERTICAL:
+  case NS_THEME_SCROLLBARTHUMB_VERTICAL:
     aGtkWidgetType = MOZ_GTK_SCROLLBAR_THUMB_VERTICAL;
     break;
-  case NS_THEME_SCROLLBAR_THUMB_HORIZONTAL:
+  case NS_THEME_SCROLLBARTHUMB_HORIZONTAL:
     aGtkWidgetType = MOZ_GTK_SCROLLBAR_THUMB_HORIZONTAL;
     break;
   case NS_THEME_SPINNER:
     aGtkWidgetType = MOZ_GTK_SPINBUTTON;
     break;
-  case NS_THEME_SPINNER_UP_BUTTON:
+  case NS_THEME_SPINNER_UPBUTTON:
     aGtkWidgetType = MOZ_GTK_SPINBUTTON_UP;
     break;
-  case NS_THEME_SPINNER_DOWN_BUTTON:
+  case NS_THEME_SPINNER_DOWNBUTTON:
     aGtkWidgetType = MOZ_GTK_SPINBUTTON_DOWN;
     break;
   case NS_THEME_SPINNER_TEXTFIELD:
     aGtkWidgetType = MOZ_GTK_SPINBUTTON_ENTRY;
     break;
   case NS_THEME_RANGE:
     {
       if (IsRangeHorizontal(aFrame)) {
@@ -479,35 +479,35 @@ nsNativeThemeGTK::GetGtkWidgetAndState(u
       }
       break;
     }
   case NS_THEME_SCALE_HORIZONTAL:
     if (aWidgetFlags)
       *aWidgetFlags = GTK_ORIENTATION_HORIZONTAL;
     aGtkWidgetType = MOZ_GTK_SCALE_HORIZONTAL;
     break;
-  case NS_THEME_SCALE_THUMB_HORIZONTAL:
+  case NS_THEME_SCALETHUMB_HORIZONTAL:
     if (aWidgetFlags)
       *aWidgetFlags = GTK_ORIENTATION_HORIZONTAL;
     aGtkWidgetType = MOZ_GTK_SCALE_THUMB_HORIZONTAL;
     break;
   case NS_THEME_SCALE_VERTICAL:
     if (aWidgetFlags)
       *aWidgetFlags = GTK_ORIENTATION_VERTICAL;
     aGtkWidgetType = MOZ_GTK_SCALE_VERTICAL;
     break;
-  case NS_THEME_TOOLBAR_SEPARATOR:
+  case NS_THEME_SEPARATOR:
     aGtkWidgetType = MOZ_GTK_TOOLBAR_SEPARATOR;
     break;
-  case NS_THEME_SCALE_THUMB_VERTICAL:
+  case NS_THEME_SCALETHUMB_VERTICAL:
     if (aWidgetFlags)
       *aWidgetFlags = GTK_ORIENTATION_VERTICAL;
     aGtkWidgetType = MOZ_GTK_SCALE_THUMB_VERTICAL;
     break;
-  case NS_THEME_TOOLBAR_GRIPPER:
+  case NS_THEME_TOOLBARGRIPPER:
     aGtkWidgetType = MOZ_GTK_GRIPPER;
     break;
   case NS_THEME_RESIZER:
     aGtkWidgetType = MOZ_GTK_RESIZER;
     break;
   case NS_THEME_NUMBER_INPUT:
   case NS_THEME_TEXTFIELD:
     aGtkWidgetType = MOZ_GTK_ENTRY;
@@ -518,27 +518,27 @@ nsNativeThemeGTK::GetGtkWidgetAndState(u
 #else
     aGtkWidgetType = MOZ_GTK_ENTRY;
 #endif
     break;
   case NS_THEME_LISTBOX:
   case NS_THEME_TREEVIEW:
     aGtkWidgetType = MOZ_GTK_TREEVIEW;
     break;
-  case NS_THEME_TREEVIEW_HEADER_CELL:
+  case NS_THEME_TREEHEADERCELL:
     if (aWidgetFlags) {
       // In this case, the flag denotes whether the header is the sorted one or not
       if (GetTreeSortDirection(aFrame) == eTreeSortDirection_Natural)
         *aWidgetFlags = false;
       else
         *aWidgetFlags = true;
     }
     aGtkWidgetType = MOZ_GTK_TREE_HEADER_CELL;
     break;
-  case NS_THEME_TREEVIEW_HEADER_SORTARROW:
+  case NS_THEME_TREEHEADERSORTARROW:
     if (aWidgetFlags) {
       switch (GetTreeSortDirection(aFrame)) {
         case eTreeSortDirection_Ascending:
           *aWidgetFlags = GTK_ARROW_DOWN;
           break;
         case eTreeSortDirection_Descending:
           *aWidgetFlags = GTK_ARROW_UP;
           break;
@@ -548,40 +548,40 @@ nsNativeThemeGTK::GetGtkWidgetAndState(u
            * and wider when switching sort direction off and on
            * */
           *aWidgetFlags = GTK_ARROW_NONE;
           break;
       }
     }
     aGtkWidgetType = MOZ_GTK_TREE_HEADER_SORTARROW;
     break;
-  case NS_THEME_TREEVIEW_TWISTY:
+  case NS_THEME_TREETWISTY:
     aGtkWidgetType = MOZ_GTK_TREEVIEW_EXPANDER;
     if (aWidgetFlags)
       *aWidgetFlags = GTK_EXPANDER_COLLAPSED;
     break;
-  case NS_THEME_TREEVIEW_TWISTY_OPEN:
+  case NS_THEME_TREETWISTYOPEN:
     aGtkWidgetType = MOZ_GTK_TREEVIEW_EXPANDER;
     if (aWidgetFlags)
       *aWidgetFlags = GTK_EXPANDER_EXPANDED;
     break;
-  case NS_THEME_DROPDOWN:
+  case NS_THEME_MENULIST:
     aGtkWidgetType = MOZ_GTK_DROPDOWN;
     if (aWidgetFlags)
         *aWidgetFlags = IsFrameContentNodeInNamespace(aFrame, kNameSpaceID_XHTML);
     break;
-  case NS_THEME_DROPDOWN_TEXT:
+  case NS_THEME_MENULIST_TEXT:
     return false; // nothing to do, but prevents the bg from being drawn
-  case NS_THEME_DROPDOWN_TEXTFIELD:
+  case NS_THEME_MENULIST_TEXTFIELD:
     aGtkWidgetType = MOZ_GTK_DROPDOWN_ENTRY;
     break;
-  case NS_THEME_DROPDOWN_BUTTON:
+  case NS_THEME_MENULIST_BUTTON:
     aGtkWidgetType = MOZ_GTK_DROPDOWN_ARROW;
     break;
-  case NS_THEME_TOOLBAR_BUTTON_DROPDOWN:
+  case NS_THEME_TOOLBARBUTTON_DROPDOWN:
   case NS_THEME_BUTTON_ARROW_DOWN:
   case NS_THEME_BUTTON_ARROW_UP:
   case NS_THEME_BUTTON_ARROW_NEXT:
   case NS_THEME_BUTTON_ARROW_PREVIOUS:
     aGtkWidgetType = MOZ_GTK_TOOLBARBUTTON_ARROW;
     if (aWidgetFlags) {
       *aWidgetFlags = GTK_ARROW_DOWN;
 
@@ -606,45 +606,45 @@ nsNativeThemeGTK::GetGtkWidgetAndState(u
     aGtkWidgetType = MOZ_GTK_RADIOBUTTON_LABEL;
     break;
   case NS_THEME_TOOLBAR:
     aGtkWidgetType = MOZ_GTK_TOOLBAR;
     break;
   case NS_THEME_TOOLTIP:
     aGtkWidgetType = MOZ_GTK_TOOLTIP;
     break;
-  case NS_THEME_STATUSBAR_PANEL:
-  case NS_THEME_STATUSBAR_RESIZER_PANEL:
+  case NS_THEME_STATUSBARPANEL:
+  case NS_THEME_RESIZER_PANEL:
     aGtkWidgetType = MOZ_GTK_FRAME;
     break;
   case NS_THEME_PROGRESSBAR:
   case NS_THEME_PROGRESSBAR_VERTICAL:
     aGtkWidgetType = MOZ_GTK_PROGRESSBAR;
     break;
-  case NS_THEME_PROGRESSBAR_CHUNK:
-  case NS_THEME_PROGRESSBAR_CHUNK_VERTICAL:
+  case NS_THEME_PROGRESSCHUNK:
+  case NS_THEME_PROGRESSCHUNK_VERTICAL:
     {
       nsIFrame* stateFrame = aFrame->GetParent();
       EventStates eventStates = GetContentState(stateFrame, aWidgetType);
 
       aGtkWidgetType = IsIndeterminateProgress(stateFrame, eventStates)
                          ? IsVerticalProgress(stateFrame)
                            ? MOZ_GTK_PROGRESS_CHUNK_VERTICAL_INDETERMINATE
                            : MOZ_GTK_PROGRESS_CHUNK_INDETERMINATE
                          : MOZ_GTK_PROGRESS_CHUNK;
     }
     break;
-  case NS_THEME_TAB_SCROLLARROW_BACK:
-  case NS_THEME_TAB_SCROLLARROW_FORWARD:
+  case NS_THEME_TAB_SCROLL_ARROW_BACK:
+  case NS_THEME_TAB_SCROLL_ARROW_FORWARD:
     if (aWidgetFlags)
-      *aWidgetFlags = aWidgetType == NS_THEME_TAB_SCROLLARROW_BACK ?
+      *aWidgetFlags = aWidgetType == NS_THEME_TAB_SCROLL_ARROW_BACK ?
                         GTK_ARROW_LEFT : GTK_ARROW_RIGHT;
     aGtkWidgetType = MOZ_GTK_TAB_SCROLLARROW;
     break;
-  case NS_THEME_TAB_PANELS:
+  case NS_THEME_TABPANELS:
     aGtkWidgetType = MOZ_GTK_TABPANELS;
     break;
   case NS_THEME_TAB:
     {
       if (aWidgetFlags) {
         /* First bits will be used to store max(0,-bmargin) where bmargin
          * is the bottom margin of the tab in pixels  (resp. top margin,
          * for bottom tabs). */
@@ -998,20 +998,20 @@ bool
 nsNativeThemeGTK::GetExtraSizeForWidget(nsIFrame* aFrame, uint8_t aWidgetType,
                                         nsIntMargin* aExtra)
 {
   *aExtra = nsIntMargin(0,0,0,0);
   // Allow an extra one pixel above and below the thumb for certain
   // GTK2 themes (Ximian Industrial, Bluecurve, Misty, at least);
   // We modify the frame's overflow area.  See bug 297508.
   switch (aWidgetType) {
-  case NS_THEME_SCROLLBAR_THUMB_VERTICAL:
+  case NS_THEME_SCROLLBARTHUMB_VERTICAL:
     aExtra->top = aExtra->bottom = 1;
     break;
-  case NS_THEME_SCROLLBAR_THUMB_HORIZONTAL:
+  case NS_THEME_SCROLLBARTHUMB_HORIZONTAL:
     aExtra->left = aExtra->right = 1;
     break;
 
   // Include the indicator spacing (the padding around the control).
   case NS_THEME_CHECKBOX:
   case NS_THEME_RADIO:
     {
       gint indicator_size, indicator_spacing;
@@ -1229,39 +1229,39 @@ nsNativeThemeGTK::DrawWidgetBackground(n
 NS_IMETHODIMP
 nsNativeThemeGTK::GetWidgetBorder(nsDeviceContext* aContext, nsIFrame* aFrame,
                                   uint8_t aWidgetType, nsIntMargin* aResult)
 {
   GtkTextDirection direction = GetTextDirection(aFrame);
   aResult->top = aResult->left = aResult->right = aResult->bottom = 0;
   switch (aWidgetType) {
   case NS_THEME_SCROLLBAR_VERTICAL:
-  case NS_THEME_SCROLLBAR_TRACK_HORIZONTAL:
+  case NS_THEME_SCROLLBARTRACK_HORIZONTAL:
     {
       MozGtkScrollbarMetrics metrics;
       moz_gtk_get_scrollbar_metrics(&metrics);
       /* Top and bottom border for whole vertical scrollbar, top and bottom
        * border for horizontal track - to correctly position thumb element */
       aResult->top = aResult->bottom = metrics.trough_border;
     }
     break;
   case NS_THEME_SCROLLBAR_HORIZONTAL:
-  case NS_THEME_SCROLLBAR_TRACK_VERTICAL:
+  case NS_THEME_SCROLLBARTRACK_VERTICAL:
     {
       MozGtkScrollbarMetrics metrics;
       moz_gtk_get_scrollbar_metrics(&metrics);
       aResult->left = aResult->right = metrics.trough_border;
     }
     break;
   case NS_THEME_TOOLBOX:
     // gtk has no toolbox equivalent.  So, although we map toolbox to
     // gtk's 'toolbar' for purposes of painting the widget background,
     // we don't use the toolbar border for toolbox.
     break;
-  case NS_THEME_TOOLBAR_DUAL_BUTTON:
+  case NS_THEME_DUALBUTTON:
     // TOOLBAR_DUAL_BUTTON is an interesting case.  We want a border to draw
     // around the entire button + dropdown, and also an inner border if you're
     // over the button part.  But, we want the inner button to be right up
     // against the edge of the outer button so that the borders overlap.
     // To make this happen, we draw a button border for the outer button,
     // but don't reserve any space for it.
     break;
   case NS_THEME_TAB:
@@ -1309,22 +1309,22 @@ nsNativeThemeGTK::GetWidgetBorder(nsDevi
 
 bool
 nsNativeThemeGTK::GetWidgetPadding(nsDeviceContext* aContext,
                                    nsIFrame* aFrame, uint8_t aWidgetType,
                                    nsIntMargin* aResult)
 {
   switch (aWidgetType) {
     case NS_THEME_BUTTON_FOCUS:
-    case NS_THEME_TOOLBAR_BUTTON:
-    case NS_THEME_TOOLBAR_DUAL_BUTTON:
-    case NS_THEME_TAB_SCROLLARROW_BACK:
-    case NS_THEME_TAB_SCROLLARROW_FORWARD:
-    case NS_THEME_DROPDOWN_BUTTON:
-    case NS_THEME_TOOLBAR_BUTTON_DROPDOWN:
+    case NS_THEME_TOOLBARBUTTON:
+    case NS_THEME_DUALBUTTON:
+    case NS_THEME_TAB_SCROLL_ARROW_BACK:
+    case NS_THEME_TAB_SCROLL_ARROW_FORWARD:
+    case NS_THEME_MENULIST_BUTTON:
+    case NS_THEME_TOOLBARBUTTON_DROPDOWN:
     case NS_THEME_BUTTON_ARROW_UP:
     case NS_THEME_BUTTON_ARROW_DOWN:
     case NS_THEME_BUTTON_ARROW_NEXT:
     case NS_THEME_BUTTON_ARROW_PREVIOUS:
     case NS_THEME_RANGE_THUMB:
     // Radios and checkboxes return a fixed size in GetMinimumWidgetSize
     // and have a meaningful baseline, so they can't have
     // author-specified padding.
@@ -1396,29 +1396,29 @@ nsNativeThemeGTK::GetMinimumWidgetSize(n
                                        nsIFrame* aFrame, uint8_t aWidgetType,
                                        LayoutDeviceIntSize* aResult,
                                        bool* aIsOverridable)
 {
   aResult->width = aResult->height = 0;
   *aIsOverridable = true;
 
   switch (aWidgetType) {
-    case NS_THEME_SCROLLBAR_BUTTON_UP:
-    case NS_THEME_SCROLLBAR_BUTTON_DOWN:
+    case NS_THEME_SCROLLBARBUTTON_UP:
+    case NS_THEME_SCROLLBARBUTTON_DOWN:
       {
         MozGtkScrollbarMetrics metrics;
         moz_gtk_get_scrollbar_metrics(&metrics);
 
         aResult->width = metrics.slider_width;
         aResult->height = metrics.stepper_size;
         *aIsOverridable = false;
       }
       break;
-    case NS_THEME_SCROLLBAR_BUTTON_LEFT:
-    case NS_THEME_SCROLLBAR_BUTTON_RIGHT:
+    case NS_THEME_SCROLLBARBUTTON_LEFT:
+    case NS_THEME_SCROLLBARBUTTON_RIGHT:
       {
         MozGtkScrollbarMetrics metrics;
         moz_gtk_get_scrollbar_metrics(&metrics);
 
         aResult->width = metrics.stepper_size;
         aResult->height = metrics.slider_width;
         *aIsOverridable = false;
       }
@@ -1460,23 +1460,23 @@ nsNativeThemeGTK::GetMinimumWidgetSize(n
         aResult->height = metrics.slider_width + 2 * metrics.trough_border;
         if (!hasScrollbarButtons)
           aResult->width = metrics.min_slider_size + 2 * metrics.trough_border;
       }
 
       *aIsOverridable = false;
     }
     break;
-    case NS_THEME_SCROLLBAR_THUMB_VERTICAL:
-    case NS_THEME_SCROLLBAR_THUMB_HORIZONTAL:
+    case NS_THEME_SCROLLBARTHUMB_VERTICAL:
+    case NS_THEME_SCROLLBARTHUMB_HORIZONTAL:
       {
         MozGtkScrollbarMetrics metrics;
         moz_gtk_get_scrollbar_metrics(&metrics);
 
-        if (aWidgetType == NS_THEME_SCROLLBAR_THUMB_VERTICAL) {
+        if (aWidgetType == NS_THEME_SCROLLBARTHUMB_VERTICAL) {
           aResult->width = metrics.slider_width;
           aResult->height = metrics.min_slider_size;
         } else {
           aResult->height = metrics.slider_width;
           aResult->width = metrics.min_slider_size;
         }
 
         *aIsOverridable = false;
@@ -1505,42 +1505,42 @@ nsNativeThemeGTK::GetMinimumWidgetSize(n
             GTK_ORIENTATION_HORIZONTAL : GTK_ORIENTATION_VERTICAL,
             &scale_width, &scale_height);
         aResult->width = scale_width;
         aResult->height = scale_height;
 
         *aIsOverridable = true;
       }
       break;
-    case NS_THEME_SCALE_THUMB_HORIZONTAL:
-    case NS_THEME_SCALE_THUMB_VERTICAL:
+    case NS_THEME_SCALETHUMB_HORIZONTAL:
+    case NS_THEME_SCALETHUMB_VERTICAL:
       {
         gint thumb_length, thumb_height;
 
-        if (aWidgetType == NS_THEME_SCALE_THUMB_VERTICAL) {
+        if (aWidgetType == NS_THEME_SCALETHUMB_VERTICAL) {
           moz_gtk_get_scalethumb_metrics(GTK_ORIENTATION_VERTICAL, &thumb_length, &thumb_height);
           aResult->width = thumb_height;
           aResult->height = thumb_length;
         } else {
           moz_gtk_get_scalethumb_metrics(GTK_ORIENTATION_HORIZONTAL, &thumb_length, &thumb_height);
           aResult->width = thumb_length;
           aResult->height = thumb_height;
         }
 
         *aIsOverridable = false;
       }
       break;
-    case NS_THEME_TAB_SCROLLARROW_BACK:
-    case NS_THEME_TAB_SCROLLARROW_FORWARD:
+    case NS_THEME_TAB_SCROLL_ARROW_BACK:
+    case NS_THEME_TAB_SCROLL_ARROW_FORWARD:
       {
         moz_gtk_get_tab_scroll_arrow_size(&aResult->width, &aResult->height);
         *aIsOverridable = false;
       }
       break;
-  case NS_THEME_DROPDOWN_BUTTON:
+  case NS_THEME_MENULIST_BUTTON:
     {
       moz_gtk_get_combo_box_entry_button_size(&aResult->width,
                                               &aResult->height);
       *aIsOverridable = false;
     }
     break;
   case NS_THEME_MENUSEPARATOR:
     {
@@ -1563,37 +1563,37 @@ nsNativeThemeGTK::GetMinimumWidgetSize(n
         moz_gtk_radio_get_metrics(&indicator_size, &indicator_spacing);
       }
 
       // Include space for the indicator and the padding around it.
       aResult->width = indicator_size;
       aResult->height = indicator_size;
     }
     break;
-  case NS_THEME_TOOLBAR_BUTTON_DROPDOWN:
+  case NS_THEME_TOOLBARBUTTON_DROPDOWN:
   case NS_THEME_BUTTON_ARROW_UP:
   case NS_THEME_BUTTON_ARROW_DOWN:
   case NS_THEME_BUTTON_ARROW_NEXT:
   case NS_THEME_BUTTON_ARROW_PREVIOUS:
     {
       moz_gtk_get_arrow_size(MOZ_GTK_TOOLBARBUTTON_ARROW,
                              &aResult->width, &aResult->height);
       *aIsOverridable = false;
     }
     break;
   case NS_THEME_CHECKBOX_CONTAINER:
   case NS_THEME_RADIO_CONTAINER:
   case NS_THEME_CHECKBOX_LABEL:
   case NS_THEME_RADIO_LABEL:
   case NS_THEME_BUTTON:
-  case NS_THEME_DROPDOWN:
-  case NS_THEME_TOOLBAR_BUTTON:
-  case NS_THEME_TREEVIEW_HEADER_CELL:
+  case NS_THEME_MENULIST:
+  case NS_THEME_TOOLBARBUTTON:
+  case NS_THEME_TREEHEADERCELL:
     {
-      if (aWidgetType == NS_THEME_DROPDOWN) {
+      if (aWidgetType == NS_THEME_MENULIST) {
         // Include the arrow size.
         moz_gtk_get_arrow_size(MOZ_GTK_DROPDOWN,
                                &aResult->width, &aResult->height);
       }
       // else the minimum size is missing consideration of container
       // descendants; the value returned here will not be helpful, but the
       // box model may consider border and padding with child minimum sizes.
 
@@ -1607,44 +1607,44 @@ nsNativeThemeGTK::GetMinimumWidgetSize(n
 #if (MOZ_WIDGET_GTK == 3)
   case NS_THEME_NUMBER_INPUT:
   case NS_THEME_TEXTFIELD:
     {
       moz_gtk_get_entry_min_height(&aResult->height);
     }
     break;
 #endif
-  case NS_THEME_TOOLBAR_SEPARATOR:
+  case NS_THEME_SEPARATOR:
     {
       gint separator_width;
     
       moz_gtk_get_toolbar_separator_width(&separator_width);
     
       aResult->width = separator_width;
     }
     break;
   case NS_THEME_SPINNER:
     // hard code these sizes
     aResult->width = 14;
     aResult->height = 26;
     break;
-  case NS_THEME_TREEVIEW_HEADER_SORTARROW:
-  case NS_THEME_SPINNER_UP_BUTTON:
-  case NS_THEME_SPINNER_DOWN_BUTTON:
+  case NS_THEME_TREEHEADERSORTARROW:
+  case NS_THEME_SPINNER_UPBUTTON:
+  case NS_THEME_SPINNER_DOWNBUTTON:
     // hard code these sizes
     aResult->width = 14;
     aResult->height = 13;
     break;
   case NS_THEME_RESIZER:
     // same as Windows to make our lives easier
     aResult->width = aResult->height = 15;
     *aIsOverridable = false;
     break;
-  case NS_THEME_TREEVIEW_TWISTY:
-  case NS_THEME_TREEVIEW_TWISTY_OPEN:
+  case NS_THEME_TREETWISTY:
+  case NS_THEME_TREETWISTYOPEN:
     {
       gint expander_size;
 
       moz_gtk_get_treeview_expander_size(&expander_size);
       aResult->width = aResult->height = expander_size;
       *aIsOverridable = false;
     }
     break;
@@ -1659,43 +1659,43 @@ NS_IMETHODIMP
 nsNativeThemeGTK::WidgetStateChanged(nsIFrame* aFrame, uint8_t aWidgetType, 
                                      nsIAtom* aAttribute, bool* aShouldRepaint,
                                      const nsAttrValue* aOldValue)
 {
   // Some widget types just never change state.
   if (aWidgetType == NS_THEME_TOOLBOX ||
       aWidgetType == NS_THEME_TOOLBAR ||
       aWidgetType == NS_THEME_STATUSBAR ||
-      aWidgetType == NS_THEME_STATUSBAR_PANEL ||
-      aWidgetType == NS_THEME_STATUSBAR_RESIZER_PANEL ||
-      aWidgetType == NS_THEME_PROGRESSBAR_CHUNK ||
-      aWidgetType == NS_THEME_PROGRESSBAR_CHUNK_VERTICAL ||
+      aWidgetType == NS_THEME_STATUSBARPANEL ||
+      aWidgetType == NS_THEME_RESIZER_PANEL ||
+      aWidgetType == NS_THEME_PROGRESSCHUNK ||
+      aWidgetType == NS_THEME_PROGRESSCHUNK_VERTICAL ||
       aWidgetType == NS_THEME_PROGRESSBAR ||
       aWidgetType == NS_THEME_PROGRESSBAR_VERTICAL ||
       aWidgetType == NS_THEME_MENUBAR ||
       aWidgetType == NS_THEME_MENUPOPUP ||
       aWidgetType == NS_THEME_TOOLTIP ||
       aWidgetType == NS_THEME_MENUSEPARATOR ||
       aWidgetType == NS_THEME_WINDOW ||
       aWidgetType == NS_THEME_DIALOG) {
     *aShouldRepaint = false;
     return NS_OK;
   }
 
-  if ((aWidgetType == NS_THEME_SCROLLBAR_THUMB_VERTICAL ||
-       aWidgetType == NS_THEME_SCROLLBAR_THUMB_HORIZONTAL) &&
+  if ((aWidgetType == NS_THEME_SCROLLBARTHUMB_VERTICAL ||
+       aWidgetType == NS_THEME_SCROLLBARTHUMB_HORIZONTAL) &&
        aAttribute == nsGkAtoms::active) {
     *aShouldRepaint = true;
     return NS_OK;
   }
 
-  if ((aWidgetType == NS_THEME_SCROLLBAR_BUTTON_UP ||
-       aWidgetType == NS_THEME_SCROLLBAR_BUTTON_DOWN ||
-       aWidgetType == NS_THEME_SCROLLBAR_BUTTON_LEFT ||
-       aWidgetType == NS_THEME_SCROLLBAR_BUTTON_RIGHT) &&
+  if ((aWidgetType == NS_THEME_SCROLLBARBUTTON_UP ||
+       aWidgetType == NS_THEME_SCROLLBARBUTTON_DOWN ||
+       aWidgetType == NS_THEME_SCROLLBARBUTTON_LEFT ||
+       aWidgetType == NS_THEME_SCROLLBARBUTTON_RIGHT) &&
       (aAttribute == nsGkAtoms::curpos ||
        aAttribute == nsGkAtoms::maxpos)) {
     // If 'curpos' has changed and we are passed its old value, we can
     // determine whether the button's enablement actually needs to change.
     if (aAttribute == nsGkAtoms::curpos && aOldValue) {
       int32_t curpos = CheckIntAttr(aFrame, nsGkAtoms::curpos, 0);
       int32_t maxpos = CheckIntAttr(aFrame, nsGkAtoms::maxpos, 0);
       nsAutoString str;
@@ -1754,91 +1754,91 @@ nsNativeThemeGTK::ThemeSupportsWidget(ns
                                       nsIFrame* aFrame,
                                       uint8_t aWidgetType)
 {
   if (IsWidgetTypeDisabled(mDisabledWidgetTypes, aWidgetType))
     return false;
 
   switch (aWidgetType) {
   // Combobox dropdowns don't support native theming in vertical mode.
-  case NS_THEME_DROPDOWN:
-  case NS_THEME_DROPDOWN_TEXT:
-  case NS_THEME_DROPDOWN_TEXTFIELD:
+  case NS_THEME_MENULIST:
+  case NS_THEME_MENULIST_TEXT:
+  case NS_THEME_MENULIST_TEXTFIELD:
     if (aFrame && aFrame->GetWritingMode().IsVertical()) {
       return false;
     }
     MOZ_FALLTHROUGH;
 
   case NS_THEME_BUTTON:
   case NS_THEME_BUTTON_FOCUS:
   case NS_THEME_RADIO:
   case NS_THEME_CHECKBOX:
   case NS_THEME_TOOLBOX: // N/A
   case NS_THEME_TOOLBAR:
-  case NS_THEME_TOOLBAR_BUTTON:
-  case NS_THEME_TOOLBAR_DUAL_BUTTON: // so we can override the border with 0
-  case NS_THEME_TOOLBAR_BUTTON_DROPDOWN:
+  case NS_THEME_TOOLBARBUTTON:
+  case NS_THEME_DUALBUTTON: // so we can override the border with 0
+  case NS_THEME_TOOLBARBUTTON_DROPDOWN:
   case NS_THEME_BUTTON_ARROW_UP:
   case NS_THEME_BUTTON_ARROW_DOWN:
   case NS_THEME_BUTTON_ARROW_NEXT:
   case NS_THEME_BUTTON_ARROW_PREVIOUS:
-  case NS_THEME_TOOLBAR_SEPARATOR:
-  case NS_THEME_TOOLBAR_GRIPPER:
+  case NS_THEME_SEPARATOR:
+  case NS_THEME_TOOLBARGRIPPER:
   case NS_THEME_STATUSBAR:
-  case NS_THEME_STATUSBAR_PANEL:
-  case NS_THEME_STATUSBAR_RESIZER_PANEL:
+  case NS_THEME_STATUSBARPANEL:
+  case NS_THEME_RESIZER_PANEL:
   case NS_THEME_RESIZER:
   case NS_THEME_LISTBOX:
-    // case NS_THEME_LISTBOX_LISTITEM:
+    // case NS_THEME_LISTITEM:
   case NS_THEME_TREEVIEW:
-    // case NS_THEME_TREEVIEW_TREEITEM:
-  case NS_THEME_TREEVIEW_TWISTY:
-    // case NS_THEME_TREEVIEW_LINE:
-    // case NS_THEME_TREEVIEW_HEADER:
-  case NS_THEME_TREEVIEW_HEADER_CELL:
-  case NS_THEME_TREEVIEW_HEADER_SORTARROW:
-  case NS_THEME_TREEVIEW_TWISTY_OPEN:
+    // case NS_THEME_TREEITEM:
+  case NS_THEME_TREETWISTY:
+    // case NS_THEME_TREELINE:
+    // case NS_THEME_TREEHEADER:
+  case NS_THEME_TREEHEADERCELL:
+  case NS_THEME_TREEHEADERSORTARROW:
+  case NS_THEME_TREETWISTYOPEN:
     case NS_THEME_PROGRESSBAR:
-    case NS_THEME_PROGRESSBAR_CHUNK:
+    case NS_THEME_PROGRESSCHUNK:
     case NS_THEME_PROGRESSBAR_VERTICAL:
-    case NS_THEME_PROGRESSBAR_CHUNK_VERTICAL:
+    case NS_THEME_PROGRESSCHUNK_VERTICAL:
     case NS_THEME_TAB:
-    // case NS_THEME_TAB_PANEL:
-    case NS_THEME_TAB_PANELS:
-    case NS_THEME_TAB_SCROLLARROW_BACK:
-    case NS_THEME_TAB_SCROLLARROW_FORWARD:
+    // case NS_THEME_TABPANEL:
+    case NS_THEME_TABPANELS:
+    case NS_THEME_TAB_SCROLL_ARROW_BACK:
+    case NS_THEME_TAB_SCROLL_ARROW_FORWARD:
   case NS_THEME_TOOLTIP:
   case NS_THEME_SPINNER:
-  case NS_THEME_SPINNER_UP_BUTTON:
-  case NS_THEME_SPINNER_DOWN_BUTTON:
+  case NS_THEME_SPINNER_UPBUTTON:
+  case NS_THEME_SPINNER_DOWNBUTTON:
   case NS_THEME_SPINNER_TEXTFIELD:
     // case NS_THEME_SCROLLBAR:  (n/a for gtk)
     // case NS_THEME_SCROLLBAR_SMALL: (n/a for gtk)
-  case NS_THEME_SCROLLBAR_BUTTON_UP:
-  case NS_THEME_SCROLLBAR_BUTTON_DOWN:
-  case NS_THEME_SCROLLBAR_BUTTON_LEFT:
-  case NS_THEME_SCROLLBAR_BUTTON_RIGHT:
+  case NS_THEME_SCROLLBARBUTTON_UP:
+  case NS_THEME_SCROLLBARBUTTON_DOWN:
+  case NS_THEME_SCROLLBARBUTTON_LEFT:
+  case NS_THEME_SCROLLBARBUTTON_RIGHT:
   case NS_THEME_SCROLLBAR_HORIZONTAL:
   case NS_THEME_SCROLLBAR_VERTICAL:
-  case NS_THEME_SCROLLBAR_TRACK_HORIZONTAL:
-  case NS_THEME_SCROLLBAR_TRACK_VERTICAL:
-  case NS_THEME_SCROLLBAR_THUMB_HORIZONTAL:
-  case NS_THEME_SCROLLBAR_THUMB_VERTICAL:
+  case NS_THEME_SCROLLBARTRACK_HORIZONTAL:
+  case NS_THEME_SCROLLBARTRACK_VERTICAL:
+  case NS_THEME_SCROLLBARTHUMB_HORIZONTAL:
+  case NS_THEME_SCROLLBARTHUMB_VERTICAL:
   case NS_THEME_NUMBER_INPUT:
   case NS_THEME_TEXTFIELD:
   case NS_THEME_TEXTFIELD_MULTILINE:
   case NS_THEME_RANGE:
   case NS_THEME_RANGE_THUMB:
   case NS_THEME_SCALE_HORIZONTAL:
-  case NS_THEME_SCALE_THUMB_HORIZONTAL:
+  case NS_THEME_SCALETHUMB_HORIZONTAL:
   case NS_THEME_SCALE_VERTICAL:
-  case NS_THEME_SCALE_THUMB_VERTICAL:
-    // case NS_THEME_SCALE_THUMB_START:
-    // case NS_THEME_SCALE_THUMB_END:
-    // case NS_THEME_SCALE_TICK:
+  case NS_THEME_SCALETHUMB_VERTICAL:
+    // case NS_THEME_SCALETHUMBSTART:
+    // case NS_THEME_SCALETHUMBEND:
+    // case NS_THEME_SCALETHUMBTICK:
   case NS_THEME_CHECKBOX_CONTAINER:
   case NS_THEME_RADIO_CONTAINER:
   case NS_THEME_CHECKBOX_LABEL:
   case NS_THEME_RADIO_LABEL:
   case NS_THEME_MENUBAR:
   case NS_THEME_MENUPOPUP:
   case NS_THEME_MENUITEM:
   case NS_THEME_MENUARROW:
@@ -1848,17 +1848,17 @@ nsNativeThemeGTK::ThemeSupportsWidget(ns
   case NS_THEME_SPLITTER:
   case NS_THEME_WINDOW:
   case NS_THEME_DIALOG:
 #if (MOZ_WIDGET_GTK == 3)
   case NS_THEME_GTK_INFO_BAR:
 #endif
     return !IsWidgetStyled(aPresContext, aFrame, aWidgetType);
 
-  case NS_THEME_DROPDOWN_BUTTON:
+  case NS_THEME_MENULIST_BUTTON:
     if (aFrame && aFrame->GetWritingMode().IsVertical()) {
       return false;
     }
     // "Native" dropdown buttons cause padding and margin problems, but only
     // in HTML so allow them in XUL.
     return (!aFrame || IsFrameContentNodeInNamespace(aFrame, kNameSpaceID_XUL)) &&
            !IsWidgetStyled(aPresContext, aFrame, aWidgetType);
 
@@ -1868,36 +1868,36 @@ nsNativeThemeGTK::ThemeSupportsWidget(ns
 
   return false;
 }
 
 NS_IMETHODIMP_(bool)
 nsNativeThemeGTK::WidgetIsContainer(uint8_t aWidgetType)
 {
   // XXXdwh At some point flesh all of this out.
-  if (aWidgetType == NS_THEME_DROPDOWN_BUTTON ||
+  if (aWidgetType == NS_THEME_MENULIST_BUTTON ||
       aWidgetType == NS_THEME_RADIO ||
       aWidgetType == NS_THEME_RANGE_THUMB ||
       aWidgetType == NS_THEME_CHECKBOX ||
-      aWidgetType == NS_THEME_TAB_SCROLLARROW_BACK ||
-      aWidgetType == NS_THEME_TAB_SCROLLARROW_FORWARD ||
+      aWidgetType == NS_THEME_TAB_SCROLL_ARROW_BACK ||
+      aWidgetType == NS_THEME_TAB_SCROLL_ARROW_FORWARD ||
       aWidgetType == NS_THEME_BUTTON_ARROW_UP ||
       aWidgetType == NS_THEME_BUTTON_ARROW_DOWN ||
       aWidgetType == NS_THEME_BUTTON_ARROW_NEXT ||
       aWidgetType == NS_THEME_BUTTON_ARROW_PREVIOUS)
     return false;
   return true;
 }
 
 bool
 nsNativeThemeGTK::ThemeDrawsFocusForWidget(uint8_t aWidgetType)
 {
-   if (aWidgetType == NS_THEME_DROPDOWN ||
+   if (aWidgetType == NS_THEME_MENULIST ||
       aWidgetType == NS_THEME_BUTTON || 
-      aWidgetType == NS_THEME_TREEVIEW_HEADER_CELL)
+      aWidgetType == NS_THEME_TREEHEADERCELL)
     return true;
   
   return false;
 }
 
 bool
 nsNativeThemeGTK::ThemeNeedsComboboxDropmarker()
 {
--- a/widget/nsNativeTheme.cpp
+++ b/widget/nsNativeTheme.cpp
@@ -226,17 +226,17 @@ nsNativeTheme::IsButtonTypeMenu(nsIFrame
   nsIContent* content = aFrame->GetContent();
   return content->AttrValueIs(kNameSpaceID_None, nsGkAtoms::type,
                               NS_LITERAL_STRING("menu"), eCaseMatters);
 }
 
 bool
 nsNativeTheme::IsPressedButton(nsIFrame* aFrame)
 {
-  EventStates eventState = GetContentState(aFrame, NS_THEME_TOOLBAR_BUTTON);
+  EventStates eventState = GetContentState(aFrame, NS_THEME_TOOLBARBUTTON);
   if (IsDisabled(aFrame, eventState))
     return false;
 
   return IsOpenButton(aFrame) ||
          eventState.HasAllStates(NS_EVENT_STATE_ACTIVE | NS_EVENT_STATE_HOVER);
 }
 
 
@@ -290,32 +290,32 @@ nsNativeTheme::IsWidgetStyled(nsPresCont
       }
     }
   }
 
   /**
    * Progress bar appearance should be the same for the bar and the container
    * frame. nsProgressFrame owns the logic and will tell us what we should do.
    */
-  if (aWidgetType == NS_THEME_PROGRESSBAR_CHUNK ||
+  if (aWidgetType == NS_THEME_PROGRESSCHUNK ||
       aWidgetType == NS_THEME_PROGRESSBAR) {
-    nsProgressFrame* progressFrame = do_QueryFrame(aWidgetType == NS_THEME_PROGRESSBAR_CHUNK
+    nsProgressFrame* progressFrame = do_QueryFrame(aWidgetType == NS_THEME_PROGRESSCHUNK
                                        ? aFrame->GetParent() : aFrame);
     if (progressFrame) {
       return !progressFrame->ShouldUseNativeStyle();
     }
   }
 
   /**
    * Meter bar appearance should be the same for the bar and the container
    * frame. nsMeterFrame owns the logic and will tell us what we should do.
    */
-  if (aWidgetType == NS_THEME_METERBAR_CHUNK ||
+  if (aWidgetType == NS_THEME_METERCHUNK ||
       aWidgetType == NS_THEME_METERBAR) {
-    nsMeterFrame* meterFrame = do_QueryFrame(aWidgetType == NS_THEME_METERBAR_CHUNK
+    nsMeterFrame* meterFrame = do_QueryFrame(aWidgetType == NS_THEME_METERCHUNK
                                        ? aFrame->GetParent() : aFrame);
     if (meterFrame) {
       return !meterFrame->ShouldUseNativeStyle();
     }
   }
 
   /**
    * An nsRangeFrame and its children are treated atomically when it
@@ -327,31 +327,31 @@ nsNativeTheme::IsWidgetStyled(nsPresCont
     nsRangeFrame* rangeFrame =
       do_QueryFrame(aWidgetType == NS_THEME_RANGE_THUMB
                       ? aFrame->GetParent() : aFrame);
     if (rangeFrame) {
       return !rangeFrame->ShouldUseNativeStyle();
     }
   }
 
-  if (aWidgetType == NS_THEME_SPINNER_UP_BUTTON ||
-      aWidgetType == NS_THEME_SPINNER_DOWN_BUTTON) {
+  if (aWidgetType == NS_THEME_SPINNER_UPBUTTON ||
+      aWidgetType == NS_THEME_SPINNER_DOWNBUTTON) {
     nsNumberControlFrame* numberControlFrame =
       nsNumberControlFrame::GetNumberControlFrameForSpinButton(aFrame);
     if (numberControlFrame) {
       return !numberControlFrame->ShouldUseNativeStyleForSpinner();
     }
   }
 
   return (aWidgetType == NS_THEME_NUMBER_INPUT ||
           aWidgetType == NS_THEME_BUTTON ||
           aWidgetType == NS_THEME_TEXTFIELD ||
           aWidgetType == NS_THEME_TEXTFIELD_MULTILINE ||
           aWidgetType == NS_THEME_LISTBOX ||
-          aWidgetType == NS_THEME_DROPDOWN) &&
+          aWidgetType == NS_THEME_MENULIST) &&
          aFrame->GetContent()->IsHTMLElement() &&
          aPresContext->HasAuthorSpecifiedRules(aFrame,
                                                NS_AUTHOR_SPECIFIED_BORDER |
                                                NS_AUTHOR_SPECIFIED_BACKGROUND);
 }
 
 bool
 nsNativeTheme::IsDisabled(nsIFrame* aFrame, EventStates aEventStates)
--- a/widget/windows/nsNativeThemeWin.cpp
+++ b/widget/windows/nsNativeThemeWin.cpp
@@ -675,17 +675,17 @@ nsNativeThemeWin::DrawThemedProgressMete
   if (!parentFrame) {
     // We have no parent to work with, just bail.
     NS_WARNING("No parent frame for progress rendering. Can't paint.");
     return;
   }
 
   EventStates eventStates = GetContentState(parentFrame, aWidgetType);
   bool vertical = IsVerticalProgress(parentFrame) ||
-                  aWidgetType == NS_THEME_PROGRESSBAR_CHUNK_VERTICAL;
+                  aWidgetType == NS_THEME_PROGRESSCHUNK_VERTICAL;
   bool indeterminate = IsIndeterminateProgress(parentFrame, eventStates);
   bool animate = indeterminate;
 
   if (IsVistaOrLater()) {
     // Vista and up progress meter is fill style, rendered here. We render
     // the pulse overlay in the follow up section below.
     DrawThemeBackground(aTheme, aHdc, aPart, aState,
                         &adjWidgetRect, &adjClipRect);
@@ -723,17 +723,17 @@ nsNativeThemeWin::DrawThemedProgressMete
 HANDLE
 nsNativeThemeWin::GetTheme(uint8_t aWidgetType)
 { 
   if (!IsVistaOrLater()) {
     // On XP or earlier, render dropdowns as textfields;
     // doing it the right way works fine with the MS themes,
     // but breaks on a lot of custom themes (presumably because MS
     // apps do the textfield border business as well).
-    if (aWidgetType == NS_THEME_DROPDOWN)
+    if (aWidgetType == NS_THEME_MENULIST)
       aWidgetType = NS_THEME_TEXTFIELD;
   }
 
   switch (aWidgetType) {
     case NS_THEME_BUTTON:
     case NS_THEME_RADIO:
     case NS_THEME_CHECKBOX:
     case NS_THEME_GROUPBOX:
@@ -748,68 +748,68 @@ nsNativeThemeWin::GetTheme(uint8_t aWidg
       return !IsVistaOrLater() ?
         nullptr : nsUXThemeData::GetTheme(eUXTooltip);
     case NS_THEME_TOOLBOX:
       return nsUXThemeData::GetTheme(eUXRebar);
     case NS_THEME_WIN_MEDIA_TOOLBOX:
       return nsUXThemeData::GetTheme(eUXMediaRebar);
     case NS_THEME_WIN_COMMUNICATIONS_TOOLBOX:
       return nsUXThemeData::GetTheme(eUXCommunicationsRebar);
-    case NS_THEME_WIN_BROWSER_TAB_BAR_TOOLBOX:
+    case NS_THEME_WIN_BROWSERTABBAR_TOOLBOX:
       return nsUXThemeData::GetTheme(eUXBrowserTabBarRebar);
     case NS_THEME_TOOLBAR:
-    case NS_THEME_TOOLBAR_BUTTON:
-    case NS_THEME_TOOLBAR_SEPARATOR:
+    case NS_THEME_TOOLBARBUTTON:
+    case NS_THEME_SEPARATOR:
       return nsUXThemeData::GetTheme(eUXToolbar);
     case NS_THEME_PROGRESSBAR:
     case NS_THEME_PROGRESSBAR_VERTICAL:
-    case NS_THEME_PROGRESSBAR_CHUNK:
-    case NS_THEME_PROGRESSBAR_CHUNK_VERTICAL:
+    case NS_THEME_PROGRESSCHUNK:
+    case NS_THEME_PROGRESSCHUNK_VERTICAL:
       return nsUXThemeData::GetTheme(eUXProgress);
     case NS_THEME_TAB:
-    case NS_THEME_TAB_PANEL:
-    case NS_THEME_TAB_PANELS:
+    case NS_THEME_TABPANEL:
+    case NS_THEME_TABPANELS:
       return nsUXThemeData::GetTheme(eUXTab);
     case NS_THEME_SCROLLBAR:
     case NS_THEME_SCROLLBAR_SMALL:
     case NS_THEME_SCROLLBAR_VERTICAL:
     case NS_THEME_SCROLLBAR_HORIZONTAL:
-    case NS_THEME_SCROLLBAR_BUTTON_UP:
-    case NS_THEME_SCROLLBAR_BUTTON_DOWN:
-    case NS_THEME_SCROLLBAR_BUTTON_LEFT:
-    case NS_THEME_SCROLLBAR_BUTTON_RIGHT:
-    case NS_THEME_SCROLLBAR_THUMB_VERTICAL:
-    case NS_THEME_SCROLLBAR_THUMB_HORIZONTAL:
+    case NS_THEME_SCROLLBARBUTTON_UP:
+    case NS_THEME_SCROLLBARBUTTON_DOWN:
+    case NS_THEME_SCROLLBARBUTTON_LEFT:
+    case NS_THEME_SCROLLBARBUTTON_RIGHT:
+    case NS_THEME_SCROLLBARTHUMB_VERTICAL:
+    case NS_THEME_SCROLLBARTHUMB_HORIZONTAL:
       return nsUXThemeData::GetTheme(eUXScrollbar);
     case NS_THEME_RANGE:
     case NS_THEME_RANGE_THUMB:
     case NS_THEME_SCALE_HORIZONTAL:
     case NS_THEME_SCALE_VERTICAL:
-    case NS_THEME_SCALE_THUMB_HORIZONTAL:
-    case NS_THEME_SCALE_THUMB_VERTICAL:
+    case NS_THEME_SCALETHUMB_HORIZONTAL:
+    case NS_THEME_SCALETHUMB_VERTICAL:
       return nsUXThemeData::GetTheme(eUXTrackbar);
-    case NS_THEME_SPINNER_UP_BUTTON:
-    case NS_THEME_SPINNER_DOWN_BUTTON:
+    case NS_THEME_SPINNER_UPBUTTON:
+    case NS_THEME_SPINNER_DOWNBUTTON:
       return nsUXThemeData::GetTheme(eUXSpin);
     case NS_THEME_STATUSBAR:
-    case NS_THEME_STATUSBAR_PANEL:
-    case NS_THEME_STATUSBAR_RESIZER_PANEL:
+    case NS_THEME_STATUSBARPANEL:
+    case NS_THEME_RESIZER_PANEL:
     case NS_THEME_RESIZER:
       return nsUXThemeData::GetTheme(eUXStatus);
-    case NS_THEME_DROPDOWN:
-    case NS_THEME_DROPDOWN_BUTTON:
+    case NS_THEME_MENULIST:
+    case NS_THEME_MENULIST_BUTTON:
       return nsUXThemeData::GetTheme(eUXCombobox);
-    case NS_THEME_TREEVIEW_HEADER_CELL:
-    case NS_THEME_TREEVIEW_HEADER_SORTARROW:
+    case NS_THEME_TREEHEADERCELL:
+    case NS_THEME_TREEHEADERSORTARROW:
       return nsUXThemeData::GetTheme(eUXHeader);
     case NS_THEME_LISTBOX:
-    case NS_THEME_LISTBOX_LISTITEM:
+    case NS_THEME_LISTITEM:
     case NS_THEME_TREEVIEW:
-    case NS_THEME_TREEVIEW_TWISTY_OPEN:
-    case NS_THEME_TREEVIEW_TREEITEM:
+    case NS_THEME_TREETWISTYOPEN:
+    case NS_THEME_TREEITEM:
       return nsUXThemeData::GetTheme(eUXListview);
     case NS_THEME_MENUBAR:
     case NS_THEME_MENUPOPUP:
     case NS_THEME_MENUITEM:
     case NS_THEME_CHECKMENUITEM:
     case NS_THEME_RADIOMENUITEM:
     case NS_THEME_MENUCHECKBOX:
     case NS_THEME_MENURADIO:
@@ -870,17 +870,17 @@ nsNativeThemeWin::IsMenuActive(nsIFrame 
  * (but isThemeBackgroundPartiallyTransparent may not work).
  */
 nsresult 
 nsNativeThemeWin::GetThemePartAndState(nsIFrame* aFrame, uint8_t aWidgetType, 
                                        int32_t& aPart, int32_t& aState)
 {
   if (!IsVistaOrLater()) {
     // See GetTheme
-    if (aWidgetType == NS_THEME_DROPDOWN)
+    if (aWidgetType == NS_THEME_MENULIST)
       aWidgetType = NS_THEME_TEXTFIELD;
   }
 
   switch (aWidgetType) {
     case NS_THEME_BUTTON: {
       aPart = BP_BUTTON;
       if (!aFrame) {
         aState = TS_NORMAL;
@@ -1021,32 +1021,32 @@ nsNativeThemeWin::GetThemePartAndState(n
       // NS_THEME_PROGRESSBAR_VERTICAL is dedicated to -moz-appearance:
       // progressbar-vertical.
       bool vertical = IsVerticalProgress(aFrame) ||
                       aWidgetType == NS_THEME_PROGRESSBAR_VERTICAL;
       aPart = vertical ? PP_BARVERT : PP_BAR;
       aState = PBBS_NORMAL;
       return NS_OK;
     }
-    case NS_THEME_PROGRESSBAR_CHUNK:
-    case NS_THEME_PROGRESSBAR_CHUNK_VERTICAL: {
+    case NS_THEME_PROGRESSCHUNK:
+    case NS_THEME_PROGRESSCHUNK_VERTICAL: {
       nsIFrame* parentFrame = aFrame->GetParent();
-      if (aWidgetType == NS_THEME_PROGRESSBAR_CHUNK_VERTICAL ||
+      if (aWidgetType == NS_THEME_PROGRESSCHUNK_VERTICAL ||
           IsVerticalProgress(parentFrame)) {
         aPart = IsVistaOrLater() ?
           PP_FILLVERT : PP_CHUNKVERT;
       } else {
         aPart = IsVistaOrLater() ?
           PP_FILL : PP_CHUNK;
       }
 
       aState = PBBVS_NORMAL;
       return NS_OK;
     }
-    case NS_THEME_TOOLBAR_BUTTON: {
+    case NS_THEME_TOOLBARBUTTON: {
       aPart = BP_BUTTON;
       if (!aFrame) {
         aState = TS_NORMAL;
         return NS_OK;
       }
 
       EventStates eventState = GetContentState(aFrame, aWidgetType);
       if (IsDisabled(aFrame, eventState)) {
@@ -1070,58 +1070,58 @@ nsNativeThemeWin::GetThemePartAndState(n
         if (IsCheckedButton(aFrame))
           aState = TB_CHECKED;
         else
           aState = TS_NORMAL;
       }
      
       return NS_OK;
     }
-    case NS_THEME_TOOLBAR_SEPARATOR: {
+    case NS_THEME_SEPARATOR: {
       aPart = TP_SEPARATOR;
       aState = TS_NORMAL;
       return NS_OK;
     }
-    case NS_THEME_SCROLLBAR_BUTTON_UP:
-    case NS_THEME_SCROLLBAR_BUTTON_DOWN:
-    case NS_THEME_SCROLLBAR_BUTTON_LEFT:
-    case NS_THEME_SCROLLBAR_BUTTON_RIGHT: {
+    case NS_THEME_SCROLLBARBUTTON_UP:
+    case NS_THEME_SCROLLBARBUTTON_DOWN:
+    case NS_THEME_SCROLLBARBUTTON_LEFT:
+    case NS_THEME_SCROLLBARBUTTON_RIGHT: {
       aPart = SP_BUTTON;
-      aState = (aWidgetType - NS_THEME_SCROLLBAR_BUTTON_UP)*4;
+      aState = (aWidgetType - NS_THEME_SCROLLBARBUTTON_UP)*4;
       EventStates eventState = GetContentState(aFrame, aWidgetType);
       if (!aFrame)
         aState += TS_NORMAL;
       else if (IsDisabled(aFrame, eventState))
         aState += TS_DISABLED;
       else {
         nsIFrame *parent = aFrame->GetParent();
         EventStates parentState =
           GetContentState(parent, parent->StyleDisplay()->mAppearance);
         if (eventState.HasAllStates(NS_EVENT_STATE_HOVER | NS_EVENT_STATE_ACTIVE))
           aState += TS_ACTIVE;
         else if (eventState.HasState(NS_EVENT_STATE_HOVER))
           aState += TS_HOVER;
         else if (IsVistaOrLater() &&
                  parentState.HasState(NS_EVENT_STATE_HOVER))
-          aState = (aWidgetType - NS_THEME_SCROLLBAR_BUTTON_UP) + SP_BUTTON_IMPLICIT_HOVER_BASE;
+          aState = (aWidgetType - NS_THEME_SCROLLBARBUTTON_UP) + SP_BUTTON_IMPLICIT_HOVER_BASE;
         else
           aState += TS_NORMAL;
       }
       return NS_OK;
     }
     case NS_THEME_SCROLLBAR_HORIZONTAL:
     case NS_THEME_SCROLLBAR_VERTICAL: {
       aPart = (aWidgetType == NS_THEME_SCROLLBAR_HORIZONTAL) ?
               SP_TRACKSTARTHOR : SP_TRACKSTARTVERT;
       aState = TS_NORMAL;
       return NS_OK;
     }
-    case NS_THEME_SCROLLBAR_THUMB_HORIZONTAL:
-    case NS_THEME_SCROLLBAR_THUMB_VERTICAL: {
-      aPart = (aWidgetType == NS_THEME_SCROLLBAR_THUMB_HORIZONTAL) ?
+    case NS_THEME_SCROLLBARTHUMB_HORIZONTAL:
+    case NS_THEME_SCROLLBARTHUMB_VERTICAL: {
+      aPart = (aWidgetType == NS_THEME_SCROLLBARTHUMB_HORIZONTAL) ?
               SP_THUMBHOR : SP_THUMBVERT;
       EventStates eventState = GetContentState(aFrame, aWidgetType);
       if (!aFrame)
         aState = TS_NORMAL;
       else if (IsDisabled(aFrame, eventState))
         aState = TS_DISABLED;
       else {
         if (eventState.HasState(NS_EVENT_STATE_ACTIVE)) // Hover is not also a requirement for
@@ -1145,26 +1145,26 @@ nsNativeThemeWin::GetThemePartAndState(n
         aState = TRS_NORMAL;
       } else {
         aPart = TKP_TRACKVERT;
         aState = TRVS_NORMAL;
       }
       return NS_OK;
     }
     case NS_THEME_RANGE_THUMB:
-    case NS_THEME_SCALE_THUMB_HORIZONTAL:
-    case NS_THEME_SCALE_THUMB_VERTICAL: {
+    case NS_THEME_SCALETHUMB_HORIZONTAL:
+    case NS_THEME_SCALETHUMB_VERTICAL: {
       if (aWidgetType == NS_THEME_RANGE_THUMB) {
         if (IsRangeHorizontal(aFrame)) {
           aPart = TKP_THUMBBOTTOM;
         } else {
           aPart = IsFrameRTL(aFrame) ? TKP_THUMBLEFT : TKP_THUMBRIGHT;
         }
       } else {
-        aPart = (aWidgetType == NS_THEME_SCALE_THUMB_HORIZONTAL) ?
+        aPart = (aWidgetType == NS_THEME_SCALETHUMB_HORIZONTAL) ?
                 TKP_THUMB : TKP_THUMBVERT;
       }
       EventStates eventState = GetContentState(aFrame, aWidgetType);
       if (!aFrame)
         aState = TS_NORMAL;
       else if (IsDisabled(aFrame, eventState)) {
         aState = TKP_DISABLED;
       }
@@ -1177,33 +1177,33 @@ nsNativeThemeWin::GetThemePartAndState(n
           aState = TKP_FOCUSED;
         else if (eventState.HasState(NS_EVENT_STATE_HOVER))
           aState = TS_HOVER;
         else
           aState = TS_NORMAL;
       }
       return NS_OK;
     }
-    case NS_THEME_SPINNER_UP_BUTTON:
-    case NS_THEME_SPINNER_DOWN_BUTTON: {
-      aPart = (aWidgetType == NS_THEME_SPINNER_UP_BUTTON) ?
+    case NS_THEME_SPINNER_UPBUTTON:
+    case NS_THEME_SPINNER_DOWNBUTTON: {
+      aPart = (aWidgetType == NS_THEME_SPINNER_UPBUTTON) ?
               SPNP_UP : SPNP_DOWN;
       EventStates eventState = GetContentState(aFrame, aWidgetType);
       if (!aFrame)
         aState = TS_NORMAL;
       else if (IsDisabled(aFrame, eventState))
         aState = TS_DISABLED;
       else
         aState = StandardGetState(aFrame, aWidgetType, false);
       return NS_OK;    
     }
     case NS_THEME_TOOLBOX:
     case NS_THEME_WIN_MEDIA_TOOLBOX:
     case NS_THEME_WIN_COMMUNICATIONS_TOOLBOX:
-    case NS_THEME_WIN_BROWSER_TAB_BAR_TOOLBOX:
+    case NS_THEME_WIN_BROWSERTABBAR_TOOLBOX:
     case NS_THEME_STATUSBAR:
     case NS_THEME_SCROLLBAR:
     case NS_THEME_SCROLLBAR_SMALL: {
       aState = 0;
       if (IsVistaOrLater()) {
         // On vista, they have a part
         aPart = RP_BACKGROUND;
       } else {
@@ -1224,35 +1224,35 @@ nsNativeThemeWin::GetThemePartAndState(n
         nsIContent* parent = content->GetParent();
         // XXXzeniko hiding the first toolbar will result in an unwanted margin
         if (parent && parent->GetFirstChild() == content) {
           aState = 1;
         }
       }
       return NS_OK;
     }
-    case NS_THEME_STATUSBAR_PANEL:
-    case NS_THEME_STATUSBAR_RESIZER_PANEL:
+    case NS_THEME_STATUSBARPANEL:
+    case NS_THEME_RESIZER_PANEL:
     case NS_THEME_RESIZER: {
-      aPart = (aWidgetType - NS_THEME_STATUSBAR_PANEL) + 1;
+      aPart = (aWidgetType - NS_THEME_STATUSBARPANEL) + 1;
       aState = TS_NORMAL;
       return NS_OK;
     }
     case NS_THEME_TREEVIEW:
     case NS_THEME_LISTBOX: {
       aPart = TREEVIEW_BODY;
       aState = TS_NORMAL;
       return NS_OK;
     }
-    case NS_THEME_TAB_PANELS: {
+    case NS_THEME_TABPANELS: {
       aPart = TABP_PANELS;
       aState = TS_NORMAL;
       return NS_OK;
     }
-    case NS_THEME_TAB_PANEL: {
+    case NS_THEME_TABPANEL: {
       aPart = TABP_PANEL;
       aState = TS_NORMAL;
       return NS_OK;
     }
     case NS_THEME_TAB: {
       aPart = TABP_TAB;
       if (!aFrame) {
         aState = TS_NORMAL;
@@ -1269,34 +1269,34 @@ nsNativeThemeWin::GetThemePartAndState(n
         aPart = TABP_TAB_SELECTED;
         aState = TS_ACTIVE; // The selected tab is always "pressed".
       }
       else
         aState = StandardGetState(aFrame, aWidgetType, true);
       
       return NS_OK;
     }
-    case NS_THEME_TREEVIEW_HEADER_SORTARROW: {
+    case NS_THEME_TREEHEADERSORTARROW: {
       // XXX Probably will never work due to a bug in the Luna theme.
       aPart = 4;
       aState = 1;
       return NS_OK;
     }
-    case NS_THEME_TREEVIEW_HEADER_CELL: {
+    case NS_THEME_TREEHEADERCELL: {
       aPart = 1;
       if (!aFrame) {
         aState = TS_NORMAL;
         return NS_OK;
       }
       
       aState = StandardGetState(aFrame, aWidgetType, true);
       
       return NS_OK;
     }
-    case NS_THEME_DROPDOWN: {
+    case NS_THEME_MENULIST: {
       nsIContent* content = aFrame->GetContent();
       bool isHTML = content && content->IsHTMLElement();
       bool useDropBorder = isHTML || IsMenuListEditable(aFrame);
       EventStates eventState = GetContentState(aFrame, aWidgetType);
 
       /* On Vista/Win7, we use CBP_DROPBORDER instead of DROPFRAME for HTML
        * content or for editable menulists; this gives us the thin outline,
        * instead of the gradient-filled background */
@@ -1319,34 +1319,34 @@ nsNativeThemeWin::GetThemePartAndState(n
         else if (eventState.HasState(NS_EVENT_STATE_HOVER))
           aState = TS_HOVER;
         else
           aState = TS_NORMAL;
       }
 
       return NS_OK;
     }
-    case NS_THEME_DROPDOWN_BUTTON: {
+    case NS_THEME_MENULIST_BUTTON: {
       bool isHTML = IsHTMLContent(aFrame);
       nsIFrame* parentFrame = aFrame->GetParent();
       bool isMenulist = !isHTML && parentFrame->GetType() == nsGkAtoms::menuFrame;
       bool isOpen = false;
 
       // HTML select and XUL menulist dropdown buttons get state from the parent.
       if (isHTML || isMenulist)
         aFrame = parentFrame;
 
       EventStates eventState = GetContentState(aFrame, aWidgetType);
       aPart = IsVistaOrLater() ?
         CBP_DROPMARKER_VISTA : CBP_DROPMARKER;
 
       // For HTML controls with author styling, we should fall
       // back to the old dropmarker style to avoid clashes with
       // author-specified backgrounds and borders (bug #441034)
-      if (isHTML && IsWidgetStyled(aFrame->PresContext(), aFrame, NS_THEME_DROPDOWN))
+      if (isHTML && IsWidgetStyled(aFrame->PresContext(), aFrame, NS_THEME_MENULIST))
         aPart = CBP_DROPMARKER;
 
       if (IsDisabled(aFrame, eventState)) {
         aState = TS_DISABLED;
         return NS_OK;
       }
 
       if (isHTML) {
@@ -1843,17 +1843,17 @@ RENDER_AGAIN:
       renderRect.left = glyphSize.cx;
       renderRect.right = renderRect.left + glyphSize.cx;
     }
     DrawThemeBGRTLAware(theme, hdc, part, state, &renderRect, &clipRect,
                         IsFrameRTL(aFrame));
   }
   // The following widgets need to be RTL-aware
   else if (aWidgetType == NS_THEME_RESIZER ||
-           aWidgetType == NS_THEME_DROPDOWN_BUTTON)
+           aWidgetType == NS_THEME_MENULIST_BUTTON)
   {
     DrawThemeBGRTLAware(theme, hdc, part, state,
                         &widgetRect, &clipRect, IsFrameRTL(aFrame));
   }
   else if (aWidgetType == NS_THEME_NUMBER_INPUT ||
            aWidgetType == NS_THEME_TEXTFIELD ||
            aWidgetType == NS_THEME_TEXTFIELD_MULTILINE) {
     DrawThemeBackground(theme, hdc, part, state, &widgetRect, &clipRect);
@@ -1870,18 +1870,18 @@ RENDER_AGAIN:
     COLORREF color;
     color = GetPixel(hdc, widgetRect.left, widgetRect.top);
     DrawThemeBackground(theme, hdc, part, state, &widgetRect, &clipRect);
     SetPixel(hdc, widgetRect.left, widgetRect.top, color);
     SetPixel(hdc, widgetRect.right-1, widgetRect.top, color);
     SetPixel(hdc, widgetRect.right-1, widgetRect.bottom-1, color);
     SetPixel(hdc, widgetRect.left, widgetRect.bottom-1, color);
   }
-  else if (aWidgetType == NS_THEME_PROGRESSBAR_CHUNK ||
-           aWidgetType == NS_THEME_PROGRESSBAR_CHUNK_VERTICAL) {
+  else if (aWidgetType == NS_THEME_PROGRESSCHUNK ||
+           aWidgetType == NS_THEME_PROGRESSCHUNK_VERTICAL) {
     DrawThemedProgressMeter(aFrame, aWidgetType, theme, hdc, part, state,
                             &widgetRect, &clipRect, p2a);
   }
   else if (aWidgetType == NS_THEME_FOCUS_OUTLINE) {
     // Inflate 'widgetRect' with the focus outline size.
     nsIntMargin border;
     if (NS_SUCCEEDED(GetWidgetBorder(aFrame->PresContext()->DeviceContext(),
                                      aFrame, aWidgetType, &border))) {
@@ -1961,24 +1961,24 @@ RENDER_AGAIN:
     // The lines are part of the Rebar theme, which is loaded for NS_THEME_TOOLBOX.
     theme = GetTheme(NS_THEME_TOOLBOX);
     if (!theme)
       return NS_ERROR_FAILURE;
 
     widgetRect.bottom = widgetRect.top + TB_SEPARATOR_HEIGHT;
     DrawThemeEdge(theme, hdc, RP_BAND, 0, &widgetRect, EDGE_ETCHED, BF_TOP, nullptr);
   }
-  else if (aWidgetType == NS_THEME_SCROLLBAR_THUMB_HORIZONTAL ||
-           aWidgetType == NS_THEME_SCROLLBAR_THUMB_VERTICAL)
+  else if (aWidgetType == NS_THEME_SCROLLBARTHUMB_HORIZONTAL ||
+           aWidgetType == NS_THEME_SCROLLBARTHUMB_VERTICAL)
   {
     // Draw the decorative gripper for the scrollbar thumb button, if it fits
 
     SIZE gripSize;
     MARGINS thumbMgns;
-    int gripPart = (aWidgetType == NS_THEME_SCROLLBAR_THUMB_HORIZONTAL) ?
+    int gripPart = (aWidgetType == NS_THEME_SCROLLBARTHUMB_HORIZONTAL) ?
                    SP_GRIPPERHOR : SP_GRIPPERVERT;
 
     if (GetThemePartSize(theme, hdc, gripPart, state, nullptr, TS_TRUE, &gripSize) == S_OK &&
         GetThemeMargins(theme, hdc, part, state, TMT_CONTENTMARGINS, nullptr, &thumbMgns) == S_OK &&
         gripSize.cx + thumbMgns.cxLeftWidth + thumbMgns.cxRightWidth <= widgetRect.right - widgetRect.left &&
         gripSize.cy + thumbMgns.cyTopHeight + thumbMgns.cyBottomHeight <= widgetRect.bottom - widgetRect.top)
     {
       DrawThemeBackground(theme, hdc, gripPart, state, &widgetRect, &clipRect);
@@ -2032,25 +2032,25 @@ nsNativeThemeWin::GetWidgetBorder(nsDevi
   }
 
   aResult->top = aResult->bottom = aResult->left = aResult->right = 0;
 
   if (!WidgetIsContainer(aWidgetType) ||
       aWidgetType == NS_THEME_TOOLBOX || 
       aWidgetType == NS_THEME_WIN_MEDIA_TOOLBOX ||
       aWidgetType == NS_THEME_WIN_COMMUNICATIONS_TOOLBOX ||
-      aWidgetType == NS_THEME_WIN_BROWSER_TAB_BAR_TOOLBOX ||
+      aWidgetType == NS_THEME_WIN_BROWSERTABBAR_TOOLBOX ||
       aWidgetType == NS_THEME_STATUSBAR || 
-      aWidgetType == NS_THEME_RESIZER || aWidgetType == NS_THEME_TAB_PANEL ||
+      aWidgetType == NS_THEME_RESIZER || aWidgetType == NS_THEME_TABPANEL ||
       aWidgetType == NS_THEME_SCROLLBAR_HORIZONTAL ||
       aWidgetType == NS_THEME_SCROLLBAR_VERTICAL ||
       aWidgetType == NS_THEME_MENUITEM || aWidgetType == NS_THEME_CHECKMENUITEM ||
       aWidgetType == NS_THEME_RADIOMENUITEM || aWidgetType == NS_THEME_MENUPOPUP ||
       aWidgetType == NS_THEME_MENUIMAGE || aWidgetType == NS_THEME_MENUITEMTEXT ||
-      aWidgetType == NS_THEME_TOOLBAR_SEPARATOR ||
+      aWidgetType == NS_THEME_SEPARATOR ||
       aWidgetType == NS_THEME_WINDOW_TITLEBAR ||
       aWidgetType == NS_THEME_WINDOW_TITLEBAR_MAXIMIZED ||
       aWidgetType == NS_THEME_WIN_GLASS || aWidgetType == NS_THEME_WIN_BORDERLESS_GLASS)
     return NS_OK; // Don't worry about it.
 
   int32_t part, state;
   rv = GetThemePartAndState(aFrame, aWidgetType, part, state);
   if (NS_FAILED(rv))
@@ -2171,17 +2171,17 @@ nsNativeThemeWin::GetWidgetPadding(nsDev
     ScaleForFrameDPI(aResult, aFrame);
     return ok;
   }
 
   if (IsVistaOrLater()) {
     if (aWidgetType == NS_THEME_NUMBER_INPUT ||
         aWidgetType == NS_THEME_TEXTFIELD ||
         aWidgetType == NS_THEME_TEXTFIELD_MULTILINE ||
-        aWidgetType == NS_THEME_DROPDOWN)
+        aWidgetType == NS_THEME_MENULIST)
     {
       /* If we have author-specified padding for these elements, don't do the fixups below */
       if (aFrame->PresContext()->HasAuthorSpecifiedRules(aFrame, NS_AUTHOR_SPECIFIED_PADDING))
         return false;
     }
 
     /* textfields need extra pixels on all sides, otherwise they
      * wrap their content too tightly.  The actual border is drawn 1px
@@ -2191,17 +2191,17 @@ nsNativeThemeWin::GetWidgetPadding(nsDev
      */
     if (aWidgetType == NS_THEME_NUMBER_INPUT ||
         aWidgetType == NS_THEME_TEXTFIELD ||
         aWidgetType == NS_THEME_TEXTFIELD_MULTILINE) {
       aResult->top = aResult->bottom = 2;
       aResult->left = aResult->right = 2;
       ScaleForFrameDPI(aResult, aFrame);
       return ok;
-    } else if (IsHTMLContent(aFrame) && aWidgetType == NS_THEME_DROPDOWN) {
+    } else if (IsHTMLContent(aFrame) && aWidgetType == NS_THEME_MENULIST) {
       /* For content menulist controls, we need an extra pixel so
        * that we have room to draw our focus rectangle stuff.
        * Otherwise, the focus rect might overlap the control's
        * border.
        */
       aResult->top = aResult->bottom = 1;
       aResult->left = aResult->right = 1;
       ScaleForFrameDPI(aResult, aFrame);
@@ -2271,21 +2271,21 @@ nsNativeThemeWin::GetWidgetOverflow(nsDe
    * a border only shows up if the widget is being hovered.
    */
 #if 0
   if (IsVistaOrLater()) {
     /* We explicitly draw dropdown buttons in HTML content 1px bigger
      * up, right, and bottom so that they overlap the dropdown's border
      * like they're supposed to.
      */
-    if (aWidgetType == NS_THEME_DROPDOWN_BUTTON &&
+    if (aWidgetType == NS_THEME_MENULIST_BUTTON &&
         IsHTMLContent(aFrame) &&
         !IsWidgetStyled(aFrame->GetParent()->PresContext(),
                         aFrame->GetParent(),
-                        NS_THEME_DROPDOWN))
+                        NS_THEME_MENULIST))
     {
       int32_t p2a = aContext->AppUnitsPerDevPixel();
       /* Note: no overflow on the left */
       nsMargin m(p2a, p2a, p2a, 0);
       aOverflowRect->Inflate (m);
       return true;
     }
   }
@@ -2325,48 +2325,48 @@ nsNativeThemeWin::GetMinimumWidgetSize(n
   }
   switch (aWidgetType) {
     case NS_THEME_GROUPBOX:
     case NS_THEME_NUMBER_INPUT:
     case NS_THEME_TEXTFIELD:
     case NS_THEME_TOOLBOX:
     case NS_THEME_WIN_MEDIA_TOOLBOX:
     case NS_THEME_WIN_COMMUNICATIONS_TOOLBOX:
-    case NS_THEME_WIN_BROWSER_TAB_BAR_TOOLBOX:
+    case NS_THEME_WIN_BROWSERTABBAR_TOOLBOX:
     case NS_THEME_TOOLBAR:
     case NS_THEME_STATUSBAR:
-    case NS_THEME_PROGRESSBAR_CHUNK:
-    case NS_THEME_PROGRESSBAR_CHUNK_VERTICAL:
-    case NS_THEME_TAB_PANELS:
-    case NS_THEME_TAB_PANEL:
+    case NS_THEME_PROGRESSCHUNK:
+    case NS_THEME_PROGRESSCHUNK_VERTICAL:
+    case NS_THEME_TABPANELS:
+    case NS_THEME_TABPANEL:
     case NS_THEME_LISTBOX:
     case NS_THEME_TREEVIEW:
     case NS_THEME_MENUITEMTEXT:
     case NS_THEME_WIN_GLASS:
     case NS_THEME_WIN_BORDERLESS_GLASS:
       return NS_OK; // Don't worry about it.
   }
 
   if (aWidgetType == NS_THEME_MENUITEM && IsTopLevelMenu(aFrame))
       return NS_OK; // Don't worry about it for top level menus
 
   // Call GetSystemMetrics to determine size for WinXP scrollbars
   // (GetThemeSysSize API returns the optimal size for the theme, but 
   //  Windows appears to always use metrics when drawing standard scrollbars)
   THEMESIZE sizeReq = TS_TRUE; // Best-fit size
   switch (aWidgetType) {
-    case NS_THEME_SCROLLBAR_THUMB_VERTICAL:
-    case NS_THEME_SCROLLBAR_THUMB_HORIZONTAL:
-    case NS_THEME_SCROLLBAR_BUTTON_UP:
-    case NS_THEME_SCROLLBAR_BUTTON_DOWN:
-    case NS_THEME_SCROLLBAR_BUTTON_LEFT:
-    case NS_THEME_SCROLLBAR_BUTTON_RIGHT:
+    case NS_THEME_SCROLLBARTHUMB_VERTICAL:
+    case NS_THEME_SCROLLBARTHUMB_HORIZONTAL:
+    case NS_THEME_SCROLLBARBUTTON_UP:
+    case NS_THEME_SCROLLBARBUTTON_DOWN:
+    case NS_THEME_SCROLLBARBUTTON_LEFT:
+    case NS_THEME_SCROLLBARBUTTON_RIGHT:
     case NS_THEME_SCROLLBAR_HORIZONTAL:
     case NS_THEME_SCROLLBAR_VERTICAL:
-    case NS_THEME_DROPDOWN_BUTTON: {
+    case NS_THEME_MENULIST_BUTTON: {
       rv = ClassicGetMinimumWidgetSize(aFrame, aWidgetType, aResult, aIsOverridable);
       ScaleForFrameDPI(aResult, aFrame);
       return rv;
     }
     case NS_THEME_MENUITEM:
     case NS_THEME_CHECKMENUITEM:
     case NS_THEME_RADIOMENUITEM:
       if(!IsTopLevelMenu(aFrame))
@@ -2402,24 +2402,24 @@ nsNativeThemeWin::GetMinimumWidgetSize(n
       sizeReq = TS_MIN; 
       break;
 
     case NS_THEME_RESIZER:
       *aIsOverridable = false;
       break;
 
     case NS_THEME_RANGE_THUMB:
-    case NS_THEME_SCALE_THUMB_HORIZONTAL:
-    case NS_THEME_SCALE_THUMB_VERTICAL:
+    case NS_THEME_SCALETHUMB_HORIZONTAL:
+    case NS_THEME_SCALETHUMB_VERTICAL:
     {
       *aIsOverridable = false;
       // on Vista, GetThemePartAndState returns odd values for
       // scale thumbs, so use a hardcoded size instead.
       if (IsVistaOrLater()) {
-        if (aWidgetType == NS_THEME_SCALE_THUMB_HORIZONTAL ||
+        if (aWidgetType == NS_THEME_SCALETHUMB_HORIZONTAL ||
             (aWidgetType == NS_THEME_RANGE_THUMB && IsRangeHorizontal(aFrame))) {
           aResult->width = 12;
           aResult->height = 20;
         }
         else {
           aResult->width = 20;
           aResult->height = 12;
         }
@@ -2436,17 +2436,17 @@ nsNativeThemeWin::GetMinimumWidgetSize(n
         aResult->SizeTo(::GetSystemMetrics(SM_CXHSCROLL),
                         ::GetSystemMetrics(SM_CYVSCROLL));
         ScaleForFrameDPI(aResult, aFrame);
         return rv;
       }
       break;
     }
 
-    case NS_THEME_TOOLBAR_SEPARATOR:
+    case NS_THEME_SEPARATOR:
       // that's 2px left margin, 2px right margin and 2px separator
       // (the margin is drawn as part of the separator, though)
       aResult->width = 6;
       ScaleForFrameDPI(aResult, aFrame);
       return rv;
 
     case NS_THEME_BUTTON:
       // We should let HTML buttons shrink to their min size.
@@ -2548,18 +2548,18 @@ nsNativeThemeWin::GetMinimumWidgetSize(n
     return NS_ERROR_FAILURE;
 
   SIZE sz;
   GetThemePartSize(theme, hdc, part, state, nullptr, sizeReq, &sz);
   aResult->width = sz.cx;
   aResult->height = sz.cy;
 
   switch(aWidgetType) {
-    case NS_THEME_SPINNER_UP_BUTTON:
-    case NS_THEME_SPINNER_DOWN_BUTTON:
+    case NS_THEME_SPINNER_UPBUTTON:
+    case NS_THEME_SPINNER_DOWNBUTTON:
       aResult->width++;
       aResult->height = aResult->height / 2 + 1;
       break;
 
     case NS_THEME_MENUSEPARATOR:
     {
       SIZE gutterSize(GetGutterSize(theme, hdc));
       aResult->width += gutterSize.cx;
@@ -2585,28 +2585,28 @@ NS_IMETHODIMP
 nsNativeThemeWin::WidgetStateChanged(nsIFrame* aFrame, uint8_t aWidgetType, 
                                      nsIAtom* aAttribute, bool* aShouldRepaint,
                                      const nsAttrValue* aOldValue)
 {
   // Some widget types just never change state.
   if (aWidgetType == NS_THEME_TOOLBOX ||
       aWidgetType == NS_THEME_WIN_MEDIA_TOOLBOX ||
       aWidgetType == NS_THEME_WIN_COMMUNICATIONS_TOOLBOX ||
-      aWidgetType == NS_THEME_WIN_BROWSER_TAB_BAR_TOOLBOX ||
+      aWidgetType == NS_THEME_WIN_BROWSERTABBAR_TOOLBOX ||
       aWidgetType == NS_THEME_TOOLBAR ||
-      aWidgetType == NS_THEME_STATUSBAR || aWidgetType == NS_THEME_STATUSBAR_PANEL ||
-      aWidgetType == NS_THEME_STATUSBAR_RESIZER_PANEL ||
-      aWidgetType == NS_THEME_PROGRESSBAR_CHUNK ||
-      aWidgetType == NS_THEME_PROGRESSBAR_CHUNK_VERTICAL ||
+      aWidgetType == NS_THEME_STATUSBAR || aWidgetType == NS_THEME_STATUSBARPANEL ||
+      aWidgetType == NS_THEME_RESIZER_PANEL ||
+      aWidgetType == NS_THEME_PROGRESSCHUNK ||
+      aWidgetType == NS_THEME_PROGRESSCHUNK_VERTICAL ||
       aWidgetType == NS_THEME_PROGRESSBAR ||
       aWidgetType == NS_THEME_PROGRESSBAR_VERTICAL ||
       aWidgetType == NS_THEME_TOOLTIP ||
-      aWidgetType == NS_THEME_TAB_PANELS ||
-      aWidgetType == NS_THEME_TAB_PANEL ||
-      aWidgetType == NS_THEME_TOOLBAR_SEPARATOR ||
+      aWidgetType == NS_THEME_TABPANELS ||
+      aWidgetType == NS_THEME_TABPANEL ||
+      aWidgetType == NS_THEME_SEPARATOR ||
       aWidgetType == NS_THEME_WIN_GLASS ||
       aWidgetType == NS_THEME_WIN_BORDERLESS_GLASS) {
     *aShouldRepaint = false;
     return NS_OK;
   }
 
   if (aWidgetType == NS_THEME_WINDOW_TITLEBAR ||
       aWidgetType == NS_THEME_WINDOW_TITLEBAR_MAXIMIZED ||
@@ -2627,17 +2627,17 @@ nsNativeThemeWin::WidgetStateChanged(nsI
       aWidgetType == NS_THEME_SCROLLBAR_HORIZONTAL)) {
     *aShouldRepaint = false;
     return NS_OK;
   }
 
   // We need to repaint the dropdown arrow in vista HTML combobox controls when
   // the control is closed to get rid of the hover effect.
   if (IsVistaOrLater() &&
-      (aWidgetType == NS_THEME_DROPDOWN || aWidgetType == NS_THEME_DROPDOWN_BUTTON) &&
+      (aWidgetType == NS_THEME_MENULIST || aWidgetType == NS_THEME_MENULIST_BUTTON) &&
       IsHTMLContent(aFrame))
   {
     *aShouldRepaint = true;
     return NS_OK;
   }
 
   // XXXdwh Not sure what can really be done here.  Can at least guess for
   // specific widgets that they're highly unlikely to have certain states.
@@ -2703,17 +2703,17 @@ nsNativeThemeWin::ThemeSupportsWidget(ns
 
   return false;
 }
 
 bool 
 nsNativeThemeWin::WidgetIsContainer(uint8_t aWidgetType)
 {
   // XXXdwh At some point flesh all of this out.
-  if (aWidgetType == NS_THEME_DROPDOWN_BUTTON || 
+  if (aWidgetType == NS_THEME_MENULIST_BUTTON || 
       aWidgetType == NS_THEME_RADIO ||
       aWidgetType == NS_THEME_CHECKBOX)
     return false;
   return true;
 }
 
 bool
 nsNativeThemeWin::ThemeDrawsFocusForWidget(uint8_t aWidgetType)
@@ -2778,18 +2778,18 @@ nsNativeThemeWin::GetWidgetTransparency(
     // paint an opaque background for them to make it true!
     return eOpaque;
   case NS_THEME_WIN_GLASS:
   case NS_THEME_WIN_BORDERLESS_GLASS:
   case NS_THEME_SCALE_HORIZONTAL:
   case NS_THEME_SCALE_VERTICAL:
   case NS_THEME_PROGRESSBAR:
   case NS_THEME_PROGRESSBAR_VERTICAL:
-  case NS_THEME_PROGRESSBAR_CHUNK:
-  case NS_THEME_PROGRESSBAR_CHUNK_VERTICAL:
+  case NS_THEME_PROGRESSCHUNK:
+  case NS_THEME_PROGRESSCHUNK_VERTICAL:
   case NS_THEME_RANGE:
     return eTransparent;
   }
 
   HANDLE theme = GetTheme(aWidgetType);
   // For the classic theme we don't really have a way of knowing
   if (!theme) {
     // menu backgrounds and tooltips which can't be themed are opaque
@@ -2839,47 +2839,47 @@ nsNativeThemeWin::ClassicThemeSupportsWi
     case NS_THEME_NUMBER_INPUT:
     case NS_THEME_TEXTFIELD:
     case NS_THEME_TEXTFIELD_MULTILINE:
     case NS_THEME_CHECKBOX:
     case NS_THEME_RADIO:
     case NS_THEME_RANGE:
     case NS_THEME_RANGE_THUMB:
     case NS_THEME_GROUPBOX:
-    case NS_THEME_SCROLLBAR_BUTTON_UP:
-    case NS_THEME_SCROLLBAR_BUTTON_DOWN:
-    case NS_THEME_SCROLLBAR_BUTTON_LEFT:
-    case NS_THEME_SCROLLBAR_BUTTON_RIGHT:
-    case NS_THEME_SCROLLBAR_THUMB_VERTICAL:
-    case NS_THEME_SCROLLBAR_THUMB_HORIZONTAL:
+    case NS_THEME_SCROLLBARBUTTON_UP:
+    case NS_THEME_SCROLLBARBUTTON_DOWN:
+    case NS_THEME_SCROLLBARBUTTON_LEFT:
+    case NS_THEME_SCROLLBARBUTTON_RIGHT:
+    case NS_THEME_SCROLLBARTHUMB_VERTICAL:
+    case NS_THEME_SCROLLBARTHUMB_HORIZONTAL:
     case NS_THEME_SCROLLBAR_VERTICAL:
     case NS_THEME_SCROLLBAR_HORIZONTAL:
     case NS_THEME_SCROLLBAR_NON_DISAPPEARING:
     case NS_THEME_SCALE_HORIZONTAL:
     case NS_THEME_SCALE_VERTICAL:
-    case NS_THEME_SCALE_THUMB_HORIZONTAL:
-    case NS_THEME_SCALE_THUMB_VERTICAL:
-    case NS_THEME_DROPDOWN_BUTTON:
-    case NS_THEME_SPINNER_UP_BUTTON:
-    case NS_THEME_SPINNER_DOWN_BUTTON:
+    case NS_THEME_SCALETHUMB_HORIZONTAL:
+    case NS_THEME_SCALETHUMB_VERTICAL:
+    case NS_THEME_MENULIST_BUTTON:
+    case NS_THEME_SPINNER_UPBUTTON:
+    case NS_THEME_SPINNER_DOWNBUTTON:
     case NS_THEME_LISTBOX:
     case NS_THEME_TREEVIEW:
-    case NS_THEME_DROPDOWN_TEXTFIELD:
-    case NS_THEME_DROPDOWN:
+    case NS_THEME_MENULIST_TEXTFIELD:
+    case NS_THEME_MENULIST:
     case NS_THEME_TOOLTIP:
     case NS_THEME_STATUSBAR:
-    case NS_THEME_STATUSBAR_PANEL:
-    case NS_THEME_STATUSBAR_RESIZER_PANEL:
+    case NS_THEME_STATUSBARPANEL:
+    case NS_THEME_RESIZER_PANEL:
     case NS_THEME_PROGRESSBAR:
     case NS_THEME_PROGRESSBAR_VERTICAL:
-    case NS_THEME_PROGRESSBAR_CHUNK:
-    case NS_THEME_PROGRESSBAR_CHUNK_VERTICAL:
+    case NS_THEME_PROGRESSCHUNK:
+    case NS_THEME_PROGRESSCHUNK_VERTICAL:
     case NS_THEME_TAB:
-    case NS_THEME_TAB_PANEL:
-    case NS_THEME_TAB_PANELS:
+    case NS_THEME_TABPANEL:
+    case NS_THEME_TABPANELS:
     case NS_THEME_MENUITEM:
     case NS_THEME_CHECKMENUITEM:
     case NS_THEME_RADIOMENUITEM:
     case NS_THEME_MENUCHECKBOX:
     case NS_THEME_MENURADIO:
     case NS_THEME_MENUARROW:
     case NS_THEME_MENUSEPARATOR:
     case NS_THEME_MENUITEMTEXT:
@@ -2911,27 +2911,27 @@ nsNativeThemeWin::ClassicGetWidgetBorder
       (*aResult).top = (*aResult).left = (*aResult).bottom = (*aResult).right = 2; 
       break;
     case NS_THEME_STATUSBAR:
       (*aResult).bottom = (*aResult).left = (*aResult).right = 0;
       (*aResult).top = 2;
       break;
     case NS_THEME_LISTBOX:
     case NS_THEME_TREEVIEW:
-    case NS_THEME_DROPDOWN:
-    case NS_THEME_DROPDOWN_TEXTFIELD:
+    case NS_THEME_MENULIST:
+    case NS_THEME_MENULIST_TEXTFIELD:
     case NS_THEME_TAB:
     case NS_THEME_NUMBER_INPUT:
     case NS_THEME_TEXTFIELD:
     case NS_THEME_TEXTFIELD_MULTILINE:
     case NS_THEME_FOCUS_OUTLINE:
       (*aResult).top = (*aResult).left = (*aResult).bottom = (*aResult).right = 2;
       break;
-    case NS_THEME_STATUSBAR_PANEL:
-    case NS_THEME_STATUSBAR_RESIZER_PANEL: {
+    case NS_THEME_STATUSBARPANEL:
+    case NS_THEME_RESIZER_PANEL: {
       (*aResult).top = 1;      
       (*aResult).left = 1;
       (*aResult).bottom = 1;
       (*aResult).right = aFrame->GetNextSibling() ? 3 : 1;
       break;
     }    
     case NS_THEME_TOOLTIP:
       (*aResult).top = (*aResult).left = (*aResult).bottom = (*aResult).right = 1;
@@ -3008,30 +3008,30 @@ nsNativeThemeWin::ClassicGetMinimumWidge
       (*aResult).width = (*aResult).height = 13;
       break;
     case NS_THEME_MENUCHECKBOX:
     case NS_THEME_MENURADIO:
     case NS_THEME_MENUARROW:
       (*aResult).width = ::GetSystemMetrics(SM_CXMENUCHECK);
       (*aResult).height = ::GetSystemMetrics(SM_CYMENUCHECK);
       break;
-    case NS_THEME_SPINNER_UP_BUTTON:
-    case NS_THEME_SPINNER_DOWN_BUTTON:
+    case NS_THEME_SPINNER_UPBUTTON:
+    case NS_THEME_SPINNER_DOWNBUTTON:
       (*aResult).width = ::GetSystemMetrics(SM_CXVSCROLL);
       (*aResult).height = 8; // No good metrics available for this
       *aIsOverridable = false;
       break;
-    case NS_THEME_SCROLLBAR_BUTTON_UP:
-    case NS_THEME_SCROLLBAR_BUTTON_DOWN:
+    case NS_THEME_SCROLLBARBUTTON_UP:
+    case NS_THEME_SCROLLBARBUTTON_DOWN:
       (*aResult).width = ::GetSystemMetrics(SM_CXVSCROLL);
       (*aResult).height = ::GetSystemMetrics(SM_CYVSCROLL);
       *aIsOverridable = false;
       break;
-    case NS_THEME_SCROLLBAR_BUTTON_LEFT:
-    case NS_THEME_SCROLLBAR_BUTTON_RIGHT:
+    case NS_THEME_SCROLLBARBUTTON_LEFT:
+    case NS_THEME_SCROLLBARBUTTON_RIGHT:
       (*aResult).width = ::GetSystemMetrics(SM_CXHSCROLL);
       (*aResult).height = ::GetSystemMetrics(SM_CYHSCROLL);
       *aIsOverridable = false;
       break;
     case NS_THEME_SCROLLBAR_VERTICAL:
       // XXX HACK We should be able to have a minimum height for the scrollbar
       // track.  However, this causes problems when uncollapsing a scrollbar
       // inside a tree.  See bug 201379 for details.
@@ -3050,70 +3050,70 @@ nsNativeThemeWin::ClassicGetMinimumWidge
         (*aResult).height = 20;
       } else {
         (*aResult).width = 20;
         (*aResult).height = 12;
       }
       *aIsOverridable = false;
       break;
     }
-    case NS_THEME_SCALE_THUMB_HORIZONTAL:
+    case NS_THEME_SCALETHUMB_HORIZONTAL:
       (*aResult).width = 12;
       (*aResult).height = 20;
       *aIsOverridable = false;
       break;
-    case NS_THEME_SCALE_THUMB_VERTICAL:
+    case NS_THEME_SCALETHUMB_VERTICAL:
       (*aResult).width = 20;
       (*aResult).height = 12;
       *aIsOverridable = false;
       break;
-    case NS_THEME_DROPDOWN_BUTTON:
+    case NS_THEME_MENULIST_BUTTON:
       (*aResult).width = ::GetSystemMetrics(SM_CXVSCROLL);
       break;
-    case NS_THEME_DROPDOWN:
+    case NS_THEME_MENULIST:
     case NS_THEME_BUTTON:
     case NS_THEME_GROUPBOX:
     case NS_THEME_LISTBOX:
     case NS_THEME_TREEVIEW:
     case NS_THEME_NUMBER_INPUT:
     case NS_THEME_TEXTFIELD:
     case NS_THEME_TEXTFIELD_MULTILINE:
-    case NS_THEME_DROPDOWN_TEXTFIELD:      
+    case NS_THEME_MENULIST_TEXTFIELD:      
     case NS_THEME_STATUSBAR:
-    case NS_THEME_STATUSBAR_PANEL:      
-    case NS_THEME_STATUSBAR_RESIZER_PANEL:
-    case NS_THEME_PROGRESSBAR_CHUNK:
-    case NS_THEME_PROGRESSBAR_CHUNK_VERTICAL:
+    case NS_THEME_STATUSBARPANEL:      
+    case NS_THEME_RESIZER_PANEL:
+    case NS_THEME_PROGRESSCHUNK:
+    case NS_THEME_PROGRESSCHUNK_VERTICAL:
     case NS_THEME_TOOLTIP:
     case NS_THEME_PROGRESSBAR:
     case NS_THEME_PROGRESSBAR_VERTICAL:
     case NS_THEME_TAB:
-    case NS_THEME_TAB_PANEL:
-    case NS_THEME_TAB_PANELS:
+    case NS_THEME_TABPANEL:
+    case NS_THEME_TABPANELS:
       // no minimum widget size
       break;
     case NS_THEME_RESIZER: {     
       NONCLIENTMETRICS nc;
       nc.cbSize = sizeof(nc);
       if (SystemParametersInfo(SPI_GETNONCLIENTMETRICS, sizeof(nc), &nc, 0))
         (*aResult).width = (*aResult).height = abs(nc.lfStatusFont.lfHeight) + 4;
       else
         (*aResult).width = (*aResult).height = 15;
       *aIsOverridable = false;
       break;
-    case NS_THEME_SCROLLBAR_THUMB_VERTICAL:
+    case NS_THEME_SCROLLBARTHUMB_VERTICAL:
       (*aResult).width = ::GetSystemMetrics(SM_CXVSCROLL);
       (*aResult).height = ::GetSystemMetrics(SM_CYVTHUMB);
       // Without theming, divide the thumb size by two in order to look more
       // native
       if (!GetTheme(aWidgetType))
         (*aResult).height >>= 1;
       *aIsOverridable = false;
       break;
-    case NS_THEME_SCROLLBAR_THUMB_HORIZONTAL:
+    case NS_THEME_SCROLLBARTHUMB_HORIZONTAL:
       (*aResult).width = ::GetSystemMetrics(SM_CXHTHUMB);
       (*aResult).height = ::GetSystemMetrics(SM_CYHSCROLL);
       // Without theming, divide the thumb size by two in order to look more
       // native
       if (!GetTheme(aWidgetType))
         (*aResult).width >>= 1;
       *aIsOverridable = false;
       break;
@@ -3311,45 +3311,45 @@ nsresult nsNativeThemeWin::ClassicGetThe
       return NS_OK;
     }
     case NS_THEME_LISTBOX:
     case NS_THEME_TREEVIEW:
     case NS_THEME_NUMBER_INPUT:
     case NS_THEME_FOCUS_OUTLINE:
     case NS_THEME_TEXTFIELD:
     case NS_THEME_TEXTFIELD_MULTILINE:
-    case NS_THEME_DROPDOWN:
-    case NS_THEME_DROPDOWN_TEXTFIELD:
+    case NS_THEME_MENULIST:
+    case NS_THEME_MENULIST_TEXTFIELD:
     case NS_THEME_RANGE:
     case NS_THEME_RANGE_THUMB:
-    case NS_THEME_SCROLLBAR_THUMB_VERTICAL:
-    case NS_THEME_SCROLLBAR_THUMB_HORIZONTAL:     
+    case NS_THEME_SCROLLBARTHUMB_VERTICAL:
+    case NS_THEME_SCROLLBARTHUMB_HORIZONTAL:     
     case NS_THEME_SCROLLBAR_VERTICAL:
     case NS_THEME_SCROLLBAR_HORIZONTAL:      
     case NS_THEME_SCALE_HORIZONTAL:
     case NS_THEME_SCALE_VERTICAL:
-    case NS_THEME_SCALE_THUMB_HORIZONTAL:
-    case NS_THEME_SCALE_THUMB_VERTICAL:
+    case NS_THEME_SCALETHUMB_HORIZONTAL:
+    case NS_THEME_SCALETHUMB_VERTICAL:
     case NS_THEME_STATUSBAR:
-    case NS_THEME_STATUSBAR_PANEL:
-    case NS_THEME_STATUSBAR_RESIZER_PANEL:
-    case NS_THEME_PROGRESSBAR_CHUNK:
-    case NS_THEME_PROGRESSBAR_CHUNK_VERTICAL:
+    case NS_THEME_STATUSBARPANEL:
+    case NS_THEME_RESIZER_PANEL:
+    case NS_THEME_PROGRESSCHUNK:
+    case NS_THEME_PROGRESSCHUNK_VERTICAL:
     case NS_THEME_TOOLTIP:
     case NS_THEME_PROGRESSBAR:
     case NS_THEME_PROGRESSBAR_VERTICAL:
     case NS_THEME_TAB:
-    case NS_THEME_TAB_PANEL:
-    case NS_THEME_TAB_PANELS:
+    case NS_THEME_TABPANEL:
+    case NS_THEME_TABPANELS:
     case NS_THEME_MENUBAR:
     case NS_THEME_MENUPOPUP:
     case NS_THEME_GROUPBOX:
       // these don't use DrawFrameControl
       return NS_OK;
-    case NS_THEME_DROPDOWN_BUTTON: {
+    case NS_THEME_MENULIST_BUTTON: {
 
       aPart = DFC_SCROLL;
       aState = DFCS_SCROLLCOMBOBOX;
 
       nsIFrame* parentFrame = aFrame->GetParent();
       bool isHTML = IsHTMLContent(aFrame);
       bool isMenulist = !isHTML && parentFrame->GetType() == nsGkAtoms::menuFrame;
       bool isOpen = false;
@@ -3378,57 +3378,57 @@ nsresult nsNativeThemeWin::ClassicGetThe
         return NS_OK;
 
       // Dropdown button active state doesn't need :hover.
       if (eventState.HasState(NS_EVENT_STATE_ACTIVE))
         aState |= DFCS_PUSHED | DFCS_FLAT;
 
       return NS_OK;
     }
-    case NS_THEME_SCROLLBAR_BUTTON_UP:
-    case NS_THEME_SCROLLBAR_BUTTON_DOWN:
-    case NS_THEME_SCROLLBAR_BUTTON_LEFT:
-    case NS_THEME_SCROLLBAR_BUTTON_RIGHT: {
+    case NS_THEME_SCROLLBARBUTTON_UP:
+    case NS_THEME_SCROLLBARBUTTON_DOWN:
+    case NS_THEME_SCROLLBARBUTTON_LEFT:
+    case NS_THEME_SCROLLBARBUTTON_RIGHT: {
       EventStates contentState = GetContentState(aFrame, aWidgetType);
 
       aPart = DFC_SCROLL;
       switch (aWidgetType) {
-        case NS_THEME_SCROLLBAR_BUTTON_UP:
+        case NS_THEME_SCROLLBARBUTTON_UP:
           aState = DFCS_SCROLLUP;
           break;
-        case NS_THEME_SCROLLBAR_BUTTON_DOWN:
+        case NS_THEME_SCROLLBARBUTTON_DOWN:
           aState = DFCS_SCROLLDOWN;
           break;
-        case NS_THEME_SCROLLBAR_BUTTON_LEFT:
+        case NS_THEME_SCROLLBARBUTTON_LEFT:
           aState = DFCS_SCROLLLEFT;
           break;
-        case NS_THEME_SCROLLBAR_BUTTON_RIGHT:
+        case NS_THEME_SCROLLBARBUTTON_RIGHT:
           aState = DFCS_SCROLLRIGHT;
           break;
       }
 
       if (IsDisabled(aFrame, contentState))
         aState |= DFCS_INACTIVE;
       else {
         if (contentState.HasAllStates(NS_EVENT_STATE_HOVER | NS_EVENT_STATE_ACTIVE))
           aState |= DFCS_PUSHED | DFCS_FLAT;
       }
 
       return NS_OK;
     }
-    case NS_THEME_SPINNER_UP_BUTTON:
-    case NS_THEME_SPINNER_DOWN_BUTTON: {
+    case NS_THEME_SPINNER_UPBUTTON:
+    case NS_THEME_SPINNER_DOWNBUTTON: {
       EventStates contentState = GetContentState(aFrame, aWidgetType);
 
       aPart = DFC_SCROLL;
       switch (aWidgetType) {
-        case NS_THEME_SPINNER_UP_BUTTON:
+        case NS_THEME_SPINNER_UPBUTTON:
           aState = DFCS_SCROLLUP;
           break;
-        case NS_THEME_SPINNER_DOWN_BUTTON:
+        case NS_THEME_SPINNER_DOWNBUTTON:
           aState = DFCS_SCROLLDOWN;
           break;
       }
 
       if (IsDisabled(aFrame, contentState))
         aState |= DFCS_INACTIVE;
       else {
         if (contentState.HasAllStates(NS_EVENT_STATE_HOVER | NS_EVENT_STATE_ACTIVE))
@@ -3714,23 +3714,23 @@ RENDER_AGAIN:
           ::FrameRect(hdc, &widgetRect, brush);
         InflateRect(&widgetRect, -1, -1);
       }
       // fall-through...
     }
     // Draw controls supported by DrawFrameControl
     case NS_THEME_CHECKBOX:
     case NS_THEME_RADIO:
-    case NS_THEME_SCROLLBAR_BUTTON_UP:
-    case NS_THEME_SCROLLBAR_BUTTON_DOWN:
-    case NS_THEME_SCROLLBAR_BUTTON_LEFT:
-    case NS_THEME_SCROLLBAR_BUTTON_RIGHT:
-    case NS_THEME_SPINNER_UP_BUTTON:
-    case NS_THEME_SPINNER_DOWN_BUTTON:
-    case NS_THEME_DROPDOWN_BUTTON:
+    case NS_THEME_SCROLLBARBUTTON_UP:
+    case NS_THEME_SCROLLBARBUTTON_DOWN:
+    case NS_THEME_SCROLLBARBUTTON_LEFT:
+    case NS_THEME_SCROLLBARBUTTON_RIGHT:
+    case NS_THEME_SPINNER_UPBUTTON:
+    case NS_THEME_SPINNER_DOWNBUTTON:
+    case NS_THEME_MENULIST_BUTTON:
     case NS_THEME_RESIZER: {
       int32_t oldTA;
       // setup DC to make DrawFrameControl draw correctly
       oldTA = ::SetTextAlign(hdc, TA_TOP | TA_LEFT | TA_NOUPDATECP);
       ::DrawFrameControl(hdc, &widgetRect, part, state);
       ::SetTextAlign(hdc, oldTA);
 
       // Draw focus rectangles for HTML checkboxes and radio buttons
@@ -3748,18 +3748,18 @@ RENDER_AGAIN:
       }
       break;
     }
     // Draw controls with 2px 3D inset border
     case NS_THEME_NUMBER_INPUT:
     case NS_THEME_TEXTFIELD:
     case NS_THEME_TEXTFIELD_MULTILINE:
     case NS_THEME_LISTBOX:
-    case NS_THEME_DROPDOWN:
-    case NS_THEME_DROPDOWN_TEXTFIELD: {
+    case NS_THEME_MENULIST:
+    case NS_THEME_MENULIST_TEXTFIELD: {
       // Draw inset edge
       ::DrawEdge(hdc, &widgetRect, EDGE_SUNKEN, BF_RECT | BF_ADJUST);
       EventStates eventState = GetContentState(aFrame, aWidgetType);
 
       // Fill in background
       if (IsDisabled(aFrame, eventState) ||
           (aFrame->GetContent()->IsXULElement() &&
            IsReadOnly(aFrame)))
@@ -3791,41 +3791,41 @@ RENDER_AGAIN:
       break;
     // Draw 3D face background controls
     case NS_THEME_PROGRESSBAR:
     case NS_THEME_PROGRESSBAR_VERTICAL:
       // Draw 3D border
       ::DrawEdge(hdc, &widgetRect, BDR_SUNKENOUTER, BF_RECT | BF_MIDDLE);
       InflateRect(&widgetRect, -1, -1);
       // fall through
-    case NS_THEME_TAB_PANEL:
+    case NS_THEME_TABPANEL:
     case NS_THEME_STATUSBAR:
-    case NS_THEME_STATUSBAR_RESIZER_PANEL: {
+    case NS_THEME_RESIZER_PANEL: {
       ::FillRect(hdc, &widgetRect, (HBRUSH) (COLOR_BTNFACE+1));
 
       break;
     }
     // Draw 3D inset statusbar panel
-    case NS_THEME_STATUSBAR_PANEL: {
+    case NS_THEME_STATUSBARPANEL: {
       if (aFrame->GetNextSibling())
         widgetRect.right -= 2; // space between sibling status panels
 
       ::DrawEdge(hdc, &widgetRect, BDR_SUNKENOUTER, BF_RECT | BF_MIDDLE);
 
       break;
     }
     // Draw scrollbar thumb
-    case NS_THEME_SCROLLBAR_THUMB_VERTICAL:
-    case NS_THEME_SCROLLBAR_THUMB_HORIZONTAL:
+    case NS_THEME_SCROLLBARTHUMB_VERTICAL:
+    case NS_THEME_SCROLLBARTHUMB_HORIZONTAL:
       ::DrawEdge(hdc, &widgetRect, EDGE_RAISED, BF_RECT | BF_MIDDLE);
 
       break;
     case NS_THEME_RANGE_THUMB:
-    case NS_THEME_SCALE_THUMB_VERTICAL:
-    case NS_THEME_SCALE_THUMB_HORIZONTAL: {
+    case NS_THEME_SCALETHUMB_VERTICAL:
+    case NS_THEME_SCALETHUMB_HORIZONTAL: {
       EventStates eventState = GetContentState(aFrame, aWidgetType);
 
       ::DrawEdge(hdc, &widgetRect, EDGE_RAISED, BF_RECT | BF_SOFT | BF_MIDDLE | BF_ADJUST);
       if (IsDisabled(aFrame, eventState)) {
         DrawCheckedRect(hdc, widgetRect, COLOR_3DFACE, COLOR_3DHILIGHT,
                         (HBRUSH) COLOR_3DHILIGHT);
       }
 
@@ -3878,27 +3878,27 @@ RENDER_AGAIN:
         }
       }
 
       ::DrawEdge(hdc, &widgetRect, EDGE_SUNKEN, BF_RECT | BF_ADJUST);
       ::FillRect(hdc, &widgetRect, (HBRUSH) GetStockObject(GRAY_BRUSH));
  
       break;
     }
-    case NS_THEME_PROGRESSBAR_CHUNK_VERTICAL:
+    case NS_THEME_PROGRESSCHUNK_VERTICAL:
       ::FillRect(hdc, &widgetRect, (HBRUSH) (COLOR_HIGHLIGHT+1));
       break;
 
-    case NS_THEME_PROGRESSBAR_CHUNK: {
+    case NS_THEME_PROGRESSCHUNK: {
       nsIFrame* stateFrame = aFrame->GetParent();
       EventStates eventStates = GetContentState(stateFrame, aWidgetType);
 
       bool indeterminate = IsIndeterminateProgress(stateFrame, eventStates);
       bool vertical = IsVerticalProgress(stateFrame) ||
-                      aWidgetType == NS_THEME_PROGRESSBAR_CHUNK_VERTICAL;
+                      aWidgetType == NS_THEME_PROGRESSCHUNK_VERTICAL;
 
       nsIContent* content = aFrame->GetContent();
       if (!indeterminate || !content) {
         ::FillRect(hdc, &widgetRect, (HBRUSH) (COLOR_HIGHLIGHT+1));
         break;
       }
 
       RECT overlayRect =
@@ -3918,17 +3918,17 @@ RENDER_AGAIN:
       DrawTab(hdc, widgetRect,
         IsBottomTab(aFrame) ? BF_BOTTOM : BF_TOP, 
         IsSelectedTab(aFrame),
         !IsRightToSelectedTab(aFrame),
         !IsLeftToSelectedTab(aFrame));
 
       break;
     }
-    case NS_THEME_TAB_PANELS:
+    case NS_THEME_TABPANELS:
       ::DrawEdge(hdc, &widgetRect, EDGE_RAISED, BF_SOFT | BF_MIDDLE |
           BF_LEFT | BF_RIGHT | BF_BOTTOM);
 
       break;
     case NS_THEME_MENUBAR:
       break;
     case NS_THEME_MENUPOPUP:
       NS_ASSERTION(nsUXThemeData::sFlatMenus, "Classic menus are styled entirely through CSS");
@@ -4114,63 +4114,63 @@ nsNativeThemeWin::GetWidgetNativeDrawing
 {
   switch (aWidgetType) {
     case NS_THEME_BUTTON:
     case NS_THEME_NUMBER_INPUT:
     case NS_THEME_FOCUS_OUTLINE:
     case NS_THEME_TEXTFIELD:
     case NS_THEME_TEXTFIELD_MULTILINE:
 
-    case NS_THEME_DROPDOWN:
-    case NS_THEME_DROPDOWN_TEXTFIELD:
+    case NS_THEME_MENULIST:
+    case NS_THEME_MENULIST_TEXTFIELD:
       return
         gfxWindowsNativeDrawing::CANNOT_DRAW_TO_COLOR_ALPHA |
         gfxWindowsNativeDrawing::CAN_AXIS_ALIGNED_SCALE |
         gfxWindowsNativeDrawing::CANNOT_COMPLEX_TRANSFORM;
 
     // need to check these others
     case NS_THEME_RANGE:
     case NS_THEME_RANGE_THUMB:
-    case NS_THEME_SCROLLBAR_BUTTON_UP:
-    case NS_THEME_SCROLLBAR_BUTTON_DOWN:
-    case NS_THEME_SCROLLBAR_BUTTON_LEFT:
-    case NS_THEME_SCROLLBAR_BUTTON_RIGHT:
-    case NS_THEME_SCROLLBAR_THUMB_VERTICAL:
-    case NS_THEME_SCROLLBAR_THUMB_HORIZONTAL:
+    case NS_THEME_SCROLLBARBUTTON_UP:
+    case NS_THEME_SCROLLBARBUTTON_DOWN:
+    case NS_THEME_SCROLLBARBUTTON_LEFT:
+    case NS_THEME_SCROLLBARBUTTON_RIGHT:
+    case NS_THEME_SCROLLBARTHUMB_VERTICAL:
+    case NS_THEME_SCROLLBARTHUMB_HORIZONTAL:
     case NS_THEME_SCROLLBAR_VERTICAL:
     case NS_THEME_SCROLLBAR_HORIZONTAL:
     case NS_THEME_SCALE_HORIZONTAL:
     case NS_THEME_SCALE_VERTICAL:
-    case NS_THEME_SCALE_THUMB_HORIZONTAL:
-    case NS_THEME_SCALE_THUMB_VERTICAL:
-    case NS_THEME_SPINNER_UP_BUTTON:
-    case NS_THEME_SPINNER_DOWN_BUTTON:
+    case NS_THEME_SCALETHUMB_HORIZONTAL:
+    case NS_THEME_SCALETHUMB_VERTICAL:
+    case NS_THEME_SPINNER_UPBUTTON:
+    case NS_THEME_SPINNER_DOWNBUTTON:
     case NS_THEME_LISTBOX:
     case NS_THEME_TREEVIEW:
     case NS_THEME_TOOLTIP:
     case NS_THEME_STATUSBAR:
-    case NS_THEME_STATUSBAR_PANEL:
-    case NS_THEME_STATUSBAR_RESIZER_PANEL:
+    case NS_THEME_STATUSBARPANEL:
+    case NS_THEME_RESIZER_PANEL:
     case NS_THEME_RESIZER:
     case NS_THEME_PROGRESSBAR:
     case NS_THEME_PROGRESSBAR_VERTICAL:
-    case NS_THEME_PROGRESSBAR_CHUNK:
-    case NS_THEME_PROGRESSBAR_CHUNK_VERTICAL:
+    case NS_THEME_PROGRESSCHUNK:
+    case NS_THEME_PROGRESSCHUNK_VERTICAL:
     case NS_THEME_TAB:
-    case NS_THEME_TAB_PANEL:
-    case NS_THEME_TAB_PANELS:
+    case NS_THEME_TABPANEL:
+    case NS_THEME_TABPANELS:
     case NS_THEME_MENUBAR:
     case NS_THEME_MENUPOPUP:
     case NS_THEME_MENUITEM:
       break;
 
     // the dropdown button /almost/ renders correctly with scaling,
     // except that the graphic in the dropdown button (the downward arrow)
     // doesn't get scaled up.
-    case NS_THEME_DROPDOWN_BUTTON:
+    case NS_THEME_MENULIST_BUTTON:
     // these are definitely no; they're all graphics that don't get scaled up
     case NS_THEME_CHECKBOX:
     case NS_THEME_RADIO:
     case NS_THEME_GROUPBOX:
     case NS_THEME_CHECKMENUITEM:
     case NS_THEME_RADIOMENUITEM:
     case NS_THEME_MENUCHECKBOX:
     case NS_THEME_MENURADIO: