mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-12-04 02:57:38 +00:00
Bug 504183, crash setting focus on file input that has no frame, r=smaug
This commit is contained in:
parent
1076bf5866
commit
aaa7feaf96
12
content/html/content/crashtests/504183-1.html
Normal file
12
content/html/content/crashtests/504183-1.html
Normal file
@ -0,0 +1,12 @@
|
||||
<html class="reftest-wait">
|
||||
<input id="a" type="file">
|
||||
<script>
|
||||
function doe() {
|
||||
var elem = document.getElementById('a');
|
||||
elem.style.display = "none";
|
||||
elem.focus();
|
||||
document.documentElement.className = "";
|
||||
}
|
||||
setTimeout(doe, 0);
|
||||
</script>
|
||||
</html>
|
@ -9,3 +9,4 @@ load 382568-1.html
|
||||
load 423371-1.html
|
||||
load 451123-1.html
|
||||
load 453406-1.html
|
||||
load 504183-1.html
|
||||
|
@ -1368,6 +1368,7 @@ nsHTMLInputElement::Focus()
|
||||
nsIFocusManager* fm = nsFocusManager::GetFocusManager();
|
||||
if (fm && element)
|
||||
fm->SetFocus(element, 0);
|
||||
break;
|
||||
}
|
||||
|
||||
childFrame = childFrame->GetNextSibling();
|
||||
|
Loading…
Reference in New Issue
Block a user