summaryrefslogtreecommitdiffstats
path: root/app/resource_bundle_dummy.cc
diff options
context:
space:
mode:
authorgregoryd@google.com <gregoryd@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2009-12-07 23:05:02 +0000
committergregoryd@google.com <gregoryd@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2009-12-07 23:05:02 +0000
commitdfdfad0c7f19b5f9e3bc9e174d0ecf40b4351c5d (patch)
treecabc1161fc9b2aac5d6c01b70833aa005faef08e /app/resource_bundle_dummy.cc
parent192745015c18e59970b382d69371d46eb15390ed (diff)
downloadchromium_src-dfdfad0c7f19b5f9e3bc9e174d0ecf40b4351c5d.zip
chromium_src-dfdfad0c7f19b5f9e3bc9e174d0ecf40b4351c5d.tar.gz
chromium_src-dfdfad0c7f19b5f9e3bc9e174d0ecf40b4351c5d.tar.bz2
Split app.gyp and add a Win64 version of the app_base target.
This is required for supporting NaCl on 64-bit Windows TEST=none BUG=28176 Review URL: http://codereview.chromium.org/460083 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@34009 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'app/resource_bundle_dummy.cc')
-rw-r--r--app/resource_bundle_dummy.cc58
1 files changed, 58 insertions, 0 deletions
diff --git a/app/resource_bundle_dummy.cc b/app/resource_bundle_dummy.cc
new file mode 100644
index 0000000..77479f6
--- /dev/null
+++ b/app/resource_bundle_dummy.cc
@@ -0,0 +1,58 @@
+// Copyright (c) 2006-2009 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#include "app/resource_bundle.h"
+
+#include <atlbase.h>
+#include <windows.h>
+
+#include "app/gfx/font.h"
+#include "base/logging.h"
+#include "base/win_util.h"
+
+ResourceBundle* ResourceBundle::g_shared_instance_ = NULL;
+
+// NOTE(gregoryd): This is a hack to avoid creating more nacl_win64-specific
+// files. The font members of ResourceBundle are never initialized in our code
+// so this destructor is never called.
+namespace gfx {
+ Font::HFontRef::~HFontRef() {
+ NOTREACHED();
+ }
+}
+
+
+/* static */
+void ResourceBundle::InitSharedInstance(const std::wstring& pref_locale) {
+ DCHECK(g_shared_instance_ == NULL) << "ResourceBundle initialized twice";
+ g_shared_instance_ = new ResourceBundle();
+}
+
+/* static */
+void ResourceBundle::CleanupSharedInstance() {
+ if (g_shared_instance_) {
+ delete g_shared_instance_;
+ g_shared_instance_ = NULL;
+ }
+}
+
+/* static */
+ResourceBundle& ResourceBundle::GetSharedInstance() {
+ // Must call InitSharedInstance before this function.
+ CHECK(g_shared_instance_ != NULL);
+ return *g_shared_instance_;
+}
+
+ResourceBundle::ResourceBundle()
+ : resources_data_(NULL),
+ locale_resources_data_(NULL) {
+}
+
+ResourceBundle::~ResourceBundle() {
+}
+
+
+string16 ResourceBundle::GetLocalizedString(int message_id) {
+ return std::wstring();
+}