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

Side by Side Diff: chrome/browser/search_engines/template_url_service.cc

Issue 9699054: rlz: Hook up on mac, switch to chrome's network stack on win. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 8 years, 9 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) 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/search_engines/template_url_service.h" 5 #include "chrome/browser/search_engines/template_url_service.h"
6 6
7 #include "base/auto_reset.h" 7 #include "base/auto_reset.h"
8 #include "base/command_line.h" 8 #include "base/command_line.h"
9 #include "base/environment.h" 9 #include "base/environment.h"
10 #include "base/i18n/case_conversion.h" 10 #include "base/i18n/case_conversion.h"
(...skipping 1570 matching lines...) Expand 10 before | Expand all | Expand 10 after
1581 TemplateURL* modifiable_url = const_cast<TemplateURL*>(url); 1581 TemplateURL* modifiable_url = const_cast<TemplateURL*>(url);
1582 // Don't mark the url as edited, otherwise we won't be able to rev the 1582 // Don't mark the url as edited, otherwise we won't be able to rev the
1583 // template urls we ship with. 1583 // template urls we ship with.
1584 modifiable_url->set_show_in_default_list(true); 1584 modifiable_url->set_show_in_default_list(true);
1585 if (service_.get()) 1585 if (service_.get())
1586 service_.get()->UpdateKeyword(*url); 1586 service_.get()->UpdateKeyword(*url);
1587 1587
1588 const TemplateURLRef* url_ref = url->url(); 1588 const TemplateURLRef* url_ref = url->url();
1589 if (url_ref && url_ref->HasGoogleBaseURLs()) { 1589 if (url_ref && url_ref->HasGoogleBaseURLs()) {
1590 GoogleURLTracker::RequestServerCheck(); 1590 GoogleURLTracker::RequestServerCheck();
1591 #if defined(OS_WIN) && defined(GOOGLE_CHROME_BUILD) 1591 #if (defined(OS_WIN) || defined(OS_MACOSX)) && defined(GOOGLE_CHROME_BUILD)
1592 // Needs to be evaluated. See http://crbug.com/62328. 1592 // Needs to be evaluated. See http://crbug.com/62328.
1593 base::ThreadRestrictions::ScopedAllowIO allow_io; 1593 base::ThreadRestrictions::ScopedAllowIO allow_io;
1594 RLZTracker::RecordProductEvent(rlz_lib::CHROME, 1594 RLZTracker::RecordProductEvent(rlz_lib::CHROME,
1595 rlz_lib::CHROME_OMNIBOX, 1595 rlz_lib::CHROME_OMNIBOX,
1596 rlz_lib::SET_TO_GOOGLE); 1596 rlz_lib::SET_TO_GOOGLE);
1597 #endif 1597 #endif
1598 } 1598 }
1599 } 1599 }
1600 1600
1601 if (!is_default_search_managed_) { 1601 if (!is_default_search_managed_) {
(...skipping 306 matching lines...) Expand 10 before | Expand all | Expand 10 after
1908 dst->set_input_encodings(input_encodings); 1908 dst->set_input_encodings(input_encodings);
1909 dst->set_show_in_default_list(specifics.show_in_default_list()); 1909 dst->set_show_in_default_list(specifics.show_in_default_list());
1910 dst->SetSuggestionsURL(specifics.suggestions_url(), 0, 0); 1910 dst->SetSuggestionsURL(specifics.suggestions_url(), 0, 0);
1911 dst->SetPrepopulateId(specifics.prepopulate_id()); 1911 dst->SetPrepopulateId(specifics.prepopulate_id());
1912 dst->set_autogenerate_keyword(specifics.autogenerate_keyword()); 1912 dst->set_autogenerate_keyword(specifics.autogenerate_keyword());
1913 dst->SetInstantURL(specifics.instant_url(), 0, 0); 1913 dst->SetInstantURL(specifics.instant_url(), 0, 0);
1914 dst->set_last_modified( 1914 dst->set_last_modified(
1915 base::Time::FromInternalValue(specifics.last_modified())); 1915 base::Time::FromInternalValue(specifics.last_modified()));
1916 dst->set_sync_guid(specifics.sync_guid()); 1916 dst->set_sync_guid(specifics.sync_guid());
1917 } 1917 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698