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

Side by Side Diff: chrome/browser/visitedlink_event_listener.cc

Issue 3106018: Reapplies all the IPC system work (reverts the revert r56272). (Closed) Base URL: http://src.chromium.org/git/chromium.git
Patch Set: Created 10 years, 4 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 | « chrome/browser/renderer_host/sync_resource_handler.cc ('k') | chrome/chrome.gyp » ('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 (c) 2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2009 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 "chrome/browser/visitedlink_event_listener.h" 5 #include "chrome/browser/visitedlink_event_listener.h"
6 6
7 #include "base/shared_memory.h" 7 #include "base/shared_memory.h"
8 #include "chrome/browser/renderer_host/render_process_host.h" 8 #include "chrome/browser/renderer_host/render_process_host.h"
9 #include "chrome/common/render_messages.h"
10 9
11 using base::Time; 10 using base::Time;
12 using base::TimeDelta; 11 using base::TimeDelta;
13 12
14 // The amount of time we wait to accumulate visited link additions. 13 // The amount of time we wait to accumulate visited link additions.
15 static const int kCommitIntervalMs = 100; 14 static const int kCommitIntervalMs = 100;
16 15
17 void VisitedLinkEventListener::NewTable(base::SharedMemory* table_memory) { 16 void VisitedLinkEventListener::NewTable(base::SharedMemory* table_memory) {
18 if (!table_memory) 17 if (!table_memory)
19 return; 18 return;
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
51 50
52 void VisitedLinkEventListener::CommitVisitedLinks() { 51 void VisitedLinkEventListener::CommitVisitedLinks() {
53 // Send to all RenderProcessHosts. 52 // Send to all RenderProcessHosts.
54 for (RenderProcessHost::iterator i(RenderProcessHost::AllHostsIterator()); 53 for (RenderProcessHost::iterator i(RenderProcessHost::AllHostsIterator());
55 !i.IsAtEnd(); i.Advance()) { 54 !i.IsAtEnd(); i.Advance()) {
56 i.GetCurrentValue()->AddVisitedLinks(pending_visited_links_); 55 i.GetCurrentValue()->AddVisitedLinks(pending_visited_links_);
57 } 56 }
58 57
59 pending_visited_links_.clear(); 58 pending_visited_links_.clear();
60 } 59 }
OLDNEW
« no previous file with comments | « chrome/browser/renderer_host/sync_resource_handler.cc ('k') | chrome/chrome.gyp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698