Index: content/browser/frame_host/interstitial_page_impl.cc |
diff --git a/content/browser/frame_host/interstitial_page_impl.cc b/content/browser/frame_host/interstitial_page_impl.cc |
index 41470a421e55ecf31507396cc318b61e01f48516..e46ed84e8ec85f53cdee62ce8a89f65cb6fb9fe9 100644 |
--- a/content/browser/frame_host/interstitial_page_impl.cc |
+++ b/content/browser/frame_host/interstitial_page_impl.cc |
@@ -249,9 +249,6 @@ void InterstitialPageImpl::Show() { |
notification_registrar_.Add(this, NOTIFICATION_NAV_ENTRY_PENDING, |
Source<NavigationController>(controller_)); |
- notification_registrar_.Add( |
- this, NOTIFICATION_DOM_OPERATION_RESPONSE, |
- Source<RenderViewHost>(render_view_host_)); |
} |
void InterstitialPageImpl::Hide() { |
@@ -346,13 +343,6 @@ void InterstitialPageImpl::Observe( |
TakeActionOnResourceDispatcher(CANCEL); |
} |
break; |
- case NOTIFICATION_DOM_OPERATION_RESPONSE: |
- if (enabled()) { |
- Details<DomOperationNotificationDetails> dom_op_details( |
- details); |
- delegate_->CommandReceived(dom_op_details->json); |
- } |
- break; |
default: |
NOTREACHED(); |
} |
@@ -375,6 +365,18 @@ void InterstitialPageImpl::RenderFrameCreated( |
render_frame_host); |
} |
+void InterstitialPageImpl::OnDomOperationResponse( |
+ const DomOperationNotificationDetails& details) { |
+ // Needed by test code. |
+ NotificationService::current()->Notify( |
+ NOTIFICATION_DOM_OPERATION_RESPONSE, |
+ Source<WebContents>(web_contents()), |
+ Details<const DomOperationNotificationDetails>(&details)); |
+ if (!enabled()) |
+ return; |
+ delegate_->CommandReceived(details.json); |
+} |
+ |
RenderViewHostDelegateView* InterstitialPageImpl::GetDelegateView() { |
return rvh_delegate_view_.get(); |
} |