In BrowserWindow::_TabChanged(), the BWebView could be NULL. Also check if there
is a focused view set at all. git-svn-id: http://svn.haiku-os.org/webpositive/webkit/trunk@398 94f232f2-1747-11df-bad5-a5bfde151594
This commit is contained in:
committed by
Alexandre Deckner
parent
845ec8e102
commit
8061d9ebff
@@ -1228,17 +1228,19 @@ BrowserWindow::_TabChanged(int32 index)
|
|||||||
|
|
||||||
SetCurrentWebView(webView);
|
SetCurrentWebView(webView);
|
||||||
|
|
||||||
PageUserData* userData = static_cast<PageUserData*>(webView->GetUserData());
|
|
||||||
if (userData)
|
|
||||||
userData->FocusedView()->MakeFocus(true);
|
|
||||||
else
|
|
||||||
webView->MakeFocus(true);
|
|
||||||
|
|
||||||
if (webView)
|
if (webView)
|
||||||
_UpdateTitle(webView->MainFrameTitle());
|
_UpdateTitle(webView->MainFrameTitle());
|
||||||
else
|
else
|
||||||
_UpdateTitle("");
|
_UpdateTitle("");
|
||||||
|
|
||||||
if (webView) {
|
if (webView) {
|
||||||
|
PageUserData* userData = static_cast<PageUserData*>(
|
||||||
|
webView->GetUserData());
|
||||||
|
if (userData && userData->FocusedView() != NULL)
|
||||||
|
userData->FocusedView()->MakeFocus(true);
|
||||||
|
else
|
||||||
|
webView->MakeFocus(true);
|
||||||
|
|
||||||
fURLTextControl->SetText(webView->MainFrameURL());
|
fURLTextControl->SetText(webView->MainFrameURL());
|
||||||
// Trigger update of the interface to the new page, by requesting
|
// Trigger update of the interface to the new page, by requesting
|
||||||
// to resend all notifications.
|
// to resend all notifications.
|
||||||
|
|||||||
Reference in New Issue
Block a user