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

Side by Side Diff: chrome/common/pref_service.cc

Issue 109043: Move l10n_util to app/ (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 years, 7 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
« no previous file with comments | « chrome/common/platform_util_mac.mm ('k') | chrome/common/security_filter_peer.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2008 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/common/pref_service.h" 5 #include "chrome/common/pref_service.h"
6 6
7 #include "app/l10n_util.h"
7 #include "base/logging.h" 8 #include "base/logging.h"
8 #include "base/message_loop.h" 9 #include "base/message_loop.h"
9 #include "base/stl_util-inl.h" 10 #include "base/stl_util-inl.h"
10 #include "base/string_util.h" 11 #include "base/string_util.h"
11 #include "base/thread.h" 12 #include "base/thread.h"
12 #include "chrome/common/json_value_serializer.h" 13 #include "chrome/common/json_value_serializer.h"
13 #include "chrome/common/l10n_util.h"
14 #include "chrome/common/notification_service.h" 14 #include "chrome/common/notification_service.h"
15 #include "grit/generated_resources.h" 15 #include "grit/generated_resources.h"
16 16
17 namespace { 17 namespace {
18 18
19 // A helper function for RegisterLocalized*Pref that creates a Value* based on 19 // A helper function for RegisterLocalized*Pref that creates a Value* based on
20 // the string value in the locale dll. Because we control the values in a 20 // the string value in the locale dll. Because we control the values in a
21 // locale dll, this should always return a Value of the appropriate type. 21 // locale dll, this should always return a Value of the appropriate type.
22 Value* CreateLocaleDefaultValue(Value::ValueType type, int message_id) { 22 Value* CreateLocaleDefaultValue(Value::ValueType type, int message_id) {
23 std::wstring resource_string = l10n_util::GetString(message_id); 23 std::wstring resource_string = l10n_util::GetString(message_id);
(...skipping 663 matching lines...) Expand 10 before | Expand all | Expand 10 after
687 } 687 }
688 688
689 // Pref not found, just return the app default. 689 // Pref not found, just return the app default.
690 return default_value_.get(); 690 return default_value_.get();
691 } 691 }
692 692
693 bool PrefService::Preference::IsDefaultValue() const { 693 bool PrefService::Preference::IsDefaultValue() const {
694 DCHECK(default_value_.get()); 694 DCHECK(default_value_.get());
695 return default_value_->Equals(GetValue()); 695 return default_value_->Equals(GetValue());
696 } 696 }
OLDNEW
« no previous file with comments | « chrome/common/platform_util_mac.mm ('k') | chrome/common/security_filter_peer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698