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

Side by Side Diff: chrome/browser/geolocation/geolocation_settings_state.cc

Issue 5606002: Move:... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 10 years 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) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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/geolocation/geolocation_settings_state.h" 5 #include "chrome/browser/geolocation/geolocation_settings_state.h"
6 6
7 #include "base/string_piece.h" 7 #include "base/string_piece.h"
8 #include "base/utf_string_conversions.h" 8 #include "base/utf_string_conversions.h"
9 #include "chrome/browser/geolocation/geolocation_content_settings_map.h" 9 #include "chrome/browser/geolocation/geolocation_content_settings_map.h"
10 #include "chrome/browser/prefs/pref_service.h" 10 #include "chrome/browser/prefs/pref_service.h"
11 #include "chrome/browser/profile.h" 11 #include "chrome/browser/profiles/profile.h"
12 #include "chrome/browser/tab_contents/navigation_entry.h" 12 #include "chrome/browser/tab_contents/navigation_entry.h"
13 #include "chrome/common/pref_names.h" 13 #include "chrome/common/pref_names.h"
14 #include "net/base/net_util.h" 14 #include "net/base/net_util.h"
15 15
16 GeolocationSettingsState::GeolocationSettingsState(Profile* profile) 16 GeolocationSettingsState::GeolocationSettingsState(Profile* profile)
17 : profile_(profile) { 17 : profile_(profile) {
18 } 18 }
19 19
20 GeolocationSettingsState::~GeolocationSettingsState() { 20 GeolocationSettingsState::~GeolocationSettingsState() {
21 } 21 }
(...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after
94 } 94 }
95 95
96 std::string GeolocationSettingsState::GURLToFormattedHost( 96 std::string GeolocationSettingsState::GURLToFormattedHost(
97 const GURL& url) const { 97 const GURL& url) const {
98 std::wstring display_host_wide; 98 std::wstring display_host_wide;
99 net::AppendFormattedHost( 99 net::AppendFormattedHost(
100 url, UTF8ToWide(profile_->GetPrefs()->GetString(prefs::kAcceptLanguages)), 100 url, UTF8ToWide(profile_->GetPrefs()->GetString(prefs::kAcceptLanguages)),
101 &display_host_wide, NULL, NULL); 101 &display_host_wide, NULL, NULL);
102 return WideToUTF8(display_host_wide); 102 return WideToUTF8(display_host_wide);
103 } 103 }
OLDNEW
« no previous file with comments | « chrome/browser/geolocation/geolocation_permission_context.cc ('k') | chrome/browser/geolocation/location_arbitrator.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698