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

Side by Side Diff: extensions/shell/common/shell_extensions_client.cc

Issue 2266673002: [Extensions] Remove mechanism for non-generated schemas (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: lazyboys Created 4 years, 4 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
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "extensions/shell/common/shell_extensions_client.h" 5 #include "extensions/shell/common/shell_extensions_client.h"
6 6
7 #include "base/lazy_instance.h" 7 #include "base/lazy_instance.h"
8 #include "base/logging.h" 8 #include "base/logging.h"
9 #include "base/macros.h" 9 #include "base/macros.h"
10 #include "extensions/common/api/generated_schemas.h" 10 #include "extensions/common/api/generated_schemas.h"
(...skipping 154 matching lines...) Expand 10 before | Expand all | Expand 10 after
165 base::StringPiece ShellExtensionsClient::GetAPISchema( 165 base::StringPiece ShellExtensionsClient::GetAPISchema(
166 const std::string& name) const { 166 const std::string& name) const {
167 // Schema for app_shell-only APIs. 167 // Schema for app_shell-only APIs.
168 if (shell::api::ShellGeneratedSchemas::IsGenerated(name)) 168 if (shell::api::ShellGeneratedSchemas::IsGenerated(name))
169 return shell::api::ShellGeneratedSchemas::Get(name); 169 return shell::api::ShellGeneratedSchemas::Get(name);
170 170
171 // Core extensions APIs. 171 // Core extensions APIs.
172 return api::GeneratedSchemas::Get(name); 172 return api::GeneratedSchemas::Get(name);
173 } 173 }
174 174
175 void ShellExtensionsClient::RegisterAPISchemaResources(
176 ExtensionAPI* api) const {
177 }
178
179 bool ShellExtensionsClient::ShouldSuppressFatalErrors() const { 175 bool ShellExtensionsClient::ShouldSuppressFatalErrors() const {
180 return true; 176 return true;
181 } 177 }
182 178
183 void ShellExtensionsClient::RecordDidSuppressFatalError() { 179 void ShellExtensionsClient::RecordDidSuppressFatalError() {
184 } 180 }
185 181
186 std::string ShellExtensionsClient::GetWebstoreBaseURL() const { 182 std::string ShellExtensionsClient::GetWebstoreBaseURL() const {
187 return extension_urls::kChromeWebstoreBaseURL; 183 return extension_urls::kChromeWebstoreBaseURL;
188 } 184 }
189 185
190 std::string ShellExtensionsClient::GetWebstoreUpdateURL() const { 186 std::string ShellExtensionsClient::GetWebstoreUpdateURL() const {
191 return extension_urls::kChromeWebstoreUpdateURL; 187 return extension_urls::kChromeWebstoreUpdateURL;
192 } 188 }
193 189
194 bool ShellExtensionsClient::IsBlacklistUpdateURL(const GURL& url) const { 190 bool ShellExtensionsClient::IsBlacklistUpdateURL(const GURL& url) const {
195 // TODO(rockot): Maybe we want to do something else here. For now we accept 191 // TODO(rockot): Maybe we want to do something else here. For now we accept
196 // any URL as a blacklist URL because we don't really care. 192 // any URL as a blacklist URL because we don't really care.
197 return true; 193 return true;
198 } 194 }
199 195
200 } // namespace extensions 196 } // namespace extensions
OLDNEW
« no previous file with comments | « extensions/shell/common/shell_extensions_client.h ('k') | extensions/test/test_extensions_client.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698