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

Unified Diff: content/renderer/render_thread_impl.h

Issue 23694031: Fix race conditions in window snapshot code. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Addressed Nit Created 7 years, 2 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « content/renderer/gpu/render_widget_compositor.cc ('k') | content/renderer/render_thread_impl.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/renderer/render_thread_impl.h
diff --git a/content/renderer/render_thread_impl.h b/content/renderer/render_thread_impl.h
index 59b7c1d3e4c8c0a942deb54ed42265a6575a4407..aea1836292cd9c00cac282cdd0264835e06efbb8 100644
--- a/content/renderer/render_thread_impl.h
+++ b/content/renderer/render_thread_impl.h
@@ -11,6 +11,7 @@
#include "base/memory/memory_pressure_listener.h"
#include "base/observer_list.h"
+#include "base/process/process_handle.h"
#include "base/strings/string16.h"
#include "base/timer/timer.h"
#include "build/build_config.h"
@@ -343,6 +344,11 @@ class CONTENT_EXPORT RenderThreadImpl : public RenderThread,
// Retrieve current gamepad data.
void SampleGamepads(WebKit::WebGamepads* data);
+ // Get the browser process's notion of the renderer process's ID.
+ // This is the first argument to RenderWidgetHost::FromID. Ideally
+ // this would be available on all platforms via base::Process.
+ base::ProcessId renderer_process_id() const;
+
private:
// ChildThread
virtual bool OnControlMessageReceived(const IPC::Message& msg) OVERRIDE;
@@ -374,6 +380,7 @@ class CONTENT_EXPORT RenderThreadImpl : public RenderThread,
void OnNetworkStateChanged(bool online);
void OnGetAccessibilityTree();
void OnTempCrashWithData(const GURL& data);
+ void OnSetRendererProcessID(base::ProcessId process_id);
void OnSetWebKitSharedTimersSuspended(bool suspend);
void OnMemoryPressure(
base::MemoryPressureListener::MemoryPressureLevel memory_pressure_level);
@@ -486,6 +493,8 @@ class CONTENT_EXPORT RenderThreadImpl : public RenderThread,
scoped_ptr<GamepadSharedMemoryReader> gamepad_shared_memory_reader_;
+ base::ProcessId renderer_process_id_;
+
DISALLOW_COPY_AND_ASSIGN(RenderThreadImpl);
};
« no previous file with comments | « content/renderer/gpu/render_widget_compositor.cc ('k') | content/renderer/render_thread_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698