chore: fix IsolateData handling (#20918)
This commit is contained in:
parent
776cab96b1
commit
b194d5d0e2
4 changed files with 17 additions and 4 deletions
|
@ -19,6 +19,7 @@ class MessageLoop;
|
|||
namespace node {
|
||||
class Environment;
|
||||
class MultiIsolatePlatform;
|
||||
class IsolateData;
|
||||
} // namespace node
|
||||
|
||||
namespace electron {
|
||||
|
@ -54,6 +55,8 @@ class NodeBindings {
|
|||
// Do message loop integration.
|
||||
virtual void RunMessageLoop();
|
||||
|
||||
node::IsolateData* isolate_data() const { return isolate_data_; }
|
||||
|
||||
// Gets/sets the environment to wrap uv loop.
|
||||
void set_uv_env(node::Environment* env) { uv_env_ = env; }
|
||||
node::Environment* uv_env() const { return uv_env_; }
|
||||
|
@ -106,6 +109,9 @@ class NodeBindings {
|
|||
// Environment that to wrap the uv loop.
|
||||
node::Environment* uv_env_ = nullptr;
|
||||
|
||||
// Isolate data used in creating the environment
|
||||
node::IsolateData* isolate_data_ = nullptr;
|
||||
|
||||
base::WeakPtrFactory<NodeBindings> weak_factory_;
|
||||
|
||||
DISALLOW_COPY_AND_ASSIGN(NodeBindings);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue