Remove parsing and storage code for CSS 2.0 aural properties. (Bug 649119) r=bzbarsky

This commit is contained in:
L. David Baron 2011-04-21 20:17:32 -07:00
Родитель eac95bc5f3
Коммит 72447213b1
12 изменённых файлов: 14 добавлений и 635 удалений

Просмотреть файл

@ -50,12 +50,9 @@
* http://www.w3.org/TR/DOM-Level-2-Style
*/
[scriptable, uuid(cd0e6cfe-7278-49b2-a1d6-c2b87b6eb7e0)]
[scriptable, uuid(f28df617-ac8b-48e0-8094-c4642ab43940)]
interface nsIDOMCSS2Properties : nsISupports
{
attribute DOMString azimuth;
// raises(DOMException) on setting
attribute DOMString background;
// raises(DOMException) on setting
@ -182,15 +179,6 @@ interface nsIDOMCSS2Properties : nsISupports
attribute DOMString counterReset;
// raises(DOMException) on setting
attribute DOMString cue;
// raises(DOMException) on setting
attribute DOMString cueAfter;
// raises(DOMException) on setting
attribute DOMString cueBefore;
// raises(DOMException) on setting
attribute DOMString cursor;
// raises(DOMException) on setting
@ -200,9 +188,6 @@ interface nsIDOMCSS2Properties : nsISupports
attribute DOMString display;
// raises(DOMException) on setting
attribute DOMString elevation;
// raises(DOMException) on setting
attribute DOMString emptyCells;
// raises(DOMException) on setting
@ -335,54 +320,18 @@ interface nsIDOMCSS2Properties : nsISupports
attribute DOMString pageBreakInside;
// raises(DOMException) on setting
attribute DOMString pause;
// raises(DOMException) on setting
attribute DOMString pauseAfter;
// raises(DOMException) on setting
attribute DOMString pauseBefore;
// raises(DOMException) on setting
attribute DOMString pitch;
// raises(DOMException) on setting
attribute DOMString pitchRange;
// raises(DOMException) on setting
attribute DOMString position;
// raises(DOMException) on setting
attribute DOMString quotes;
// raises(DOMException) on setting
attribute DOMString richness;
// raises(DOMException) on setting
attribute DOMString right;
// raises(DOMException) on setting
attribute DOMString size;
// raises(DOMException) on setting
attribute DOMString speak;
// raises(DOMException) on setting
attribute DOMString speakHeader;
// raises(DOMException) on setting
attribute DOMString speakNumeral;
// raises(DOMException) on setting
attribute DOMString speakPunctuation;
// raises(DOMException) on setting
attribute DOMString speechRate;
// raises(DOMException) on setting
attribute DOMString stress;
// raises(DOMException) on setting
attribute DOMString tableLayout;
// raises(DOMException) on setting
@ -413,12 +362,6 @@ interface nsIDOMCSS2Properties : nsISupports
attribute DOMString visibility;
// raises(DOMException) on setting
attribute DOMString voiceFamily;
// raises(DOMException) on setting
attribute DOMString volume;
// raises(DOMException) on setting
attribute DOMString whiteSpace;
// raises(DOMException) on setting

Просмотреть файл

@ -483,14 +483,6 @@ Declaration::GetValue(nsCSSProperty aProperty, nsAString& aValue) const
AppendValueToString(eCSSProperty_background_color, aValue);
break;
}
case eCSSProperty_cue: {
if (AppendValueToString(eCSSProperty_cue_before, aValue)) {
aValue.Append(PRUnichar(' '));
if (!AppendValueToString(eCSSProperty_cue_after, aValue))
aValue.Truncate();
}
break;
}
case eCSSProperty_font: {
// systemFont might not be present; the others are guaranteed to be
// based on the shorthand check at the beginning of the function
@ -588,14 +580,6 @@ Declaration::GetValue(nsCSSProperty aProperty, nsAString& aValue) const
xValue.AppendToString(eCSSProperty_overflow_x, aValue);
break;
}
case eCSSProperty_pause: {
if (AppendValueToString(eCSSProperty_pause_before, aValue)) {
aValue.Append(PRUnichar(' '));
if (!AppendValueToString(eCSSProperty_pause_after, aValue))
aValue.Truncate();
}
break;
}
case eCSSProperty_transition: {
const nsCSSValue &transProp =
*data->ValueFor(eCSSProperty_transition_property);

Просмотреть файл

@ -180,7 +180,6 @@ CSS_KEY(-moz-window, _moz_window)
CSS_KEY(-moz-workspace, _moz_workspace)
CSS_KEY(-moz-zoom-in, _moz_zoom_in)
CSS_KEY(-moz-zoom-out, _moz_zoom_out)
CSS_KEY(above, above)
CSS_KEY(absolute, absolute)
CSS_KEY(active, active)
CSS_KEY(activeborder, activeborder)
@ -197,8 +196,6 @@ CSS_KEY(avoid, avoid)
CSS_KEY(background, background)
CSS_KEY(backwards, backwards)
CSS_KEY(baseline, baseline)
CSS_KEY(behind, behind)
CSS_KEY(below, below)
CSS_KEY(bidi-override, bidi_override)
CSS_KEY(blink, blink)
CSS_KEY(block, block)
@ -221,8 +218,6 @@ CSS_KEY(caption, caption)
CSS_KEY(captiontext, captiontext)
CSS_KEY(cell, cell)
CSS_KEY(center, center)
CSS_KEY(center-left, center_left)
CSS_KEY(center-right, center_right)
CSS_KEY(ch, ch)
CSS_KEY(circle, circle)
CSS_KEY(cjk-ideographic, cjk_ideographic)
@ -230,7 +225,6 @@ CSS_KEY(close-quote, close_quote)
CSS_KEY(closest-corner, closest_corner)
CSS_KEY(closest-side, closest_side)
CSS_KEY(cm, cm)
CSS_KEY(code, code)
CSS_KEY(col-resize, col_resize)
CSS_KEY(collapse, collapse)
CSS_KEY(condensed, condensed)
@ -250,7 +244,6 @@ CSS_KEY(decimal-leading-zero, decimal_leading_zero)
CSS_KEY(default, default)
CSS_KEY(deg, deg)
CSS_KEY(dialog, dialog)
CSS_KEY(digits, digits)
CSS_KEY(disabled, disabled)
CSS_KEY(disc, disc)
CSS_KEY(dotted, dotted)
@ -273,12 +266,8 @@ CSS_KEY(expanded, expanded)
CSS_KEY(extra-condensed, extra_condensed)
CSS_KEY(extra-expanded, extra_expanded)
CSS_KEY(ew-resize, ew_resize)
CSS_KEY(far-left, far_left)
CSS_KEY(far-right, far_right)
CSS_KEY(farthest-side, farthest_side)
CSS_KEY(farthest-corner, farthest_corner)
CSS_KEY(fast, fast)
CSS_KEY(faster, faster)
CSS_KEY(fill, fill)
CSS_KEY(fixed, fixed)
CSS_KEY(forwards, forwards)
@ -290,8 +279,6 @@ CSS_KEY(hebrew, hebrew)
CSS_KEY(help, help)
CSS_KEY(hidden, hidden)
CSS_KEY(hide, hide)
CSS_KEY(high, high)
CSS_KEY(higher, higher)
CSS_KEY(highlight, highlight)
CSS_KEY(highlighttext, highlighttext)
CSS_KEY(hiragana, hiragana)
@ -328,17 +315,11 @@ CSS_KEY(landscape, landscape)
CSS_KEY(large, large)
CSS_KEY(larger, larger)
CSS_KEY(left, left)
CSS_KEY(left-side, left_side)
CSS_KEY(leftwards, leftwards)
CSS_KEY(level, level)
CSS_KEY(lighter, lighter)
CSS_KEY(line-through, line_through)
CSS_KEY(linear, linear)
CSS_KEY(list-item, list_item)
CSS_KEY(logical, logical)
CSS_KEY(loud, loud)
CSS_KEY(low, low)
CSS_KEY(lower, lower)
CSS_KEY(lower-alpha, lower_alpha)
CSS_KEY(lower-greek, lower_greek)
CSS_KEY(lower-latin, lower_latin)
@ -372,7 +353,6 @@ CSS_KEY(ns-resize, ns_resize)
CSS_KEY(nw-resize, nw_resize)
CSS_KEY(nwse-resize, nwse_resize)
CSS_KEY(oblique, oblique)
CSS_KEY(once, once)
CSS_KEY(open-quote, open_quote)
CSS_KEY(outset, outset)
CSS_KEY(outside, outside)
@ -401,8 +381,6 @@ CSS_KEY(repeat-y, repeat_y)
CSS_KEY(reverse, reverse)
CSS_KEY(ridge, ridge)
CSS_KEY(right, right)
CSS_KEY(right-side, right_side)
CSS_KEY(rightwards, rightwards)
CSS_KEY(rotate, rotate)
CSS_KEY(round, round)
CSS_KEY(row-resize, row_resize)
@ -426,19 +404,15 @@ CSS_KEY(semi-condensed, semi_condensed)
CSS_KEY(semi-expanded, semi_expanded)
CSS_KEY(separate, separate)
CSS_KEY(show, show)
CSS_KEY(silent, silent)
CSS_KEY(skew, skew)
CSS_KEY(skewx, skewx)
CSS_KEY(skewy, skewy)
CSS_KEY(slow, slow)
CSS_KEY(slower, slower)
CSS_KEY(small, small)
CSS_KEY(small-caps, small_caps)
CSS_KEY(small-caption, small_caption)
CSS_KEY(smaller, smaller)
CSS_KEY(soft, soft)
CSS_KEY(solid, solid)
CSS_KEY(spell-out, spell_out)
CSS_KEY(square, square)
CSS_KEY(start, start)
CSS_KEY(static, static)
@ -499,14 +473,8 @@ CSS_KEY(window, window)
CSS_KEY(windowframe, windowframe)
CSS_KEY(windowtext, windowtext)
CSS_KEY(write-only, write_only)
CSS_KEY(x-fast, x_fast)
CSS_KEY(x-high, x_high)
CSS_KEY(x-large, x_large)
CSS_KEY(x-loud, x_loud)
CSS_KEY(x-low, x_low)
CSS_KEY(x-slow, x_slow)
CSS_KEY(x-small, x_small)
CSS_KEY(x-soft, x_soft)
CSS_KEY(xx-large, xx_large)
CSS_KEY(xx-small, xx_small)

Просмотреть файл

@ -453,7 +453,6 @@ protected:
void InitBoxPropsAsPhysical(const nsCSSProperty *aSourceProperties);
// Property specific parsing routines
PRBool ParseAzimuth(nsCSSValue& aValue);
PRBool ParseBackground();
struct BackgroundParseState {
@ -506,7 +505,6 @@ protected:
PRBool ParseRect(nsCSSProperty aPropID);
PRBool ParseContent();
PRBool ParseCounterData(nsCSSProperty aPropID);
PRBool ParseCue();
PRBool ParseCursor();
PRBool ParseFont();
PRBool ParseFontWeight(nsCSSValue& aValue);
@ -522,7 +520,6 @@ protected:
PRBool ParseOutline();
PRBool ParseOverflow();
PRBool ParsePadding();
PRBool ParsePause();
PRBool ParseQuotes();
PRBool ParseSize();
PRBool ParseTextDecoration(nsCSSValue& aValue);
@ -5523,8 +5520,6 @@ CSSParserImpl::ParsePropertyByFunction(nsCSSProperty aPropID)
case eCSSProperty_counter_increment:
case eCSSProperty_counter_reset:
return ParseCounterData(aPropID);
case eCSSProperty_cue:
return ParseCue();
case eCSSProperty_cursor:
return ParseCursor();
case eCSSProperty_font:
@ -5565,8 +5560,6 @@ CSSParserImpl::ParsePropertyByFunction(nsCSSProperty aPropID)
case eCSSProperty_padding_start:
return ParseDirectionalBoxProperty(eCSSProperty_padding_start,
NS_BOXPROP_SOURCE_LOGICAL);
case eCSSProperty_pause:
return ParsePause();
case eCSSProperty_quotes:
return ParseQuotes();
case eCSSProperty_size:
@ -5624,10 +5617,7 @@ CSSParserImpl::ParseSingleValueProperty(nsCSSValue& aValue,
if (nsCSSProps::PropHasFlags(aPropID, CSS_PROPERTY_VALUE_PARSER_FUNCTION)) {
switch (aPropID) {
case eCSSProperty_azimuth:
return ParseAzimuth(aValue);
case eCSSProperty_font_family:
case eCSSProperty_voice_family:
return ParseFamily(aValue);
case eCSSProperty_font_weight:
return ParseFontWeight(aValue);
@ -5776,36 +5766,6 @@ CSSParserImpl::InitBoxPropsAsPhysical(const nsCSSProperty *aSourceProperties)
}
}
PRBool
CSSParserImpl::ParseAzimuth(nsCSSValue& aValue)
{
if (ParseVariant(aValue, VARIANT_HK | VARIANT_ANGLE,
nsCSSProps::kAzimuthKTable)) {
if (eCSSUnit_Enumerated == aValue.GetUnit()) {
PRInt32 intValue = aValue.GetIntValue();
if ((NS_STYLE_AZIMUTH_LEFT_SIDE <= intValue) &&
(intValue <= NS_STYLE_AZIMUTH_BEHIND)) { // look for optional modifier
nsCSSValue modifier;
if (ParseEnum(modifier, nsCSSProps::kAzimuthKTable)) {
PRInt32 enumValue = modifier.GetIntValue();
if (((intValue == NS_STYLE_AZIMUTH_BEHIND) &&
(NS_STYLE_AZIMUTH_LEFT_SIDE <= enumValue) && (enumValue <= NS_STYLE_AZIMUTH_RIGHT_SIDE)) ||
((enumValue == NS_STYLE_AZIMUTH_BEHIND) &&
(NS_STYLE_AZIMUTH_LEFT_SIDE <= intValue) && (intValue <= NS_STYLE_AZIMUTH_RIGHT_SIDE))) {
aValue.SetIntValue(intValue | enumValue, eCSSUnit_Enumerated);
return PR_TRUE;
}
// Put the unknown identifier back and return
UngetToken();
return PR_FALSE;
}
}
}
return PR_TRUE;
}
return PR_FALSE;
}
static nsCSSValue
BoxPositionMaskToCSSValue(PRInt32 aMask, PRBool isX)
{
@ -7001,32 +6961,6 @@ CSSParserImpl::ParseCounterData(nsCSSProperty aPropID)
return PR_TRUE;
}
PRBool
CSSParserImpl::ParseCue()
{
nsCSSValue before;
if (ParseSingleValueProperty(before, eCSSProperty_cue_before)) {
if (eCSSUnit_Inherit != before.GetUnit() &&
eCSSUnit_Initial != before.GetUnit()) {
nsCSSValue after;
if (ParseSingleValueProperty(after, eCSSProperty_cue_after)) {
if (ExpectEndProperty()) {
AppendValue(eCSSProperty_cue_before, before);
AppendValue(eCSSProperty_cue_after, after);
return PR_TRUE;
}
return PR_FALSE;
}
}
if (ExpectEndProperty()) {
AppendValue(eCSSProperty_cue_before, before);
AppendValue(eCSSProperty_cue_after, before);
return PR_TRUE;
}
}
return PR_FALSE;
}
PRBool
CSSParserImpl::ParseCursor()
{
@ -7948,31 +7882,6 @@ CSSParserImpl::ParsePadding()
return ParseBoxProperties(kPaddingSideIDs);
}
PRBool
CSSParserImpl::ParsePause()
{
nsCSSValue before;
if (ParseSingleValueProperty(before, eCSSProperty_pause_before)) {
if (eCSSUnit_Inherit != before.GetUnit() && eCSSUnit_Initial != before.GetUnit()) {
nsCSSValue after;
if (ParseSingleValueProperty(after, eCSSProperty_pause_after)) {
if (ExpectEndProperty()) {
AppendValue(eCSSProperty_pause_before, before);
AppendValue(eCSSProperty_pause_after, after);
return PR_TRUE;
}
return PR_FALSE;
}
}
if (ExpectEndProperty()) {
AppendValue(eCSSProperty_pause_before, before);
AppendValue(eCSSProperty_pause_after, before);
return PR_TRUE;
}
}
return PR_FALSE;
}
PRBool
CSSParserImpl::ParseQuotes()
{

Просмотреть файл

@ -456,14 +456,6 @@ CSS_PROP_DISPLAY(
CSS_PROP_NO_OFFSET,
eStyleAnimType_None)
#endif
CSS_PROP_BACKENDONLY(
azimuth,
azimuth,
Azimuth,
CSS_PROPERTY_PARSE_VALUE |
CSS_PROPERTY_VALUE_PARSER_FUNCTION,
0,
kAzimuthKTable)
CSS_PROP_SHORTHAND(
background,
background,
@ -1332,25 +1324,6 @@ CSS_PROP_CONTENT(
nsnull,
CSS_PROP_NO_OFFSET,
eStyleAnimType_None) // XXX bug 137285
CSS_PROP_SHORTHAND(
cue,
cue,
Cue,
CSS_PROPERTY_PARSE_FUNCTION)
CSS_PROP_BACKENDONLY(
cue-after,
cue_after,
CueAfter,
CSS_PROPERTY_PARSE_VALUE,
VARIANT_HUO,
nsnull)
CSS_PROP_BACKENDONLY(
cue-before,
cue_before,
CueBefore,
CSS_PROPERTY_PARSE_VALUE,
VARIANT_HUO,
nsnull)
CSS_PROP_USERINTERFACE(
cursor,
cursor,
@ -1381,13 +1354,6 @@ CSS_PROP_DISPLAY(
kDisplayKTable,
offsetof(nsStyleDisplay, mDisplay),
eStyleAnimType_EnumU8)
CSS_PROP_BACKENDONLY(
elevation,
elevation,
Elevation,
CSS_PROPERTY_PARSE_VALUE,
VARIANT_HK | VARIANT_ANGLE,
kElevationKTable)
CSS_PROP_TABLEBORDER(
empty-cells,
empty_cells,
@ -2091,39 +2057,6 @@ CSS_PROP_BACKENDONLY(
CSS_PROPERTY_PARSE_VALUE,
VARIANT_HK,
kPageBreakInsideKTable)
CSS_PROP_SHORTHAND(
pause,
pause,
Pause,
CSS_PROPERTY_PARSE_FUNCTION)
CSS_PROP_BACKENDONLY(
pause-after,
pause_after,
PauseAfter,
CSS_PROPERTY_PARSE_VALUE,
VARIANT_HTP,
nsnull)
CSS_PROP_BACKENDONLY(
pause-before,
pause_before,
PauseBefore,
CSS_PROPERTY_PARSE_VALUE,
VARIANT_HTP,
nsnull)
CSS_PROP_BACKENDONLY(
pitch,
pitch,
Pitch,
CSS_PROPERTY_PARSE_VALUE,
VARIANT_HKF,
kPitchKTable)
CSS_PROP_BACKENDONLY(
pitch-range,
pitch_range,
PitchRange,
CSS_PROPERTY_PARSE_VALUE,
VARIANT_HN,
nsnull)
CSS_PROP_VISIBILITY(
pointer-events,
pointer_events,
@ -2160,13 +2093,6 @@ CSS_PROP_DISPLAY(
kResizeKTable,
CSS_PROP_NO_OFFSET,
eStyleAnimType_None)
CSS_PROP_BACKENDONLY(
richness,
richness,
Richness,
CSS_PROPERTY_PARSE_VALUE,
VARIANT_HN,
nsnull)
CSS_PROP_POSITION(
right,
right,
@ -2184,48 +2110,6 @@ CSS_PROP_BACKENDONLY(
CSS_PROPERTY_PARSE_FUNCTION,
0,
kPageSizeKTable)
CSS_PROP_BACKENDONLY(
speak,
speak,
Speak,
CSS_PROPERTY_PARSE_VALUE,
VARIANT_HK,
kSpeakKTable)
CSS_PROP_BACKENDONLY(
speak-header,
speak_header,
SpeakHeader,
CSS_PROPERTY_PARSE_VALUE,
VARIANT_HK,
kSpeakHeaderKTable)
CSS_PROP_BACKENDONLY(
speak-numeral,
speak_numeral,
SpeakNumeral,
CSS_PROPERTY_PARSE_VALUE,
VARIANT_HK,
kSpeakNumeralKTable)
CSS_PROP_BACKENDONLY(
speak-punctuation,
speak_punctuation,
SpeakPunctuation,
CSS_PROPERTY_PARSE_VALUE,
VARIANT_HK,
kSpeakPunctuationKTable)
CSS_PROP_BACKENDONLY(
speech-rate,
speech_rate,
SpeechRate,
CSS_PROPERTY_PARSE_VALUE,
VARIANT_HN | VARIANT_KEYWORD,
kSpeechRateKTable)
CSS_PROP_BACKENDONLY(
stress,
stress,
Stress,
CSS_PROPERTY_PARSE_VALUE,
VARIANT_HN,
nsnull)
CSS_PROP_TABLE(
table-layout,
table_layout,
@ -2452,21 +2336,6 @@ CSS_PROP_VISIBILITY(
kVisibilityKTable,
offsetof(nsStyleVisibility, mVisible),
eStyleAnimType_EnumU8) // reflow for collapse
CSS_PROP_BACKENDONLY(
voice-family,
voice_family,
VoiceFamily,
CSS_PROPERTY_PARSE_VALUE |
CSS_PROPERTY_VALUE_PARSER_FUNCTION,
0,
nsnull)
CSS_PROP_BACKENDONLY(
volume,
volume,
Volume,
CSS_PROPERTY_PARSE_VALUE,
VARIANT_HPN | VARIANT_KEYWORD,
kVolumeKTable)
CSS_PROP_TEXT(
white-space,
white_space,

Просмотреть файл

@ -582,23 +582,6 @@ const PRInt32 nsCSSProps::kAppearanceKTable[] = {
eCSSKeyword_UNKNOWN,-1
};
// Keyword id tables for variant/enum parsing
const PRInt32 nsCSSProps::kAzimuthKTable[] = {
eCSSKeyword_left_side, NS_STYLE_AZIMUTH_LEFT_SIDE,
eCSSKeyword_far_left, NS_STYLE_AZIMUTH_FAR_LEFT,
eCSSKeyword_left, NS_STYLE_AZIMUTH_LEFT,
eCSSKeyword_center_left, NS_STYLE_AZIMUTH_CENTER_LEFT,
eCSSKeyword_center, NS_STYLE_AZIMUTH_CENTER,
eCSSKeyword_center_right, NS_STYLE_AZIMUTH_CENTER_RIGHT,
eCSSKeyword_right, NS_STYLE_AZIMUTH_RIGHT,
eCSSKeyword_far_right, NS_STYLE_AZIMUTH_FAR_RIGHT,
eCSSKeyword_right_side, NS_STYLE_AZIMUTH_RIGHT_SIDE,
eCSSKeyword_behind, NS_STYLE_AZIMUTH_BEHIND,
eCSSKeyword_leftwards, NS_STYLE_AZIMUTH_LEFTWARDS,
eCSSKeyword_rightwards, NS_STYLE_AZIMUTH_RIGHTWARDS,
eCSSKeyword_UNKNOWN,-1
};
const PRInt32 nsCSSProps::kBackgroundAttachmentKTable[] = {
eCSSKeyword_fixed, NS_STYLE_BG_ATTACHMENT_FIXED,
eCSSKeyword_scroll, NS_STYLE_BG_ATTACHMENT_SCROLL,
@ -887,15 +870,6 @@ const PRInt32 nsCSSProps::kDisplayKTable[] = {
eCSSKeyword_UNKNOWN,-1
};
const PRInt32 nsCSSProps::kElevationKTable[] = {
eCSSKeyword_below, NS_STYLE_ELEVATION_BELOW,
eCSSKeyword_level, NS_STYLE_ELEVATION_LEVEL,
eCSSKeyword_above, NS_STYLE_ELEVATION_ABOVE,
eCSSKeyword_higher, NS_STYLE_ELEVATION_HIGHER,
eCSSKeyword_lower, NS_STYLE_ELEVATION_LOWER,
eCSSKeyword_UNKNOWN,-1
};
const PRInt32 nsCSSProps::kEmptyCellsKTable[] = {
eCSSKeyword_show, NS_STYLE_TABLE_EMPTY_CELLS_SHOW,
eCSSKeyword_hide, NS_STYLE_TABLE_EMPTY_CELLS_HIDE,
@ -1138,15 +1112,6 @@ const PRInt32 nsCSSProps::kPageSizeKTable[] = {
eCSSKeyword_UNKNOWN,-1
};
const PRInt32 nsCSSProps::kPitchKTable[] = {
eCSSKeyword_x_low, NS_STYLE_PITCH_X_LOW,
eCSSKeyword_low, NS_STYLE_PITCH_LOW,
eCSSKeyword_medium, NS_STYLE_PITCH_MEDIUM,
eCSSKeyword_high, NS_STYLE_PITCH_HIGH,
eCSSKeyword_x_high, NS_STYLE_PITCH_X_HIGH,
eCSSKeyword_UNKNOWN,-1
};
const PRInt32 nsCSSProps::kPointerEventsKTable[] = {
eCSSKeyword_none, NS_STYLE_POINTER_EVENTS_NONE,
eCSSKeyword_visiblepainted, NS_STYLE_POINTER_EVENTS_VISIBLEPAINTED,
@ -1194,42 +1159,6 @@ const PRInt32 nsCSSProps::kResizeKTable[] = {
eCSSKeyword_UNKNOWN,-1
};
const PRInt32 nsCSSProps::kSpeakKTable[] = {
eCSSKeyword_none, NS_STYLE_SPEAK_NONE,
eCSSKeyword_normal, NS_STYLE_SPEAK_NORMAL,
eCSSKeyword_spell_out, NS_STYLE_SPEAK_SPELL_OUT,
eCSSKeyword_UNKNOWN,-1
};
const PRInt32 nsCSSProps::kSpeakHeaderKTable[] = {
eCSSKeyword_once, NS_STYLE_SPEAK_HEADER_ONCE,
eCSSKeyword_always, NS_STYLE_SPEAK_HEADER_ALWAYS,
eCSSKeyword_UNKNOWN,-1
};
const PRInt32 nsCSSProps::kSpeakNumeralKTable[] = {
eCSSKeyword_digits, NS_STYLE_SPEAK_NUMERAL_DIGITS,
eCSSKeyword_continuous, NS_STYLE_SPEAK_NUMERAL_CONTINUOUS,
eCSSKeyword_UNKNOWN,-1
};
const PRInt32 nsCSSProps::kSpeakPunctuationKTable[] = {
eCSSKeyword_none, NS_STYLE_SPEAK_PUNCTUATION_NONE,
eCSSKeyword_code, NS_STYLE_SPEAK_PUNCTUATION_CODE,
eCSSKeyword_UNKNOWN,-1
};
const PRInt32 nsCSSProps::kSpeechRateKTable[] = {
eCSSKeyword_x_slow, NS_STYLE_SPEECH_RATE_X_SLOW,
eCSSKeyword_slow, NS_STYLE_SPEECH_RATE_SLOW,
eCSSKeyword_medium, NS_STYLE_SPEECH_RATE_MEDIUM,
eCSSKeyword_fast, NS_STYLE_SPEECH_RATE_FAST,
eCSSKeyword_x_fast, NS_STYLE_SPEECH_RATE_X_FAST,
eCSSKeyword_faster, NS_STYLE_SPEECH_RATE_FASTER,
eCSSKeyword_slower, NS_STYLE_SPEECH_RATE_SLOWER,
eCSSKeyword_UNKNOWN,-1
};
const PRInt32 nsCSSProps::kStackSizingKTable[] = {
eCSSKeyword_ignore, NS_STYLE_STACK_SIZING_IGNORE,
eCSSKeyword_stretch_to_fit, NS_STYLE_STACK_SIZING_STRETCH_TO_FIT,
@ -1362,16 +1291,6 @@ const PRInt32 nsCSSProps::kVisibilityKTable[] = {
eCSSKeyword_UNKNOWN,-1
};
const PRInt32 nsCSSProps::kVolumeKTable[] = {
eCSSKeyword_silent, NS_STYLE_VOLUME_SILENT,
eCSSKeyword_x_soft, NS_STYLE_VOLUME_X_SOFT,
eCSSKeyword_soft, NS_STYLE_VOLUME_SOFT,
eCSSKeyword_medium, NS_STYLE_VOLUME_MEDIUM,
eCSSKeyword_loud, NS_STYLE_VOLUME_LOUD,
eCSSKeyword_x_loud, NS_STYLE_VOLUME_X_LOUD,
eCSSKeyword_UNKNOWN,-1
};
const PRInt32 nsCSSProps::kWhitespaceKTable[] = {
eCSSKeyword_normal, NS_STYLE_WHITESPACE_NORMAL,
eCSSKeyword_pre, NS_STYLE_WHITESPACE_PRE,
@ -1946,12 +1865,6 @@ static const nsCSSProperty gBorderEndWidthSubpropTable[] = {
eCSSProperty_UNKNOWN
};
static const nsCSSProperty gCueSubpropTable[] = {
eCSSProperty_cue_after,
eCSSProperty_cue_before,
eCSSProperty_UNKNOWN
};
static const nsCSSProperty gFontSubpropTable[] = {
eCSSProperty_font_family,
eCSSProperty_font_style,
@ -2091,12 +2004,6 @@ static const nsCSSProperty gPaddingEndSubpropTable[] = {
eCSSProperty_UNKNOWN
};
static const nsCSSProperty gPauseSubpropTable[] = {
eCSSProperty_pause_after,
eCSSProperty_pause_before,
eCSSProperty_UNKNOWN
};
static const nsCSSProperty gTransitionSubpropTable[] = {
eCSSProperty_transition_property,
eCSSProperty_transition_duration,

Просмотреть файл

@ -806,14 +806,6 @@ nsCSSValue::AppendToString(nsCSSProperty aProperty, nsAString& aResult) const
aResult);
}
}
else if (eCSSProperty_azimuth == aProperty) {
PRInt32 intValue = GetIntValue();
AppendASCIItoUTF16(nsCSSProps::LookupPropertyValue(aProperty, (intValue & ~NS_STYLE_AZIMUTH_BEHIND)), aResult);
if ((NS_STYLE_AZIMUTH_BEHIND & intValue) != 0) {
aResult.Append(PRUnichar(' '));
AppendASCIItoUTF16(nsCSSProps::LookupPropertyValue(aProperty, NS_STYLE_AZIMUTH_BEHIND), aResult);
}
}
else if (eCSSProperty_marks == aProperty) {
PRInt32 intValue = GetIntValue();
if (intValue == NS_STYLE_PAGE_MARKS_NONE) {

Просмотреть файл

@ -4140,7 +4140,6 @@ nsComputedDOMStyle::GetQueryablePropertyMap(PRUint32* aLength)
* Implementations of CSS2 styles *
\* ****************************** */
// COMPUTED_STYLE_MAP_ENTRY(azimuth, Azimuth),
//// COMPUTED_STYLE_MAP_ENTRY(background, Background),
COMPUTED_STYLE_MAP_ENTRY(background_attachment, BackgroundAttachment),
COMPUTED_STYLE_MAP_ENTRY(background_color, BackgroundColor),
@ -4177,13 +4176,9 @@ nsComputedDOMStyle::GetQueryablePropertyMap(PRUint32* aLength)
COMPUTED_STYLE_MAP_ENTRY(content, Content),
COMPUTED_STYLE_MAP_ENTRY(counter_increment, CounterIncrement),
COMPUTED_STYLE_MAP_ENTRY(counter_reset, CounterReset),
//// COMPUTED_STYLE_MAP_ENTRY(cue, Cue),
// COMPUTED_STYLE_MAP_ENTRY(cue_after, CueAfter),
// COMPUTED_STYLE_MAP_ENTRY(cue_before, CueBefore),
COMPUTED_STYLE_MAP_ENTRY(cursor, Cursor),
COMPUTED_STYLE_MAP_ENTRY(direction, Direction),
COMPUTED_STYLE_MAP_ENTRY(display, Display),
// COMPUTED_STYLE_MAP_ENTRY(elevation, Elevation),
COMPUTED_STYLE_MAP_ENTRY(empty_cells, EmptyCells),
COMPUTED_STYLE_MAP_ENTRY(float, CssFloat),
//// COMPUTED_STYLE_MAP_ENTRY(font, Font),
@ -4233,23 +4228,11 @@ nsComputedDOMStyle::GetQueryablePropertyMap(PRUint32* aLength)
COMPUTED_STYLE_MAP_ENTRY(page_break_after, PageBreakAfter),
COMPUTED_STYLE_MAP_ENTRY(page_break_before, PageBreakBefore),
// COMPUTED_STYLE_MAP_ENTRY(page_break_inside, PageBreakInside),
//// COMPUTED_STYLE_MAP_ENTRY(pause, Pause),
// COMPUTED_STYLE_MAP_ENTRY(pause_after, PauseAfter),
// COMPUTED_STYLE_MAP_ENTRY(pause_before, PauseBefore),
// COMPUTED_STYLE_MAP_ENTRY(pitch, Pitch),
// COMPUTED_STYLE_MAP_ENTRY(pitch_range, PitchRange),
COMPUTED_STYLE_MAP_ENTRY(pointer_events, PointerEvents),
COMPUTED_STYLE_MAP_ENTRY(position, Position),
COMPUTED_STYLE_MAP_ENTRY(quotes, Quotes),
// COMPUTED_STYLE_MAP_ENTRY(richness, Richness),
COMPUTED_STYLE_MAP_ENTRY_LAYOUT(right, Right),
//// COMPUTED_STYLE_MAP_ENTRY(size, Size),
// COMPUTED_STYLE_MAP_ENTRY(speak, Speak),
// COMPUTED_STYLE_MAP_ENTRY(speak_header, SpeakHeader),
// COMPUTED_STYLE_MAP_ENTRY(speak_numeral, SpeakNumeral),
// COMPUTED_STYLE_MAP_ENTRY(speak_punctuation, SpeakPunctuation),
// COMPUTED_STYLE_MAP_ENTRY(speech_rate, SpeechRate),
// COMPUTED_STYLE_MAP_ENTRY(stress, Stress),
COMPUTED_STYLE_MAP_ENTRY(table_layout, TableLayout),
COMPUTED_STYLE_MAP_ENTRY(text_align, TextAlign),
COMPUTED_STYLE_MAP_ENTRY(text_decoration, TextDecoration),
@ -4260,8 +4243,6 @@ nsComputedDOMStyle::GetQueryablePropertyMap(PRUint32* aLength)
COMPUTED_STYLE_MAP_ENTRY(unicode_bidi, UnicodeBidi),
COMPUTED_STYLE_MAP_ENTRY_LAYOUT(vertical_align, VerticalAlign),
COMPUTED_STYLE_MAP_ENTRY(visibility, Visibility),
// COMPUTED_STYLE_MAP_ENTRY(voice_family, VoiceFamily),
// COMPUTED_STYLE_MAP_ENTRY(volume, Volume),
COMPUTED_STYLE_MAP_ENTRY(white_space, WhiteSpace),
// COMPUTED_STYLE_MAP_ENTRY(widows, Widows),
COMPUTED_STYLE_MAP_ENTRY_LAYOUT(width, Width),

Просмотреть файл

@ -1006,15 +1006,6 @@ var gCSSProperties = {
other_values: [ "none", "menu", "tooltip", "sheet" ],
invalid_values: []
},
"azimuth": {
domProp: "azimuth",
inherited: true,
backend_only: true,
type: CSS_TYPE_LONGHAND,
initial_values: [ "center", "0deg" ],
other_values: [ "center behind", "behind far-right", "left-side", "73deg", "90.1deg", "0.1deg" ],
invalid_values: [ "0deg behind", "behind 0deg", "90deg behind", "behind 90deg" ]
},
"background": {
domProp: "background",
inherited: false,
@ -1745,34 +1736,6 @@ var gCSSProperties = {
other_values: [ "foo 1", "bar", "foo 3 bar baz 2", "\\32 1", "-\\32 1", "-c 1", "\\32 1", "-\\32 1", "\\2 1", "-\\2 1", "-c 1", "\\2 1", "-\\2 1" ],
invalid_values: []
},
"cue": {
domProp: "cue",
inherited: false,
backend_only: true,
type: CSS_TYPE_TRUE_SHORTHAND,
subproperties: [ "cue-before", "cue-after" ],
initial_values: [ "none", "none none" ],
other_values: [ "url(404.wav)", "url(404.wav) none", "none url(404.wav)" ],
invalid_values: []
},
"cue-after": {
domProp: "cueAfter",
inherited: false,
backend_only: true,
type: CSS_TYPE_LONGHAND,
initial_values: [ "none" ],
other_values: [ "url(404.wav)" ],
invalid_values: []
},
"cue-before": {
domProp: "cueBefore",
inherited: false,
backend_only: true,
type: CSS_TYPE_LONGHAND,
initial_values: [ "none" ],
other_values: [ "url(404.wav)" ],
invalid_values: []
},
"cursor": {
domProp: "cursor",
inherited: true,
@ -1799,15 +1762,6 @@ var gCSSProperties = {
other_values: [ "block", "list-item", "inline-block", "table", "inline-table", "table-row-group", "table-header-group", "table-footer-group", "table-row", "table-column-group", "table-column", "table-cell", "table-caption", "none" ],
invalid_values: []
},
"elevation": {
domProp: "elevation",
inherited: true,
backend_only: true,
type: CSS_TYPE_LONGHAND,
initial_values: [ "level", "0deg" ],
other_values: [ "below", "above", "60deg", "higher", "lower", "-79deg", "0.33deg" ],
invalid_values: []
},
"empty-cells": {
domProp: "emptyCells",
inherited: true,
@ -2404,52 +2358,6 @@ var gCSSProperties = {
other_values: [ "avoid" ],
invalid_values: []
},
"pause": {
domProp: "pause",
inherited: false,
backend_only: true,
type: CSS_TYPE_TRUE_SHORTHAND,
subproperties: [ "pause-before", "pause-after" ],
initial_values: [ "0s", "0ms", "0s 0ms" ],
other_values: [ "1s", "200ms", "-2s", "50%", "-10%", "10% 200ms", "-3s -5%" ],
invalid_values: [ "0", "0px", "0 0", "0ms 0" ]
},
"pause-after": {
domProp: "pauseAfter",
inherited: false,
backend_only: true,
type: CSS_TYPE_LONGHAND,
initial_values: [ "0s", "0ms" ],
other_values: [ "1s", "200ms", "-2s", "50%", "-10%" ],
invalid_values: [ "0", "0px" ]
},
"pause-before": {
domProp: "pauseBefore",
inherited: false,
backend_only: true,
type: CSS_TYPE_LONGHAND,
initial_values: [ "0s", "0ms" ],
other_values: [ "1s", "200ms", "-2s", "50%", "-10%" ],
invalid_values: [ "0", "0px" ]
},
"pitch": {
domProp: "pitch",
inherited: true,
backend_only: true,
type: CSS_TYPE_LONGHAND,
initial_values: [ "medium" ],
other_values: [ "x-low", "low", "high", "x-high" ],
invalid_values: []
},
"pitch-range": {
domProp: "pitchRange",
inherited: true,
backend_only: true,
type: CSS_TYPE_LONGHAND,
initial_values: [ "50", "50.0" ],
other_values: [ "0", "100.0", "99.7", "47", "3.2" ],
invalid_values: [" -0.01", "100.2", "108", "-3" ]
},
"pointer-events": {
domProp: "pointerEvents",
inherited: true,
@ -2476,15 +2384,6 @@ var gCSSProperties = {
other_values: [ "none", "'\"' '\"'" ],
invalid_values: []
},
"richness": {
domProp: "richness",
inherited: true,
backend_only: true,
type: CSS_TYPE_LONGHAND,
initial_values: [ "50", "50.0" ],
other_values: [ "0", "100.0", "99.7", "47", "3.2" ],
invalid_values: [" -0.01", "100.2", "108", "-3" ]
},
"right": {
domProp: "right",
inherited: false,
@ -2516,62 +2415,6 @@ var gCSSProperties = {
"100mm 100mm 100mm"
]
},
"speak": {
domProp: "speak",
inherited: true,
backend_only: true,
type: CSS_TYPE_LONGHAND,
initial_values: [ "normal" ],
other_values: [ "none", "spell-out" ],
invalid_values: []
},
"speak-header": {
domProp: "speakHeader",
inherited: true,
backend_only: true,
type: CSS_TYPE_LONGHAND,
initial_values: [ "once" ],
other_values: [ "always" ],
invalid_values: []
},
"speak-numeral": {
domProp: "speakNumeral",
inherited: true,
backend_only: true,
type: CSS_TYPE_LONGHAND,
initial_values: [ "continuous" ],
other_values: [ "digits" ],
invalid_values: []
},
"speak-punctuation": {
domProp: "speakPunctuation",
inherited: true,
backend_only: true,
type: CSS_TYPE_LONGHAND,
initial_values: [ "none" ],
other_values: [ "code" ],
invalid_values: []
},
"speech-rate": {
domProp: "speechRate",
inherited: true,
backend_only: true,
type: CSS_TYPE_LONGHAND,
initial_values: [ "medium" ],
other_values: [ "x-slow", "slow", "fast", "x-fast", "faster", "slower", "80", "500", "73.2" ],
invalid_values: [
// "0", "-80" // unclear
]
},
"stress": {
domProp: "stress",
inherited: true,
backend_only: true,
type: CSS_TYPE_LONGHAND,
initial_values: [ "50", "50.0" ],
other_values: [ "0", "100.0", "99.7", "47", "3.2" ],
invalid_values: [" -0.01", "100.2", "108", "-3" ]
},
"table-layout": {
domProp: "tableLayout",
inherited: false,
@ -2750,24 +2593,6 @@ var gCSSProperties = {
other_values: [ "hidden", "collapse" ],
invalid_values: []
},
"voice-family": {
domProp: "voiceFamily",
inherited: true,
backend_only: true,
type: CSS_TYPE_LONGHAND,
initial_values: [ "male" ], /* arbitrary guess */
other_values: [ "female", "child", "Bob, male", "Jane, Juliet, female" ],
invalid_values: []
},
"volume": {
domProp: "volume",
inherited: true,
backend_only: true,
type: CSS_TYPE_LONGHAND,
initial_values: [ "50", "50.0", "medium" ],
other_values: [ "0", "100.0", "99.7", "47", "3.2", "silent", "x-soft", "soft", "loud", "x-loud" ],
invalid_values: [" -0.01", "100.2", "108", "-3" ]
},
"white-space": {
domProp: "whiteSpace",
inherited: true,

Просмотреть файл

@ -31,8 +31,8 @@ var tests = {
var p = document.getElementById("display");
for (var test in tests) {
p.setAttribute("style", "elevation: " + test);
is(p.style.getPropertyValue("elevation"), test,
p.setAttribute("style", "-moz-transform: rotate(" + test + ")");
is(p.style.getPropertyValue("-moz-transform"), "rotate(" + test + ")",
test + " serializes to exactly itself");
// We can't test any equivalence since we don't have any properties
// with angle values that we compute. (-moz-transform doesn't help.)

Просмотреть файл

@ -30,11 +30,16 @@ var tests = {
var p = document.getElementById("display");
for (var test in tests) {
// We can't test this because we no longer support any properties
// with frequency values.
todo(false, "no tests to run, for now");
/*
p.setAttribute("style", "pitch: " + test);
is(p.style.getPropertyValue("pitch"), test,
test + " serializes to exactly itself");
*/
// We can't test any equivalence since we don't have any properties
// with angle values that we compute.
// with frequency values that we compute.
/*
var equiv = tests[test];
if (equiv) {

Просмотреть файл

@ -30,20 +30,16 @@ var tests = {
var p = document.getElementById("display");
for (var test in tests) {
p.setAttribute("style", "pause-before: " + test);
is(p.style.getPropertyValue("pause-before"), test,
p.setAttribute("style", "-moz-transition-duration: " + test);
is(p.style.getPropertyValue("-moz-transition-duration"), test,
test + " serializes to exactly itself");
// We can't test any equivalence since we don't have any properties
// with angle values that we compute.
/*
var equiv = tests[test];
if (equiv) {
var cm1 = getComputedStyle(p, "").pauseBefore;
p.style.pauseBefore = equiv;
var cm2 = getComputedStyle(p, "").pauseBefore;
var cm1 = getComputedStyle(p, "").MozTransitionDuration;
p.style.MozTransitionDuration = equiv;
var cm2 = getComputedStyle(p, "").MozTransitionDuration;
is(cm1, cm2, test + " should compute to the same as " + equiv);
}
*/
}
</script>