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

Side by Side Diff: content/browser/frame_host/frame_tree_node.cc

Issue 1031133003: favor DCHECK_CURRENTLY_ON for better logs in content/browser (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 9 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
« no previous file with comments | « no previous file | content/browser/gpu/gpu_process_host.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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/browser/frame_host/frame_tree_node.h" 5 #include "content/browser/frame_host/frame_tree_node.h"
6 6
7 #include <queue> 7 #include <queue>
8 8
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/stl_util.h" 10 #include "base/stl_util.h"
(...skipping 14 matching lines...) Expand all
25 25
26 base::LazyInstance<FrameTreeNodeIDMap> g_frame_tree_node_id_map = 26 base::LazyInstance<FrameTreeNodeIDMap> g_frame_tree_node_id_map =
27 LAZY_INSTANCE_INITIALIZER; 27 LAZY_INSTANCE_INITIALIZER;
28 28
29 } // namespace 29 } // namespace
30 30
31 int64 FrameTreeNode::next_frame_tree_node_id_ = 1; 31 int64 FrameTreeNode::next_frame_tree_node_id_ = 1;
32 32
33 // static 33 // static
34 FrameTreeNode* FrameTreeNode::GloballyFindByID(int64 frame_tree_node_id) { 34 FrameTreeNode* FrameTreeNode::GloballyFindByID(int64 frame_tree_node_id) {
35 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); 35 DCHECK_CURRENTLY_ON(BrowserThread::UI);
36 FrameTreeNodeIDMap* nodes = g_frame_tree_node_id_map.Pointer(); 36 FrameTreeNodeIDMap* nodes = g_frame_tree_node_id_map.Pointer();
37 FrameTreeNodeIDMap::iterator it = nodes->find(frame_tree_node_id); 37 FrameTreeNodeIDMap::iterator it = nodes->find(frame_tree_node_id);
38 return it == nodes->end() ? nullptr : it->second; 38 return it == nodes->end() ? nullptr : it->second;
39 } 39 }
40 40
41 FrameTreeNode::FrameTreeNode(FrameTree* frame_tree, 41 FrameTreeNode::FrameTreeNode(FrameTree* frame_tree,
42 Navigator* navigator, 42 Navigator* navigator,
43 RenderFrameHostDelegate* render_frame_delegate, 43 RenderFrameHostDelegate* render_frame_delegate,
44 RenderViewHostDelegate* render_view_delegate, 44 RenderViewHostDelegate* render_view_delegate,
45 RenderWidgetHostDelegate* render_widget_delegate, 45 RenderWidgetHostDelegate* render_widget_delegate,
(...skipping 117 matching lines...) Expand 10 before | Expand all | Expand 10 after
163 } 163 }
164 164
165 bool FrameTreeNode::CommitPendingSandboxFlags() { 165 bool FrameTreeNode::CommitPendingSandboxFlags() {
166 bool did_change_flags = 166 bool did_change_flags =
167 effective_sandbox_flags_ != replication_state_.sandbox_flags; 167 effective_sandbox_flags_ != replication_state_.sandbox_flags;
168 effective_sandbox_flags_ = replication_state_.sandbox_flags; 168 effective_sandbox_flags_ = replication_state_.sandbox_flags;
169 return did_change_flags; 169 return did_change_flags;
170 } 170 }
171 171
172 } // namespace content 172 } // namespace content
OLDNEW
« no previous file with comments | « no previous file | content/browser/gpu/gpu_process_host.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698