| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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/content_settings/content_settings_usages_state.h" | 5 #include "chrome/browser/content_settings/content_settings_usages_state.h" |
| 6 | 6 |
| 7 #include <string> | 7 #include <string> |
| 8 | 8 |
| 9 #include "base/prefs/pref_service.h" | 9 #include "base/prefs/pref_service.h" |
| 10 #include "base/strings/string_piece.h" | 10 #include "base/strings/string_piece.h" |
| (...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 94 *tab_state_flags |= TABSTATE_HAS_EXCEPTION; | 94 *tab_state_flags |= TABSTATE_HAS_EXCEPTION; |
| 95 if (saved_setting != i->second) | 95 if (saved_setting != i->second) |
| 96 *tab_state_flags |= TABSTATE_HAS_CHANGED; | 96 *tab_state_flags |= TABSTATE_HAS_CHANGED; |
| 97 if (saved_setting != CONTENT_SETTING_ASK) | 97 if (saved_setting != CONTENT_SETTING_ASK) |
| 98 *tab_state_flags |= TABSTATE_HAS_ANY_ICON; | 98 *tab_state_flags |= TABSTATE_HAS_ANY_ICON; |
| 99 } | 99 } |
| 100 } | 100 } |
| 101 | 101 |
| 102 std::string ContentSettingsUsagesState::GURLToFormattedHost( | 102 std::string ContentSettingsUsagesState::GURLToFormattedHost( |
| 103 const GURL& url) const { | 103 const GURL& url) const { |
| 104 string16 display_host; | 104 base::string16 display_host; |
| 105 net::AppendFormattedHost(url, | 105 net::AppendFormattedHost(url, |
| 106 profile_->GetPrefs()->GetString(prefs::kAcceptLanguages), &display_host); | 106 profile_->GetPrefs()->GetString(prefs::kAcceptLanguages), &display_host); |
| 107 return UTF16ToUTF8(display_host); | 107 return UTF16ToUTF8(display_host); |
| 108 } | 108 } |
| OLD | NEW |