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

Unified Diff: chrome/browser/background/background_mode_manager_mac.mm

Issue 1103343005: favor DCHECK_CURRENTLY_ON for better logs in chrome/browser/autocomplete,banners,background (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 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
Index: chrome/browser/background/background_mode_manager_mac.mm
diff --git a/chrome/browser/background/background_mode_manager_mac.mm b/chrome/browser/background/background_mode_manager_mac.mm
index 3b1dd7d3e0d74c1fc2019b5c6423fcd6545b9a4c..3cebfbc943c41b872f0082dcd95c4b62ccae1d7d 100644
--- a/chrome/browser/background/background_mode_manager_mac.mm
+++ b/chrome/browser/background/background_mode_manager_mac.mm
@@ -18,19 +18,19 @@ using content::BrowserThread;
namespace {
void SetUserRemovedLoginItemPrefOnUIThread() {
- DCHECK(content::BrowserThread::CurrentlyOn(content::BrowserThread::UI));
+ DCHECK_CURRENTLY_ON(content::BrowserThread::UI);
PrefService* service = g_browser_process->local_state();
service->SetBoolean(prefs::kUserRemovedLoginItem, true);
}
void SetCreatedLoginItemPrefOnUIThread() {
- DCHECK(content::BrowserThread::CurrentlyOn(content::BrowserThread::UI));
+ DCHECK_CURRENTLY_ON(content::BrowserThread::UI);
PrefService* service = g_browser_process->local_state();
service->SetBoolean(prefs::kChromeCreatedLoginItem, true);
}
void DisableLaunchOnStartupOnFileThread() {
- DCHECK(content::BrowserThread::CurrentlyOn(content::BrowserThread::FILE));
+ DCHECK_CURRENTLY_ON(content::BrowserThread::FILE);
// If the LoginItem is not hidden, it means it's user created, so don't
// delete it.
bool is_hidden = false;
@@ -39,7 +39,7 @@ void DisableLaunchOnStartupOnFileThread() {
}
void CheckForUserRemovedLoginItemOnFileThread() {
- DCHECK(content::BrowserThread::CurrentlyOn(content::BrowserThread::FILE));
+ DCHECK_CURRENTLY_ON(content::BrowserThread::FILE);
if (!base::mac::CheckLoginItemStatus(NULL)) {
// There's no LoginItem, so set the kUserRemovedLoginItem pref.
BrowserThread::PostTask(BrowserThread::UI, FROM_HERE,
@@ -48,7 +48,7 @@ void CheckForUserRemovedLoginItemOnFileThread() {
}
void EnableLaunchOnStartupOnFileThread(bool need_migration) {
- DCHECK(content::BrowserThread::CurrentlyOn(content::BrowserThread::FILE));
+ DCHECK_CURRENTLY_ON(content::BrowserThread::FILE);
if (need_migration) {
// This is the first time running Chrome since the kChromeCreatedLoginItem
// pref was added. Initialize the status of this pref based on whether
« no previous file with comments | « chrome/browser/autocomplete/in_memory_url_index.cc ('k') | chrome/browser/banners/app_banner_data_fetcher.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698