Commit a84d8e63 authored by thestig's avatar thestig Committed by Commit bot

Cleanup: Put more chrome/ code behind ENABLE_EXTENSIONS ifdefs.

Review URL: https://codereview.chromium.org/664553007

Cr-Commit-Position: refs/heads/master@{#300177}
parent 7d27cc02
...@@ -1980,6 +1980,7 @@ void Browser::Observe(int type, ...@@ -1980,6 +1980,7 @@ void Browser::Observe(int type,
} }
} }
#if defined(ENABLE_EXTENSIONS)
/////////////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////////
// Browser, extensions::ExtensionRegistryObserver implementation: // Browser, extensions::ExtensionRegistryObserver implementation:
...@@ -2044,6 +2045,7 @@ void Browser::OnExtensionUnloaded( ...@@ -2044,6 +2045,7 @@ void Browser::OnExtensionUnloaded(
} }
} }
} }
#endif // defined(ENABLE_EXTENSIONS)
/////////////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////////
// Browser, Command and state updating (private): // Browser, Command and state updating (private):
......
...@@ -39,13 +39,16 @@ ...@@ -39,13 +39,16 @@
#include "content/public/browser/page_navigator.h" #include "content/public/browser/page_navigator.h"
#include "content/public/browser/web_contents_delegate.h" #include "content/public/browser/web_contents_delegate.h"
#include "content/public/common/page_zoom.h" #include "content/public/common/page_zoom.h"
#include "extensions/browser/extension_registry_observer.h"
#include "ui/base/page_transition_types.h" #include "ui/base/page_transition_types.h"
#include "ui/base/ui_base_types.h" #include "ui/base/ui_base_types.h"
#include "ui/base/window_open_disposition.h" #include "ui/base/window_open_disposition.h"
#include "ui/gfx/rect.h" #include "ui/gfx/rect.h"
#include "ui/shell_dialogs/select_file_dialog.h" #include "ui/shell_dialogs/select_file_dialog.h"
#if defined(ENABLE_EXTENSIONS)
#include "extensions/browser/extension_registry_observer.h"
#endif
class BrowserContentSettingBubbleModelDelegate; class BrowserContentSettingBubbleModelDelegate;
class BrowserContentTranslateDriverObserver; class BrowserContentTranslateDriverObserver;
class BrowserInstantController; class BrowserInstantController;
...@@ -108,7 +111,9 @@ class Browser : public TabStripModelObserver, ...@@ -108,7 +111,9 @@ class Browser : public TabStripModelObserver,
public ZoomObserver, public ZoomObserver,
public content::PageNavigator, public content::PageNavigator,
public content::NotificationObserver, public content::NotificationObserver,
#if defined(ENABLE_EXTENSIONS)
public extensions::ExtensionRegistryObserver, public extensions::ExtensionRegistryObserver,
#endif
public ui::SelectFileDialog::Listener { public ui::SelectFileDialog::Listener {
public: public:
// SessionService::WindowType mirrors these values. If you add to this // SessionService::WindowType mirrors these values. If you add to this
...@@ -716,6 +721,7 @@ class Browser : public TabStripModelObserver, ...@@ -716,6 +721,7 @@ class Browser : public TabStripModelObserver,
const content::NotificationSource& source, const content::NotificationSource& source,
const content::NotificationDetails& details) override; const content::NotificationDetails& details) override;
#if defined(ENABLE_EXTENSIONS)
// Overridden from extensions::ExtensionRegistryObserver: // Overridden from extensions::ExtensionRegistryObserver:
virtual void OnExtensionUninstalled( virtual void OnExtensionUninstalled(
content::BrowserContext* browser_context, content::BrowserContext* browser_context,
...@@ -728,6 +734,7 @@ class Browser : public TabStripModelObserver, ...@@ -728,6 +734,7 @@ class Browser : public TabStripModelObserver,
content::BrowserContext* browser_context, content::BrowserContext* browser_context,
const extensions::Extension* extension, const extensions::Extension* extension,
extensions::UnloadedExtensionInfo::Reason reason) override; extensions::UnloadedExtensionInfo::Reason reason) override;
#endif
// Command and state updating /////////////////////////////////////////////// // Command and state updating ///////////////////////////////////////////////
...@@ -842,9 +849,11 @@ class Browser : public TabStripModelObserver, ...@@ -842,9 +849,11 @@ class Browser : public TabStripModelObserver,
content::NotificationRegistrar registrar_; content::NotificationRegistrar registrar_;
#if defined(ENABLE_EXTENSIONS)
ScopedObserver<extensions::ExtensionRegistry, ScopedObserver<extensions::ExtensionRegistry,
extensions::ExtensionRegistryObserver> extensions::ExtensionRegistryObserver>
extension_registry_observer_; extension_registry_observer_;
#endif
PrefChangeRegistrar profile_pref_registrar_; PrefChangeRegistrar profile_pref_registrar_;
......
...@@ -17,9 +17,6 @@ ...@@ -17,9 +17,6 @@
#include "chrome/browser/chrome_page_zoom.h" #include "chrome/browser/chrome_page_zoom.h"
#include "chrome/browser/devtools/devtools_window.h" #include "chrome/browser/devtools/devtools_window.h"
#include "chrome/browser/dom_distiller/tab_utils.h" #include "chrome/browser/dom_distiller/tab_utils.h"
#include "chrome/browser/extensions/api/commands/command_service.h"
#include "chrome/browser/extensions/api/extension_action/extension_action_api.h"
#include "chrome/browser/extensions/tab_helper.h"
#include "chrome/browser/favicon/favicon_tab_helper.h" #include "chrome/browser/favicon/favicon_tab_helper.h"
#include "chrome/browser/lifetime/application_lifetime.h" #include "chrome/browser/lifetime/application_lifetime.h"
#include "chrome/browser/platform_util.h" #include "chrome/browser/platform_util.h"
...@@ -53,14 +50,11 @@ ...@@ -53,14 +50,11 @@
#include "chrome/browser/ui/status_bubble.h" #include "chrome/browser/ui/status_bubble.h"
#include "chrome/browser/ui/tab_contents/core_tab_helper.h" #include "chrome/browser/ui/tab_contents/core_tab_helper.h"
#include "chrome/browser/ui/tabs/tab_strip_model.h" #include "chrome/browser/ui/tabs/tab_strip_model.h"
#include "chrome/browser/ui/webui/ntp/core_app_launcher_handler.h"
#include "chrome/browser/ui/zoom/zoom_controller.h" #include "chrome/browser/ui/zoom/zoom_controller.h"
#include "chrome/browser/upgrade_detector.h" #include "chrome/browser/upgrade_detector.h"
#include "chrome/browser/web_applications/web_app.h"
#include "chrome/common/chrome_switches.h" #include "chrome/common/chrome_switches.h"
#include "chrome/common/chrome_version_info.h" #include "chrome/common/chrome_version_info.h"
#include "chrome/common/content_restriction.h" #include "chrome/common/content_restriction.h"
#include "chrome/common/extensions/manifest_handlers/app_launch_info.h"
#include "chrome/common/pref_names.h" #include "chrome/common/pref_names.h"
#include "components/bookmarks/browser/bookmark_model.h" #include "components/bookmarks/browser/bookmark_model.h"
#include "components/bookmarks/browser/bookmark_utils.h" #include "components/bookmarks/browser/bookmark_utils.h"
...@@ -88,6 +82,12 @@ ...@@ -88,6 +82,12 @@
#endif #endif
#if defined(ENABLE_EXTENSIONS) #if defined(ENABLE_EXTENSIONS)
#include "chrome/browser/extensions/api/commands/command_service.h"
#include "chrome/browser/extensions/api/extension_action/extension_action_api.h"
#include "chrome/browser/extensions/tab_helper.h"
#include "chrome/browser/ui/webui/ntp/core_app_launcher_handler.h"
#include "chrome/browser/web_applications/web_app.h"
#include "chrome/common/extensions/manifest_handlers/app_launch_info.h"
#include "extensions/browser/extension_registry.h" #include "extensions/browser/extension_registry.h"
#include "extensions/browser/extension_system.h" #include "extensions/browser/extension_system.h"
#include "extensions/common/extension.h" #include "extensions/common/extension.h"
...@@ -130,12 +130,12 @@ bool CanBookmarkCurrentPageInternal(const Browser* browser, ...@@ -130,12 +130,12 @@ bool CanBookmarkCurrentPageInternal(const Browser* browser,
!chrome::ShouldRemoveBookmarkThisPageUI(browser->profile())); !chrome::ShouldRemoveBookmarkThisPageUI(browser->profile()));
} }
#if defined(ENABLE_EXTENSIONS)
bool GetBookmarkOverrideCommand( bool GetBookmarkOverrideCommand(
Profile* profile, Profile* profile,
const extensions::Extension** extension, const extensions::Extension** extension,
extensions::Command* command, extensions::Command* command,
extensions::CommandService::ExtensionCommandType* command_type) { extensions::CommandService::ExtensionCommandType* command_type) {
#if defined(ENABLE_EXTENSIONS)
DCHECK(extension); DCHECK(extension);
DCHECK(command); DCHECK(command);
DCHECK(command_type); DCHECK(command_type);
...@@ -164,10 +164,9 @@ bool GetBookmarkOverrideCommand( ...@@ -164,10 +164,9 @@ bool GetBookmarkOverrideCommand(
return true; return true;
} }
} }
#endif
return false; return false;
} }
#endif
void BookmarkCurrentPageInternal(Browser* browser) { void BookmarkCurrentPageInternal(Browser* browser) {
content::RecordAction(UserMetricsAction("Star")); content::RecordAction(UserMetricsAction("Star"));
...@@ -745,6 +744,7 @@ void Exit() { ...@@ -745,6 +744,7 @@ void Exit() {
void BookmarkCurrentPage(Browser* browser) { void BookmarkCurrentPage(Browser* browser) {
DCHECK(!chrome::ShouldRemoveBookmarkThisPageUI(browser->profile())); DCHECK(!chrome::ShouldRemoveBookmarkThisPageUI(browser->profile()));
#if defined(ENABLE_EXTENSIONS)
const extensions::Extension* extension = NULL; const extensions::Extension* extension = NULL;
extensions::Command command; extensions::Command command;
extensions::CommandService::ExtensionCommandType command_type; extensions::CommandService::ExtensionCommandType command_type;
...@@ -766,6 +766,7 @@ void BookmarkCurrentPage(Browser* browser) { ...@@ -766,6 +766,7 @@ void BookmarkCurrentPage(Browser* browser) {
} }
return; return;
} }
#endif
BookmarkCurrentPageInternal(browser); BookmarkCurrentPageInternal(browser);
} }
...@@ -1242,6 +1243,7 @@ bool CanViewSource(const Browser* browser) { ...@@ -1242,6 +1243,7 @@ bool CanViewSource(const Browser* browser) {
CanViewSource(); CanViewSource();
} }
#if defined(ENABLE_EXTENSIONS)
void CreateApplicationShortcuts(Browser* browser) { void CreateApplicationShortcuts(Browser* browser) {
content::RecordAction(UserMetricsAction("CreateShortcut")); content::RecordAction(UserMetricsAction("CreateShortcut"));
extensions::TabHelper::FromWebContents( extensions::TabHelper::FromWebContents(
...@@ -1289,5 +1291,6 @@ void ConvertTabToAppWindow(Browser* browser, ...@@ -1289,5 +1291,6 @@ void ConvertTabToAppWindow(Browser* browser,
contents->GetRenderViewHost()->SyncRendererPrefs(); contents->GetRenderViewHost()->SyncRendererPrefs();
app_browser->window()->Show(); app_browser->window()->Show();
} }
#endif // defined(ENABLE_EXTENSIONS)
} // namespace chrome } // namespace chrome
...@@ -12,7 +12,6 @@ ...@@ -12,7 +12,6 @@
#include "base/strings/utf_string_conversions.h" #include "base/strings/utf_string_conversions.h"
#include "chrome/browser/browser_about_handler.h" #include "chrome/browser/browser_about_handler.h"
#include "chrome/browser/chrome_notification_types.h" #include "chrome/browser/chrome_notification_types.h"
#include "chrome/browser/extensions/tab_helper.h"
#include "chrome/browser/prefs/incognito_mode_prefs.h" #include "chrome/browser/prefs/incognito_mode_prefs.h"
#include "chrome/browser/prerender/prerender_manager.h" #include "chrome/browser/prerender/prerender_manager.h"
#include "chrome/browser/prerender/prerender_manager_factory.h" #include "chrome/browser/prerender/prerender_manager_factory.h"
...@@ -30,7 +29,6 @@ ...@@ -30,7 +29,6 @@
#include "chrome/browser/ui/status_bubble.h" #include "chrome/browser/ui/status_bubble.h"
#include "chrome/browser/ui/tab_helpers.h" #include "chrome/browser/ui/tab_helpers.h"
#include "chrome/browser/ui/tabs/tab_strip_model.h" #include "chrome/browser/ui/tabs/tab_strip_model.h"
#include "chrome/browser/web_applications/web_app.h"
#include "chrome/common/pref_names.h" #include "chrome/common/pref_names.h"
#include "chrome/common/url_constants.h" #include "chrome/common/url_constants.h"
#include "components/google/core/browser/google_url_tracker.h" #include "components/google/core/browser/google_url_tracker.h"
...@@ -49,6 +47,8 @@ ...@@ -49,6 +47,8 @@
#endif #endif
#if defined(ENABLE_EXTENSIONS) #if defined(ENABLE_EXTENSIONS)
#include "chrome/browser/extensions/tab_helper.h"
#include "chrome/browser/web_applications/web_app.h"
#include "extensions/browser/extension_registry.h" #include "extensions/browser/extension_registry.h"
#include "extensions/common/extension.h" #include "extensions/common/extension.h"
#include "extensions/common/extension_set.h" #include "extensions/common/extension_set.h"
...@@ -154,6 +154,7 @@ Browser* GetBrowserForDisposition(chrome::NavigateParams* params) { ...@@ -154,6 +154,7 @@ Browser* GetBrowserForDisposition(chrome::NavigateParams* params) {
// Make a new popup window. // Make a new popup window.
// Coerce app-style if |source| represents an app. // Coerce app-style if |source| represents an app.
std::string app_name; std::string app_name;
#if defined(ENABLE_EXTENSIONS)
if (!params->extension_app_id.empty()) { if (!params->extension_app_id.empty()) {
app_name = web_app::GenerateApplicationNameFromExtensionId( app_name = web_app::GenerateApplicationNameFromExtensionId(
params->extension_app_id); params->extension_app_id);
...@@ -167,6 +168,7 @@ Browser* GetBrowserForDisposition(chrome::NavigateParams* params) { ...@@ -167,6 +168,7 @@ Browser* GetBrowserForDisposition(chrome::NavigateParams* params) {
extensions_tab_helper->extension_app()->id()); extensions_tab_helper->extension_app()->id());
} }
} }
#endif
if (app_name.empty()) { if (app_name.empty()) {
Browser::CreateParams browser_params( Browser::CreateParams browser_params(
Browser::TYPE_POPUP, profile, params->host_desktop_type); Browser::TYPE_POPUP, profile, params->host_desktop_type);
...@@ -372,8 +374,10 @@ content::WebContents* CreateTargetContents(const chrome::NavigateParams& params, ...@@ -372,8 +374,10 @@ content::WebContents* CreateTargetContents(const chrome::NavigateParams& params,
// tab helpers, so the entire set of tab helpers needs to be set up // tab helpers, so the entire set of tab helpers needs to be set up
// immediately. // immediately.
BrowserNavigatorWebContentsAdoption::AttachTabHelpers(target_contents); BrowserNavigatorWebContentsAdoption::AttachTabHelpers(target_contents);
#if defined(ENABLE_EXTENSIONS)
extensions::TabHelper::FromWebContents(target_contents)-> extensions::TabHelper::FromWebContents(target_contents)->
SetExtensionAppById(params.extension_app_id); SetExtensionAppById(params.extension_app_id);
#endif
return target_contents; return target_contents;
} }
......
...@@ -15,9 +15,6 @@ ...@@ -15,9 +15,6 @@
#include "chrome/grit/generated_resources.h" #include "chrome/grit/generated_resources.h"
#include "components/error_page/common/error_page_params.h" #include "components/error_page/common/error_page_params.h"
#include "components/error_page/common/net_error_info.h" #include "components/error_page/common/net_error_info.h"
#include "extensions/common/constants.h"
#include "extensions/common/extension_icon_set.h"
#include "extensions/common/manifest_handlers/icons_handler.h"
#include "net/base/escape.h" #include "net/base/escape.h"
#include "net/base/net_errors.h" #include "net/base/net_errors.h"
#include "net/base/net_util.h" #include "net/base/net_util.h"
...@@ -29,6 +26,12 @@ ...@@ -29,6 +26,12 @@
#include "base/win/windows_version.h" #include "base/win/windows_version.h"
#endif #endif
#if defined(ENABLE_EXTENSIONS)
#include "extensions/common/constants.h"
#include "extensions/common/extension_icon_set.h"
#include "extensions/common/manifest_handlers/icons_handler.h"
#endif
using blink::WebURLError; using blink::WebURLError;
// Some error pages have no details. // Some error pages have no details.
...@@ -847,6 +850,7 @@ bool LocalizedError::HasStrings(const std::string& error_domain, ...@@ -847,6 +850,7 @@ bool LocalizedError::HasStrings(const std::string& error_domain,
return LookupErrorMap(error_domain, error_code, /*is_post=*/false) != NULL; return LookupErrorMap(error_domain, error_code, /*is_post=*/false) != NULL;
} }
#if defined(ENABLE_EXTENSIONS)
void LocalizedError::GetAppErrorStrings( void LocalizedError::GetAppErrorStrings(
const GURL& display_url, const GURL& display_url,
const extensions::Extension* app, const extensions::Extension* app,
...@@ -886,3 +890,4 @@ void LocalizedError::GetAppErrorStrings( ...@@ -886,3 +890,4 @@ void LocalizedError::GetAppErrorStrings(
error_strings->Set("suggestionsLearnMore", suggest_learn_more); error_strings->Set("suggestionsLearnMore", suggest_learn_more);
#endif // defined(OS_CHROMEOS) #endif // defined(OS_CHROMEOS)
} }
#endif
...@@ -50,6 +50,7 @@ class LocalizedError { ...@@ -50,6 +50,7 @@ class LocalizedError {
// Returns true if an error page exists for the specified parameters. // Returns true if an error page exists for the specified parameters.
static bool HasStrings(const std::string& error_domain, int error_code); static bool HasStrings(const std::string& error_domain, int error_code);
#if defined(ENABLE_EXTENSIONS)
// Fills |error_strings| with values to be used to build an error page used // Fills |error_strings| with values to be used to build an error page used
// on HTTP errors, like 404 or connection reset, but using information from // on HTTP errors, like 404 or connection reset, but using information from
// the associated |app| in order to make the error page look like it's more // the associated |app| in order to make the error page look like it's more
...@@ -57,6 +58,7 @@ class LocalizedError { ...@@ -57,6 +58,7 @@ class LocalizedError {
static void GetAppErrorStrings(const GURL& display_url, static void GetAppErrorStrings(const GURL& display_url,
const extensions::Extension* app, const extensions::Extension* app,
base::DictionaryValue* error_strings); base::DictionaryValue* error_strings);
#endif
static const char kHttpErrorDomain[]; static const char kHttpErrorDomain[];
......
...@@ -1108,8 +1108,13 @@ void ChromeContentRendererClient::GetNavigationErrorStrings( ...@@ -1108,8 +1108,13 @@ void ChromeContentRendererClient::GetNavigationErrorStrings(
bool is_post = EqualsASCII(failed_request.httpMethod(), "POST"); bool is_post = EqualsASCII(failed_request.httpMethod(), "POST");
if (error_html) { if (error_html) {
bool extension_but_not_bookmark_app = false;
#if defined(ENABLE_EXTENSIONS)
extension_but_not_bookmark_app = extension && !extension->from_bookmark();
#endif
// Use a local error page. // Use a local error page.
if (extension && !extension->from_bookmark()) { if (extension_but_not_bookmark_app) {
#if defined(ENABLE_EXTENSIONS)
// TODO(erikkay): Should we use a different template for different // TODO(erikkay): Should we use a different template for different
// error messages? // error messages?
int resource_id = IDR_ERROR_APP_HTML; int resource_id = IDR_ERROR_APP_HTML;
...@@ -1126,6 +1131,7 @@ void ChromeContentRendererClient::GetNavigationErrorStrings( ...@@ -1126,6 +1131,7 @@ void ChromeContentRendererClient::GetNavigationErrorStrings(
*error_html = webui::GetTemplatesHtml(template_html, &error_strings, *error_html = webui::GetTemplatesHtml(template_html, &error_strings,
"t"); "t");
} }
#endif
} else { } else {
// TODO(ellyjones): change GetNavigationErrorStrings to take a RenderFrame // TODO(ellyjones): change GetNavigationErrorStrings to take a RenderFrame
// instead of a RenderView, then pass that in. // instead of a RenderView, then pass that in.
......
...@@ -8,7 +8,6 @@ ...@@ -8,7 +8,6 @@
#include "base/values.h" #include "base/values.h"
#include "chrome/renderer/printing/mock_printer.h" #include "chrome/renderer/printing/mock_printer.h"
#include "extensions/common/extension_messages.h"
#include "ipc/ipc_sync_message.h" #include "ipc/ipc_sync_message.h"
#include "printing/page_range.h" #include "printing/page_range.h"
#include "printing/print_job_constants.h" #include "printing/print_job_constants.h"
...@@ -20,6 +19,10 @@ ...@@ -20,6 +19,10 @@
#include "base/files/file_util.h" #include "base/files/file_util.h"
#endif #endif
#if defined(ENABLE_EXTENSIONS)
#include "extensions/common/extension_messages.h"
#endif
#if defined(ENABLE_PRINTING) #if defined(ENABLE_PRINTING)
#include "chrome/common/print_messages.h" #include "chrome/common/print_messages.h"
#endif #endif
...@@ -54,8 +57,10 @@ bool ChromeMockRenderThread::OnMessageReceived(const IPC::Message& msg) { ...@@ -54,8 +57,10 @@ bool ChromeMockRenderThread::OnMessageReceived(const IPC::Message& msg) {
// Some messages we do special handling. // Some messages we do special handling.
bool handled = true; bool handled = true;
IPC_BEGIN_MESSAGE_MAP(ChromeMockRenderThread, msg) IPC_BEGIN_MESSAGE_MAP(ChromeMockRenderThread, msg)
#if defined(ENABLE_EXTENSIONS)
IPC_MESSAGE_HANDLER(ExtensionHostMsg_OpenChannelToExtension, IPC_MESSAGE_HANDLER(ExtensionHostMsg_OpenChannelToExtension,
OnOpenChannelToExtension) OnOpenChannelToExtension)
#endif
#if defined(ENABLE_PRINTING) #if defined(ENABLE_PRINTING)
IPC_MESSAGE_HANDLER(PrintHostMsg_GetDefaultPrintSettings, IPC_MESSAGE_HANDLER(PrintHostMsg_GetDefaultPrintSettings,
OnGetDefaultPrintSettings) OnGetDefaultPrintSettings)
...@@ -83,6 +88,7 @@ bool ChromeMockRenderThread::OnMessageReceived(const IPC::Message& msg) { ...@@ -83,6 +88,7 @@ bool ChromeMockRenderThread::OnMessageReceived(const IPC::Message& msg) {
return handled; return handled;
} }
#if defined(ENABLE_EXTENSIONS)
void ChromeMockRenderThread::OnOpenChannelToExtension( void ChromeMockRenderThread::OnOpenChannelToExtension(
int routing_id, int routing_id,
const ExtensionMsg_ExternalConnectionInfo& info, const ExtensionMsg_ExternalConnectionInfo& info,
...@@ -91,6 +97,7 @@ void ChromeMockRenderThread::OnOpenChannelToExtension( ...@@ -91,6 +97,7 @@ void ChromeMockRenderThread::OnOpenChannelToExtension(
int* port_id) { int* port_id) {
*port_id = 0; *port_id = 0;
} }
#endif
#if defined(ENABLE_PRINTING) #if defined(ENABLE_PRINTING)
#if defined(OS_CHROMEOS) #if defined(OS_CHROMEOS)
......
...@@ -61,12 +61,14 @@ class ChromeMockRenderThread : public content::MockRenderThread { ...@@ -61,12 +61,14 @@ class ChromeMockRenderThread : public content::MockRenderThread {
// print and extensions. // print and extensions.
virtual bool OnMessageReceived(const IPC::Message& msg) override; virtual bool OnMessageReceived(const IPC::Message& msg) override;
#if defined(ENABLE_EXTENSIONS)
// The callee expects to be returned a valid channel_id. // The callee expects to be returned a valid channel_id.
void OnOpenChannelToExtension(int routing_id, void OnOpenChannelToExtension(int routing_id,
const ExtensionMsg_ExternalConnectionInfo& info, const ExtensionMsg_ExternalConnectionInfo& info,
const std::string& channel_name, const std::string& channel_name,
bool include_tls_channel_id, bool include_tls_channel_id,
int* port_id); int* port_id);
#endif
#if defined(ENABLE_PRINTING) #if defined(ENABLE_PRINTING)
#if defined(OS_CHROMEOS) || defined(OS_ANDROID) #if defined(OS_CHROMEOS) || defined(OS_ANDROID)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment