Add ICU message format support
[chromium-blink-merge.git] / ios / public / provider / web / web_controller_provider.mm
blob82aa875c25cd12880c52a2c8351d7194592a9a7c
1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #include "ios/public/provider/web/web_controller_provider.h"
7 namespace ios {
9 static WebControllerProviderFactory* g_web_controller_provider_factory;
11 void SetWebControllerProviderFactory(
12     WebControllerProviderFactory* provider_factory) {
13   g_web_controller_provider_factory = provider_factory;
16 WebControllerProviderFactory* GetWebControllerProviderFactory() {
17   return g_web_controller_provider_factory;
20 WebControllerProvider::WebControllerProvider(web::BrowserState* browser_state) {
23 WebControllerProvider::~WebControllerProvider() {
26 bool WebControllerProvider::SuppressesDialogs() const {
27   return false;
30 web::WebState* WebControllerProvider::GetWebState() const {
31   return nullptr;
34 void WebControllerProvider::InjectScript(const std::string& script,
35                                          web::JavaScriptCompletion completion) {
36   if (completion)
37     completion(nil, nil);
40 WebControllerProviderFactory::WebControllerProviderFactory() {
43 WebControllerProviderFactory::~WebControllerProviderFactory() {
46 scoped_ptr<WebControllerProvider>
47 WebControllerProviderFactory::CreateWebControllerProvider(
48     web::BrowserState* browser_state) {
49   return scoped_ptr<WebControllerProvider>(
50       new WebControllerProvider(browser_state));
53 }  // namespace ios