| 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/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 1569 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1580 TemplateURL* modifiable_url = const_cast<TemplateURL*>(url); | 1580 TemplateURL* modifiable_url = const_cast<TemplateURL*>(url); |
| 1581 // Don't mark the url as edited, otherwise we won't be able to rev the | 1581 // Don't mark the url as edited, otherwise we won't be able to rev the |
| 1582 // template urls we ship with. | 1582 // template urls we ship with. |
| 1583 modifiable_url->set_show_in_default_list(true); | 1583 modifiable_url->set_show_in_default_list(true); |
| 1584 if (service_.get()) | 1584 if (service_.get()) |
| 1585 service_.get()->UpdateKeyword(*url); | 1585 service_.get()->UpdateKeyword(*url); |
| 1586 | 1586 |
| 1587 const TemplateURLRef* url_ref = url->url(); | 1587 const TemplateURLRef* url_ref = url->url(); |
| 1588 if (url_ref && url_ref->HasGoogleBaseURLs()) { | 1588 if (url_ref && url_ref->HasGoogleBaseURLs()) { |
| 1589 GoogleURLTracker::RequestServerCheck(); | 1589 GoogleURLTracker::RequestServerCheck(); |
| 1590 #if defined(OS_WIN) && defined(GOOGLE_CHROME_BUILD) | 1590 #if defined(ENABLE_RLZ) |
| 1591 // Needs to be evaluated. See http://crbug.com/62328. | 1591 // Needs to be evaluated. See http://crbug.com/62328. |
| 1592 base::ThreadRestrictions::ScopedAllowIO allow_io; | 1592 base::ThreadRestrictions::ScopedAllowIO allow_io; |
| 1593 RLZTracker::RecordProductEvent(rlz_lib::CHROME, | 1593 RLZTracker::RecordProductEvent(rlz_lib::CHROME, |
| 1594 rlz_lib::CHROME_OMNIBOX, | 1594 rlz_lib::CHROME_OMNIBOX, |
| 1595 rlz_lib::SET_TO_GOOGLE); | 1595 rlz_lib::SET_TO_GOOGLE); |
| 1596 #endif | 1596 #endif |
| 1597 } | 1597 } |
| 1598 } | 1598 } |
| 1599 | 1599 |
| 1600 if (!is_default_search_managed_) { | 1600 if (!is_default_search_managed_) { |
| (...skipping 307 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 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 } |
| OLD | NEW |