mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-02-21 09:49:14 +00:00
Bug 1428535 - Add missing override specifiers to overridden virtual functions. r=froydnj
MozReview-Commit-ID: DCPTnyBooIe --HG-- extra : rebase_source : cfec2d96faeb11656d86d760a34e0a04cacddb13 extra : intermediate-source : 6176724d63788b0fe8caa3f91607c2d93dbaa7ec extra : source : eebbb0600447f9b64aae3bcd47b4be66c02a51ea
This commit is contained in:
parent
757cf798bc
commit
37efe4d0e6
@ -482,7 +482,7 @@ public:
|
||||
|
||||
NS_DECL_ISUPPORTS
|
||||
|
||||
NS_IMETHOD Notify(nsITimer* aTimer) final
|
||||
NS_IMETHOD Notify(nsITimer* aTimer) final override
|
||||
{
|
||||
if (!mContent->IsInUncomposedDoc())
|
||||
return NS_OK;
|
||||
@ -506,7 +506,7 @@ public:
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
NS_IMETHOD GetName(nsACString& aName) final
|
||||
NS_IMETHOD GetName(nsACString& aName) final override
|
||||
{
|
||||
aName.AssignLiteral("PluginTimerCallBack");
|
||||
return NS_OK;
|
||||
|
@ -36,7 +36,7 @@ struct E {
|
||||
virtual void e();
|
||||
};
|
||||
struct F : E {
|
||||
virtual void e() final;
|
||||
virtual void e() final override;
|
||||
};
|
||||
struct G {
|
||||
virtual void e() = 0;
|
||||
|
@ -60,15 +60,15 @@ public:
|
||||
enum DocumentDomainConsideration { DontConsiderDocumentDomain, ConsiderDocumentDomain};
|
||||
bool Subsumes(nsIPrincipal* aOther, DocumentDomainConsideration aConsideration);
|
||||
|
||||
NS_IMETHOD GetOrigin(nsACString& aOrigin) final;
|
||||
NS_IMETHOD GetOriginNoSuffix(nsACString& aOrigin) final;
|
||||
NS_IMETHOD Equals(nsIPrincipal* other, bool* _retval) final;
|
||||
NS_IMETHOD EqualsConsideringDomain(nsIPrincipal* other, bool* _retval) final;
|
||||
NS_IMETHOD Subsumes(nsIPrincipal* other, bool* _retval) final;
|
||||
NS_IMETHOD SubsumesConsideringDomain(nsIPrincipal* other, bool* _retval) final;
|
||||
NS_IMETHOD SubsumesConsideringDomainIgnoringFPD(nsIPrincipal* other, bool* _retval) final;
|
||||
NS_IMETHOD CheckMayLoad(nsIURI* uri, bool report, bool allowIfInheritsPrincipal) final;
|
||||
NS_IMETHOD GetAddonPolicy(nsISupports** aResult) final;
|
||||
NS_IMETHOD GetOrigin(nsACString& aOrigin) final override;
|
||||
NS_IMETHOD GetOriginNoSuffix(nsACString& aOrigin) final override;
|
||||
NS_IMETHOD Equals(nsIPrincipal* other, bool* _retval) final override;
|
||||
NS_IMETHOD EqualsConsideringDomain(nsIPrincipal* other, bool* _retval) final override;
|
||||
NS_IMETHOD Subsumes(nsIPrincipal* other, bool* _retval) final override;
|
||||
NS_IMETHOD SubsumesConsideringDomain(nsIPrincipal* other, bool* _retval) final override;
|
||||
NS_IMETHOD SubsumesConsideringDomainIgnoringFPD(nsIPrincipal* other, bool* _retval) final override;
|
||||
NS_IMETHOD CheckMayLoad(nsIURI* uri, bool report, bool allowIfInheritsPrincipal) final override;
|
||||
NS_IMETHOD GetAddonPolicy(nsISupports** aResult) final override;
|
||||
NS_IMETHOD GetCsp(nsIContentSecurityPolicy** aCsp) override;
|
||||
NS_IMETHOD SetCsp(nsIContentSecurityPolicy* aCsp) override;
|
||||
NS_IMETHOD EnsureCSP(nsIDOMDocument* aDocument, nsIContentSecurityPolicy** aCSP) override;
|
||||
@ -79,12 +79,12 @@ public:
|
||||
NS_IMETHOD GetIsCodebasePrincipal(bool* aResult) override;
|
||||
NS_IMETHOD GetIsExpandedPrincipal(bool* aResult) override;
|
||||
NS_IMETHOD GetIsSystemPrincipal(bool* aResult) override;
|
||||
NS_IMETHOD GetOriginAttributes(JSContext* aCx, JS::MutableHandle<JS::Value> aVal) final;
|
||||
NS_IMETHOD GetOriginSuffix(nsACString& aOriginSuffix) final;
|
||||
NS_IMETHOD GetAppId(uint32_t* aAppId) final;
|
||||
NS_IMETHOD GetIsInIsolatedMozBrowserElement(bool* aIsInIsolatedMozBrowserElement) final;
|
||||
NS_IMETHOD GetUserContextId(uint32_t* aUserContextId) final;
|
||||
NS_IMETHOD GetPrivateBrowsingId(uint32_t* aPrivateBrowsingId) final;
|
||||
NS_IMETHOD GetOriginAttributes(JSContext* aCx, JS::MutableHandle<JS::Value> aVal) final override;
|
||||
NS_IMETHOD GetOriginSuffix(nsACString& aOriginSuffix) final override;
|
||||
NS_IMETHOD GetAppId(uint32_t* aAppId) final override;
|
||||
NS_IMETHOD GetIsInIsolatedMozBrowserElement(bool* aIsInIsolatedMozBrowserElement) final override;
|
||||
NS_IMETHOD GetUserContextId(uint32_t* aUserContextId) final override;
|
||||
NS_IMETHOD GetPrivateBrowsingId(uint32_t* aPrivateBrowsingId) final override;
|
||||
|
||||
virtual bool AddonHasPermission(const nsAtom* aPerm);
|
||||
|
||||
@ -102,7 +102,7 @@ public:
|
||||
static already_AddRefed<BasePrincipal>
|
||||
CreateCodebasePrincipal(nsIURI* aURI, const OriginAttributes& aAttrs);
|
||||
|
||||
const OriginAttributes& OriginAttributesRef() final { return mOriginAttributes; }
|
||||
const OriginAttributes& OriginAttributesRef() final override { return mOriginAttributes; }
|
||||
uint32_t AppId() const { return mOriginAttributes.mAppId; }
|
||||
extensions::WebExtensionPolicy* AddonPolicy();
|
||||
uint32_t UserContextId() const { return mOriginAttributes.mUserContextId; }
|
||||
|
@ -25,7 +25,7 @@ public:
|
||||
uint32_t aTag,
|
||||
JSPrincipals** aOutPrincipals);
|
||||
|
||||
bool write(JSContext* aCx, JSStructuredCloneWriter* aWriter) final;
|
||||
bool write(JSContext* aCx, JSStructuredCloneWriter* aWriter) final override;
|
||||
|
||||
/*
|
||||
* Get a weak reference to nsIPrincipal associated with the given JS
|
||||
|
@ -252,13 +252,13 @@ public:
|
||||
new (storage) Concrete(ptr);
|
||||
}
|
||||
|
||||
CoarseType coarseType() const final { return get().coarseType; }
|
||||
CoarseType coarseType() const final override { return get().coarseType; }
|
||||
Id identifier() const override { return get().id; }
|
||||
bool isLive() const override { return false; }
|
||||
const char16_t* typeName() const override;
|
||||
Node::Size size(mozilla::MallocSizeOf mallocSizeof) const override;
|
||||
const char* jsObjectClassName() const override { return get().jsObjectClassName; }
|
||||
const char* scriptFilename() const final { return get().scriptFilename; }
|
||||
const char* scriptFilename() const final override { return get().scriptFilename; }
|
||||
|
||||
bool hasAllocationStack() const override { return get().allocationStack.isSome(); }
|
||||
StackFrame allocationStack() const override;
|
||||
|
@ -1255,7 +1255,7 @@ public:
|
||||
|
||||
~StreamWriter() override { }
|
||||
|
||||
virtual bool writeMetadata(uint64_t timestamp) final {
|
||||
virtual bool writeMetadata(uint64_t timestamp) final override {
|
||||
protobuf::Metadata metadata;
|
||||
metadata.set_timestamp(timestamp);
|
||||
return writeMessage(metadata);
|
||||
|
@ -88,7 +88,7 @@ public:
|
||||
|
||||
protected:
|
||||
virtual nsresult BuildArrayRecursive(nsIDocShellTreeItem* aItem,
|
||||
nsTArray<nsWeakPtr>& aItemArray);
|
||||
nsTArray<nsWeakPtr>& aItemArray) override;
|
||||
};
|
||||
|
||||
class nsDocShellBackwardsEnumerator : public nsDocShellEnumerator
|
||||
@ -101,7 +101,7 @@ public:
|
||||
|
||||
protected:
|
||||
virtual nsresult BuildArrayRecursive(nsIDocShellTreeItem* aItem,
|
||||
nsTArray<nsWeakPtr>& aItemArray);
|
||||
nsTArray<nsWeakPtr>& aItemArray) override;
|
||||
};
|
||||
|
||||
#endif // nsDocShellEnumerator_h___
|
||||
|
@ -48,7 +48,7 @@ public:
|
||||
}
|
||||
|
||||
protected:
|
||||
virtual void NotifyExpired(nsSHEntryShared* aObj)
|
||||
virtual void NotifyExpired(nsSHEntryShared* aObj) override
|
||||
{
|
||||
RemoveObject(aObj);
|
||||
mSHistory->EvictExpiredContentViewerForEntry(aObj);
|
||||
|
@ -243,8 +243,8 @@ public:
|
||||
nsExtendedDOMSlots();
|
||||
~nsExtendedDOMSlots() final;
|
||||
|
||||
void Traverse(nsCycleCollectionTraversalCallback&) final;
|
||||
void Unlink() final;
|
||||
void Traverse(nsCycleCollectionTraversalCallback&) final override;
|
||||
void Unlink() final override;
|
||||
|
||||
/**
|
||||
* SMIL Overridde style rules (for SMIL animation of CSS properties)
|
||||
@ -295,8 +295,8 @@ public:
|
||||
nsDOMSlots();
|
||||
~nsDOMSlots() final;
|
||||
|
||||
void Traverse(nsCycleCollectionTraversalCallback&) final;
|
||||
void Unlink() final;
|
||||
void Traverse(nsCycleCollectionTraversalCallback&) final override;
|
||||
void Unlink() final override;
|
||||
|
||||
size_t SizeOfIncludingThis(mozilla::MallocSizeOf aMallocSizeOf) const;
|
||||
|
||||
@ -340,7 +340,7 @@ protected:
|
||||
return new nsDOMSlots();
|
||||
}
|
||||
|
||||
nsIContent::nsExtendedContentSlots* CreateExtendedSlots() final
|
||||
nsIContent::nsExtendedContentSlots* CreateExtendedSlots() final override
|
||||
{
|
||||
return new nsExtendedDOMSlots();
|
||||
}
|
||||
|
@ -185,4 +185,3 @@ protected:
|
||||
} // namespace mozilla
|
||||
|
||||
#endif // mozilla_dom_shadowroot_h__
|
||||
|
||||
|
@ -143,10 +143,10 @@ class ContentPermissionRequestParent : public PContentPermissionRequestParent
|
||||
nsTArray<PermissionRequest> mRequests;
|
||||
|
||||
private:
|
||||
virtual mozilla::ipc::IPCResult Recvprompt();
|
||||
virtual mozilla::ipc::IPCResult RecvNotifyVisibility(const bool& aIsVisible);
|
||||
virtual mozilla::ipc::IPCResult RecvDestroy();
|
||||
virtual void ActorDestroy(ActorDestroyReason why);
|
||||
virtual mozilla::ipc::IPCResult Recvprompt() override;
|
||||
virtual mozilla::ipc::IPCResult RecvNotifyVisibility(const bool& aIsVisible) override;
|
||||
virtual mozilla::ipc::IPCResult RecvDestroy() override;
|
||||
virtual void ActorDestroy(ActorDestroyReason why) override;
|
||||
};
|
||||
|
||||
ContentPermissionRequestParent::ContentPermissionRequestParent(const nsTArray<PermissionRequest>& aRequests,
|
||||
|
@ -11980,7 +11980,7 @@ public:
|
||||
, mUserInputOrChromeCaller(aUserInputOrChromeCaller)
|
||||
{}
|
||||
|
||||
NS_IMETHOD Run() final;
|
||||
NS_IMETHOD Run() final override;
|
||||
|
||||
private:
|
||||
nsWeakPtr mElement;
|
||||
|
@ -423,7 +423,7 @@ public:
|
||||
already_AddRefed<nsIPresShell> CreateShell(nsPresContext* aContext,
|
||||
nsViewManager* aViewManager,
|
||||
mozilla::StyleSetHandle aStyleSet)
|
||||
final;
|
||||
final override;
|
||||
virtual void DeleteShell() override;
|
||||
|
||||
virtual bool GetAllowPlugins() override;
|
||||
|
@ -1254,14 +1254,14 @@ public:
|
||||
nsHTMLCopyEncoder();
|
||||
virtual ~nsHTMLCopyEncoder();
|
||||
|
||||
NS_IMETHOD Init(nsIDOMDocument* aDocument, const nsAString& aMimeType, uint32_t aFlags);
|
||||
NS_IMETHOD Init(nsIDOMDocument* aDocument, const nsAString& aMimeType, uint32_t aFlags) override;
|
||||
|
||||
// overridden methods from nsDocumentEncoder
|
||||
NS_IMETHOD SetSelection(nsISelection* aSelection);
|
||||
NS_IMETHOD SetSelection(nsISelection* aSelection) override;
|
||||
NS_IMETHOD EncodeToStringWithContext(nsAString& aContextString,
|
||||
nsAString& aInfoString,
|
||||
nsAString& aEncodedString);
|
||||
NS_IMETHOD EncodeToString(nsAString& aOutputString);
|
||||
nsAString& aEncodedString) override;
|
||||
NS_IMETHOD EncodeToString(nsAString& aOutputString) override;
|
||||
|
||||
protected:
|
||||
|
||||
@ -1284,9 +1284,9 @@ protected:
|
||||
bool IsFirstNode(nsIDOMNode *aNode);
|
||||
bool IsLastNode(nsIDOMNode *aNode);
|
||||
bool IsEmptyTextContent(nsIDOMNode* aNode);
|
||||
virtual bool IncludeInContext(nsINode *aNode);
|
||||
virtual bool IncludeInContext(nsINode *aNode) override;
|
||||
virtual int32_t
|
||||
GetImmediateContextCount(const nsTArray<nsINode*>& aAncestorArray);
|
||||
GetImmediateContextCount(const nsTArray<nsINode*>& aAncestorArray) override;
|
||||
|
||||
bool mIsTextWidget;
|
||||
};
|
||||
|
@ -312,7 +312,7 @@ private:
|
||||
|
||||
class MyAsyncMessage : public nsSameProcessAsyncMessageBase, public Runnable
|
||||
{
|
||||
NS_IMETHOD Run() override {
|
||||
NS_IMETHOD Run() {
|
||||
ReceiveMessage(..., ...);
|
||||
return NS_OK;
|
||||
}
|
||||
|
@ -145,7 +145,7 @@ public:
|
||||
virtual nsresult AppendText(const char16_t* aBuffer, uint32_t aLength,
|
||||
bool aNotify) override;
|
||||
virtual bool TextIsOnlyWhitespace() override;
|
||||
virtual bool ThreadSafeTextIsOnlyWhitespace() const final;
|
||||
virtual bool ThreadSafeTextIsOnlyWhitespace() const final override;
|
||||
virtual bool HasTextForTranslation() override;
|
||||
virtual void AppendTextTo(nsAString& aResult) override;
|
||||
MOZ_MUST_USE
|
||||
|
@ -137,7 +137,7 @@ class nsSelectMoveScrollCommand : public nsSelectionCommandsBase
|
||||
{
|
||||
public:
|
||||
|
||||
NS_IMETHOD DoCommand(const char * aCommandName, nsISupports *aCommandContext);
|
||||
NS_IMETHOD DoCommand(const char * aCommandName, nsISupports *aCommandContext) override;
|
||||
|
||||
// no member variables, please, we're stateless!
|
||||
};
|
||||
@ -147,7 +147,7 @@ class nsPhysicalSelectMoveScrollCommand : public nsSelectionCommandsBase
|
||||
{
|
||||
public:
|
||||
|
||||
NS_IMETHOD DoCommand(const char * aCommandName, nsISupports *aCommandContext);
|
||||
NS_IMETHOD DoCommand(const char * aCommandName, nsISupports *aCommandContext) override;
|
||||
|
||||
// no member variables, please, we're stateless!
|
||||
};
|
||||
@ -157,7 +157,7 @@ class nsSelectCommand : public nsSelectionCommandsBase
|
||||
{
|
||||
public:
|
||||
|
||||
NS_IMETHOD DoCommand(const char * aCommandName, nsISupports *aCommandContext);
|
||||
NS_IMETHOD DoCommand(const char * aCommandName, nsISupports *aCommandContext) override;
|
||||
|
||||
// no member variables, please, we're stateless!
|
||||
};
|
||||
@ -167,7 +167,7 @@ class nsPhysicalSelectCommand : public nsSelectionCommandsBase
|
||||
{
|
||||
public:
|
||||
|
||||
NS_IMETHOD DoCommand(const char * aCommandName, nsISupports *aCommandContext);
|
||||
NS_IMETHOD DoCommand(const char * aCommandName, nsISupports *aCommandContext) override;
|
||||
|
||||
// no member variables, please, we're stateless!
|
||||
};
|
||||
@ -697,9 +697,11 @@ class _cmd : public nsSelectionCommand
|
||||
protected: \
|
||||
\
|
||||
virtual nsresult IsClipboardCommandEnabled(const char* aCommandName, \
|
||||
nsIContentViewerEdit* aEdit, bool *outCmdEnabled); \
|
||||
nsIContentViewerEdit* aEdit, \
|
||||
bool *outCmdEnabled) override; \
|
||||
virtual nsresult DoClipboardCommand(const char* aCommandName, \
|
||||
nsIContentViewerEdit* aEdit, nsICommandParams* aParams); \
|
||||
nsIContentViewerEdit* aEdit, \
|
||||
nsICommandParams* aParams) override; \
|
||||
/* no member variables, please, we're stateless! */ \
|
||||
};
|
||||
|
||||
|
@ -67,30 +67,30 @@ public:
|
||||
}
|
||||
|
||||
NS_IMETHOD_(void) DescribeRefCountedNode(nsrefcnt aRefCount,
|
||||
const char* aObjName)
|
||||
const char* aObjName) override
|
||||
{
|
||||
}
|
||||
NS_IMETHOD_(void) DescribeGCedNode(bool aIsMarked,
|
||||
const char* aObjName,
|
||||
uint64_t aCompartmentAddress)
|
||||
uint64_t aCompartmentAddress) override
|
||||
{
|
||||
}
|
||||
|
||||
NS_IMETHOD_(void) NoteJSChild(const JS::GCCellPtr& aChild)
|
||||
NS_IMETHOD_(void) NoteJSChild(const JS::GCCellPtr& aChild) override
|
||||
{
|
||||
if (aChild == mWrapper) {
|
||||
mFound = true;
|
||||
}
|
||||
}
|
||||
NS_IMETHOD_(void) NoteXPCOMChild(nsISupports* aChild)
|
||||
NS_IMETHOD_(void) NoteXPCOMChild(nsISupports* aChild) override
|
||||
{
|
||||
}
|
||||
NS_IMETHOD_(void) NoteNativeChild(void* aChild,
|
||||
nsCycleCollectionParticipant* aHelper)
|
||||
nsCycleCollectionParticipant* aHelper) override
|
||||
{
|
||||
}
|
||||
|
||||
NS_IMETHOD_(void) NoteNextEdgeName(const char* aName)
|
||||
NS_IMETHOD_(void) NoteNextEdgeName(const char* aName) override
|
||||
{
|
||||
}
|
||||
|
||||
|
@ -177,7 +177,7 @@ protected:
|
||||
|
||||
// Since we're templated on a binding, we need to possibly CC it, but can't do
|
||||
// that through macros. So it happens here.
|
||||
virtual void UnlinkHelper() final
|
||||
virtual void UnlinkHelper() final override
|
||||
{
|
||||
mIterableObj = nullptr;
|
||||
}
|
||||
|
@ -166,7 +166,7 @@ public:
|
||||
ImageCache();
|
||||
~ImageCache();
|
||||
|
||||
virtual void NotifyExpired(ImageCacheEntryData* aObject)
|
||||
virtual void NotifyExpired(ImageCacheEntryData* aObject) override
|
||||
{
|
||||
mTotal -= aObject->SizeInBytes();
|
||||
RemoveObject(aObject);
|
||||
|
@ -4277,7 +4277,7 @@ struct MOZ_STACK_CLASS CanvasBidiProcessor : public nsBidiPresUtils::BidiProcess
|
||||
|
||||
typedef CanvasRenderingContext2D::ContextState ContextState;
|
||||
|
||||
virtual void SetText(const char16_t* aText, int32_t aLength, nsBidiDirection aDirection)
|
||||
virtual void SetText(const char16_t* aText, int32_t aLength, nsBidiDirection aDirection) override
|
||||
{
|
||||
mFontgrp->UpdateUserFonts(); // ensure user font generation is current
|
||||
// adjust flags for current direction run
|
||||
@ -4296,7 +4296,7 @@ struct MOZ_STACK_CLASS CanvasBidiProcessor : public nsBidiPresUtils::BidiProcess
|
||||
mMissingFonts);
|
||||
}
|
||||
|
||||
virtual nscoord GetWidth()
|
||||
virtual nscoord GetWidth() override
|
||||
{
|
||||
gfxTextRun::Metrics textRunMetrics = mTextRun->MeasureText(
|
||||
mDoMeasureBoundingBox ? gfxFont::TIGHT_INK_EXTENTS
|
||||
@ -4369,7 +4369,7 @@ struct MOZ_STACK_CLASS CanvasBidiProcessor : public nsBidiPresUtils::BidiProcess
|
||||
return pattern.forget();
|
||||
}
|
||||
|
||||
virtual void DrawText(nscoord aXOffset, nscoord aWidth)
|
||||
virtual void DrawText(nscoord aXOffset, nscoord aWidth) override
|
||||
{
|
||||
gfx::Point point = mPt;
|
||||
bool rtl = mTextRun->IsRightToLeft();
|
||||
|
@ -37,7 +37,7 @@ CanvasRenderingContextHelper::ToBlob(JSContext* aCx,
|
||||
, mBlobCallback(aCallback) {}
|
||||
|
||||
// This is called on main thread.
|
||||
nsresult ReceiveBlob(already_AddRefed<Blob> aBlob)
|
||||
nsresult ReceiveBlob(already_AddRefed<Blob> aBlob) override
|
||||
{
|
||||
RefPtr<Blob> blob = aBlob;
|
||||
|
||||
|
@ -258,7 +258,7 @@ OffscreenCanvas::ToBlob(JSContext* aCx,
|
||||
, mPromise(aPromise) {}
|
||||
|
||||
// This is called on main thread.
|
||||
nsresult ReceiveBlob(already_AddRefed<Blob> aBlob)
|
||||
nsresult ReceiveBlob(already_AddRefed<Blob> aBlob) override
|
||||
{
|
||||
RefPtr<Blob> blob = aBlob;
|
||||
|
||||
|
@ -43,7 +43,7 @@ public:
|
||||
}
|
||||
|
||||
NS_IMETHOD
|
||||
Run()
|
||||
Run() override
|
||||
{
|
||||
MOZ_ASSERT(NS_IsMainThread());
|
||||
mContentParent->KillHard("invalid ClientSourceParent actor");
|
||||
|
@ -240,19 +240,19 @@ NS_DEFINE_STATIC_IID_ACCESSOR(DOMEventTargetHelper,
|
||||
* want to override it.
|
||||
*/
|
||||
#define NS_FORWARD_NSIDOMEVENTTARGET_NOGETEVENTTARGETPARENT(_to) \
|
||||
NS_IMETHOD AddEventListener(const nsAString & type, nsIDOMEventListener *listener, bool useCapture, bool wantsUntrusted, uint8_t _argc) { \
|
||||
NS_IMETHOD AddEventListener(const nsAString & type, nsIDOMEventListener *listener, bool useCapture, bool wantsUntrusted, uint8_t _argc) override { \
|
||||
return _to AddEventListener(type, listener, useCapture, wantsUntrusted, _argc); \
|
||||
} \
|
||||
NS_IMETHOD AddSystemEventListener(const nsAString & type, nsIDOMEventListener *listener, bool aUseCapture, bool aWantsUntrusted, uint8_t _argc) { \
|
||||
NS_IMETHOD AddSystemEventListener(const nsAString & type, nsIDOMEventListener *listener, bool aUseCapture, bool aWantsUntrusted, uint8_t _argc) override { \
|
||||
return _to AddSystemEventListener(type, listener, aUseCapture, aWantsUntrusted, _argc); \
|
||||
} \
|
||||
NS_IMETHOD RemoveEventListener(const nsAString & type, nsIDOMEventListener *listener, bool useCapture) { \
|
||||
NS_IMETHOD RemoveEventListener(const nsAString & type, nsIDOMEventListener *listener, bool useCapture) override { \
|
||||
return _to RemoveEventListener(type, listener, useCapture); \
|
||||
} \
|
||||
NS_IMETHOD RemoveSystemEventListener(const nsAString & type, nsIDOMEventListener *listener, bool aUseCapture) { \
|
||||
NS_IMETHOD RemoveSystemEventListener(const nsAString & type, nsIDOMEventListener *listener, bool aUseCapture) override { \
|
||||
return _to RemoveSystemEventListener(type, listener, aUseCapture); \
|
||||
} \
|
||||
NS_IMETHOD DispatchEvent(nsIDOMEvent *evt, bool *_retval) { \
|
||||
NS_IMETHOD DispatchEvent(nsIDOMEvent *evt, bool *_retval) override { \
|
||||
return _to DispatchEvent(evt, _retval); \
|
||||
} \
|
||||
virtual mozilla::dom::EventTarget* GetTargetForDOMEvent() { \
|
||||
|
@ -255,7 +255,7 @@ public:
|
||||
}
|
||||
~nsMediaEvent() {}
|
||||
|
||||
NS_IMETHOD Run() = 0;
|
||||
NS_IMETHOD Run() override = 0;
|
||||
|
||||
protected:
|
||||
bool IsCancelled() {
|
||||
@ -5279,7 +5279,7 @@ public:
|
||||
explicit MediaStreamTracksAvailableCallback(HTMLMediaElement* aElement):
|
||||
OnTracksAvailableCallback(), mElement(aElement)
|
||||
{}
|
||||
virtual void NotifyTracksAvailable(DOMMediaStream* aStream)
|
||||
virtual void NotifyTracksAvailable(DOMMediaStream* aStream) override
|
||||
{
|
||||
NS_ASSERTION(NS_IsMainThread(), "Should be on main thread.");
|
||||
|
||||
|
@ -63,7 +63,7 @@ public:
|
||||
explicit GetCheckedVisitor(HTMLMenuItemElement** aResult)
|
||||
: mResult(aResult)
|
||||
{ }
|
||||
virtual bool Visit(HTMLMenuItemElement* aMenuItem)
|
||||
virtual bool Visit(HTMLMenuItemElement* aMenuItem) override
|
||||
{
|
||||
if (aMenuItem->IsChecked()) {
|
||||
*mResult = aMenuItem;
|
||||
@ -82,7 +82,7 @@ public:
|
||||
explicit ClearCheckedVisitor(HTMLMenuItemElement* aExcludeMenuItem)
|
||||
: mExcludeMenuItem(aExcludeMenuItem)
|
||||
{ }
|
||||
virtual bool Visit(HTMLMenuItemElement* aMenuItem)
|
||||
virtual bool Visit(HTMLMenuItemElement* aMenuItem) override
|
||||
{
|
||||
if (aMenuItem != mExcludeMenuItem && aMenuItem->IsChecked()) {
|
||||
aMenuItem->ClearChecked();
|
||||
@ -103,7 +103,7 @@ public:
|
||||
: mCheckedDirty(aCheckedDirty),
|
||||
mExcludeMenuItem(aExcludeMenuItem)
|
||||
{ }
|
||||
virtual bool Visit(HTMLMenuItemElement* aMenuItem)
|
||||
virtual bool Visit(HTMLMenuItemElement* aMenuItem) override
|
||||
{
|
||||
if (aMenuItem == mExcludeMenuItem) {
|
||||
return true;
|
||||
@ -122,7 +122,7 @@ class SetCheckedDirtyVisitor : public Visitor
|
||||
public:
|
||||
SetCheckedDirtyVisitor()
|
||||
{ }
|
||||
virtual bool Visit(HTMLMenuItemElement* aMenuItem)
|
||||
virtual bool Visit(HTMLMenuItemElement* aMenuItem) override
|
||||
{
|
||||
aMenuItem->SetCheckedDirty();
|
||||
return true;
|
||||
@ -138,7 +138,7 @@ public:
|
||||
: mVisitor1(aVisitor1), mVisitor2(aVisitor2),
|
||||
mContinue1(true), mContinue2(true)
|
||||
{ }
|
||||
virtual bool Visit(HTMLMenuItemElement* aMenuItem)
|
||||
virtual bool Visit(HTMLMenuItemElement* aMenuItem) override
|
||||
{
|
||||
if (mContinue1) {
|
||||
mContinue1 = mVisitor1->Visit(aMenuItem);
|
||||
|
@ -498,7 +498,7 @@ public:
|
||||
, mCue(aCue)
|
||||
{}
|
||||
|
||||
NS_IMETHOD Run() {
|
||||
NS_IMETHOD Run() override {
|
||||
WEBVTT_LOGV("SimpleTextTrackEvent cue %p mName %s mTime %lf",
|
||||
mCue.get(), NS_ConvertUTF16toUTF8(mName).get(), mTime);
|
||||
mCue->DispatchTrustedEvent(mName);
|
||||
|
@ -25,10 +25,10 @@ public:
|
||||
nsISupports* aContainer,
|
||||
nsIStreamListener** aDocListener,
|
||||
bool aReset = true,
|
||||
nsIContentSink* aSink = nullptr);
|
||||
virtual void SetScriptGlobalObject(nsIScriptGlobalObject* aScriptGlobalObject);
|
||||
nsIContentSink* aSink = nullptr) override;
|
||||
virtual void SetScriptGlobalObject(nsIScriptGlobalObject* aScriptGlobalObject) override;
|
||||
|
||||
virtual void Destroy()
|
||||
virtual void Destroy() override
|
||||
{
|
||||
if (mStreamListener) {
|
||||
mStreamListener->DropDocumentRef();
|
||||
|
@ -7553,7 +7553,7 @@ protected:
|
||||
|
||||
// Common nsIRunnable implementation that subclasses may not override.
|
||||
NS_IMETHOD
|
||||
Run() final;
|
||||
Run() final override;
|
||||
|
||||
// OpenDirectoryListener overrides.
|
||||
void
|
||||
@ -7896,7 +7896,7 @@ protected:
|
||||
|
||||
// Common nsIRunnable implementation that subclasses may not override.
|
||||
NS_IMETHOD
|
||||
Run() final;
|
||||
Run() final override;
|
||||
|
||||
// IPDL methods.
|
||||
void
|
||||
|
@ -474,7 +474,7 @@ class PendingInputEventHangAnnotator final
|
||||
: public HangMonitor::Annotator
|
||||
{
|
||||
public:
|
||||
virtual void AnnotateHang(HangMonitor::HangAnnotations& aAnnotations)
|
||||
virtual void AnnotateHang(HangMonitor::HangAnnotations& aAnnotations) override
|
||||
{
|
||||
int32_t pending = ContentChild::GetSingleton()->GetPendingInputEvents();
|
||||
if (pending > 0) {
|
||||
|
@ -92,7 +92,7 @@ class FilePickerParent : public PFilePickerParent
|
||||
bool aIsDirectory);
|
||||
|
||||
bool Dispatch();
|
||||
NS_IMETHOD Run();
|
||||
NS_IMETHOD Run() override;
|
||||
void Destroy();
|
||||
};
|
||||
|
||||
|
@ -23,7 +23,7 @@ public:
|
||||
NS_IMETHOD OnClassifyComplete(nsresult aErrorCode,
|
||||
const nsACString& aList,
|
||||
const nsACString& aProvider,
|
||||
const nsACString& aFullHash)
|
||||
const nsACString& aFullHash) override
|
||||
{
|
||||
if (mIPCOpen) {
|
||||
ClassifierInfo info = ClassifierInfo(nsCString(aList),
|
||||
|
@ -93,7 +93,7 @@ public:
|
||||
// Override the nsIClassInfo method GetClassIDNoAlloc to make sure our
|
||||
// nsISerializable impl works right.
|
||||
NS_IMETHOD GetClassIDNoAlloc(nsCID *aClassIDNoAlloc) override;
|
||||
//NS_IMETHOD QueryInterface( const nsIID& aIID, void** aInstancePtr );
|
||||
//NS_IMETHOD QueryInterface( const nsIID& aIID, void** aInstancePtr ) override;
|
||||
|
||||
protected:
|
||||
virtual ~nsJSURI() {}
|
||||
|
@ -3911,7 +3911,7 @@ public:
|
||||
|
||||
MOZ_DEFINE_MALLOC_SIZE_OF(MallocSizeOf);
|
||||
|
||||
virtual void operator()(void* aObject)
|
||||
virtual void operator()(void* aObject) override
|
||||
{
|
||||
const VideoData* v = static_cast<const VideoData*>(aObject);
|
||||
mSize += v->SizeOfIncludingThis(MallocSizeOf);
|
||||
@ -3930,7 +3930,7 @@ public:
|
||||
|
||||
MOZ_DEFINE_MALLOC_SIZE_OF(MallocSizeOf);
|
||||
|
||||
virtual void operator()(void* aObject)
|
||||
virtual void operator()(void* aObject) override
|
||||
{
|
||||
const AudioData* audioData = static_cast<const AudioData*>(aObject);
|
||||
mSize += audioData->SizeOfIncludingThis(MallocSizeOf);
|
||||
|
@ -31,7 +31,7 @@ public:
|
||||
|
||||
NS_DECL_ISUPPORTS
|
||||
|
||||
NS_IMETHOD Notify(nsITimer* aTimer) final
|
||||
NS_IMETHOD Notify(nsITimer* aTimer) final override
|
||||
{
|
||||
mMediaDevices->DispatchTrustedEvent(NS_LITERAL_STRING("devicechange"));
|
||||
return NS_OK;
|
||||
|
@ -18,7 +18,7 @@ namespace mozilla {
|
||||
// Thread and type safe wrapper around nsDeque.
|
||||
template <class T>
|
||||
class MediaQueueDeallocator : public nsDequeFunctor {
|
||||
virtual void operator()(void* aObject)
|
||||
virtual void operator()(void* aObject) override
|
||||
{
|
||||
RefPtr<T> releaseMe = dont_AddRef(static_cast<T*>(aObject));
|
||||
}
|
||||
|
@ -1418,7 +1418,7 @@ public:
|
||||
: Runnable("MediaStreamGraphShutDownRunnable")
|
||||
, mGraph(aGraph)
|
||||
{}
|
||||
NS_IMETHOD Run()
|
||||
NS_IMETHOD Run() override
|
||||
{
|
||||
MOZ_ASSERT(NS_IsMainThread());
|
||||
MOZ_ASSERT(mGraph->mDetectedNotRunning && mGraph->mDriver,
|
||||
|
@ -104,7 +104,7 @@ public:
|
||||
: Runnable("VideoFrameContainerInvalidateRunnable")
|
||||
, mVideoFrameContainer(aVideoFrameContainer)
|
||||
{}
|
||||
NS_IMETHOD Run()
|
||||
NS_IMETHOD Run() override
|
||||
{
|
||||
MOZ_ASSERT(NS_IsMainThread());
|
||||
|
||||
|
@ -244,11 +244,11 @@ AudioSink::PopFrames(uint32_t aFrames)
|
||||
Chunk(AudioData* aBuffer, uint32_t aFrames, AudioDataValue* aData)
|
||||
: mBuffer(aBuffer), mFrames(aFrames), mData(aData) {}
|
||||
Chunk() : mFrames(0), mData(nullptr) {}
|
||||
const AudioDataValue* Data() const { return mData; }
|
||||
uint32_t Frames() const { return mFrames; }
|
||||
uint32_t Channels() const { return mBuffer ? mBuffer->mChannels: 0; }
|
||||
uint32_t Rate() const { return mBuffer ? mBuffer->mRate : 0; }
|
||||
AudioDataValue* GetWritable() const { return mData; }
|
||||
const AudioDataValue* Data() const override { return mData; }
|
||||
uint32_t Frames() const override { return mFrames; }
|
||||
uint32_t Channels() const override { return mBuffer ? mBuffer->mChannels: 0; }
|
||||
uint32_t Rate() const override { return mBuffer ? mBuffer->mRate : 0; }
|
||||
AudioDataValue* GetWritable() const override { return mData; }
|
||||
private:
|
||||
const RefPtr<AudioData> mBuffer;
|
||||
const uint32_t mFrames;
|
||||
|
@ -143,7 +143,7 @@ public:
|
||||
{
|
||||
}
|
||||
explicit Edts(Box& aBox);
|
||||
virtual bool IsValid()
|
||||
virtual bool IsValid() override
|
||||
{
|
||||
// edts is optional
|
||||
return true;
|
||||
|
@ -48,7 +48,7 @@ using OggPacketPtr = UniquePtr<ogg_packet, OggPacketDeletePolicy>;
|
||||
// Deallocates a packet, used in OggPacketQueue below.
|
||||
class OggPacketDeallocator : public nsDequeFunctor
|
||||
{
|
||||
virtual void operator()(void* aPacket)
|
||||
virtual void operator()(void* aPacket) override
|
||||
{
|
||||
OggPacketDeletePolicy()(static_cast<ogg_packet*>(aPacket));
|
||||
}
|
||||
|
@ -872,7 +872,7 @@ public:
|
||||
{
|
||||
}
|
||||
|
||||
NS_IMETHOD Run()
|
||||
NS_IMETHOD Run() override
|
||||
{
|
||||
MOZ_ASSERT(NS_IsMainThread(), "Must be on main thread.");
|
||||
mSupportsConfig = mDXVA2Manager->SupportsConfig(mMediaType, mFramerate);
|
||||
|
@ -63,7 +63,8 @@ public:
|
||||
|
||||
explicit InputObserver(CamerasParent* aParent)
|
||||
: mParent(aParent) {};
|
||||
virtual void OnDeviceChange();
|
||||
|
||||
virtual void OnDeviceChange() override;
|
||||
|
||||
friend CamerasParent;
|
||||
|
||||
|
@ -96,7 +96,7 @@ public:
|
||||
MOZ_ASSERT(NS_IsMainThread());
|
||||
}
|
||||
|
||||
NS_IMETHOD Run();
|
||||
NS_IMETHOD Run() override;
|
||||
bool CreateReader();
|
||||
MediaFormatReader* Reader()
|
||||
{
|
||||
|
@ -65,7 +65,7 @@ class MediaEngineTabVideoSource : public MediaEngineVideoSource, nsIDOMEventList
|
||||
: Runnable("MediaEngineTabVideoSource::StartRunnable")
|
||||
, mVideoSource(videoSource)
|
||||
{}
|
||||
NS_IMETHOD Run();
|
||||
NS_IMETHOD Run() override;
|
||||
RefPtr<MediaEngineTabVideoSource> mVideoSource;
|
||||
};
|
||||
|
||||
@ -75,7 +75,7 @@ class MediaEngineTabVideoSource : public MediaEngineVideoSource, nsIDOMEventList
|
||||
: Runnable("MediaEngineTabVideoSource::StopRunnable")
|
||||
, mVideoSource(videoSource)
|
||||
{}
|
||||
NS_IMETHOD Run();
|
||||
NS_IMETHOD Run() override;
|
||||
RefPtr<MediaEngineTabVideoSource> mVideoSource;
|
||||
};
|
||||
|
||||
@ -85,7 +85,7 @@ class MediaEngineTabVideoSource : public MediaEngineVideoSource, nsIDOMEventList
|
||||
: Runnable("MediaEngineTabVideoSource::InitRunnable")
|
||||
, mVideoSource(videoSource)
|
||||
{}
|
||||
NS_IMETHOD Run();
|
||||
NS_IMETHOD Run() override;
|
||||
RefPtr<MediaEngineTabVideoSource> mVideoSource;
|
||||
};
|
||||
|
||||
@ -95,7 +95,7 @@ class MediaEngineTabVideoSource : public MediaEngineVideoSource, nsIDOMEventList
|
||||
: Runnable("MediaEngineTabVideoSource::DestroyRunnable")
|
||||
, mVideoSource(videoSource)
|
||||
{}
|
||||
NS_IMETHOD Run();
|
||||
NS_IMETHOD Run() override;
|
||||
RefPtr<MediaEngineTabVideoSource> mVideoSource;
|
||||
};
|
||||
|
||||
|
@ -96,7 +96,7 @@ public:
|
||||
}
|
||||
|
||||
bool
|
||||
MainThreadRun()
|
||||
MainThreadRun() override
|
||||
{
|
||||
MOZ_ASSERT(NS_IsMainThread());
|
||||
hal::RegisterNetworkObserver(mProxy);
|
||||
@ -123,7 +123,7 @@ public:
|
||||
}
|
||||
|
||||
bool
|
||||
MainThreadRun()
|
||||
MainThreadRun() override
|
||||
{
|
||||
MOZ_ASSERT(NS_IsMainThread());
|
||||
hal::UnregisterNetworkObserver(mProxy);
|
||||
|
@ -94,7 +94,7 @@ public:
|
||||
const nsAString& aIcon,
|
||||
const nsAString& aData,
|
||||
const nsAString& aBehavior,
|
||||
const nsAString& aServiceWorkerRegistrationScope) final
|
||||
const nsAString& aServiceWorkerRegistrationScope) final override
|
||||
{
|
||||
AssertIsOnMainThread();
|
||||
MOZ_ASSERT(!aID.IsEmpty());
|
||||
@ -147,7 +147,7 @@ public:
|
||||
MOZ_ASSERT(aPromise);
|
||||
}
|
||||
|
||||
NS_IMETHOD Done() final
|
||||
NS_IMETHOD Done() final override
|
||||
{
|
||||
ErrorResult result;
|
||||
AutoTArray<RefPtr<Notification>, 5> notifications;
|
||||
@ -1617,7 +1617,7 @@ namespace {
|
||||
nsAString& mBuffer; // This struct must not outlive this buffer
|
||||
explicit StringWriteFunc(nsAString& buffer) : mBuffer(buffer) {}
|
||||
|
||||
void Write(const char* aStr)
|
||||
void Write(const char* aStr) override
|
||||
{
|
||||
mBuffer.Append(NS_ConvertUTF8toUTF16(aStr));
|
||||
}
|
||||
@ -2090,7 +2090,7 @@ public:
|
||||
MOZ_ASSERT(aProxy);
|
||||
}
|
||||
|
||||
NS_IMETHOD Done() final
|
||||
NS_IMETHOD Done() final override
|
||||
{
|
||||
AssertIsOnMainThread();
|
||||
MOZ_ASSERT(mPromiseProxy, "Was Done() called twice?");
|
||||
|
@ -30,7 +30,7 @@ public:
|
||||
NS_ASSERTION(o, "no release null objects");
|
||||
}
|
||||
|
||||
NS_IMETHOD Run();
|
||||
NS_IMETHOD Run() override;
|
||||
|
||||
private:
|
||||
const NPNetscapeFuncs* mFuncs;
|
||||
|
@ -656,7 +656,7 @@ public:
|
||||
}
|
||||
|
||||
virtual bool
|
||||
WorkerRun(JSContext* aCx, WorkerPrivate* aWorkerPrivate)
|
||||
WorkerRun(JSContext* aCx, WorkerPrivate* aWorkerPrivate) override
|
||||
{
|
||||
MOZ_ASSERT(aWorkerPrivate);
|
||||
aWorkerPrivate->AssertIsOnWorkerThread();
|
||||
|
@ -387,7 +387,7 @@ public:
|
||||
mInvalidated = true;
|
||||
}
|
||||
|
||||
NS_INLINE_DECL_REFCOUNTING(DirectoryLockImpl)
|
||||
NS_INLINE_DECL_REFCOUNTING(DirectoryLockImpl, override)
|
||||
|
||||
private:
|
||||
~DirectoryLockImpl();
|
||||
|
@ -251,9 +251,9 @@ class nsCSPSchemeSrc : public nsCSPBaseSrc {
|
||||
virtual ~nsCSPSchemeSrc();
|
||||
|
||||
bool permits(nsIURI* aUri, const nsAString& aNonce, bool aWasRedirected,
|
||||
bool aReportOnly, bool aUpgradeInsecure, bool aParserCreated) const;
|
||||
bool visit(nsCSPSrcVisitor* aVisitor) const;
|
||||
void toString(nsAString& outStr) const;
|
||||
bool aReportOnly, bool aUpgradeInsecure, bool aParserCreated) const override;
|
||||
bool visit(nsCSPSrcVisitor* aVisitor) const override;
|
||||
void toString(nsAString& outStr) const override;
|
||||
|
||||
inline void getScheme(nsAString& outStr) const
|
||||
{ outStr.Assign(mScheme); };
|
||||
@ -270,9 +270,9 @@ class nsCSPHostSrc : public nsCSPBaseSrc {
|
||||
virtual ~nsCSPHostSrc();
|
||||
|
||||
bool permits(nsIURI* aUri, const nsAString& aNonce, bool aWasRedirected,
|
||||
bool aReportOnly, bool aUpgradeInsecure, bool aParserCreated) const;
|
||||
bool visit(nsCSPSrcVisitor* aVisitor) const;
|
||||
void toString(nsAString& outStr) const;
|
||||
bool aReportOnly, bool aUpgradeInsecure, bool aParserCreated) const override;
|
||||
bool visit(nsCSPSrcVisitor* aVisitor) const override;
|
||||
void toString(nsAString& outStr) const override;
|
||||
|
||||
void setScheme(const nsAString& aScheme);
|
||||
void setPort(const nsAString& aPort);
|
||||
@ -317,16 +317,16 @@ class nsCSPKeywordSrc : public nsCSPBaseSrc {
|
||||
virtual ~nsCSPKeywordSrc();
|
||||
|
||||
bool allows(enum CSPKeyword aKeyword, const nsAString& aHashOrNonce,
|
||||
bool aParserCreated) const;
|
||||
bool aParserCreated) const override;
|
||||
bool permits(nsIURI* aUri, const nsAString& aNonce, bool aWasRedirected,
|
||||
bool aReportOnly, bool aUpgradeInsecure, bool aParserCreated) const;
|
||||
bool visit(nsCSPSrcVisitor* aVisitor) const;
|
||||
void toString(nsAString& outStr) const;
|
||||
bool aReportOnly, bool aUpgradeInsecure, bool aParserCreated) const override;
|
||||
bool visit(nsCSPSrcVisitor* aVisitor) const override;
|
||||
void toString(nsAString& outStr) const override;
|
||||
|
||||
inline CSPKeyword getKeyword() const
|
||||
{ return mKeyword; };
|
||||
|
||||
inline void invalidate() const
|
||||
inline void invalidate() const override
|
||||
{
|
||||
// keywords that need to invalidated
|
||||
if (mKeyword == CSP_SELF || mKeyword == CSP_UNSAFE_INLINE) {
|
||||
@ -346,16 +346,16 @@ class nsCSPNonceSrc : public nsCSPBaseSrc {
|
||||
virtual ~nsCSPNonceSrc();
|
||||
|
||||
bool permits(nsIURI* aUri, const nsAString& aNonce, bool aWasRedirected,
|
||||
bool aReportOnly, bool aUpgradeInsecure, bool aParserCreated) const;
|
||||
bool aReportOnly, bool aUpgradeInsecure, bool aParserCreated) const override;
|
||||
bool allows(enum CSPKeyword aKeyword, const nsAString& aHashOrNonce,
|
||||
bool aParserCreated) const;
|
||||
bool visit(nsCSPSrcVisitor* aVisitor) const;
|
||||
void toString(nsAString& outStr) const;
|
||||
bool aParserCreated) const override;
|
||||
bool visit(nsCSPSrcVisitor* aVisitor) const override;
|
||||
void toString(nsAString& outStr) const override;
|
||||
|
||||
inline void getNonce(nsAString& outStr) const
|
||||
{ outStr.Assign(mNonce); };
|
||||
|
||||
inline void invalidate() const
|
||||
inline void invalidate() const override
|
||||
{
|
||||
// overwrite nsCSPBaseSRC::invalidate() and explicitily
|
||||
// do *not* invalidate, because 'strict-dynamic' should
|
||||
@ -374,9 +374,9 @@ class nsCSPHashSrc : public nsCSPBaseSrc {
|
||||
virtual ~nsCSPHashSrc();
|
||||
|
||||
bool allows(enum CSPKeyword aKeyword, const nsAString& aHashOrNonce,
|
||||
bool aParserCreated) const;
|
||||
void toString(nsAString& outStr) const;
|
||||
bool visit(nsCSPSrcVisitor* aVisitor) const;
|
||||
bool aParserCreated) const override;
|
||||
void toString(nsAString& outStr) const override;
|
||||
bool visit(nsCSPSrcVisitor* aVisitor) const override;
|
||||
|
||||
inline void getAlgorithm(nsAString& outStr) const
|
||||
{ outStr.Assign(mAlgorithm); };
|
||||
@ -384,7 +384,7 @@ class nsCSPHashSrc : public nsCSPBaseSrc {
|
||||
inline void getHash(nsAString& outStr) const
|
||||
{ outStr.Assign(mHash); };
|
||||
|
||||
inline void invalidate() const
|
||||
inline void invalidate() const override
|
||||
{
|
||||
// overwrite nsCSPBaseSRC::invalidate() and explicitily
|
||||
// do *not* invalidate, because 'strict-dynamic' should
|
||||
@ -403,8 +403,8 @@ class nsCSPReportURI : public nsCSPBaseSrc {
|
||||
explicit nsCSPReportURI(nsIURI* aURI);
|
||||
virtual ~nsCSPReportURI();
|
||||
|
||||
bool visit(nsCSPSrcVisitor* aVisitor) const;
|
||||
void toString(nsAString& outStr) const;
|
||||
bool visit(nsCSPSrcVisitor* aVisitor) const override;
|
||||
void toString(nsAString& outStr) const override;
|
||||
|
||||
private:
|
||||
nsCOMPtr<nsIURI> mReportURI;
|
||||
@ -417,8 +417,8 @@ class nsCSPSandboxFlags : public nsCSPBaseSrc {
|
||||
explicit nsCSPSandboxFlags(const nsAString& aFlags);
|
||||
virtual ~nsCSPSandboxFlags();
|
||||
|
||||
bool visit(nsCSPSrcVisitor* aVisitor) const;
|
||||
void toString(nsAString& outStr) const;
|
||||
bool visit(nsCSPSrcVisitor* aVisitor) const override;
|
||||
void toString(nsAString& outStr) const override;
|
||||
|
||||
private:
|
||||
nsString mFlags;
|
||||
@ -495,9 +495,9 @@ class nsCSPChildSrcDirective : public nsCSPDirective {
|
||||
void setRestrictWorkers()
|
||||
{ mRestrictWorkers = true; }
|
||||
|
||||
virtual bool restrictsContentType(nsContentPolicyType aContentType) const;
|
||||
virtual bool restrictsContentType(nsContentPolicyType aContentType) const override;
|
||||
|
||||
virtual bool equals(CSPDirective aDirective) const;
|
||||
virtual bool equals(CSPDirective aDirective) const override;
|
||||
|
||||
private:
|
||||
bool mRestrictFrames;
|
||||
@ -519,9 +519,9 @@ class nsCSPScriptSrcDirective : public nsCSPDirective {
|
||||
void setRestrictWorkers()
|
||||
{ mRestrictWorkers = true; }
|
||||
|
||||
virtual bool restrictsContentType(nsContentPolicyType aContentType) const;
|
||||
virtual bool restrictsContentType(nsContentPolicyType aContentType) const override;
|
||||
|
||||
virtual bool equals(CSPDirective aDirective) const;
|
||||
virtual bool equals(CSPDirective aDirective) const override;
|
||||
|
||||
private:
|
||||
bool mRestrictWorkers;
|
||||
@ -535,19 +535,19 @@ class nsBlockAllMixedContentDirective : public nsCSPDirective {
|
||||
~nsBlockAllMixedContentDirective();
|
||||
|
||||
bool permits(nsIURI* aUri, const nsAString& aNonce, bool aWasRedirected,
|
||||
bool aReportOnly, bool aUpgradeInsecure, bool aParserCreated) const
|
||||
bool aReportOnly, bool aUpgradeInsecure, bool aParserCreated) const override
|
||||
{ return false; }
|
||||
|
||||
bool permits(nsIURI* aUri) const
|
||||
{ return false; }
|
||||
|
||||
bool allows(enum CSPKeyword aKeyword, const nsAString& aHashOrNonce,
|
||||
bool aParserCreated) const
|
||||
bool aParserCreated) const override
|
||||
{ return false; }
|
||||
|
||||
void toString(nsAString& outStr) const;
|
||||
void toString(nsAString& outStr) const override;
|
||||
|
||||
void addSrcs(const nsTArray<nsCSPBaseSrc*>& aSrcs)
|
||||
void addSrcs(const nsTArray<nsCSPBaseSrc*>& aSrcs) override
|
||||
{ MOZ_ASSERT(false, "block-all-mixed-content does not hold any srcs"); }
|
||||
};
|
||||
|
||||
@ -588,19 +588,19 @@ class nsUpgradeInsecureDirective : public nsCSPDirective {
|
||||
~nsUpgradeInsecureDirective();
|
||||
|
||||
bool permits(nsIURI* aUri, const nsAString& aNonce, bool aWasRedirected,
|
||||
bool aReportOnly, bool aUpgradeInsecure, bool aParserCreated) const
|
||||
bool aReportOnly, bool aUpgradeInsecure, bool aParserCreated) const override
|
||||
{ return false; }
|
||||
|
||||
bool permits(nsIURI* aUri) const
|
||||
{ return false; }
|
||||
|
||||
bool allows(enum CSPKeyword aKeyword, const nsAString& aHashOrNonce,
|
||||
bool aParserCreated) const
|
||||
bool aParserCreated) const override
|
||||
{ return false; }
|
||||
|
||||
void toString(nsAString& outStr) const;
|
||||
void toString(nsAString& outStr) const override;
|
||||
|
||||
void addSrcs(const nsTArray<nsCSPBaseSrc*>& aSrcs)
|
||||
void addSrcs(const nsTArray<nsCSPBaseSrc*>& aSrcs) override
|
||||
{ MOZ_ASSERT(false, "upgrade-insecure-requests does not hold any srcs"); }
|
||||
};
|
||||
|
||||
@ -611,14 +611,14 @@ class nsRequireSRIForDirective : public nsCSPDirective {
|
||||
explicit nsRequireSRIForDirective(CSPDirective aDirective);
|
||||
~nsRequireSRIForDirective();
|
||||
|
||||
void toString(nsAString& outStr) const;
|
||||
void toString(nsAString& outStr) const override;
|
||||
|
||||
void addType(nsContentPolicyType aType)
|
||||
{ mTypes.AppendElement(aType); }
|
||||
bool hasType(nsContentPolicyType aType) const;
|
||||
bool restrictsContentType(nsContentPolicyType aType) const;
|
||||
bool restrictsContentType(nsContentPolicyType aType) const override;
|
||||
bool allows(enum CSPKeyword aKeyword, const nsAString& aHashOrNonce,
|
||||
bool aParserCreated) const;
|
||||
bool aParserCreated) const override;
|
||||
|
||||
private:
|
||||
nsTArray<nsContentPolicyType> mTypes;
|
||||
|
@ -76,7 +76,7 @@ protected:
|
||||
class LocalStorageCache : public LocalStorageCacheBridge
|
||||
{
|
||||
public:
|
||||
NS_IMETHOD_(void) Release(void);
|
||||
NS_IMETHOD_(void) Release(void) override;
|
||||
|
||||
enum MutationSource {
|
||||
// The mutation is a result of an explicit JS mutation in this process.
|
||||
@ -133,14 +133,14 @@ public:
|
||||
|
||||
// LocalStorageCacheBridge
|
||||
|
||||
virtual const nsCString Origin() const;
|
||||
virtual const nsCString& OriginNoSuffix() const { return mOriginNoSuffix; }
|
||||
virtual const nsCString& OriginSuffix() const { return mOriginSuffix; }
|
||||
virtual bool Loaded() { return mLoaded; }
|
||||
virtual uint32_t LoadedCount();
|
||||
virtual bool LoadItem(const nsAString& aKey, const nsString& aValue);
|
||||
virtual void LoadDone(nsresult aRv);
|
||||
virtual void LoadWait();
|
||||
const nsCString Origin() const override;
|
||||
const nsCString& OriginNoSuffix() const override { return mOriginNoSuffix; }
|
||||
const nsCString& OriginSuffix() const override { return mOriginSuffix; }
|
||||
bool Loaded() override { return mLoaded; }
|
||||
uint32_t LoadedCount() override;
|
||||
bool LoadItem(const nsAString& aKey, const nsString& aValue) override;
|
||||
void LoadDone(nsresult aRv) override;
|
||||
void LoadWait() override;
|
||||
|
||||
// Cache keeps 3 sets of data: regular, private and session-only.
|
||||
// This class keeps keys and values for a set and also caches
|
||||
@ -279,8 +279,8 @@ public:
|
||||
const LocalStorageCache::MutationSource aSource);
|
||||
|
||||
private:
|
||||
virtual const nsCString& OriginScope() { return mOriginScope; }
|
||||
virtual void LoadUsage(const int64_t aUsage);
|
||||
const nsCString& OriginScope() override { return mOriginScope; }
|
||||
void LoadUsage(const int64_t aUsage) override;
|
||||
|
||||
nsCString mOriginScope;
|
||||
int64_t mUsage[LocalStorageCache::kDataSetCount];
|
||||
|
@ -658,15 +658,15 @@ public:
|
||||
*mRv = NS_ERROR_UNEXPECTED;
|
||||
}
|
||||
|
||||
virtual const nsCString Origin() const
|
||||
virtual const nsCString Origin() const override
|
||||
{
|
||||
return LocalStorageManager::CreateOrigin(mSuffix, mOrigin);
|
||||
}
|
||||
virtual const nsCString& OriginNoSuffix() const { return mOrigin; }
|
||||
virtual const nsCString& OriginSuffix() const { return mSuffix; }
|
||||
virtual bool Loaded() { return mLoaded; }
|
||||
virtual uint32_t LoadedCount() { return mLoadedCount; }
|
||||
virtual bool LoadItem(const nsAString& aKey, const nsString& aValue)
|
||||
virtual const nsCString& OriginNoSuffix() const override { return mOrigin; }
|
||||
virtual const nsCString& OriginSuffix() const override { return mSuffix; }
|
||||
virtual bool Loaded() override { return mLoaded; }
|
||||
virtual uint32_t LoadedCount() override { return mLoadedCount; }
|
||||
virtual bool LoadItem(const nsAString& aKey, const nsString& aValue) override
|
||||
{
|
||||
// Called on the aCache background thread
|
||||
MOZ_ASSERT(!mLoaded);
|
||||
@ -680,7 +680,7 @@ public:
|
||||
return true;
|
||||
}
|
||||
|
||||
virtual void LoadDone(nsresult aRv)
|
||||
virtual void LoadDone(nsresult aRv) override
|
||||
{
|
||||
// Called on the aCache background thread
|
||||
MonitorAutoLock monitor(mMonitor);
|
||||
@ -693,7 +693,7 @@ public:
|
||||
monitor.Notify();
|
||||
}
|
||||
|
||||
virtual void LoadWait()
|
||||
virtual void LoadWait() override
|
||||
{
|
||||
// Called on the main thread, exits after LoadDone() call
|
||||
MonitorAutoLock monitor(mMonitor);
|
||||
|
@ -95,18 +95,18 @@ public:
|
||||
private:
|
||||
mozilla::ipc::IPCResult RecvObserve(const nsCString& aTopic,
|
||||
const nsString& aOriginAttributesPattern,
|
||||
const nsCString& aOriginScope);
|
||||
const nsCString& aOriginScope) override;
|
||||
mozilla::ipc::IPCResult RecvLoadItem(const nsCString& aOriginSuffix,
|
||||
const nsCString& aOriginNoSuffix,
|
||||
const nsString& aKey,
|
||||
const nsString& aValue);
|
||||
const nsString& aValue) override;
|
||||
mozilla::ipc::IPCResult RecvLoadDone(const nsCString& aOriginSuffix,
|
||||
const nsCString& aOriginNoSuffix,
|
||||
const nsresult& aRv);
|
||||
mozilla::ipc::IPCResult RecvOriginsHavingData(nsTArray<nsCString>&& aOrigins);
|
||||
const nsresult& aRv) override;
|
||||
mozilla::ipc::IPCResult RecvOriginsHavingData(nsTArray<nsCString>&& aOrigins) override;
|
||||
mozilla::ipc::IPCResult RecvLoadUsage(const nsCString& aOriginNoSuffix,
|
||||
const int64_t& aUsage);
|
||||
mozilla::ipc::IPCResult RecvError(const nsresult& aRv);
|
||||
const int64_t& aUsage) override;
|
||||
mozilla::ipc::IPCResult RecvError(const nsresult& aRv) override;
|
||||
|
||||
nsTHashtable<nsCStringHashKey>& OriginsHavingData();
|
||||
|
||||
@ -167,22 +167,22 @@ public:
|
||||
virtual ~CacheParentBridge() {}
|
||||
|
||||
// LocalStorageCacheBridge
|
||||
virtual const nsCString Origin() const;
|
||||
virtual const nsCString& OriginNoSuffix() const
|
||||
virtual const nsCString Origin() const override;
|
||||
virtual const nsCString& OriginNoSuffix() const override
|
||||
{ return mOriginNoSuffix; }
|
||||
virtual const nsCString& OriginSuffix() const
|
||||
virtual const nsCString& OriginSuffix() const override
|
||||
{ return mOriginSuffix; }
|
||||
virtual bool Loaded()
|
||||
virtual bool Loaded() override
|
||||
{ return mLoaded; }
|
||||
virtual uint32_t LoadedCount()
|
||||
virtual uint32_t LoadedCount() override
|
||||
{ return mLoadedCount; }
|
||||
|
||||
virtual bool LoadItem(const nsAString& aKey, const nsString& aValue);
|
||||
virtual void LoadDone(nsresult aRv);
|
||||
virtual void LoadWait();
|
||||
virtual bool LoadItem(const nsAString& aKey, const nsString& aValue) override;
|
||||
virtual void LoadDone(nsresult aRv) override;
|
||||
virtual void LoadWait() override;
|
||||
|
||||
NS_IMETHOD_(void)
|
||||
Release(void);
|
||||
Release(void) override;
|
||||
|
||||
private:
|
||||
void
|
||||
@ -207,11 +207,11 @@ public:
|
||||
virtual ~UsageParentBridge() {}
|
||||
|
||||
// StorageUsageBridge
|
||||
virtual const nsCString& OriginScope() { return mOriginScope; }
|
||||
virtual void LoadUsage(const int64_t usage);
|
||||
virtual const nsCString& OriginScope() override { return mOriginScope; }
|
||||
virtual void LoadUsage(const int64_t usage) override;
|
||||
|
||||
NS_IMETHOD_(MozExternalRefCountType)
|
||||
Release(void);
|
||||
Release(void) override;
|
||||
|
||||
private:
|
||||
void
|
||||
|
@ -32,7 +32,7 @@ public:
|
||||
return mX;
|
||||
}
|
||||
|
||||
virtual void SetX(float aX, ErrorResult& aRv) final
|
||||
virtual void SetX(float aX, ErrorResult& aRv) final override
|
||||
{
|
||||
mX = aX;
|
||||
}
|
||||
@ -42,7 +42,7 @@ public:
|
||||
return mY;
|
||||
}
|
||||
|
||||
virtual void SetY(float aY, ErrorResult& aRv) final
|
||||
virtual void SetY(float aY, ErrorResult& aRv) final override
|
||||
{
|
||||
mY = aY;
|
||||
}
|
||||
@ -52,7 +52,7 @@ public:
|
||||
return mWidth;
|
||||
}
|
||||
|
||||
virtual void SetWidth(float aWidth, ErrorResult& aRv) final
|
||||
virtual void SetWidth(float aWidth, ErrorResult& aRv) final override
|
||||
{
|
||||
mWidth = aWidth;
|
||||
}
|
||||
@ -62,7 +62,7 @@ public:
|
||||
return mHeight;
|
||||
}
|
||||
|
||||
virtual void SetHeight(float aHeight, ErrorResult& aRv) final
|
||||
virtual void SetHeight(float aHeight, ErrorResult& aRv) final override
|
||||
{
|
||||
mHeight = aHeight;
|
||||
}
|
||||
|
@ -30,7 +30,8 @@ public:
|
||||
{
|
||||
UnregisterSystemTimezoneChangeObserver(this);
|
||||
}
|
||||
void Notify(const SystemTimezoneChangeInformation& aSystemTimezoneChangeInfo)
|
||||
|
||||
void Notify(const SystemTimezoneChangeInformation& aSystemTimezoneChangeInfo) override
|
||||
{
|
||||
JS::ResetTimeZone();
|
||||
}
|
||||
|
@ -31,11 +31,11 @@ public:
|
||||
virtual ~nsSystemTimeChangeObserver();
|
||||
|
||||
// Implementing hal::SystemClockChangeObserver::Notify()
|
||||
void Notify(const int64_t& aClockDeltaMS);
|
||||
void Notify(const int64_t& aClockDeltaMS) override;
|
||||
|
||||
// Implementing hal::SystemTimezoneChangeObserver::Notify()
|
||||
void Notify(
|
||||
const mozilla::hal::SystemTimezoneChangeInformation& aSystemTimezoneChangeInfo);
|
||||
const mozilla::hal::SystemTimezoneChangeInformation& aSystemTimezoneChangeInfo) override;
|
||||
|
||||
nsresult AddWindowListenerImpl(nsPIDOMWindowInner* aWindow);
|
||||
nsresult RemoveWindowListenerImpl(nsPIDOMWindowInner* aWindow);
|
||||
|
@ -85,7 +85,7 @@ public:
|
||||
}
|
||||
|
||||
bool
|
||||
MainThreadRun()
|
||||
MainThreadRun() override
|
||||
{
|
||||
using namespace mozilla::ipc;
|
||||
|
||||
@ -145,7 +145,7 @@ public:
|
||||
{}
|
||||
|
||||
bool
|
||||
MainThreadRun()
|
||||
MainThreadRun() override
|
||||
{
|
||||
AssertIsOnMainThread();
|
||||
|
||||
@ -202,7 +202,7 @@ public:
|
||||
{}
|
||||
|
||||
bool
|
||||
MainThreadRun()
|
||||
MainThreadRun() override
|
||||
{
|
||||
AssertIsOnMainThread();
|
||||
|
||||
@ -245,7 +245,7 @@ public:
|
||||
}
|
||||
|
||||
bool
|
||||
MainThreadRun()
|
||||
MainThreadRun() override
|
||||
{
|
||||
AssertIsOnMainThread();
|
||||
|
||||
@ -289,7 +289,7 @@ public:
|
||||
{
|
||||
}
|
||||
|
||||
NS_IMETHOD Run()
|
||||
NS_IMETHOD Run() override
|
||||
{
|
||||
AssertIsOnMainThread();
|
||||
|
||||
@ -336,7 +336,7 @@ public:
|
||||
}
|
||||
|
||||
bool
|
||||
MainThreadRun()
|
||||
MainThreadRun() override
|
||||
{
|
||||
AssertIsOnMainThread();
|
||||
ErrorResult rv;
|
||||
@ -436,7 +436,7 @@ public:
|
||||
}
|
||||
|
||||
bool
|
||||
MainThreadRun()
|
||||
MainThreadRun() override
|
||||
{
|
||||
AssertIsOnMainThread();
|
||||
ErrorResult rv;
|
||||
|
@ -28,17 +28,17 @@ public:
|
||||
|
||||
mozilla::ipc::IPCResult
|
||||
RecvConfirmRegister(const uint64_t& aTransactionId,
|
||||
nsTArray<uint8_t>&& aRegBuffer);
|
||||
nsTArray<uint8_t>&& aRegBuffer) override;
|
||||
|
||||
mozilla::ipc::IPCResult
|
||||
RecvConfirmSign(const uint64_t& aTransactionId,
|
||||
nsTArray<uint8_t>&& aCredentialId,
|
||||
nsTArray<uint8_t>&& aBuffer);
|
||||
nsTArray<uint8_t>&& aBuffer) override;
|
||||
|
||||
mozilla::ipc::IPCResult
|
||||
RecvAbort(const uint64_t& aTransactionId, const nsresult& aError);
|
||||
RecvAbort(const uint64_t& aTransactionId, const nsresult& aError) override;
|
||||
|
||||
void ActorDestroy(ActorDestroyReason why);
|
||||
void ActorDestroy(ActorDestroyReason why) override;
|
||||
|
||||
void Disconnect();
|
||||
|
||||
|
@ -1536,7 +1536,7 @@ public:
|
||||
}
|
||||
|
||||
void
|
||||
JobFinished(ServiceWorkerJob* aJob, ErrorResult& aStatus)
|
||||
JobFinished(ServiceWorkerJob* aJob, ErrorResult& aStatus) override
|
||||
{
|
||||
AssertIsOnMainThread();
|
||||
MOZ_ASSERT(aJob);
|
||||
@ -1552,7 +1552,7 @@ public:
|
||||
mCallback->UnregisterSucceeded(unregisterJob->GetResult());
|
||||
}
|
||||
|
||||
NS_INLINE_DECL_REFCOUNTING(UnregisterJobCallback)
|
||||
NS_INLINE_DECL_REFCOUNTING(UnregisterJobCallback, override)
|
||||
};
|
||||
|
||||
} // anonymous namespace
|
||||
@ -2788,7 +2788,7 @@ public:
|
||||
}
|
||||
|
||||
void
|
||||
JobFinished(ServiceWorkerJob* aJob, ErrorResult& aStatus)
|
||||
JobFinished(ServiceWorkerJob* aJob, ErrorResult& aStatus) override
|
||||
{
|
||||
AssertIsOnMainThread();
|
||||
MOZ_ASSERT(aJob);
|
||||
@ -2805,7 +2805,7 @@ public:
|
||||
mCallback->UpdateSucceeded(reg);
|
||||
}
|
||||
|
||||
NS_INLINE_DECL_REFCOUNTING(UpdateJobCallback)
|
||||
NS_INLINE_DECL_REFCOUNTING(UpdateJobCallback, override)
|
||||
};
|
||||
|
||||
} // anonymous namespace
|
||||
|
@ -609,7 +609,7 @@ public:
|
||||
}
|
||||
|
||||
void
|
||||
PostRun(JSContext* aCx, WorkerPrivate* aWorkerPrivate, bool aRunResult)
|
||||
PostRun(JSContext* aCx, WorkerPrivate* aWorkerPrivate, bool aRunResult) override
|
||||
{
|
||||
// Sub-class PreRun() or WorkerRun() methods could clear our mRegistration.
|
||||
if (mRegistration) {
|
||||
|
@ -1491,7 +1491,7 @@ public:
|
||||
{ }
|
||||
|
||||
bool
|
||||
WorkerRun(JSContext* aCx, WorkerPrivate* aWorkerPrivate)
|
||||
WorkerRun(JSContext* aCx, WorkerPrivate* aWorkerPrivate) override
|
||||
{
|
||||
aWorkerPrivate->CycleCollectInternal(mCollectChildren);
|
||||
return true;
|
||||
@ -1508,7 +1508,7 @@ public:
|
||||
}
|
||||
|
||||
bool
|
||||
WorkerRun(JSContext* aCx, WorkerPrivate* aWorkerPrivate)
|
||||
WorkerRun(JSContext* aCx, WorkerPrivate* aWorkerPrivate) override
|
||||
{
|
||||
aWorkerPrivate->OfflineStatusChangeEventInternal(mIsOffline);
|
||||
return true;
|
||||
@ -1526,7 +1526,7 @@ public:
|
||||
{}
|
||||
|
||||
bool
|
||||
WorkerRun(JSContext* aCx, WorkerPrivate* aWorkerPrivate)
|
||||
WorkerRun(JSContext* aCx, WorkerPrivate* aWorkerPrivate) override
|
||||
{
|
||||
aWorkerPrivate->MemoryPressureInternal();
|
||||
return true;
|
||||
@ -1593,7 +1593,7 @@ public:
|
||||
: WorkerHolder("SimpleWorkerHolder")
|
||||
{}
|
||||
|
||||
virtual bool Notify(Status aStatus) { return true; }
|
||||
virtual bool Notify(Status aStatus) override { return true; }
|
||||
};
|
||||
|
||||
} /* anonymous namespace */
|
||||
|
@ -341,7 +341,7 @@ private:
|
||||
{ }
|
||||
|
||||
bool
|
||||
WorkerRun(JSContext* aCx, WorkerPrivate* aWorkerPrivate)
|
||||
WorkerRun(JSContext* aCx, WorkerPrivate* aWorkerPrivate) override
|
||||
{
|
||||
if (mXMLHttpRequestPrivate->SendInProgress()) {
|
||||
mXMLHttpRequestPrivate->Unpin();
|
||||
|
@ -53,11 +53,11 @@ public:
|
||||
return mLastError;
|
||||
}
|
||||
|
||||
nsresult resolveNamespacePrefix(nsAtom* aPrefix, int32_t& aID);
|
||||
nsresult resolveNamespacePrefix(nsAtom* aPrefix, int32_t& aID) override;
|
||||
nsresult resolveFunctionCall(nsAtom* aName, int32_t aID,
|
||||
FunctionCall** aFunction);
|
||||
bool caseInsensitiveNameTests();
|
||||
void SetErrorOffset(uint32_t aOffset);
|
||||
FunctionCall** aFunction) override;
|
||||
bool caseInsensitiveNameTests() override;
|
||||
void SetErrorOffset(uint32_t aOffset) override;
|
||||
|
||||
private:
|
||||
XPathNSResolver* mResolver;
|
||||
|
@ -87,12 +87,11 @@ private:
|
||||
};
|
||||
|
||||
#define TX_DECL_EXPRRESULT \
|
||||
virtual short getResultType(); \
|
||||
virtual void stringValue(nsString& aString); \
|
||||
virtual const nsString* stringValuePointer(); \
|
||||
virtual bool booleanValue(); \
|
||||
virtual double numberValue(); \
|
||||
|
||||
virtual short getResultType() override; \
|
||||
virtual void stringValue(nsString& aString) override; \
|
||||
virtual const nsString* stringValuePointer() override; \
|
||||
virtual bool booleanValue() override; \
|
||||
virtual double numberValue() override;
|
||||
|
||||
class BooleanResult : public txAExprResult {
|
||||
|
||||
@ -128,4 +127,3 @@ public:
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
|
@ -106,11 +106,12 @@ public:
|
||||
|
||||
#define TX_DECL_MATCH_CONTEXT \
|
||||
nsresult getVariable(int32_t aNamespace, nsAtom* aLName, \
|
||||
txAExprResult*& aResult); \
|
||||
nsresult isStripSpaceAllowed(const txXPathNode& aNode, bool& aAllowed); \
|
||||
void* getPrivateContext(); \
|
||||
txResultRecycler* recycler(); \
|
||||
void receiveError(const nsAString& aMsg, nsresult aRes)
|
||||
txAExprResult*& aResult) override; \
|
||||
nsresult isStripSpaceAllowed(const txXPathNode& aNode, \
|
||||
bool& aAllowed) override; \
|
||||
void* getPrivateContext() override; \
|
||||
txResultRecycler* recycler() override; \
|
||||
void receiveError(const nsAString& aMsg, nsresult aRes) override
|
||||
|
||||
class txIEvalContext : public txIMatchContext
|
||||
{
|
||||
@ -134,8 +135,8 @@ public:
|
||||
|
||||
#define TX_DECL_EVAL_CONTEXT \
|
||||
TX_DECL_MATCH_CONTEXT; \
|
||||
const txXPathNode& getContextNode(); \
|
||||
uint32_t size(); \
|
||||
uint32_t position()
|
||||
const txXPathNode& getContextNode() override; \
|
||||
uint32_t size() override; \
|
||||
uint32_t position() override
|
||||
|
||||
#endif // __TX_I_XPATH_CONTEXT
|
||||
|
@ -22,34 +22,35 @@ public:
|
||||
|
||||
// txIEvalContext
|
||||
nsresult getVariable(int32_t aNamespace, nsAtom* aLName,
|
||||
txAExprResult*& aResult)
|
||||
txAExprResult*& aResult) override
|
||||
{
|
||||
MOZ_CRASH("shouldn't depend on this context");
|
||||
}
|
||||
nsresult isStripSpaceAllowed(const txXPathNode& aNode, bool& aAllowed)
|
||||
nsresult isStripSpaceAllowed(const txXPathNode& aNode,
|
||||
bool& aAllowed) override
|
||||
{
|
||||
MOZ_CRASH("shouldn't depend on this context");
|
||||
}
|
||||
void* getPrivateContext()
|
||||
void* getPrivateContext() override
|
||||
{
|
||||
MOZ_CRASH("shouldn't depend on this context");
|
||||
}
|
||||
txResultRecycler* recycler()
|
||||
txResultRecycler* recycler() override
|
||||
{
|
||||
return mRecycler;
|
||||
}
|
||||
void receiveError(const nsAString& aMsg, nsresult aRes)
|
||||
void receiveError(const nsAString& aMsg, nsresult aRes) override
|
||||
{
|
||||
}
|
||||
const txXPathNode& getContextNode()
|
||||
const txXPathNode& getContextNode() override
|
||||
{
|
||||
MOZ_CRASH("shouldn't depend on this context");
|
||||
}
|
||||
uint32_t size()
|
||||
uint32_t size() override
|
||||
{
|
||||
MOZ_CRASH("shouldn't depend on this context");
|
||||
}
|
||||
uint32_t position()
|
||||
uint32_t position() override
|
||||
{
|
||||
MOZ_CRASH("shouldn't depend on this context");
|
||||
}
|
||||
@ -58,7 +59,6 @@ private:
|
||||
txResultRecycler* mRecycler;
|
||||
};
|
||||
|
||||
|
||||
nsresult
|
||||
txXPathOptimizer::optimize(Expr* aInExpr, Expr** aOutExpr)
|
||||
{
|
||||
|
@ -38,7 +38,7 @@ public:
|
||||
};
|
||||
|
||||
#define TX_DECL_TXINSTRUCTION \
|
||||
virtual nsresult execute(txExecutionState& aEs);
|
||||
virtual nsresult execute(txExecutionState& aEs) override;
|
||||
|
||||
|
||||
class txApplyDefaultElementTemplate : public txInstruction
|
||||
|
@ -371,7 +371,7 @@ public:
|
||||
nsIDocument* aLoaderDocument);
|
||||
|
||||
TX_DECL_ACOMPILEOBSERVER
|
||||
NS_INLINE_DECL_REFCOUNTING(txCompileObserver)
|
||||
NS_INLINE_DECL_REFCOUNTING(txCompileObserver, override)
|
||||
|
||||
nsresult startLoad(nsIURI* aUri, txStylesheetCompiler* aCompiler,
|
||||
nsIPrincipal* aSourcePrincipal,
|
||||
@ -588,7 +588,7 @@ public:
|
||||
explicit txSyncCompileObserver(txMozillaXSLTProcessor* aProcessor);
|
||||
|
||||
TX_DECL_ACOMPILEOBSERVER
|
||||
NS_INLINE_DECL_REFCOUNTING(txSyncCompileObserver)
|
||||
NS_INLINE_DECL_REFCOUNTING(txSyncCompileObserver, override)
|
||||
|
||||
private:
|
||||
// Private destructor, to discourage deletion outside of Release():
|
||||
|
@ -247,7 +247,7 @@ public:
|
||||
{
|
||||
NS_ASSERTION(aValue, "missing value");
|
||||
}
|
||||
nsresult getValue(txAExprResult** aValue)
|
||||
nsresult getValue(txAExprResult** aValue) override
|
||||
{
|
||||
NS_ASSERTION(mValue || mTxValue, "variablevalue is null");
|
||||
|
||||
@ -428,58 +428,58 @@ public:
|
||||
}
|
||||
|
||||
// txIParseContext
|
||||
nsresult resolveNamespacePrefix(nsAtom* aPrefix, int32_t& aID)
|
||||
nsresult resolveNamespacePrefix(nsAtom* aPrefix, int32_t& aID) override
|
||||
{
|
||||
aID = mResolver->lookupNamespace(aPrefix);
|
||||
return aID == kNameSpaceID_Unknown ? NS_ERROR_DOM_NAMESPACE_ERR :
|
||||
NS_OK;
|
||||
}
|
||||
nsresult resolveFunctionCall(nsAtom* aName, int32_t aID,
|
||||
FunctionCall** aFunction)
|
||||
FunctionCall** aFunction) override
|
||||
{
|
||||
return NS_ERROR_XPATH_UNKNOWN_FUNCTION;
|
||||
}
|
||||
bool caseInsensitiveNameTests()
|
||||
bool caseInsensitiveNameTests() override
|
||||
{
|
||||
return false;
|
||||
}
|
||||
void SetErrorOffset(uint32_t aOffset)
|
||||
void SetErrorOffset(uint32_t aOffset) override
|
||||
{
|
||||
}
|
||||
|
||||
// txIEvalContext
|
||||
nsresult getVariable(int32_t aNamespace, nsAtom* aLName,
|
||||
txAExprResult*& aResult)
|
||||
txAExprResult*& aResult) override
|
||||
{
|
||||
aResult = nullptr;
|
||||
return NS_ERROR_INVALID_ARG;
|
||||
}
|
||||
nsresult isStripSpaceAllowed(const txXPathNode& aNode, bool& aAllowed)
|
||||
nsresult isStripSpaceAllowed(const txXPathNode& aNode, bool& aAllowed) override
|
||||
{
|
||||
aAllowed = false;
|
||||
|
||||
return NS_OK;
|
||||
}
|
||||
void* getPrivateContext()
|
||||
void* getPrivateContext() override
|
||||
{
|
||||
return nullptr;
|
||||
}
|
||||
txResultRecycler* recycler()
|
||||
txResultRecycler* recycler() override
|
||||
{
|
||||
return mRecycler;
|
||||
}
|
||||
void receiveError(const nsAString& aMsg, nsresult aRes)
|
||||
void receiveError(const nsAString& aMsg, nsresult aRes) override
|
||||
{
|
||||
}
|
||||
const txXPathNode& getContextNode()
|
||||
const txXPathNode& getContextNode() override
|
||||
{
|
||||
return mContext;
|
||||
}
|
||||
uint32_t size()
|
||||
uint32_t size() override
|
||||
{
|
||||
return 1;
|
||||
}
|
||||
uint32_t position()
|
||||
uint32_t position() override
|
||||
{
|
||||
return 1;
|
||||
}
|
||||
|
@ -61,10 +61,10 @@ public:
|
||||
#define TX_DECL_ACOMPILEOBSERVER \
|
||||
nsresult loadURI(const nsAString& aUri, const nsAString& aReferrerUri, \
|
||||
mozilla::net::ReferrerPolicy aReferrerPolicy, \
|
||||
txStylesheetCompiler* aCompiler); \
|
||||
txStylesheetCompiler* aCompiler) override; \
|
||||
void onDoneCompiling(txStylesheetCompiler* aCompiler, nsresult aResult, \
|
||||
const char16_t *aErrorText = nullptr, \
|
||||
const char16_t *aParam = nullptr);
|
||||
const char16_t *aParam = nullptr) override;
|
||||
|
||||
class txStylesheetCompilerState : public txIParseContext
|
||||
{
|
||||
@ -233,7 +233,7 @@ public:
|
||||
txStylesheet* getStylesheet();
|
||||
|
||||
TX_DECL_ACOMPILEOBSERVER
|
||||
NS_INLINE_DECL_REFCOUNTING(txStylesheetCompiler)
|
||||
NS_INLINE_DECL_REFCOUNTING(txStylesheetCompiler, override)
|
||||
|
||||
private:
|
||||
// Private destructor, to discourage deletion outside of Release():
|
||||
|
@ -41,7 +41,7 @@ public:
|
||||
virtual type getType() = 0;
|
||||
};
|
||||
|
||||
#define TX_DECL_TOPLEVELITEM virtual type getType();
|
||||
#define TX_DECL_TOPLEVELITEM virtual type getType() override;
|
||||
#define TX_IMPL_GETTYPE(_class, _type) \
|
||||
txToplevelItem::type \
|
||||
_class::getType() { return _type;}
|
||||
|
@ -120,25 +120,25 @@ public:
|
||||
#define TX_DECL_TXAXMLEVENTHANDLER \
|
||||
virtual nsresult attribute(nsAtom* aPrefix, nsAtom* aLocalName, \
|
||||
nsAtom* aLowercaseLocalName, int32_t aNsID, \
|
||||
const nsString& aValue); \
|
||||
const nsString& aValue) override; \
|
||||
virtual nsresult attribute(nsAtom* aPrefix, \
|
||||
const nsAString& aLocalName, \
|
||||
const int32_t aNsID, \
|
||||
const nsString& aValue); \
|
||||
virtual nsresult characters(const nsAString& aData, bool aDOE); \
|
||||
virtual nsresult comment(const nsString& aData); \
|
||||
virtual nsresult endDocument(nsresult aResult = NS_OK); \
|
||||
virtual nsresult endElement(); \
|
||||
const nsString& aValue) override; \
|
||||
virtual nsresult characters(const nsAString& aData, bool aDOE) override; \
|
||||
virtual nsresult comment(const nsString& aData) override; \
|
||||
virtual nsresult endDocument(nsresult aResult = NS_OK) override; \
|
||||
virtual nsresult endElement() override; \
|
||||
virtual nsresult processingInstruction(const nsString& aTarget, \
|
||||
const nsString& aData); \
|
||||
virtual nsresult startDocument(); \
|
||||
const nsString& aData) override; \
|
||||
virtual nsresult startDocument() override; \
|
||||
virtual nsresult startElement(nsAtom* aPrefix, \
|
||||
nsAtom* aLocalName, \
|
||||
nsAtom* aLowercaseLocalName, \
|
||||
int32_t aNsID); \
|
||||
int32_t aNsID) override; \
|
||||
virtual nsresult startElement(nsAtom* aPrefix, \
|
||||
const nsAString& aName, \
|
||||
const int32_t aNsID);
|
||||
const int32_t aNsID) override;
|
||||
|
||||
|
||||
class txAOutputXMLEventHandler : public txAXMLEventHandler
|
||||
@ -153,7 +153,7 @@ public:
|
||||
};
|
||||
|
||||
#define TX_DECL_TXAOUTPUTXMLEVENTHANDLER \
|
||||
virtual void getOutputDocument(nsIDOMDocument** aDocument);
|
||||
virtual void getOutputDocument(nsIDOMDocument** aDocument) override;
|
||||
|
||||
/**
|
||||
* Interface used to create the appropriate outputhandler
|
||||
@ -189,10 +189,10 @@ public:
|
||||
|
||||
#define TX_DECL_TXAOUTPUTHANDLERFACTORY \
|
||||
nsresult createHandlerWith(txOutputFormat* aFormat, \
|
||||
txAXMLEventHandler** aHandler); \
|
||||
txAXMLEventHandler** aHandler) override; \
|
||||
nsresult createHandlerWith(txOutputFormat* aFormat, \
|
||||
const nsAString& aName, \
|
||||
int32_t aNsID, \
|
||||
txAXMLEventHandler** aHandler);
|
||||
txAXMLEventHandler** aHandler) override;
|
||||
|
||||
#endif
|
||||
|
@ -16,7 +16,7 @@ public:
|
||||
txDecimalCounter(int32_t aMinLength, int32_t aGroupSize,
|
||||
const nsAString& mGroupSeparator);
|
||||
|
||||
virtual void appendNumber(int32_t aNumber, nsAString& aDest);
|
||||
virtual void appendNumber(int32_t aNumber, nsAString& aDest) override;
|
||||
|
||||
private:
|
||||
int32_t mMinLength;
|
||||
@ -30,7 +30,7 @@ public:
|
||||
{
|
||||
}
|
||||
|
||||
virtual void appendNumber(int32_t aNumber, nsAString& aDest);
|
||||
virtual void appendNumber(int32_t aNumber, nsAString& aDest) override;
|
||||
|
||||
private:
|
||||
char16_t mOffset;
|
||||
@ -42,7 +42,7 @@ public:
|
||||
{
|
||||
}
|
||||
|
||||
void appendNumber(int32_t aNumber, nsAString& aDest);
|
||||
void appendNumber(int32_t aNumber, nsAString& aDest) override;
|
||||
|
||||
private:
|
||||
int32_t mTableOffset;
|
||||
|
@ -380,7 +380,7 @@ public:
|
||||
bool aIsTrustedEvent) override;
|
||||
void ClickWithInputSource(uint16_t aInputSource, bool aIsTrustedEvent);
|
||||
|
||||
nsIContent* GetBindingParent() const final
|
||||
nsIContent* GetBindingParent() const final override
|
||||
{
|
||||
return mBindingParent;
|
||||
}
|
||||
|
@ -522,7 +522,7 @@ class TrivialFunctor final : public BoolDomIterFunctor
|
||||
{
|
||||
public:
|
||||
// Used to build list of all nodes iterator covers
|
||||
virtual bool operator()(nsINode* aNode) const
|
||||
virtual bool operator()(nsINode* aNode) const override
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
@ -133,7 +133,7 @@ class TableCellAndListItemFunctor final : public BoolDomIterFunctor
|
||||
{
|
||||
public:
|
||||
// Used to build list of all li's, td's & th's iterator covers
|
||||
virtual bool operator()(nsINode* aNode) const
|
||||
virtual bool operator()(nsINode* aNode) const override
|
||||
{
|
||||
return HTMLEditUtils::IsTableCell(aNode) ||
|
||||
HTMLEditUtils::IsListItem(aNode);
|
||||
@ -143,7 +143,7 @@ public:
|
||||
class BRNodeFunctor final : public BoolDomIterFunctor
|
||||
{
|
||||
public:
|
||||
virtual bool operator()(nsINode* aNode) const
|
||||
virtual bool operator()(nsINode* aNode) const override
|
||||
{
|
||||
return aNode->IsHTMLElement(nsGkAtoms::br);
|
||||
}
|
||||
@ -156,7 +156,7 @@ public:
|
||||
: mHTMLEditor(aHTMLEditor)
|
||||
{}
|
||||
|
||||
virtual bool operator()(nsINode* aNode) const
|
||||
virtual bool operator()(nsINode* aNode) const override
|
||||
{
|
||||
if (mHTMLEditor->IsEditable(aNode) &&
|
||||
(HTMLEditUtils::IsListItem(aNode) ||
|
||||
@ -6119,7 +6119,7 @@ public:
|
||||
}
|
||||
|
||||
// Used to build list of all nodes iterator covers.
|
||||
virtual bool operator()(nsINode* aNode) const
|
||||
virtual bool operator()(nsINode* aNode) const override
|
||||
{
|
||||
return !mArray.Contains(aNode);
|
||||
}
|
||||
|
@ -11,7 +11,7 @@
|
||||
#include "nscore.h"
|
||||
|
||||
class nsTransactionStackDeallocator : public nsDequeFunctor {
|
||||
virtual void operator()(void* aObject)
|
||||
virtual void operator()(void* aObject) override
|
||||
{
|
||||
RefPtr<nsTransactionItem> releaseMe = dont_AddRef(static_cast<nsTransactionItem*>(aObject));
|
||||
}
|
||||
|
@ -380,7 +380,7 @@ public:
|
||||
nsresult
|
||||
Insert(const nsACString& aOrigin, const nsCString& aType,
|
||||
uint32_t aPermission, uint32_t aExpireType, int64_t aExpireTime,
|
||||
int64_t aModificationTime) final
|
||||
int64_t aModificationTime) final override
|
||||
{
|
||||
nsresult rv = mStmt->BindInt64ByIndex(0, *mID);
|
||||
NS_ENSURE_SUCCESS(rv, rv);
|
||||
@ -430,7 +430,7 @@ public:
|
||||
nsresult
|
||||
Insert(const nsACString& aOrigin, const nsCString& aType,
|
||||
uint32_t aPermission, uint32_t aExpireType, int64_t aExpireTime,
|
||||
int64_t aModificationTime) final
|
||||
int64_t aModificationTime) final override
|
||||
{
|
||||
nsCOMPtr<nsIPrincipal> principal;
|
||||
nsresult rv = GetPrincipalFromOrigin(aOrigin, getter_AddRefs(principal));
|
||||
@ -465,7 +465,7 @@ public:
|
||||
nsresult
|
||||
Insert(const nsACString& aOrigin, const nsCString& aType,
|
||||
uint32_t aPermission, uint32_t aExpireType, int64_t aExpireTime,
|
||||
int64_t aModificationTime) final
|
||||
int64_t aModificationTime) final override
|
||||
{
|
||||
// Every time the migration code wants to insert an origin into
|
||||
// the database we need to check to see if someone has already
|
||||
|
@ -94,8 +94,9 @@ protected:
|
||||
// first byte range: 0xc4 -- 0xfe
|
||||
// second byte range: 0xa1 -- 0xfe
|
||||
//no validation needed here. State machine has done that
|
||||
int32_t GetOrder(const char* str)
|
||||
{ if ((unsigned char)*str >= (unsigned char)0xc4)
|
||||
int32_t GetOrder(const char* str) override
|
||||
{
|
||||
if ((unsigned char)*str >= (unsigned char)0xc4)
|
||||
return 94*((unsigned char)str[0]-(unsigned char)0xc4) + (unsigned char)str[1] - (unsigned char)0xa1;
|
||||
else
|
||||
return -1;
|
||||
@ -112,8 +113,9 @@ protected:
|
||||
// first byte range: 0xb0 -- 0xfe
|
||||
// second byte range: 0xa1 -- 0xfe
|
||||
//no validation needed here. State machine has done that
|
||||
int32_t GetOrder(const char* str)
|
||||
{ if ((unsigned char)*str >= (unsigned char)0xb0)
|
||||
int32_t GetOrder(const char* str) override
|
||||
{
|
||||
if ((unsigned char)*str >= (unsigned char)0xb0)
|
||||
return 94*((unsigned char)str[0]-(unsigned char)0xb0) + (unsigned char)str[1] - (unsigned char)0xa1;
|
||||
else
|
||||
return -1;
|
||||
@ -129,8 +131,9 @@ protected:
|
||||
// first byte range: 0xb0 -- 0xfe
|
||||
// second byte range: 0xa1 -- 0xfe
|
||||
//no validation needed here. State machine has done that
|
||||
int32_t GetOrder(const char* str)
|
||||
{ if ((unsigned char)*str >= (unsigned char)0xb0 && (unsigned char)str[1] >= (unsigned char)0xa1)
|
||||
int32_t GetOrder(const char* str) override
|
||||
{
|
||||
if ((unsigned char)*str >= (unsigned char)0xb0 && (unsigned char)str[1] >= (unsigned char)0xa1)
|
||||
return 94*((unsigned char)str[0]-(unsigned char)0xb0) + (unsigned char)str[1] - (unsigned char)0xa1;
|
||||
else
|
||||
return -1;
|
||||
@ -147,8 +150,9 @@ protected:
|
||||
// first byte range: 0xa4 -- 0xfe
|
||||
// second byte range: 0x40 -- 0x7e , 0xa1 -- 0xfe
|
||||
//no validation needed here. State machine has done that
|
||||
int32_t GetOrder(const char* str)
|
||||
{ if ((unsigned char)*str >= (unsigned char)0xa4)
|
||||
int32_t GetOrder(const char* str) override
|
||||
{
|
||||
if ((unsigned char)*str >= (unsigned char)0xa4)
|
||||
if ((unsigned char)str[1] >= (unsigned char)0xa1)
|
||||
return 157*((unsigned char)str[0]-(unsigned char)0xa4) + (unsigned char)str[1] - (unsigned char)0xa1 +63;
|
||||
else
|
||||
@ -167,7 +171,7 @@ protected:
|
||||
// first byte range: 0x81 -- 0x9f , 0xe0 -- 0xfe
|
||||
// second byte range: 0x40 -- 0x7e, 0x81 -- oxfe
|
||||
//no validation needed here. State machine has done that
|
||||
int32_t GetOrder(const char* str)
|
||||
int32_t GetOrder(const char* str) override
|
||||
{
|
||||
int32_t order;
|
||||
if ((unsigned char)*str >= (unsigned char)0x81 && (unsigned char)*str <= (unsigned char)0x9f)
|
||||
@ -192,8 +196,9 @@ protected:
|
||||
// first byte range: 0xa0 -- 0xfe
|
||||
// second byte range: 0xa1 -- 0xfe
|
||||
//no validation needed here. State machine has done that
|
||||
int32_t GetOrder(const char* str)
|
||||
{ if ((unsigned char)*str >= (unsigned char)0xa0)
|
||||
int32_t GetOrder(const char* str) override
|
||||
{
|
||||
if ((unsigned char)*str >= (unsigned char)0xa0)
|
||||
return 94*((unsigned char)str[0]-(unsigned char)0xa1) + (unsigned char)str[1] - (unsigned char)0xa1;
|
||||
else
|
||||
return -1;
|
||||
@ -201,4 +206,3 @@ protected:
|
||||
};
|
||||
|
||||
#endif //CharDistribution_h__
|
||||
|
||||
|
@ -75,9 +75,9 @@ class SJISContextAnalysis : public JapaneseContextAnalysis
|
||||
{
|
||||
//SJISContextAnalysis(){};
|
||||
protected:
|
||||
int32_t GetOrder(const char* str, uint32_t *charLen);
|
||||
int32_t GetOrder(const char* str, uint32_t *charLen) override;
|
||||
|
||||
int32_t GetOrder(const char* str)
|
||||
int32_t GetOrder(const char* str) override
|
||||
{
|
||||
//We only interested in Hiragana, so first byte is '\202'
|
||||
if (*str == '\202' &&
|
||||
@ -91,8 +91,8 @@ protected:
|
||||
class EUCJPContextAnalysis : public JapaneseContextAnalysis
|
||||
{
|
||||
protected:
|
||||
int32_t GetOrder(const char* str, uint32_t *charLen);
|
||||
int32_t GetOrder(const char* str)
|
||||
int32_t GetOrder(const char* str, uint32_t *charLen) override;
|
||||
int32_t GetOrder(const char* str) override
|
||||
//We only interested in Hiragana, so first byte is '\244'
|
||||
{
|
||||
if (*str == '\244' &&
|
||||
|
@ -22,11 +22,11 @@ public:
|
||||
{mCodingSM = new nsCodingStateMachine(&EUCJPSMModel);
|
||||
Reset();}
|
||||
virtual ~nsEUCJPProber(void){delete mCodingSM;}
|
||||
nsProbingState HandleData(const char* aBuf, uint32_t aLen);
|
||||
const char* GetCharSetName() {return "EUC-JP";}
|
||||
nsProbingState GetState(void) {return mState;}
|
||||
void Reset(void);
|
||||
float GetConfidence(void);
|
||||
nsProbingState HandleData(const char* aBuf, uint32_t aLen) override;
|
||||
const char* GetCharSetName() override {return "EUC-JP";}
|
||||
nsProbingState GetState(void) override {return mState;}
|
||||
void Reset(void) override;
|
||||
float GetConfidence(void) override;
|
||||
|
||||
protected:
|
||||
nsCodingStateMachine* mCodingSM;
|
||||
@ -38,6 +38,5 @@ protected:
|
||||
char mLastChar[2];
|
||||
};
|
||||
|
||||
|
||||
#endif /* nsEUCJPProber_h__ */
|
||||
|
||||
|
@ -14,11 +14,11 @@ class nsEscCharSetProber: public nsCharSetProber {
|
||||
public:
|
||||
nsEscCharSetProber();
|
||||
virtual ~nsEscCharSetProber(void);
|
||||
nsProbingState HandleData(const char* aBuf, uint32_t aLen);
|
||||
const char* GetCharSetName() {return mDetectedCharset;}
|
||||
nsProbingState GetState(void) {return mState;}
|
||||
void Reset(void);
|
||||
float GetConfidence(void){return (float)0.99;}
|
||||
nsProbingState HandleData(const char* aBuf, uint32_t aLen) override;
|
||||
const char* GetCharSetName() override {return mDetectedCharset;}
|
||||
nsProbingState GetState(void) override {return mState;}
|
||||
void Reset(void) override;
|
||||
float GetConfidence(void) override {return (float)0.99;}
|
||||
|
||||
protected:
|
||||
void GetDistribution(uint32_t aCharLen, const char* aStr);
|
||||
|
@ -14,11 +14,11 @@ class nsLatin1Prober: public nsCharSetProber {
|
||||
public:
|
||||
nsLatin1Prober(void){Reset();}
|
||||
virtual ~nsLatin1Prober(void){}
|
||||
nsProbingState HandleData(const char* aBuf, uint32_t aLen);
|
||||
const char* GetCharSetName() {return "windows-1252";}
|
||||
nsProbingState GetState(void) {return mState;}
|
||||
void Reset(void);
|
||||
float GetConfidence(void);
|
||||
nsProbingState HandleData(const char* aBuf, uint32_t aLen) override;
|
||||
const char* GetCharSetName() override {return "windows-1252";}
|
||||
nsProbingState GetState(void) override {return mState;}
|
||||
void Reset(void) override;
|
||||
float GetConfidence(void) override;
|
||||
|
||||
#ifdef DEBUG_chardet
|
||||
virtual void DumpStatus();
|
||||
@ -31,6 +31,5 @@ protected:
|
||||
uint32_t mFreqCounter[FREQ_CAT_NUM];
|
||||
};
|
||||
|
||||
|
||||
#endif /* nsLatin1Prober_h__ */
|
||||
|
||||
|
@ -16,11 +16,11 @@ class nsMBCSGroupProber: public nsCharSetProber {
|
||||
public:
|
||||
nsMBCSGroupProber();
|
||||
virtual ~nsMBCSGroupProber();
|
||||
nsProbingState HandleData(const char* aBuf, uint32_t aLen);
|
||||
const char* GetCharSetName();
|
||||
nsProbingState GetState(void) {return mState;}
|
||||
void Reset(void);
|
||||
float GetConfidence(void);
|
||||
nsProbingState HandleData(const char* aBuf, uint32_t aLen) override;
|
||||
const char* GetCharSetName() override;
|
||||
nsProbingState GetState(void) override {return mState;}
|
||||
void Reset(void) override;
|
||||
float GetConfidence(void) override;
|
||||
|
||||
#ifdef DEBUG_chardet
|
||||
void DumpStatus();
|
||||
@ -39,4 +39,3 @@ protected:
|
||||
};
|
||||
|
||||
#endif /* nsMBCSGroupProber_h__ */
|
||||
|
||||
|
@ -23,11 +23,11 @@ public:
|
||||
{mCodingSM = new nsCodingStateMachine(&SJISSMModel);
|
||||
Reset();}
|
||||
virtual ~nsSJISProber(void){delete mCodingSM;}
|
||||
nsProbingState HandleData(const char* aBuf, uint32_t aLen);
|
||||
const char* GetCharSetName() {return "Shift_JIS";}
|
||||
nsProbingState GetState(void) {return mState;}
|
||||
void Reset(void);
|
||||
float GetConfidence(void);
|
||||
nsProbingState HandleData(const char* aBuf, uint32_t aLen) override;
|
||||
const char* GetCharSetName() override {return "Shift_JIS";}
|
||||
nsProbingState GetState(void) override {return mState;}
|
||||
void Reset(void) override;
|
||||
float GetConfidence(void) override;
|
||||
|
||||
protected:
|
||||
nsCodingStateMachine* mCodingSM;
|
||||
@ -39,6 +39,4 @@ protected:
|
||||
char mLastChar[2];
|
||||
};
|
||||
|
||||
|
||||
#endif /* nsSJISProber_h__ */
|
||||
|
||||
|
@ -15,11 +15,11 @@ public:
|
||||
mCodingSM = new nsCodingStateMachine(&UTF8SMModel);
|
||||
Reset(); }
|
||||
virtual ~nsUTF8Prober(){delete mCodingSM;}
|
||||
nsProbingState HandleData(const char* aBuf, uint32_t aLen);
|
||||
const char* GetCharSetName() {return "UTF-8";}
|
||||
nsProbingState GetState(void) {return mState;}
|
||||
void Reset(void);
|
||||
float GetConfidence(void);
|
||||
nsProbingState HandleData(const char* aBuf, uint32_t aLen) override;
|
||||
const char* GetCharSetName() override {return "UTF-8";}
|
||||
nsProbingState GetState(void) override {return mState;}
|
||||
void Reset(void) override;
|
||||
float GetConfidence(void) override;
|
||||
|
||||
protected:
|
||||
nsCodingStateMachine* mCodingSM;
|
||||
@ -28,4 +28,3 @@ protected:
|
||||
};
|
||||
|
||||
#endif /* nsUTF8Prober_h__ */
|
||||
|
||||
|
@ -706,7 +706,7 @@ protected:
|
||||
class PathBuilder : public PathSink
|
||||
{
|
||||
public:
|
||||
MOZ_DECLARE_REFCOUNTED_VIRTUAL_TYPENAME(PathBuilder)
|
||||
MOZ_DECLARE_REFCOUNTED_VIRTUAL_TYPENAME(PathBuilder, override)
|
||||
/** Finish writing to the path and return a Path object that can be used for
|
||||
* drawing. Future use of the builder results in a crash!
|
||||
*/
|
||||
@ -1445,7 +1445,7 @@ protected:
|
||||
class DrawTargetCapture : public DrawTarget
|
||||
{
|
||||
public:
|
||||
virtual bool IsCaptureDT() const { return true; }
|
||||
virtual bool IsCaptureDT() const override { return true; }
|
||||
|
||||
/**
|
||||
* Returns true if the recording only contains FillGlyph calls with
|
||||
|
@ -172,11 +172,12 @@ public:
|
||||
{
|
||||
}
|
||||
|
||||
void CloneInto(CaptureCommandList* aList) {
|
||||
void CloneInto(CaptureCommandList* aList) override
|
||||
{
|
||||
CLONE_INTO(DrawSurfaceCommand)(mSurface, mDest, mSource, mSurfOptions, mOptions);
|
||||
}
|
||||
|
||||
virtual void ExecuteOnDT(DrawTarget* aDT, const Matrix*) const
|
||||
virtual void ExecuteOnDT(DrawTarget* aDT, const Matrix*) const override
|
||||
{
|
||||
aDT->DrawSurface(mSurface, mDest, mSource, mSurfOptions, mOptions);
|
||||
}
|
||||
@ -210,11 +211,12 @@ public:
|
||||
{
|
||||
}
|
||||
|
||||
void CloneInto(CaptureCommandList* aList) {
|
||||
void CloneInto(CaptureCommandList* aList) override
|
||||
{
|
||||
CLONE_INTO(DrawSurfaceWithShadowCommand)(mSurface, mDest, mColor, mOffset, mSigma, mOperator);
|
||||
}
|
||||
|
||||
virtual void ExecuteOnDT(DrawTarget* aDT, const Matrix*) const
|
||||
virtual void ExecuteOnDT(DrawTarget* aDT, const Matrix*) const override
|
||||
{
|
||||
aDT->DrawSurfaceWithShadow(mSurface, mDest, mColor, mOffset, mSigma, mOperator);
|
||||
}
|
||||
@ -241,11 +243,12 @@ public:
|
||||
{
|
||||
}
|
||||
|
||||
void CloneInto(CaptureCommandList* aList) {
|
||||
void CloneInto(CaptureCommandList* aList) override
|
||||
{
|
||||
CLONE_INTO(DrawFilterCommand)(mFilter, mSourceRect, mDestPoint, mOptions);
|
||||
}
|
||||
|
||||
virtual void ExecuteOnDT(DrawTarget* aDT, const Matrix*) const
|
||||
virtual void ExecuteOnDT(DrawTarget* aDT, const Matrix*) const override
|
||||
{
|
||||
RefPtr<FilterNode> filter = mFilter;
|
||||
if (mFilter->GetBackendType() == FilterBackend::FILTER_BACKEND_CAPTURE) {
|
||||
@ -272,11 +275,12 @@ public:
|
||||
{
|
||||
}
|
||||
|
||||
void CloneInto(CaptureCommandList* aList) {
|
||||
void CloneInto(CaptureCommandList* aList) override
|
||||
{
|
||||
CLONE_INTO(ClearRectCommand)(mRect);
|
||||
}
|
||||
|
||||
virtual void ExecuteOnDT(DrawTarget* aDT, const Matrix*) const
|
||||
virtual void ExecuteOnDT(DrawTarget* aDT, const Matrix*) const override
|
||||
{
|
||||
aDT->ClearRect(mRect);
|
||||
}
|
||||
@ -300,11 +304,12 @@ public:
|
||||
{
|
||||
}
|
||||
|
||||
void CloneInto(CaptureCommandList* aList) {
|
||||
void CloneInto(CaptureCommandList* aList) override
|
||||
{
|
||||
CLONE_INTO(CopySurfaceCommand)(mSurface, mSourceRect, mDestination);
|
||||
}
|
||||
|
||||
virtual void ExecuteOnDT(DrawTarget* aDT, const Matrix* aTransform) const
|
||||
virtual void ExecuteOnDT(DrawTarget* aDT, const Matrix* aTransform) const override
|
||||
{
|
||||
MOZ_ASSERT(!aTransform || !aTransform->HasNonIntegerTranslation());
|
||||
Point dest(Float(mDestination.x), Float(mDestination.y));
|
||||
@ -335,16 +340,17 @@ public:
|
||||
{
|
||||
}
|
||||
|
||||
void CloneInto(CaptureCommandList* aList) {
|
||||
void CloneInto(CaptureCommandList* aList) override
|
||||
{
|
||||
CLONE_INTO(FillRectCommand)(mRect, mPattern, mOptions);
|
||||
}
|
||||
|
||||
virtual void ExecuteOnDT(DrawTarget* aDT, const Matrix*) const
|
||||
virtual void ExecuteOnDT(DrawTarget* aDT, const Matrix*) const override
|
||||
{
|
||||
aDT->FillRect(mRect, mPattern, mOptions);
|
||||
}
|
||||
|
||||
bool GetAffectedRect(Rect& aDeviceRect, const Matrix& aTransform) const
|
||||
bool GetAffectedRect(Rect& aDeviceRect, const Matrix& aTransform) const override
|
||||
{
|
||||
aDeviceRect = aTransform.TransformBounds(mRect);
|
||||
return true;
|
||||
@ -372,11 +378,12 @@ public:
|
||||
{
|
||||
}
|
||||
|
||||
void CloneInto(CaptureCommandList* aList) {
|
||||
void CloneInto(CaptureCommandList* aList) override
|
||||
{
|
||||
CLONE_INTO(StrokeRectCommand)(mRect, mPattern, mStrokeOptions, mOptions);
|
||||
}
|
||||
|
||||
virtual void ExecuteOnDT(DrawTarget* aDT, const Matrix*) const
|
||||
virtual void ExecuteOnDT(DrawTarget* aDT, const Matrix*) const override
|
||||
{
|
||||
aDT->StrokeRect(mRect, mPattern, mStrokeOptions, mOptions);
|
||||
}
|
||||
@ -405,11 +412,12 @@ public:
|
||||
{
|
||||
}
|
||||
|
||||
void CloneInto(CaptureCommandList* aList) {
|
||||
void CloneInto(CaptureCommandList* aList) override
|
||||
{
|
||||
CLONE_INTO(StrokeLineCommand)(mStart, mEnd, mPattern, mStrokeOptions, mOptions);
|
||||
}
|
||||
|
||||
virtual void ExecuteOnDT(DrawTarget* aDT, const Matrix*) const
|
||||
virtual void ExecuteOnDT(DrawTarget* aDT, const Matrix*) const override
|
||||
{
|
||||
aDT->StrokeLine(mStart, mEnd, mPattern, mStrokeOptions, mOptions);
|
||||
}
|
||||
@ -436,16 +444,17 @@ public:
|
||||
{
|
||||
}
|
||||
|
||||
void CloneInto(CaptureCommandList* aList) {
|
||||
void CloneInto(CaptureCommandList* aList) override
|
||||
{
|
||||
CLONE_INTO(FillCommand)(mPath, mPattern, mOptions);
|
||||
}
|
||||
|
||||
virtual void ExecuteOnDT(DrawTarget* aDT, const Matrix*) const
|
||||
virtual void ExecuteOnDT(DrawTarget* aDT, const Matrix*) const override
|
||||
{
|
||||
aDT->Fill(mPath, mPattern, mOptions);
|
||||
}
|
||||
|
||||
bool GetAffectedRect(Rect& aDeviceRect, const Matrix& aTransform) const
|
||||
bool GetAffectedRect(Rect& aDeviceRect, const Matrix& aTransform) const override
|
||||
{
|
||||
aDeviceRect = mPath->GetBounds(aTransform);
|
||||
return true;
|
||||
@ -514,16 +523,17 @@ public:
|
||||
{
|
||||
}
|
||||
|
||||
void CloneInto(CaptureCommandList* aList) {
|
||||
void CloneInto(CaptureCommandList* aList) override
|
||||
{
|
||||
CLONE_INTO(StrokeCommand)(mPath, mPattern, mStrokeOptions, mOptions);
|
||||
}
|
||||
|
||||
virtual void ExecuteOnDT(DrawTarget* aDT, const Matrix*) const
|
||||
virtual void ExecuteOnDT(DrawTarget* aDT, const Matrix*) const override
|
||||
{
|
||||
aDT->Stroke(mPath, mPattern, mStrokeOptions, mOptions);
|
||||
}
|
||||
|
||||
bool GetAffectedRect(Rect& aDeviceRect, const Matrix& aTransform) const
|
||||
bool GetAffectedRect(Rect& aDeviceRect, const Matrix& aTransform) const override
|
||||
{
|
||||
aDeviceRect = PathExtentsToMaxStrokeExtents(mStrokeOptions, mPath->GetBounds(aTransform), aTransform);
|
||||
return true;
|
||||
@ -554,7 +564,8 @@ public:
|
||||
memcpy(&mGlyphs.front(), aBuffer.mGlyphs, sizeof(Glyph) * aBuffer.mNumGlyphs);
|
||||
}
|
||||
|
||||
void CloneInto(CaptureCommandList* aList) {
|
||||
void CloneInto(CaptureCommandList* aList) override
|
||||
{
|
||||
GlyphBuffer glyphs = {
|
||||
mGlyphs.data(),
|
||||
(uint32_t)mGlyphs.size(),
|
||||
@ -562,7 +573,7 @@ public:
|
||||
CLONE_INTO(FillGlyphsCommand)(mFont, glyphs, mPattern, mOptions);
|
||||
}
|
||||
|
||||
virtual void ExecuteOnDT(DrawTarget* aDT, const Matrix*) const
|
||||
virtual void ExecuteOnDT(DrawTarget* aDT, const Matrix*) const override
|
||||
{
|
||||
GlyphBuffer buf;
|
||||
buf.mNumGlyphs = mGlyphs.size();
|
||||
@ -597,7 +608,8 @@ public:
|
||||
memcpy(&mGlyphs.front(), aBuffer.mGlyphs, sizeof(Glyph) * aBuffer.mNumGlyphs);
|
||||
}
|
||||
|
||||
void CloneInto(CaptureCommandList* aList) {
|
||||
void CloneInto(CaptureCommandList* aList) override
|
||||
{
|
||||
GlyphBuffer glyphs = {
|
||||
mGlyphs.data(),
|
||||
(uint32_t)mGlyphs.size(),
|
||||
@ -605,7 +617,7 @@ public:
|
||||
CLONE_INTO(StrokeGlyphsCommand)(mFont, glyphs, mPattern, mStrokeOptions, mOptions);
|
||||
}
|
||||
|
||||
virtual void ExecuteOnDT(DrawTarget* aDT, const Matrix*) const
|
||||
virtual void ExecuteOnDT(DrawTarget* aDT, const Matrix*) const override
|
||||
{
|
||||
GlyphBuffer buf;
|
||||
buf.mNumGlyphs = mGlyphs.size();
|
||||
@ -635,11 +647,12 @@ public:
|
||||
{
|
||||
}
|
||||
|
||||
void CloneInto(CaptureCommandList* aList) {
|
||||
void CloneInto(CaptureCommandList* aList) override
|
||||
{
|
||||
CLONE_INTO(MaskCommand)(mSource, mMask, mOptions);
|
||||
}
|
||||
|
||||
virtual void ExecuteOnDT(DrawTarget* aDT, const Matrix*) const
|
||||
virtual void ExecuteOnDT(DrawTarget* aDT, const Matrix*) const override
|
||||
{
|
||||
aDT->Mask(mSource, mMask, mOptions);
|
||||
}
|
||||
@ -667,11 +680,12 @@ public:
|
||||
{
|
||||
}
|
||||
|
||||
void CloneInto(CaptureCommandList* aList) {
|
||||
void CloneInto(CaptureCommandList* aList) override
|
||||
{
|
||||
CLONE_INTO(MaskSurfaceCommand)(mSource, mMask, mOffset, mOptions);
|
||||
}
|
||||
|
||||
virtual void ExecuteOnDT(DrawTarget* aDT, const Matrix*) const
|
||||
virtual void ExecuteOnDT(DrawTarget* aDT, const Matrix*) const override
|
||||
{
|
||||
aDT->MaskSurface(mSource, mMask, mOffset, mOptions);
|
||||
}
|
||||
@ -694,11 +708,12 @@ public:
|
||||
{
|
||||
}
|
||||
|
||||
void CloneInto(CaptureCommandList* aList) {
|
||||
void CloneInto(CaptureCommandList* aList) override
|
||||
{
|
||||
CLONE_INTO(PushClipCommand)(mPath);
|
||||
}
|
||||
|
||||
virtual void ExecuteOnDT(DrawTarget* aDT, const Matrix*) const
|
||||
virtual void ExecuteOnDT(DrawTarget* aDT, const Matrix*) const override
|
||||
{
|
||||
aDT->PushClip(mPath);
|
||||
}
|
||||
@ -718,11 +733,12 @@ public:
|
||||
{
|
||||
}
|
||||
|
||||
void CloneInto(CaptureCommandList* aList) {
|
||||
void CloneInto(CaptureCommandList* aList) override
|
||||
{
|
||||
CLONE_INTO(PushClipRectCommand)(mRect);
|
||||
}
|
||||
|
||||
virtual void ExecuteOnDT(DrawTarget* aDT, const Matrix*) const
|
||||
virtual void ExecuteOnDT(DrawTarget* aDT, const Matrix*) const override
|
||||
{
|
||||
aDT->PushClipRect(mRect);
|
||||
}
|
||||
@ -752,11 +768,12 @@ public:
|
||||
{
|
||||
}
|
||||
|
||||
void CloneInto(CaptureCommandList* aList) {
|
||||
void CloneInto(CaptureCommandList* aList) override
|
||||
{
|
||||
CLONE_INTO(PushLayerCommand)(mOpaque, mOpacity, mMask, mMaskTransform, mBounds, mCopyBackground);
|
||||
}
|
||||
|
||||
virtual void ExecuteOnDT(DrawTarget* aDT, const Matrix*) const
|
||||
virtual void ExecuteOnDT(DrawTarget* aDT, const Matrix*) const override
|
||||
{
|
||||
aDT->PushLayer(mOpaque, mOpacity, mMask,
|
||||
mMaskTransform, mBounds, mCopyBackground);
|
||||
@ -781,11 +798,12 @@ public:
|
||||
{
|
||||
}
|
||||
|
||||
void CloneInto(CaptureCommandList* aList) {
|
||||
void CloneInto(CaptureCommandList* aList) override
|
||||
{
|
||||
CLONE_INTO(PopClipCommand)();
|
||||
}
|
||||
|
||||
virtual void ExecuteOnDT(DrawTarget* aDT, const Matrix*) const
|
||||
virtual void ExecuteOnDT(DrawTarget* aDT, const Matrix*) const override
|
||||
{
|
||||
aDT->PopClip();
|
||||
}
|
||||
@ -801,11 +819,12 @@ public:
|
||||
{
|
||||
}
|
||||
|
||||
void CloneInto(CaptureCommandList* aList) {
|
||||
void CloneInto(CaptureCommandList* aList) override
|
||||
{
|
||||
CLONE_INTO(PopLayerCommand)();
|
||||
}
|
||||
|
||||
virtual void ExecuteOnDT(DrawTarget* aDT, const Matrix*) const
|
||||
virtual void ExecuteOnDT(DrawTarget* aDT, const Matrix*) const override
|
||||
{
|
||||
aDT->PopLayer();
|
||||
}
|
||||
@ -823,11 +842,12 @@ public:
|
||||
{
|
||||
}
|
||||
|
||||
void CloneInto(CaptureCommandList* aList) {
|
||||
void CloneInto(CaptureCommandList* aList) override
|
||||
{
|
||||
CLONE_INTO(SetTransformCommand)(mTransform);
|
||||
}
|
||||
|
||||
virtual void ExecuteOnDT(DrawTarget* aDT, const Matrix* aMatrix) const
|
||||
virtual void ExecuteOnDT(DrawTarget* aDT, const Matrix* aMatrix) const override
|
||||
{
|
||||
if (aMatrix) {
|
||||
aDT->SetTransform(mTransform * (*aMatrix));
|
||||
@ -852,11 +872,12 @@ public:
|
||||
{
|
||||
}
|
||||
|
||||
void CloneInto(CaptureCommandList* aList) {
|
||||
void CloneInto(CaptureCommandList* aList) override
|
||||
{
|
||||
CLONE_INTO(SetPermitSubpixelAACommand)(mPermitSubpixelAA);
|
||||
}
|
||||
|
||||
virtual void ExecuteOnDT(DrawTarget* aDT, const Matrix* aMatrix) const
|
||||
virtual void ExecuteOnDT(DrawTarget* aDT, const Matrix* aMatrix) const override
|
||||
{
|
||||
aDT->SetPermitSubpixelAA(mPermitSubpixelAA);
|
||||
}
|
||||
@ -875,11 +896,12 @@ public:
|
||||
{
|
||||
}
|
||||
|
||||
void CloneInto(CaptureCommandList* aList) {
|
||||
void CloneInto(CaptureCommandList* aList) override
|
||||
{
|
||||
CLONE_INTO(FlushCommand)();
|
||||
}
|
||||
|
||||
virtual void ExecuteOnDT(DrawTarget* aDT, const Matrix*) const
|
||||
virtual void ExecuteOnDT(DrawTarget* aDT, const Matrix*) const override
|
||||
{
|
||||
aDT->Flush();
|
||||
}
|
||||
@ -895,11 +917,13 @@ public:
|
||||
, mBlur(aBlur)
|
||||
{}
|
||||
|
||||
void CloneInto(CaptureCommandList* aList) {
|
||||
void CloneInto(CaptureCommandList* aList) override
|
||||
{
|
||||
CLONE_INTO(BlurCommand)(mBlur);
|
||||
}
|
||||
|
||||
virtual void ExecuteOnDT(DrawTarget* aDT, const Matrix*) const {
|
||||
virtual void ExecuteOnDT(DrawTarget* aDT, const Matrix*) const override
|
||||
{
|
||||
aDT->Blur(mBlur);
|
||||
}
|
||||
|
||||
|
@ -25,10 +25,11 @@ class PathRecording;
|
||||
class DrawEventRecorderPrivate : public DrawEventRecorder
|
||||
{
|
||||
public:
|
||||
MOZ_DECLARE_REFCOUNTED_VIRTUAL_TYPENAME(DrawEventRecorderPrivate)
|
||||
MOZ_DECLARE_REFCOUNTED_VIRTUAL_TYPENAME(DrawEventRecorderPrivate, override)
|
||||
|
||||
DrawEventRecorderPrivate();
|
||||
virtual ~DrawEventRecorderPrivate() { }
|
||||
virtual void Finish() { ClearResources(); }
|
||||
virtual void Finish() override { ClearResources(); }
|
||||
virtual void FlushItem(IntRect) { }
|
||||
void DetatchResources() {
|
||||
// The iteration is a bit awkward here because our iterator will
|
||||
|
@ -21,7 +21,8 @@ class SourceSurfaceCairo;
|
||||
class GradientStopsCairo : public GradientStops
|
||||
{
|
||||
public:
|
||||
MOZ_DECLARE_REFCOUNTED_VIRTUAL_TYPENAME(GradientStopsCairo)
|
||||
MOZ_DECLARE_REFCOUNTED_VIRTUAL_TYPENAME(GradientStopsCairo, override)
|
||||
|
||||
GradientStopsCairo(GradientStop* aStops, uint32_t aNumStops,
|
||||
ExtendMode aExtendMode)
|
||||
: mExtendMode(aExtendMode)
|
||||
@ -43,7 +44,7 @@ class GradientStopsCairo : public GradientStops
|
||||
return mExtendMode;
|
||||
}
|
||||
|
||||
virtual BackendType GetBackendType() const { return BackendType::CAIRO; }
|
||||
virtual BackendType GetBackendType() const override { return BackendType::CAIRO; }
|
||||
|
||||
private:
|
||||
std::vector<GradientStop> mStops;
|
||||
|
@ -80,7 +80,8 @@ EnsureSurfaceStoredRecording(DrawEventRecorderPrivate *aRecorder, SourceSurface
|
||||
class SourceSurfaceRecording : public SourceSurface
|
||||
{
|
||||
public:
|
||||
MOZ_DECLARE_REFCOUNTED_VIRTUAL_TYPENAME(SourceSurfaceRecording)
|
||||
MOZ_DECLARE_REFCOUNTED_VIRTUAL_TYPENAME(SourceSurfaceRecording, override)
|
||||
|
||||
SourceSurfaceRecording(IntSize aSize, SurfaceFormat aFormat, DrawEventRecorderPrivate *aRecorder)
|
||||
: mSize(aSize), mFormat(aFormat), mRecorder(aRecorder)
|
||||
{
|
||||
@ -93,10 +94,10 @@ public:
|
||||
mRecorder->RecordEvent(RecordedSourceSurfaceDestruction(ReferencePtr(this)));
|
||||
}
|
||||
|
||||
virtual SurfaceType GetType() const { return SurfaceType::RECORDING; }
|
||||
virtual IntSize GetSize() const { return mSize; }
|
||||
virtual SurfaceFormat GetFormat() const { return mFormat; }
|
||||
virtual already_AddRefed<DataSourceSurface> GetDataSurface() { return nullptr; }
|
||||
virtual SurfaceType GetType() const override { return SurfaceType::RECORDING; }
|
||||
virtual IntSize GetSize() const override { return mSize; }
|
||||
virtual SurfaceFormat GetFormat() const override { return mFormat; }
|
||||
virtual already_AddRefed<DataSourceSurface> GetDataSurface() override { return nullptr; }
|
||||
|
||||
IntSize mSize;
|
||||
SurfaceFormat mFormat;
|
||||
@ -149,7 +150,8 @@ public:
|
||||
class GradientStopsRecording : public GradientStops
|
||||
{
|
||||
public:
|
||||
MOZ_DECLARE_REFCOUNTED_VIRTUAL_TYPENAME(GradientStopsRecording)
|
||||
MOZ_DECLARE_REFCOUNTED_VIRTUAL_TYPENAME(GradientStopsRecording, override)
|
||||
|
||||
explicit GradientStopsRecording(DrawEventRecorderPrivate *aRecorder)
|
||||
: mRecorder(aRecorder)
|
||||
{
|
||||
@ -162,7 +164,7 @@ public:
|
||||
mRecorder->RecordEvent(RecordedGradientStopsDestruction(ReferencePtr(this)));
|
||||
}
|
||||
|
||||
virtual BackendType GetBackendType() const { return BackendType::RECORDING; }
|
||||
virtual BackendType GetBackendType() const override { return BackendType::RECORDING; }
|
||||
|
||||
RefPtr<DrawEventRecorderPrivate> mRecorder;
|
||||
};
|
||||
|
@ -58,7 +58,8 @@ namespace gfx {
|
||||
class GradientStopsSkia : public GradientStops
|
||||
{
|
||||
public:
|
||||
MOZ_DECLARE_REFCOUNTED_VIRTUAL_TYPENAME(GradientStopsSkia)
|
||||
MOZ_DECLARE_REFCOUNTED_VIRTUAL_TYPENAME(GradientStopsSkia, override)
|
||||
|
||||
GradientStopsSkia(const std::vector<GradientStop>& aStops, uint32_t aNumStops, ExtendMode aExtendMode)
|
||||
: mCount(aNumStops)
|
||||
, mExtendMode(aExtendMode)
|
||||
@ -93,7 +94,7 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
BackendType GetBackendType() const { return BackendType::SKIA; }
|
||||
BackendType GetBackendType() const override { return BackendType::SKIA; }
|
||||
|
||||
std::vector<SkColor> mColors;
|
||||
std::vector<SkScalar> mPositions;
|
||||
|
@ -193,14 +193,14 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
virtual SurfaceType GetType() const { return SurfaceType::TILED; }
|
||||
virtual IntSize GetSize() const {
|
||||
virtual SurfaceType GetType() const override { return SurfaceType::TILED; }
|
||||
virtual IntSize GetSize() const override {
|
||||
MOZ_ASSERT(mRect.Width() > 0 && mRect.Height() > 0);
|
||||
return IntSize(mRect.XMost(), mRect.YMost());
|
||||
}
|
||||
virtual SurfaceFormat GetFormat() const { return mSnapshots[0]->GetFormat(); }
|
||||
virtual SurfaceFormat GetFormat() const override { return mSnapshots[0]->GetFormat(); }
|
||||
|
||||
virtual already_AddRefed<DataSourceSurface> GetDataSurface()
|
||||
virtual already_AddRefed<DataSourceSurface> GetDataSurface() override
|
||||
{
|
||||
RefPtr<DataSourceSurface> surf = Factory::CreateDataSourceSurface(GetSize(), GetFormat());
|
||||
if (!surf) {
|
||||
|
@ -80,7 +80,8 @@ EnsureSurfaceStored(DrawEventRecorderPrivate *aRecorder, SourceSurface *aSurface
|
||||
class SourceSurfaceWrapAndRecord : public SourceSurface
|
||||
{
|
||||
public:
|
||||
MOZ_DECLARE_REFCOUNTED_VIRTUAL_TYPENAME(SourceSurfaceWrapAndRecord)
|
||||
MOZ_DECLARE_REFCOUNTED_VIRTUAL_TYPENAME(SourceSurfaceWrapAndRecord, override)
|
||||
|
||||
SourceSurfaceWrapAndRecord(SourceSurface *aFinalSurface, DrawEventRecorderPrivate *aRecorder)
|
||||
: mFinalSurface(aFinalSurface), mRecorder(aRecorder)
|
||||
{
|
||||
@ -93,10 +94,10 @@ public:
|
||||
mRecorder->RecordEvent(RecordedSourceSurfaceDestruction(ReferencePtr(this)));
|
||||
}
|
||||
|
||||
virtual SurfaceType GetType() const { return SurfaceType::RECORDING; }
|
||||
virtual IntSize GetSize() const { return mFinalSurface->GetSize(); }
|
||||
virtual SurfaceFormat GetFormat() const { return mFinalSurface->GetFormat(); }
|
||||
virtual already_AddRefed<DataSourceSurface> GetDataSurface() { return mFinalSurface->GetDataSurface(); }
|
||||
virtual SurfaceType GetType() const override { return SurfaceType::RECORDING; }
|
||||
virtual IntSize GetSize() const override { return mFinalSurface->GetSize(); }
|
||||
virtual SurfaceFormat GetFormat() const override { return mFinalSurface->GetFormat(); }
|
||||
virtual already_AddRefed<DataSourceSurface> GetDataSurface() override { return mFinalSurface->GetDataSurface(); }
|
||||
|
||||
RefPtr<SourceSurface> mFinalSurface;
|
||||
RefPtr<DrawEventRecorderPrivate> mRecorder;
|
||||
@ -105,7 +106,8 @@ public:
|
||||
class GradientStopsWrapAndRecord : public GradientStops
|
||||
{
|
||||
public:
|
||||
MOZ_DECLARE_REFCOUNTED_VIRTUAL_TYPENAME(GradientStopsWrapAndRecord)
|
||||
MOZ_DECLARE_REFCOUNTED_VIRTUAL_TYPENAME(GradientStopsWrapAndRecord, override)
|
||||
|
||||
GradientStopsWrapAndRecord(GradientStops *aFinalGradientStops, DrawEventRecorderPrivate *aRecorder)
|
||||
: mFinalGradientStops(aFinalGradientStops), mRecorder(aRecorder)
|
||||
{
|
||||
@ -118,7 +120,7 @@ public:
|
||||
mRecorder->RecordEvent(RecordedGradientStopsDestruction(ReferencePtr(this)));
|
||||
}
|
||||
|
||||
virtual BackendType GetBackendType() const { return BackendType::RECORDING; }
|
||||
virtual BackendType GetBackendType() const override { return BackendType::RECORDING; }
|
||||
|
||||
RefPtr<GradientStops> mFinalGradientStops;
|
||||
RefPtr<DrawEventRecorderPrivate> mRecorder;
|
||||
|
@ -19,7 +19,8 @@ namespace gfx {
|
||||
class FilterNodeD2D1 : public FilterNode
|
||||
{
|
||||
public:
|
||||
MOZ_DECLARE_REFCOUNTED_VIRTUAL_TYPENAME(FilterNodeD2D1)
|
||||
MOZ_DECLARE_REFCOUNTED_VIRTUAL_TYPENAME(FilterNodeD2D1, override)
|
||||
|
||||
static already_AddRefed<FilterNode> Create(ID2D1DeviceContext *aDC, FilterType aType);
|
||||
|
||||
FilterNodeD2D1(ID2D1Effect *aEffect, FilterType aType)
|
||||
|
@ -17,7 +17,8 @@ namespace gfx {
|
||||
class GradientStopsD2D : public GradientStops
|
||||
{
|
||||
public:
|
||||
MOZ_DECLARE_REFCOUNTED_VIRTUAL_TYPENAME(GradientStopsD2D)
|
||||
MOZ_DECLARE_REFCOUNTED_VIRTUAL_TYPENAME(GradientStopsD2D, override)
|
||||
|
||||
GradientStopsD2D(ID2D1GradientStopCollection *aStopCollection, ID3D11Device *aDevice)
|
||||
: mStopCollection(aStopCollection)
|
||||
, mDevice(aDevice)
|
||||
|
@ -34,42 +34,42 @@ public:
|
||||
|
||||
bool TranslateRecording(char *, size_t len);
|
||||
|
||||
DrawTarget* LookupDrawTarget(ReferencePtr aRefPtr) final
|
||||
DrawTarget* LookupDrawTarget(ReferencePtr aRefPtr) final override
|
||||
{
|
||||
DrawTarget* result = mDrawTargets.GetWeak(aRefPtr);
|
||||
MOZ_ASSERT(result);
|
||||
return result;
|
||||
}
|
||||
|
||||
Path* LookupPath(ReferencePtr aRefPtr) final
|
||||
Path* LookupPath(ReferencePtr aRefPtr) final override
|
||||
{
|
||||
Path* result = mPaths.GetWeak(aRefPtr);
|
||||
MOZ_ASSERT(result);
|
||||
return result;
|
||||
}
|
||||
|
||||
SourceSurface* LookupSourceSurface(ReferencePtr aRefPtr) final
|
||||
SourceSurface* LookupSourceSurface(ReferencePtr aRefPtr) final override
|
||||
{
|
||||
SourceSurface* result = mSourceSurfaces.GetWeak(aRefPtr);
|
||||
MOZ_ASSERT(result);
|
||||
return result;
|
||||
}
|
||||
|
||||
FilterNode* LookupFilterNode(ReferencePtr aRefPtr) final
|
||||
FilterNode* LookupFilterNode(ReferencePtr aRefPtr) final override
|
||||
{
|
||||
FilterNode* result = mFilterNodes.GetWeak(aRefPtr);
|
||||
MOZ_ASSERT(result);
|
||||
return result;
|
||||
}
|
||||
|
||||
GradientStops* LookupGradientStops(ReferencePtr aRefPtr) final
|
||||
GradientStops* LookupGradientStops(ReferencePtr aRefPtr) final override
|
||||
{
|
||||
GradientStops* result = mGradientStops.GetWeak(aRefPtr);
|
||||
MOZ_ASSERT(result);
|
||||
return result;
|
||||
}
|
||||
|
||||
ScaledFont* LookupScaledFont(ReferencePtr aRefPtr) final
|
||||
ScaledFont* LookupScaledFont(ReferencePtr aRefPtr) final override
|
||||
{
|
||||
ScaledFont* result = mScaledFonts.GetWeak(aRefPtr);
|
||||
MOZ_ASSERT(result);
|
||||
@ -89,86 +89,86 @@ public:
|
||||
return result;
|
||||
}
|
||||
|
||||
NativeFontResource* LookupNativeFontResource(uint64_t aKey) final
|
||||
NativeFontResource* LookupNativeFontResource(uint64_t aKey) final override
|
||||
{
|
||||
NativeFontResource* result = mNativeFontResources.GetWeak(aKey);
|
||||
MOZ_ASSERT(result);
|
||||
return result;
|
||||
}
|
||||
|
||||
void AddDrawTarget(ReferencePtr aRefPtr, DrawTarget *aDT) final
|
||||
void AddDrawTarget(ReferencePtr aRefPtr, DrawTarget *aDT) final override
|
||||
{
|
||||
mDrawTargets.Put(aRefPtr, aDT);
|
||||
}
|
||||
|
||||
void AddPath(ReferencePtr aRefPtr, Path *aPath) final
|
||||
void AddPath(ReferencePtr aRefPtr, Path *aPath) final override
|
||||
{
|
||||
mPaths.Put(aRefPtr, aPath);
|
||||
}
|
||||
|
||||
void AddSourceSurface(ReferencePtr aRefPtr, SourceSurface *aSurface) final
|
||||
void AddSourceSurface(ReferencePtr aRefPtr, SourceSurface *aSurface) final override
|
||||
{
|
||||
mSourceSurfaces.Put(aRefPtr, aSurface);
|
||||
}
|
||||
|
||||
void AddFilterNode(ReferencePtr aRefPtr, FilterNode *aFilter) final
|
||||
void AddFilterNode(ReferencePtr aRefPtr, FilterNode *aFilter) final override
|
||||
{
|
||||
mFilterNodes.Put(aRefPtr, aFilter);
|
||||
}
|
||||
|
||||
void AddGradientStops(ReferencePtr aRefPtr, GradientStops *aStops) final
|
||||
void AddGradientStops(ReferencePtr aRefPtr, GradientStops *aStops) final override
|
||||
{
|
||||
mGradientStops.Put(aRefPtr, aStops);
|
||||
}
|
||||
|
||||
void AddScaledFont(ReferencePtr aRefPtr, ScaledFont *aScaledFont) final
|
||||
void AddScaledFont(ReferencePtr aRefPtr, ScaledFont *aScaledFont) final override
|
||||
{
|
||||
mScaledFonts.Put(aRefPtr, aScaledFont);
|
||||
}
|
||||
|
||||
void AddUnscaledFont(ReferencePtr aRefPtr, UnscaledFont *aUnscaledFont) final
|
||||
void AddUnscaledFont(ReferencePtr aRefPtr, UnscaledFont *aUnscaledFont) final override
|
||||
{
|
||||
mUnscaledFontTable.push_back(aUnscaledFont);
|
||||
mUnscaledFonts.Put(aRefPtr, aUnscaledFont);
|
||||
}
|
||||
|
||||
void AddNativeFontResource(uint64_t aKey,
|
||||
NativeFontResource *aScaledFontResouce) final
|
||||
NativeFontResource *aScaledFontResouce) final override
|
||||
{
|
||||
mNativeFontResources.Put(aKey, aScaledFontResouce);
|
||||
}
|
||||
|
||||
void RemoveDrawTarget(ReferencePtr aRefPtr) final
|
||||
void RemoveDrawTarget(ReferencePtr aRefPtr) final override
|
||||
{
|
||||
mDrawTargets.Remove(aRefPtr);
|
||||
}
|
||||
|
||||
void RemovePath(ReferencePtr aRefPtr) final
|
||||
void RemovePath(ReferencePtr aRefPtr) final override
|
||||
{
|
||||
mPaths.Remove(aRefPtr);
|
||||
}
|
||||
|
||||
void RemoveSourceSurface(ReferencePtr aRefPtr) final
|
||||
void RemoveSourceSurface(ReferencePtr aRefPtr) final override
|
||||
{
|
||||
mSourceSurfaces.Remove(aRefPtr);
|
||||
}
|
||||
|
||||
void RemoveFilterNode(ReferencePtr aRefPtr) final
|
||||
void RemoveFilterNode(ReferencePtr aRefPtr) final override
|
||||
{
|
||||
mFilterNodes.Remove(aRefPtr);
|
||||
}
|
||||
|
||||
void RemoveGradientStops(ReferencePtr aRefPtr) final
|
||||
void RemoveGradientStops(ReferencePtr aRefPtr) final override
|
||||
{
|
||||
mGradientStops.Remove(aRefPtr);
|
||||
}
|
||||
|
||||
void RemoveScaledFont(ReferencePtr aRefPtr) final
|
||||
void RemoveScaledFont(ReferencePtr aRefPtr) final override
|
||||
{
|
||||
mScaledFonts.Remove(aRefPtr);
|
||||
}
|
||||
|
||||
void RemoveUnscaledFont(ReferencePtr aRefPtr) final
|
||||
void RemoveUnscaledFont(ReferencePtr aRefPtr) final override
|
||||
{
|
||||
mUnscaledFonts.Remove(aRefPtr);
|
||||
}
|
||||
@ -176,11 +176,11 @@ public:
|
||||
|
||||
already_AddRefed<DrawTarget> CreateDrawTarget(ReferencePtr aRefPtr,
|
||||
const gfx::IntSize &aSize,
|
||||
gfx::SurfaceFormat aFormat) final;
|
||||
gfx::SurfaceFormat aFormat) final override;
|
||||
|
||||
mozilla::gfx::DrawTarget* GetReferenceDrawTarget() final { return mBaseDT; }
|
||||
mozilla::gfx::DrawTarget* GetReferenceDrawTarget() final override { return mBaseDT; }
|
||||
|
||||
void* GetFontContext() final { return mFontContext; }
|
||||
void* GetFontContext() final override { return mFontContext; }
|
||||
|
||||
private:
|
||||
RefPtr<DrawTarget> mBaseDT;
|
||||
|
@ -18,7 +18,8 @@ namespace gfx {
|
||||
class NativeFontResourceDWrite final : public NativeFontResource
|
||||
{
|
||||
public:
|
||||
MOZ_DECLARE_REFCOUNTED_VIRTUAL_TYPENAME(NativeFontResourceDWrite)
|
||||
MOZ_DECLARE_REFCOUNTED_VIRTUAL_TYPENAME(NativeFontResourceDWrite, override)
|
||||
|
||||
/**
|
||||
* Creates a NativeFontResourceDWrite if data is valid. Note aFontData will be
|
||||
* copied if required and so can be released after calling.
|
||||
@ -34,7 +35,7 @@ public:
|
||||
already_AddRefed<UnscaledFont>
|
||||
CreateUnscaledFont(uint32_t aIndex,
|
||||
const uint8_t* aInstanceData,
|
||||
uint32_t aInstanceDataLength) final;
|
||||
uint32_t aInstanceDataLength) final override;
|
||||
|
||||
private:
|
||||
NativeFontResourceDWrite(IDWriteFactory *aFactory,
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
x
Reference in New Issue
Block a user