зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1071631 - fix findbar re-filling in last character, r=mikedeboer
--HG-- extra : commitid : 3KDFc8SayaU extra : rebase_source : 01e8ca9fdcf52e3380ef4b634d1134e9a83ad422
This commit is contained in:
Родитель
5da6b02777
Коммит
182520fa90
|
@ -74,6 +74,14 @@
|
|||
if (this.findbar._isIMEComposing) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (this._hadValue && !this.value) {
|
||||
this._willfullyDeleted = true;
|
||||
this._hadValue = false;
|
||||
} else if (this.value.trim()) {
|
||||
this._hadValue = true;
|
||||
this._willfullyDeleted = false;
|
||||
}
|
||||
this.findbar._find(this.value);
|
||||
]]></handler>
|
||||
|
||||
|
@ -1101,8 +1109,10 @@
|
|||
return;
|
||||
|
||||
let clipboardSearchString = this._browser.finder.clipboardSearchString;
|
||||
if (clipboardSearchString && this._findField.value != clipboardSearchString) {
|
||||
if (clipboardSearchString && this._findField.value != clipboardSearchString &&
|
||||
!this._findField._willfullyDeleted) {
|
||||
this._findField.value = clipboardSearchString;
|
||||
this._findField._hadValue = true;
|
||||
// Changing the search string makes the previous status invalid, so
|
||||
// we better clear it here.
|
||||
this._updateStatusUI();
|
||||
|
|
Загрузка…
Ссылка в новой задаче