summaryrefslogtreecommitdiffstats
path: root/extensions/browser/extensions_browser_client.cc
blob: cae50ed0e59f9480259e36955b3adebf5a056ae3 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
// Copyright 2013 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 "extensions/browser/extensions_browser_client.h"

#include "base/logging.h"
#include "components/update_client/update_client.h"
#include "extensions/browser/extension_error.h"
#include "extensions/browser/updater/update_client_config.h"

namespace extensions {

namespace {

ExtensionsBrowserClient* g_client = NULL;

}  // namespace

scoped_refptr<update_client::UpdateClient>
ExtensionsBrowserClient::CreateUpdateClient(content::BrowserContext* context) {
  return scoped_refptr<update_client::UpdateClient>(nullptr);
}

int ExtensionsBrowserClient::GetTabIdForWebContents(
    content::WebContents* web_contents) {
  return -1;
}

void ExtensionsBrowserClient::ReportError(content::BrowserContext* context,
                                          scoped_ptr<ExtensionError> error) {
  LOG(ERROR) << error->GetDebugString();
}

ExtensionsBrowserClient* ExtensionsBrowserClient::Get() {
  return g_client;
}

void ExtensionsBrowserClient::Set(ExtensionsBrowserClient* client) {
  g_client = client;
}

}  // namespace extensions