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

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

Issue 8253002: Move PageTransition into content namespace. While I'm touching all these files, I've also updated... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 9 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 // This code glues the RLZ library DLL with Chrome. It allows Chrome to work 5 // This code glues the RLZ library DLL with Chrome. It allows Chrome to work
6 // with or without the DLL being present. If the DLL is not present the 6 // with or without the DLL being present. If the DLL is not present the
7 // functions do nothing and just return false. 7 // functions do nothing and just return false.
8 8
9 #include "chrome/browser/rlz/rlz.h" 9 #include "chrome/browser/rlz/rlz.h"
10 10
(...skipping 280 matching lines...) Expand 10 before | Expand all | Expand 10 after
291 call_record = true; 291 call_record = true;
292 292
293 registrar_.Remove(this, chrome::NOTIFICATION_OMNIBOX_OPENED_URL, 293 registrar_.Remove(this, chrome::NOTIFICATION_OMNIBOX_OPENED_URL,
294 NotificationService::AllSources()); 294 NotificationService::AllSources());
295 registrar_.Remove(this, chrome::NOTIFICATION_INSTANT_CONTROLLER_UPDATED, 295 registrar_.Remove(this, chrome::NOTIFICATION_INSTANT_CONTROLLER_UPDATED,
296 NotificationService::AllSources()); 296 NotificationService::AllSources());
297 break; 297 break;
298 case content::NOTIFICATION_NAV_ENTRY_PENDING: { 298 case content::NOTIFICATION_NAV_ENTRY_PENDING: {
299 const NavigationEntry* entry = Details<NavigationEntry>(details).ptr(); 299 const NavigationEntry* entry = Details<NavigationEntry>(details).ptr();
300 if (entry != NULL && 300 if (entry != NULL &&
301 ((entry->transition_type() & PageTransition::HOME_PAGE) != 0)) { 301 ((entry->transition_type() &
302 content::PAGE_TRANSITION_HOME_PAGE) != 0)) {
302 point = rlz_lib::CHROME_HOME_PAGE; 303 point = rlz_lib::CHROME_HOME_PAGE;
303 record_used = &homepage_used_; 304 record_used = &homepage_used_;
304 call_record = true; 305 call_record = true;
305 306
306 registrar_.Remove(this, content::NOTIFICATION_NAV_ENTRY_PENDING, 307 registrar_.Remove(this, content::NOTIFICATION_NAV_ENTRY_PENDING,
307 NotificationService::AllSources()); 308 NotificationService::AllSources());
308 } 309 }
309 break; 310 break;
310 } 311 }
311 default: 312 default:
(...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after
389 BrowserThread::FILE, FROM_HERE, 390 BrowserThread::FILE, FROM_HERE,
390 NewRunnableFunction(&RLZTracker::GetAccessPointRlz, point, not_used)); 391 NewRunnableFunction(&RLZTracker::GetAccessPointRlz, point, not_used));
391 return true; 392 return true;
392 } 393 }
393 394
394 // static 395 // static
395 void RLZTracker::CleanupRlz() { 396 void RLZTracker::CleanupRlz() {
396 GetInstance()->rlz_cache_.clear(); 397 GetInstance()->rlz_cache_.clear();
397 GetInstance()->registrar_.RemoveAll(); 398 GetInstance()->registrar_.RemoveAll();
398 } 399 }
OLDNEW
« no previous file with comments | « chrome/browser/printing/print_preview_tab_controller_unittest.cc ('k') | chrome/browser/rlz/rlz_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698