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

Side by Side Diff: chrome/browser/budget_service/budget_database.cc

Issue 2598963005: Include-what-you-use for WrapUnique/MakeUnique. (Closed)
Patch Set: restore order of includes in x11_topmost_window_finder_interactive_uitest.cc Created 3 years, 12 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
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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/budget_service/budget_database.h" 5 #include "chrome/browser/budget_service/budget_database.h"
6 6
7 #include "base/memory/ptr_util.h"
7 #include "base/metrics/histogram_macros.h" 8 #include "base/metrics/histogram_macros.h"
8 #include "base/time/clock.h" 9 #include "base/time/clock.h"
9 #include "base/time/default_clock.h" 10 #include "base/time/default_clock.h"
10 #include "chrome/browser/budget_service/budget.pb.h" 11 #include "chrome/browser/budget_service/budget.pb.h"
11 #include "chrome/browser/engagement/site_engagement_score.h" 12 #include "chrome/browser/engagement/site_engagement_score.h"
12 #include "chrome/browser/engagement/site_engagement_service.h" 13 #include "chrome/browser/engagement/site_engagement_service.h"
13 #include "chrome/browser/profiles/profile.h" 14 #include "chrome/browser/profiles/profile.h"
14 #include "components/leveldb_proto/proto_database_impl.h" 15 #include "components/leveldb_proto/proto_database_impl.h"
15 #include "content/public/browser/browser_thread.h" 16 #include "content/public/browser/browser_thread.h"
16 #include "url/gurl.h" 17 #include "url/gurl.h"
(...skipping 343 matching lines...) Expand 10 before | Expand all | Expand 10 after
360 clock_->Now() - base::TimeDelta::FromHours(kBudgetDurationInHours)) { 361 clock_->Now() - base::TimeDelta::FromHours(kBudgetDurationInHours)) {
361 budget_map_.erase(origin); 362 budget_map_.erase(origin);
362 return true; 363 return true;
363 } 364 }
364 365
365 // Although some things may have expired, there are some chunks still valid. 366 // Although some things may have expired, there are some chunks still valid.
366 // Don't write to the DB now, write either when all chunks expire or when the 367 // Don't write to the DB now, write either when all chunks expire or when the
367 // origin spends some budget. 368 // origin spends some budget.
368 return false; 369 return false;
369 } 370 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698