Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(87)

Side by Side Diff: content/browser/renderer_host/render_widget_host_impl.h

Issue 1159143008: Fix wrong initialization of renderer_initiated_creation parameter. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: addressing mmenke@'s comments Created 5 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 #ifndef CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_IMPL_H_ 5 #ifndef CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_IMPL_H_
6 #define CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_IMPL_H_ 6 #define CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_IMPL_H_
7 7
8 #include <deque> 8 #include <deque>
9 #include <list> 9 #include <list>
10 #include <map> 10 #include <map>
(...skipping 460 matching lines...) Expand 10 before | Expand all | Expand 10 after
471 // Get the BrowserAccessibilityManager for the root of the frame tree, 471 // Get the BrowserAccessibilityManager for the root of the frame tree,
472 // or create it if it doesn't already exist. 472 // or create it if it doesn't already exist.
473 BrowserAccessibilityManager* GetOrCreateRootBrowserAccessibilityManager(); 473 BrowserAccessibilityManager* GetOrCreateRootBrowserAccessibilityManager();
474 474
475 void RejectMouseLockOrUnlockIfNecessary(); 475 void RejectMouseLockOrUnlockIfNecessary();
476 476
477 #if defined(OS_WIN) 477 #if defined(OS_WIN)
478 gfx::NativeViewAccessible GetParentNativeViewAccessible(); 478 gfx::NativeViewAccessible GetParentNativeViewAccessible();
479 #endif 479 #endif
480 480
481 void set_renderer_initialized(bool renderer_initialized) {
482 renderer_initialized_ = renderer_initialized;
483 }
484
481 protected: 485 protected:
482 RenderWidgetHostImpl* AsRenderWidgetHostImpl() override; 486 RenderWidgetHostImpl* AsRenderWidgetHostImpl() override;
483 487
484 // Called when we receive a notification indicating that the renderer 488 // Called when we receive a notification indicating that the renderer
485 // process has gone. This will reset our state so that our state will be 489 // process has gone. This will reset our state so that our state will be
486 // consistent if a new renderer is created. 490 // consistent if a new renderer is created.
487 void RendererExited(base::TerminationStatus status, int exit_code); 491 void RendererExited(base::TerminationStatus status, int exit_code);
488 492
489 // Retrieves an id the renderer can use to refer to its view. 493 // Retrieves an id the renderer can use to refer to its view.
490 // This is used for various IPC messages, including plugins. 494 // This is used for various IPC messages, including plugins.
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after
546 void SetInitialRenderSizeParams(const ViewMsg_Resize_Params& resize_params); 550 void SetInitialRenderSizeParams(const ViewMsg_Resize_Params& resize_params);
547 551
548 // Expose increment/decrement of the in-flight event count, so 552 // Expose increment/decrement of the in-flight event count, so
549 // RenderViewHostImpl can account for in-flight beforeunload/unload events. 553 // RenderViewHostImpl can account for in-flight beforeunload/unload events.
550 int increment_in_flight_event_count() { return ++in_flight_event_count_; } 554 int increment_in_flight_event_count() { return ++in_flight_event_count_; }
551 int decrement_in_flight_event_count() { 555 int decrement_in_flight_event_count() {
552 DCHECK_GT(in_flight_event_count_, 0); 556 DCHECK_GT(in_flight_event_count_, 0);
553 return --in_flight_event_count_; 557 return --in_flight_event_count_;
554 } 558 }
555 559
556 void set_renderer_initialized(bool renderer_initialized) {
557 renderer_initialized_ = renderer_initialized;
558 }
559
560 bool renderer_initialized() const { return renderer_initialized_; } 560 bool renderer_initialized() const { return renderer_initialized_; }
561 561
562 // The View associated with the RenderViewHost. The lifetime of this object 562 // The View associated with the RenderViewHost. The lifetime of this object
563 // is associated with the lifetime of the Render process. If the Renderer 563 // is associated with the lifetime of the Render process. If the Renderer
564 // crashes, its View is destroyed and this pointer becomes NULL, even though 564 // crashes, its View is destroyed and this pointer becomes NULL, even though
565 // render_view_host_ lives on to load another URL (creating a new View while 565 // render_view_host_ lives on to load another URL (creating a new View while
566 // doing so). 566 // doing so).
567 RenderWidgetHostViewBase* view_; 567 RenderWidgetHostViewBase* view_;
568 568
569 // A weak pointer to the view. The above pointer should be weak, but changing 569 // A weak pointer to the view. The above pointer should be weak, but changing
(...skipping 261 matching lines...) Expand 10 before | Expand all | Expand 10 after
831 bool is_focused_; 831 bool is_focused_;
832 832
833 base::WeakPtrFactory<RenderWidgetHostImpl> weak_factory_; 833 base::WeakPtrFactory<RenderWidgetHostImpl> weak_factory_;
834 834
835 DISALLOW_COPY_AND_ASSIGN(RenderWidgetHostImpl); 835 DISALLOW_COPY_AND_ASSIGN(RenderWidgetHostImpl);
836 }; 836 };
837 837
838 } // namespace content 838 } // namespace content
839 839
840 #endif // CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_IMPL_H_ 840 #endif // CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_IMPL_H_
OLDNEW
« no previous file with comments | « content/browser/frame_host/render_frame_host_impl.cc ('k') | content/browser/web_contents/web_contents_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698