| Index: Source/core/page/FocusController.cpp
|
| diff --git a/Source/core/page/FocusController.cpp b/Source/core/page/FocusController.cpp
|
| index 8981bcc33633ebf533a999f94f1b02b4d79b7201..c11e09d6c95b15cff3657ad44fbe244ac567c438 100644
|
| --- a/Source/core/page/FocusController.cpp
|
| +++ b/Source/core/page/FocusController.cpp
|
| @@ -304,6 +304,12 @@ Frame* FocusController::focusedOrMainFrame() const
|
| {
|
| if (Frame* frame = focusedFrame())
|
| return frame;
|
| +
|
| + for (Frame* frame = m_page->mainFrame()->tree().top(); frame; frame = frame->tree().traverseNext()) {
|
| + if (frame->isLocalRoot())
|
| + return frame;
|
| + }
|
| +
|
| return m_page->mainFrame();
|
| }
|
|
|
| @@ -727,7 +733,9 @@ void FocusController::setActive(bool active)
|
| view->updateControlTints();
|
| }
|
|
|
| - toLocalFrame(focusedOrMainFrame())->selection().pageActivationChanged();
|
| + Frame* frame = focusedOrMainFrame();
|
| + if (frame->isLocalFrame())
|
| + toLocalFrame(frame)->selection().pageActivationChanged();
|
| }
|
|
|
| static void updateFocusCandidateIfNeeded(FocusType type, const FocusCandidate& current, FocusCandidate& candidate, FocusCandidate& closest)
|
|
|