Index: mojo/icu/icu.cc |
diff --git a/mojo/icu/icu.cc b/mojo/icu/icu.cc |
deleted file mode 100644 |
index 803b3d72e3fcb88961e76457d920f6d6456eef14..0000000000000000000000000000000000000000 |
--- a/mojo/icu/icu.cc |
+++ /dev/null |
@@ -1,51 +0,0 @@ |
-// Copyright 2015 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 "mojo/icu/icu.h" |
- |
-#include "mojo/icu/constants.h" |
-#include "mojo/public/cpp/application/application_impl.h" |
-#include "mojo/services/icu_data/interfaces/icu_data.mojom.h" |
-#include "third_party/icu/source/common/unicode/putil.h" |
-#include "third_party/icu/source/common/unicode/udata.h" |
- |
-#if !defined(OS_ANDROID) |
-#include "base/i18n/icu_util.h" |
-#endif |
- |
-namespace mojo { |
-namespace icu { |
-namespace { |
- |
-class Callback { |
- public: |
- void Run(mojo::ScopedSharedBufferHandle handle) const { |
- void* ptr = nullptr; |
- mojo::MapBuffer(handle.get(), 0, kDataSize, &ptr, |
- MOJO_MAP_BUFFER_FLAG_NONE); |
- UErrorCode err = U_ZERO_ERROR; |
- udata_setCommonData(ptr, &err); |
- // Leak the handle because we never unmap the buffer. |
- (void)handle.release(); |
- }; |
-}; |
- |
-} // namespace |
- |
-void Initialize(ApplicationImpl* app) { |
-#if !defined(OS_ANDROID) |
- // On desktop platforms, the icu data table is stored in a file on disk, which |
- // can be loaded using base. |
- base::i18n::InitializeICU(); |
- return; |
-#endif |
- |
- icu_data::ICUDataPtr icu_data; |
- app->ConnectToService("mojo:icu_data", &icu_data); |
- icu_data->Map(kDataHash, Callback()); |
- icu_data.WaitForIncomingResponse(); |
-} |
- |
-} // namespace icu |
-} // namespace mojo |