Chromium Code Reviews| Index: chrome/browser/ui/webui/options/chromeos/system_settings_provider.cc |
| diff --git a/chrome/browser/ui/webui/options/chromeos/system_settings_provider.cc b/chrome/browser/ui/webui/options/chromeos/system_settings_provider.cc |
| index bc7a963050225d43ded12c299def50fc77a05cd8..d6c46186cbad670e8f9c6306cca98fcc9fa73c28 100644 |
| --- a/chrome/browser/ui/webui/options/chromeos/system_settings_provider.cc |
| +++ b/chrome/browser/ui/webui/options/chromeos/system_settings_provider.cc |
| @@ -211,14 +211,20 @@ void SystemSettingsProvider::DoSet(const std::string& path, Value* in_value) { |
| } |
| } |
| -bool SystemSettingsProvider::Get(const std::string& path, |
| - Value** out_value) const { |
| +const base::Value* SystemSettingsProvider::Get(const std::string& path) const { |
| if (path == kSystemTimezone) { |
| - *out_value = Value::CreateStringValue(GetKnownTimezoneID( |
| + // TODO(pastarmovj): This will leak now if the callee doesn't delete it. |
| + // We should anyhow cache this in the local_state. |
|
Mattias Nissler (ping if slow)
2011/09/26 17:26:37
I don't like code that introduces leaks. Can you k
pastarmovj
2011/09/29 15:15:03
Done.
|
| + return Value::CreateStringValue(GetKnownTimezoneID( |
| system::TimezoneSettings::GetInstance()->GetTimezone())); |
| - return true; |
| } |
| - return false; |
| + return NULL; |
| +} |
| + |
| +// The timezone is always trusted. |
| +bool SystemSettingsProvider::GetTrusted(const std::string& path, |
| + const base::Closure& callback) const { |
| + return true; |
| } |
| bool SystemSettingsProvider::HandlesSetting(const std::string& path) const { |