Remove '-moz-resizer' from the style system.

Bug 242712. r+sr=dbaron
This commit is contained in:
caillon%redhat.com 2004-05-05 21:37:32 +00:00
Родитель 4223ad9eaa
Коммит 56b3fc7a8c
25 изменённых файлов: 6 добавлений и 93 удалений

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

@ -2442,20 +2442,6 @@ nsRuleNode::ComputeUIResetData(nsStyleStruct* aStartData,
ui->mKeyEquivalent = parentUI->mKeyEquivalent;
}
}
// resizer: auto, none, enum, inherit
if (eCSSUnit_Enumerated == uiData.mResizer.GetUnit()) {
ui->mResizer = uiData.mResizer.GetIntValue();
}
else if (eCSSUnit_Auto == uiData.mResizer.GetUnit()) {
ui->mResizer = NS_STYLE_RESIZER_AUTO;
}
else if (eCSSUnit_None == uiData.mResizer.GetUnit()) {
ui->mResizer = NS_STYLE_RESIZER_NONE;
}
else if (eCSSUnit_Inherit == uiData.mResizer.GetUnit()) {
inherited = PR_TRUE;
ui->mResizer = parentUI->mResizer;
}
// force-broken-image-icons: integer
if (eCSSUnit_Integer == uiData.mForceBrokenImageIcon.GetUnit()) {

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

@ -802,10 +802,9 @@ void nsStyleContext::DumpRegressionData(nsIPresContext* aPresContext, FILE* out,
// UIReset
IndentBy(out,aIndent);
const nsStyleUIReset* uiReset = GetStyleUIReset();
fprintf(out, "<uireset data=\"%d %d %d\" />\n",
fprintf(out, "<uireset data=\"%d %d\" />\n",
(int)uiReset->mUserSelect,
(int)uiReset->mKeyEquivalent,
(int)uiReset->mResizer);
(int)uiReset->mKeyEquivalent);
// XUL
IndentBy(out,aIndent);

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

@ -4339,9 +4339,6 @@ PRBool CSSParserImpl::ParseSingleValueProperty(nsresult& aErrorCode,
return ParseVariant(aErrorCode, aValue, VARIANT_HN, nsnull);
case eCSSProperty_position:
return ParseVariant(aErrorCode, aValue, VARIANT_HK, nsCSSProps::kPositionKTable);
case eCSSProperty_resizer:
return ParseVariant(aErrorCode, aValue, VARIANT_AHK | VARIANT_NONE,
nsCSSProps::kResizerKTable);
case eCSSProperty_richness:
return ParseVariant(aErrorCode, aValue, VARIANT_HN, nsnull);
case eCSSProperty_speak:

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

@ -1004,7 +1004,6 @@ nsCSSUserInterface::nsCSSUserInterface(const nsCSSUserInterface& aCopy)
mUserSelect(aCopy.mUserSelect),
mKeyEquivalent(nsnull),
mUserFocus(aCopy.mUserFocus),
mResizer(aCopy.mResizer),
mCursor(nsnull),
mForceBrokenImageIcon(aCopy.mForceBrokenImageIcon)
{
@ -1036,7 +1035,6 @@ void nsCSSUserInterface::List(FILE* out, PRInt32 aIndent) const
keyEquiv= keyEquiv->mNext;
}
mUserFocus.AppendToString(buffer, eCSSProperty_user_focus);
mResizer.AppendToString(buffer, eCSSProperty_resizer);
nsCSSValueList* cursor = mCursor;
while (nsnull != cursor) {

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

@ -446,7 +446,6 @@ struct nsCSSUserInterface : public nsCSSStruct { // NEW
nsCSSValue mUserSelect;
nsCSSValueList* mKeyEquivalent;
nsCSSValue mUserFocus;
nsCSSValue mResizer;
nsCSSValueList* mCursor;
nsCSSValue mForceBrokenImageIcon;

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

@ -244,7 +244,6 @@ CSSDisablePropsRule::CommonMapRuleInfoInto(nsRuleData* aData)
if (aData->mSID == eStyleStruct_UIReset) {
nsCSSValue autovalue(eCSSUnit_Auto);
nsCSSValue none(eCSSUnit_None);
aData->mUserInterfaceData->mResizer = autovalue;
// XXX |mKeyEquivalent| is a pain, because we have to have our own cursor
// structure allocated.
// Don't bother with '-moz-force-broken-image-icon' since it's only

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

@ -438,7 +438,6 @@ CSS_PROP_BACKENDONLY(-x-play-during-uri, play_during_uri, PlayDuringURI, Aural,
#endif /* !defined (CSS_PROP_LIST_EXCLUDE_INTERNAL) */
CSS_PROP_DISPLAY(position, position, Position, Display, mPosition, eCSSType_Value, PR_FALSE, kPositionKTable)
CSS_PROP_QUOTES(quotes, quotes, Quotes, Content, mQuotes, eCSSType_Quotes, PR_FALSE, nsnull)
CSS_PROP_UIRESET(-moz-resizer, resizer, MozResizer, UserInterface, mResizer, eCSSType_Value, PR_FALSE, kResizerKTable) // XXX bug 3935
CSS_PROP_BACKENDONLY(richness, richness, Richness, Aural, mRichness, eCSSType_Value, PR_FALSE, nsnull)
CSS_PROP_POSITION(right, right, Right, Position, mOffset.mRight, eCSSType_Value, PR_TRUE, nsnull)
CSS_PROP_SHORTHAND(size, size, Size)

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

@ -156,7 +156,6 @@ public:
static const PRInt32 kPitchKTable[];
static const PRInt32 kPlayDuringKTable[];
static const PRInt32 kPositionKTable[];
static const PRInt32 kResizerKTable[];
static const PRInt32 kSpeakKTable[];
static const PRInt32 kSpeakHeaderKTable[];
static const PRInt32 kSpeakNumeralKTable[];

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

@ -1080,7 +1080,6 @@ struct nsStyleUIReset: public nsStyleStruct {
PRUnichar mKeyEquivalent; // [reset] XXX what type should this be?
PRUint8 mUserSelect; // [reset] (selection-style)
PRUint8 mResizer; // [reset]
PRUint8 mForceBrokenImageIcon; // [reset] (0 if not forcing, otherwise forcing)
};

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

@ -731,13 +731,6 @@ const PRInt32 nsCSSProps::kPositionKTable[] = {
-1,-1
};
const PRInt32 nsCSSProps::kResizerKTable[] = {
eCSSKeyword_both, NS_STYLE_RESIZER_BOTH,
eCSSKeyword_horizontal, NS_STYLE_RESIZER_HORIZONTAL,
eCSSKeyword_vertical, NS_STYLE_RESIZER_VERTICAL,
-1,-1
};
const PRInt32 nsCSSProps::kSpeakKTable[] = {
eCSSKeyword_spell_out, NS_STYLE_SPEAK_SPELL_OUT,
-1,-1

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

@ -1416,7 +1416,6 @@ nsStyleUIReset::nsStyleUIReset(void)
{
mUserSelect = NS_STYLE_USER_SELECT_AUTO;
mKeyEquivalent = PRUnichar(0); // XXX what type should this be?
mResizer = NS_STYLE_RESIZER_AUTO;
mForceBrokenImageIcon = 0;
}
@ -1424,7 +1423,6 @@ nsStyleUIReset::nsStyleUIReset(const nsStyleUIReset& aSource)
{
mUserSelect = aSource.mUserSelect;
mKeyEquivalent = aSource.mKeyEquivalent;
mResizer = aSource.mResizer;
mForceBrokenImageIcon = aSource.mForceBrokenImageIcon;
}
@ -1435,8 +1433,7 @@ nsStyleUIReset::~nsStyleUIReset(void)
nsChangeHint nsStyleUIReset::CalcDifference(const nsStyleUIReset& aOther) const
{
if (mForceBrokenImageIcon == aOther.mForceBrokenImageIcon) {
if (mResizer == aOther.mResizer &&
mUserSelect == aOther.mUserSelect) {
if (mUserSelect == aOther.mUserSelect) {
// ignore mKeyEquivalent
return NS_STYLE_HINT_NONE;
}

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

@ -538,9 +538,6 @@ interface nsIDOMNSCSS2Properties : nsIDOMCSS2Properties
attribute DOMString MozPaddingStart;
// raises(DOMException) on setting
attribute DOMString MozResizer;
// raises(DOMException) on setting
attribute DOMString MozUserFocus;
// raises(DOMException) on setting

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

@ -67,13 +67,6 @@
// key-equivalent
#define NS_STYLE_KEY_EQUIVALENT_NONE 0
// resizer
#define NS_STYLE_RESIZER_NONE 0x00
#define NS_STYLE_RESIZER_HORIZONTAL 0x01 // bits
#define NS_STYLE_RESIZER_VERTICAL 0x02 // bits
#define NS_STYLE_RESIZER_BOTH 0x03 // bits
#define NS_STYLE_RESIZER_AUTO 0x04 // bits
// user-focus
#define NS_STYLE_USER_FOCUS_NONE 0
#define NS_STYLE_USER_FOCUS_IGNORE 1

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

@ -67,13 +67,6 @@
// key-equivalent
#define NS_STYLE_KEY_EQUIVALENT_NONE 0
// resizer
#define NS_STYLE_RESIZER_NONE 0x00
#define NS_STYLE_RESIZER_HORIZONTAL 0x01 // bits
#define NS_STYLE_RESIZER_VERTICAL 0x02 // bits
#define NS_STYLE_RESIZER_BOTH 0x03 // bits
#define NS_STYLE_RESIZER_AUTO 0x04 // bits
// user-focus
#define NS_STYLE_USER_FOCUS_NONE 0
#define NS_STYLE_USER_FOCUS_IGNORE 1

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

@ -4339,9 +4339,6 @@ PRBool CSSParserImpl::ParseSingleValueProperty(nsresult& aErrorCode,
return ParseVariant(aErrorCode, aValue, VARIANT_HN, nsnull);
case eCSSProperty_position:
return ParseVariant(aErrorCode, aValue, VARIANT_HK, nsCSSProps::kPositionKTable);
case eCSSProperty_resizer:
return ParseVariant(aErrorCode, aValue, VARIANT_AHK | VARIANT_NONE,
nsCSSProps::kResizerKTable);
case eCSSProperty_richness:
return ParseVariant(aErrorCode, aValue, VARIANT_HN, nsnull);
case eCSSProperty_speak:

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

@ -438,7 +438,6 @@ CSS_PROP_BACKENDONLY(-x-play-during-uri, play_during_uri, PlayDuringURI, Aural,
#endif /* !defined (CSS_PROP_LIST_EXCLUDE_INTERNAL) */
CSS_PROP_DISPLAY(position, position, Position, Display, mPosition, eCSSType_Value, PR_FALSE, kPositionKTable)
CSS_PROP_QUOTES(quotes, quotes, Quotes, Content, mQuotes, eCSSType_Quotes, PR_FALSE, nsnull)
CSS_PROP_UIRESET(-moz-resizer, resizer, MozResizer, UserInterface, mResizer, eCSSType_Value, PR_FALSE, kResizerKTable) // XXX bug 3935
CSS_PROP_BACKENDONLY(richness, richness, Richness, Aural, mRichness, eCSSType_Value, PR_FALSE, nsnull)
CSS_PROP_POSITION(right, right, Right, Position, mOffset.mRight, eCSSType_Value, PR_TRUE, nsnull)
CSS_PROP_SHORTHAND(size, size, Size)

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

@ -731,13 +731,6 @@ const PRInt32 nsCSSProps::kPositionKTable[] = {
-1,-1
};
const PRInt32 nsCSSProps::kResizerKTable[] = {
eCSSKeyword_both, NS_STYLE_RESIZER_BOTH,
eCSSKeyword_horizontal, NS_STYLE_RESIZER_HORIZONTAL,
eCSSKeyword_vertical, NS_STYLE_RESIZER_VERTICAL,
-1,-1
};
const PRInt32 nsCSSProps::kSpeakKTable[] = {
eCSSKeyword_spell_out, NS_STYLE_SPEAK_SPELL_OUT,
-1,-1

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

@ -156,7 +156,6 @@ public:
static const PRInt32 kPitchKTable[];
static const PRInt32 kPlayDuringKTable[];
static const PRInt32 kPositionKTable[];
static const PRInt32 kResizerKTable[];
static const PRInt32 kSpeakKTable[];
static const PRInt32 kSpeakHeaderKTable[];
static const PRInt32 kSpeakNumeralKTable[];

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

@ -1004,7 +1004,6 @@ nsCSSUserInterface::nsCSSUserInterface(const nsCSSUserInterface& aCopy)
mUserSelect(aCopy.mUserSelect),
mKeyEquivalent(nsnull),
mUserFocus(aCopy.mUserFocus),
mResizer(aCopy.mResizer),
mCursor(nsnull),
mForceBrokenImageIcon(aCopy.mForceBrokenImageIcon)
{
@ -1036,7 +1035,6 @@ void nsCSSUserInterface::List(FILE* out, PRInt32 aIndent) const
keyEquiv= keyEquiv->mNext;
}
mUserFocus.AppendToString(buffer, eCSSProperty_user_focus);
mResizer.AppendToString(buffer, eCSSProperty_resizer);
nsCSSValueList* cursor = mCursor;
while (nsnull != cursor) {

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

@ -446,7 +446,6 @@ struct nsCSSUserInterface : public nsCSSStruct { // NEW
nsCSSValue mUserSelect;
nsCSSValueList* mKeyEquivalent;
nsCSSValue mUserFocus;
nsCSSValue mResizer;
nsCSSValueList* mCursor;
nsCSSValue mForceBrokenImageIcon;

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

@ -244,7 +244,6 @@ CSSDisablePropsRule::CommonMapRuleInfoInto(nsRuleData* aData)
if (aData->mSID == eStyleStruct_UIReset) {
nsCSSValue autovalue(eCSSUnit_Auto);
nsCSSValue none(eCSSUnit_None);
aData->mUserInterfaceData->mResizer = autovalue;
// XXX |mKeyEquivalent| is a pain, because we have to have our own cursor
// structure allocated.
// Don't bother with '-moz-force-broken-image-icon' since it's only

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

@ -2442,20 +2442,6 @@ nsRuleNode::ComputeUIResetData(nsStyleStruct* aStartData,
ui->mKeyEquivalent = parentUI->mKeyEquivalent;
}
}
// resizer: auto, none, enum, inherit
if (eCSSUnit_Enumerated == uiData.mResizer.GetUnit()) {
ui->mResizer = uiData.mResizer.GetIntValue();
}
else if (eCSSUnit_Auto == uiData.mResizer.GetUnit()) {
ui->mResizer = NS_STYLE_RESIZER_AUTO;
}
else if (eCSSUnit_None == uiData.mResizer.GetUnit()) {
ui->mResizer = NS_STYLE_RESIZER_NONE;
}
else if (eCSSUnit_Inherit == uiData.mResizer.GetUnit()) {
inherited = PR_TRUE;
ui->mResizer = parentUI->mResizer;
}
// force-broken-image-icons: integer
if (eCSSUnit_Integer == uiData.mForceBrokenImageIcon.GetUnit()) {

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

@ -802,10 +802,9 @@ void nsStyleContext::DumpRegressionData(nsIPresContext* aPresContext, FILE* out,
// UIReset
IndentBy(out,aIndent);
const nsStyleUIReset* uiReset = GetStyleUIReset();
fprintf(out, "<uireset data=\"%d %d %d\" />\n",
fprintf(out, "<uireset data=\"%d %d\" />\n",
(int)uiReset->mUserSelect,
(int)uiReset->mKeyEquivalent,
(int)uiReset->mResizer);
(int)uiReset->mKeyEquivalent);
// XUL
IndentBy(out,aIndent);

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

@ -1416,7 +1416,6 @@ nsStyleUIReset::nsStyleUIReset(void)
{
mUserSelect = NS_STYLE_USER_SELECT_AUTO;
mKeyEquivalent = PRUnichar(0); // XXX what type should this be?
mResizer = NS_STYLE_RESIZER_AUTO;
mForceBrokenImageIcon = 0;
}
@ -1424,7 +1423,6 @@ nsStyleUIReset::nsStyleUIReset(const nsStyleUIReset& aSource)
{
mUserSelect = aSource.mUserSelect;
mKeyEquivalent = aSource.mKeyEquivalent;
mResizer = aSource.mResizer;
mForceBrokenImageIcon = aSource.mForceBrokenImageIcon;
}
@ -1435,8 +1433,7 @@ nsStyleUIReset::~nsStyleUIReset(void)
nsChangeHint nsStyleUIReset::CalcDifference(const nsStyleUIReset& aOther) const
{
if (mForceBrokenImageIcon == aOther.mForceBrokenImageIcon) {
if (mResizer == aOther.mResizer &&
mUserSelect == aOther.mUserSelect) {
if (mUserSelect == aOther.mUserSelect) {
// ignore mKeyEquivalent
return NS_STYLE_HINT_NONE;
}

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

@ -1080,7 +1080,6 @@ struct nsStyleUIReset: public nsStyleStruct {
PRUnichar mKeyEquivalent; // [reset] XXX what type should this be?
PRUint8 mUserSelect; // [reset] (selection-style)
PRUint8 mResizer; // [reset]
PRUint8 mForceBrokenImageIcon; // [reset] (0 if not forcing, otherwise forcing)
};