Skip to content

Commit

Permalink
Bug 1613985 - Use default for equivalent-to-default constructors/dest…
Browse files Browse the repository at this point in the history
…ructors in dom/presentation. r=smaug

Depends on D66023

Differential Revision: https://phabricator.services.mozilla.com/D66024

--HG--
extra : moz-landing-system : lando
  • Loading branch information
sigiesec committed Mar 9, 2020
1 parent 5e3c24c commit 3cff223
Show file tree
Hide file tree
Showing 14 changed files with 18 additions and 18 deletions.
2 changes: 1 addition & 1 deletion dom/presentation/Presentation.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ already_AddRefed<Presentation> Presentation::Create(

Presentation::Presentation(nsPIDOMWindowInner* aWindow) : mWindow(aWindow) {}

Presentation::~Presentation() {}
Presentation::~Presentation() = default;

/* virtual */
JSObject* Presentation::WrapObject(JSContext* aCx,
Expand Down
4 changes: 2 additions & 2 deletions dom/presentation/PresentationCallbacks.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ PresentationRequesterCallback::PresentationRequesterCallback(
MOZ_ASSERT(!mSessionId.IsEmpty());
}

PresentationRequesterCallback::~PresentationRequesterCallback() {}
PresentationRequesterCallback::~PresentationRequesterCallback() = default;

// nsIPresentationServiceCallback
NS_IMETHODIMP
Expand Down Expand Up @@ -77,7 +77,7 @@ PresentationReconnectCallback::PresentationReconnectCallback(
: PresentationRequesterCallback(aRequest, aSessionId, aPromise),
mConnection(aConnection) {}

PresentationReconnectCallback::~PresentationReconnectCallback() {}
PresentationReconnectCallback::~PresentationReconnectCallback() = default;

NS_IMETHODIMP
PresentationReconnectCallback::NotifySuccess(const nsAString& aUrl) {
Expand Down
2 changes: 1 addition & 1 deletion dom/presentation/PresentationConnection.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ PresentationConnection::PresentationConnection(
mRole = aRole;
}

/* virtual */ PresentationConnection::~PresentationConnection() {}
/* virtual */ PresentationConnection::~PresentationConnection() = default;

/* static */
already_AddRefed<PresentationConnection> PresentationConnection::Create(
Expand Down
2 changes: 1 addition & 1 deletion dom/presentation/PresentationDeviceManager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ NS_IMPL_ISUPPORTS(PresentationDeviceManager, nsIPresentationDeviceManager,
nsIPresentationDeviceListener, nsIObserver,
nsISupportsWeakReference)

PresentationDeviceManager::PresentationDeviceManager() {}
PresentationDeviceManager::PresentationDeviceManager() = default;

PresentationDeviceManager::~PresentationDeviceManager() {
UnloadDeviceProviders();
Expand Down
2 changes: 1 addition & 1 deletion dom/presentation/PresentationRequest.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ PresentationRequest::PresentationRequest(nsPIDOMWindowInner* aWindow,
nsTArray<nsString>&& aUrls)
: DOMEventTargetHelper(aWindow), mUrls(std::move(aUrls)) {}

PresentationRequest::~PresentationRequest() {}
PresentationRequest::~PresentationRequest() = default;

bool PresentationRequest::Init() { return true; }

Expand Down
2 changes: 1 addition & 1 deletion dom/presentation/PresentationService.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -244,7 +244,7 @@ PresentationDeviceRequest::Cancel(nsresult aReason) {

NS_IMPL_ISUPPORTS(PresentationService, nsIPresentationService, nsIObserver)

PresentationService::PresentationService() {}
PresentationService::PresentationService() = default;

PresentationService::~PresentationService() { HandleShutdown(); }

Expand Down
2 changes: 1 addition & 1 deletion dom/presentation/PresentationSessionInfo.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ class TCPPresentationChannelDescription final
: mAddress(aAddress), mPort(aPort) {}

private:
~TCPPresentationChannelDescription() {}
~TCPPresentationChannelDescription() = default;

nsCString mAddress;
uint16_t mPort;
Expand Down
2 changes: 1 addition & 1 deletion dom/presentation/PresentationSessionRequest.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ PresentationSessionRequest::PresentationSessionRequest(
mDevice(aDevice),
mControlChannel(aControlChannel) {}

PresentationSessionRequest::~PresentationSessionRequest() {}
PresentationSessionRequest::~PresentationSessionRequest() = default;

// nsIPresentationSessionRequest

Expand Down
4 changes: 2 additions & 2 deletions dom/presentation/PresentationTCPSessionTransport.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ class CopierCallbacks final : public nsIRequestObserver {
NS_DECL_ISUPPORTS
NS_DECL_NSIREQUESTOBSERVER
private:
~CopierCallbacks() {}
~CopierCallbacks() = default;

RefPtr<PresentationTCPSessionTransport> mOwner;
};
Expand Down Expand Up @@ -72,7 +72,7 @@ PresentationTCPSessionTransport::PresentationTCPSessionTransport()
mCloseStatus(NS_OK),
mDataNotificationEnabled(false) {}

PresentationTCPSessionTransport::~PresentationTCPSessionTransport() {}
PresentationTCPSessionTransport::~PresentationTCPSessionTransport() = default;

NS_IMETHODIMP
PresentationTCPSessionTransport::BuildTCPSenderTransport(
Expand Down
2 changes: 1 addition & 1 deletion dom/presentation/PresentationTerminateRequest.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ PresentationTerminateRequest::PresentationTerminateRequest(
mControlChannel(aControlChannel),
mIsFromReceiver(aIsFromReceiver) {}

PresentationTerminateRequest::~PresentationTerminateRequest() {}
PresentationTerminateRequest::~PresentationTerminateRequest() = default;

// nsIPresentationTerminateRequest
NS_IMETHODIMP
Expand Down
2 changes: 1 addition & 1 deletion dom/presentation/ipc/PresentationContentSessionInfo.h
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ class PresentationContentSessionInfo final
nsresult Close(nsresult aReason);

private:
virtual ~PresentationContentSessionInfo() {}
virtual ~PresentationContentSessionInfo() = default;

nsString mSessionId;
uint8_t mRole;
Expand Down
6 changes: 3 additions & 3 deletions dom/presentation/ipc/PresentationParent.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -87,9 +87,9 @@ NS_IMPL_ISUPPORTS(PresentationParent, nsIPresentationAvailabilityListener,
nsIPresentationSessionListener,
nsIPresentationRespondingListener)

PresentationParent::PresentationParent() {}
PresentationParent::PresentationParent() = default;

/* virtual */ PresentationParent::~PresentationParent() {}
/* virtual */ PresentationParent::~PresentationParent() = default;

bool PresentationParent::Init(ContentParentId aContentParentId) {
MOZ_ASSERT(!mService);
Expand Down Expand Up @@ -343,7 +343,7 @@ PresentationRequestParent::PresentationRequestParent(
nsIPresentationService* aService, ContentParentId aContentParentId)
: mService(aService), mChildId(aContentParentId) {}

PresentationRequestParent::~PresentationRequestParent() {}
PresentationRequestParent::~PresentationRequestParent() = default;

void PresentationRequestParent::ActorDestroy(ActorDestroyReason aWhy) {
mActorDestroyed = true;
Expand Down
2 changes: 1 addition & 1 deletion dom/presentation/provider/MulticastDNSDeviceProvider.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ NS_IMPL_ISUPPORTS(MulticastDNSDeviceProvider, nsIPresentationDeviceProvider,
nsIDNSServiceResolveListener,
nsIPresentationControlServerListener, nsIObserver)

MulticastDNSDeviceProvider::MulticastDNSDeviceProvider() {}
MulticastDNSDeviceProvider::MulticastDNSDeviceProvider() = default;
MulticastDNSDeviceProvider::~MulticastDNSDeviceProvider() { Uninit(); }

nsresult MulticastDNSDeviceProvider::Init() {
Expand Down
2 changes: 1 addition & 1 deletion dom/presentation/provider/nsTCPDeviceInfo.h
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ class TCPDeviceInfo final : public nsITCPDeviceInfo {
mCertFingerprint(aCertFingerprint) {}

private:
virtual ~TCPDeviceInfo() {}
virtual ~TCPDeviceInfo() = default;

nsCString mId;
nsCString mAddress;
Expand Down

0 comments on commit 3cff223

Please sign in to comment.