Bug 342432: After Undo Close Tab, content area of newly-opened page isn't focused, patch by Simon B�nzli <zeniko@gmail.com>, r=mano

This commit is contained in:
gavin%gavinsharp.com 2006-09-12 22:25:22 +00:00
Родитель 0416c56105
Коммит 9aefd82c9e
1 изменённых файлов: 4 добавлений и 0 удалений

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

@ -680,6 +680,10 @@ SessionStoreService.prototype = {
// restore tab content
this.restoreHistoryPrecursor(aWindow, [closedTabState], 1, 0, 0);
// focus the tab's content area
var content = browser.getBrowserForTab(closedTabState._tab).contentWindow;
aWindow.setTimeout(function() { content.focus(); }, 0);
}
else {
Components.returnCode = Cr.NS_ERROR_INVALID_ARG;