Files
electron/shell/browser/electron_plugin_info_host_impl.h
Samuel Attard 88cdf50b0a 7159368: update PluginService API for sync GetPlugins
Upstream removed async PluginService APIs:
- GetPluginsAsync() removed, use synchronous GetPlugins()
- RegisterInternalPlugin() now takes single argument (remove add_at_beginning)
- RefreshPlugins() removed entirely

Updated ElectronPluginInfoHostImpl to use synchronous plugin loading and
simplified ElectronBrowserMainParts internal plugin registration.

Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7159368
Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7159328
Ref: https://chromium-review.googlesource.com/c/chromium/src/+/7159056
2025-11-24 16:26:45 -08:00

41 lines
1.1 KiB
C++

// Copyright 2012 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#ifndef SHELL_BROWSER_ELECTRON_PLUGIN_INFO_HOST_IMPL_H_
#define SHELL_BROWSER_ELECTRON_PLUGIN_INFO_HOST_IMPL_H_
#include <string>
#include "shell/common/plugin.mojom.h"
class GURL;
namespace url {
class Origin;
}
namespace electron {
// Implements ElectronPluginInfoHost interface.
class ElectronPluginInfoHostImpl : public mojom::ElectronPluginInfoHost {
public:
ElectronPluginInfoHostImpl();
ElectronPluginInfoHostImpl(const ElectronPluginInfoHostImpl&) = delete;
ElectronPluginInfoHostImpl& operator=(const ElectronPluginInfoHostImpl&) =
delete;
~ElectronPluginInfoHostImpl() override;
// mojom::ElectronPluginInfoHost
void GetPluginInfo(const GURL& url,
const url::Origin& origin,
const std::string& mime_type,
GetPluginInfoCallback callback) override;
};
} // namespace electron
#endif // SHELL_BROWSER_ELECTRON_PLUGIN_INFO_HOST_IMPL_H_