refactor: replace deprecated DISALLOW_COPY_AND_ASSIGN (#31633)
This commit is contained in:
parent
2a2a1a834c
commit
65a980c673
231 changed files with 918 additions and 576 deletions
|
@ -106,8 +106,6 @@ class WindowsToastNotification : public Notification {
|
|||
ComPtr<ToastEventHandler> event_handler_;
|
||||
ComPtr<ABI::Windows::UI::Notifications::IToastNotification>
|
||||
toast_notification_;
|
||||
|
||||
DISALLOW_COPY_AND_ASSIGN(WindowsToastNotification);
|
||||
};
|
||||
|
||||
class ToastEventHandler : public RuntimeClass<RuntimeClassFlags<ClassicCom>,
|
||||
|
@ -118,6 +116,10 @@ class ToastEventHandler : public RuntimeClass<RuntimeClassFlags<ClassicCom>,
|
|||
explicit ToastEventHandler(Notification* notification);
|
||||
~ToastEventHandler() override;
|
||||
|
||||
// disable copy
|
||||
ToastEventHandler(const ToastEventHandler&) = delete;
|
||||
ToastEventHandler& operator=(const ToastEventHandler&) = delete;
|
||||
|
||||
IFACEMETHODIMP Invoke(
|
||||
ABI::Windows::UI::Notifications::IToastNotification* sender,
|
||||
IInspectable* args) override;
|
||||
|
@ -130,8 +132,6 @@ class ToastEventHandler : public RuntimeClass<RuntimeClassFlags<ClassicCom>,
|
|||
|
||||
private:
|
||||
base::WeakPtr<Notification> notification_; // weak ref.
|
||||
|
||||
DISALLOW_COPY_AND_ASSIGN(ToastEventHandler);
|
||||
};
|
||||
|
||||
} // namespace electron
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue