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

Unified Diff: extensions/browser/api/app_view/app_view_internal_api.cc

Issue 498303002: AppView internal API doesn't need to go through ExtensionsAPIClient anymore, since AppView is now i… (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebasing Created 6 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 side-by-side diff with in-line comments
Download patch
Index: extensions/browser/api/app_view/app_view_internal_api.cc
diff --git a/extensions/browser/api/app_view/app_view_internal_api.cc b/extensions/browser/api/app_view/app_view_internal_api.cc
index 519f9ffbdb6a1ef2d357946c9c15be97478dea33..7874243c3acc1dcba33c9c521857b45369a8261e 100644
--- a/extensions/browser/api/app_view/app_view_internal_api.cc
+++ b/extensions/browser/api/app_view/app_view_internal_api.cc
@@ -4,7 +4,7 @@
#include "extensions/browser/api/app_view/app_view_internal_api.h"
-#include "extensions/browser/api/extensions_api_client.h"
+#include "extensions/browser/guest_view/app_view/app_view_guest.h"
#include "extensions/common/api/app_view_internal.h"
@@ -24,12 +24,10 @@ bool AppViewInternalAttachFrameFunction::RunAsync() {
GURL url = extension()->GetResourceURL(params->url);
EXTENSION_FUNCTION_VALIDATE(url.is_valid());
- ExtensionsAPIClient* extensions_client = ExtensionsAPIClient::Get();
- return extensions_client->AppViewInternalAttachFrame(
- browser_context(),
- url,
- params->guest_instance_id,
- extension_id());
+ return AppViewGuest::CompletePendingRequest(browser_context(),
+ url,
+ params->guest_instance_id,
+ extension_id());
}
AppViewInternalDenyRequestFunction::
@@ -41,13 +39,12 @@ bool AppViewInternalDenyRequestFunction::RunAsync() {
appview::DenyRequest::Params::Create(*args_));
EXTENSION_FUNCTION_VALIDATE(params.get());
- ExtensionsAPIClient* extensions_client = ExtensionsAPIClient::Get();
// Since the URL passed into AppViewGuest:::CompletePendingRequest is invalid,
// a new <appview> WebContents will not be created.
- return extensions_client->AppViewInternalDenyRequest(
- browser_context(),
- params->guest_instance_id,
- extension_id());
+ return AppViewGuest::CompletePendingRequest(browser_context(),
+ GURL(),
+ params->guest_instance_id,
+ extension_id());
}
} // namespace extensions
« no previous file with comments | « chrome/browser/extensions/api/chrome_extensions_api_client.cc ('k') | extensions/browser/api/extensions_api_client.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698