зеркало из https://github.com/mozilla/gecko-dev.git
Bug 409388 - "Number box text fields seem not to get repainted on focus events" [p=twanno@lycos.nl (Teune van Steeg) r=Enn sr=roc a1.9=schrep]
This commit is contained in:
Родитель
dbcffee172
Коммит
5cecb2fc60
|
@ -508,11 +508,21 @@
|
|||
<handler event="compositionend" phase="capturing"
|
||||
action="if (this.mController.input == this) this.mController.handleEndComposition();"/>
|
||||
|
||||
<handler event="focus" phase="capturing"
|
||||
action="this.attachController();"/>
|
||||
<handler event="focus" phase="capturing">
|
||||
<![CDATA[
|
||||
this.attachController();
|
||||
this.mInputElt.parentNode.parentNode.setAttribute('focused', 'true');
|
||||
]]>
|
||||
</handler>
|
||||
|
||||
<handler event="blur" phase="capturing"
|
||||
action="if (!this._dontBlur) this.detachController();"/>
|
||||
<handler event="blur" phase="capturing">
|
||||
<![CDATA[
|
||||
if (!this._dontBlur) {
|
||||
this.detachController();
|
||||
this.mInputElt.parentNode.parentNode.removeAttribute('focused');
|
||||
}
|
||||
]]>
|
||||
</handler>
|
||||
|
||||
<handler event="contextmenu" phase="capturing"
|
||||
action="this.closePopup();"/>
|
||||
|
|
|
@ -399,7 +399,7 @@
|
|||
|
||||
<binding id="menulist-editable" extends="chrome://global/content/bindings/menulist.xml#menulist">
|
||||
<content sizetopopup="pref">
|
||||
<xul:hbox class="menulist-editable-box textbox-input-box" xbl:inherits="context,disabled,readonly" flex="1">
|
||||
<xul:hbox class="menulist-editable-box textbox-input-box" xbl:inherits="context,disabled,readonly,focused" flex="1">
|
||||
<html:input class="menulist-editable-input" flex="1" anonid="input" allowevents="true"
|
||||
xbl:inherits="value=label,value,disabled,tabindex,readonly"/>
|
||||
</xul:hbox>
|
||||
|
|
|
@ -293,6 +293,14 @@
|
|||
this._validateValue(newval, false);
|
||||
}
|
||||
</handler>
|
||||
|
||||
<handler event="focus" phase="capturing">
|
||||
this.inputField.parentNode.setAttribute('focused', 'true');
|
||||
</handler>
|
||||
|
||||
<handler event="blur" phase="capturing">
|
||||
this.inputField.parentNode.removeAttribute('focused');
|
||||
</handler>
|
||||
</handlers>
|
||||
|
||||
</binding>
|
||||
|
|
|
@ -191,12 +191,6 @@ nsNativeThemeGTK::GetGtkWidgetAndState(PRUint8 aWidgetType, nsIFrame* aFrame,
|
|||
memset(aState, 0, sizeof(GtkWidgetState));
|
||||
} else {
|
||||
|
||||
// for dropdown and spinner textfields,
|
||||
// look at the parent frame (textbox or menulist)
|
||||
if (aWidgetType == NS_THEME_DROPDOWN_TEXTFIELD ||
|
||||
aWidgetType == NS_THEME_SPINNER_TEXTFIELD)
|
||||
aFrame = aFrame->GetParent();
|
||||
|
||||
// For XUL checkboxes and radio buttons, the state of the parent
|
||||
// determines our state.
|
||||
nsIFrame *stateFrame = aFrame;
|
||||
|
|
Загрузка…
Ссылка в новой задаче