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

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

Issue 10917120: Activate the VariationsService for ChromeOS and ensure that it does not ping the server until the E… (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: init Created 8 years, 3 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 (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
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. 1429 // If we're running tests (ui_task is non-null), then we don't want to
1430 // http://crosbug.com/17687 1430 // call FetchLanguageListFromTranslateServer.
Nikita (slow) 2012/09/10 14:48:55 nit: Comment should be updated so that it doesn't
SteveT 2012/09/10 16:33:02 Ah you're right. Should have left it the way it wa
1431 if (parameters().ui_task == NULL) {
1431 #if !defined(OS_CHROMEOS) 1432 #if !defined(OS_CHROMEOS)
1432 // If we're running tests (ui_task is non-null), then we don't want to 1433 // TODO(mad): Move this call in a proper place on CrOS.
1433 // call FetchLanguageListFromTranslateServer or 1434 // http://crosbug.com/17687
1434 // StartRepeatedVariationsSeedFetch.
1435 if (parameters().ui_task == NULL) {
1436 // Request new variations seed information from server.
1437 browser_process_->variations_service()->
1438 StartRepeatedVariationsSeedFetch();
1439
1440 if (translate_manager_ != NULL) { 1435 if (translate_manager_ != NULL) {
1441 translate_manager_->FetchLanguageListFromTranslateServer( 1436 translate_manager_->FetchLanguageListFromTranslateServer(
1442 profile_->GetPrefs()); 1437 profile_->GetPrefs());
1443 } 1438 }
1439 #endif
1440 // Request new variations seed information from server.
1441 browser_process_->variations_service()->
1442 StartRepeatedVariationsSeedFetch();
1444 } 1443 }
1445 #endif
1446 1444
1447 run_message_loop_ = true; 1445 run_message_loop_ = true;
1448 } else { 1446 } else {
1449 run_message_loop_ = false; 1447 run_message_loop_ = false;
1450 } 1448 }
1451 browser_creator_.reset(); 1449 browser_creator_.reset();
1452 #endif // !defined(OS_ANDROID) 1450 #endif // !defined(OS_ANDROID)
1453 1451
1454 PostBrowserStart(); 1452 PostBrowserStart();
1455 1453
(...skipping 171 matching lines...) Expand 10 before | Expand all | Expand 10 after
1627 if (base::win::GetVersion() <= base::win::VERSION_XP) 1625 if (base::win::GetVersion() <= base::win::VERSION_XP)
1628 uma_name += "_XP"; 1626 uma_name += "_XP";
1629 1627
1630 uma_name += "_PreRead_"; 1628 uma_name += "_PreRead_";
1631 uma_name += pre_read_percentage; 1629 uma_name += pre_read_percentage;
1632 AddPreReadHistogramTime(uma_name.c_str(), time); 1630 AddPreReadHistogramTime(uma_name.c_str(), time);
1633 } 1631 }
1634 #endif 1632 #endif
1635 #endif 1633 #endif
1636 } 1634 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698