Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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/chrome_browser_main.h" | 5 #include "chrome/browser/chrome_browser_main.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 #include <string> | 8 #include <string> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| (...skipping 1408 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1419 #if defined(OS_MACOSX) | 1419 #if defined(OS_MACOSX) |
| 1420 // Call Recycle() here as late as possible, before going into the loop | 1420 // Call Recycle() here as late as possible, before going into the loop |
| 1421 // because Start() will add things to it while creating the main window. | 1421 // because Start() will add things to it while creating the main window. |
| 1422 if (parameters().autorelease_pool) | 1422 if (parameters().autorelease_pool) |
| 1423 parameters().autorelease_pool->Recycle(); | 1423 parameters().autorelease_pool->Recycle(); |
| 1424 #endif | 1424 #endif |
| 1425 | 1425 |
| 1426 RecordPreReadExperimentTime("Startup.BrowserOpenTabs", | 1426 RecordPreReadExperimentTime("Startup.BrowserOpenTabs", |
| 1427 base::TimeTicks::Now() - browser_open_start); | 1427 base::TimeTicks::Now() - browser_open_start); |
| 1428 | 1428 |
| 1429 // TODO(mad): Move this call in a proper place on CrOS. | |
| 1430 // http://crosbug.com/17687 | |
| 1431 #if !defined(OS_CHROMEOS) | |
| 1432 // If we're running tests (ui_task is non-null), then we don't want to | 1429 // If we're running tests (ui_task is non-null), then we don't want to |
| 1433 // call FetchLanguageListFromTranslateServer or | 1430 // call FetchLanguageListFromTranslateServer or |
| 1434 // StartRepeatedVariationsSeedFetch. | 1431 // StartRepeatedVariationsSeedFetch. |
| 1435 if (parameters().ui_task == NULL) { | 1432 if (parameters().ui_task == NULL) { |
| 1436 // Request new variations seed information from server. | 1433 #if !defined(OS_CHROMEOS) |
| 1437 browser_process_->variations_service()-> | 1434 // TODO(mad): Move this call in a proper place on CrOS. |
| 1438 StartRepeatedVariationsSeedFetch(); | 1435 // http://crosbug.com/17687 |
| 1439 | |
| 1440 if (translate_manager_ != NULL) { | 1436 if (translate_manager_ != NULL) { |
| 1441 translate_manager_->FetchLanguageListFromTranslateServer( | 1437 translate_manager_->FetchLanguageListFromTranslateServer( |
| 1442 profile_->GetPrefs()); | 1438 profile_->GetPrefs()); |
| 1443 } | 1439 } |
| 1440 #endif | |
| 1441 // Request new variations seed information from server. | |
|
MAD
2012/09/10 17:35:03
This is not within "if (parameters().ui_task == NU
SteveT
2012/09/10 19:33:52
It still is. Perhaps it'd be more clear if I moved
MAD
2012/09/10 19:46:17
D'Ho! :-)
Yeah, maybe it would be better...
Sorry
| |
| 1442 browser_process_->variations_service()-> | |
| 1443 StartRepeatedVariationsSeedFetch(); | |
| 1444 } | 1444 } |
| 1445 #endif | |
| 1446 | 1445 |
| 1447 run_message_loop_ = true; | 1446 run_message_loop_ = true; |
| 1448 } else { | 1447 } else { |
| 1449 run_message_loop_ = false; | 1448 run_message_loop_ = false; |
| 1450 } | 1449 } |
| 1451 browser_creator_.reset(); | 1450 browser_creator_.reset(); |
| 1452 #endif // !defined(OS_ANDROID) | 1451 #endif // !defined(OS_ANDROID) |
| 1453 | 1452 |
| 1454 PostBrowserStart(); | 1453 PostBrowserStart(); |
| 1455 | 1454 |
| (...skipping 171 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1627 if (base::win::GetVersion() <= base::win::VERSION_XP) | 1626 if (base::win::GetVersion() <= base::win::VERSION_XP) |
| 1628 uma_name += "_XP"; | 1627 uma_name += "_XP"; |
| 1629 | 1628 |
| 1630 uma_name += "_PreRead_"; | 1629 uma_name += "_PreRead_"; |
| 1631 uma_name += pre_read_percentage; | 1630 uma_name += pre_read_percentage; |
| 1632 AddPreReadHistogramTime(uma_name.c_str(), time); | 1631 AddPreReadHistogramTime(uma_name.c_str(), time); |
| 1633 } | 1632 } |
| 1634 #endif | 1633 #endif |
| 1635 #endif | 1634 #endif |
| 1636 } | 1635 } |
| OLD | NEW |