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

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

* chore: move gin::Handle to gin_helper

* chore: fix lint

Co-authored-by: Robo <hop2deep@gmail.com>
This commit is contained in:
Calvin
2025-08-10 13:46:37 -06:00
committed by GitHub
parent 89d5b6cd5b
commit e3f358a45a
95 changed files with 555 additions and 419 deletions

View File

@@ -8,12 +8,12 @@
#include "base/no_destructor.h"
#include "gin/data_object_builder.h"
#include "gin/handle.h"
#include "gin/object_template_builder.h"
#include "shell/browser/api/message_port.h"
#include "shell/browser/javascript_environment.h"
#include "shell/common/gin_helper/dictionary.h"
#include "shell/common/gin_helper/event_emitter_caller.h"
#include "shell/common/gin_helper/handle.h"
#include "shell/common/node_includes.h"
#include "shell/common/v8_util.h"
#include "third_party/blink/public/common/messaging/transferable_message_mojom_traits.h"
@@ -107,8 +107,8 @@ bool ParentPort::Accept(mojo::Message* mojo_message) {
}
// static
gin::Handle<ParentPort> ParentPort::Create(v8::Isolate* isolate) {
return gin::CreateHandle(isolate, ParentPort::GetInstance());
gin_helper::Handle<ParentPort> ParentPort::Create(v8::Isolate* isolate) {
return gin_helper::CreateHandle(isolate, ParentPort::GetInstance());
}
// static

View File

@@ -22,9 +22,12 @@ class Isolate;
namespace gin {
class Arguments;
} // namespace gin
namespace gin_helper {
template <typename T>
class Handle;
} // namespace gin
} // namespace gin_helper
namespace electron {
@@ -36,7 +39,7 @@ class ParentPort final : public gin_helper::DeprecatedWrappable<ParentPort>,
private mojo::MessageReceiver {
public:
static ParentPort* GetInstance();
static gin::Handle<ParentPort> Create(v8::Isolate* isolate);
static gin_helper::Handle<ParentPort> Create(v8::Isolate* isolate);
ParentPort(const ParentPort&) = delete;
ParentPort& operator=(const ParentPort&) = delete;