chore: move gin::Handle to gin_helper (#47959)

* chore: move gin::Handle to gin_helper

* chore: fix lint
This commit is contained in:
Robo
2025-08-05 02:03:06 +09:00
committed by GitHub
parent 9d05454dc7
commit 4ca10a1056
95 changed files with 555 additions and 419 deletions

View File

@@ -8,7 +8,6 @@
#include "content/public/renderer/render_frame_observer.h"
#include "content/public/renderer/worker_thread.h"
#include "gin/dictionary.h"
#include "gin/handle.h"
#include "gin/object_template_builder.h"
#include "services/service_manager/public/cpp/interface_provider.h"
#include "shell/common/api/api.mojom.h"
@@ -17,6 +16,7 @@
#include "shell/common/gin_helper/dictionary.h"
#include "shell/common/gin_helper/error_thrower.h"
#include "shell/common/gin_helper/function_template_extensions.h"
#include "shell/common/gin_helper/handle.h"
#include "shell/common/gin_helper/promise.h"
#include "shell/common/gin_helper/wrappable.h"
#include "shell/common/node_bindings.h"
@@ -59,8 +59,8 @@ class IPCBase : public gin_helper::DeprecatedWrappable<T> {
public:
static gin::DeprecatedWrapperInfo kWrapperInfo;
static gin::Handle<T> Create(v8::Isolate* isolate) {
return gin::CreateHandle(isolate, new T(isolate));
static gin_helper::Handle<T> Create(v8::Isolate* isolate) {
return gin_helper::CreateHandle(isolate, new T(isolate));
}
void SendMessage(v8::Isolate* isolate,

View File

@@ -17,7 +17,6 @@
#include "content/public/renderer/render_frame.h"
#include "content/public/renderer/render_frame_observer.h"
#include "content/public/renderer/render_frame_visitor.h"
#include "gin/handle.h"
#include "gin/object_template_builder.h"
#include "services/service_manager/public/cpp/interface_provider.h"
#include "shell/common/api/api.mojom.h"
@@ -29,6 +28,7 @@
#include "shell/common/gin_helper/dictionary.h"
#include "shell/common/gin_helper/error_thrower.h"
#include "shell/common/gin_helper/function_template_extensions.h"
#include "shell/common/gin_helper/handle.h"
#include "shell/common/gin_helper/object_template_builder.h"
#include "shell/common/gin_helper/promise.h"
#include "shell/common/gin_helper/wrappable.h"
@@ -383,14 +383,17 @@ class WebFrameRenderer final
.Build();
}
static const char* GetClassName() { return "WebFrame"; }
static gin::Handle<WebFrameRenderer> New(v8::Isolate* isolate) { return {}; }
static gin_helper::Handle<WebFrameRenderer> New(v8::Isolate* isolate) {
return {};
}
static gin::DeprecatedWrapperInfo kWrapperInfo;
static gin::Handle<WebFrameRenderer> Create(
static gin_helper::Handle<WebFrameRenderer> Create(
v8::Isolate* isolate,
content::RenderFrame* render_frame) {
return gin::CreateHandle(isolate, new WebFrameRenderer(render_frame));
return gin_helper::CreateHandle(isolate,
new WebFrameRenderer(render_frame));
}
explicit WebFrameRenderer(content::RenderFrame* render_frame)