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

Side by Side Diff: chrome/renderer/extensions/i18n_custom_bindings.cc

Issue 194333002: Move extension_messages.h to extensions/common. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: merge again Created 6 years, 9 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
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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/renderer/extensions/i18n_custom_bindings.h" 5 #include "chrome/renderer/extensions/i18n_custom_bindings.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "chrome/common/extensions/extension_messages.h"
9 #include "chrome/common/extensions/message_bundle.h" 8 #include "chrome/common/extensions/message_bundle.h"
10 #include "content/public/renderer/render_thread.h" 9 #include "content/public/renderer/render_thread.h"
11 #include "content/public/renderer/render_view.h" 10 #include "content/public/renderer/render_view.h"
11 #include "extensions/common/extension_messages.h"
12 #include "grit/renderer_resources.h" 12 #include "grit/renderer_resources.h"
13 #include "v8/include/v8.h" 13 #include "v8/include/v8.h"
14 14
15 namespace extensions { 15 namespace extensions {
16 16
17 I18NCustomBindings::I18NCustomBindings(Dispatcher* dispatcher, 17 I18NCustomBindings::I18NCustomBindings(Dispatcher* dispatcher,
18 ChromeV8Context* context) 18 ChromeV8Context* context)
19 : ChromeV8Extension(dispatcher, context) { 19 : ChromeV8Extension(dispatcher, context) {
20 RouteFunction("GetL10nMessage", 20 RouteFunction("GetL10nMessage",
21 base::Bind(&I18NCustomBindings::GetL10nMessage, base::Unretained(this))); 21 base::Bind(&I18NCustomBindings::GetL10nMessage, base::Unretained(this)));
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after
88 message, substitutions, NULL).c_str())); 88 message, substitutions, NULL).c_str()));
89 } 89 }
90 90
91 void I18NCustomBindings::GetL10nUILanguage( 91 void I18NCustomBindings::GetL10nUILanguage(
92 const v8::FunctionCallbackInfo<v8::Value>& args) { 92 const v8::FunctionCallbackInfo<v8::Value>& args) {
93 args.GetReturnValue().Set(v8::String::NewFromUtf8( 93 args.GetReturnValue().Set(v8::String::NewFromUtf8(
94 args.GetIsolate(), content::RenderThread::Get()->GetLocale().c_str())); 94 args.GetIsolate(), content::RenderThread::Get()->GetLocale().c_str()));
95 } 95 }
96 96
97 } // namespace extensions 97 } // namespace extensions
OLDNEW
« no previous file with comments | « chrome/renderer/extensions/extension_localization_peer.cc ('k') | chrome/renderer/extensions/messaging_bindings.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698