From d539846cab7c8b2859f74c7aa6cc216a797f1a41 Mon Sep 17 00:00:00 2001 From: Joshua Cranmer Date: Fri, 6 Jul 2012 13:15:45 -0500 Subject: [PATCH] Bug 702877 - Replace NS_OVERRIDE with MOZ_OVERRIDE. r=ehsan --HG-- extra : rebase_source : 1843575683c3897f96f3966cbce26140ff1a7d90 --- chrome/src/nsChromeRegistryChrome.h | 42 ++--- chrome/src/nsChromeRegistryContent.h | 38 ++-- content/smil/nsSMILCSSValueType.h | 34 ++-- content/smil/nsSMILSetAnimationFunction.h | 16 +- .../src/SVGMotionSMILAnimationFunction.h | 20 +-- dom/ipc/ContentChild.h | 4 +- dom/ipc/ContentParent.h | 4 +- dom/ipc/ContentProcess.h | 6 +- dom/ipc/TabChild.h | 9 +- dom/ipc/TabParent.h | 6 +- dom/plugins/base/PluginPRLibrary.h | 11 +- dom/plugins/ipc/BrowserStreamChild.h | 2 +- dom/plugins/ipc/BrowserStreamParent.h | 2 +- dom/plugins/ipc/ChildAsyncCall.h | 4 +- dom/plugins/ipc/PluginBackgroundDestroyer.h | 6 +- dom/plugins/ipc/PluginInstanceChild.h | 28 ++- dom/plugins/ipc/PluginInstanceParent.h | 36 ++-- dom/plugins/ipc/PluginModuleChild.h | 28 ++- dom/plugins/ipc/PluginModuleParent.h | 77 ++++----- dom/plugins/ipc/PluginProcessChild.h | 4 +- dom/plugins/ipc/PluginStreamChild.h | 2 +- dom/plugins/ipc/PluginStreamParent.h | 2 +- dom/plugins/ipc/StreamNotifyChild.h | 4 +- dom/sms/src/ipc/SmsChild.h | 30 ++-- dom/sms/src/ipc/SmsParent.h | 22 +-- gfx/layers/ipc/ShadowLayerChild.h | 3 +- gfx/layers/ipc/ShadowLayerParent.h | 3 +- gfx/thebes/gfxImageSurface.h | 3 +- hal/sandbox/SandboxHal.cpp | 162 +++++++++--------- ipc/glue/AsyncChannel.h | 18 +- ipc/glue/RPCChannel.h | 19 +- ipc/glue/SharedMemory.h | 1 + ipc/glue/SharedMemoryBasic_android.h | 12 +- ipc/glue/SharedMemoryBasic_chromium.h | 12 +- ipc/glue/SharedMemorySysV.h | 12 +- ipc/glue/SyncChannel.h | 7 +- ipc/ipdl/test/cxx/TestBadActor.h | 3 +- ipc/ipdl/test/cxx/TestBlockChild.h | 30 ++-- ipc/ipdl/test/cxx/TestBridgeMain.h | 48 ++---- ipc/ipdl/test/cxx/TestCrashCleanup.h | 9 +- ipc/ipdl/test/cxx/TestDataStructures.h | 85 ++++----- ipc/ipdl/test/cxx/TestDesc.h | 36 ++-- ipc/ipdl/test/cxx/TestFailedCtor.h | 48 ++---- ipc/ipdl/test/cxx/TestHangs.h | 22 +-- ipc/ipdl/test/cxx/TestJSON.h | 24 +-- ipc/ipdl/test/cxx/TestLatency.h | 27 +-- ipc/ipdl/test/cxx/TestManyChildAllocs.h | 27 +-- ipc/ipdl/test/cxx/TestMultiMgrs.h | 66 +++---- ipc/ipdl/test/cxx/TestNestedLoops.h | 15 +- ipc/ipdl/test/cxx/TestOpens.h | 36 ++-- ipc/ipdl/test/cxx/TestRPCErrorCleanup.h | 12 +- ipc/ipdl/test/cxx/TestRPCRaces.h | 51 ++---- ipc/ipdl/test/cxx/TestRPCShutdownRace.h | 18 +- ipc/ipdl/test/cxx/TestRaceDeferral.h | 24 +-- ipc/ipdl/test/cxx/TestRacyRPCReplies.h | 21 +-- ipc/ipdl/test/cxx/TestRacyReentry.h | 18 +- ipc/ipdl/test/cxx/TestRacyUndefer.h | 27 +-- ipc/ipdl/test/cxx/TestSanity.h | 12 +- ipc/ipdl/test/cxx/TestSelfManageRoot.h | 36 ++-- ipc/ipdl/test/cxx/TestShmem.h | 12 +- ipc/ipdl/test/cxx/TestShutdown.h | 51 ++---- ipc/ipdl/test/cxx/TestStackHooks.h | 48 ++---- ipc/ipdl/test/cxx/TestSyncError.h | 18 +- ipc/ipdl/test/cxx/TestSyncHang.h | 6 +- ipc/ipdl/test/cxx/TestSyncWakeup.h | 27 +-- ipc/ipdl/test/cxx/TestSysVShmem.h | 12 +- layout/ipc/RenderFrameChild.h | 6 +- layout/ipc/RenderFrameParent.h | 12 +- netwerk/protocol/ftp/FTPChannelChild.h | 28 +-- netwerk/protocol/ftp/FTPChannelParent.h | 30 ++-- xpcom/base/nscore.h | 2 - xpcom/components/nsNativeComponentLoader.h | 2 +- .../tests/static-checker/override-global.cpp | 1 - .../override-namespace-typedef.cpp | 16 -- xpcom/tests/static-checker/override-pass.cpp | 21 --- .../static-checker/override-signature.cpp | 9 - .../tests/static-checker/override-static.cpp | 9 - .../tests/static-checker/override-virtual.cpp | 9 - 78 files changed, 644 insertions(+), 1059 deletions(-) delete mode 100644 xpcom/tests/static-checker/override-global.cpp delete mode 100644 xpcom/tests/static-checker/override-namespace-typedef.cpp delete mode 100644 xpcom/tests/static-checker/override-pass.cpp delete mode 100644 xpcom/tests/static-checker/override-signature.cpp delete mode 100644 xpcom/tests/static-checker/override-static.cpp delete mode 100644 xpcom/tests/static-checker/override-virtual.cpp diff --git a/chrome/src/nsChromeRegistryChrome.h b/chrome/src/nsChromeRegistryChrome.h index a2e4df4909f3..64eaf67b4b3c 100644 --- a/chrome/src/nsChromeRegistryChrome.h +++ b/chrome/src/nsChromeRegistryChrome.h @@ -22,24 +22,24 @@ class nsChromeRegistryChrome : public nsChromeRegistry nsChromeRegistryChrome(); ~nsChromeRegistryChrome(); - NS_OVERRIDE nsresult Init(); + nsresult Init() MOZ_OVERRIDE; - NS_OVERRIDE NS_IMETHOD CheckForNewChrome(); - NS_OVERRIDE NS_IMETHOD CheckForOSAccessibility(); - NS_OVERRIDE NS_IMETHOD GetLocalesForPackage(const nsACString& aPackage, - nsIUTF8StringEnumerator* *aResult); - NS_OVERRIDE NS_IMETHOD IsLocaleRTL(const nsACString& package, - bool *aResult); - NS_OVERRIDE NS_IMETHOD GetSelectedLocale(const nsACString& aPackage, - nsACString& aLocale); - NS_OVERRIDE NS_IMETHOD Observe(nsISupports *aSubject, const char *aTopic, - const PRUnichar *someData); + NS_IMETHOD CheckForNewChrome() MOZ_OVERRIDE; + NS_IMETHOD CheckForOSAccessibility() MOZ_OVERRIDE; + NS_IMETHOD GetLocalesForPackage(const nsACString& aPackage, + nsIUTF8StringEnumerator* *aResult) MOZ_OVERRIDE; + NS_IMETHOD IsLocaleRTL(const nsACString& package, + bool *aResult) MOZ_OVERRIDE; + NS_IMETHOD GetSelectedLocale(const nsACString& aPackage, + nsACString& aLocale) MOZ_OVERRIDE; + NS_IMETHOD Observe(nsISupports *aSubject, const char *aTopic, + const PRUnichar *someData) MOZ_OVERRIDE; #ifdef MOZ_XUL - NS_OVERRIDE NS_IMETHOD GetXULOverlays(nsIURI *aURI, - nsISimpleEnumerator **_retval); - NS_OVERRIDE NS_IMETHOD GetStyleOverlays(nsIURI *aURI, - nsISimpleEnumerator **_retval); + NS_IMETHOD GetXULOverlays(nsIURI *aURI, + nsISimpleEnumerator **_retval) MOZ_OVERRIDE; + NS_IMETHOD GetStyleOverlays(nsIURI *aURI, + nsISimpleEnumerator **_retval) MOZ_OVERRIDE; #endif void SendRegisteredChrome(mozilla::dom::PContentParent* aChild); @@ -50,12 +50,12 @@ class nsChromeRegistryChrome : public nsChromeRegistry PRUint32 number, void *arg); nsresult SelectLocaleFromPref(nsIPrefBranch* prefs); - NS_OVERRIDE nsresult UpdateSelectedLocale(); - NS_OVERRIDE nsIURI* GetBaseURIFromPackage(const nsCString& aPackage, - const nsCString& aProvider, - const nsCString& aPath); - NS_OVERRIDE nsresult GetFlagsFromPackage(const nsCString& aPackage, - PRUint32* aFlags); + nsresult UpdateSelectedLocale() MOZ_OVERRIDE; + nsIURI* GetBaseURIFromPackage(const nsCString& aPackage, + const nsCString& aProvider, + const nsCString& aPath) MOZ_OVERRIDE; + nsresult GetFlagsFromPackage(const nsCString& aPackage, + PRUint32* aFlags) MOZ_OVERRIDE; static const PLDHashTableOps kTableOps; static PLDHashNumber HashKey(PLDHashTable *table, const void *key); diff --git a/chrome/src/nsChromeRegistryContent.h b/chrome/src/nsChromeRegistryContent.h index 1b8323fad439..bd73dbb72c37 100644 --- a/chrome/src/nsChromeRegistryContent.h +++ b/chrome/src/nsChromeRegistryContent.h @@ -25,20 +25,20 @@ class nsChromeRegistryContent : public nsChromeRegistry const nsTArray& aOverrides, const nsACString& aLocale); - NS_OVERRIDE NS_IMETHOD GetLocalesForPackage(const nsACString& aPackage, - nsIUTF8StringEnumerator* *aResult); - NS_OVERRIDE NS_IMETHOD CheckForNewChrome(); - NS_OVERRIDE NS_IMETHOD CheckForOSAccessibility(); - NS_OVERRIDE NS_IMETHOD Observe(nsISupports* aSubject, const char* aTopic, - const PRUnichar* aData); - NS_OVERRIDE NS_IMETHOD IsLocaleRTL(const nsACString& package, - bool *aResult); - NS_OVERRIDE NS_IMETHOD GetSelectedLocale(const nsACString& aPackage, - nsACString& aLocale); - NS_OVERRIDE NS_IMETHOD GetStyleOverlays(nsIURI *aChromeURL, - nsISimpleEnumerator **aResult); - NS_OVERRIDE NS_IMETHOD GetXULOverlays(nsIURI *aChromeURL, - nsISimpleEnumerator **aResult); + NS_IMETHOD GetLocalesForPackage(const nsACString& aPackage, + nsIUTF8StringEnumerator* *aResult) MOZ_OVERRIDE; + NS_IMETHOD CheckForNewChrome() MOZ_OVERRIDE; + NS_IMETHOD CheckForOSAccessibility() MOZ_OVERRIDE; + NS_IMETHOD Observe(nsISupports* aSubject, const char* aTopic, + const PRUnichar* aData) MOZ_OVERRIDE; + NS_IMETHOD IsLocaleRTL(const nsACString& package, + bool *aResult) MOZ_OVERRIDE; + NS_IMETHOD GetSelectedLocale(const nsACString& aPackage, + nsACString& aLocale) MOZ_OVERRIDE; + NS_IMETHOD GetStyleOverlays(nsIURI *aChromeURL, + nsISimpleEnumerator **aResult) MOZ_OVERRIDE; + NS_IMETHOD GetXULOverlays(nsIURI *aChromeURL, + nsISimpleEnumerator **aResult) MOZ_OVERRIDE; private: struct PackageEntry @@ -56,11 +56,11 @@ class nsChromeRegistryContent : public nsChromeRegistry void RegisterResource(const ResourceMapping& aResource); void RegisterOverride(const OverrideMapping& aOverride); - NS_OVERRIDE nsresult UpdateSelectedLocale(); - NS_OVERRIDE nsIURI* GetBaseURIFromPackage(const nsCString& aPackage, - const nsCString& aProvider, - const nsCString& aPath); - NS_OVERRIDE nsresult GetFlagsFromPackage(const nsCString& aPackage, PRUint32* aFlags); + nsresult UpdateSelectedLocale() MOZ_OVERRIDE; + nsIURI* GetBaseURIFromPackage(const nsCString& aPackage, + const nsCString& aProvider, + const nsCString& aPath) MOZ_OVERRIDE; + nsresult GetFlagsFromPackage(const nsCString& aPackage, PRUint32* aFlags) MOZ_OVERRIDE; nsClassHashtable mPackagesHash; nsCString mLocale; diff --git a/content/smil/nsSMILCSSValueType.h b/content/smil/nsSMILCSSValueType.h index 8af3891c44b4..152461b73eea 100644 --- a/content/smil/nsSMILCSSValueType.h +++ b/content/smil/nsSMILCSSValueType.h @@ -10,7 +10,7 @@ #include "nsISMILType.h" #include "nsCSSProperty.h" -#include "nscore.h" // For NS_OVERRIDE +#include "mozilla/Attributes.h" class nsAString; @@ -34,22 +34,22 @@ public: protected: // nsISMILType Methods // ------------------- - NS_OVERRIDE virtual void Init(nsSMILValue& aValue) const; - NS_OVERRIDE virtual void Destroy(nsSMILValue&) const; - NS_OVERRIDE virtual nsresult Assign(nsSMILValue& aDest, - const nsSMILValue& aSrc) const; - NS_OVERRIDE virtual bool IsEqual(const nsSMILValue& aLeft, - const nsSMILValue& aRight) const; - NS_OVERRIDE virtual nsresult Add(nsSMILValue& aDest, - const nsSMILValue& aValueToAdd, - PRUint32 aCount) const; - NS_OVERRIDE virtual nsresult ComputeDistance(const nsSMILValue& aFrom, - const nsSMILValue& aTo, - double& aDistance) const; - NS_OVERRIDE virtual nsresult Interpolate(const nsSMILValue& aStartVal, - const nsSMILValue& aEndVal, - double aUnitDistance, - nsSMILValue& aResult) const; + virtual void Init(nsSMILValue& aValue) const MOZ_OVERRIDE; + virtual void Destroy(nsSMILValue&) const MOZ_OVERRIDE; + virtual nsresult Assign(nsSMILValue& aDest, + const nsSMILValue& aSrc) const MOZ_OVERRIDE; + virtual bool IsEqual(const nsSMILValue& aLeft, + const nsSMILValue& aRight) const MOZ_OVERRIDE; + virtual nsresult Add(nsSMILValue& aDest, + const nsSMILValue& aValueToAdd, + PRUint32 aCount) const MOZ_OVERRIDE; + virtual nsresult ComputeDistance(const nsSMILValue& aFrom, + const nsSMILValue& aTo, + double& aDistance) const MOZ_OVERRIDE; + virtual nsresult Interpolate(const nsSMILValue& aStartVal, + const nsSMILValue& aEndVal, + double aUnitDistance, + nsSMILValue& aResult) const MOZ_OVERRIDE; public: // Helper Methods diff --git a/content/smil/nsSMILSetAnimationFunction.h b/content/smil/nsSMILSetAnimationFunction.h index 4f6384042f8d..e38433bd9b26 100644 --- a/content/smil/nsSMILSetAnimationFunction.h +++ b/content/smil/nsSMILSetAnimationFunction.h @@ -39,26 +39,26 @@ public: * @returns true if aAttribute is a recognized animation-related * attribute; false otherwise. */ - NS_OVERRIDE virtual bool UnsetAttr(nsIAtom* aAttribute); + virtual bool UnsetAttr(nsIAtom* aAttribute) MOZ_OVERRIDE; protected: // Although animation might look like to-animation, unlike to-animation, // it never interpolates values. // Returning false here will mean this animation function gets treated as // a single-valued function and no interpolation will be attempted. - NS_OVERRIDE virtual bool IsToAnimation() const { + virtual bool IsToAnimation() const MOZ_OVERRIDE { return false; } // applies the exact same value across the simple duration. - NS_OVERRIDE virtual bool IsValueFixedForSimpleDuration() const { + virtual bool IsValueFixedForSimpleDuration() const MOZ_OVERRIDE { return true; } - NS_OVERRIDE virtual bool HasAttr(nsIAtom* aAttName) const; - NS_OVERRIDE virtual const nsAttrValue* GetAttr(nsIAtom* aAttName) const; - NS_OVERRIDE virtual bool GetAttr(nsIAtom* aAttName, - nsAString& aResult) const; - NS_OVERRIDE virtual bool WillReplace() const; + virtual bool HasAttr(nsIAtom* aAttName) const MOZ_OVERRIDE; + virtual const nsAttrValue* GetAttr(nsIAtom* aAttName) const MOZ_OVERRIDE; + virtual bool GetAttr(nsIAtom* aAttName, + nsAString& aResult) const MOZ_OVERRIDE; + virtual bool WillReplace() const MOZ_OVERRIDE; bool IsDisallowedAttribute(const nsIAtom* aAttribute) const; }; diff --git a/content/svg/content/src/SVGMotionSMILAnimationFunction.h b/content/svg/content/src/SVGMotionSMILAnimationFunction.h index be4ac17d5375..2bac4b0d03d1 100644 --- a/content/svg/content/src/SVGMotionSMILAnimationFunction.h +++ b/content/svg/content/src/SVGMotionSMILAnimationFunction.h @@ -31,11 +31,11 @@ class SVGMotionSMILAnimationFunction : public nsSMILAnimationFunction { public: SVGMotionSMILAnimationFunction(); - NS_OVERRIDE virtual bool SetAttr(nsIAtom* aAttribute, - const nsAString& aValue, - nsAttrValue& aResult, - nsresult* aParseResult = nsnull); - NS_OVERRIDE virtual bool UnsetAttr(nsIAtom* aAttribute); + virtual bool SetAttr(nsIAtom* aAttribute, + const nsAString& aValue, + nsAttrValue& aResult, + nsresult* aParseResult = nsnull) MOZ_OVERRIDE; + virtual bool UnsetAttr(nsIAtom* aAttribute) MOZ_OVERRIDE; // Method to allow our owner-element to signal us when our // has changed or been added/removed. When that happens, we need to @@ -56,12 +56,12 @@ protected: ePathSourceType_Mpath }; - NS_OVERRIDE virtual nsSMILCalcMode GetCalcMode() const; - NS_OVERRIDE virtual nsresult GetValues(const nsISMILAttr& aSMILAttr, - nsSMILValueArray& aResult); - NS_OVERRIDE virtual void CheckValueListDependentAttrs(PRUint32 aNumValues); + virtual nsSMILCalcMode GetCalcMode() const MOZ_OVERRIDE; + virtual nsresult GetValues(const nsISMILAttr& aSMILAttr, + nsSMILValueArray& aResult) MOZ_OVERRIDE; + virtual void CheckValueListDependentAttrs(PRUint32 aNumValues) MOZ_OVERRIDE; - NS_OVERRIDE virtual bool IsToAnimation() const; + virtual bool IsToAnimation() const MOZ_OVERRIDE; void CheckKeyPoints(); nsresult SetKeyPoints(const nsAString& aKeyPoints, nsAttrValue& aResult); diff --git a/dom/ipc/ContentChild.h b/dom/ipc/ContentChild.h index ffebd3eca91c..841def5e5324 100644 --- a/dom/ipc/ContentChild.h +++ b/dom/ipc/ContentChild.h @@ -76,8 +76,8 @@ public: virtual bool DeallocPCrashReporter(PCrashReporterChild*); - NS_OVERRIDE virtual PHalChild* AllocPHal(); - NS_OVERRIDE virtual bool DeallocPHal(PHalChild*); + virtual PHalChild* AllocPHal() MOZ_OVERRIDE; + virtual bool DeallocPHal(PHalChild*) MOZ_OVERRIDE; virtual PIndexedDBChild* AllocPIndexedDB(); virtual bool DeallocPIndexedDB(PIndexedDBChild* aActor); diff --git a/dom/ipc/ContentParent.h b/dom/ipc/ContentParent.h index eabe2dd3eac5..8c8679ccfd11 100644 --- a/dom/ipc/ContentParent.h +++ b/dom/ipc/ContentParent.h @@ -146,8 +146,8 @@ private: const NativeThreadId& tid, const PRUint32& processType); - NS_OVERRIDE virtual PHalParent* AllocPHal(); - NS_OVERRIDE virtual bool DeallocPHal(PHalParent*); + virtual PHalParent* AllocPHal() MOZ_OVERRIDE; + virtual bool DeallocPHal(PHalParent*) MOZ_OVERRIDE; virtual PIndexedDBParent* AllocPIndexedDB(); diff --git a/dom/ipc/ContentProcess.h b/dom/ipc/ContentProcess.h index 189db3fbf255..d30cb3ad6dff 100644 --- a/dom/ipc/ContentProcess.h +++ b/dom/ipc/ContentProcess.h @@ -33,10 +33,8 @@ public: ~ContentProcess() { } - NS_OVERRIDE - virtual bool Init(); - NS_OVERRIDE - virtual void CleanUp(); + virtual bool Init() MOZ_OVERRIDE; + virtual void CleanUp() MOZ_OVERRIDE; private: ContentChild mContent; diff --git a/dom/ipc/TabChild.h b/dom/ipc/TabChild.h index 47d3e88c740a..fa6034b9afde 100644 --- a/dom/ipc/TabChild.h +++ b/dom/ipc/TabChild.h @@ -259,15 +259,12 @@ public: bool IsAsyncPanZoomEnabled(); protected: - NS_OVERRIDE virtual PRenderFrameChild* AllocPRenderFrame(ScrollingBehavior* aScrolling, LayersBackend* aBackend, int32_t* aMaxTextureSize, - uint64_t* aLayersId); - NS_OVERRIDE - virtual bool DeallocPRenderFrame(PRenderFrameChild* aFrame); - NS_OVERRIDE - virtual bool RecvDestroy(); + uint64_t* aLayersId) MOZ_OVERRIDE; + virtual bool DeallocPRenderFrame(PRenderFrameChild* aFrame) MOZ_OVERRIDE; + virtual bool RecvDestroy() MOZ_OVERRIDE; nsEventStatus DispatchWidgetEvent(nsGUIEvent& event); diff --git a/dom/ipc/TabParent.h b/dom/ipc/TabParent.h index 20425706c4e4..69cede799d43 100644 --- a/dom/ipc/TabParent.h +++ b/dom/ipc/TabParent.h @@ -212,13 +212,11 @@ protected: bool ShouldDelayDialogs(); bool AllowContentIME(); - NS_OVERRIDE virtual PRenderFrameParent* AllocPRenderFrame(ScrollingBehavior* aScrolling, LayersBackend* aBackend, int32_t* aMaxTextureSize, - uint64_t* aLayersId); - NS_OVERRIDE - virtual bool DeallocPRenderFrame(PRenderFrameParent* aFrame); + uint64_t* aLayersId) MOZ_OVERRIDE; + virtual bool DeallocPRenderFrame(PRenderFrameParent* aFrame) MOZ_OVERRIDE; // IME static TabParent *mIMETabParent; diff --git a/dom/plugins/base/PluginPRLibrary.h b/dom/plugins/base/PluginPRLibrary.h index 8114b429c88e..64a8225fd81a 100644 --- a/dom/plugins/base/PluginPRLibrary.h +++ b/dom/plugins/base/PluginPRLibrary.h @@ -112,18 +112,15 @@ public: virtual nsresult AsyncSetWindow(NPP instance, NPWindow* window); virtual nsresult GetImageContainer(NPP instance, ImageContainer** aContainer); virtual nsresult GetImageSize(NPP instance, nsIntSize* aSize); - NS_OVERRIDE virtual bool UseAsyncPainting() { return false; } + virtual bool UseAsyncPainting() MOZ_OVERRIDE { return false; } #if defined(XP_MACOSX) virtual nsresult IsRemoteDrawingCoreAnimation(NPP instance, bool *aDrawing); #endif - NS_OVERRIDE - virtual nsresult SetBackgroundUnknown(NPP instance); - NS_OVERRIDE + virtual nsresult SetBackgroundUnknown(NPP instance) MOZ_OVERRIDE; virtual nsresult BeginUpdateBackground(NPP instance, - const nsIntRect&, gfxContext** aCtx); - NS_OVERRIDE + const nsIntRect&, gfxContext** aCtx) MOZ_OVERRIDE; virtual nsresult EndUpdateBackground(NPP instance, - gfxContext* aCtx, const nsIntRect&); + gfxContext* aCtx, const nsIntRect&) MOZ_OVERRIDE; #if defined(MOZ_WIDGET_QT) && (MOZ_PLATFORM_MAEMO == 6) virtual nsresult HandleGUIEvent(NPP instance, const nsGUIEvent& anEvent, bool* handled); diff --git a/dom/plugins/ipc/BrowserStreamChild.h b/dom/plugins/ipc/BrowserStreamChild.h index 0e5a92805bb0..940fb825aa01 100644 --- a/dom/plugins/ipc/BrowserStreamChild.h +++ b/dom/plugins/ipc/BrowserStreamChild.h @@ -30,7 +30,7 @@ public: uint16_t* stype); virtual ~BrowserStreamChild(); - NS_OVERRIDE virtual bool IsBrowserStream() { return true; } + virtual bool IsBrowserStream() MOZ_OVERRIDE { return true; } NPError StreamConstructed( const nsCString& mimeType, diff --git a/dom/plugins/ipc/BrowserStreamParent.h b/dom/plugins/ipc/BrowserStreamParent.h index d5d9a716cfb6..9723e9a8ad02 100644 --- a/dom/plugins/ipc/BrowserStreamParent.h +++ b/dom/plugins/ipc/BrowserStreamParent.h @@ -24,7 +24,7 @@ public: NPStream* stream); virtual ~BrowserStreamParent(); - NS_OVERRIDE virtual bool IsBrowserStream() { return true; } + virtual bool IsBrowserStream() MOZ_OVERRIDE { return true; } virtual bool AnswerNPN_RequestRead(const IPCByteRanges& ranges, NPError* result); diff --git a/dom/plugins/ipc/ChildAsyncCall.h b/dom/plugins/ipc/ChildAsyncCall.h index 535279dcf85c..e10340a6d23b 100644 --- a/dom/plugins/ipc/ChildAsyncCall.h +++ b/dom/plugins/ipc/ChildAsyncCall.h @@ -24,8 +24,8 @@ public: ChildAsyncCall(PluginInstanceChild* instance, PluginThreadCallback aFunc, void* aUserData); - NS_OVERRIDE void Run(); - NS_OVERRIDE void Cancel(); + void Run() MOZ_OVERRIDE; + void Cancel() MOZ_OVERRIDE; protected: PluginInstanceChild* mInstance; diff --git a/dom/plugins/ipc/PluginBackgroundDestroyer.h b/dom/plugins/ipc/PluginBackgroundDestroyer.h index ab506a92706a..8b0a751c1e6a 100644 --- a/dom/plugins/ipc/PluginBackgroundDestroyer.h +++ b/dom/plugins/ipc/PluginBackgroundDestroyer.h @@ -31,8 +31,7 @@ public: virtual ~PluginBackgroundDestroyerParent() { } private: - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { switch(why) { case Deletion: @@ -64,8 +63,7 @@ public: private: // Implementing this for good hygiene. - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { } }; diff --git a/dom/plugins/ipc/PluginInstanceChild.h b/dom/plugins/ipc/PluginInstanceChild.h index 7fb8fe297237..775ee0227685 100644 --- a/dom/plugins/ipc/PluginInstanceChild.h +++ b/dom/plugins/ipc/PluginInstanceChild.h @@ -112,17 +112,15 @@ protected: return true; } - NS_OVERRIDE virtual bool - AnswerPaint(const NPRemoteEvent& event, int16_t* handled) + AnswerPaint(const NPRemoteEvent& event, int16_t* handled) MOZ_OVERRIDE { PaintTracker pt; return AnswerNPP_HandleEvent(event, handled); } - NS_OVERRIDE virtual bool - RecvWindowPosChanged(const NPRemoteEvent& event); + RecvWindowPosChanged(const NPRemoteEvent& event) MOZ_OVERRIDE; virtual bool AnswerNPP_Destroy(NPError* result); @@ -133,8 +131,8 @@ protected: virtual bool DeallocPPluginScriptableObject(PPluginScriptableObjectChild* aObject); - NS_OVERRIDE virtual bool - RecvPPluginScriptableObjectConstructor(PPluginScriptableObjectChild* aActor); + virtual bool + RecvPPluginScriptableObjectConstructor(PPluginScriptableObjectChild* aActor) MOZ_OVERRIDE; virtual PBrowserStreamChild* AllocPBrowserStream(const nsCString& url, @@ -177,8 +175,8 @@ protected: const bool& file, NPError* result); - NS_OVERRIDE virtual bool - DeallocPStreamNotify(PStreamNotifyChild* notifyData); + virtual bool + DeallocPStreamNotify(PStreamNotifyChild* notifyData) MOZ_OVERRIDE; virtual bool AnswerSetPluginFocus(); @@ -247,21 +245,17 @@ private: NPError DeallocateAsyncBitmapSurface(NPAsyncSurface *aSurface); - NS_OVERRIDE virtual bool RecvUpdateBackground(const SurfaceDescriptor& aBackground, - const nsIntRect& aRect); + const nsIntRect& aRect) MOZ_OVERRIDE; - NS_OVERRIDE virtual PPluginBackgroundDestroyerChild* - AllocPPluginBackgroundDestroyer(); + AllocPPluginBackgroundDestroyer() MOZ_OVERRIDE; - NS_OVERRIDE virtual bool - RecvPPluginBackgroundDestroyerConstructor(PPluginBackgroundDestroyerChild* aActor); + RecvPPluginBackgroundDestroyerConstructor(PPluginBackgroundDestroyerChild* aActor) MOZ_OVERRIDE; - NS_OVERRIDE virtual bool - DeallocPPluginBackgroundDestroyer(PPluginBackgroundDestroyerChild* aActor); + DeallocPPluginBackgroundDestroyer(PPluginBackgroundDestroyerChild* aActor) MOZ_OVERRIDE; #if defined(OS_WIN) static bool RegisterWindowClass(); @@ -334,7 +328,7 @@ private: mWindowed(isWindowed) {} - NS_OVERRIDE void Run(); + void Run() MOZ_OVERRIDE; WNDPROC GetProc(); HWND GetWnd() { return mWnd; } diff --git a/dom/plugins/ipc/PluginInstanceParent.h b/dom/plugins/ipc/PluginInstanceParent.h index af13d02d5595..a2b0848034f6 100644 --- a/dom/plugins/ipc/PluginInstanceParent.h +++ b/dom/plugins/ipc/PluginInstanceParent.h @@ -53,13 +53,13 @@ public: bool Init(); NPError Destroy(); - NS_OVERRIDE virtual void ActorDestroy(ActorDestroyReason why); + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE; virtual PPluginScriptableObjectParent* AllocPPluginScriptableObject(); - NS_OVERRIDE virtual bool - RecvPPluginScriptableObjectConstructor(PPluginScriptableObjectParent* aActor); + virtual bool + RecvPPluginScriptableObjectConstructor(PPluginScriptableObjectParent* aActor) MOZ_OVERRIDE; virtual bool DeallocPPluginScriptableObject(PPluginScriptableObjectParent* aObject); @@ -139,13 +139,13 @@ public: const bool& file, NPError* result); - NS_OVERRIDE virtual bool + virtual bool AnswerPStreamNotifyConstructor(PStreamNotifyParent* actor, const nsCString& url, const nsCString& target, const bool& post, const nsCString& buffer, const bool& file, - NPError* result); + NPError* result) MOZ_OVERRIDE; virtual bool DeallocPStreamNotify(PStreamNotifyParent* notifyData); @@ -173,17 +173,17 @@ public: virtual bool AnswerNPN_PopPopupsEnabledState(); - NS_OVERRIDE virtual bool + virtual bool AnswerNPN_GetValueForURL(const NPNURLVariable& variable, const nsCString& url, - nsCString* value, NPError* result); + nsCString* value, NPError* result) MOZ_OVERRIDE; - NS_OVERRIDE virtual bool + virtual bool AnswerNPN_SetValueForURL(const NPNURLVariable& variable, const nsCString& url, - const nsCString& value, NPError* result); + const nsCString& value, NPError* result) MOZ_OVERRIDE; - NS_OVERRIDE virtual bool + virtual bool AnswerNPN_GetAuthenticationInfo(const nsCString& protocol, const nsCString& host, const int32_t& port, @@ -191,9 +191,9 @@ public: const nsCString& realm, nsCString* username, nsCString* password, - NPError* result); + NPError* result) MOZ_OVERRIDE; - NS_OVERRIDE virtual bool + virtual bool AnswerNPN_ConvertPoint(const double& sourceX, const bool& ignoreDestX, const double& sourceY, @@ -202,7 +202,7 @@ public: const NPCoordinateSpace& destSpace, double *destX, double *destY, - bool *result); + bool *result) MOZ_OVERRIDE; virtual bool AnswerNPN_InitAsyncSurface(const gfxIntSize& size, @@ -213,8 +213,8 @@ public: virtual bool RecvRedrawPlugin(); - NS_OVERRIDE virtual bool - RecvNegotiatedCarbon(); + virtual bool + RecvNegotiatedCarbon() MOZ_OVERRIDE; virtual bool RecvReleaseDXGISharedSurface(const DXGISharedSurfaceHandle &aHandle); @@ -292,13 +292,11 @@ private: typedef mozilla::layers::ImageContainer ImageContainer; ImageContainer *GetImageContainer(); - NS_OVERRIDE virtual PPluginBackgroundDestroyerParent* - AllocPPluginBackgroundDestroyer(); + AllocPPluginBackgroundDestroyer() MOZ_OVERRIDE; - NS_OVERRIDE virtual bool - DeallocPPluginBackgroundDestroyer(PPluginBackgroundDestroyerParent* aActor); + DeallocPPluginBackgroundDestroyer(PPluginBackgroundDestroyerParent* aActor) MOZ_OVERRIDE; bool InternalGetValueForNPObject(NPNVariable aVariable, PPluginScriptableObjectParent** aValue, diff --git a/dom/plugins/ipc/PluginModuleChild.h b/dom/plugins/ipc/PluginModuleChild.h index ac7709bb707b..4587a5d6fcef 100644 --- a/dom/plugins/ipc/PluginModuleChild.h +++ b/dom/plugins/ipc/PluginModuleChild.h @@ -78,15 +78,13 @@ class PluginModuleChild : public PPluginModuleChild { typedef mozilla::dom::PCrashReporterChild PCrashReporterChild; protected: - NS_OVERRIDE virtual mozilla::ipc::RPCChannel::RacyRPCPolicy - MediateRPCRace(const Message& parent, const Message& child) + MediateRPCRace(const Message& parent, const Message& child) MOZ_OVERRIDE { return MediateRace(parent, child); } - NS_OVERRIDE - virtual bool ShouldContinueFromReplyTimeout(); + virtual bool ShouldContinueFromReplyTimeout() MOZ_OVERRIDE; // Implement the PPluginModuleChild interface virtual bool AnswerNP_GetEntryPoints(NPError* rv); @@ -163,8 +161,8 @@ protected: MOZ_NORETURN void QuickExit(); - NS_OVERRIDE virtual bool - RecvProcessNativeEventsInRPCCall(); + virtual bool + RecvProcessNativeEventsInRPCCall() MOZ_OVERRIDE; public: PluginModuleChild(); @@ -310,16 +308,12 @@ private: static gboolean DetectNestedEventLoop(gpointer data); static gboolean ProcessBrowserEvents(gpointer data); - NS_OVERRIDE - virtual void EnteredCxxStack(); - NS_OVERRIDE - virtual void ExitedCxxStack(); + virtual void EnteredCxxStack() MOZ_OVERRIDE; + virtual void ExitedCxxStack() MOZ_OVERRIDE; #elif defined(MOZ_WIDGET_QT) - NS_OVERRIDE - virtual void EnteredCxxStack(); - NS_OVERRIDE - virtual void ExitedCxxStack(); + virtual void EnteredCxxStack() MOZ_OVERRIDE; + virtual void ExitedCxxStack() MOZ_OVERRIDE; #endif PRLibrary* mLibrary; @@ -429,10 +423,8 @@ private: static PLDHashOperator CollectForInstance(NPObjectData* d, void* userArg); #if defined(OS_WIN) - NS_OVERRIDE - virtual void EnteredCall(); - NS_OVERRIDE - virtual void ExitedCall(); + virtual void EnteredCall() MOZ_OVERRIDE; + virtual void ExitedCall() MOZ_OVERRIDE; // Entered/ExitedCall notifications keep track of whether the plugin has // entered a nested event loop within this RPC call. diff --git a/dom/plugins/ipc/PluginModuleParent.h b/dom/plugins/ipc/PluginModuleParent.h index a00a59d70da7..69a5a71facb7 100644 --- a/dom/plugins/ipc/PluginModuleParent.h +++ b/dom/plugins/ipc/PluginModuleParent.h @@ -93,12 +93,12 @@ public: PluginModuleParent(const char* aFilePath); virtual ~PluginModuleParent(); - NS_OVERRIDE virtual void SetPlugin(nsNPAPIPlugin* plugin) + virtual void SetPlugin(nsNPAPIPlugin* plugin) MOZ_OVERRIDE { mPlugin = plugin; } - NS_OVERRIDE virtual void ActorDestroy(ActorDestroyReason why); + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE; /** * LoadModule @@ -131,21 +131,18 @@ public: void ProcessRemoteNativeEventsInRPCCall(); protected: - NS_OVERRIDE virtual mozilla::ipc::RPCChannel::RacyRPCPolicy - MediateRPCRace(const Message& parent, const Message& child) + MediateRPCRace(const Message& parent, const Message& child) MOZ_OVERRIDE { return MediateRace(parent, child); } virtual bool RecvXXX_HACK_FIXME_cjones(Shmem& mem) { NS_RUNTIMEABORT("not reached"); return false; } - NS_OVERRIDE - virtual bool ShouldContinueFromReplyTimeout(); + virtual bool ShouldContinueFromReplyTimeout() MOZ_OVERRIDE; - NS_OVERRIDE virtual bool - RecvBackUpXResources(const FileDescriptor& aXSocketFd); + RecvBackUpXResources(const FileDescriptor& aXSocketFd) MOZ_OVERRIDE; virtual bool AnswerNPN_UserAgent(nsCString* userAgent); @@ -155,47 +152,46 @@ protected: NPError* aError, bool* aBoolVal); - NS_OVERRIDE - virtual bool AnswerProcessSomeEvents(); + virtual bool AnswerProcessSomeEvents() MOZ_OVERRIDE; - NS_OVERRIDE virtual bool - RecvProcessNativeEventsInRPCCall(); + virtual bool + RecvProcessNativeEventsInRPCCall() MOZ_OVERRIDE; - NS_OVERRIDE virtual bool + virtual bool RecvPluginShowWindow(const uint32_t& aWindowId, const bool& aModal, const int32_t& aX, const int32_t& aY, - const size_t& aWidth, const size_t& aHeight); + const size_t& aWidth, const size_t& aHeight) MOZ_OVERRIDE; - NS_OVERRIDE virtual bool - RecvPluginHideWindow(const uint32_t& aWindowId); + virtual bool + RecvPluginHideWindow(const uint32_t& aWindowId) MOZ_OVERRIDE; - NS_OVERRIDE virtual PCrashReporterParent* + virtual PCrashReporterParent* AllocPCrashReporter(mozilla::dom::NativeThreadId* id, - PRUint32* processType); - NS_OVERRIDE virtual bool - DeallocPCrashReporter(PCrashReporterParent* actor); + PRUint32* processType) MOZ_OVERRIDE; + virtual bool + DeallocPCrashReporter(PCrashReporterParent* actor) MOZ_OVERRIDE; - NS_OVERRIDE virtual bool - RecvSetCursor(const NSCursorInfo& aCursorInfo); + virtual bool + RecvSetCursor(const NSCursorInfo& aCursorInfo) MOZ_OVERRIDE; - NS_OVERRIDE virtual bool - RecvShowCursor(const bool& aShow); + virtual bool + RecvShowCursor(const bool& aShow) MOZ_OVERRIDE; - NS_OVERRIDE virtual bool - RecvPushCursor(const NSCursorInfo& aCursorInfo); + virtual bool + RecvPushCursor(const NSCursorInfo& aCursorInfo) MOZ_OVERRIDE; - NS_OVERRIDE virtual bool - RecvPopCursor(); + virtual bool + RecvPopCursor() MOZ_OVERRIDE; - NS_OVERRIDE virtual bool - RecvGetNativeCursorsSupported(bool* supported); + virtual bool + RecvGetNativeCursorsSupported(bool* supported) MOZ_OVERRIDE; - NS_OVERRIDE virtual bool + virtual bool RecvNPN_SetException(PPluginScriptableObjectParent* aActor, - const nsCString& aMessage); + const nsCString& aMessage) MOZ_OVERRIDE; - NS_OVERRIDE virtual bool - RecvNPN_ReloadPlugins(const bool& aReloadPages); + virtual bool + RecvNPN_ReloadPlugins(const bool& aReloadPages) MOZ_OVERRIDE; static PluginInstanceParent* InstCast(NPP instance); static BrowserStreamParent* StreamCast(NPP instance, NPStream* s); @@ -244,17 +240,14 @@ private: virtual nsresult AsyncSetWindow(NPP instance, NPWindow* window); virtual nsresult GetImageContainer(NPP instance, mozilla::layers::ImageContainer** aContainer); virtual nsresult GetImageSize(NPP instance, nsIntSize* aSize); - NS_OVERRIDE virtual bool UseAsyncPainting() { return true; } - NS_OVERRIDE - virtual nsresult SetBackgroundUnknown(NPP instance); - NS_OVERRIDE + virtual bool UseAsyncPainting() MOZ_OVERRIDE { return true; } + virtual nsresult SetBackgroundUnknown(NPP instance) MOZ_OVERRIDE; virtual nsresult BeginUpdateBackground(NPP instance, const nsIntRect& aRect, - gfxContext** aCtx); - NS_OVERRIDE + gfxContext** aCtx) MOZ_OVERRIDE; virtual nsresult EndUpdateBackground(NPP instance, gfxContext* aCtx, - const nsIntRect& aRect); + const nsIntRect& aRect) MOZ_OVERRIDE; #if defined(XP_UNIX) && !defined(XP_MACOSX) && !defined(MOZ_WIDGET_GONK) virtual nsresult NP_Initialize(NPNetscapeFuncs* bFuncs, NPPluginFuncs* pFuncs, NPError* error); @@ -320,7 +313,7 @@ private: #ifdef MOZ_CRASHREPORTER_INJECTOR void InitializeInjector(); - NS_OVERRIDE void OnCrash(DWORD processID); + void OnCrash(DWORD processID) MOZ_OVERRIDE; DWORD mFlashProcess1; DWORD mFlashProcess2; diff --git a/dom/plugins/ipc/PluginProcessChild.h b/dom/plugins/ipc/PluginProcessChild.h index 37e814f79473..66641e16dea5 100644 --- a/dom/plugins/ipc/PluginProcessChild.h +++ b/dom/plugins/ipc/PluginProcessChild.h @@ -25,8 +25,8 @@ public: virtual ~PluginProcessChild() { } - NS_OVERRIDE virtual bool Init(); - NS_OVERRIDE virtual void CleanUp(); + virtual bool Init() MOZ_OVERRIDE; + virtual void CleanUp() MOZ_OVERRIDE; protected: static PluginProcessChild* current() { diff --git a/dom/plugins/ipc/PluginStreamChild.h b/dom/plugins/ipc/PluginStreamChild.h index c22230d7c836..e3cd408a96b6 100644 --- a/dom/plugins/ipc/PluginStreamChild.h +++ b/dom/plugins/ipc/PluginStreamChild.h @@ -22,7 +22,7 @@ public: PluginStreamChild(); virtual ~PluginStreamChild() { } - NS_OVERRIDE virtual bool IsBrowserStream() { return false; } + virtual bool IsBrowserStream() MOZ_OVERRIDE { return false; } virtual bool Answer__delete__(const NPReason& reason, const bool& artificial); diff --git a/dom/plugins/ipc/PluginStreamParent.h b/dom/plugins/ipc/PluginStreamParent.h index 61de78eccce0..1e15360bb17b 100644 --- a/dom/plugins/ipc/PluginStreamParent.h +++ b/dom/plugins/ipc/PluginStreamParent.h @@ -24,7 +24,7 @@ public: const nsCString& target, NPError* result); virtual ~PluginStreamParent() { } - NS_OVERRIDE virtual bool IsBrowserStream() { return false; } + virtual bool IsBrowserStream() MOZ_OVERRIDE { return false; } virtual bool AnswerNPN_Write(const Buffer& data, int32_t* written); diff --git a/dom/plugins/ipc/StreamNotifyChild.h b/dom/plugins/ipc/StreamNotifyChild.h index 4fb6b850557a..f4c80a640647 100644 --- a/dom/plugins/ipc/StreamNotifyChild.h +++ b/dom/plugins/ipc/StreamNotifyChild.h @@ -26,7 +26,7 @@ public: , mBrowserStream(NULL) { } - NS_OVERRIDE virtual void ActorDestroy(ActorDestroyReason why); + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE; void SetValid(void* aClosure) { mClosure = aClosure; @@ -35,7 +35,7 @@ public: void NPP_URLNotify(NPReason reason); private: - NS_OVERRIDE virtual bool Recv__delete__(const NPReason& reason); + virtual bool Recv__delete__(const NPReason& reason) MOZ_OVERRIDE; bool RecvRedirectNotify(const nsCString& url, const int32_t& status); diff --git a/dom/sms/src/ipc/SmsChild.h b/dom/sms/src/ipc/SmsChild.h index 3e0dbb190fb6..6655d3c11425 100644 --- a/dom/sms/src/ipc/SmsChild.h +++ b/dom/sms/src/ipc/SmsChild.h @@ -15,21 +15,21 @@ namespace sms { class SmsChild : public PSmsChild { public: - NS_OVERRIDE virtual bool RecvNotifyReceivedMessage(const SmsMessageData& aMessage); - NS_OVERRIDE virtual bool RecvNotifySentMessage(const SmsMessageData& aMessage); - NS_OVERRIDE virtual bool RecvNotifyDeliveredMessage(const SmsMessageData& aMessage); - NS_OVERRIDE virtual bool RecvNotifyRequestSmsSent(const SmsMessageData& aMessage, const PRInt32& aRequestId, const PRUint64& aProcessId); - NS_OVERRIDE virtual bool RecvNotifyRequestSmsSendFailed(const PRInt32& aError, const PRInt32& aRequestId, const PRUint64& aProcessId); - NS_OVERRIDE virtual bool RecvNotifyRequestGotSms(const SmsMessageData& aMessage, const PRInt32& aRequestId, const PRUint64& aProcessId); - NS_OVERRIDE virtual bool RecvNotifyRequestGetSmsFailed(const PRInt32& aError, const PRInt32& aRequestId, const PRUint64& aProcessId); - NS_OVERRIDE virtual bool RecvNotifyRequestSmsDeleted(const bool& aDeleted, const PRInt32& aRequestId, const PRUint64& aProcessId); - NS_OVERRIDE virtual bool RecvNotifyRequestSmsDeleteFailed(const PRInt32& aError, const PRInt32& aRequestId, const PRUint64& aProcessId); - NS_OVERRIDE virtual bool RecvNotifyRequestNoMessageInList(const PRInt32& aRequestId, const PRUint64& aProcessId); - NS_OVERRIDE virtual bool RecvNotifyRequestCreateMessageList(const PRInt32& aListId, const SmsMessageData& aMessage, const PRInt32& aRequestId, const PRUint64& aProcessId); - NS_OVERRIDE virtual bool RecvNotifyRequestGotNextMessage(const SmsMessageData& aMessage, const PRInt32& aRequestId, const PRUint64& aProcessId); - NS_OVERRIDE virtual bool RecvNotifyRequestReadListFailed(const PRInt32& aError, const PRInt32& aRequestId, const PRUint64& aProcessId); - NS_OVERRIDE virtual bool RecvNotifyRequestMarkedMessageRead(const bool& aRead, const PRInt32& aRequestId, const PRUint64& aProcessId); - NS_OVERRIDE virtual bool RecvNotifyRequestMarkMessageReadFailed(const PRInt32& aError, const PRInt32& aRequestId, const PRUint64& aProcessId); + virtual bool RecvNotifyReceivedMessage(const SmsMessageData& aMessage) MOZ_OVERRIDE; + virtual bool RecvNotifySentMessage(const SmsMessageData& aMessage) MOZ_OVERRIDE; + virtual bool RecvNotifyDeliveredMessage(const SmsMessageData& aMessage) MOZ_OVERRIDE; + virtual bool RecvNotifyRequestSmsSent(const SmsMessageData& aMessage, const PRInt32& aRequestId, const PRUint64& aProcessId) MOZ_OVERRIDE; + virtual bool RecvNotifyRequestSmsSendFailed(const PRInt32& aError, const PRInt32& aRequestId, const PRUint64& aProcessId) MOZ_OVERRIDE; + virtual bool RecvNotifyRequestGotSms(const SmsMessageData& aMessage, const PRInt32& aRequestId, const PRUint64& aProcessId) MOZ_OVERRIDE; + virtual bool RecvNotifyRequestGetSmsFailed(const PRInt32& aError, const PRInt32& aRequestId, const PRUint64& aProcessId) MOZ_OVERRIDE; + virtual bool RecvNotifyRequestSmsDeleted(const bool& aDeleted, const PRInt32& aRequestId, const PRUint64& aProcessId) MOZ_OVERRIDE; + virtual bool RecvNotifyRequestSmsDeleteFailed(const PRInt32& aError, const PRInt32& aRequestId, const PRUint64& aProcessId) MOZ_OVERRIDE; + virtual bool RecvNotifyRequestNoMessageInList(const PRInt32& aRequestId, const PRUint64& aProcessId) MOZ_OVERRIDE; + virtual bool RecvNotifyRequestCreateMessageList(const PRInt32& aListId, const SmsMessageData& aMessage, const PRInt32& aRequestId, const PRUint64& aProcessId) MOZ_OVERRIDE; + virtual bool RecvNotifyRequestGotNextMessage(const SmsMessageData& aMessage, const PRInt32& aRequestId, const PRUint64& aProcessId) MOZ_OVERRIDE; + virtual bool RecvNotifyRequestReadListFailed(const PRInt32& aError, const PRInt32& aRequestId, const PRUint64& aProcessId) MOZ_OVERRIDE; + virtual bool RecvNotifyRequestMarkedMessageRead(const bool& aRead, const PRInt32& aRequestId, const PRUint64& aProcessId) MOZ_OVERRIDE; + virtual bool RecvNotifyRequestMarkMessageReadFailed(const PRInt32& aError, const PRInt32& aRequestId, const PRUint64& aProcessId) MOZ_OVERRIDE; }; } // namespace sms diff --git a/dom/sms/src/ipc/SmsParent.h b/dom/sms/src/ipc/SmsParent.h index ca8277e4a531..db140b86729b 100644 --- a/dom/sms/src/ipc/SmsParent.h +++ b/dom/sms/src/ipc/SmsParent.h @@ -24,17 +24,17 @@ public: SmsParent(); - NS_OVERRIDE virtual bool RecvHasSupport(bool* aHasSupport); - NS_OVERRIDE virtual bool RecvGetNumberOfMessagesForText(const nsString& aText, PRUint16* aResult); - NS_OVERRIDE virtual bool RecvSendMessage(const nsString& aNumber, const nsString& aMessage, const PRInt32& aRequestId, const PRUint64& aProcessId); - NS_OVERRIDE virtual bool RecvSaveReceivedMessage(const nsString& aSender, const nsString& aBody, const PRUint64& aDate, PRInt32* aId); - NS_OVERRIDE virtual bool RecvSaveSentMessage(const nsString& aRecipient, const nsString& aBody, const PRUint64& aDate, PRInt32* aId); - NS_OVERRIDE virtual bool RecvGetMessage(const PRInt32& aMessageId, const PRInt32& aRequestId, const PRUint64& aProcessId); - NS_OVERRIDE virtual bool RecvDeleteMessage(const PRInt32& aMessageId, const PRInt32& aRequestId, const PRUint64& aProcessId); - NS_OVERRIDE virtual bool RecvCreateMessageList(const SmsFilterData& aFilter, const bool& aReverse, const PRInt32& aRequestId, const PRUint64& aProcessId); - NS_OVERRIDE virtual bool RecvGetNextMessageInList(const PRInt32& aListId, const PRInt32& aRequestId, const PRUint64& aProcessId); - NS_OVERRIDE virtual bool RecvClearMessageList(const PRInt32& aListId); - NS_OVERRIDE virtual bool RecvMarkMessageRead(const PRInt32& aMessageId, const bool& aValue, const PRInt32& aRequestId, const PRUint64& aProcessId); + virtual bool RecvHasSupport(bool* aHasSupport) MOZ_OVERRIDE; + virtual bool RecvGetNumberOfMessagesForText(const nsString& aText, PRUint16* aResult) MOZ_OVERRIDE; + virtual bool RecvSendMessage(const nsString& aNumber, const nsString& aMessage, const PRInt32& aRequestId, const PRUint64& aProcessId) MOZ_OVERRIDE; + virtual bool RecvSaveReceivedMessage(const nsString& aSender, const nsString& aBody, const PRUint64& aDate, PRInt32* aId) MOZ_OVERRIDE; + virtual bool RecvSaveSentMessage(const nsString& aRecipient, const nsString& aBody, const PRUint64& aDate, PRInt32* aId) MOZ_OVERRIDE; + virtual bool RecvGetMessage(const PRInt32& aMessageId, const PRInt32& aRequestId, const PRUint64& aProcessId) MOZ_OVERRIDE; + virtual bool RecvDeleteMessage(const PRInt32& aMessageId, const PRInt32& aRequestId, const PRUint64& aProcessId) MOZ_OVERRIDE; + virtual bool RecvCreateMessageList(const SmsFilterData& aFilter, const bool& aReverse, const PRInt32& aRequestId, const PRUint64& aProcessId) MOZ_OVERRIDE; + virtual bool RecvGetNextMessageInList(const PRInt32& aListId, const PRInt32& aRequestId, const PRUint64& aProcessId) MOZ_OVERRIDE; + virtual bool RecvClearMessageList(const PRInt32& aListId) MOZ_OVERRIDE; + virtual bool RecvMarkMessageRead(const PRInt32& aMessageId, const bool& aValue, const PRInt32& aRequestId, const PRUint64& aProcessId) MOZ_OVERRIDE; protected: virtual void ActorDestroy(ActorDestroyReason why); diff --git a/gfx/layers/ipc/ShadowLayerChild.h b/gfx/layers/ipc/ShadowLayerChild.h index 52c1aae2e12a..f38d24fbece9 100644 --- a/gfx/layers/ipc/ShadowLayerChild.h +++ b/gfx/layers/ipc/ShadowLayerChild.h @@ -24,8 +24,7 @@ public: ShadowableLayer* layer() const { return mLayer; } protected: - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why); + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE; private: ShadowableLayer* mLayer; diff --git a/gfx/layers/ipc/ShadowLayerParent.h b/gfx/layers/ipc/ShadowLayerParent.h index f4952ec5846b..e81747488e59 100644 --- a/gfx/layers/ipc/ShadowLayerParent.h +++ b/gfx/layers/ipc/ShadowLayerParent.h @@ -32,8 +32,7 @@ public: ContainerLayer* AsContainer() const; private: - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why); + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE; nsRefPtr mLayer; }; diff --git a/gfx/thebes/gfxImageSurface.h b/gfx/thebes/gfxImageSurface.h index bfe2ad5e1e1e..789031c23508 100644 --- a/gfx/thebes/gfxImageSurface.h +++ b/gfx/thebes/gfxImageSurface.h @@ -89,9 +89,8 @@ public: virtual already_AddRefed GetAsImageSurface(); /** See gfxASurface.h. */ - NS_OVERRIDE virtual void MovePixels(const nsIntRect& aSourceRect, - const nsIntPoint& aDestTopLeft); + const nsIntPoint& aDestTopLeft) MOZ_OVERRIDE; protected: gfxImageSurface(); diff --git a/hal/sandbox/SandboxHal.cpp b/hal/sandbox/SandboxHal.cpp index d832c8a07c72..bc090f2356ac 100644 --- a/hal/sandbox/SandboxHal.cpp +++ b/hal/sandbox/SandboxHal.cpp @@ -289,10 +289,10 @@ class HalParent : public PHalParent , public SwitchObserver { public: - NS_OVERRIDE virtual bool + virtual bool RecvVibrate(const InfallibleTArray& pattern, const InfallibleTArray &id, - PBrowserParent *browserParent) + PBrowserParent *browserParent) MOZ_OVERRIDE { // Check whether browserParent is active. We should have already // checked that the corresponding window is active, but this check @@ -316,9 +316,9 @@ public: return true; } - NS_OVERRIDE virtual bool + virtual bool RecvCancelVibrate(const InfallibleTArray &id, - PBrowserParent *browserParent) + PBrowserParent *browserParent) MOZ_OVERRIDE { TabParent *tabParent = static_cast(browserParent); nsCOMPtr window = @@ -328,42 +328,42 @@ public: return true; } - NS_OVERRIDE virtual bool - RecvEnableBatteryNotifications() { + virtual bool + RecvEnableBatteryNotifications() MOZ_OVERRIDE { hal::RegisterBatteryObserver(this); return true; } - NS_OVERRIDE virtual bool - RecvDisableBatteryNotifications() { + virtual bool + RecvDisableBatteryNotifications() MOZ_OVERRIDE { hal::UnregisterBatteryObserver(this); return true; } - NS_OVERRIDE virtual bool - RecvGetCurrentBatteryInformation(BatteryInformation* aBatteryInfo) { + virtual bool + RecvGetCurrentBatteryInformation(BatteryInformation* aBatteryInfo) MOZ_OVERRIDE { hal::GetCurrentBatteryInformation(aBatteryInfo); return true; } - void Notify(const BatteryInformation& aBatteryInfo) { + void Notify(const BatteryInformation& aBatteryInfo) MOZ_OVERRIDE { unused << SendNotifyBatteryChange(aBatteryInfo); } - NS_OVERRIDE virtual bool - RecvEnableNetworkNotifications() { + virtual bool + RecvEnableNetworkNotifications() MOZ_OVERRIDE { hal::RegisterNetworkObserver(this); return true; } - NS_OVERRIDE virtual bool - RecvDisableNetworkNotifications() { + virtual bool + RecvDisableNetworkNotifications() MOZ_OVERRIDE { hal::UnregisterNetworkObserver(this); return true; } - NS_OVERRIDE virtual bool - RecvGetCurrentNetworkInformation(NetworkInformation* aNetworkInfo) { + virtual bool + RecvGetCurrentNetworkInformation(NetworkInformation* aNetworkInfo) MOZ_OVERRIDE { hal::GetCurrentNetworkInformation(aNetworkInfo); return true; } @@ -372,33 +372,33 @@ public: unused << SendNotifyNetworkChange(aNetworkInfo); } - NS_OVERRIDE virtual bool - RecvEnableScreenConfigurationNotifications() { + virtual bool + RecvEnableScreenConfigurationNotifications() MOZ_OVERRIDE { hal::RegisterScreenConfigurationObserver(this); return true; } - NS_OVERRIDE virtual bool - RecvDisableScreenConfigurationNotifications() { + virtual bool + RecvDisableScreenConfigurationNotifications() MOZ_OVERRIDE { hal::UnregisterScreenConfigurationObserver(this); return true; } - NS_OVERRIDE virtual bool - RecvGetCurrentScreenConfiguration(ScreenConfiguration* aScreenConfiguration) { + virtual bool + RecvGetCurrentScreenConfiguration(ScreenConfiguration* aScreenConfiguration) MOZ_OVERRIDE { hal::GetCurrentScreenConfiguration(aScreenConfiguration); return true; } - NS_OVERRIDE virtual bool - RecvLockScreenOrientation(const dom::ScreenOrientation& aOrientation, bool* aAllowed) + virtual bool + RecvLockScreenOrientation(const dom::ScreenOrientation& aOrientation, bool* aAllowed) MOZ_OVERRIDE { *aAllowed = hal::LockScreenOrientation(aOrientation); return true; } - NS_OVERRIDE virtual bool - RecvUnlockScreenOrientation() + virtual bool + RecvUnlockScreenOrientation() MOZ_OVERRIDE { hal::UnlockScreenOrientation(); return true; @@ -408,98 +408,98 @@ public: unused << SendNotifyScreenConfigurationChange(aScreenConfiguration); } - NS_OVERRIDE virtual bool - RecvGetScreenEnabled(bool *enabled) + virtual bool + RecvGetScreenEnabled(bool *enabled) MOZ_OVERRIDE { *enabled = hal::GetScreenEnabled(); return true; } - NS_OVERRIDE virtual bool - RecvSetScreenEnabled(const bool &enabled) + virtual bool + RecvSetScreenEnabled(const bool &enabled) MOZ_OVERRIDE { hal::SetScreenEnabled(enabled); return true; } - NS_OVERRIDE virtual bool - RecvGetCpuSleepAllowed(bool *allowed) + virtual bool + RecvGetCpuSleepAllowed(bool *allowed) MOZ_OVERRIDE { *allowed = hal::GetCpuSleepAllowed(); return true; } - NS_OVERRIDE virtual bool - RecvSetCpuSleepAllowed(const bool &allowed) + virtual bool + RecvSetCpuSleepAllowed(const bool &allowed) MOZ_OVERRIDE { hal::SetCpuSleepAllowed(allowed); return true; } - NS_OVERRIDE virtual bool - RecvGetScreenBrightness(double *brightness) + virtual bool + RecvGetScreenBrightness(double *brightness) MOZ_OVERRIDE { *brightness = hal::GetScreenBrightness(); return true; } - NS_OVERRIDE virtual bool - RecvSetScreenBrightness(const double &brightness) + virtual bool + RecvSetScreenBrightness(const double &brightness) MOZ_OVERRIDE { hal::SetScreenBrightness(brightness); return true; } - NS_OVERRIDE virtual bool - RecvSetLight(const LightType& aLight, const hal::LightConfiguration& aConfig, bool *status) + virtual bool + RecvSetLight(const LightType& aLight, const hal::LightConfiguration& aConfig, bool *status) MOZ_OVERRIDE { *status = hal::SetLight(aLight, aConfig); return true; } - NS_OVERRIDE virtual bool - RecvGetLight(const LightType& aLight, LightConfiguration* aConfig, bool* status) + virtual bool + RecvGetLight(const LightType& aLight, LightConfiguration* aConfig, bool* status) MOZ_OVERRIDE { *status = hal::GetLight(aLight, aConfig); return true; } - NS_OVERRIDE virtual bool - RecvAdjustSystemClock(const int32_t &aDeltaMilliseconds) + virtual bool + RecvAdjustSystemClock(const int32_t &aDeltaMilliseconds) MOZ_OVERRIDE { hal::AdjustSystemClock(aDeltaMilliseconds); return true; } - NS_OVERRIDE virtual bool - RecvSetTimezone(const nsCString& aTimezoneSpec) + virtual bool + RecvSetTimezone(const nsCString& aTimezoneSpec) MOZ_OVERRIDE { hal::SetTimezone(aTimezoneSpec); return true; } - NS_OVERRIDE virtual bool - RecvReboot() + virtual bool + RecvReboot() MOZ_OVERRIDE { hal::Reboot(); return true; } - NS_OVERRIDE virtual bool - RecvPowerOff() + virtual bool + RecvPowerOff() MOZ_OVERRIDE { hal::PowerOff(); return true; } - NS_OVERRIDE virtual bool - RecvEnableSensorNotifications(const SensorType &aSensor) { + virtual bool + RecvEnableSensorNotifications(const SensorType &aSensor) MOZ_OVERRIDE { hal::RegisterSensorObserver(aSensor, this); return true; } - NS_OVERRIDE virtual bool - RecvDisableSensorNotifications(const SensorType &aSensor) { + virtual bool + RecvDisableSensorNotifications(const SensorType &aSensor) MOZ_OVERRIDE { hal::UnregisterSensorObserver(aSensor, this); return true; } @@ -508,31 +508,31 @@ public: unused << SendNotifySensorChange(aSensorData); } - NS_OVERRIDE virtual bool + virtual bool RecvModifyWakeLock(const nsString &aTopic, const WakeLockControl &aLockAdjust, - const WakeLockControl &aHiddenAdjust) + const WakeLockControl &aHiddenAdjust) MOZ_OVERRIDE { hal::ModifyWakeLock(aTopic, aLockAdjust, aHiddenAdjust); return true; } - NS_OVERRIDE virtual bool - RecvEnableWakeLockNotifications() + virtual bool + RecvEnableWakeLockNotifications() MOZ_OVERRIDE { hal::RegisterWakeLockObserver(this); return true; } - NS_OVERRIDE virtual bool - RecvDisableWakeLockNotifications() + virtual bool + RecvDisableWakeLockNotifications() MOZ_OVERRIDE { hal::UnregisterWakeLockObserver(this); return true; } - NS_OVERRIDE virtual bool - RecvGetWakeLockInfo(const nsString &aTopic, WakeLockInformation *aWakeLockInfo) + virtual bool + RecvGetWakeLockInfo(const nsString &aTopic, WakeLockInformation *aWakeLockInfo) MOZ_OVERRIDE { hal::GetWakeLockInfo(aTopic, aWakeLockInfo); return true; @@ -543,15 +543,15 @@ public: unused << SendNotifyWakeLockChange(aWakeLockInfo); } - NS_OVERRIDE virtual bool - RecvEnableSwitchNotifications(const SwitchDevice& aDevice) + virtual bool + RecvEnableSwitchNotifications(const SwitchDevice& aDevice) MOZ_OVERRIDE { hal::RegisterSwitchObserver(aDevice, this); return true; } - NS_OVERRIDE virtual bool - RecvDisableSwitchNotifications(const SwitchDevice& aDevice) + virtual bool + RecvDisableSwitchNotifications(const SwitchDevice& aDevice) MOZ_OVERRIDE { hal::UnregisterSwitchObserver(aDevice, this); return true; @@ -562,8 +562,8 @@ public: unused << SendNotifySwitchChange(aSwitchEvent); } - NS_OVERRIDE virtual bool - RecvGetCurrentSwitchState(const SwitchDevice& aDevice, hal::SwitchState *aState) + virtual bool + RecvGetCurrentSwitchState(const SwitchDevice& aDevice, hal::SwitchState *aState) MOZ_OVERRIDE { *aState = hal::GetCurrentSwitchState(aDevice); return true; @@ -572,35 +572,35 @@ public: class HalChild : public PHalChild { public: - NS_OVERRIDE virtual bool - RecvNotifyBatteryChange(const BatteryInformation& aBatteryInfo) { + virtual bool + RecvNotifyBatteryChange(const BatteryInformation& aBatteryInfo) MOZ_OVERRIDE { hal::NotifyBatteryChange(aBatteryInfo); return true; } - NS_OVERRIDE virtual bool - RecvNotifySensorChange(const hal::SensorData &aSensorData); + virtual bool + RecvNotifySensorChange(const hal::SensorData &aSensorData) MOZ_OVERRIDE; - NS_OVERRIDE virtual bool - RecvNotifyNetworkChange(const NetworkInformation& aNetworkInfo) { + virtual bool + RecvNotifyNetworkChange(const NetworkInformation& aNetworkInfo) MOZ_OVERRIDE { hal::NotifyNetworkChange(aNetworkInfo); return true; } - NS_OVERRIDE virtual bool - RecvNotifyWakeLockChange(const WakeLockInformation& aWakeLockInfo) { + virtual bool + RecvNotifyWakeLockChange(const WakeLockInformation& aWakeLockInfo) MOZ_OVERRIDE { hal::NotifyWakeLockChange(aWakeLockInfo); return true; } - NS_OVERRIDE virtual bool - RecvNotifyScreenConfigurationChange(const ScreenConfiguration& aScreenConfiguration) { + virtual bool + RecvNotifyScreenConfigurationChange(const ScreenConfiguration& aScreenConfiguration) MOZ_OVERRIDE { hal::NotifyScreenConfigurationChange(aScreenConfiguration); return true; } - NS_OVERRIDE virtual bool - RecvNotifySwitchChange(const mozilla::hal::SwitchEvent& aEvent) { + virtual bool + RecvNotifySwitchChange(const mozilla::hal::SwitchEvent& aEvent) MOZ_OVERRIDE { hal::NotifySwitchChange(aEvent); return true; } diff --git a/ipc/glue/AsyncChannel.h b/ipc/glue/AsyncChannel.h index 8b7e4eba1561..a4b4d7fbf493 100644 --- a/ipc/glue/AsyncChannel.h +++ b/ipc/glue/AsyncChannel.h @@ -168,13 +168,13 @@ public: // These methods acquire the monitor and forward to the // similarly named methods in AsyncChannel below // (OnMessageReceivedFromLink(), etc) - NS_OVERRIDE virtual void OnMessageReceived(const Message& msg); - NS_OVERRIDE virtual void OnChannelConnected(int32 peer_pid); - NS_OVERRIDE virtual void OnChannelError(); + virtual void OnMessageReceived(const Message& msg) MOZ_OVERRIDE; + virtual void OnChannelConnected(int32 peer_pid) MOZ_OVERRIDE; + virtual void OnChannelError() MOZ_OVERRIDE; - NS_OVERRIDE virtual void EchoMessage(Message *msg); - NS_OVERRIDE virtual void SendMessage(Message *msg); - NS_OVERRIDE virtual void SendClose(); + virtual void EchoMessage(Message *msg) MOZ_OVERRIDE; + virtual void SendMessage(Message *msg) MOZ_OVERRIDE; + virtual void SendClose() MOZ_OVERRIDE; }; class ThreadLink : public Link { @@ -185,9 +185,9 @@ public: ThreadLink(AsyncChannel *aChan, AsyncChannel *aTargetChan); virtual ~ThreadLink(); - NS_OVERRIDE virtual void EchoMessage(Message *msg); - NS_OVERRIDE virtual void SendMessage(Message *msg); - NS_OVERRIDE virtual void SendClose(); + virtual void EchoMessage(Message *msg) MOZ_OVERRIDE; + virtual void SendMessage(Message *msg) MOZ_OVERRIDE; + virtual void SendClose() MOZ_OVERRIDE; }; protected: diff --git a/ipc/glue/RPCChannel.h b/ipc/glue/RPCChannel.h index a14d404b2272..919be3f71b41 100644 --- a/ipc/glue/RPCChannel.h +++ b/ipc/glue/RPCChannel.h @@ -86,18 +86,15 @@ public: virtual ~RPCChannel(); - NS_OVERRIDE - void Clear(); + void Clear() MOZ_OVERRIDE; // Make an RPC to the other side of the channel bool Call(Message* msg, Message* reply); // RPCChannel overrides these so that the async and sync messages // can be counted against mStackFrames - NS_OVERRIDE - virtual bool Send(Message* msg); - NS_OVERRIDE - virtual bool Send(Message* msg, Message* reply); + virtual bool Send(Message* msg) MOZ_OVERRIDE; + virtual bool Send(Message* msg, Message* reply) MOZ_OVERRIDE; // Asynchronously, send the child a message that puts it in such a // state that it can't send messages to the parent unless the @@ -127,8 +124,7 @@ public: return !mCxxStackFrames.empty(); } - NS_OVERRIDE - virtual bool OnSpecialMessage(uint16 id, const Message& msg); + virtual bool OnSpecialMessage(uint16 id, const Message& msg) MOZ_OVERRIDE; /** @@ -149,8 +145,8 @@ protected: #endif protected: - NS_OVERRIDE virtual void OnMessageReceivedFromLink(const Message& msg); - NS_OVERRIDE virtual void OnChannelErrorFromLink(); + virtual void OnMessageReceivedFromLink(const Message& msg) MOZ_OVERRIDE; + virtual void OnChannelErrorFromLink() MOZ_OVERRIDE; private: // Called on worker thread only @@ -159,8 +155,7 @@ private: return static_cast(mListener); } - NS_OVERRIDE - virtual bool ShouldDeferNotifyMaybeError() const { + virtual bool ShouldDeferNotifyMaybeError() const MOZ_OVERRIDE { return IsOnCxxStack(); } diff --git a/ipc/glue/SharedMemory.h b/ipc/glue/SharedMemory.h index 587ab5955ba6..26ff18744c8a 100644 --- a/ipc/glue/SharedMemory.h +++ b/ipc/glue/SharedMemory.h @@ -10,6 +10,7 @@ #include "nsDebug.h" #include "nsISupportsImpl.h" // NS_INLINE_DECL_REFCOUNTING +#include "mozilla/Attributes.h" // // This is a low-level wrapper around platform shared memory. Don't diff --git a/ipc/glue/SharedMemoryBasic_android.h b/ipc/glue/SharedMemoryBasic_android.h index 6a93169b0dab..681a2cb53822 100644 --- a/ipc/glue/SharedMemoryBasic_android.h +++ b/ipc/glue/SharedMemoryBasic_android.h @@ -31,20 +31,16 @@ public: virtual ~SharedMemoryBasic(); - NS_OVERRIDE - virtual bool Create(size_t aNbytes); + virtual bool Create(size_t aNbytes) MOZ_OVERRIDE; - NS_OVERRIDE - virtual bool Map(size_t nBytes); + virtual bool Map(size_t nBytes) MOZ_OVERRIDE; - NS_OVERRIDE - virtual void* memory() const + virtual void* memory() const MOZ_OVERRIDE { return mMemory; } - NS_OVERRIDE - virtual SharedMemoryType Type() const + virtual SharedMemoryType Type() const MOZ_OVERRIDE { return TYPE_BASIC; } diff --git a/ipc/glue/SharedMemoryBasic_chromium.h b/ipc/glue/SharedMemoryBasic_chromium.h index 1d51f6311b4d..ac563bac0774 100644 --- a/ipc/glue/SharedMemoryBasic_chromium.h +++ b/ipc/glue/SharedMemoryBasic_chromium.h @@ -35,8 +35,7 @@ public: { } - NS_OVERRIDE - virtual bool Create(size_t aNbytes) + virtual bool Create(size_t aNbytes) MOZ_OVERRIDE { bool ok = mSharedMemory.Create("", false, false, aNbytes); if (ok) { @@ -45,8 +44,7 @@ public: return ok; } - NS_OVERRIDE - virtual bool Map(size_t nBytes) + virtual bool Map(size_t nBytes) MOZ_OVERRIDE { bool ok = mSharedMemory.Map(nBytes); if (ok) { @@ -55,14 +53,12 @@ public: return ok; } - NS_OVERRIDE - virtual void* memory() const + virtual void* memory() const MOZ_OVERRIDE { return mSharedMemory.memory(); } - NS_OVERRIDE - virtual SharedMemoryType Type() const + virtual SharedMemoryType Type() const MOZ_OVERRIDE { return TYPE_BASIC; } diff --git a/ipc/glue/SharedMemorySysV.h b/ipc/glue/SharedMemorySysV.h index 3c78d3aec627..f37998d816fb 100644 --- a/ipc/glue/SharedMemorySysV.h +++ b/ipc/glue/SharedMemorySysV.h @@ -59,8 +59,7 @@ public: mData = nsnull; } - NS_OVERRIDE - virtual bool Create(size_t aNbytes) + virtual bool Create(size_t aNbytes) MOZ_OVERRIDE { int id = shmget(IPC_PRIVATE, aNbytes, IPC_CREAT | 0600); if (id == -1) @@ -73,8 +72,7 @@ public: return Map(aNbytes); } - NS_OVERRIDE - virtual bool Map(size_t nBytes) + virtual bool Map(size_t nBytes) MOZ_OVERRIDE { // already mapped if (mData) @@ -113,14 +111,12 @@ public: return true; } - NS_OVERRIDE - virtual void* memory() const + virtual void* memory() const MOZ_OVERRIDE { return mData; } - NS_OVERRIDE - virtual SharedMemoryType Type() const + virtual SharedMemoryType Type() const MOZ_OVERRIDE { return TYPE_SYSV; } diff --git a/ipc/glue/SyncChannel.h b/ipc/glue/SyncChannel.h index 497ea86472d8..60297a73394f 100644 --- a/ipc/glue/SyncChannel.h +++ b/ipc/glue/SyncChannel.h @@ -41,8 +41,7 @@ public: SyncChannel(SyncListener* aListener); virtual ~SyncChannel(); - NS_OVERRIDE - virtual bool Send(Message* msg) { + virtual bool Send(Message* msg) MOZ_OVERRIDE { return AsyncChannel::Send(msg); } @@ -106,8 +105,8 @@ protected: protected: // Executed on the link thread // Override the AsyncChannel handler so we can dispatch sync messages - NS_OVERRIDE virtual void OnMessageReceivedFromLink(const Message& msg); - NS_OVERRIDE virtual void OnChannelErrorFromLink(); + virtual void OnMessageReceivedFromLink(const Message& msg) MOZ_OVERRIDE; + virtual void OnChannelErrorFromLink() MOZ_OVERRIDE; // Executed on the worker thread bool ProcessingSyncMessage() const { diff --git a/ipc/ipdl/test/cxx/TestBadActor.h b/ipc/ipdl/test/cxx/TestBadActor.h index edad5dcf2e94..acb2114a3900 100644 --- a/ipc/ipdl/test/cxx/TestBadActor.h +++ b/ipc/ipdl/test/cxx/TestBadActor.h @@ -25,8 +25,7 @@ public: void Main(); protected: - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { if (AbnormalShutdown != why) fail("unexpected destruction"); diff --git a/ipc/ipdl/test/cxx/TestBlockChild.h b/ipc/ipdl/test/cxx/TestBlockChild.h index 9ac36103d136..e9534c012384 100644 --- a/ipc/ipdl/test/cxx/TestBlockChild.h +++ b/ipc/ipdl/test/cxx/TestBlockChild.h @@ -26,20 +26,15 @@ public: void Main(); protected: - NS_OVERRIDE - virtual bool AnswerStackFrame(); + virtual bool AnswerStackFrame() MOZ_OVERRIDE; - NS_OVERRIDE - virtual bool RecvP1(); + virtual bool RecvP1() MOZ_OVERRIDE; - NS_OVERRIDE - virtual bool RecvP2(); + virtual bool RecvP2() MOZ_OVERRIDE; - NS_OVERRIDE - virtual bool RecvDone(); + virtual bool RecvDone() MOZ_OVERRIDE; - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { if (NormalShutdown != why) fail("unexpected destruction!"); @@ -65,20 +60,15 @@ public: virtual ~TestBlockChildChild() { } protected: - NS_OVERRIDE - virtual bool RecvPoke1(); + virtual bool RecvPoke1() MOZ_OVERRIDE; - NS_OVERRIDE - virtual bool AnswerStackFrame(); + virtual bool AnswerStackFrame() MOZ_OVERRIDE; - NS_OVERRIDE - virtual bool RecvPoke2(); + virtual bool RecvPoke2() MOZ_OVERRIDE; - NS_OVERRIDE - virtual bool RecvLastPoke(); + virtual bool RecvLastPoke() MOZ_OVERRIDE; - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { if (NormalShutdown != why) fail("unexpected destruction!"); diff --git a/ipc/ipdl/test/cxx/TestBridgeMain.h b/ipc/ipdl/test/cxx/TestBridgeMain.h index 697b5df90a4a..13e0c0f170dd 100644 --- a/ipc/ipdl/test/cxx/TestBridgeMain.h +++ b/ipc/ipdl/test/cxx/TestBridgeMain.h @@ -31,13 +31,11 @@ public: void Main(); protected: - NS_OVERRIDE virtual PTestBridgeMainSubParent* AllocPTestBridgeMainSub(Transport* transport, - ProcessId otherProcess); + ProcessId otherProcess) MOZ_OVERRIDE; - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why); + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE; }; class TestBridgeMainSubParent : @@ -50,15 +48,11 @@ public: virtual ~TestBridgeMainSubParent() {} protected: - NS_OVERRIDE - virtual bool RecvHello(); - NS_OVERRIDE - virtual bool RecvHelloSync(); - NS_OVERRIDE - virtual bool AnswerHelloRpc(); + virtual bool RecvHello() MOZ_OVERRIDE; + virtual bool RecvHelloSync() MOZ_OVERRIDE; + virtual bool AnswerHelloRpc() MOZ_OVERRIDE; - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why); + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE; Transport* mTransport; }; @@ -76,11 +70,9 @@ public: virtual ~TestBridgeMainChild() {} protected: - NS_OVERRIDE - virtual bool RecvStart(); + virtual bool RecvStart() MOZ_OVERRIDE; - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why); + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE; IPDLUnitTestSubprocess* mSubprocess; }; @@ -95,11 +87,9 @@ public: void Main(); protected: - NS_OVERRIDE - virtual bool RecvBridgeEm(); + virtual bool RecvBridgeEm() MOZ_OVERRIDE; - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why); + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE; }; //----------------------------------------------------------------------------- @@ -113,16 +103,13 @@ public: virtual ~TestBridgeSubChild() {} protected: - NS_OVERRIDE - virtual bool RecvPing(); + virtual bool RecvPing() MOZ_OVERRIDE; - NS_OVERRIDE virtual PTestBridgeMainSubChild* AllocPTestBridgeMainSub(Transport* transport, - ProcessId otherProcess); + ProcessId otherProcess) MOZ_OVERRIDE; - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why); + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE; }; class TestBridgeMainSubChild : @@ -136,13 +123,10 @@ public: virtual ~TestBridgeMainSubChild() {} protected: - NS_OVERRIDE - virtual bool RecvHi(); - NS_OVERRIDE - virtual bool AnswerHiRpc(); + virtual bool RecvHi() MOZ_OVERRIDE; + virtual bool AnswerHiRpc() MOZ_OVERRIDE; - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why); + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE; bool mGotHi; Transport* mTransport; diff --git a/ipc/ipdl/test/cxx/TestCrashCleanup.h b/ipc/ipdl/test/cxx/TestCrashCleanup.h index bb1e47027d0a..e4c4409d0cc7 100644 --- a/ipc/ipdl/test/cxx/TestCrashCleanup.h +++ b/ipc/ipdl/test/cxx/TestCrashCleanup.h @@ -23,8 +23,7 @@ public: void Main(); protected: - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { if (AbnormalShutdown != why) fail("unexpected destruction!"); @@ -43,11 +42,9 @@ public: virtual ~TestCrashCleanupChild(); protected: - NS_OVERRIDE - virtual bool AnswerDIEDIEDIE(); + virtual bool AnswerDIEDIEDIE() MOZ_OVERRIDE; - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { fail("should have 'crashed'!"); } diff --git a/ipc/ipdl/test/cxx/TestDataStructures.h b/ipc/ipdl/test/cxx/TestDataStructures.h index 90b6f4ec7f92..6959026810bf 100644 --- a/ipc/ipdl/test/cxx/TestDataStructures.h +++ b/ipc/ipdl/test/cxx/TestDataStructures.h @@ -24,8 +24,7 @@ public: { } virtual ~TestDataStructuresSub() { } - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { if (Deletion != why) fail("unexpected destruction!"); @@ -49,72 +48,61 @@ public: void Main(); protected: - NS_OVERRIDE - virtual PTestDataStructuresSubParent* AllocPTestDataStructuresSub(const int& i) + virtual PTestDataStructuresSubParent* AllocPTestDataStructuresSub(const int& i) MOZ_OVERRIDE { PTestDataStructuresSubParent* actor = new TestDataStructuresSub(i); mKids.AppendElement(actor); return actor; } - NS_OVERRIDE - virtual bool DeallocPTestDataStructuresSub(PTestDataStructuresSubParent* actor); + virtual bool DeallocPTestDataStructuresSub(PTestDataStructuresSubParent* actor) MOZ_OVERRIDE; - NS_OVERRIDE virtual bool RecvTest1( const InfallibleTArray& i1, - InfallibleTArray* o1); + InfallibleTArray* o1) MOZ_OVERRIDE; - NS_OVERRIDE virtual bool RecvTest2( const InfallibleTArray& i1, - InfallibleTArray* o1); + InfallibleTArray* o1) MOZ_OVERRIDE; - NS_OVERRIDE virtual bool RecvTest3( const IntDouble& i1, const IntDouble& i2, IntDouble* o1, - IntDouble* o2); + IntDouble* o2) MOZ_OVERRIDE; - NS_OVERRIDE virtual bool RecvTest4( const InfallibleTArray& i1, - InfallibleTArray* o1); + InfallibleTArray* o1) MOZ_OVERRIDE; - NS_OVERRIDE virtual bool RecvTest5( const IntDoubleArrays& i1, const IntDoubleArrays& i2, const IntDoubleArrays& i3, IntDoubleArrays* o1, IntDoubleArrays* o2, - IntDoubleArrays* o3); + IntDoubleArrays* o3) MOZ_OVERRIDE; - NS_OVERRIDE virtual bool RecvTest6( const InfallibleTArray& i1, - InfallibleTArray* o1); + InfallibleTArray* o1) MOZ_OVERRIDE; + - NS_OVERRIDE virtual bool RecvTest7_0(const ActorWrapper& i1, - ActorWrapper* o1); + ActorWrapper* o1) MOZ_OVERRIDE; - NS_OVERRIDE virtual bool RecvTest7( const Actors& i1, const Actors& i2, const Actors& i3, Actors* o1, Actors* o2, - Actors* o3); + Actors* o3) MOZ_OVERRIDE; - NS_OVERRIDE virtual bool RecvTest8( const InfallibleTArray& i1, - InfallibleTArray* o1); + InfallibleTArray* o1) MOZ_OVERRIDE; - NS_OVERRIDE virtual bool RecvTest9( const Unions& i1, const Unions& i2, @@ -123,34 +111,28 @@ protected: Unions* o1, Unions* o2, Unions* o3, - Unions* o4); + Unions* o4) MOZ_OVERRIDE; - NS_OVERRIDE virtual bool RecvTest10( const InfallibleTArray& i1, - InfallibleTArray* o1); + InfallibleTArray* o1) MOZ_OVERRIDE; - NS_OVERRIDE virtual bool RecvTest11( const SIntDouble& i, - SIntDouble* o); + SIntDouble* o) MOZ_OVERRIDE; - NS_OVERRIDE virtual bool RecvTest12( const SIntDoubleArrays& i, - SIntDoubleArrays* o); + SIntDoubleArrays* o) MOZ_OVERRIDE; - NS_OVERRIDE virtual bool RecvTest13( const SActors& i, - SActors* o); + SActors* o) MOZ_OVERRIDE; - NS_OVERRIDE virtual bool RecvTest14( const Structs& i, - Structs* o); + Structs* o) MOZ_OVERRIDE; - NS_OVERRIDE virtual bool RecvTest15( const WithStructs& i1, const WithStructs& i2, @@ -161,28 +143,23 @@ protected: WithStructs* o2, WithStructs* o3, WithStructs* o4, - WithStructs* o5); + WithStructs* o5) MOZ_OVERRIDE; - NS_OVERRIDE virtual bool RecvTest16( const WithUnions& i, - WithUnions* o); + WithUnions* o) MOZ_OVERRIDE; - NS_OVERRIDE - virtual bool RecvTest17(const InfallibleTArray& sa); + virtual bool RecvTest17(const InfallibleTArray& sa) MOZ_OVERRIDE; - NS_OVERRIDE - virtual bool RecvTest18(const InfallibleTArray& ra); + virtual bool RecvTest18(const InfallibleTArray& ra) MOZ_OVERRIDE; - NS_OVERRIDE - virtual bool RecvDummy(const ShmemUnion& su, ShmemUnion* rsu) + virtual bool RecvDummy(const ShmemUnion& su, ShmemUnion* rsu) MOZ_OVERRIDE { *rsu = su; return true; } - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { if (NormalShutdown != why) fail("unexpected destruction!"); @@ -203,26 +180,22 @@ public: virtual ~TestDataStructuresChild(); protected: - NS_OVERRIDE - virtual PTestDataStructuresSubChild* AllocPTestDataStructuresSub(const int& i) + virtual PTestDataStructuresSubChild* AllocPTestDataStructuresSub(const int& i) MOZ_OVERRIDE { PTestDataStructuresSubChild* actor = new TestDataStructuresSub(i); mKids.AppendElement(actor); return actor; } - NS_OVERRIDE - virtual bool DeallocPTestDataStructuresSub(PTestDataStructuresSubChild* actor) + virtual bool DeallocPTestDataStructuresSub(PTestDataStructuresSubChild* actor) MOZ_OVERRIDE { delete actor; return true; } - NS_OVERRIDE - virtual bool RecvStart(); + virtual bool RecvStart() MOZ_OVERRIDE; - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { if (NormalShutdown != why) fail("unexpected destruction!"); diff --git a/ipc/ipdl/test/cxx/TestDesc.h b/ipc/ipdl/test/cxx/TestDesc.h index 34238037c801..386da1dc63ce 100644 --- a/ipc/ipdl/test/cxx/TestDesc.h +++ b/ipc/ipdl/test/cxx/TestDesc.h @@ -30,17 +30,13 @@ public: void Main(); - NS_OVERRIDE - virtual bool RecvOk(PTestDescSubsubParent* a); + virtual bool RecvOk(PTestDescSubsubParent* a) MOZ_OVERRIDE; protected: - NS_OVERRIDE - virtual PTestDescSubParent* AllocPTestDescSub(PTestDescSubsubParent*); - NS_OVERRIDE - virtual bool DeallocPTestDescSub(PTestDescSubParent* actor); + virtual PTestDescSubParent* AllocPTestDescSub(PTestDescSubsubParent*) MOZ_OVERRIDE; + virtual bool DeallocPTestDescSub(PTestDescSubParent* actor) MOZ_OVERRIDE; - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { if (NormalShutdown != why) fail("unexpected destruction!"); @@ -58,17 +54,13 @@ public: virtual ~TestDescChild() { } protected: - NS_OVERRIDE - virtual PTestDescSubChild* AllocPTestDescSub(PTestDescSubsubChild*); + virtual PTestDescSubChild* AllocPTestDescSub(PTestDescSubsubChild*) MOZ_OVERRIDE; - NS_OVERRIDE - virtual bool DeallocPTestDescSub(PTestDescSubChild* actor); + virtual bool DeallocPTestDescSub(PTestDescSubChild* actor) MOZ_OVERRIDE; - NS_OVERRIDE - virtual bool RecvTest(PTestDescSubsubChild* a); + virtual bool RecvTest(PTestDescSubsubChild* a) MOZ_OVERRIDE; - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { if (NormalShutdown != why) fail("unexpected destruction!"); @@ -88,11 +80,9 @@ public: virtual ~TestDescSubParent() { } protected: - NS_OVERRIDE - virtual PTestDescSubsubParent* AllocPTestDescSubsub(); + virtual PTestDescSubsubParent* AllocPTestDescSubsub() MOZ_OVERRIDE; - NS_OVERRIDE - virtual bool DeallocPTestDescSubsub(PTestDescSubsubParent* actor); + virtual bool DeallocPTestDescSubsub(PTestDescSubsubParent* actor) MOZ_OVERRIDE; }; @@ -104,10 +94,8 @@ public: virtual ~TestDescSubChild() { } protected: - NS_OVERRIDE - virtual PTestDescSubsubChild* AllocPTestDescSubsub(); - NS_OVERRIDE - virtual bool DeallocPTestDescSubsub(PTestDescSubsubChild* actor); + virtual PTestDescSubsubChild* AllocPTestDescSubsub() MOZ_OVERRIDE; + virtual bool DeallocPTestDescSubsub(PTestDescSubsubChild* actor) MOZ_OVERRIDE; }; diff --git a/ipc/ipdl/test/cxx/TestFailedCtor.h b/ipc/ipdl/test/cxx/TestFailedCtor.h index 7fe261764bae..2e3003dbd985 100644 --- a/ipc/ipdl/test/cxx/TestFailedCtor.h +++ b/ipc/ipdl/test/cxx/TestFailedCtor.h @@ -35,13 +35,10 @@ public: void Main(); protected: - NS_OVERRIDE - virtual PTestFailedCtorSubParent* AllocPTestFailedCtorSub(); - NS_OVERRIDE - virtual bool DeallocPTestFailedCtorSub(PTestFailedCtorSubParent* actor); + virtual PTestFailedCtorSubParent* AllocPTestFailedCtorSub() MOZ_OVERRIDE; + virtual bool DeallocPTestFailedCtorSub(PTestFailedCtorSubParent* actor) MOZ_OVERRIDE; - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { if (AbnormalShutdown != why) fail("unexpected destruction!"); @@ -59,20 +56,15 @@ public: virtual ~TestFailedCtorChild() { } protected: - NS_OVERRIDE - virtual PTestFailedCtorSubChild* AllocPTestFailedCtorSub(); + virtual PTestFailedCtorSubChild* AllocPTestFailedCtorSub() MOZ_OVERRIDE; - NS_OVERRIDE - virtual bool AnswerPTestFailedCtorSubConstructor(PTestFailedCtorSubChild* actor); + virtual bool AnswerPTestFailedCtorSubConstructor(PTestFailedCtorSubChild* actor) MOZ_OVERRIDE; - NS_OVERRIDE - virtual bool DeallocPTestFailedCtorSub(PTestFailedCtorSubChild* actor); + virtual bool DeallocPTestFailedCtorSub(PTestFailedCtorSubChild* actor) MOZ_OVERRIDE; - NS_OVERRIDE - virtual void ProcessingError(Result what); + virtual void ProcessingError(Result what) MOZ_OVERRIDE; - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { fail("should have _exit()ed"); } @@ -92,16 +84,12 @@ public: virtual ~TestFailedCtorSubParent(); protected: - NS_OVERRIDE - virtual PTestFailedCtorSubsubParent* AllocPTestFailedCtorSubsub(); + virtual PTestFailedCtorSubsubParent* AllocPTestFailedCtorSubsub() MOZ_OVERRIDE; - NS_OVERRIDE - virtual bool DeallocPTestFailedCtorSubsub(PTestFailedCtorSubsubParent* actor); - NS_OVERRIDE - virtual bool RecvSync() { return true; } + virtual bool DeallocPTestFailedCtorSubsub(PTestFailedCtorSubsubParent* actor) MOZ_OVERRIDE; + virtual bool RecvSync() MOZ_OVERRIDE { return true; } - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why); + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE; TestFailedCtorSubsub* mOne; TestFailedCtorSubsub* mTwo; @@ -117,13 +105,10 @@ public: virtual ~TestFailedCtorSubChild() { } protected: - NS_OVERRIDE - virtual PTestFailedCtorSubsubChild* AllocPTestFailedCtorSubsub(); - NS_OVERRIDE - virtual bool DeallocPTestFailedCtorSubsub(PTestFailedCtorSubsubChild* actor); + virtual PTestFailedCtorSubsubChild* AllocPTestFailedCtorSubsub() MOZ_OVERRIDE; + virtual bool DeallocPTestFailedCtorSubsub(PTestFailedCtorSubsubChild* actor) MOZ_OVERRIDE; - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why); + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE; }; @@ -138,8 +123,7 @@ public: TestFailedCtorSubsub() : mWhy(ActorDestroyReason(-1)), mDealloced(false) {} virtual ~TestFailedCtorSubsub() {} - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) { mWhy = why; } + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { mWhy = why; } ActorDestroyReason mWhy; bool mDealloced; diff --git a/ipc/ipdl/test/cxx/TestHangs.h b/ipc/ipdl/test/cxx/TestHangs.h index c4c814153fdc..52f6da2dd568 100644 --- a/ipc/ipdl/test/cxx/TestHangs.h +++ b/ipc/ipdl/test/cxx/TestHangs.h @@ -26,19 +26,15 @@ public: void Main(); protected: - NS_OVERRIDE - virtual bool ShouldContinueFromReplyTimeout(); + virtual bool ShouldContinueFromReplyTimeout() MOZ_OVERRIDE; - NS_OVERRIDE virtual bool RecvNonce() { return true; } - NS_OVERRIDE - virtual bool AnswerStackFrame(); + virtual bool AnswerStackFrame() MOZ_OVERRIDE; - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { if (AbnormalShutdown != why) fail("unexpected destruction!"); @@ -60,26 +56,22 @@ public: virtual ~TestHangsChild(); protected: - NS_OVERRIDE - virtual bool RecvStart() { + virtual bool RecvStart() MOZ_OVERRIDE { if (!SendNonce()) fail("sending Nonce"); return true; } - NS_OVERRIDE - virtual bool AnswerStackFrame() + virtual bool AnswerStackFrame() MOZ_OVERRIDE { if (CallStackFrame()) fail("should have failed"); return true; } - NS_OVERRIDE - virtual bool AnswerHang(); + virtual bool AnswerHang() MOZ_OVERRIDE; - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { if (AbnormalShutdown != why) fail("unexpected destruction!"); diff --git a/ipc/ipdl/test/cxx/TestJSON.h b/ipc/ipdl/test/cxx/TestJSON.h index 3459d7eb19c8..043d1be3b8d9 100644 --- a/ipc/ipdl/test/cxx/TestJSON.h +++ b/ipc/ipdl/test/cxx/TestJSON.h @@ -33,26 +33,22 @@ public: void Main(); protected: - NS_OVERRIDE virtual bool RecvTest(const JSONVariant& i, - JSONVariant* o); + JSONVariant* o) MOZ_OVERRIDE; - NS_OVERRIDE - virtual PTestHandleParent* AllocPTestHandle() + virtual PTestHandleParent* AllocPTestHandle() MOZ_OVERRIDE { return mKid = new TestHandleParent(); } - NS_OVERRIDE - virtual bool DeallocPTestHandle(PTestHandleParent* actor) + virtual bool DeallocPTestHandle(PTestHandleParent* actor) MOZ_OVERRIDE { delete actor; return true; } - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { if (NormalShutdown != why) fail("unexpected destruction!"); @@ -80,25 +76,21 @@ public: virtual ~TestJSONChild() { } protected: - NS_OVERRIDE virtual bool - RecvStart(); + RecvStart() MOZ_OVERRIDE; - NS_OVERRIDE - virtual PTestHandleChild* AllocPTestHandle() + virtual PTestHandleChild* AllocPTestHandle() MOZ_OVERRIDE { return mKid = new TestHandleChild(); } - NS_OVERRIDE - virtual bool DeallocPTestHandle(PTestHandleChild* actor) + virtual bool DeallocPTestHandle(PTestHandleChild* actor) MOZ_OVERRIDE { delete actor; return true; } - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { if (NormalShutdown != why) fail("unexpected destruction!"); diff --git a/ipc/ipdl/test/cxx/TestLatency.h b/ipc/ipdl/test/cxx/TestLatency.h index 41e973b19ce7..06ff8acc27be 100644 --- a/ipc/ipdl/test/cxx/TestLatency.h +++ b/ipc/ipdl/test/cxx/TestLatency.h @@ -31,13 +31,10 @@ public: void Main(); protected: - NS_OVERRIDE - virtual bool RecvPong(); - NS_OVERRIDE - virtual bool RecvPong5(); + virtual bool RecvPong() MOZ_OVERRIDE; + virtual bool RecvPong5() MOZ_OVERRIDE; - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { if (NormalShutdown != why) fail("unexpected destruction!"); @@ -82,19 +79,13 @@ public: virtual ~TestLatencyChild(); protected: - NS_OVERRIDE - virtual bool RecvPing(); - NS_OVERRIDE - virtual bool RecvPing5(); - NS_OVERRIDE - virtual bool AnswerRpc(); - NS_OVERRIDE - virtual bool RecvSpam(); - NS_OVERRIDE - virtual bool AnswerSynchro(); + virtual bool RecvPing() MOZ_OVERRIDE; + virtual bool RecvPing5() MOZ_OVERRIDE; + virtual bool AnswerRpc() MOZ_OVERRIDE; + virtual bool RecvSpam() MOZ_OVERRIDE; + virtual bool AnswerSynchro() MOZ_OVERRIDE; - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { if (NormalShutdown != why) fail("unexpected destruction!"); diff --git a/ipc/ipdl/test/cxx/TestManyChildAllocs.h b/ipc/ipdl/test/cxx/TestManyChildAllocs.h index a198a202f20f..70ddb87893bb 100644 --- a/ipc/ipdl/test/cxx/TestManyChildAllocs.h +++ b/ipc/ipdl/test/cxx/TestManyChildAllocs.h @@ -27,15 +27,11 @@ public: void Main(); protected: - NS_OVERRIDE - virtual bool RecvDone(); - NS_OVERRIDE - virtual bool DeallocPTestManyChildAllocsSub(PTestManyChildAllocsSubParent* __a); - NS_OVERRIDE - virtual PTestManyChildAllocsSubParent* AllocPTestManyChildAllocsSub(); + virtual bool RecvDone() MOZ_OVERRIDE; + virtual bool DeallocPTestManyChildAllocsSub(PTestManyChildAllocsSubParent* __a) MOZ_OVERRIDE; + virtual PTestManyChildAllocsSubParent* AllocPTestManyChildAllocsSub() MOZ_OVERRIDE; - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { if (NormalShutdown != why) fail("unexpected destruction!"); @@ -53,15 +49,11 @@ public: virtual ~TestManyChildAllocsChild(); protected: - NS_OVERRIDE - virtual bool RecvGo(); - NS_OVERRIDE - virtual bool DeallocPTestManyChildAllocsSub(PTestManyChildAllocsSubChild* __a); - NS_OVERRIDE - virtual PTestManyChildAllocsSubChild* AllocPTestManyChildAllocsSub(); + virtual bool RecvGo() MOZ_OVERRIDE; + virtual bool DeallocPTestManyChildAllocsSub(PTestManyChildAllocsSubChild* __a) MOZ_OVERRIDE; + virtual PTestManyChildAllocsSubChild* AllocPTestManyChildAllocsSub() MOZ_OVERRIDE; - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { if (NormalShutdown != why) fail("unexpected destruction!"); @@ -80,8 +72,7 @@ public: virtual ~TestManyChildAllocsSubParent() { } protected: - NS_OVERRIDE - virtual bool RecvHello() { return true; } + virtual bool RecvHello() MOZ_OVERRIDE { return true; } }; diff --git a/ipc/ipdl/test/cxx/TestMultiMgrs.h b/ipc/ipdl/test/cxx/TestMultiMgrs.h index 75855300dedf..8b282663d10a 100644 --- a/ipc/ipdl/test/cxx/TestMultiMgrs.h +++ b/ipc/ipdl/test/cxx/TestMultiMgrs.h @@ -40,14 +40,12 @@ public: } protected: - NS_OVERRIDE - virtual PTestMultiMgrsBottomParent* AllocPTestMultiMgrsBottom() + virtual PTestMultiMgrsBottomParent* AllocPTestMultiMgrsBottom() MOZ_OVERRIDE { return new TestMultiMgrsBottomParent(); } - NS_OVERRIDE - virtual bool DeallocPTestMultiMgrsBottom(PTestMultiMgrsBottomParent* actor) + virtual bool DeallocPTestMultiMgrsBottom(PTestMultiMgrsBottomParent* actor) MOZ_OVERRIDE { delete actor; return true; @@ -67,14 +65,12 @@ public: } protected: - NS_OVERRIDE - virtual PTestMultiMgrsBottomParent* AllocPTestMultiMgrsBottom() + virtual PTestMultiMgrsBottomParent* AllocPTestMultiMgrsBottom() MOZ_OVERRIDE { return new TestMultiMgrsBottomParent(); } - NS_OVERRIDE - virtual bool DeallocPTestMultiMgrsBottom(PTestMultiMgrsBottomParent* actor) + virtual bool DeallocPTestMultiMgrsBottom(PTestMultiMgrsBottomParent* actor) MOZ_OVERRIDE { delete actor; return true; @@ -94,37 +90,31 @@ public: void Main(); protected: - NS_OVERRIDE - virtual bool RecvOK(); + virtual bool RecvOK() MOZ_OVERRIDE; - NS_OVERRIDE - virtual PTestMultiMgrsLeftParent* AllocPTestMultiMgrsLeft() + virtual PTestMultiMgrsLeftParent* AllocPTestMultiMgrsLeft() MOZ_OVERRIDE { return new TestMultiMgrsLeftParent(); } - NS_OVERRIDE - virtual bool DeallocPTestMultiMgrsLeft(PTestMultiMgrsLeftParent* actor) + virtual bool DeallocPTestMultiMgrsLeft(PTestMultiMgrsLeftParent* actor) MOZ_OVERRIDE { delete actor; return true; } - NS_OVERRIDE - virtual PTestMultiMgrsRightParent* AllocPTestMultiMgrsRight() + virtual PTestMultiMgrsRightParent* AllocPTestMultiMgrsRight() MOZ_OVERRIDE { return new TestMultiMgrsRightParent(); } - NS_OVERRIDE - virtual bool DeallocPTestMultiMgrsRight(PTestMultiMgrsRightParent* actor) + virtual bool DeallocPTestMultiMgrsRight(PTestMultiMgrsRightParent* actor) MOZ_OVERRIDE { delete actor; return true; } - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { if (NormalShutdown != why) fail("unexpected destruction!"); @@ -158,17 +148,14 @@ public: } protected: - NS_OVERRIDE - virtual bool RecvPTestMultiMgrsBottomConstructor(PTestMultiMgrsBottomChild* actor); + virtual bool RecvPTestMultiMgrsBottomConstructor(PTestMultiMgrsBottomChild* actor) MOZ_OVERRIDE; - NS_OVERRIDE - virtual PTestMultiMgrsBottomChild* AllocPTestMultiMgrsBottom() + virtual PTestMultiMgrsBottomChild* AllocPTestMultiMgrsBottom() MOZ_OVERRIDE { return new TestMultiMgrsBottomChild(); } - NS_OVERRIDE - virtual bool DeallocPTestMultiMgrsBottom(PTestMultiMgrsBottomChild* actor) + virtual bool DeallocPTestMultiMgrsBottom(PTestMultiMgrsBottomChild* actor) MOZ_OVERRIDE { delete actor; return true; @@ -188,17 +175,14 @@ public: } protected: - NS_OVERRIDE - virtual bool RecvPTestMultiMgrsBottomConstructor(PTestMultiMgrsBottomChild* actor); + virtual bool RecvPTestMultiMgrsBottomConstructor(PTestMultiMgrsBottomChild* actor) MOZ_OVERRIDE; - NS_OVERRIDE - virtual PTestMultiMgrsBottomChild* AllocPTestMultiMgrsBottom() + virtual PTestMultiMgrsBottomChild* AllocPTestMultiMgrsBottom() MOZ_OVERRIDE { return new TestMultiMgrsBottomChild(); } - NS_OVERRIDE - virtual bool DeallocPTestMultiMgrsBottom(PTestMultiMgrsBottomChild* actor) + virtual bool DeallocPTestMultiMgrsBottom(PTestMultiMgrsBottomChild* actor) MOZ_OVERRIDE { delete actor; return true; @@ -218,37 +202,31 @@ public: PTestMultiMgrsBottomChild* mBottomR; protected: - NS_OVERRIDE - virtual bool RecvCheck(); + virtual bool RecvCheck() MOZ_OVERRIDE; - NS_OVERRIDE - virtual PTestMultiMgrsLeftChild* AllocPTestMultiMgrsLeft() + virtual PTestMultiMgrsLeftChild* AllocPTestMultiMgrsLeft() MOZ_OVERRIDE { return new TestMultiMgrsLeftChild(); } - NS_OVERRIDE - virtual bool DeallocPTestMultiMgrsLeft(PTestMultiMgrsLeftChild* actor) + virtual bool DeallocPTestMultiMgrsLeft(PTestMultiMgrsLeftChild* actor) MOZ_OVERRIDE { delete actor; return true; } - NS_OVERRIDE - virtual PTestMultiMgrsRightChild* AllocPTestMultiMgrsRight() + virtual PTestMultiMgrsRightChild* AllocPTestMultiMgrsRight() MOZ_OVERRIDE { return new TestMultiMgrsRightChild(); } - NS_OVERRIDE - virtual bool DeallocPTestMultiMgrsRight(PTestMultiMgrsRightChild* actor) + virtual bool DeallocPTestMultiMgrsRight(PTestMultiMgrsRightChild* actor) MOZ_OVERRIDE { delete actor; return true; } - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { if (NormalShutdown != why) fail("unexpected destruction!"); diff --git a/ipc/ipdl/test/cxx/TestNestedLoops.h b/ipc/ipdl/test/cxx/TestNestedLoops.h index 84d71db52777..aed240dbf6df 100644 --- a/ipc/ipdl/test/cxx/TestNestedLoops.h +++ b/ipc/ipdl/test/cxx/TestNestedLoops.h @@ -23,13 +23,11 @@ public: void Main(); protected: - NS_OVERRIDE - virtual bool RecvNonce(); + virtual bool RecvNonce() MOZ_OVERRIDE; void BreakNestedLoop(); - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { if (NormalShutdown != why) fail("unexpected destruction!"); @@ -49,14 +47,11 @@ public: virtual ~TestNestedLoopsChild(); protected: - NS_OVERRIDE - virtual bool RecvStart(); + virtual bool RecvStart() MOZ_OVERRIDE; - NS_OVERRIDE - virtual bool AnswerR(); + virtual bool AnswerR() MOZ_OVERRIDE; - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { if (NormalShutdown != why) fail("unexpected destruction!"); diff --git a/ipc/ipdl/test/cxx/TestOpens.h b/ipc/ipdl/test/cxx/TestOpens.h index 2ce250051e86..79ac90b64be6 100644 --- a/ipc/ipdl/test/cxx/TestOpens.h +++ b/ipc/ipdl/test/cxx/TestOpens.h @@ -27,12 +27,10 @@ public: void Main(); protected: - NS_OVERRIDE virtual PTestOpensOpenedParent* - AllocPTestOpensOpened(Transport* transport, ProcessId otherProcess); + AllocPTestOpensOpened(Transport* transport, ProcessId otherProcess) MOZ_OVERRIDE; - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why); + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE; }; } // namespace _ipdltest @@ -48,15 +46,11 @@ public: virtual ~TestOpensOpenedParent() {} protected: - NS_OVERRIDE - virtual bool RecvHello(); - NS_OVERRIDE - virtual bool RecvHelloSync(); - NS_OVERRIDE - virtual bool AnswerHelloRpc(); + virtual bool RecvHello() MOZ_OVERRIDE; + virtual bool RecvHelloSync() MOZ_OVERRIDE; + virtual bool AnswerHelloRpc() MOZ_OVERRIDE; - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why); + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE; Transport* mTransport; }; @@ -74,15 +68,12 @@ public: virtual ~TestOpensChild() {} protected: - NS_OVERRIDE - virtual bool RecvStart(); + virtual bool RecvStart() MOZ_OVERRIDE; - NS_OVERRIDE virtual PTestOpensOpenedChild* - AllocPTestOpensOpened(Transport* transport, ProcessId otherProcess); + AllocPTestOpensOpened(Transport* transport, ProcessId otherProcess) MOZ_OVERRIDE; - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why); + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE; }; } // namespace _ipdltest @@ -99,13 +90,10 @@ public: virtual ~TestOpensOpenedChild() {} protected: - NS_OVERRIDE - virtual bool RecvHi(); - NS_OVERRIDE - virtual bool AnswerHiRpc(); + virtual bool RecvHi() MOZ_OVERRIDE; + virtual bool AnswerHiRpc() MOZ_OVERRIDE; - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why); + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE; bool mGotHi; Transport* mTransport; diff --git a/ipc/ipdl/test/cxx/TestRPCErrorCleanup.h b/ipc/ipdl/test/cxx/TestRPCErrorCleanup.h index 76c4e3d20caa..19d3ffdabf64 100644 --- a/ipc/ipdl/test/cxx/TestRPCErrorCleanup.h +++ b/ipc/ipdl/test/cxx/TestRPCErrorCleanup.h @@ -24,15 +24,13 @@ public: void Main(); protected: - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { if (AbnormalShutdown != why) fail("unexpected destruction!"); } - NS_OVERRIDE - virtual void ProcessingError(Result what); + virtual void ProcessingError(Result what) MOZ_OVERRIDE; bool mGotProcessingError; }; @@ -46,11 +44,9 @@ public: virtual ~TestRPCErrorCleanupChild(); protected: - NS_OVERRIDE - virtual bool AnswerError(); + virtual bool AnswerError() MOZ_OVERRIDE; - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { fail("should have 'crashed'!"); } diff --git a/ipc/ipdl/test/cxx/TestRPCRaces.h b/ipc/ipdl/test/cxx/TestRPCRaces.h index 78664a35bc2b..af53f91dccf0 100644 --- a/ipc/ipdl/test/cxx/TestRPCRaces.h +++ b/ipc/ipdl/test/cxx/TestRPCRaces.h @@ -29,39 +29,31 @@ public: void Main(); protected: - NS_OVERRIDE virtual bool - RecvStartRace(); + RecvStartRace() MOZ_OVERRIDE; - NS_OVERRIDE virtual bool - AnswerRace(bool* hasRace); + AnswerRace(bool* hasRace) MOZ_OVERRIDE; - NS_OVERRIDE virtual bool - AnswerStackFrame(); + AnswerStackFrame() MOZ_OVERRIDE; - NS_OVERRIDE virtual bool - AnswerStackFrame3(); + AnswerStackFrame3() MOZ_OVERRIDE; - NS_OVERRIDE virtual bool - AnswerParent(); + AnswerParent() MOZ_OVERRIDE; - NS_OVERRIDE virtual bool - RecvGetAnsweredParent(bool* answeredParent); + RecvGetAnsweredParent(bool* answeredParent) MOZ_OVERRIDE; - NS_OVERRIDE virtual mozilla::ipc::RPCChannel::RacyRPCPolicy - MediateRPCRace(const Message& parent, const Message& child) + MediateRPCRace(const Message& parent, const Message& child) MOZ_OVERRIDE { return MediateRace(parent, child); } - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { if (NormalShutdown != why) fail("unexpected destruction!"); @@ -91,43 +83,34 @@ public: virtual ~TestRPCRacesChild() { } protected: - NS_OVERRIDE virtual bool - RecvStart(); + RecvStart() MOZ_OVERRIDE; - NS_OVERRIDE virtual bool - AnswerRace(bool* hasRace); + AnswerRace(bool* hasRace) MOZ_OVERRIDE; - NS_OVERRIDE virtual bool - AnswerStackFrame(); + AnswerStackFrame() MOZ_OVERRIDE; - NS_OVERRIDE virtual bool - AnswerStackFrame3(); + AnswerStackFrame3() MOZ_OVERRIDE; - NS_OVERRIDE virtual bool - RecvWakeup(); + RecvWakeup() MOZ_OVERRIDE; - NS_OVERRIDE virtual bool - RecvWakeup3(); + RecvWakeup3() MOZ_OVERRIDE; - NS_OVERRIDE virtual bool - AnswerChild(); + AnswerChild() MOZ_OVERRIDE; - NS_OVERRIDE virtual mozilla::ipc::RPCChannel::RacyRPCPolicy - MediateRPCRace(const Message& parent, const Message& child) + MediateRPCRace(const Message& parent, const Message& child) MOZ_OVERRIDE { return MediateRace(parent, child); } - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { if (NormalShutdown != why) fail("unexpected destruction!"); diff --git a/ipc/ipdl/test/cxx/TestRPCShutdownRace.h b/ipc/ipdl/test/cxx/TestRPCShutdownRace.h index f19322a3f19a..41b2fa9df728 100644 --- a/ipc/ipdl/test/cxx/TestRPCShutdownRace.h +++ b/ipc/ipdl/test/cxx/TestRPCShutdownRace.h @@ -23,17 +23,14 @@ public: void Main(); - NS_OVERRIDE - virtual bool RecvStartDeath(); + virtual bool RecvStartDeath() MOZ_OVERRIDE; - NS_OVERRIDE - virtual bool RecvOrphan(); + virtual bool RecvOrphan() MOZ_OVERRIDE; protected: void StartShuttingDown(); - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { if (AbnormalShutdown != why) fail("unexpected destruction!"); @@ -49,14 +46,11 @@ public: virtual ~TestRPCShutdownRaceChild(); protected: - NS_OVERRIDE - virtual bool RecvStart(); + virtual bool RecvStart() MOZ_OVERRIDE; - NS_OVERRIDE - virtual bool AnswerExit(); + virtual bool AnswerExit() MOZ_OVERRIDE; - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { fail("should have 'crashed'!"); } diff --git a/ipc/ipdl/test/cxx/TestRaceDeferral.h b/ipc/ipdl/test/cxx/TestRaceDeferral.h index e28a98a0f286..d35b48875cfa 100644 --- a/ipc/ipdl/test/cxx/TestRaceDeferral.h +++ b/ipc/ipdl/test/cxx/TestRaceDeferral.h @@ -24,15 +24,12 @@ public: protected: void Test1(); - NS_OVERRIDE - virtual bool AnswerLose(); + virtual bool AnswerLose() MOZ_OVERRIDE; - NS_OVERRIDE virtual mozilla::ipc::RPCChannel::RacyRPCPolicy - MediateRPCRace(const Message& parent, const Message& child); + MediateRPCRace(const Message& parent, const Message& child) MOZ_OVERRIDE; - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { if (NormalShutdown != why) fail("unexpected destruction!"); @@ -52,21 +49,16 @@ public: virtual ~TestRaceDeferralChild(); protected: - NS_OVERRIDE - virtual bool RecvStartRace(); + virtual bool RecvStartRace() MOZ_OVERRIDE; - NS_OVERRIDE - virtual bool AnswerWin(); + virtual bool AnswerWin() MOZ_OVERRIDE; - NS_OVERRIDE - virtual bool AnswerRpc(); + virtual bool AnswerRpc() MOZ_OVERRIDE; - NS_OVERRIDE virtual mozilla::ipc::RPCChannel::RacyRPCPolicy - MediateRPCRace(const Message& parent, const Message& child); + MediateRPCRace(const Message& parent, const Message& child) MOZ_OVERRIDE; - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { if (NormalShutdown != why) fail("unexpected destruction!"); diff --git a/ipc/ipdl/test/cxx/TestRacyRPCReplies.h b/ipc/ipdl/test/cxx/TestRacyRPCReplies.h index b3df5c105c8b..7e386bdc5367 100644 --- a/ipc/ipdl/test/cxx/TestRacyRPCReplies.h +++ b/ipc/ipdl/test/cxx/TestRacyRPCReplies.h @@ -23,14 +23,11 @@ public: void Main(); protected: - NS_OVERRIDE - virtual bool RecvA_(); + virtual bool RecvA_() MOZ_OVERRIDE; - NS_OVERRIDE - virtual bool Answer_R(int* replyNum); + virtual bool Answer_R(int* replyNum) MOZ_OVERRIDE; - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { if (NormalShutdown != why) fail("unexpected destruction!"); @@ -51,17 +48,13 @@ public: virtual ~TestRacyRPCRepliesChild(); protected: - NS_OVERRIDE - virtual bool AnswerR_(int* replyNum); + virtual bool AnswerR_(int* replyNum) MOZ_OVERRIDE; - NS_OVERRIDE - virtual bool RecvChildTest(); + virtual bool RecvChildTest() MOZ_OVERRIDE; - NS_OVERRIDE - virtual bool Recv_A(); + virtual bool Recv_A() MOZ_OVERRIDE; - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { if (NormalShutdown != why) fail("unexpected destruction!"); diff --git a/ipc/ipdl/test/cxx/TestRacyReentry.h b/ipc/ipdl/test/cxx/TestRacyReentry.h index 3ccf0c7b28ae..ee84084cda91 100644 --- a/ipc/ipdl/test/cxx/TestRacyReentry.h +++ b/ipc/ipdl/test/cxx/TestRacyReentry.h @@ -23,11 +23,9 @@ public: void Main(); protected: - NS_OVERRIDE - virtual bool AnswerE(); + virtual bool AnswerE() MOZ_OVERRIDE; - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { if (NormalShutdown != why) fail("unexpected destruction!"); @@ -47,17 +45,13 @@ public: virtual ~TestRacyReentryChild(); protected: - NS_OVERRIDE - virtual bool RecvStart(); + virtual bool RecvStart() MOZ_OVERRIDE; - NS_OVERRIDE - virtual bool RecvN(); + virtual bool RecvN() MOZ_OVERRIDE; - NS_OVERRIDE - virtual bool AnswerH(); + virtual bool AnswerH() MOZ_OVERRIDE; - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { if (NormalShutdown != why) fail("unexpected destruction!"); diff --git a/ipc/ipdl/test/cxx/TestRacyUndefer.h b/ipc/ipdl/test/cxx/TestRacyUndefer.h index 56d9ffeb16ce..e22117406111 100644 --- a/ipc/ipdl/test/cxx/TestRacyUndefer.h +++ b/ipc/ipdl/test/cxx/TestRacyUndefer.h @@ -23,17 +23,13 @@ public: void Main(); protected: - NS_OVERRIDE - virtual bool AnswerSpam(); + virtual bool AnswerSpam() MOZ_OVERRIDE; - NS_OVERRIDE - virtual bool AnswerRaceWinTwice(); + virtual bool AnswerRaceWinTwice() MOZ_OVERRIDE; - NS_OVERRIDE - virtual bool RecvDone(); + virtual bool RecvDone() MOZ_OVERRIDE; - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { if (NormalShutdown != why) fail("unexpected destruction!"); @@ -51,19 +47,14 @@ public: virtual ~TestRacyUndeferChild(); protected: - NS_OVERRIDE - virtual bool RecvStart(); + virtual bool RecvStart() MOZ_OVERRIDE; - NS_OVERRIDE - virtual bool RecvAwakenSpam(); - NS_OVERRIDE - virtual bool RecvAwakenRaceWinTwice(); + virtual bool RecvAwakenSpam() MOZ_OVERRIDE; + virtual bool RecvAwakenRaceWinTwice() MOZ_OVERRIDE; - NS_OVERRIDE - virtual bool AnswerRace(); + virtual bool AnswerRace() MOZ_OVERRIDE; - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { if (NormalShutdown != why) fail("unexpected destruction!"); diff --git a/ipc/ipdl/test/cxx/TestSanity.h b/ipc/ipdl/test/cxx/TestSanity.h index 2245fd041da8..a78547447808 100644 --- a/ipc/ipdl/test/cxx/TestSanity.h +++ b/ipc/ipdl/test/cxx/TestSanity.h @@ -23,12 +23,10 @@ public: void Main(); protected: - NS_OVERRIDE virtual bool RecvPong(const int& one, const float& zeroPtTwoFive, - const PRUint8& dummy); + const PRUint8& dummy) MOZ_OVERRIDE; - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { if (NormalShutdown != why) fail("unexpected destruction!"); @@ -46,12 +44,10 @@ public: virtual ~TestSanityChild(); protected: - NS_OVERRIDE virtual bool RecvPing(const int& zero, const float& zeroPtFive, - const PRInt8& dummy); + const PRInt8& dummy) MOZ_OVERRIDE; - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { if (NormalShutdown != why) fail("unexpected destruction!"); diff --git a/ipc/ipdl/test/cxx/TestSelfManageRoot.h b/ipc/ipdl/test/cxx/TestSelfManageRoot.h index caffa41c41c2..b73f2efad23a 100644 --- a/ipc/ipdl/test/cxx/TestSelfManageRoot.h +++ b/ipc/ipdl/test/cxx/TestSelfManageRoot.h @@ -29,18 +29,15 @@ public: ActorDestroyReason mWhy; protected: - NS_OVERRIDE - virtual PTestSelfManageParent* AllocPTestSelfManage() { + virtual PTestSelfManageParent* AllocPTestSelfManage() MOZ_OVERRIDE { return new TestSelfManageParent(); } - NS_OVERRIDE - virtual bool DeallocPTestSelfManage(PTestSelfManageParent* a) { + virtual bool DeallocPTestSelfManage(PTestSelfManageParent* a) MOZ_OVERRIDE { return true; } - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) { + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { mWhy = why; } }; @@ -62,18 +59,15 @@ public: void Main(); protected: - NS_OVERRIDE - virtual PTestSelfManageParent* AllocPTestSelfManage() { + virtual PTestSelfManageParent* AllocPTestSelfManage() MOZ_OVERRIDE { return new TestSelfManageParent(); } - NS_OVERRIDE - virtual bool DeallocPTestSelfManage(PTestSelfManageParent* a) { + virtual bool DeallocPTestSelfManage(PTestSelfManageParent* a) MOZ_OVERRIDE { return true; } - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { if (NormalShutdown != why) fail("unexpected destruction!"); @@ -97,19 +91,16 @@ public: } protected: - NS_OVERRIDE - virtual PTestSelfManageChild* AllocPTestSelfManage() { + virtual PTestSelfManageChild* AllocPTestSelfManage() MOZ_OVERRIDE { return new TestSelfManageChild(); } - NS_OVERRIDE - virtual bool DeallocPTestSelfManage(PTestSelfManageChild* a) { + virtual bool DeallocPTestSelfManage(PTestSelfManageChild* a) MOZ_OVERRIDE { delete a; return true; } - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) { } + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { } }; class TestSelfManageRootChild : @@ -126,19 +117,16 @@ public: void Main(); protected: - NS_OVERRIDE - virtual PTestSelfManageChild* AllocPTestSelfManage() { + virtual PTestSelfManageChild* AllocPTestSelfManage() MOZ_OVERRIDE { return new TestSelfManageChild(); } - NS_OVERRIDE - virtual bool DeallocPTestSelfManage(PTestSelfManageChild* a) { + virtual bool DeallocPTestSelfManage(PTestSelfManageChild* a) MOZ_OVERRIDE { delete a; return true; } - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { if (NormalShutdown != why) fail("unexpected destruction!"); diff --git a/ipc/ipdl/test/cxx/TestShmem.h b/ipc/ipdl/test/cxx/TestShmem.h index 73fbe0567874..60ce26882017 100644 --- a/ipc/ipdl/test/cxx/TestShmem.h +++ b/ipc/ipdl/test/cxx/TestShmem.h @@ -23,14 +23,12 @@ public: void Main(); protected: - NS_OVERRIDE virtual bool RecvTake( Shmem& mem, Shmem& unsafe, - const size_t& expectedSize); + const size_t& expectedSize) MOZ_OVERRIDE; - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { if (NormalShutdown != why) fail("unexpected destruction!"); @@ -48,14 +46,12 @@ public: virtual ~TestShmemChild() { } protected: - NS_OVERRIDE virtual bool RecvGive( Shmem& mem, Shmem& unsafe, - const size_t& expectedSize); + const size_t& expectedSize) MOZ_OVERRIDE; - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { if (NormalShutdown != why) fail("unexpected destruction!"); diff --git a/ipc/ipdl/test/cxx/TestShutdown.h b/ipc/ipdl/test/cxx/TestShutdown.h index 3b170db38796..a972f06a5542 100644 --- a/ipc/ipdl/test/cxx/TestShutdown.h +++ b/ipc/ipdl/test/cxx/TestShutdown.h @@ -32,9 +32,8 @@ public: } protected: - NS_OVERRIDE virtual void - ActorDestroy(ActorDestroyReason why); + ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE; private: bool mExpectParentDeleted; @@ -58,32 +57,28 @@ public: } protected: - NS_OVERRIDE virtual bool - AnswerStackFrame() + AnswerStackFrame() MOZ_OVERRIDE { return CallStackFrame(); } - NS_OVERRIDE virtual PTestShutdownSubsubParent* - AllocPTestShutdownSubsub(const bool& expectParentDelete) + AllocPTestShutdownSubsub(const bool& expectParentDelete) MOZ_OVERRIDE { return new TestShutdownSubsubParent(expectParentDelete); } - NS_OVERRIDE virtual bool - DeallocPTestShutdownSubsub(PTestShutdownSubsubParent* actor) + DeallocPTestShutdownSubsub(PTestShutdownSubsubParent* actor) MOZ_OVERRIDE { delete actor; ++mDeletedCount; return true; } - NS_OVERRIDE virtual void - ActorDestroy(ActorDestroyReason why); + ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE; private: bool mExpectCrash; @@ -109,26 +104,23 @@ public: void Main(); protected: - NS_OVERRIDE virtual bool RecvSync() { return true; } + virtual bool RecvSync() MOZ_OVERRIDE { return true; } - NS_OVERRIDE virtual PTestShutdownSubParent* - AllocPTestShutdownSub(const bool& expectCrash) + AllocPTestShutdownSub(const bool& expectCrash) MOZ_OVERRIDE { return new TestShutdownSubParent(expectCrash); } - NS_OVERRIDE virtual bool - DeallocPTestShutdownSub(PTestShutdownSubParent* actor) + DeallocPTestShutdownSub(PTestShutdownSubParent* actor) MOZ_OVERRIDE { delete actor; return true; } - NS_OVERRIDE virtual void - ActorDestroy(ActorDestroyReason why); + ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE; }; @@ -148,9 +140,8 @@ public: } protected: - NS_OVERRIDE virtual void - ActorDestroy(ActorDestroyReason why); + ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE; private: bool mExpectParentDeleted; @@ -170,27 +161,23 @@ public: } protected: - NS_OVERRIDE - virtual bool AnswerStackFrame(); + virtual bool AnswerStackFrame() MOZ_OVERRIDE; - NS_OVERRIDE virtual PTestShutdownSubsubChild* - AllocPTestShutdownSubsub(const bool& expectParentDelete) + AllocPTestShutdownSubsub(const bool& expectParentDelete) MOZ_OVERRIDE { return new TestShutdownSubsubChild(expectParentDelete); } - NS_OVERRIDE virtual bool - DeallocPTestShutdownSubsub(PTestShutdownSubsubChild* actor) + DeallocPTestShutdownSubsub(PTestShutdownSubsubChild* actor) MOZ_OVERRIDE { delete actor; return true; } - NS_OVERRIDE virtual void - ActorDestroy(ActorDestroyReason why); + ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE; private: bool mExpectCrash; @@ -209,29 +196,25 @@ public: } protected: - NS_OVERRIDE virtual bool RecvStart(); - NS_OVERRIDE virtual PTestShutdownSubChild* AllocPTestShutdownSub( - const bool& expectCrash) + const bool& expectCrash) MOZ_OVERRIDE { return new TestShutdownSubChild(expectCrash); } - NS_OVERRIDE virtual bool - DeallocPTestShutdownSub(PTestShutdownSubChild* actor) + DeallocPTestShutdownSub(PTestShutdownSubChild* actor) MOZ_OVERRIDE { delete actor; return true; } - NS_OVERRIDE virtual void - ActorDestroy(ActorDestroyReason why); + ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE; }; diff --git a/ipc/ipdl/test/cxx/TestStackHooks.h b/ipc/ipdl/test/cxx/TestStackHooks.h index 991410ec181e..5fb045d5dbdd 100644 --- a/ipc/ipdl/test/cxx/TestStackHooks.h +++ b/ipc/ipdl/test/cxx/TestStackHooks.h @@ -23,32 +23,27 @@ public: void Main(); protected: - NS_OVERRIDE - virtual bool RecvAsync() { + virtual bool RecvAsync() MOZ_OVERRIDE { if (!mOnStack) fail("not on C++ stack?!"); return true; } - NS_OVERRIDE - virtual bool RecvSync() { + virtual bool RecvSync() MOZ_OVERRIDE { if (!mOnStack) fail("not on C++ stack?!"); return true; } - NS_OVERRIDE - virtual bool AnswerRpc() { + virtual bool AnswerRpc() MOZ_OVERRIDE { if (!mOnStack) fail("not on C++ stack?!"); return true; } - NS_OVERRIDE - virtual bool AnswerStackFrame(); + virtual bool AnswerStackFrame() MOZ_OVERRIDE; - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { if (NormalShutdown != why) fail("unexpected destruction!"); @@ -56,21 +51,17 @@ protected: QuitParent(); } - NS_OVERRIDE - virtual void EnteredCxxStack() { + virtual void EnteredCxxStack() MOZ_OVERRIDE { mOnStack = true; } - NS_OVERRIDE - virtual void ExitedCxxStack() { + virtual void ExitedCxxStack() MOZ_OVERRIDE { mOnStack = false; } - NS_OVERRIDE - virtual void EnteredCall() { + virtual void EnteredCall() MOZ_OVERRIDE { ++mIncallDepth; } - NS_OVERRIDE - virtual void ExitedCall() { + virtual void ExitedCall() MOZ_OVERRIDE { --mIncallDepth; } @@ -90,14 +81,11 @@ public: void RunTests(); protected: - NS_OVERRIDE - virtual bool RecvStart(); + virtual bool RecvStart() MOZ_OVERRIDE; - NS_OVERRIDE - virtual bool AnswerStackFrame(); + virtual bool AnswerStackFrame() MOZ_OVERRIDE; - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { if (NormalShutdown != why) fail("unexpected destruction!"); @@ -111,23 +99,19 @@ protected: QuitChild(); } - NS_OVERRIDE - virtual void EnteredCxxStack() { + virtual void EnteredCxxStack() MOZ_OVERRIDE { ++mEntered; mOnStack = true; } - NS_OVERRIDE - virtual void ExitedCxxStack() { + virtual void ExitedCxxStack() MOZ_OVERRIDE { ++mExited; mOnStack = false; } - NS_OVERRIDE - virtual void EnteredCall() { + virtual void EnteredCall() MOZ_OVERRIDE { ++mIncallDepth; } - NS_OVERRIDE - virtual void ExitedCall() { + virtual void ExitedCall() MOZ_OVERRIDE { --mIncallDepth; } diff --git a/ipc/ipdl/test/cxx/TestSyncError.h b/ipc/ipdl/test/cxx/TestSyncError.h index 02a321095580..28983a6a6176 100644 --- a/ipc/ipdl/test/cxx/TestSyncError.h +++ b/ipc/ipdl/test/cxx/TestSyncError.h @@ -23,17 +23,14 @@ public: void Main(); protected: - NS_OVERRIDE - virtual bool RecvError(); + virtual bool RecvError() MOZ_OVERRIDE; - NS_OVERRIDE - virtual void ProcessingError(Result what) + virtual void ProcessingError(Result what) MOZ_OVERRIDE { // Ignore errors } - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { if (NormalShutdown != why) fail("unexpected destruction!"); @@ -51,17 +48,14 @@ public: virtual ~TestSyncErrorChild(); protected: - NS_OVERRIDE - virtual bool RecvStart(); + virtual bool RecvStart() MOZ_OVERRIDE; - NS_OVERRIDE - virtual void ProcessingError(Result what) + virtual void ProcessingError(Result what) MOZ_OVERRIDE { // Ignore errors } - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { if (NormalShutdown != why) fail("unexpected destruction!"); diff --git a/ipc/ipdl/test/cxx/TestSyncHang.h b/ipc/ipdl/test/cxx/TestSyncHang.h index d825786598bd..13a534550ef2 100644 --- a/ipc/ipdl/test/cxx/TestSyncHang.h +++ b/ipc/ipdl/test/cxx/TestSyncHang.h @@ -24,8 +24,7 @@ public: void Main(); protected: - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { if (NormalShutdown != why) fail("unexpected destruction!"); @@ -43,8 +42,7 @@ public: virtual ~TestSyncHangChild(); protected: - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { if (NormalShutdown != why) fail("unexpected destruction!"); diff --git a/ipc/ipdl/test/cxx/TestSyncWakeup.h b/ipc/ipdl/test/cxx/TestSyncWakeup.h index 3f6d4177844b..3f3504b0cd6b 100644 --- a/ipc/ipdl/test/cxx/TestSyncWakeup.h +++ b/ipc/ipdl/test/cxx/TestSyncWakeup.h @@ -23,17 +23,13 @@ public: void Main(); protected: - NS_OVERRIDE - virtual bool AnswerStackFrame(); + virtual bool AnswerStackFrame() MOZ_OVERRIDE; - NS_OVERRIDE - virtual bool RecvSync1(); + virtual bool RecvSync1() MOZ_OVERRIDE; - NS_OVERRIDE - virtual bool RecvSync2(); + virtual bool RecvSync2() MOZ_OVERRIDE; - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { if (NormalShutdown != why) fail("unexpected destruction!"); @@ -51,20 +47,15 @@ public: virtual ~TestSyncWakeupChild(); protected: - NS_OVERRIDE - virtual bool RecvStart(); + virtual bool RecvStart() MOZ_OVERRIDE; - NS_OVERRIDE - virtual bool RecvNote1(); + virtual bool RecvNote1() MOZ_OVERRIDE; - NS_OVERRIDE - virtual bool AnswerStackFrame(); + virtual bool AnswerStackFrame() MOZ_OVERRIDE; - NS_OVERRIDE - virtual bool RecvNote2(); + virtual bool RecvNote2() MOZ_OVERRIDE; - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { if (NormalShutdown != why) fail("unexpected destruction!"); diff --git a/ipc/ipdl/test/cxx/TestSysVShmem.h b/ipc/ipdl/test/cxx/TestSysVShmem.h index e115c2ea1339..f10e314cd7b9 100644 --- a/ipc/ipdl/test/cxx/TestSysVShmem.h +++ b/ipc/ipdl/test/cxx/TestSysVShmem.h @@ -23,14 +23,12 @@ public: void Main(); protected: - NS_OVERRIDE virtual bool RecvTake( Shmem& mem, Shmem& unsafe, - const size_t& expectedSize); + const size_t& expectedSize) MOZ_OVERRIDE; - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { if (NormalShutdown != why) fail("unexpected destruction!"); @@ -48,14 +46,12 @@ public: virtual ~TestSysVShmemChild() { } protected: - NS_OVERRIDE virtual bool RecvGive( Shmem& mem, Shmem& unsafe, - const size_t& expectedSize); + const size_t& expectedSize) MOZ_OVERRIDE; - NS_OVERRIDE - virtual void ActorDestroy(ActorDestroyReason why) + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE { if (NormalShutdown != why) fail("unexpected destruction!"); diff --git a/layout/ipc/RenderFrameChild.h b/layout/ipc/RenderFrameChild.h index 6ba1ed0449b9..c9d6fc599604 100644 --- a/layout/ipc/RenderFrameChild.h +++ b/layout/ipc/RenderFrameChild.h @@ -22,10 +22,8 @@ public: void Destroy(); protected: - NS_OVERRIDE - virtual PLayersChild* AllocPLayers(); - NS_OVERRIDE - virtual bool DeallocPLayers(PLayersChild* aLayers); + virtual PLayersChild* AllocPLayers() MOZ_OVERRIDE; + virtual bool DeallocPLayers(PLayersChild* aLayers) MOZ_OVERRIDE; }; } // namespace layout diff --git a/layout/ipc/RenderFrameParent.h b/layout/ipc/RenderFrameParent.h index ed5a12cae539..385bb10e08f6 100644 --- a/layout/ipc/RenderFrameParent.h +++ b/layout/ipc/RenderFrameParent.h @@ -163,16 +163,14 @@ public: , mRemoteFrame(aRemoteFrame) {} - NS_OVERRIDE virtual LayerState GetLayerState(nsDisplayListBuilder* aBuilder, LayerManager* aManager, - const ContainerParameters& aParameters) + const ContainerParameters& aParameters) MOZ_OVERRIDE { return mozilla::LAYER_ACTIVE_FORCE; } - NS_OVERRIDE virtual already_AddRefed BuildLayer(nsDisplayListBuilder* aBuilder, LayerManager* aManager, - const ContainerParameters& aContainerParameters); + const ContainerParameters& aContainerParameters) MOZ_OVERRIDE; NS_DISPLAY_DECL_NAME("Remote", TYPE_REMOTE) @@ -202,7 +200,7 @@ public: , mId(aId) {} - NS_OVERRIDE nsRect GetBounds(nsDisplayListBuilder* aBuilder, bool* aSnap) + nsRect GetBounds(nsDisplayListBuilder* aBuilder, bool* aSnap) MOZ_OVERRIDE { *aSnap = false; return mRect; @@ -214,8 +212,8 @@ public: return 0; } - NS_OVERRIDE void HitTest(nsDisplayListBuilder* aBuilder, const nsRect& aRect, - HitTestState* aState, nsTArray *aOutFrames); + void HitTest(nsDisplayListBuilder* aBuilder, const nsRect& aRect, + HitTestState* aState, nsTArray *aOutFrames) MOZ_OVERRIDE; NS_DISPLAY_DECL_NAME("Remote-Shadow", TYPE_REMOTE_SHADOW) diff --git a/netwerk/protocol/ftp/FTPChannelChild.h b/netwerk/protocol/ftp/FTPChannelChild.h index 528b1471475c..1a1b65aaefe8 100644 --- a/netwerk/protocol/ftp/FTPChannelChild.h +++ b/netwerk/protocol/ftp/FTPChannelChild.h @@ -61,24 +61,24 @@ public: // default behavior, in order to be e10s-friendly. NS_IMETHOD IsPending(bool* result); - NS_OVERRIDE nsresult OpenContentStream(bool async, - nsIInputStream** stream, - nsIChannel** channel); + nsresult OpenContentStream(bool async, + nsIInputStream** stream, + nsIChannel** channel) MOZ_OVERRIDE; bool IsSuspended(); protected: - NS_OVERRIDE bool RecvOnStartRequest(const PRInt32& aContentLength, - const nsCString& aContentType, - const PRTime& aLastModified, - const nsCString& aEntityID, - const IPC::URI& aURI); - NS_OVERRIDE bool RecvOnDataAvailable(const nsCString& data, - const PRUint32& offset, - const PRUint32& count); - NS_OVERRIDE bool RecvOnStopRequest(const nsresult& statusCode); - NS_OVERRIDE bool RecvFailedAsyncOpen(const nsresult& statusCode); - NS_OVERRIDE bool RecvDeleteSelf(); + bool RecvOnStartRequest(const PRInt32& aContentLength, + const nsCString& aContentType, + const PRTime& aLastModified, + const nsCString& aEntityID, + const IPC::URI& aURI) MOZ_OVERRIDE; + bool RecvOnDataAvailable(const nsCString& data, + const PRUint32& offset, + const PRUint32& count) MOZ_OVERRIDE; + bool RecvOnStopRequest(const nsresult& statusCode) MOZ_OVERRIDE; + bool RecvFailedAsyncOpen(const nsresult& statusCode) MOZ_OVERRIDE; + bool RecvDeleteSelf() MOZ_OVERRIDE; void DoOnStartRequest(const PRInt32& aContentLength, const nsCString& aContentType, diff --git a/netwerk/protocol/ftp/FTPChannelParent.h b/netwerk/protocol/ftp/FTPChannelParent.h index 0381a4bcd41c..ad637d5df8bc 100644 --- a/netwerk/protocol/ftp/FTPChannelParent.h +++ b/netwerk/protocol/ftp/FTPChannelParent.h @@ -36,22 +36,22 @@ public: virtual ~FTPChannelParent(); protected: - NS_OVERRIDE virtual bool RecvAsyncOpen(const IPC::URI& uri, - const PRUint64& startPos, - const nsCString& entityID, - const IPC::InputStream& uploadStream, - const bool& haveLoadContext, - const bool& isContent, - const bool& usingPrivateBrowsing, - const bool& isInBrowserElement, - const PRUint32& appId, - const nsCString& extendedOrigin); - NS_OVERRIDE virtual bool RecvConnectChannel(const PRUint32& channelId); - NS_OVERRIDE virtual bool RecvCancel(const nsresult& status); - NS_OVERRIDE virtual bool RecvSuspend(); - NS_OVERRIDE virtual bool RecvResume(); + virtual bool RecvAsyncOpen(const IPC::URI& uri, + const PRUint64& startPos, + const nsCString& entityID, + const IPC::InputStream& uploadStream, + const bool& haveLoadContext, + const bool& isContent, + const bool& usingPrivateBrowsing, + const bool& isInBrowserElement, + const PRUint32& appId, + const nsCString& extendedOrigin) MOZ_OVERRIDE; + virtual bool RecvConnectChannel(const PRUint32& channelId) MOZ_OVERRIDE; + virtual bool RecvCancel(const nsresult& status) MOZ_OVERRIDE; + virtual bool RecvSuspend() MOZ_OVERRIDE; + virtual bool RecvResume() MOZ_OVERRIDE; - NS_OVERRIDE virtual void ActorDestroy(ActorDestroyReason why); + virtual void ActorDestroy(ActorDestroyReason why) MOZ_OVERRIDE; nsRefPtr mChannel; diff --git a/xpcom/base/nscore.h b/xpcom/base/nscore.h index 3d1e60d70f70..b6cb3754cbcb 100644 --- a/xpcom/base/nscore.h +++ b/xpcom/base/nscore.h @@ -450,13 +450,11 @@ typedef PRUint32 nsrefcnt; # define NS_INPARAM __attribute__((user("NS_inparam"))) # define NS_OUTPARAM __attribute__((user("NS_outparam"))) # define NS_INOUTPARAM __attribute__((user("NS_inoutparam"))) -# define NS_OVERRIDE __attribute__((user("NS_override"))) #else # define NS_SCRIPTABLE # define NS_INPARAM # define NS_OUTPARAM # define NS_INOUTPARAM -# define NS_OVERRIDE #endif /* diff --git a/xpcom/components/nsNativeComponentLoader.h b/xpcom/components/nsNativeComponentLoader.h index 6e7d3fa36c59..a7cf1408f3c6 100644 --- a/xpcom/components/nsNativeComponentLoader.h +++ b/xpcom/components/nsNativeComponentLoader.h @@ -21,7 +21,7 @@ class nsNativeModuleLoader : public mozilla::ModuleLoader nsNativeModuleLoader() {} ~nsNativeModuleLoader() {} - NS_OVERRIDE virtual const mozilla::Module* LoadModule(mozilla::FileLocation &aFile); + virtual const mozilla::Module* LoadModule(mozilla::FileLocation &aFile) MOZ_OVERRIDE; nsresult Init(); diff --git a/xpcom/tests/static-checker/override-global.cpp b/xpcom/tests/static-checker/override-global.cpp deleted file mode 100644 index e79d70c3f101..000000000000 --- a/xpcom/tests/static-checker/override-global.cpp +++ /dev/null @@ -1 +0,0 @@ -__attribute__((user("NS_override"))) int m(); diff --git a/xpcom/tests/static-checker/override-namespace-typedef.cpp b/xpcom/tests/static-checker/override-namespace-typedef.cpp deleted file mode 100644 index 10ca7de90bd4..000000000000 --- a/xpcom/tests/static-checker/override-namespace-typedef.cpp +++ /dev/null @@ -1,16 +0,0 @@ -#include "nscore.h" - -namespace A { -namespace B { -namespace C { - struct Param {}; - - class Base { - virtual void f(const Param& p) {} - }; -}}} - -class Derived : public A::B::C::Base { - typedef A::B::C::Param P; - NS_OVERRIDE void f(const P& p) {} -}; diff --git a/xpcom/tests/static-checker/override-pass.cpp b/xpcom/tests/static-checker/override-pass.cpp deleted file mode 100644 index a31ed1d46bf9..000000000000 --- a/xpcom/tests/static-checker/override-pass.cpp +++ /dev/null @@ -1,21 +0,0 @@ -class A -{ - int a(int, char*); - void c(char); - virtual void d(int) = 0; -}; - -class B : A -{ - __attribute__((user("NS_override"))) int a(int, char*); -}; - -class C : B -{ - __attribute__((user("NS_override"))) void c(char); -}; - -class D : A -{ - __attribute__((user("NS_override"))) void d(int); -}; diff --git a/xpcom/tests/static-checker/override-signature.cpp b/xpcom/tests/static-checker/override-signature.cpp deleted file mode 100644 index ec2c17aa63bc..000000000000 --- a/xpcom/tests/static-checker/override-signature.cpp +++ /dev/null @@ -1,9 +0,0 @@ -class A -{ - int m(int); -}; - -class B : A -{ - __attribute__((user("NS_override"))) int m(void*); -}; diff --git a/xpcom/tests/static-checker/override-static.cpp b/xpcom/tests/static-checker/override-static.cpp deleted file mode 100644 index b56bd7fd3e6f..000000000000 --- a/xpcom/tests/static-checker/override-static.cpp +++ /dev/null @@ -1,9 +0,0 @@ -class A -{ - static int m(); -}; - -class B : A -{ - __attribute__((user("NS_override"))) static int m(); -}; diff --git a/xpcom/tests/static-checker/override-virtual.cpp b/xpcom/tests/static-checker/override-virtual.cpp deleted file mode 100644 index 020bfce47b97..000000000000 --- a/xpcom/tests/static-checker/override-virtual.cpp +++ /dev/null @@ -1,9 +0,0 @@ -class A -{ - int m(); -}; - -class B : A -{ - __attribute__((user("NS_override"))) virtual int m(); -};