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

Unified Diff: content/browser/frame_host/frame_tree_node.h

Issue 1901023003: Introduce browser side FrameTreeNodeBlameContext (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Remove thread safety handling (and its doc) Created 4 years, 8 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/browser/frame_host/frame_tree.cc ('k') | content/browser/frame_host/frame_tree_node.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/frame_host/frame_tree_node.h
diff --git a/content/browser/frame_host/frame_tree_node.h b/content/browser/frame_host/frame_tree_node.h
index d38185808db2c6eb11f4130ed031e24a5b72a7c2..15df53db42c4281c646a4873951918faa3b47320 100644
--- a/content/browser/frame_host/frame_tree_node.h
+++ b/content/browser/frame_host/frame_tree_node.h
@@ -13,6 +13,7 @@
#include "base/macros.h"
#include "base/memory/ref_counted.h"
+#include "content/browser/frame_host/frame_tree_node_blame_context.h"
#include "content/browser/frame_host/render_frame_host_impl.h"
#include "content/browser/frame_host/render_frame_host_manager.h"
#include "content/common/content_export.h"
@@ -265,13 +266,19 @@ class CONTENT_EXPORT FrameTreeNode {
// FrameTreeNode.
void BeforeUnloadCanceled();
+ // Creates and initializes a new FrameTreeNodeBlameContext for tracing
+ // snapshots of this node and attributing browser process activities to it.
+ void InitializeBlameContext();
+
+ FrameTreeNodeBlameContext* blame_context() const {
+ return blame_context_.get();
+ }
+
private:
class OpenerDestroyedObserver;
void set_parent(FrameTreeNode* parent) { parent_ = parent; }
- void TraceSnapshot() const;
-
// The next available browser-global FrameTreeNode ID.
static int next_frame_tree_node_id_;
@@ -347,6 +354,12 @@ class CONTENT_EXPORT FrameTreeNode {
base::TimeTicks last_focus_time_;
+ // The FrameTreeNodeBlameContext object for tracing the snapshots of this
+ // FrameTreeNode and attributing browser process activities to this node
+ // (when possible). It is unrelated to the core logic of FrameTreeNode.
+ // See frame_tree_node_blame_context.h for more detailed documentation.
+ std::unique_ptr<FrameTreeNodeBlameContext> blame_context_;
+
DISALLOW_COPY_AND_ASSIGN(FrameTreeNode);
};
« no previous file with comments | « content/browser/frame_host/frame_tree.cc ('k') | content/browser/frame_host/frame_tree_node.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698