Merge Quotes and CounterData storage types into ValuePairList. (Bug 322475) r+sr=bzbarsky
authorL. David Baron <dbaron@dbaron.org>
Mon, 04 Aug 2008 15:15:11 -0700
changeset 16372 6ad2e5aa3c6448851c1d6c4cb3b55faa8eca1276
parent 16371 85a9eb44b2400c1fc25bbe91e9b9723da8f2a6a0
child 16373 5034907cae2a05eb0b8beb348122a7b9729041f1
push idunknown
push userunknown
push dateunknown
bugs322475
milestone1.9.1a2pre
Merge Quotes and CounterData storage types into ValuePairList. (Bug 322475) r+sr=bzbarsky
layout/style/nsCSSDataBlock.cpp
layout/style/nsCSSDeclaration.cpp
layout/style/nsCSSParser.cpp
layout/style/nsCSSPropList.h
layout/style/nsCSSProperty.h
layout/style/nsCSSStruct.cpp
layout/style/nsCSSStruct.h
layout/style/nsHTMLCSSStyleSheet.cpp
layout/style/nsRuleNode.cpp
--- a/layout/style/nsCSSDataBlock.cpp
+++ b/layout/style/nsCSSDataBlock.cpp
@@ -43,20 +43,20 @@
 #include "nsCSSDataBlock.h"
 #include "nsCSSProps.h"
 #include "nsRuleData.h"
 #include "nsRuleNode.h"
 #include "nsStyleSet.h"
 
 /*
  * nsCSSCompressedDataBlock holds property-value pairs corresponding to
- * CSS declaration blocks.  The value is stored in one of the six CSS
- * data types.  These six types are nsCSSValue, nsCSSRect,
- * nsCSSValueList, nsCSSCounterData, nsCSSQuotes, and nsCSSValuePair, and
- * each correspond to a value of the nsCSSType enumeration.
+ * CSS declaration blocks.  The value is stored in one of the five CSS
+ * data types: nsCSSValue, nsCSSRect, nsCSSValueList, nsCSSValuePair,
+ * and nsCSSValuePairList, which each correspond to a value of the
+ * nsCSSType enumeration.
  *
  * The storage strategy uses the CDB*Storage structs below to help
  * ensure that all the types remain properly aligned.  nsCSSValue's
  * alignment requirements cannot be weaker than any others, since it
  * contains a pointer and an enumeration.
  *
  * The simple types, nsCSSValue and nsCSSRect have the nsCSSValue or
  * nsCSSRect objects stored in the block.  The list types have only a
@@ -147,33 +147,23 @@ inline nsCSSValueList*& ValueListAtCurso
                              (& reinterpret_cast<CDBPointerStorage*>(aCursor)->value);
 }
 
 inline nsCSSValueList* ValueListAtCursor(const char *aCursor) {
     return static_cast<nsCSSValueList*>
                       (reinterpret_cast<const CDBPointerStorage*>(aCursor)->value);
 }
 
-inline nsCSSCounterData*& CounterDataAtCursor(char *aCursor) {
-    return * reinterpret_cast<nsCSSCounterData**>
+inline nsCSSValuePairList*& ValuePairListAtCursor(char *aCursor) {
+    return * reinterpret_cast<nsCSSValuePairList**>
                              (& reinterpret_cast<CDBPointerStorage*>(aCursor)->value);
 }
 
-inline nsCSSCounterData* CounterDataAtCursor(const char *aCursor) {
-    return static_cast<nsCSSCounterData*>
-                      (reinterpret_cast<const CDBPointerStorage*>(aCursor)->value);
-}
-
-inline nsCSSQuotes*& QuotesAtCursor(char *aCursor) {
-    return * reinterpret_cast<nsCSSQuotes**>
-                             (& reinterpret_cast<CDBPointerStorage*>(aCursor)->value);
-}
-
-inline nsCSSQuotes* QuotesAtCursor(const char *aCursor) {
-    return static_cast<nsCSSQuotes*>
+inline nsCSSValuePairList* ValuePairListAtCursor(const char *aCursor) {
+    return static_cast<nsCSSValuePairList*>
                       (reinterpret_cast<const CDBPointerStorage*>(aCursor)->value);
 }
 
 static PRBool
 ShouldIgnoreColors(nsRuleData *aRuleData)
 {
     return aRuleData->mLevel != nsStyleSet::eAgentSheet &&
            aRuleData->mLevel != nsStyleSet::eUserSheet &&
@@ -305,18 +295,17 @@ nsCSSCompressedDataBlock::MapRuleInfoInt
                                 nsCSSValue& val =
                                     l->mValue.GetArrayValue()->Item(0);
                                 if (val.GetUnit() == eCSSUnit_URL)
                                     val.StartImageLoad(
                                       aRuleData->mPresContext->Document());
                             }
                     }
                 // fall through
-                case eCSSType_CounterData:
-                case eCSSType_Quotes: {
+                case eCSSType_ValuePairList: {
                     void** target = static_cast<void**>(prop);
                     if (!*target) {
                         void* val = PointerAtCursor(cursor);
                         NS_ASSERTION(val, "oops");
                         *target = val;
 
                         if (iProp == eCSSProperty_border_top_colors ||
                             iProp == eCSSProperty_border_right_colors ||
@@ -340,18 +329,17 @@ nsCSSCompressedDataBlock::MapRuleInfoInt
                     cursor += CDBRectStorage_advance;
                 } break;
 
                 case eCSSType_ValuePair: {
                     cursor += CDBValuePairStorage_advance;
                 } break;
 
                 case eCSSType_ValueList:
-                case eCSSType_CounterData:
-                case eCSSType_Quotes: {
+                case eCSSType_ValuePairList: {
                     cursor += CDBPointerStorage_advance;
                 } break;
             }
         }
     }
     NS_ASSERTION(cursor == cursor_end, "inconsistent data");
 
     return NS_OK;
@@ -381,18 +369,17 @@ nsCSSCompressedDataBlock::StorageFor(nsC
                 }
                 case eCSSType_Rect: {
                     return RectAtCursor(cursor);
                 }
                 case eCSSType_ValuePair: {
                     return ValuePairAtCursor(cursor);
                 }
                 case eCSSType_ValueList:
-                case eCSSType_CounterData:
-                case eCSSType_Quotes: {
+                case eCSSType_ValuePairList: {
                     return &PointerAtCursor(const_cast<char*>(cursor));
                 }
             }
         }
         switch (nsCSSProps::kTypeTable[iProp]) {
             case eCSSType_Value: {
                 cursor += CDBValueStorage_advance;
             } break;
@@ -401,18 +388,17 @@ nsCSSCompressedDataBlock::StorageFor(nsC
                 cursor += CDBRectStorage_advance;
             } break;
 
             case eCSSType_ValuePair: {
                 cursor += CDBValuePairStorage_advance;
             } break;
 
             case eCSSType_ValueList:
-            case eCSSType_CounterData:
-            case eCSSType_Quotes: {
+            case eCSSType_ValuePairList: {
                 cursor += CDBPointerStorage_advance;
             } break;
         }
     }
     NS_ASSERTION(cursor == cursor_end, "inconsistent data");
 
     return nsnull;
 }
@@ -460,34 +446,29 @@ nsCSSCompressedDataBlock::Clone() const
                              val->mYValue.GetUnit() != eCSSUnit_Null, "oops");
                 nsCSSValuePair* result_val = ValuePairAtCursor(result_cursor);
                 new (result_val) nsCSSValuePair(*val);
                 cursor += CDBValuePairStorage_advance;
                 result_cursor += CDBValuePairStorage_advance;
             } break;
 
             case eCSSType_ValueList:
-            case eCSSType_CounterData:
-            case eCSSType_Quotes: {
+            case eCSSType_ValuePairList: {
                 void *copy;
                 NS_ASSERTION(PointerAtCursor(cursor), "oops");
                 switch (nsCSSProps::kTypeTable[iProp]) {
                     default:
                         NS_NOTREACHED("unreachable");
                         // fall through to keep gcc's uninitialized
                         // variable warning quiet
                     case eCSSType_ValueList:
                         copy = new nsCSSValueList(*ValueListAtCursor(cursor));
                         break;
-                    case eCSSType_CounterData:
-                        copy =
-                            new nsCSSCounterData(*CounterDataAtCursor(cursor));
-                        break;
-                    case eCSSType_Quotes:
-                        copy = new nsCSSQuotes(*QuotesAtCursor(cursor));
+                    case eCSSType_ValuePairList:
+                        copy = new nsCSSValuePairList(*ValuePairListAtCursor(cursor));
                         break;
                 }
                 if (!copy) {
                     result->mBlockEnd = result_cursor;
                     result->Destroy();
                     return nsnull;
                 }
                 PointerAtCursor(result_cursor) = copy;
@@ -539,25 +520,18 @@ nsCSSCompressedDataBlock::Destroy()
 
             case eCSSType_ValueList: {
                 nsCSSValueList* val = ValueListAtCursor(cursor);
                 NS_ASSERTION(val, "oops");
                 delete val;
                 cursor += CDBPointerStorage_advance;
             } break;
 
-            case eCSSType_CounterData: {
-                nsCSSCounterData* val = CounterDataAtCursor(cursor);
-                NS_ASSERTION(val, "oops");
-                delete val;
-                cursor += CDBPointerStorage_advance;
-            } break;
-
-            case eCSSType_Quotes: {
-                nsCSSQuotes* val = QuotesAtCursor(cursor);
+            case eCSSType_ValuePairList: {
+                nsCSSValuePairList* val = ValuePairListAtCursor(cursor);
                 NS_ASSERTION(val, "oops");
                 delete val;
                 cursor += CDBPointerStorage_advance;
             } break;
         }
     }
     NS_ASSERTION(cursor == cursor_end, "inconsistent data");
     delete this;
@@ -664,18 +638,17 @@ nsCSSExpandedDataBlock::DoExpand(nsCSSCo
 #ifdef NS_BUILD_REFCNT_LOGGING
                 dest->~nsCSSValuePair();
 #endif
                 memcpy(dest, val, sizeof(nsCSSValuePair));
                 cursor += CDBValuePairStorage_advance;
             } break;
 
             case eCSSType_ValueList:
-            case eCSSType_CounterData:
-            case eCSSType_Quotes: {
+            case eCSSType_ValuePairList: {
                 void* val = PointerAtCursor(cursor);
                 void** dest = static_cast<void**>(prop);
                 NS_ASSERTION(val, "oops");
                 NS_ASSERTION(!*dest, "expanding into non-empty block");
                 *dest = val;
                 cursor += CDBPointerStorage_advance;
             } break;
         }
@@ -741,18 +714,17 @@ nsCSSExpandedDataBlock::ComputeSize()
                     NS_ASSERTION(val->mXValue.GetUnit() != eCSSUnit_Null ||
                                  val->mYValue.GetUnit() != eCSSUnit_Null,
                                  "Valueless pair while computing size");
 #endif
                     increment = CDBValuePairStorage_advance;
                 } break;
 
                 case eCSSType_ValueList:
-                case eCSSType_CounterData:
-                case eCSSType_Quotes: {
+                case eCSSType_ValuePairList: {
 #ifdef DEBUG
                     void* val = *static_cast<void**>(prop);
                     NS_ASSERTION(val, "Null pointer while computing size");
 #endif
                     increment = CDBPointerStorage_advance;
                 } break;
             }
             if ((mPropertiesImportant[iHigh] & (1 << iLow)) == 0)
@@ -849,18 +821,17 @@ nsCSSExpandedDataBlock::Compress(nsCSSCo
                         reinterpret_cast<CDBValuePairStorage*>(cursor);
                     storage->property = iProp;
                     memcpy(&storage->value, val, sizeof(nsCSSValuePair));
                     new (val) nsCSSValuePair();
                     cursor += CDBValuePairStorage_advance;
                 } break;
 
                 case eCSSType_ValueList:
-                case eCSSType_CounterData:
-                case eCSSType_Quotes: {
+                case eCSSType_ValuePairList: {
                     void*& val = *static_cast<void**>(prop);
                     NS_ASSERTION(val, "Null pointer while compressing");
                     CDBPointerStorage *storage =
                         reinterpret_cast<CDBPointerStorage*>(cursor);
                     storage->property = iProp;
                     storage->value = val;
                     val = nsnull;
                     cursor += CDBPointerStorage_advance;
@@ -934,27 +905,19 @@ nsCSSExpandedDataBlock::ClearProperty(ns
         case eCSSType_ValueList: {
             nsCSSValueList*& val = *static_cast<nsCSSValueList**>(prop);
             if (val) {
                 delete val;
                 val = nsnull;
             }
         } break;
 
-        case eCSSType_CounterData: {
-            nsCSSCounterData*& val =
-                *static_cast<nsCSSCounterData**>(prop);
-            if (val) {
-                delete val;
-                val = nsnull;
-            }
-        } break;
-
-        case eCSSType_Quotes: {
-            nsCSSQuotes*& val = *static_cast<nsCSSQuotes**>(prop);
+        case eCSSType_ValuePairList: {
+            nsCSSValuePairList*& val =
+              *static_cast<nsCSSValuePairList**>(prop);
             if (val) {
                 delete val;
                 val = nsnull;
             }
         } break;
     }
 }
 
@@ -999,22 +962,17 @@ nsCSSExpandedDataBlock::DoAssertInitialS
                              "not initial state");
             } break;
 
             case eCSSType_ValueList: {
                 nsCSSValueList* val = *static_cast<nsCSSValueList**>(prop);
                 NS_ASSERTION(val == nsnull, "not initial state");
             } break;
 
-            case eCSSType_CounterData: {
-                nsCSSCounterData* val =
-                    *static_cast<nsCSSCounterData**>(prop);
-                NS_ASSERTION(val == nsnull, "not initial state");
-            } break;
-
-            case eCSSType_Quotes: {
-                nsCSSQuotes* val = *static_cast<nsCSSQuotes**>(prop);
+            case eCSSType_ValuePairList: {
+                nsCSSValuePairList* val =
+                  *static_cast<nsCSSValuePairList**>(prop);
                 NS_ASSERTION(val == nsnull, "not initial state");
             } break;
         }
     }
 }
 #endif
--- a/layout/style/nsCSSDeclaration.cpp
+++ b/layout/style/nsCSSDeclaration.cpp
@@ -250,55 +250,32 @@ PRBool nsCSSDeclaration::AppendValueToSt
                 || aProperty == eCSSProperty_stroke_dasharray
 #endif
                )
               aResult.Append(PRUnichar(','));
             aResult.Append(PRUnichar(' '));
           }
         } while (val);
       } break;
-      case eCSSType_CounterData: {
-        const nsCSSCounterData* counter =
-            *static_cast<nsCSSCounterData*const*>(storage);
+      case eCSSType_ValuePairList: {
+        const nsCSSValuePairList* item =
+            *static_cast<nsCSSValuePairList*const*>(storage);
         do {
-          if (AppendCSSValueToString(aProperty, counter->mCounter, aResult)) {
-            if (counter->mValue.GetUnit() != eCSSUnit_Null) {
-              aResult.Append(PRUnichar(' '));
-              AppendCSSValueToString(aProperty, counter->mValue, aResult);
-            }
+          NS_ASSERTION(item->mXValue.GetUnit() != eCSSUnit_Null,
+                       "unexpected null unit");
+          AppendCSSValueToString(aProperty, item->mXValue, aResult);
+          if (item->mYValue.GetUnit() != eCSSUnit_Null) {
+            aResult.Append(PRUnichar(' '));
+            AppendCSSValueToString(aProperty, item->mYValue, aResult);
           }
-          counter = counter->mNext;
-          if (counter) {
+          item = item->mNext;
+          if (item) {
             aResult.Append(PRUnichar(' '));
           }
-        } while (counter);
-      } break;
-      case eCSSType_Quotes: {
-        const nsCSSQuotes* quotes = 
-            *static_cast<nsCSSQuotes*const*>(storage);
-        NS_ASSERTION((quotes->mOpen.GetUnit() == eCSSUnit_String) ||
-                     (quotes->mNext == nsnull),
-                     "non-strings must be alone");
-        do {
-          AppendCSSValueToString(aProperty, quotes->mOpen, aResult);
-          NS_ASSERTION((quotes->mOpen.GetUnit() == eCSSUnit_String) ==
-                       (quotes->mClose.GetUnit() == eCSSUnit_String),
-                       "strings must come in pairs");
-          NS_ASSERTION((quotes->mOpen.GetUnit() != eCSSUnit_String) ==
-                       (quotes->mClose.GetUnit() == eCSSUnit_Null),
-                       "non-strings must be alone");
-          if (quotes->mClose.GetUnit() != eCSSUnit_Null) {
-            aResult.Append(PRUnichar(' '));
-            AppendCSSValueToString(aProperty, quotes->mClose, aResult);
-          }
-          quotes = quotes->mNext;
-          if (quotes) {
-            aResult.Append(PRUnichar(' '));
-          }
-        } while (quotes);
+        } while (item);
       } break;
     }
   }
   return storage != nsnull;
 }
 
 /* static */ PRBool
 nsCSSDeclaration::AppendCSSValueToString(nsCSSProperty aProperty,
--- a/layout/style/nsCSSParser.cpp
+++ b/layout/style/nsCSSParser.cpp
@@ -405,17 +405,17 @@ protected:
   PRBool ParseBorderRadius(nsresult& aErrorCode);
   PRBool ParseOutlineRadius(nsresult& aErrorCode);
   // for 'clip' and '-moz-image-region'
   PRBool ParseRect(nsCSSRect& aRect, nsresult& aErrorCode,
                    nsCSSProperty aPropID);
   PRBool DoParseRect(nsCSSRect& aRect, nsresult& aErrorCode);
   PRBool ParseContent(nsresult& aErrorCode);
   PRBool ParseCounterData(nsresult& aErrorCode,
-                          nsCSSCounterData** aResult,
+                          nsCSSValuePairList** aResult,
                           nsCSSProperty aPropID);
   PRBool ParseCue(nsresult& aErrorCode);
   PRBool ParseCursor(nsresult& aErrorCode);
   PRBool ParseFont(nsresult& aErrorCode);
   PRBool ParseFontWeight(nsresult& aErrorCode, nsCSSValue& aValue);
   PRBool ParseFamily(nsresult& aErrorCode, nsCSSValue& aValue);
   PRBool ParseListStyle(nsresult& aErrorCode);
   PRBool ParseMargin(nsresult& aErrorCode);
@@ -3923,30 +3923,22 @@ CSSParserImpl::DoTransferTempData(nsCSSD
       nsCSSValueList **dest = static_cast<nsCSSValueList**>(v_dest);
       if (!nsCSSValueList::Equal(*source, *dest))
         *aChanged = PR_TRUE;
       delete *dest;
       *dest = *source;
       *source = nsnull;
     } break;
 
-    case eCSSType_CounterData: {
-      nsCSSCounterData **source = static_cast<nsCSSCounterData**>(v_source);
-      nsCSSCounterData **dest = static_cast<nsCSSCounterData**>(v_dest);
-      if (!nsCSSCounterData::Equal(*source, *dest))
-        *aChanged = PR_TRUE;
-      delete *dest;
-      *dest = *source;
-      *source = nsnull;
-    } break;
-
-    case eCSSType_Quotes: {
-      nsCSSQuotes **source = static_cast<nsCSSQuotes**>(v_source);
-      nsCSSQuotes **dest = static_cast<nsCSSQuotes**>(v_dest);
-      if (!nsCSSQuotes::Equal(*source, *dest))
+    case eCSSType_ValuePairList: {
+      nsCSSValuePairList **source =
+        static_cast<nsCSSValuePairList**>(v_source);
+      nsCSSValuePairList **dest =
+        static_cast<nsCSSValuePairList**>(v_dest);
+      if (!nsCSSValuePairList::Equal(*source, *dest))
         *aChanged = PR_TRUE;
       delete *dest;
       *dest = *source;
       *source = nsnull;
     } break;
   }
 }
 
@@ -6168,64 +6160,64 @@ PRBool CSSParserImpl::ParseContent(nsres
 }
 
 struct SingleCounterPropValue {
   char str[13];
   nsCSSUnit unit;
 };
 
 PRBool CSSParserImpl::ParseCounterData(nsresult& aErrorCode,
-                                       nsCSSCounterData** aResult,
+                                       nsCSSValuePairList** aResult,
                                        nsCSSProperty aPropID)
 {
   nsSubstring* ident = NextIdent(aErrorCode);
   if (nsnull == ident) {
     return PR_FALSE;
   }
   static const SingleCounterPropValue singleValues[] = {
     { "none", eCSSUnit_None },
     { "inherit", eCSSUnit_Inherit },
     { "-moz-initial", eCSSUnit_Initial }
   };
   for (const SingleCounterPropValue *sv = singleValues,
            *sv_end = singleValues + NS_ARRAY_LENGTH(singleValues);
        sv != sv_end; ++sv) {
     if (ident->LowerCaseEqualsASCII(sv->str)) {
       if (ExpectEndProperty(aErrorCode)) {
-        nsCSSCounterData* dataHead = new nsCSSCounterData();
+        nsCSSValuePairList* dataHead = new nsCSSValuePairList();
         if (!dataHead) {
           aErrorCode = NS_ERROR_OUT_OF_MEMORY;
           return PR_FALSE;
         }
-        dataHead->mCounter = nsCSSValue(sv->unit);
+        dataHead->mXValue = nsCSSValue(sv->unit);
         *aResult = dataHead;
         mTempData.SetPropertyBit(aPropID);
         return PR_TRUE;
       }
       return PR_FALSE;
     }
   }
   UngetToken(); // undo NextIdent
 
-  nsCSSCounterData* dataHead = nsnull;
-  nsCSSCounterData **next = &dataHead;
+  nsCSSValuePairList* dataHead = nsnull;
+  nsCSSValuePairList **next = &dataHead;
   for (;;) {
     if (!GetToken(aErrorCode, PR_TRUE) || mToken.mType != eCSSToken_Ident) {
       break;
     }
-    nsCSSCounterData *data = *next = new nsCSSCounterData();
+    nsCSSValuePairList *data = *next = new nsCSSValuePairList();
     if (!data) {
       aErrorCode = NS_ERROR_OUT_OF_MEMORY;
       break;
     }
     next = &data->mNext;
-    data->mCounter.SetStringValue(mToken.mIdent, eCSSUnit_String);
+    data->mXValue.SetStringValue(mToken.mIdent, eCSSUnit_String);
     if (GetToken(aErrorCode, PR_TRUE)) {
       if (eCSSToken_Number == mToken.mType && mToken.mIntegerValid) {
-        data->mValue.SetIntValue(mToken.mInteger, eCSSUnit_Integer);
+        data->mYValue.SetIntValue(mToken.mInteger, eCSSUnit_Integer);
       } else {
         UngetToken();
       }
     }
     if (ExpectEndProperty(aErrorCode)) {
       mTempData.SetPropertyBit(aPropID);
       *aResult = dataHead;
       aErrorCode = NS_OK;
@@ -6694,51 +6686,52 @@ PRBool CSSParserImpl::ParsePause(nsresul
   return PR_FALSE;
 }
 
 PRBool CSSParserImpl::ParseQuotes(nsresult& aErrorCode)
 {
   nsCSSValue  open;
   if (ParseVariant(aErrorCode, open, VARIANT_HOS, nsnull)) {
     if (eCSSUnit_String == open.GetUnit()) {
-      nsCSSQuotes* quotesHead = new nsCSSQuotes();
-      nsCSSQuotes* quotes = quotesHead;
+      nsCSSValuePairList* quotesHead = new nsCSSValuePairList();
+      nsCSSValuePairList* quotes = quotesHead;
       if (nsnull == quotes) {
         aErrorCode = NS_ERROR_OUT_OF_MEMORY;
         return PR_FALSE;
       }
-      quotes->mOpen = open;
+      quotes->mXValue = open;
       while (nsnull != quotes) {
         // get mandatory close
-        if (ParseVariant(aErrorCode, quotes->mClose, VARIANT_STRING, nsnull)) {
+        if (ParseVariant(aErrorCode, quotes->mYValue, VARIANT_STRING,
+                         nsnull)) {
           if (ExpectEndProperty(aErrorCode)) {
             mTempData.SetPropertyBit(eCSSProperty_quotes);
             mTempData.mContent.mQuotes = quotesHead;
             aErrorCode = NS_OK;
             return PR_TRUE;
           }
           // look for another open
           if (ParseVariant(aErrorCode, open, VARIANT_STRING, nsnull)) {
-            quotes->mNext = new nsCSSQuotes();
+            quotes->mNext = new nsCSSValuePairList();
             quotes = quotes->mNext;
             if (nsnull != quotes) {
-              quotes->mOpen = open;
+              quotes->mXValue = open;
               continue;
             }
             aErrorCode = NS_ERROR_OUT_OF_MEMORY;
           }
         }
         break;
       }
       delete quotesHead;
       return PR_FALSE;
     }
     if (ExpectEndProperty(aErrorCode)) {
-      nsCSSQuotes* quotesHead = new nsCSSQuotes();
-      quotesHead->mOpen = open;
+      nsCSSValuePairList* quotesHead = new nsCSSValuePairList();
+      quotesHead->mXValue = open;
       mTempData.mContent.mQuotes = quotesHead;
       mTempData.SetPropertyBit(eCSSProperty_quotes);
       return PR_TRUE;
     }
   }
   return PR_FALSE;
 }
 
--- a/layout/style/nsCSSPropList.h
+++ b/layout/style/nsCSSPropList.h
@@ -376,18 +376,18 @@ CSS_PROP_COLOR(color, color, Color, Colo
 CSS_PROP_COLUMN(-moz-column-count, _moz_column_count, MozColumnCount, Column, mColumnCount, eCSSType_Value, nsnull)
 CSS_PROP_COLUMN(-moz-column-width, _moz_column_width, MozColumnWidth, Column, mColumnWidth, eCSSType_Value, nsnull)
 CSS_PROP_COLUMN(-moz-column-gap, _moz_column_gap, MozColumnGap, Column, mColumnGap, eCSSType_Value, nsnull)
 CSS_PROP_SHORTHAND(-moz-column-rule, _moz_column_rule, MozColumnRule)
 CSS_PROP_COLUMN(-moz-column-rule-color, _moz_column_rule_color, MozColumnRuleColor, Column, mColumnRuleColor, eCSSType_Value, nsnull)
 CSS_PROP_COLUMN(-moz-column-rule-style, _moz_column_rule_style, MozColumnRuleStyle, Column, mColumnRuleStyle, eCSSType_Value, kBorderStyleKTable)
 CSS_PROP_COLUMN(-moz-column-rule-width, _moz_column_rule_width, MozColumnRuleWidth, Column, mColumnRuleWidth, eCSSType_Value, kBorderWidthKTable)
 CSS_PROP_CONTENT(content, content, Content, Content, mContent, eCSSType_ValueList, kContentKTable)
-CSS_PROP_CONTENT(counter-increment, counter_increment, CounterIncrement, Content, mCounterIncrement, eCSSType_CounterData, nsnull) // XXX bug 137285
-CSS_PROP_CONTENT(counter-reset, counter_reset, CounterReset, Content, mCounterReset, eCSSType_CounterData, nsnull) // XXX bug 137285
+CSS_PROP_CONTENT(counter-increment, counter_increment, CounterIncrement, Content, mCounterIncrement, eCSSType_ValuePairList, nsnull) // XXX bug 137285
+CSS_PROP_CONTENT(counter-reset, counter_reset, CounterReset, Content, mCounterReset, eCSSType_ValuePairList, nsnull) // XXX bug 137285
 CSS_PROP_SHORTHAND(cue, cue, Cue)
 CSS_PROP_BACKENDONLY(cue-after, cue_after, CueAfter, Aural, mCueAfter, eCSSType_Value, nsnull)
 CSS_PROP_BACKENDONLY(cue-before, cue_before, CueBefore, Aural, mCueBefore, eCSSType_Value, nsnull)
 CSS_PROP_USERINTERFACE(cursor, cursor, Cursor, UserInterface, mCursor, eCSSType_ValueList, kCursorKTable)
 CSS_PROP_VISIBILITY(direction, direction, Direction, Display, mDirection, eCSSType_Value, kDirectionKTable)
 CSS_PROP_DISPLAY(display, display, Display, Display, mDisplay, eCSSType_Value, kDisplayKTable)
 CSS_PROP_BACKENDONLY(elevation, elevation, Elevation, Aural, mElevation, eCSSType_Value, kElevationKTable)
 CSS_PROP_TABLEBORDER(empty-cells, empty_cells, EmptyCells, Table, mEmptyCells, eCSSType_Value, kEmptyCellsKTable)
@@ -479,17 +479,17 @@ CSS_PROP_DISPLAY(page-break-after, page_
 CSS_PROP_DISPLAY(page-break-before, page_break_before, PageBreakBefore, Display, mBreakBefore, eCSSType_Value, kPageBreakKTable) // temp fix for bug 24000
 CSS_PROP_BACKENDONLY(page-break-inside, page_break_inside, PageBreakInside, Breaks, mPageBreakInside, eCSSType_Value, kPageBreakInsideKTable)
 CSS_PROP_SHORTHAND(pause, pause, Pause)
 CSS_PROP_BACKENDONLY(pause-after, pause_after, PauseAfter, Aural, mPauseAfter, eCSSType_Value, nsnull)
 CSS_PROP_BACKENDONLY(pause-before, pause_before, PauseBefore, Aural, mPauseBefore, eCSSType_Value, nsnull)
 CSS_PROP_BACKENDONLY(pitch, pitch, Pitch, Aural, mPitch, eCSSType_Value, kPitchKTable)
 CSS_PROP_BACKENDONLY(pitch-range, pitch_range, PitchRange, Aural, mPitchRange, eCSSType_Value, nsnull)
 CSS_PROP_DISPLAY(position, position, Position, Display, mPosition, eCSSType_Value, kPositionKTable)
-CSS_PROP_QUOTES(quotes, quotes, Quotes, Content, mQuotes, eCSSType_Quotes, nsnull)
+CSS_PROP_QUOTES(quotes, quotes, Quotes, Content, mQuotes, eCSSType_ValuePairList, nsnull)
 CSS_PROP_BACKENDONLY(richness, richness, Richness, Aural, mRichness, eCSSType_Value, nsnull)
 CSS_PROP_POSITION(right, right, Right, Position, mOffset.mRight, eCSSType_Value, nsnull)
 CSS_PROP_BACKENDONLY(size, size, Size, Page, mSize, eCSSType_ValuePair, kPageSizeKTable)
 CSS_PROP_BACKENDONLY(speak, speak, Speak, Aural, mSpeak, eCSSType_Value, kSpeakKTable)
 CSS_PROP_BACKENDONLY(speak-header, speak_header, SpeakHeader, Aural, mSpeakHeader, eCSSType_Value, kSpeakHeaderKTable)
 CSS_PROP_BACKENDONLY(speak-numeral, speak_numeral, SpeakNumeral, Aural, mSpeakNumeral, eCSSType_Value, kSpeakNumeralKTable)
 CSS_PROP_BACKENDONLY(speak-punctuation, speak_punctuation, SpeakPunctuation, Aural, mSpeakPunctuation, eCSSType_Value, kSpeakPunctuationKTable)
 CSS_PROP_BACKENDONLY(speech-rate, speech_rate, SpeechRate, Aural, mSpeechRate, eCSSType_Value, kSpeechRateKTable)
--- a/layout/style/nsCSSProperty.h
+++ b/layout/style/nsCSSProperty.h
@@ -67,13 +67,12 @@ enum nsCSSProperty {
 
 // The types of values that can be in the nsCSS*/nsRuleData* structs.
 // See nsCSSPropList.h for uses.
 enum nsCSSType {
   eCSSType_Value,
   eCSSType_Rect,
   eCSSType_ValuePair,
   eCSSType_ValueList,
-  eCSSType_CounterData,
-  eCSSType_Quotes
+  eCSSType_ValuePairList
 };
 
 #endif /* nsCSSProperty_h___ */
--- a/layout/style/nsCSSStruct.cpp
+++ b/layout/style/nsCSSStruct.cpp
@@ -294,83 +294,48 @@ nsCSSPage::nsCSSPage(void)
 
 nsCSSPage::~nsCSSPage(void)
 {
   MOZ_COUNT_DTOR(nsCSSPage);
 }
 
 // --- nsCSSContent support -----------------
 
-nsCSSCounterData::nsCSSCounterData(void)
+nsCSSValuePairList::nsCSSValuePairList()
   : mNext(nsnull)
 {
-  MOZ_COUNT_CTOR(nsCSSCounterData);
+  MOZ_COUNT_CTOR(nsCSSValuePairList);
 }
 
-nsCSSCounterData::nsCSSCounterData(const nsCSSCounterData& aCopy)
-  : mCounter(aCopy.mCounter),
-    mValue(aCopy.mValue),
+nsCSSValuePairList::nsCSSValuePairList(const nsCSSValuePairList& aCopy)
+  : mXValue(aCopy.mXValue),
+    mYValue(aCopy.mYValue),
     mNext(nsnull)
 {
-  MOZ_COUNT_CTOR(nsCSSCounterData);
-  CSS_IF_COPY(mNext, nsCSSCounterData);
+  MOZ_COUNT_CTOR(nsCSSValuePairList);
+  CSS_IF_COPY(mNext, nsCSSValuePairList);
 }
 
-nsCSSCounterData::~nsCSSCounterData(void)
+nsCSSValuePairList::~nsCSSValuePairList()
 {
-  MOZ_COUNT_DTOR(nsCSSCounterData);
+  MOZ_COUNT_DTOR(nsCSSValuePairList);
   CSS_IF_DELETE(mNext);
 }
 
 /* static */ PRBool
-nsCSSCounterData::Equal(nsCSSCounterData* aList1, nsCSSCounterData* aList2)
+nsCSSValuePairList::Equal(nsCSSValuePairList* aList1,
+                          nsCSSValuePairList* aList2)
 {
   if (aList1 == aList2)
     return PR_TRUE;
 
-  nsCSSCounterData *p1 = aList1, *p2 = aList2;
+  nsCSSValuePairList *p1 = aList1, *p2 = aList2;
   for ( ; p1 && p2; p1 = p1->mNext, p2 = p2->mNext) {
-    if (p1->mCounter != p2->mCounter ||
-        p1->mValue != p2->mValue)
-      return PR_FALSE;
-  }
-  return !p1 && !p2; // true if same length, false otherwise
-}
-
-nsCSSQuotes::nsCSSQuotes(void)
-  : mNext(nsnull)
-{
-  MOZ_COUNT_CTOR(nsCSSQuotes);
-}
-
-nsCSSQuotes::nsCSSQuotes(const nsCSSQuotes& aCopy)
-  : mOpen(aCopy.mOpen),
-    mClose(aCopy.mClose),
-    mNext(nsnull)
-{
-  MOZ_COUNT_CTOR(nsCSSQuotes);
-  CSS_IF_COPY(mNext, nsCSSQuotes);
-}
-
-nsCSSQuotes::~nsCSSQuotes(void)
-{
-  MOZ_COUNT_DTOR(nsCSSQuotes);
-  CSS_IF_DELETE(mNext);
-}
-
-/* static */ PRBool
-nsCSSQuotes::Equal(nsCSSQuotes* aList1, nsCSSQuotes* aList2)
-{
-  if (aList1 == aList2)
-    return PR_TRUE;
-
-  nsCSSQuotes *p1 = aList1, *p2 = aList2;
-  for ( ; p1 && p2; p1 = p1->mNext, p2 = p2->mNext) {
-    if (p1->mOpen != p2->mOpen ||
-        p1->mClose != p2->mClose)
+    if (p1->mXValue != p2->mXValue ||
+        p1->mYValue != p2->mYValue)
       return PR_FALSE;
   }
   return !p1 && !p2; // true if same length, false otherwise
 }
 
 // --- nsCSSContent -----------------
 
 nsCSSContent::nsCSSContent(void)
--- a/layout/style/nsCSSStruct.h
+++ b/layout/style/nsCSSStruct.h
@@ -149,40 +149,27 @@ struct nsCSSValueListRect {
   nsCSSValueList* mRight;
   nsCSSValueList* mBottom;
   nsCSSValueList* mLeft;
 
   typedef nsCSSValueList* nsCSSValueListRect::*side_type;
   static const side_type sides[4];
 };
 
-// Should be replaced with nsCSSValueList and nsCSSValue::Array.
-struct nsCSSCounterData {
-  nsCSSCounterData(void);
-  nsCSSCounterData(const nsCSSCounterData& aCopy);
-  ~nsCSSCounterData(void);
-
-  static PRBool Equal(nsCSSCounterData* aList1, nsCSSCounterData* aList2);
+// Maybe should be replaced with nsCSSValueList and nsCSSValue::Array?
+struct nsCSSValuePairList {
+  nsCSSValuePairList(void);
+  nsCSSValuePairList(const nsCSSValuePairList& aCopy);
+  ~nsCSSValuePairList(void);
 
-  nsCSSValue        mCounter;
-  nsCSSValue        mValue;
-  nsCSSCounterData* mNext;
-};
+  static PRBool Equal(nsCSSValuePairList* aList1, nsCSSValuePairList* aList2);
 
-// Should be replaced with nsCSSValueList and nsCSSValue::Array.
-struct nsCSSQuotes {
-  nsCSSQuotes(void);
-  nsCSSQuotes(const nsCSSQuotes& aCopy);
-  ~nsCSSQuotes(void);
-
-  static PRBool Equal(nsCSSQuotes* aList1, nsCSSQuotes* aList2);
-
-  nsCSSValue    mOpen;
-  nsCSSValue    mClose;
-  nsCSSQuotes*  mNext;
+  nsCSSValue          mXValue;
+  nsCSSValue          mYValue;
+  nsCSSValuePairList* mNext;
 };
 
 /****************************************************************************/
 
 struct nsCSSStruct {
   // EMPTY on purpose.  ABSTRACT with no virtuals (typedef void nsCSSStruct?)
 };
 
@@ -468,21 +455,21 @@ struct nsRuleDataPage : public nsCSSPage
 private:
   nsRuleDataPage(const nsRuleDataPage& aOther); // NOT IMPLEMENTED
 };
 
 struct nsCSSContent : public nsCSSStruct  {
   nsCSSContent(void);
   ~nsCSSContent(void);
 
-  nsCSSValueList*   mContent;
-  nsCSSCounterData* mCounterIncrement;
-  nsCSSCounterData* mCounterReset;
-  nsCSSValue        mMarkerOffset;
-  nsCSSQuotes*      mQuotes;
+  nsCSSValueList*     mContent;
+  nsCSSValuePairList* mCounterIncrement;
+  nsCSSValuePairList* mCounterReset;
+  nsCSSValue          mMarkerOffset;
+  nsCSSValuePairList* mQuotes;
 private:
   nsCSSContent(const nsCSSContent& aOther); // NOT IMPLEMENTED
 };
 
 struct nsRuleDataContent : public nsCSSContent {
   nsRuleDataContent() {}
 private:
   nsRuleDataContent(const nsRuleDataContent& aOther); // NOT IMPLEMENTED
--- a/layout/style/nsHTMLCSSStyleSheet.cpp
+++ b/layout/style/nsHTMLCSSStyleSheet.cpp
@@ -76,27 +76,27 @@ public:
   // functions.
   void CommonMapRuleInfoInto(nsRuleData* aRuleData);
 
 #ifdef DEBUG
   NS_IMETHOD List(FILE* out = stdout, PRInt32 aIndent = 0) const;
 #endif
 protected:
   nsCSSValueList mInheritList;
-  nsCSSQuotes mInheritQuotes;
-  nsCSSCounterData mNoneCounter;
+  nsCSSValuePairList mInheritQuotes;
+  nsCSSValuePairList mNoneCounter;
 };
 
 CSSDisablePropsRule::CSSDisablePropsRule()
 {
   nsCSSValue none(eCSSUnit_None);
-  mNoneCounter.mCounter = none;
+  mNoneCounter.mXValue = none;
   nsCSSValue inherit(eCSSUnit_Inherit);
   mInheritList.mValue = inherit;
-  mInheritQuotes.mOpen = inherit;
+  mInheritQuotes.mXValue = inherit;
 }
 
 class CSSFirstLineRule : public CSSDisablePropsRule {
 public:
   CSSFirstLineRule() {}
 
   NS_IMETHOD MapRuleInfoInto(nsRuleData* aRuleData);
 };
--- a/layout/style/nsRuleNode.cpp
+++ b/layout/style/nsRuleNode.cpp
@@ -961,27 +961,20 @@ ValueListAtOffset(const nsRuleDataStruct
 
 inline const nsCSSValueList**
 ValueListArrayAtOffset(const nsRuleDataStruct& aRuleDataStruct, size_t aOffset)
 {
   return * reinterpret_cast<const nsCSSValueList**const*>
                            (reinterpret_cast<const char*>(&aRuleDataStruct) + aOffset);
 }
 
-inline const nsCSSCounterData*
-CounterDataAtOffset(const nsRuleDataStruct& aRuleDataStruct, size_t aOffset)
+inline const nsCSSValuePairList*
+ValuePairListAtOffset(const nsRuleDataStruct& aRuleDataStruct, size_t aOffset)
 {
-  return * reinterpret_cast<const nsCSSCounterData*const*>
-                           (reinterpret_cast<const char*>(&aRuleDataStruct) + aOffset);
-}
-
-inline const nsCSSQuotes*
-QuotesAtOffset(const nsRuleDataStruct& aRuleDataStruct, size_t aOffset)
-{
-  return * reinterpret_cast<const nsCSSQuotes*const*>
+  return * reinterpret_cast<const nsCSSValuePairList*const*>
                            (reinterpret_cast<const char*>(&aRuleDataStruct) + aOffset);
 }
 
 #if defined(MOZ_MATHML) && defined(DEBUG)
 static PRBool
 AreAllMathMLPropertiesUndefined(const nsCSSFont& aRuleData)
 {
   return aRuleData.mScriptLevel.GetUnit() == eCSSUnit_Null &&
@@ -1035,38 +1028,24 @@ nsRuleNode::CheckSpecifiedProperties(con
             ++specified;
             if (eCSSUnit_Inherit == valueList->mValue.GetUnit()) {
               ++inherited;
             }
           }
         }
         break;
 
-      case eCSSType_CounterData:
+      case eCSSType_ValuePairList:
         {
           ++total;
-          const nsCSSCounterData* counterData =
-              CounterDataAtOffset(aRuleDataStruct, prop->offset);
-          if (counterData) {
-            ++specified;
-            if (eCSSUnit_Inherit == counterData->mCounter.GetUnit()) {
-              ++inherited;
-            }
-          }
-        }
-        break;
-
-      case eCSSType_Quotes:
-        {
-          ++total;
-          const nsCSSQuotes* quotes =
-              QuotesAtOffset(aRuleDataStruct, prop->offset);
+          const nsCSSValuePairList* quotes =
+              ValuePairListAtOffset(aRuleDataStruct, prop->offset);
           if (quotes) {
             ++specified;
-            if (eCSSUnit_Inherit == quotes->mOpen.GetUnit()) {
+            if (eCSSUnit_Inherit == quotes->mXValue.GetUnit()) {
               ++inherited;
             }
           }
         }
         break;
 
       default:
         NS_NOTREACHED("unknown type");
@@ -4483,94 +4462,94 @@ nsRuleNode::ComputeContentData(void* aSt
           }
           contentValue = contentValue->mNext;
         }
       } 
     }
   }
 
   // counter-increment: [string [int]]+, none, inherit
-  nsCSSCounterData* ourIncrement = contentData.mCounterIncrement;
+  nsCSSValuePairList* ourIncrement = contentData.mCounterIncrement;
   if (ourIncrement) {
-    if (eCSSUnit_None == ourIncrement->mCounter.GetUnit() ||
-        eCSSUnit_Initial == ourIncrement->mCounter.GetUnit()) {
+    if (eCSSUnit_None == ourIncrement->mXValue.GetUnit() ||
+        eCSSUnit_Initial == ourIncrement->mXValue.GetUnit()) {
       content->AllocateCounterIncrements(0);
     }
-    else if (eCSSUnit_Inherit == ourIncrement->mCounter.GetUnit()) {
+    else if (eCSSUnit_Inherit == ourIncrement->mXValue.GetUnit()) {
       inherited = PR_TRUE;
       count = parentContent->CounterIncrementCount();
       if (NS_SUCCEEDED(content->AllocateCounterIncrements(count))) {
         while (0 < count--) {
           const nsStyleCounterData *data =
             parentContent->GetCounterIncrementAt(count);
           content->SetCounterIncrementAt(count, data->mCounter, data->mValue);
         }
       }
     }
-    else if (eCSSUnit_String == ourIncrement->mCounter.GetUnit()) {
+    else if (eCSSUnit_String == ourIncrement->mXValue.GetUnit()) {
       count = 0;
       while (ourIncrement) {
         count++;
         ourIncrement = ourIncrement->mNext;
       }
       if (NS_SUCCEEDED(content->AllocateCounterIncrements(count))) {
         count = 0;
         ourIncrement = contentData.mCounterIncrement;
         while (ourIncrement) {
           PRInt32 increment;
-          if (eCSSUnit_Integer == ourIncrement->mValue.GetUnit()) {
-            increment = ourIncrement->mValue.GetIntValue();
+          if (eCSSUnit_Integer == ourIncrement->mYValue.GetUnit()) {
+            increment = ourIncrement->mYValue.GetIntValue();
           }
           else {
             increment = 1;
           }
-          ourIncrement->mCounter.GetStringValue(buffer);
+          ourIncrement->mXValue.GetStringValue(buffer);
           content->SetCounterIncrementAt(count++, buffer, increment);
           ourIncrement = ourIncrement->mNext;
         }
       }
     }
   }
 
   // counter-reset: [string [int]]+, none, inherit
-  nsCSSCounterData* ourReset = contentData.mCounterReset;
+  nsCSSValuePairList* ourReset = contentData.mCounterReset;
   if (ourReset) {
-    if (eCSSUnit_None == ourReset->mCounter.GetUnit() ||
-        eCSSUnit_Initial == ourReset->mCounter.GetUnit()) {
+    if (eCSSUnit_None == ourReset->mXValue.GetUnit() ||
+        eCSSUnit_Initial == ourReset->mXValue.GetUnit()) {
       content->AllocateCounterResets(0);
     }
-    else if (eCSSUnit_Inherit == ourReset->mCounter.GetUnit()) {
+    else if (eCSSUnit_Inherit == ourReset->mXValue.GetUnit()) {
       inherited = PR_TRUE;
       count = parentContent->CounterResetCount();
       if (NS_SUCCEEDED(content->AllocateCounterResets(count))) {
         while (0 < count--) {
           const nsStyleCounterData *data =
             parentContent->GetCounterResetAt(count);
           content->SetCounterResetAt(count, data->mCounter, data->mValue);
         }
       }
     }
-    else if (eCSSUnit_String == ourReset->mCounter.GetUnit()) {
+    else if (eCSSUnit_String == ourReset->mXValue.GetUnit()) {
       count = 0;
       while (ourReset) {
         count++;
         ourReset = ourReset->mNext;
       }
       if (NS_SUCCEEDED(content->AllocateCounterResets(count))) {
         count = 0;
         ourReset = contentData.mCounterReset;
         while (ourReset) {
           PRInt32 reset;
-          if (eCSSUnit_Integer == ourReset->mValue.GetUnit()) {
-            reset = ourReset->mValue.GetIntValue();
+          if (eCSSUnit_Integer == ourReset->mYValue.GetUnit()) {
+            reset = ourReset->mYValue.GetIntValue();
           }
           else {
             reset = 0;
           }
-          ourReset->mCounter.GetStringValue(buffer);
+          ourReset->mXValue.GetStringValue(buffer);
           content->SetCounterResetAt(count++, buffer, reset);
           ourReset = ourReset->mNext;
         }
       }
     }
   }
 
   // marker-offset: length, auto, inherit
@@ -4589,46 +4568,46 @@ nsRuleNode::ComputeQuotesData(void* aSta
                               const RuleDetail aRuleDetail, PRBool aInherited)
 {
   COMPUTE_START_INHERITED(Quotes, (), quotes, parentQuotes,
                           Content, contentData)
 
   // quotes: [string string]+, none, inherit
   PRUint32 count;
   nsAutoString  buffer;
-  nsCSSQuotes* ourQuotes = contentData.mQuotes;
+  nsCSSValuePairList* ourQuotes = contentData.mQuotes;
   if (ourQuotes) {
     nsAutoString  closeBuffer;
     // FIXME Bug 389406: Implement eCSSUnit_Initial (correctly, unlike
     // style structs), and remove the "initial" value from ua.css.
-    if (eCSSUnit_Inherit == ourQuotes->mOpen.GetUnit()) {
+    if (eCSSUnit_Inherit == ourQuotes->mXValue.GetUnit()) {
       inherited = PR_TRUE;
       count = parentQuotes->QuotesCount();
       if (NS_SUCCEEDED(quotes->AllocateQuotes(count))) {
         while (0 < count--) {
           parentQuotes->GetQuotesAt(count, buffer, closeBuffer);
           quotes->SetQuotesAt(count, buffer, closeBuffer);
         }
       }
     }
-    else if (eCSSUnit_None == ourQuotes->mOpen.GetUnit()) {
+    else if (eCSSUnit_None == ourQuotes->mXValue.GetUnit()) {
       quotes->AllocateQuotes(0);
     }
-    else if (eCSSUnit_String == ourQuotes->mOpen.GetUnit()) {
+    else if (eCSSUnit_String == ourQuotes->mXValue.GetUnit()) {
       count = 0;
       while (ourQuotes) {
         count++;
         ourQuotes = ourQuotes->mNext;
       }
       if (NS_SUCCEEDED(quotes->AllocateQuotes(count))) {
         count = 0;
         ourQuotes = contentData.mQuotes;
         while (ourQuotes) {
-          ourQuotes->mOpen.GetStringValue(buffer);
-          ourQuotes->mClose.GetStringValue(closeBuffer);
+          ourQuotes->mXValue.GetStringValue(buffer);
+          ourQuotes->mYValue.GetStringValue(closeBuffer);
           Unquote(buffer);
           Unquote(closeBuffer);
           quotes->SetQuotesAt(count++, buffer, closeBuffer);
           ourQuotes = ourQuotes->mNext;
         }
       }
     }
   }