#include "components/guest_view/renderer/guest_view_container.h"
#include <memory>
#include "base/containers/contains.h"
#include "base/functional/bind.h"
#include "base/memory/raw_ptr.h"
#include "base/no_destructor.h"
#include "components/guest_view/common/guest_view_constants.h"
#include "components/guest_view/renderer/guest_view_request.h"
#include "content/public/renderer/render_frame_observer.h"
#include "v8/include/v8-context.h"
#include "v8/include/v8-function.h"
#include "v8/include/v8-microtask-queue.h"
#include "v8/include/v8-primitive.h"
namespace {
GuestViewContainerMap;
GuestViewContainerMap& GetContainerMap() { … }
}
namespace guest_view {
class GuestViewContainer::RenderFrameLifetimeObserver
: public content::RenderFrameObserver { … };
GuestViewContainer::RenderFrameLifetimeObserver::RenderFrameLifetimeObserver(
GuestViewContainer* container,
content::RenderFrame* render_frame)
: … { … }
void GuestViewContainer::RenderFrameLifetimeObserver::OnDestruct() { … }
GuestViewContainer::GuestViewContainer(content::RenderFrame* render_frame,
int element_instance_id)
: … { … }
GuestViewContainer::~GuestViewContainer() { … }
GuestViewContainer* GuestViewContainer::FromID(int element_instance_id) { … }
void GuestViewContainer::Destroy(bool embedder_frame_destroyed) { … }
void GuestViewContainer::RegisterDestructionCallback(
v8::Local<v8::Function> callback,
v8::Isolate* isolate) { … }
void GuestViewContainer::RenderFrameDestroyed() { … }
void GuestViewContainer::IssueRequest(
std::unique_ptr<GuestViewAttachRequest> request) { … }
void GuestViewContainer::EnqueueRequest(
std::unique_ptr<GuestViewAttachRequest> request) { … }
void GuestViewContainer::PerformPendingRequest() { … }
void GuestViewContainer::RunDestructionCallback(bool embedder_frame_destroyed) { … }
void GuestViewContainer::OnRequestAcknowledged(
GuestViewAttachRequest* request) { … }
}