PRUint32 i = 0; PRUint32 length = 0; const ComputedStyleMapEntry* propMap = GetQueryablePropertyMap(&length); for (; i < length; ++i) { if (prop == propMap[i].mProperty) {  rv = (this->*(propMap[i].mGetter))(frame, aReturn);
switch (prop) { case eCSSProperty_behavior : rv = GetBehavior(frame, *getter_AddRefs(val)); break; case eCSSProperty_display : rv = GetDisplay(frame, *getter_AddRefs(val)); break; case eCSSProperty_width : rv = GetWidth(frame, *getter_AddRefs(val)); break; case eCSSProperty_height : rv = GetHeight(frame, *getter_AddRefs(val)); break; case eCSSProperty_left : rv = GetLeft(frame, *getter_AddRefs(val)); break; case eCSSProperty_top : rv = GetTop(frame, *getter_AddRefs(val)); break; case eCSSProperty_right : rv = GetRight(frame, *getter_AddRefs(val)); break; case eCSSProperty_bottom : rv = GetBottom(frame, *getter_AddRefs(val)); break;   case eCSSProperty_color : rv = GetColor(frame, *getter_AddRefs(val)); break; case eCSSProperty_font_family : rv = GetFontFamily(frame, *getter_AddRefs(val)); break; case eCSSProperty_font_size : rv = GetFontSize(frame, *getter_AddRefs(val)); break; case eCSSProperty_font_style : rv = GetFontStyle(frame, *getter_AddRefs(val)); break; case eCSSProperty_font_weight : rv = GetFontWeight(frame, *getter_AddRefs(val)); break; case eCSSProperty_font_variant : rv = GetFontVariant(frame, *getter_AddRefs(val)); break;   case eCSSProperty_background_color : rv = GetBackgroundColor(frame, *getter_AddRefs(val)); break; case eCSSProperty_background_image : rv = GetBackgroundImage(frame, *getter_AddRefs(val)); break;   case eCSSProperty_padding : rv = GetPadding(frame, *getter_AddRefs(val)); break; case eCSSProperty_padding_top : rv = GetPaddingTop(frame, *getter_AddRefs(val)); break; case eCSSProperty_padding_bottom : rv = GetPaddingBottom(frame, *getter_AddRefs(val)); break; case eCSSProperty_padding_left : rv = GetPaddingLeft(frame, *getter_AddRefs(val)); break; case eCSSProperty_padding_right : rv = GetPaddingRight(frame, *getter_AddRefs(val)); break;   case eCSSProperty_border_collapse : rv = GetBorderCollapse(frame, *getter_AddRefs(val)); break; case eCSSProperty_border_top_style : rv = GetBorderTopStyle(frame, *getter_AddRefs(val)); break; case eCSSProperty_border_bottom_style : rv = GetBorderBottomStyle(frame, *getter_AddRefs(val)); break; case eCSSProperty_border_left_style : rv = GetBorderLeftStyle(frame, *getter_AddRefs(val)); break; case eCSSProperty_border_right_style : rv = GetBorderRightStyle(frame, *getter_AddRefs(val)); break; case eCSSProperty_border_top_width : rv = GetBorderTopWidth(frame, *getter_AddRefs(val)); break; case eCSSProperty_border_bottom_width : rv = GetBorderBottomWidth(frame, *getter_AddRefs(val)); break; case eCSSProperty_border_left_width : rv = GetBorderLeftWidth(frame, *getter_AddRefs(val)); break; case eCSSProperty_border_right_width : rv = GetBorderRightWidth(frame, *getter_AddRefs(val)); break; case eCSSProperty_border_top_color : rv = GetBorderTopColor(frame, *getter_AddRefs(val)); break; case eCSSProperty_border_bottom_color : rv = GetBorderBottomColor(frame, *getter_AddRefs(val)); break; case eCSSProperty_border_left_color : rv = GetBorderLeftColor(frame, *getter_AddRefs(val)); break; case eCSSProperty_border_right_color : rv = GetBorderRightColor(frame, *getter_AddRefs(val)); break;   case eCSSProperty_margin_top : rv = GetMarginTopWidth(frame, *getter_AddRefs(val)); break; case eCSSProperty_margin_bottom : rv = GetMarginBottomWidth(frame, *getter_AddRefs(val)); break; case eCSSProperty_margin_left : rv = GetMarginLeftWidth(frame, *getter_AddRefs(val)); break; case eCSSProperty_margin_right : rv = GetMarginRightWidth(frame, *getter_AddRefs(val)); break;   case eCSSProperty_marker_offset : rv = GetMarkerOffset(frame, *getter_AddRefs(val)); break;   case eCSSProperty_outline_width : rv = GetOutlineWidth(frame, *getter_AddRefs(val)); break; case eCSSProperty_outline_style : rv = GetOutlineStyle(frame, *getter_AddRefs(val)); break; case eCSSProperty_outline_color: rv = GetOutlineColor(frame, *getter_AddRefs(val)); break;   case eCSSProperty_text_align: rv = GetTextAlign(frame, *getter_AddRefs(val)); break; case eCSSProperty_text_decoration: rv = GetTextDecoration(frame, *getter_AddRefs(val)); break;   case eCSSProperty_list_style_image: rv = GetListStyleImage(frame, *getter_AddRefs(val)); break;   case eCSSProperty_z_index: rv = GetZIndex(frame, *getter_AddRefs(val)); break; default :
nsComputedDOMStyle::GetPropertyCSSValue(const nsAString& aPropertyName,                                        nsIDOMCSSValue** aReturn){  NS_ENSURE_ARG_POINTER(aReturn);  *aReturn = nsnull;  nsCOMPtr<nsIPresShell> presShell = do_QueryReferent(mPresShellWeak);  NS_ENSURE_TRUE(presShell, NS_ERROR_FAILURE);  nsIDocument* document = mContent->GetDocument();  if (document) {    document->FlushPendingNotifications(Flush_Style);  }  nsIFrame *frame = nsnull;  presShell->GetPrimaryFrameFor(mContent, &frame);  nsresult rv = NS_OK;  nsCSSProperty prop = nsCSSProps::LookupProperty(aPropertyName);  PRUint32 i = 0;  PRUint32 length = 0;  const ComputedStyleMapEntry* propMap = GetQueryablePropertyMap(&length);  for (; i < length; ++i) {    if (prop == propMap[i].mProperty) {      // Call our pointer-to-member-function.      rv = (this->*(propMap[i].mGetter))(frame, aReturn);      break;    }  }#ifdef DEBUG_ComputedDOMStyle  if (i == length) {    NS_WARNING(PromiseFlatCString(NS_ConvertUCS2toUTF8(aPropertyName) +                                   NS_LITERAL_CSTRING(" is not queryable!")).get());  }#endif  if (NS_FAILED(rv)) {    *aReturn = nsnull;  }  // Release the current style context for it should be re-resolved  // whenever a frame is not available.  mStyleContextHolder = nsnull;  return rv;}