| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "content/renderer/render_view_impl.h" | 5 #include "content/renderer/render_view_impl.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 #include <cmath> | 8 #include <cmath> |
| 9 #include <string> | 9 #include <string> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 343 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 354 if (counter) { | 354 if (counter) { |
| 355 shared_popup_counter_ = counter; | 355 shared_popup_counter_ = counter; |
| 356 shared_popup_counter_->data++; | 356 shared_popup_counter_->data++; |
| 357 decrement_shared_popup_at_destruction_ = true; | 357 decrement_shared_popup_at_destruction_ = true; |
| 358 } else { | 358 } else { |
| 359 shared_popup_counter_ = new SharedRenderViewCounter(0); | 359 shared_popup_counter_ = new SharedRenderViewCounter(0); |
| 360 decrement_shared_popup_at_destruction_ = false; | 360 decrement_shared_popup_at_destruction_ = false; |
| 361 } | 361 } |
| 362 | 362 |
| 363 intents_dispatcher_ = new IntentsDispatcher(this); | 363 intents_dispatcher_ = new IntentsDispatcher(this); |
| 364 |
| 365 #if defined(ENABLE_NOTIFICATIONS) |
| 364 notification_provider_ = new NotificationProvider(this); | 366 notification_provider_ = new NotificationProvider(this); |
| 367 #else |
| 368 notification_provider_ = NULL; |
| 369 #endif |
| 365 | 370 |
| 366 RenderThread::Get()->AddRoute(routing_id_, this); | 371 RenderThread::Get()->AddRoute(routing_id_, this); |
| 367 // Take a reference on behalf of the RenderThread. This will be balanced | 372 // Take a reference on behalf of the RenderThread. This will be balanced |
| 368 // when we receive ViewMsg_ClosePage. | 373 // when we receive ViewMsg_ClosePage. |
| 369 AddRef(); | 374 AddRef(); |
| 370 | 375 |
| 371 // If this is a popup, we must wait for the CreatingNew_ACK message before | 376 // If this is a popup, we must wait for the CreatingNew_ACK message before |
| 372 // completing initialization. Otherwise, we can finish it now. | 377 // completing initialization. Otherwise, we can finish it now. |
| 373 if (opener_id == MSG_ROUTING_NONE) { | 378 if (opener_id == MSG_ROUTING_NONE) { |
| 374 did_show_ = true; | 379 did_show_ = true; |
| (...skipping 4292 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4667 return webview()->settings()->useThreadedCompositor(); | 4672 return webview()->settings()->useThreadedCompositor(); |
| 4668 } | 4673 } |
| 4669 | 4674 |
| 4670 void RenderViewImpl::OnJavaBridgeInit( | 4675 void RenderViewImpl::OnJavaBridgeInit( |
| 4671 const IPC::ChannelHandle& channel_handle) { | 4676 const IPC::ChannelHandle& channel_handle) { |
| 4672 DCHECK(!java_bridge_dispatcher_.get()); | 4677 DCHECK(!java_bridge_dispatcher_.get()); |
| 4673 #if defined(ENABLE_JAVA_BRIDGE) | 4678 #if defined(ENABLE_JAVA_BRIDGE) |
| 4674 java_bridge_dispatcher_.reset(new JavaBridgeDispatcher(this, channel_handle)); | 4679 java_bridge_dispatcher_.reset(new JavaBridgeDispatcher(this, channel_handle)); |
| 4675 #endif | 4680 #endif |
| 4676 } | 4681 } |
| OLD | NEW |