Merge inbound to mozilla-central. a=merge

This commit is contained in:
shindli 2018-02-18 11:35:16 +02:00
Родитель dca25b1820 1401a05564
Коммит 6afe060566
207 изменённых файлов: 1109 добавлений и 1098 удалений

Просмотреть файл

@ -33,8 +33,8 @@ public:
NS_DECL_CYCLE_COLLECTING_ISUPPORTS;
NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_CLASS(AccessibleNode);
virtual JSObject* WrapObject(JSContext* aCx, JS::Handle<JSObject*> aGivenProto) override final;
virtual dom::ParentObject GetParentObject() const final;
JSObject* WrapObject(JSContext* aCx, JS::Handle<JSObject*> aGivenProto) final;
dom::ParentObject GetParentObject() const;
void GetRole(nsAString& aRole);
void GetStates(nsTArray<nsString>& aStates);

Просмотреть файл

@ -464,7 +464,7 @@ public:
NS_DECL_ISUPPORTS
NS_IMETHOD Notify(nsITimer* aTimer) final override
NS_IMETHOD Notify(nsITimer* aTimer) final
{
if (!mContent->IsInUncomposedDoc())
return NS_OK;
@ -488,7 +488,7 @@ public:
return NS_OK;
}
NS_IMETHOD GetName(nsACString& aName) final override
NS_IMETHOD GetName(nsACString& aName) final
{
aName.AssignLiteral("PluginTimerCallBack");
return NS_OK;

Просмотреть файл

@ -35,8 +35,8 @@ public:
// Accessible
virtual Accessible* ChildAtPoint(int32_t aX, int32_t aY,
EWhichChildAtPoint aWhichChild) override;
virtual bool InsertChildAt(uint32_t aIndex, Accessible* aChild) override final;
virtual bool RemoveChild(Accessible* aChild) override final;
bool InsertChildAt(uint32_t aIndex, Accessible* aChild) final;
bool RemoveChild(Accessible* aChild) final;
virtual bool IsAcceptableChild(nsIContent* aEl) const override;
@ -116,11 +116,11 @@ public:
explicit DummyAccessible(DocAccessible* aDocument = nullptr) :
AccessibleWrap(nullptr, aDocument) { }
virtual uint64_t NativeState() override final;
virtual uint64_t NativeInteractiveState() const override final;
virtual uint64_t NativeLinkState() const override final;
virtual bool NativelyUnavailable() const override final;
virtual void ApplyARIAState(uint64_t* aState) const override final;
uint64_t NativeState() final;
uint64_t NativeInteractiveState() const final;
uint64_t NativeLinkState() const final;
bool NativelyUnavailable() const final;
void ApplyARIAState(uint64_t* aState) const final;
protected:
virtual ~DummyAccessible() { }

Просмотреть файл

@ -77,15 +77,15 @@ public:
override;
virtual mozilla::ipc::IPCResult RecvHideEvent(const uint64_t& aRootID, const bool& aFromUser)
override;
virtual mozilla::ipc::IPCResult RecvStateChangeEvent(const uint64_t& aID,
const uint64_t& aState,
const bool& aEnabled) override final;
mozilla::ipc::IPCResult RecvStateChangeEvent(const uint64_t& aID,
const uint64_t& aState,
const bool& aEnabled) final;
virtual mozilla::ipc::IPCResult RecvCaretMoveEvent(const uint64_t& aID,
mozilla::ipc::IPCResult RecvCaretMoveEvent(const uint64_t& aID,
#if defined(XP_WIN)
const LayoutDeviceIntRect& aCaretRect,
const LayoutDeviceIntRect& aCaretRect,
#endif
const int32_t& aOffset) override final;
const int32_t& aOffset) final;
virtual mozilla::ipc::IPCResult RecvTextChangeEvent(const uint64_t& aID, const nsString& aStr,
const int32_t& aStart, const uint32_t& aLen,
@ -106,7 +106,7 @@ public:
const uint64_t& aWidgetID,
const uint32_t& aType) override;
virtual mozilla::ipc::IPCResult RecvRoleChangedEvent(const uint32_t& aRole) override final;
mozilla::ipc::IPCResult RecvRoleChangedEvent(const uint32_t& aRole) final;
virtual mozilla::ipc::IPCResult RecvBindChildDoc(PDocAccessibleParent* aChildDoc, const uint64_t& aID) override;

Просмотреть файл

@ -51,13 +51,13 @@ private:
#define DECL_IUNKNOWN \
public: \
virtual HRESULT STDMETHODCALLTYPE QueryInterface(REFIID, void**); \
virtual ULONG STDMETHODCALLTYPE AddRef() final \
ULONG STDMETHODCALLTYPE AddRef() final \
{ \
MOZ_ASSERT(int32_t(mRefCnt) >= 0, "illegal refcnt"); \
++mRefCnt; \
return mRefCnt; \
} \
virtual ULONG STDMETHODCALLTYPE Release() final \
ULONG STDMETHODCALLTYPE Release() final \
{ \
MOZ_ASSERT(int32_t(mRefCnt) > 0, "dup release"); \
--mRefCnt; \

Просмотреть файл

@ -25,68 +25,68 @@ class xpcAccessible : public nsIAccessible
{
public:
// nsIAccessible
NS_IMETHOD GetParent(nsIAccessible** aParent) final override;
NS_IMETHOD GetNextSibling(nsIAccessible** aNextSibling) final override;
NS_IMETHOD GetParent(nsIAccessible** aParent) final;
NS_IMETHOD GetNextSibling(nsIAccessible** aNextSibling) final;
NS_IMETHOD GetPreviousSibling(nsIAccessible** aPreviousSibling)
final override;
NS_IMETHOD GetFirstChild(nsIAccessible** aFirstChild) final override;
NS_IMETHOD GetLastChild(nsIAccessible** aLastChild) final override;
NS_IMETHOD GetChildCount(int32_t* aChildCount) final override;
final;
NS_IMETHOD GetFirstChild(nsIAccessible** aFirstChild) final;
NS_IMETHOD GetLastChild(nsIAccessible** aLastChild) final;
NS_IMETHOD GetChildCount(int32_t* aChildCount) final;
NS_IMETHOD GetChildAt(int32_t aChildIndex, nsIAccessible** aChild)
final override;
NS_IMETHOD GetChildren(nsIArray** aChildren) final override;
NS_IMETHOD GetIndexInParent(int32_t* aIndexInParent) final override;
final;
NS_IMETHOD GetChildren(nsIArray** aChildren) final;
NS_IMETHOD GetIndexInParent(int32_t* aIndexInParent) final;
NS_IMETHOD GetDOMNode(nsIDOMNode** aDOMNode) final override;
NS_IMETHOD GetId(nsAString& aID) final override;
NS_IMETHOD GetDocument(nsIAccessibleDocument** aDocument) final override;
NS_IMETHOD GetDOMNode(nsIDOMNode** aDOMNode) final;
NS_IMETHOD GetId(nsAString& aID) final;
NS_IMETHOD GetDocument(nsIAccessibleDocument** aDocument) final;
NS_IMETHOD GetRootDocument(nsIAccessibleDocument** aRootDocument)
final override;
final;
NS_IMETHOD GetRole(uint32_t* aRole) final override;
NS_IMETHOD GetRole(uint32_t* aRole) final;
NS_IMETHOD GetState(uint32_t* aState, uint32_t* aExtraState)
final override;
final;
NS_IMETHOD GetDescription(nsAString& aDescription) final override;
NS_IMETHOD GetName(nsAString& aName) final override;
NS_IMETHOD GetLanguage(nsAString& aLanguage) final override;
NS_IMETHOD GetValue(nsAString& aValue) final override;
NS_IMETHOD GetHelp(nsAString& aHelp) final override;
NS_IMETHOD GetDescription(nsAString& aDescription) final;
NS_IMETHOD GetName(nsAString& aName) final;
NS_IMETHOD GetLanguage(nsAString& aLanguage) final;
NS_IMETHOD GetValue(nsAString& aValue) final;
NS_IMETHOD GetHelp(nsAString& aHelp) final;
NS_IMETHOD GetAccessKey(nsAString& aAccessKey) final override;
NS_IMETHOD GetKeyboardShortcut(nsAString& aKeyBinding) final override;
NS_IMETHOD GetAccessKey(nsAString& aAccessKey) final;
NS_IMETHOD GetKeyboardShortcut(nsAString& aKeyBinding) final;
NS_IMETHOD GetAttributes(nsIPersistentProperties** aAttributes)
final override;
final;
NS_IMETHOD GetBounds(int32_t* aX, int32_t* aY,
int32_t* aWidth, int32_t* aHeight) final override;
int32_t* aWidth, int32_t* aHeight) final;
NS_IMETHOD GroupPosition(int32_t* aGroupLevel, int32_t* aSimilarItemsInGroup,
int32_t* aPositionInGroup) final override;
int32_t* aPositionInGroup) final;
NS_IMETHOD GetRelationByType(uint32_t aType,
nsIAccessibleRelation** aRelation)
final override;
NS_IMETHOD GetRelations(nsIArray** aRelations) final override;
final;
NS_IMETHOD GetRelations(nsIArray** aRelations) final;
NS_IMETHOD GetFocusedChild(nsIAccessible** aChild) final override;
NS_IMETHOD GetFocusedChild(nsIAccessible** aChild) final;
NS_IMETHOD GetChildAtPoint(int32_t aX, int32_t aY,
nsIAccessible** aAccessible) final override;
nsIAccessible** aAccessible) final;
NS_IMETHOD GetDeepestChildAtPoint(int32_t aX, int32_t aY,
nsIAccessible** aAccessible)
final override;
final;
NS_IMETHOD SetSelected(bool aSelect) final override;
NS_IMETHOD TakeSelection() final override;
NS_IMETHOD TakeFocus() final override;
NS_IMETHOD SetSelected(bool aSelect) final;
NS_IMETHOD TakeSelection() final;
NS_IMETHOD TakeFocus() final;
NS_IMETHOD GetActionCount(uint8_t* aActionCount) final override;
NS_IMETHOD GetActionName(uint8_t aIndex, nsAString& aName) final override;
NS_IMETHOD GetActionCount(uint8_t* aActionCount) final;
NS_IMETHOD GetActionName(uint8_t aIndex, nsAString& aName) final;
NS_IMETHOD GetActionDescription(uint8_t aIndex, nsAString& aDescription)
final override;
NS_IMETHOD DoAction(uint8_t aIndex) final override;
final;
NS_IMETHOD DoAction(uint8_t aIndex) final;
NS_IMETHOD ScrollTo(uint32_t aHow) final override;
NS_IMETHOD ScrollTo(uint32_t aHow) final;
NS_IMETHOD ScrollToPoint(uint32_t aCoordinateType,
int32_t aX, int32_t aY) final override;
int32_t aX, int32_t aY) final;
protected:
xpcAccessible() { }

Просмотреть файл

@ -27,10 +27,10 @@ public:
NS_DECL_ISUPPORTS_INHERITED
// nsIAccessibleApplication
NS_IMETHOD GetAppName(nsAString& aName) final override;
NS_IMETHOD GetAppVersion(nsAString& aVersion) final override;
NS_IMETHOD GetPlatformName(nsAString& aName) final override;
NS_IMETHOD GetPlatformVersion(nsAString& aVersion) final override;
NS_IMETHOD GetAppName(nsAString& aName) final;
NS_IMETHOD GetAppVersion(nsAString& aVersion) final;
NS_IMETHOD GetPlatformName(nsAString& aName) final;
NS_IMETHOD GetPlatformVersion(nsAString& aVersion) final;
protected:
virtual ~xpcAccessibleApplication()

Просмотреть файл

@ -34,20 +34,20 @@ public:
NS_DECL_ISUPPORTS_INHERITED
// nsIAccessibleDocument
NS_IMETHOD GetURL(nsAString& aURL) final override;
NS_IMETHOD GetTitle(nsAString& aTitle) final override;
NS_IMETHOD GetMimeType(nsAString& aType) final override;
NS_IMETHOD GetDocType(nsAString& aType) final override;
NS_IMETHOD GetDOMDocument(nsIDOMDocument** aDOMDocument) final override;
NS_IMETHOD GetWindow(mozIDOMWindowProxy** aDOMWindow) final override;
NS_IMETHOD GetURL(nsAString& aURL) final;
NS_IMETHOD GetTitle(nsAString& aTitle) final;
NS_IMETHOD GetMimeType(nsAString& aType) final;
NS_IMETHOD GetDocType(nsAString& aType) final;
NS_IMETHOD GetDOMDocument(nsIDOMDocument** aDOMDocument) final;
NS_IMETHOD GetWindow(mozIDOMWindowProxy** aDOMWindow) final;
NS_IMETHOD GetParentDocument(nsIAccessibleDocument** aDocument)
final override;
NS_IMETHOD GetChildDocumentCount(uint32_t* aCount) final override;
final;
NS_IMETHOD GetChildDocumentCount(uint32_t* aCount) final;
NS_IMETHOD GetChildDocumentAt(uint32_t aIndex,
nsIAccessibleDocument** aDocument)
final override;
final;
NS_IMETHOD GetVirtualCursor(nsIAccessiblePivot** aVirtualCursor)
final override;
final;
/**
* Return XPCOM wrapper for the internal accessible.

Просмотреть файл

@ -44,7 +44,7 @@ public:
NS_DECL_ISUPPORTS
// nsIAccessible
virtual Accessible* ToInternalAccessible() const final override;
Accessible* ToInternalAccessible() const final;
// xpcAccessibleGeneric
virtual void Shutdown();

Просмотреть файл

@ -23,13 +23,13 @@ class Accessible;
class xpcAccessibleHyperLink : public nsIAccessibleHyperLink
{
public:
NS_IMETHOD GetAnchorCount(int32_t* aAnchorCount) final override;
NS_IMETHOD GetStartIndex(int32_t* aStartIndex) final override;
NS_IMETHOD GetEndIndex(int32_t* aEndIndex) final override;
NS_IMETHOD GetURI(int32_t aIndex, nsIURI** aURI) final override;
NS_IMETHOD GetAnchorCount(int32_t* aAnchorCount) final;
NS_IMETHOD GetStartIndex(int32_t* aStartIndex) final;
NS_IMETHOD GetEndIndex(int32_t* aEndIndex) final;
NS_IMETHOD GetURI(int32_t aIndex, nsIURI** aURI) final;
NS_IMETHOD GetAnchor(int32_t aIndex, nsIAccessible** aAccessible)
final override;
NS_IMETHOD GetValid(bool* aValid) final override;
final;
NS_IMETHOD GetValid(bool* aValid) final;
protected:
xpcAccessibleHyperLink() { }

Просмотреть файл

@ -27,8 +27,8 @@ public:
NS_DECL_ISUPPORTS_INHERITED
NS_IMETHOD GetImagePosition(uint32_t aCoordType,
int32_t* aX, int32_t* aY) final override;
NS_IMETHOD GetImageSize(int32_t* aWidth, int32_t* aHeight) final override;
int32_t* aX, int32_t* aY) final;
NS_IMETHOD GetImageSize(int32_t* aWidth, int32_t* aHeight) final;
protected:
virtual ~xpcAccessibleImage() {}

Просмотреть файл

@ -25,17 +25,17 @@ class xpcAccessibleSelectable : public nsIAccessibleSelectable
{
public:
// nsIAccessibleSelectable
NS_IMETHOD GetSelectedItems(nsIArray** aSelectedItems) final override;
NS_IMETHOD GetSelectedItems(nsIArray** aSelectedItems) final;
NS_IMETHOD GetSelectedItemCount(uint32_t* aSelectedItemCount)
final override;
final;
NS_IMETHOD GetSelectedItemAt(uint32_t aIndex, nsIAccessible** aItem)
final override;
final;
NS_IMETHOD IsItemSelected(uint32_t aIndex, bool* aIsSelected)
final override;
NS_IMETHOD AddItemToSelection(uint32_t aIndex) final override;
NS_IMETHOD RemoveItemFromSelection(uint32_t aIndex) final override;
NS_IMETHOD SelectAll(bool* aIsMultiSelect) final override;
NS_IMETHOD UnselectAll() final override;
final;
NS_IMETHOD AddItemToSelection(uint32_t aIndex) final;
NS_IMETHOD RemoveItemFromSelection(uint32_t aIndex) final;
NS_IMETHOD SelectAll(bool* aIsMultiSelect) final;
NS_IMETHOD UnselectAll() final;
protected:
xpcAccessibleSelectable() { }

Просмотреть файл

@ -29,55 +29,55 @@ public:
NS_DECL_ISUPPORTS_INHERITED
// nsIAccessibleTable
NS_IMETHOD GetCaption(nsIAccessible** aCaption) final override;
NS_IMETHOD GetSummary(nsAString& aSummary) final override;
NS_IMETHOD GetColumnCount(int32_t* aColumnCount) final override;
NS_IMETHOD GetRowCount(int32_t* aRowCount) final override;
NS_IMETHOD GetCaption(nsIAccessible** aCaption) final;
NS_IMETHOD GetSummary(nsAString& aSummary) final;
NS_IMETHOD GetColumnCount(int32_t* aColumnCount) final;
NS_IMETHOD GetRowCount(int32_t* aRowCount) final;
NS_IMETHOD GetCellAt(int32_t aRowIndex, int32_t aColumnIndex,
nsIAccessible** aCell) final override;
nsIAccessible** aCell) final;
NS_IMETHOD GetCellIndexAt(int32_t aRowIndex, int32_t aColumnIndex,
int32_t* aCellIndex) final override;
int32_t* aCellIndex) final;
NS_IMETHOD GetColumnIndexAt(int32_t aCellIndex, int32_t* aColumnIndex)
final override;
final;
NS_IMETHOD GetRowIndexAt(int32_t aCellIndex, int32_t* aRowIndex)
final override;
final;
NS_IMETHOD GetRowAndColumnIndicesAt(int32_t aCellIndex, int32_t* aRowIndex,
int32_t* aColumnIndex)
final override;
final;
NS_IMETHOD GetColumnExtentAt(int32_t row, int32_t column,
int32_t* aColumnExtent) final override;
int32_t* aColumnExtent) final;
NS_IMETHOD GetRowExtentAt(int32_t row, int32_t column,
int32_t* aRowExtent) final override;
int32_t* aRowExtent) final;
NS_IMETHOD GetColumnDescription(int32_t aColIdx, nsAString& aDescription)
final override;
final;
NS_IMETHOD GetRowDescription(int32_t aRowIdx, nsAString& aDescription)
final override;
final;
NS_IMETHOD IsColumnSelected(int32_t aColIdx, bool* _retval)
final override;
final;
NS_IMETHOD IsRowSelected(int32_t aRowIdx, bool* _retval)
final override;
final;
NS_IMETHOD IsCellSelected(int32_t aRowIdx, int32_t aColIdx, bool* _retval)
final override;
final;
NS_IMETHOD GetSelectedCellCount(uint32_t* aSelectedCellCount)
final override;
final;
NS_IMETHOD GetSelectedColumnCount(uint32_t* aSelectedColumnCount)
final override;
final;
NS_IMETHOD GetSelectedRowCount(uint32_t* aSelectedRowCount)
final override;
NS_IMETHOD GetSelectedCells(nsIArray** aSelectedCell) final override;
final;
NS_IMETHOD GetSelectedCells(nsIArray** aSelectedCell) final;
NS_IMETHOD GetSelectedCellIndices(uint32_t* aCellsArraySize,
int32_t** aCellsArray)
final override;
final;
NS_IMETHOD GetSelectedColumnIndices(uint32_t* aColsArraySize,
int32_t** aColsArray)
final override;
final;
NS_IMETHOD GetSelectedRowIndices(uint32_t* aRowsArraySize,
int32_t** aRowsArray) final override;
NS_IMETHOD SelectColumn(int32_t aColIdx) final override;
NS_IMETHOD SelectRow(int32_t aRowIdx) final override;
NS_IMETHOD UnselectColumn(int32_t aColIdx) final override;
NS_IMETHOD UnselectRow(int32_t aRowIdx) final override;
NS_IMETHOD IsProbablyForLayout(bool* aIsForLayout) final override;
int32_t** aRowsArray) final;
NS_IMETHOD SelectColumn(int32_t aColIdx) final;
NS_IMETHOD SelectRow(int32_t aRowIdx) final;
NS_IMETHOD UnselectColumn(int32_t aColIdx) final;
NS_IMETHOD UnselectRow(int32_t aRowIdx) final;
NS_IMETHOD IsProbablyForLayout(bool* aIsForLayout) final;
protected:
virtual ~xpcAccessibleTable() {}

Просмотреть файл

@ -30,14 +30,14 @@ public:
NS_DECL_ISUPPORTS_INHERITED
// nsIAccessibleTableCell
NS_IMETHOD GetTable(nsIAccessibleTable** aTable) final override;
NS_IMETHOD GetColumnIndex(int32_t* aColIdx) final override;
NS_IMETHOD GetRowIndex(int32_t* aRowIdx) final override;
NS_IMETHOD GetColumnExtent(int32_t* aExtent) final override;
NS_IMETHOD GetRowExtent(int32_t* aExtent) final override;
NS_IMETHOD GetColumnHeaderCells(nsIArray** aHeaderCells) final override;
NS_IMETHOD GetRowHeaderCells(nsIArray** aHeaderCells) final override;
NS_IMETHOD IsSelected(bool* aSelected) final override;
NS_IMETHOD GetTable(nsIAccessibleTable** aTable) final;
NS_IMETHOD GetColumnIndex(int32_t* aColIdx) final;
NS_IMETHOD GetRowIndex(int32_t* aRowIdx) final;
NS_IMETHOD GetColumnExtent(int32_t* aExtent) final;
NS_IMETHOD GetRowExtent(int32_t* aExtent) final;
NS_IMETHOD GetColumnHeaderCells(nsIArray** aHeaderCells) final;
NS_IMETHOD GetRowHeaderCells(nsIArray** aHeaderCells) final;
NS_IMETHOD IsSelected(bool* aSelected) final;
protected:
virtual ~xpcAccessibleTableCell() {}

Просмотреть файл

@ -32,32 +32,32 @@ public:
NS_DECL_CYCLE_COLLECTING_ISUPPORTS
NS_DECL_CYCLE_COLLECTION_CLASS(xpcAccessibleTextRange)
NS_IMETHOD GetStartContainer(nsIAccessibleText** aAnchor) final override;
NS_IMETHOD GetStartOffset(int32_t* aOffset) final override;
NS_IMETHOD GetEndContainer(nsIAccessibleText** aAnchor) final override;
NS_IMETHOD GetEndOffset(int32_t* aOffset) final override;
NS_IMETHOD GetContainer(nsIAccessible** aContainer) final override;
NS_IMETHOD GetEmbeddedChildren(nsIArray** aList) final override;
NS_IMETHOD Compare(nsIAccessibleTextRange* aOtherRange, bool* aResult) final override;
NS_IMETHOD GetStartContainer(nsIAccessibleText** aAnchor) final;
NS_IMETHOD GetStartOffset(int32_t* aOffset) final;
NS_IMETHOD GetEndContainer(nsIAccessibleText** aAnchor) final;
NS_IMETHOD GetEndOffset(int32_t* aOffset) final;
NS_IMETHOD GetContainer(nsIAccessible** aContainer) final;
NS_IMETHOD GetEmbeddedChildren(nsIArray** aList) final;
NS_IMETHOD Compare(nsIAccessibleTextRange* aOtherRange, bool* aResult) final;
NS_IMETHOD CompareEndPoints(uint32_t aEndPoint,
nsIAccessibleTextRange* aOtherRange,
uint32_t aOtherRangeEndPoint,
int32_t* aResult) final override;
NS_IMETHOD GetText(nsAString& aText) final override;
NS_IMETHOD GetBounds(nsIArray** aRectList) final override;
NS_IMETHOD Move(uint32_t aUnit, int32_t aCount) final override;
NS_IMETHOD MoveStart(uint32_t aUnit, int32_t aCount) final override;
NS_IMETHOD MoveEnd(uint32_t aUnit, int32_t aCount) final override;
NS_IMETHOD Normalize(uint32_t aUnit) final override;
NS_IMETHOD Crop(nsIAccessible* aContainer, bool* aSuccess) final override;
int32_t* aResult) final;
NS_IMETHOD GetText(nsAString& aText) final;
NS_IMETHOD GetBounds(nsIArray** aRectList) final;
NS_IMETHOD Move(uint32_t aUnit, int32_t aCount) final;
NS_IMETHOD MoveStart(uint32_t aUnit, int32_t aCount) final;
NS_IMETHOD MoveEnd(uint32_t aUnit, int32_t aCount) final;
NS_IMETHOD Normalize(uint32_t aUnit) final;
NS_IMETHOD Crop(nsIAccessible* aContainer, bool* aSuccess) final;
NS_IMETHOD FindText(const nsAString& aText, bool aIsBackward, bool aIsIgnoreCase,
nsIAccessibleTextRange** aRange) final override;
nsIAccessibleTextRange** aRange) final;
NS_IMETHOD FindAttr(uint32_t aAttr, nsIVariant* aVal, bool aIsBackward,
nsIAccessibleTextRange** aRange) final override;
NS_IMETHOD AddToSelection() final override;
NS_IMETHOD RemoveFromSelection() final override;
NS_IMETHOD Select() final override;
NS_IMETHOD ScrollIntoView(uint32_t aHow) final override;
nsIAccessibleTextRange** aRange) final;
NS_IMETHOD AddToSelection() final;
NS_IMETHOD RemoveFromSelection() final;
NS_IMETHOD Select() final;
NS_IMETHOD ScrollIntoView(uint32_t aHow) final;
NS_DECLARE_STATIC_IID_ACCESSOR(NS_ACCESSIBLETEXTRANGE_IMPL_IID)

Просмотреть файл

@ -21,11 +21,11 @@ class Accessible;
class xpcAccessibleValue : public nsIAccessibleValue
{
public:
NS_IMETHOD GetMaximumValue(double* aValue) final override;
NS_IMETHOD GetMinimumValue(double* aValue) final override;
NS_IMETHOD GetCurrentValue(double* aValue) final override;
NS_IMETHOD SetCurrentValue(double aValue) final override;
NS_IMETHOD GetMinimumIncrement(double* aMinIncrement) final override;
NS_IMETHOD GetMaximumValue(double* aValue) final;
NS_IMETHOD GetMinimumValue(double* aValue) final;
NS_IMETHOD GetCurrentValue(double* aValue) final;
NS_IMETHOD SetCurrentValue(double aValue) final;
NS_IMETHOD GetMinimumIncrement(double* aMinIncrement) final;
protected:
xpcAccessibleValue() { }

Просмотреть файл

@ -90,8 +90,8 @@ public:
virtual uint32_t ChildCount() const override;
// XULTreeItemAccessibleBase
virtual XULTreeGridCellAccessible* GetCellAccessible(nsITreeColumn* aColumn)
const override final;
XULTreeGridCellAccessible* GetCellAccessible(nsITreeColumn* aColumn)
const final;
virtual void RowInvalidated(int32_t aStartColIdx, int32_t aEndColIdx) override;
protected:

Просмотреть файл

@ -1,6 +1,4 @@
[DEFAULT]
prefs =
dom.animations-api.core.enabled=true
support-files =
head.js
head_pageAction.js
@ -212,4 +210,3 @@ tags = fullscreen
skip-if = os == 'mac' # Fails when windows are randomly opened in fullscreen mode
[browser_ext_windows_update.js]
tags = fullscreen
[browser_ext_contentscript_animate.js]

Просмотреть файл

@ -1,95 +0,0 @@
/* -*- Mode: indent-tabs-mode: nil; js-indent-level: 2 -*- */
/* vim: set sts=2 sw=2 et tw=80: */
"use strict";
add_task(async function test_animate() {
let tab = await BrowserTestUtils.openNewForegroundTab(gBrowser, "http://mochi.test:8888/");
let extension = ExtensionTestUtils.loadExtension({
manifest: {
"content_scripts": [
{
"matches": ["http://mochi.test/*"],
"js": ["content-script.js"],
},
],
},
files: {
"content-script.js": function() {
let elem = document.getElementsByTagName("body")[0];
elem.style.border = "2px solid red";
let anim = elem.animate({opacity: [1, 0]}, 2000);
let frames = anim.effect.getKeyframes();
browser.test.assertEq(frames.length, 2,
"frames for Element.animate should be non-zero");
browser.test.assertEq(frames[0].opacity, "1",
"first frame opacity for Element.animate should be specified value");
browser.test.assertEq(frames[0].computedOffset, 0,
"first frame offset for Element.animate should be 0");
browser.test.assertEq(frames[1].opacity, "0",
"last frame opacity for Element.animate should be specified value");
browser.test.assertEq(frames[1].computedOffset, 1,
"last frame offset for Element.animate should be 1");
browser.test.notifyPass("contentScriptAnimate");
},
},
});
await extension.startup();
await extension.awaitFinish("contentScriptAnimate");
await extension.unload();
await BrowserTestUtils.removeTab(tab);
});
add_task(async function test_KeyframeEffect() {
let tab = await BrowserTestUtils.openNewForegroundTab(gBrowser, "http://mochi.test:8888/");
let extension = ExtensionTestUtils.loadExtension({
manifest: {
"content_scripts": [
{
"matches": ["http://mochi.test/*"],
"js": ["content-script.js"],
},
],
},
files: {
"content-script.js": function() {
let elem = document.getElementsByTagName("body")[0];
elem.style.border = "2px solid red";
let effect = new KeyframeEffect(elem, [
{opacity: 1, offset: 0},
{opacity: 0, offset: 1},
], {duration: 1000, fill: "forwards"});
let frames = effect.getKeyframes();
browser.test.assertEq(frames.length, 2,
"frames for KeyframeEffect ctor should be non-zero");
browser.test.assertEq(frames[0].opacity, "1",
"first frame opacity for KeyframeEffect ctor should be specified value");
browser.test.assertEq(frames[0].computedOffset, 0,
"first frame offset for KeyframeEffect ctor should be 0");
browser.test.assertEq(frames[1].opacity, "0",
"last frame opacity for KeyframeEffect ctor should be specified value");
browser.test.assertEq(frames[1].computedOffset, 1,
"last frame offset for KeyframeEffect ctor should be 1");
let animation = new Animation(effect, document.timeline);
animation.play();
browser.test.notifyPass("contentScriptKeyframeEffect");
},
},
});
await extension.startup();
await extension.awaitFinish("contentScriptKeyframeEffect");
await extension.unload();
await BrowserTestUtils.removeTab(tab);
});

Просмотреть файл

@ -36,7 +36,7 @@ struct E {
virtual void e();
};
struct F : E {
virtual void e() final override;
void e() final;
};
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 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 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 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 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;
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;
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 override { return mOriginAttributes; }
const OriginAttributes& OriginAttributesRef() final { 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 override;
bool write(JSContext* aCx, JSStructuredCloneWriter* aWriter) final;
/*
* Get a weak reference to nsIPrincipal associated with the given JS

Просмотреть файл

@ -252,13 +252,13 @@ public:
new (storage) Concrete(ptr);
}
CoarseType coarseType() const final override { return get().coarseType; }
CoarseType coarseType() const final { 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 override { return get().scriptFilename; }
const char* scriptFilename() const final { return get().scriptFilename; }
bool hasAllocationStack() const override { return get().allocationStack.isSome(); }
StackFrame allocationStack() const override;

Просмотреть файл

@ -1255,14 +1255,14 @@ public:
~StreamWriter() override { }
virtual bool writeMetadata(uint64_t timestamp) final override {
bool writeMetadata(uint64_t timestamp) final {
protobuf::Metadata metadata;
metadata.set_timestamp(timestamp);
return writeMessage(metadata);
}
virtual bool writeNode(const JS::ubi::Node& ubiNode,
EdgePolicy includeEdges) override final {
bool writeNode(const JS::ubi::Node& ubiNode,
EdgePolicy includeEdges) final {
// NB: de-duplicated string properties must be written in the same order
// here as they are read in `HeapSnapshot::saveNode` or else indices in
// references to already serialized strings will be off.

Просмотреть файл

@ -49,16 +49,6 @@ AnimationUtils::GetCurrentRealmDocument(JSContext* aCx)
return win->GetDoc();
}
/* static */ nsIDocument*
AnimationUtils::GetDocumentFromGlobal(JSObject* aGlobalObject)
{
nsGlobalWindowInner* win = xpc::WindowOrNull(aGlobalObject);
if (!win) {
return nullptr;
}
return win->GetDoc();
}
/* static */ bool
AnimationUtils::IsOffscreenThrottlingEnabled()
{

Просмотреть файл

@ -61,14 +61,6 @@ public:
static nsIDocument*
GetCurrentRealmDocument(JSContext* aCx);
/**
* Get the document from the global object, or nullptr if the document has
* no window, to use when constructing DOM object without entering the
* target window's compartment (see KeyframeEffect constructor).
*/
static nsIDocument*
GetDocumentFromGlobal(JSObject* aGlobalObject);
/**
* Checks if offscreen animation throttling is enabled.
*/

Просмотреть файл

@ -903,17 +903,7 @@ KeyframeEffectReadOnly::ConstructKeyframeEffect(
const OptionsType& aOptions,
ErrorResult& aRv)
{
// We should get the document from `aGlobal` instead of the current Realm
// to make this works in Xray case.
//
// In all non-Xray cases, `aGlobal` matches the current Realm, so this
// matches the spec behavior.
//
// In Xray case, the new objects should be created using the document of
// the target global, but KeyframeEffect and KeyframeEffectReadOnly
// constructors are called in the caller's compartment to access
// `aKeyframes` object.
nsIDocument* doc = AnimationUtils::GetDocumentFromGlobal(aGlobal.Get());
nsIDocument* doc = AnimationUtils::GetCurrentRealmDocument(aGlobal.Context());
if (!doc) {
aRv.Throw(NS_ERROR_FAILURE);
return nullptr;

Просмотреть файл

@ -8,7 +8,6 @@ support-files =
[chrome/test_animate_xrays.html]
# file_animate_xrays.html needs to go in mochitest.ini since it is served
# over HTTP
[chrome/test_keyframe_effect_xrays.html]
[chrome/test_animation_observers_async.html]
[chrome/test_animation_observers_sync.html]
[chrome/test_animation_performance_warning.html]

Просмотреть файл

@ -6,9 +6,10 @@
Element.prototype.animate = function() {
throw 'Called animate() as defined in content document';
}
for (let name of ["KeyframeEffect", "KeyframeEffectReadOnly", "Animation"]) {
this[name] = function() {
throw `Called overridden ${name} constructor`;
// Bug 1211783: Use KeyframeEffect (not KeyframeEffectReadOnly) here
for (var obj of [KeyframeEffectReadOnly, Animation]) {
obj = function() {
throw 'Called overridden ' + String(obj) + ' constructor';
};
}
</script>

Просмотреть файл

@ -6,8 +6,8 @@
<script type="application/javascript" src="../testcommon.js"></script>
</head>
<body>
<a href="https://bugzilla.mozilla.org/show_bug.cgi?id=1414674"
target="_blank">Mozilla Bug 1414674</a>
<a href="https://bugzilla.mozilla.org/show_bug.cgi?id=1045994"
target="_blank">Mozilla Bug 1045994</a>
<div id="log"></div>
<iframe id="iframe"
src="http://example.org/tests/dom/animation/test/chrome/file_animate_xrays.html"></iframe>
@ -19,19 +19,10 @@ var win = document.getElementById('iframe').contentWindow;
async_test(function(t) {
window.addEventListener('load', t.step_func(function() {
var target = win.document.getElementById('target');
var anim = target.animate({opacity: [ 1, 0 ]}, 100 * MS_PER_SEC);
// The frames object should be accessible via x-ray.
var frames = anim.effect.getKeyframes();
assert_equals(frames.length, 2,
"frames for Element.animate should be non-zero");
assert_equals(frames[0].opacity, "1",
"first frame opacity for Element.animate should be specified value");
assert_equals(frames[0].computedOffset, 0,
"first frame offset for Element.animate should be 0");
assert_equals(frames[1].opacity, "0",
"last frame opacity for Element.animate should be specified value");
assert_equals(frames[1].computedOffset, 1,
"last frame offset for Element.animate should be 1");
var anim = target.animate({ opacity: [ 0, 1 ] }, 100 * MS_PER_SEC);
// In the x-ray case, the frames object will be given an opaque wrapper
// so it won't be possible to fetch any frames from it.
assert_equals(anim.effect.getKeyframes().length, 0);
t.done();
}));
}, 'Calling animate() across x-rays');

Просмотреть файл

@ -1,45 +0,0 @@
<!doctype html>
<head>
<meta charset=utf-8>
<script type="application/javascript" src="../testharness.js"></script>
<script type="application/javascript" src="../testharnessreport.js"></script>
<script type="application/javascript" src="../testcommon.js"></script>
</head>
<body>
<a href="https://bugzilla.mozilla.org/show_bug.cgi?id=1414674"
target="_blank">Mozilla Bug 1414674</a>
<div id="log"></div>
<iframe id="iframe"
src="http://example.org/tests/dom/animation/test/chrome/file_animate_xrays.html"></iframe>
<script>
'use strict';
var win = document.getElementById('iframe').contentWindow;
async_test(function(t) {
window.addEventListener('load', t.step_func(function() {
var target = win.document.getElementById('target');
var effect = new win.KeyframeEffect(target, [
{opacity: 1, offset: 0},
{opacity: 0, offset: 1},
], {duration: 100 * MS_PER_SEC, fill: "forwards"});
// The frames object should be accessible via x-ray.
var frames = effect.getKeyframes();
assert_equals(frames.length, 2,
"frames for KeyframeEffect ctor should be non-zero");
assert_equals(frames[0].opacity, "1",
"first frame opacity for KeyframeEffect ctor should be specified value");
assert_equals(frames[0].computedOffset, 0,
"first frame offset for KeyframeEffect ctor should be 0");
assert_equals(frames[1].opacity, "0",
"last frame opacity for KeyframeEffect ctor should be specified value");
assert_equals(frames[1].computedOffset, 1,
"last frame offset for KeyframeEffect ctor should be 1");
var animation = new win.Animation(effect, document.timeline);
animation.play();
t.done();
}));
}, 'Calling KeyframeEffect() ctor across x-rays');
</script>
</body>

Просмотреть файл

@ -3804,23 +3804,22 @@ Element::Animate(const Nullable<ElementOrCSSPseudoElement>& aTarget,
GlobalObject global(aContext, ownerGlobal->GetGlobalJSObject());
MOZ_ASSERT(!global.Failed());
// KeyframeEffect constructor doesn't follow the standard Xray calling
// convention and needs to be called in caller's compartment.
// This should match to RunConstructorInCallerCompartment attribute in
// KeyframeEffect.webidl.
RefPtr<KeyframeEffect> effect =
KeyframeEffect::Constructor(global, aTarget, aKeyframes, aOptions,
aError);
if (aError.Failed()) {
return nullptr;
}
// Animation constructor follows the standard Xray calling convention and
// needs to be called in the target element's compartment.
// Wrap the aKeyframes object for the cross-compartment case.
JS::Rooted<JSObject*> keyframes(aContext);
keyframes = aKeyframes;
Maybe<JSAutoCompartment> ac;
if (js::GetContextCompartment(aContext) !=
js::GetObjectCompartment(ownerGlobal->GetGlobalJSObject())) {
ac.emplace(aContext, ownerGlobal->GetGlobalJSObject());
if (!JS_WrapObject(aContext, &keyframes)) {
return nullptr;
}
}
RefPtr<KeyframeEffect> effect =
KeyframeEffect::Constructor(global, aTarget, keyframes, aOptions, aError);
if (aError.Failed()) {
return nullptr;
}
AnimationTimeline* timeline = referenceElement->OwnerDoc()->Timeline();

Просмотреть файл

@ -1567,7 +1567,7 @@ public:
*/
static CORSMode AttrValueToCORSMode(const nsAttrValue* aValue);
virtual JSObject* WrapObject(JSContext *aCx, JS::Handle<JSObject*> aGivenProto) final override;
JSObject* WrapObject(JSContext *aCx, JS::Handle<JSObject*> aGivenProto) final;
nsINode* GetScopeChainParent() const override;

Просмотреть файл

@ -247,8 +247,8 @@ public:
nsExtendedDOMSlots();
~nsExtendedDOMSlots() final;
void Traverse(nsCycleCollectionTraversalCallback&) final override;
void Unlink() final override;
void Traverse(nsCycleCollectionTraversalCallback&) final;
void Unlink() final;
/**
* SMIL Overridde style rules (for SMIL animation of CSS properties)
@ -299,8 +299,8 @@ public:
nsDOMSlots();
~nsDOMSlots() final;
void Traverse(nsCycleCollectionTraversalCallback&) final override;
void Unlink() final override;
void Traverse(nsCycleCollectionTraversalCallback&) final;
void Unlink() final;
size_t SizeOfIncludingThis(mozilla::MallocSizeOf aMallocSizeOf) const;
@ -344,7 +344,7 @@ protected:
return new nsDOMSlots();
}
nsIContent::nsExtendedContentSlots* CreateExtendedSlots() final override
nsIContent::nsExtendedContentSlots* CreateExtendedSlots() final
{
return new nsExtendedDOMSlots();
}

Просмотреть файл

@ -29,7 +29,7 @@ public:
explicit StyleSheetList(DocumentOrShadowRoot& aScope);
virtual JSObject* WrapObject(JSContext* aCx, JS::Handle<JSObject*> aGivenProto) override final;
JSObject* WrapObject(JSContext* aCx, JS::Handle<JSObject*> aGivenProto) final;
nsINode* GetParentObject() const
{

Просмотреть файл

@ -60,14 +60,14 @@ public:
NS_DECL_ISUPPORTS
NS_IMETHOD GetType(nsACString& aType) override final
NS_IMETHOD GetType(nsACString& aType) final
{
aType = mType;
return NS_OK;
}
// "notify-text-change" and "notify-selection-change"
NS_IMETHOD GetOffset(uint32_t* aOffset) override final
NS_IMETHOD GetOffset(uint32_t* aOffset) final
{
if (NS_WARN_IF(!aOffset)) {
return NS_ERROR_INVALID_ARG;
@ -84,7 +84,7 @@ public:
}
// "notify-selection-change"
NS_IMETHOD GetText(nsAString& aText) override final
NS_IMETHOD GetText(nsAString& aText) final
{
if (IsSelectionChange()) {
aText = mSelectionChangeData.String();
@ -93,7 +93,7 @@ public:
return NS_ERROR_NOT_AVAILABLE;
}
NS_IMETHOD GetCollapsed(bool* aCollapsed) override final
NS_IMETHOD GetCollapsed(bool* aCollapsed) final
{
if (NS_WARN_IF(!aCollapsed)) {
return NS_ERROR_INVALID_ARG;
@ -105,7 +105,7 @@ public:
return NS_ERROR_NOT_AVAILABLE;
}
NS_IMETHOD GetLength(uint32_t* aLength) override final
NS_IMETHOD GetLength(uint32_t* aLength) final
{
if (NS_WARN_IF(!aLength)) {
return NS_ERROR_INVALID_ARG;
@ -117,7 +117,7 @@ public:
return NS_ERROR_NOT_AVAILABLE;
}
NS_IMETHOD GetReversed(bool* aReversed) override final
NS_IMETHOD GetReversed(bool* aReversed) final
{
if (NS_WARN_IF(!aReversed)) {
return NS_ERROR_INVALID_ARG;
@ -129,7 +129,7 @@ public:
return NS_ERROR_NOT_AVAILABLE;
}
NS_IMETHOD GetWritingMode(nsACString& aWritingMode) override final
NS_IMETHOD GetWritingMode(nsACString& aWritingMode) final
{
if (IsSelectionChange()) {
WritingMode writingMode = mSelectionChangeData.GetWritingMode();
@ -145,7 +145,7 @@ public:
return NS_ERROR_NOT_AVAILABLE;
}
NS_IMETHOD GetCausedByComposition(bool* aCausedByComposition) override final
NS_IMETHOD GetCausedByComposition(bool* aCausedByComposition) final
{
if (NS_WARN_IF(!aCausedByComposition)) {
return NS_ERROR_INVALID_ARG;
@ -158,7 +158,7 @@ public:
}
NS_IMETHOD GetCausedBySelectionEvent(
bool* aCausedBySelectionEvent) override final
bool* aCausedBySelectionEvent) final
{
if (NS_WARN_IF(!aCausedBySelectionEvent)) {
return NS_ERROR_INVALID_ARG;
@ -171,7 +171,7 @@ public:
}
NS_IMETHOD GetOccurredDuringComposition(
bool* aOccurredDuringComposition) override final
bool* aOccurredDuringComposition) final
{
if (NS_WARN_IF(!aOccurredDuringComposition)) {
return NS_ERROR_INVALID_ARG;
@ -185,7 +185,7 @@ public:
}
// "notify-text-change"
NS_IMETHOD GetRemovedLength(uint32_t* aLength) override final
NS_IMETHOD GetRemovedLength(uint32_t* aLength) final
{
if (NS_WARN_IF(!aLength)) {
return NS_ERROR_INVALID_ARG;
@ -197,7 +197,7 @@ public:
return NS_ERROR_NOT_AVAILABLE;
}
NS_IMETHOD GetAddedLength(uint32_t* aLength) override final
NS_IMETHOD GetAddedLength(uint32_t* aLength) final
{
if (NS_WARN_IF(!aLength)) {
return NS_ERROR_INVALID_ARG;
@ -210,7 +210,7 @@ public:
}
NS_IMETHOD GetCausedOnlyByComposition(
bool* aCausedOnlyByComposition) override final
bool* aCausedOnlyByComposition) final
{
if (NS_WARN_IF(!aCausedOnlyByComposition)) {
return NS_ERROR_INVALID_ARG;
@ -223,7 +223,7 @@ public:
}
NS_IMETHOD GetIncludingChangesDuringComposition(
bool* aIncludingChangesDuringComposition) override final
bool* aIncludingChangesDuringComposition) final
{
if (NS_WARN_IF(!aIncludingChangesDuringComposition)) {
return NS_ERROR_INVALID_ARG;
@ -237,7 +237,7 @@ public:
}
NS_IMETHOD GetIncludingChangesWithoutComposition(
bool* aIncludingChangesWithoutComposition) override final
bool* aIncludingChangesWithoutComposition) final
{
if (NS_WARN_IF(!aIncludingChangesWithoutComposition)) {
return NS_ERROR_INVALID_ARG;

Просмотреть файл

@ -172,7 +172,7 @@ public:
nsWrapperCache::PreserveWrapper(aScriptObjectHolder);
}
virtual uint32_t Length() override final
uint32_t Length() final
{
return 0;
}
@ -346,7 +346,7 @@ public:
return mRootNode;
}
virtual uint32_t Length() override final
uint32_t Length() final
{
return Length(true);
}

Просмотреть файл

@ -87,8 +87,7 @@ public:
return GetOffsetNode();
}
virtual JSObject* WrapObject(JSContext *aCx, JS::Handle<JSObject*> aGivenProto)
override final;
JSObject* WrapObject(JSContext *aCx, JS::Handle<JSObject*> aGivenProto) final;
protected:
virtual ~nsDOMCaretPosition();
@ -98,4 +97,3 @@ protected:
nsCOMPtr<nsINode> mAnonymousContentNode;
};
#endif

Просмотреть файл

@ -10536,7 +10536,7 @@ public:
{
}
NS_IMETHOD Run() override final
NS_IMETHOD Run() final
{
if (!mDoc) {
FullscreenRoots::ForEach(&AskWindowToExitFullscreen);
@ -11543,7 +11543,7 @@ public:
, mUserInputOrChromeCaller(aUserInputOrChromeCaller)
{}
NS_IMETHOD Run() final override;
NS_IMETHOD Run() final;
private:
nsWeakPtr mElement;

Просмотреть файл

@ -413,7 +413,7 @@ public:
already_AddRefed<nsIPresShell> CreateShell(nsPresContext* aContext,
nsViewManager* aViewManager,
mozilla::StyleSetHandle aStyleSet)
final override;
final;
virtual void DeleteShell() override;
virtual bool GetAllowPlugins() override;
@ -714,7 +714,7 @@ public:
nsSMILAnimationController* GetAnimationController() override;
virtual mozilla::PendingAnimationTracker*
GetPendingAnimationTracker() final override
GetPendingAnimationTracker() final
{
return mPendingAnimationTracker;
}

Просмотреть файл

@ -148,7 +148,7 @@ public:
virtual nsresult AppendText(const char16_t* aBuffer, uint32_t aLength,
bool aNotify) override;
virtual bool TextIsOnlyWhitespace() override;
virtual bool ThreadSafeTextIsOnlyWhitespace() const final override;
bool ThreadSafeTextIsOnlyWhitespace() const final;
virtual bool HasTextForTranslation() override;
virtual void AppendTextTo(nsAString& aResult) override;
MOZ_MUST_USE

Просмотреть файл

@ -348,10 +348,10 @@ public:
friend class FullscreenTransitionTask;
// Outer windows only.
virtual nsresult SetFullscreenInternal(
FullscreenReason aReason, bool aIsFullscreen) override final;
virtual void FullscreenWillChange(bool aIsFullscreen) override final;
virtual void FinishFullscreenChange(bool aIsFullscreen) override final;
nsresult SetFullscreenInternal(
FullscreenReason aReason, bool aIsFullscreen) final;
void FullscreenWillChange(bool aIsFullscreen) final;
void FinishFullscreenChange(bool aIsFullscreen) final;
bool SetWidgetFullscreen(FullscreenReason aReason, bool aIsFullscreen,
nsIWidget* aWidget, nsIScreen* aScreen);
bool FullScreen() const;

Просмотреть файл

@ -372,7 +372,7 @@ public:
nsIContent* aContainer);
nsINode* GetParentObject() const { return mOwner; }
virtual JSObject* WrapObject(JSContext* cx, JS::Handle<JSObject*> aGivenProto) override final;
JSObject* WrapObject(JSContext* cx, JS::Handle<JSObject*> aGivenProto) final;
DocGroup* GetDocGroup() const;
private:

Просмотреть файл

@ -7806,10 +7806,7 @@ class CGPerSignatureCall(CGThing):
needsUnwrap = False
argsPost = []
runConstructorInCallerCompartment = \
descriptor.interface.getExtendedAttribute(
'RunConstructorInCallerCompartment')
if isConstructor and not runConstructorInCallerCompartment:
if isConstructor:
needsUnwrap = True
needsUnwrappedVar = False
unwrappedVar = "obj"

Просмотреть файл

@ -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 override
void UnlinkHelper() final
{
mIterableObj = nullptr;
}

Просмотреть файл

@ -1743,7 +1743,6 @@ class IDLInterface(IDLInterfaceOrNamespace):
identifier == "LegacyEventInit" or
identifier == "ProbablyShortLivingWrapper" or
identifier == "LegacyUnenumerableNamedProperties" or
identifier == "RunConstructorInCallerCompartment" or
identifier == "NonOrdinaryGetPrototypeOf"):
# Known extended attributes that do not take values
if not attr.noArguments():

Просмотреть файл

@ -179,13 +179,13 @@ protected:
void FailWithError(nsresult aRv);
virtual nsresult CalculateResult() final;
nsresult CalculateResult();
virtual void CallCallback(nsresult rv) final;
void CallCallback(nsresult rv);
private:
NS_IMETHOD Run() override final;
nsresult Cancel() override final;
NS_IMETHOD Run() final;
nsresult Cancel() final;
class InternalWorkerHolder;

Просмотреть файл

@ -93,7 +93,7 @@ public:
return mOwner;
}
virtual JSObject* WrapObject(JSContext* aCx, JS::Handle<JSObject*> aGivenProto) override final;
JSObject* WrapObject(JSContext* aCx, JS::Handle<JSObject*> aGivenProto) final;
virtual JSObject* WrapObjectInternal(JSContext* aCx, JS::Handle<JSObject*> aGivenProto);

Просмотреть файл

@ -232,7 +232,7 @@ public:
}
void ToString(nsAString& aSource);
virtual void NodeInfoChanged(nsIDocument* aOldDoc) final override
void NodeInfoChanged(nsIDocument* aOldDoc) final
{
ClearHasPendingLinkUpdate();
nsGenericHTMLElement::NodeInfoChanged(aOldDoc);

Просмотреть файл

@ -188,7 +188,7 @@ public:
GetHref(aResult);
}
virtual void NodeInfoChanged(nsIDocument* aOldDoc) final override
void NodeInfoChanged(nsIDocument* aOldDoc) final
{
ClearHasPendingLinkUpdate();
nsGenericHTMLElement::NodeInfoChanged(aOldDoc);

Просмотреть файл

@ -197,7 +197,7 @@ public:
virtual CORSMode GetCORSMode() const override;
virtual void NodeInfoChanged(nsIDocument* aOldDoc) final override
void NodeInfoChanged(nsIDocument* aOldDoc) final
{
ClearHasPendingLinkUpdate();
nsGenericHTMLElement::NodeInfoChanged(aOldDoc);

Просмотреть файл

@ -169,48 +169,48 @@ public:
// etc.
virtual void MetadataLoaded(
const MediaInfo* aInfo,
UniquePtr<const MetadataTags> aTags) final override;
UniquePtr<const MetadataTags> aTags) final;
// Called by the decoder object, on the main thread,
// when it has read the first frame of the video or audio.
virtual void FirstFrameLoaded() final override;
void FirstFrameLoaded() final;
// Called by the video decoder object, on the main thread,
// when the resource has a network error during loading.
virtual void NetworkError(const MediaResult& aError) final override;
void NetworkError(const MediaResult& aError) final;
// Called by the video decoder object, on the main thread, when the
// resource has a decode error during metadata loading or decoding.
virtual void DecodeError(const MediaResult& aError) final override;
void DecodeError(const MediaResult& aError) final;
// Called by the decoder object, on the main thread, when the
// resource has a decode issue during metadata loading or decoding, but can
// continue decoding.
virtual void DecodeWarning(const MediaResult& aError) final override;
void DecodeWarning(const MediaResult& aError) final;
// Return true if error attribute is not null.
virtual bool HasError() const final override;
bool HasError() const final;
// Called by the video decoder object, on the main thread, when the
// resource load has been cancelled.
virtual void LoadAborted() final override;
void LoadAborted() final;
// Called by the video decoder object, on the main thread,
// when the video playback has ended.
virtual void PlaybackEnded() final override;
void PlaybackEnded() final;
// Called by the video decoder object, on the main thread,
// when the resource has started seeking.
virtual void SeekStarted() final override;
void SeekStarted() final;
// Called by the video decoder object, on the main thread,
// when the resource has completed seeking.
virtual void SeekCompleted() final override;
void SeekCompleted() final;
// Called by the media stream, on the main thread, when the download
// has been suspended by the cache or because the element itself
// asked the decoder to suspend the download.
virtual void DownloadSuspended() final override;
void DownloadSuspended() final;
// Called by the media stream, on the main thread, when the download
// has been resumed by the cache or because the element itself
@ -218,11 +218,11 @@ public:
void DownloadResumed();
// Called to indicate the download is progressing.
virtual void DownloadProgressed() final override;
void DownloadProgressed() final;
// Called by the media decoder to indicate whether the media cache has
// suspended the channel.
virtual void NotifySuspendedByCache(bool aSuspendedByCache) final override;
void NotifySuspendedByCache(bool aSuspendedByCache) final;
bool IsActive() const;
@ -230,7 +230,7 @@ public:
// Called by the media decoder and the video frame to get the
// ImageContainer containing the video data.
virtual VideoFrameContainer* GetVideoFrameContainer() final override;
VideoFrameContainer* GetVideoFrameContainer() final;
layers::ImageContainer* GetImageContainer();
/**
@ -251,7 +251,7 @@ public:
const PrincipalHandle& aNewPrincipalHandle) override;
// Dispatch events
virtual void DispatchAsyncEvent(const nsAString& aName) final override;
void DispatchAsyncEvent(const nsAString& aName) final;
// Triggers a recomputation of readyState.
void UpdateReadyState() override { UpdateReadyStateInternal(); }
@ -296,7 +296,7 @@ public:
already_AddRefed<nsIPrincipal> GetCurrentVideoPrincipal();
// called to notify that the principal of the decoder's media resource has changed.
void NotifyDecoderPrincipalChanged() final override;
void NotifyDecoderPrincipalChanged() final;
void GetEMEInfo(nsString& aEMEInfo);
@ -427,7 +427,7 @@ public:
* last 250ms, as required by the spec when the current time is periodically
* increasing during playback.
*/
virtual void FireTimeUpdate(bool aPeriodic) final override;
void FireTimeUpdate(bool aPeriodic) final;
/**
* This will return null if mSrcStream is null, or if mSrcStream is not
@ -472,11 +472,11 @@ public:
return mNetworkState;
}
void NotifyXPCOMShutdown() final override;
void NotifyXPCOMShutdown() final;
// Called by media decoder when the audible state changed or when input is
// a media stream.
virtual void SetAudibleState(bool aAudible) final override;
void SetAudibleState(bool aAudible) final;
// Notify agent when the MediaElement changes its audible state.
void NotifyAudioPlaybackChanged(AudibleChangedReasons aReason);
@ -787,7 +787,7 @@ public:
void SetMediaInfo(const MediaInfo& aInfo);
virtual AbstractThread* AbstractMainThread() const final override;
AbstractThread* AbstractMainThread() const final;
// Telemetry: to record the usage of a {visible / invisible} video element as
// the source of {drawImage(), createPattern(), createImageBitmap() and
@ -1241,13 +1241,13 @@ protected:
// Get the HTMLMediaElement object if the decoder is being used from an
// HTML media element, and null otherwise.
virtual HTMLMediaElement* GetMediaElement() final override
HTMLMediaElement* GetMediaElement() final
{
return this;
}
// Return true if decoding should be paused
virtual bool GetPaused() final override
bool GetPaused() final
{
return Paused();
}

Просмотреть файл

@ -53,8 +53,7 @@ public:
protected:
virtual ~HTMLTitleElement();
virtual JSObject* WrapNode(JSContext* cx, JS::Handle<JSObject*> aGivenProto)
override final;
JSObject* WrapNode(JSContext* cx, JS::Handle<JSObject*> aGivenProto) final;
private:
void SendTitleChangeEvent(bool aBound);

Просмотреть файл

@ -7554,7 +7554,7 @@ protected:
// Common nsIRunnable implementation that subclasses may not override.
NS_IMETHOD
Run() final override;
Run() final;
// OpenDirectoryListener overrides.
void
@ -7897,7 +7897,7 @@ protected:
// Common nsIRunnable implementation that subclasses may not override.
NS_IMETHOD
Run() final override;
Run() final;
// IPDL methods.
void

Просмотреть файл

@ -118,7 +118,7 @@ private:
// by the MediaResource read functions.
void NotifyBytesConsumed(int64_t aBytes, int64_t aOffset);
bool CanPlayThroughImpl() override final;
bool CanPlayThroughImpl() final;
struct PlaybackRateInfo
{

Просмотреть файл

@ -587,7 +587,7 @@ protected:
virtual ~AsyncCubebTask();
private:
NS_IMETHOD Run() override final;
NS_IMETHOD Run() final;
RefPtr<AudioCallbackDriver> mDriver;
AsyncCubebOperation mOperation;

Просмотреть файл

@ -31,7 +31,7 @@ public:
NS_DECL_ISUPPORTS
NS_IMETHOD Notify(nsITimer* aTimer) final override
NS_IMETHOD Notify(nsITimer* aTimer) final
{
mMediaDevices->DispatchTrustedEvent(NS_LITERAL_STRING("devicechange"));
return NS_OK;

Просмотреть файл

@ -32,13 +32,13 @@ public:
VP8TrackEncoder(TrackRate aTrackRate, FrameDroppingMode aFrameDroppingMode);
virtual ~VP8TrackEncoder();
already_AddRefed<TrackMetadataBase> GetMetadata() final override;
already_AddRefed<TrackMetadataBase> GetMetadata() final;
nsresult GetEncodedTrack(EncodedFrameContainer& aData) final override;
nsresult GetEncodedTrack(EncodedFrameContainer& aData) final;
protected:
nsresult Init(int32_t aWidth, int32_t aHeight,
int32_t aDisplayWidth, int32_t aDisplayHeight) final override;
int32_t aDisplayWidth, int32_t aDisplayHeight) final;
private:
// Get the EncodeOperation for next target frame.

Просмотреть файл

@ -49,7 +49,7 @@ private:
MediaDecoderStateMachine* CreateStateMachine();
bool CanPlayThroughImpl() override final
bool CanPlayThroughImpl() final
{
// TODO: We don't know how to estimate 'canplaythrough' for this decoder.
// For now we just return true for 'autoplay' can work.

Просмотреть файл

@ -26,7 +26,7 @@ public:
void DestroyMediaStream() override;
uint16_t NumberOfInputs() const final override
uint16_t NumberOfInputs() const final
{
return 0;
}

Просмотреть файл

@ -37,7 +37,7 @@ public:
JSObject* WrapObject(JSContext* aCx, JS::Handle<JSObject*> aGivenProto) override;
uint16_t NumberOfOutputs() const final override
uint16_t NumberOfOutputs() const final
{
return 0;
}

Просмотреть файл

@ -35,7 +35,7 @@ public:
void DestroyMediaStream() override;
uint16_t NumberOfInputs() const final override
uint16_t NumberOfInputs() const final
{
return 0;
}

Просмотреть файл

@ -34,7 +34,7 @@ public:
JSObject* WrapObject(JSContext* aCx, JS::Handle<JSObject*> aGivenProto) override;
uint16_t NumberOfOutputs() const final override
uint16_t NumberOfOutputs() const final
{
return 0;
}

Просмотреть файл

@ -40,7 +40,7 @@ public:
void DestroyMediaStream() override;
uint16_t NumberOfInputs() const final override
uint16_t NumberOfInputs() const final
{
return 0;
}

Просмотреть файл

@ -92,7 +92,7 @@ public:
const nsAString& aIcon,
const nsAString& aData,
const nsAString& aBehavior,
const nsAString& aServiceWorkerRegistrationScope) final override
const nsAString& aServiceWorkerRegistrationScope) final
{
AssertIsOnMainThread();
MOZ_ASSERT(!aID.IsEmpty());
@ -145,7 +145,7 @@ public:
MOZ_ASSERT(aPromise);
}
NS_IMETHOD Done() final override
NS_IMETHOD Done() final
{
ErrorResult result;
AutoTArray<RefPtr<Notification>, 5> notifications;
@ -2087,7 +2087,7 @@ public:
MOZ_ASSERT(aProxy);
}
NS_IMETHOD Done() final override
NS_IMETHOD Done() final
{
AssertIsOnMainThread();
MOZ_ASSERT(mPromiseProxy, "Was Done() called twice?");

Просмотреть файл

@ -71,7 +71,7 @@ public:
void GetDownload(nsAString & aDownload);
void SetDownload(const nsAString & aDownload, ErrorResult& rv);
virtual void NodeInfoChanged(nsIDocument* aOldDoc) final override
void NodeInfoChanged(nsIDocument* aOldDoc) final
{
ClearHasPendingLinkUpdate();
SVGAElementBase::NodeInfoChanged(aOldDoc);

Просмотреть файл

@ -26,8 +26,8 @@ public:
return mSVGElement;
}
virtual JSObject* WrapObject(JSContext* aCx, JS::Handle<JSObject*> aGivenProto)
override final;
JSObject* WrapObject(JSContext* aCx, JS::Handle<JSObject*> aGivenProto)
final;
virtual uint16_t BaseVal() = 0;
virtual void SetBaseVal(uint16_t aBaseVal, ErrorResult& aRv) = 0;

Просмотреть файл

@ -26,8 +26,8 @@ public:
return mSVGElement;
}
virtual JSObject* WrapObject(JSContext* aCx, JS::Handle<JSObject*> aGivenProto)
override final;
JSObject* WrapObject(JSContext* aCx, JS::Handle<JSObject*> aGivenProto)
final;
virtual int32_t BaseVal() = 0;
virtual void SetBaseVal(int32_t aBaseVal) = 0;

Просмотреть файл

@ -27,8 +27,8 @@ public:
return mSVGElement;
}
virtual JSObject* WrapObject(JSContext* aCx, JS::Handle<JSObject*> aGivenProto)
override final;
JSObject* WrapObject(JSContext* aCx, JS::Handle<JSObject*> aGivenProto)
final;
virtual float BaseVal() = 0;
virtual void SetBaseVal(float aBaseVal) = 0;

Просмотреть файл

@ -61,7 +61,7 @@ public:
* Causes this element to discard any Path object that GetOrBuildPath may
* have cached.
*/
virtual void ClearAnyCachedPath() override final {
void ClearAnyCachedPath() final {
mCachedPath = nullptr;
}

Просмотреть файл

@ -27,42 +27,42 @@ public:
NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_CLASS(SVGRect)
// WebIDL
virtual float X() const override final
float X() const final
{
return mX;
}
virtual void SetX(float aX, ErrorResult& aRv) final override
void SetX(float aX, ErrorResult& aRv) final
{
mX = aX;
}
virtual float Y() const override final
float Y() const final
{
return mY;
}
virtual void SetY(float aY, ErrorResult& aRv) final override
void SetY(float aY, ErrorResult& aRv) final
{
mY = aY;
}
virtual float Width() const override final
float Width() const final
{
return mWidth;
}
virtual void SetWidth(float aWidth, ErrorResult& aRv) final override
void SetWidth(float aWidth, ErrorResult& aRv) final
{
mWidth = aWidth;
}
virtual float Height() const override final
float Height() const final
{
return mHeight;
}
virtual void SetHeight(float aHeight, ErrorResult& aRv) final override
void SetHeight(float aHeight, ErrorResult& aRv) final
{
mHeight = aHeight;
}

Просмотреть файл

@ -316,7 +316,7 @@ public:
}
virtual void ClearAnyCachedPath() {}
virtual nsIDOMNode* AsDOMNode() final override { return this; }
nsIDOMNode* AsDOMNode() final { return this; }
virtual bool IsTransformable() { return false; }
// WebIDL
@ -338,9 +338,9 @@ protected:
// This is because we're not currently passing the correct value for aValue to
// BeforeSetAttr since it would involve allocating extra SVG value types.
// See the comment in nsSVGElement::WillChangeValue.
virtual nsresult BeforeSetAttr(int32_t aNamespaceID, nsAtom* aName,
const nsAttrValueOrString* aValue,
bool aNotify) override final;
nsresult BeforeSetAttr(int32_t aNamespaceID, nsAtom* aName,
const nsAttrValueOrString* aValue,
bool aNotify) final;
virtual nsresult AfterSetAttr(int32_t aNamespaceID, nsAtom* aName,
const nsAttrValue* aValue,
const nsAttrValue* aOldValue,

Просмотреть файл

@ -115,30 +115,30 @@ public:
nsSVGViewBox* mVal; // kept alive because it belongs to content
RefPtr<nsSVGElement> mSVGElement;
float X() const override final
float X() const final
{
return mVal->GetBaseValue().x;
}
float Y() const override final
float Y() const final
{
return mVal->GetBaseValue().y;
}
float Width() const override final
float Width() const final
{
return mVal->GetBaseValue().width;
}
float Height() const override final
float Height() const final
{
return mVal->GetBaseValue().height;
}
void SetX(float aX, mozilla::ErrorResult& aRv) final override;
void SetY(float aY, mozilla::ErrorResult& aRv) final override;
void SetWidth(float aWidth, mozilla::ErrorResult& aRv) final override;
void SetHeight(float aHeight, mozilla::ErrorResult& aRv) final override;
void SetX(float aX, mozilla::ErrorResult& aRv) final;
void SetY(float aY, mozilla::ErrorResult& aRv) final;
void SetWidth(float aWidth, mozilla::ErrorResult& aRv) final;
void SetHeight(float aHeight, mozilla::ErrorResult& aRv) final;
virtual nsIContent* GetParentObject() const override
{
@ -165,46 +165,46 @@ public:
// Script may have modified animation parameters or timeline -- DOM getters
// need to flush any resample requests to reflect these modifications.
float X() const override final
float X() const final
{
mSVGElement->FlushAnimations();
return mVal->GetAnimValue().x;
}
float Y() const override final
float Y() const final
{
mSVGElement->FlushAnimations();
return mVal->GetAnimValue().y;
}
float Width() const override final
float Width() const final
{
mSVGElement->FlushAnimations();
return mVal->GetAnimValue().width;
}
float Height() const override final
float Height() const final
{
mSVGElement->FlushAnimations();
return mVal->GetAnimValue().height;
}
void SetX(float aX, mozilla::ErrorResult& aRv) final override
void SetX(float aX, mozilla::ErrorResult& aRv) final
{
aRv.Throw(NS_ERROR_DOM_NO_MODIFICATION_ALLOWED_ERR);
}
void SetY(float aY, mozilla::ErrorResult& aRv) final override
void SetY(float aY, mozilla::ErrorResult& aRv) final
{
aRv.Throw(NS_ERROR_DOM_NO_MODIFICATION_ALLOWED_ERR);
}
void SetWidth(float aWidth, mozilla::ErrorResult& aRv) final override
void SetWidth(float aWidth, mozilla::ErrorResult& aRv) final
{
aRv.Throw(NS_ERROR_DOM_NO_MODIFICATION_ALLOWED_ERR);
}
void SetHeight(float aHeight, mozilla::ErrorResult& aRv) final override
void SetHeight(float aHeight, mozilla::ErrorResult& aRv) final
{
aRv.Throw(NS_ERROR_DOM_NO_MODIFICATION_ALLOWED_ERR);
}

Просмотреть файл

@ -20,10 +20,7 @@ dictionary KeyframeEffectOptions : AnimationEffectTimingProperties {
CompositeOperation composite = "replace";
};
// KeyframeEffectReadOnly should run in the caller's compartment to do custom
// processing on the `keyframes` object.
[Func="nsDocument::IsWebAnimationsEnabled",
RunConstructorInCallerCompartment,
Constructor ((Element or CSSPseudoElement)? target,
object? keyframes,
optional (unrestricted double or KeyframeEffectOptions) options),
@ -57,10 +54,7 @@ partial interface KeyframeEffectReadOnly {
[ChromeOnly, Throws] sequence<AnimationPropertyDetails> getProperties();
};
// KeyframeEffect should run in the caller's compartment to do custom
// processing on the `keyframes` object.
[Func="nsDocument::IsWebAnimationsEnabled",
RunConstructorInCallerCompartment,
Constructor ((Element or CSSPseudoElement)? target,
object? keyframes,
optional (unrestricted double or KeyframeEffectOptions) options),

Просмотреть файл

@ -199,8 +199,8 @@ private:
return true;
}
virtual bool
PreDispatch(WorkerPrivate* aWorkerPrivate) override final
bool
PreDispatch(WorkerPrivate* aWorkerPrivate) final
{
AssertIsOnMainThread();
@ -482,8 +482,8 @@ protected:
{ }
private:
virtual bool
PreDispatch(WorkerPrivate* aWorkerPrivate) override final
bool
PreDispatch(WorkerPrivate* aWorkerPrivate) final
{
AssertIsOnMainThread();
return true;
@ -496,8 +496,8 @@ private:
virtual bool
WorkerRun(JSContext* aCx, WorkerPrivate* aWorkerPrivate) override;
virtual bool
DispatchInternal() override final;
bool
DispatchInternal() final;
};
} // dom namespace

Просмотреть файл

@ -534,11 +534,8 @@ private:
~EventRunnable()
{ }
virtual bool
PreDispatch(WorkerPrivate* /* unused */) override final;
virtual bool
WorkerRun(JSContext* aCx, WorkerPrivate* aWorkerPrivate) override;
bool PreDispatch(WorkerPrivate* /* unused */) final;
bool WorkerRun(JSContext* aCx, WorkerPrivate* aWorkerPrivate) override;
};
class SyncTeardownRunnable final : public WorkerThreadProxySyncRunnable

Просмотреть файл

@ -381,7 +381,7 @@ public:
bool aIsTrustedEvent) override;
void ClickWithInputSource(uint16_t aInputSource, bool aIsTrustedEvent);
nsIContent* GetBindingParent() const final override
nsIContent* GetBindingParent() const final
{
return mBindingParent;
}

Просмотреть файл

@ -90,11 +90,11 @@ public:
protected:
// get the current state (on or off) for this style or block format
virtual nsresult GetCurrentState(mozilla::HTMLEditor* aHTMLEditor,
nsICommandParams* aParams) override final;
nsresult GetCurrentState(mozilla::HTMLEditor* aHTMLEditor,
nsICommandParams* aParams) final;
// add/remove the style
virtual nsresult ToggleState(mozilla::HTMLEditor* aHTMLEditor) override final;
nsresult ToggleState(mozilla::HTMLEditor* aHTMLEditor) final;
};
@ -122,11 +122,11 @@ public:
protected:
// get the current state (on or off) for this style or block format
virtual nsresult GetCurrentState(mozilla::HTMLEditor* aHTMLEditor,
nsICommandParams* aParams) override final;
nsresult GetCurrentState(mozilla::HTMLEditor* aHTMLEditor,
nsICommandParams* aParams) final;
// add/remove the style
virtual nsresult ToggleState(mozilla::HTMLEditor* aHTMLEditor) override final;
nsresult ToggleState(mozilla::HTMLEditor* aHTMLEditor) final;
};
class nsListItemCommand final : public nsBaseStateUpdatingCommand
@ -137,11 +137,11 @@ public:
protected:
// get the current state (on or off) for this style or block format
virtual nsresult GetCurrentState(mozilla::HTMLEditor* aHTMLEditor,
nsICommandParams* aParams) override final;
nsresult GetCurrentState(mozilla::HTMLEditor* aHTMLEditor,
nsICommandParams* aParams) final;
// add/remove the style
virtual nsresult ToggleState(mozilla::HTMLEditor* aHTMLEditor) override final;
nsresult ToggleState(mozilla::HTMLEditor* aHTMLEditor) final;
};
// Base class for commands whose state consists of a string (e.g. para format)
@ -172,10 +172,10 @@ public:
protected:
virtual nsresult GetCurrentState(mozilla::HTMLEditor* aHTMLEditor,
nsICommandParams* aParams) override final;
virtual nsresult SetState(mozilla::HTMLEditor* aHTMLEditor,
nsString& newState) override final;
nsresult GetCurrentState(mozilla::HTMLEditor* aHTMLEditor,
nsICommandParams* aParams) final;
nsresult SetState(mozilla::HTMLEditor* aHTMLEditor,
nsString& newState) final;
};
class nsFontFaceStateCommand final : public nsMultiStateCommand
@ -185,10 +185,10 @@ public:
protected:
virtual nsresult GetCurrentState(mozilla::HTMLEditor* aHTMLEditor,
nsICommandParams* aParams) override final;
virtual nsresult SetState(mozilla::HTMLEditor* aHTMLEditor,
nsString& newState) override final;
nsresult GetCurrentState(mozilla::HTMLEditor* aHTMLEditor,
nsICommandParams* aParams) final;
nsresult SetState(mozilla::HTMLEditor* aHTMLEditor,
nsString& newState) final;
};
class nsFontSizeStateCommand final : public nsMultiStateCommand
@ -198,10 +198,10 @@ public:
protected:
virtual nsresult GetCurrentState(mozilla::HTMLEditor* aHTMLEditor,
nsICommandParams* aParams) override final;
virtual nsresult SetState(mozilla::HTMLEditor* aHTMLEditor,
nsString& newState) override final;
nsresult GetCurrentState(mozilla::HTMLEditor* aHTMLEditor,
nsICommandParams* aParams) final;
nsresult SetState(mozilla::HTMLEditor* aHTMLEditor,
nsString& newState) final;
};
class nsHighlightColorStateCommand final : public nsMultiStateCommand
@ -213,12 +213,11 @@ protected:
NS_IMETHOD IsCommandEnabled(const char* aCommandName,
nsISupports* aCommandRefCon,
bool* _retval) override final;
virtual nsresult GetCurrentState(mozilla::HTMLEditor* aHTMLEditor,
nsICommandParams* aParams) override final;
virtual nsresult SetState(mozilla::HTMLEditor* aHTMLEditor,
nsString& newState) override final;
bool* _retval) final;
nsresult GetCurrentState(mozilla::HTMLEditor* aHTMLEditor,
nsICommandParams* aParams) final;
nsresult SetState(mozilla::HTMLEditor* aHTMLEditor,
nsString& newState) final;
};
class nsFontColorStateCommand final : public nsMultiStateCommand
@ -228,10 +227,10 @@ public:
protected:
virtual nsresult GetCurrentState(mozilla::HTMLEditor* aHTMLEditor,
nsICommandParams* aParams) override final;
virtual nsresult SetState(mozilla::HTMLEditor* aHTMLEditor,
nsString& newState) override final;
nsresult GetCurrentState(mozilla::HTMLEditor* aHTMLEditor,
nsICommandParams* aParams) final;
nsresult SetState(mozilla::HTMLEditor* aHTMLEditor,
nsString& newState) final;
};
class nsAlignCommand final : public nsMultiStateCommand
@ -241,10 +240,10 @@ public:
protected:
virtual nsresult GetCurrentState(mozilla::HTMLEditor* aHTMLEditor,
nsICommandParams* aParams) override final;
virtual nsresult SetState(mozilla::HTMLEditor* aHTMLEditor,
nsString& newState) override final;
nsresult GetCurrentState(mozilla::HTMLEditor* aHTMLEditor,
nsICommandParams* aParams) final;
nsresult SetState(mozilla::HTMLEditor* aHTMLEditor,
nsString& newState) final;
};
class nsBackgroundColorStateCommand final : public nsMultiStateCommand
@ -254,10 +253,10 @@ public:
protected:
virtual nsresult GetCurrentState(mozilla::HTMLEditor* aHTMLEditor,
nsICommandParams* aParams) override final;
virtual nsresult SetState(mozilla::HTMLEditor* aHTMLEditor,
nsString& newState) override final;
nsresult GetCurrentState(mozilla::HTMLEditor* aHTMLEditor,
nsICommandParams* aParams) final;
nsresult SetState(mozilla::HTMLEditor* aHTMLEditor,
nsString& newState) final;
};
class nsAbsolutePositioningCommand final : public nsBaseStateUpdatingCommand
@ -269,10 +268,10 @@ protected:
NS_IMETHOD IsCommandEnabled(const char* aCommandName,
nsISupports* aCommandRefCon,
bool* _retval) override final;
virtual nsresult GetCurrentState(mozilla::HTMLEditor* aHTMLEditor,
nsICommandParams* aParams) override final;
virtual nsresult ToggleState(mozilla::HTMLEditor* aHTMLEditor) override final;
bool* _retval) final;
nsresult GetCurrentState(mozilla::HTMLEditor* aHTMLEditor,
nsICommandParams* aParams) final;
nsresult ToggleState(mozilla::HTMLEditor* aHTMLEditor) final;
};
// composer commands

Просмотреть файл

@ -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 override
int64_t aModificationTime) final
{
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 override
int64_t aModificationTime) final
{
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 override
int64_t aModificationTime) final
{
// Every time the migration code wants to insert an origin into
// the database we need to check to see if someone has already

Просмотреть файл

@ -1222,6 +1222,30 @@ public:
const IntRect& aBounds = IntRect(),
bool aCopyBackground = false) { MOZ_CRASH("GFX: PushLayer"); }
/**
* Push a 'layer' to the DrawTarget, a layer is a temporary surface that all
* drawing will be redirected to, this is used for example to support group
* opacity or the masking of groups. Clips must be balanced within a layer,
* i.e. between a matching PushLayer/PopLayer pair there must be as many
* PushClip(Rect) calls as there are PopClip calls.
*
* @param aOpaque Whether the layer will be opaque
* @param aOpacity Opacity of the layer
* @param aMask Mask applied to the layer
* @param aMaskTransform Transform applied to the layer mask
* @param aBounds Optional bounds in device space to which the layer is
* limited in size.
* @param aCopyBackground Whether to copy the background into the layer, this
* is only supported when aOpaque is true.
*/
virtual void PushLayerWithBlend(bool aOpaque, Float aOpacity,
SourceSurface* aMask,
const Matrix& aMaskTransform,
const IntRect& aBounds = IntRect(),
bool aCopyBackground = false,
CompositionOp = CompositionOp::OP_OVER) { MOZ_CRASH("GFX: PushLayerWithBlend"); }
/**
* This balances a call to PushLayer and proceeds to blend the layer back
* onto the background. This blend will blend the temporary surface back

Просмотреть файл

@ -526,6 +526,23 @@ DrawTargetRecording::PushLayer(bool aOpaque, Float aOpacity,
aCopyBackground));
}
void
DrawTargetRecording::PushLayerWithBlend(bool aOpaque, Float aOpacity,
SourceSurface* aMask,
const Matrix& aMaskTransform,
const IntRect& aBounds,
bool aCopyBackground,
CompositionOp aCompositionOp)
{
if (aMask) {
EnsureSurfaceStoredRecording(mRecorder, aMask, "PushLayer");
}
mRecorder->RecordEvent(RecordedPushLayerWithBlend(this, aOpaque, aOpacity, aMask,
aMaskTransform, aBounds,
aCopyBackground, aCompositionOp));
}
void
DrawTargetRecording::PopLayer()
{

Просмотреть файл

@ -231,6 +231,32 @@ public:
const IntRect& aBounds = IntRect(),
bool aCopyBackground = false) override;
/**
* Push a 'layer' to the DrawTarget, a layer is a temporary surface that all
* drawing will be redirected to, this is used for example to support group
* opacity or the masking of groups. Clips must be balanced within a layer,
* i.e. between a matching PushLayer/PopLayer pair there must be as many
* PushClip(Rect) calls as there are PopClip calls.
*
* @param aOpaque Whether the layer will be opaque
* @param aOpacity Opacity of the layer
* @param aMask Mask applied to the layer
* @param aMaskTransform Transform applied to the layer mask
* @param aBounds Optional bounds in device space to which the layer is
* limited in size.
* @param aCopyBackground Whether to copy the background into the layer, this
* is only supported when aOpaque is true.a
* @param aCompositionOp The CompositionOp to use when blending the layer into
* the destination
*/
virtual void PushLayerWithBlend(bool aOpaque, Float aOpacity,
SourceSurface* aMask,
const Matrix& aMaskTransform,
const IntRect& aBounds = IntRect(),
bool aCopyBackground = false,
CompositionOp aCompositionOp = CompositionOp::OP_OVER) override;
/**
* This balances a call to PushLayer and proceeds to blend the layer back
* onto the background. This blend will blend the temporary surface back

Просмотреть файл

@ -2067,7 +2067,15 @@ DrawTargetSkia::PushLayer(bool aOpaque, Float aOpacity, SourceSurface* aMask,
const Matrix& aMaskTransform, const IntRect& aBounds,
bool aCopyBackground)
{
PushedLayer layer(GetPermitSubpixelAA(), aOpaque, aOpacity, aMask, aMaskTransform,
PushLayerWithBlend(aOpaque, aOpacity, aMask, aMaskTransform, aBounds, aCopyBackground, CompositionOp::OP_OVER);
}
void
DrawTargetSkia::PushLayerWithBlend(bool aOpaque, Float aOpacity, SourceSurface* aMask,
const Matrix& aMaskTransform, const IntRect& aBounds,
bool aCopyBackground, CompositionOp aCompositionOp)
{
PushedLayer layer(GetPermitSubpixelAA(), aOpaque, aOpacity, aCompositionOp, aMask, aMaskTransform,
mCanvas->getTopDevice());
mPushedLayers.push_back(layer);
@ -2076,6 +2084,9 @@ DrawTargetSkia::PushLayer(bool aOpaque, Float aOpacity, SourceSurface* aMask,
// If we have a mask, set the opacity to 0 so that SkCanvas::restore skips
// implicitly drawing the layer so that we can properly mask it in PopLayer.
paint.setAlpha(aMask ? 0 : ColorFloatToByte(aOpacity));
if (!aMask) {
paint.setBlendMode(GfxOpToSkiaOp(layer.mCompositionOp));
}
// aBounds is supplied in device space, but SaveLayerRec wants local space.
SkRect bounds = IntRectToSkRect(aBounds);
@ -2142,6 +2153,7 @@ DrawTargetSkia::PopLayer()
SkPaint paint;
paint.setAlpha(ColorFloatToByte(layer.mOpacity));
paint.setBlendMode(GfxOpToSkiaOp(layer.mCompositionOp));
SkMatrix maskMat, layerMat;
// Get the total transform affecting the mask, considering its pattern

Просмотреть файл

@ -109,6 +109,12 @@ public:
const Matrix& aMaskTransform,
const IntRect& aBounds = IntRect(),
bool aCopyBackground = false) override;
virtual void PushLayerWithBlend(bool aOpaque, Float aOpacity,
SourceSurface* aMask,
const Matrix& aMaskTransform,
const IntRect& aBounds = IntRect(),
bool aCopyBackground = false,
CompositionOp aCompositionOp = CompositionOp::OP_OVER) override;
virtual void PopLayer() override;
virtual void Blur(const AlphaBoxBlur& aBlur) override;
virtual already_AddRefed<SourceSurface> CreateSourceSurfaceFromData(unsigned char *aData,
@ -178,12 +184,14 @@ private:
PushedLayer(bool aOldPermitSubpixelAA,
bool aOpaque,
Float aOpacity,
CompositionOp aCompositionOp,
SourceSurface* aMask,
const Matrix& aMaskTransform,
SkBaseDevice* aPreviousDevice)
: mOldPermitSubpixelAA(aOldPermitSubpixelAA),
mOpaque(aOpaque),
mOpacity(aOpacity),
mCompositionOp(aCompositionOp),
mMask(aMask),
mMaskTransform(aMaskTransform),
mPreviousDevice(aPreviousDevice)
@ -191,6 +199,7 @@ private:
bool mOldPermitSubpixelAA;
bool mOpaque;
Float mOpacity;
CompositionOp mCompositionOp;
RefPtr<SourceSurface> mMask;
Matrix mMaskTransform;
SkBaseDevice* mPreviousDevice;

Просмотреть файл

@ -26,7 +26,7 @@ public:
virtual BackendType GetBackendType() const { return BackendType::DIRECT2D; }
virtual bool IsValid() const final{ return mDevice == Factory::GetDirect3D11Device(); }
bool IsValid() const final { return mDevice == Factory::GetDirect3D11Device(); }
private:
friend class DrawTargetD2D;

Просмотреть файл

@ -34,141 +34,141 @@ public:
bool TranslateRecording(char *, size_t len);
DrawTarget* LookupDrawTarget(ReferencePtr aRefPtr) final override
DrawTarget* LookupDrawTarget(ReferencePtr aRefPtr) final
{
DrawTarget* result = mDrawTargets.GetWeak(aRefPtr);
MOZ_ASSERT(result);
return result;
}
Path* LookupPath(ReferencePtr aRefPtr) final override
Path* LookupPath(ReferencePtr aRefPtr) final
{
Path* result = mPaths.GetWeak(aRefPtr);
MOZ_ASSERT(result);
return result;
}
SourceSurface* LookupSourceSurface(ReferencePtr aRefPtr) final override
SourceSurface* LookupSourceSurface(ReferencePtr aRefPtr) final
{
SourceSurface* result = mSourceSurfaces.GetWeak(aRefPtr);
MOZ_ASSERT(result);
return result;
}
FilterNode* LookupFilterNode(ReferencePtr aRefPtr) final override
FilterNode* LookupFilterNode(ReferencePtr aRefPtr) final
{
FilterNode* result = mFilterNodes.GetWeak(aRefPtr);
MOZ_ASSERT(result);
return result;
}
GradientStops* LookupGradientStops(ReferencePtr aRefPtr) final override
GradientStops* LookupGradientStops(ReferencePtr aRefPtr) final
{
GradientStops* result = mGradientStops.GetWeak(aRefPtr);
MOZ_ASSERT(result);
return result;
}
ScaledFont* LookupScaledFont(ReferencePtr aRefPtr) final override
ScaledFont* LookupScaledFont(ReferencePtr aRefPtr) final
{
ScaledFont* result = mScaledFonts.GetWeak(aRefPtr);
MOZ_ASSERT(result);
return result;
}
UnscaledFont* LookupUnscaledFont(ReferencePtr aRefPtr) override final
UnscaledFont* LookupUnscaledFont(ReferencePtr aRefPtr) final
{
UnscaledFont* result = mUnscaledFonts.GetWeak(aRefPtr);
MOZ_ASSERT(result);
return result;
}
virtual UnscaledFont* LookupUnscaledFontByIndex(size_t index) override final
UnscaledFont* LookupUnscaledFontByIndex(size_t index) final
{
UnscaledFont* result = mUnscaledFontTable[index];
return result;
}
NativeFontResource* LookupNativeFontResource(uint64_t aKey) final override
NativeFontResource* LookupNativeFontResource(uint64_t aKey) final
{
NativeFontResource* result = mNativeFontResources.GetWeak(aKey);
MOZ_ASSERT(result);
return result;
}
void AddDrawTarget(ReferencePtr aRefPtr, DrawTarget *aDT) final override
void AddDrawTarget(ReferencePtr aRefPtr, DrawTarget *aDT) final
{
mDrawTargets.Put(aRefPtr, aDT);
}
void AddPath(ReferencePtr aRefPtr, Path *aPath) final override
void AddPath(ReferencePtr aRefPtr, Path *aPath) final
{
mPaths.Put(aRefPtr, aPath);
}
void AddSourceSurface(ReferencePtr aRefPtr, SourceSurface *aSurface) final override
void AddSourceSurface(ReferencePtr aRefPtr, SourceSurface *aSurface) final
{
mSourceSurfaces.Put(aRefPtr, aSurface);
}
void AddFilterNode(ReferencePtr aRefPtr, FilterNode *aFilter) final override
void AddFilterNode(ReferencePtr aRefPtr, FilterNode *aFilter) final
{
mFilterNodes.Put(aRefPtr, aFilter);
}
void AddGradientStops(ReferencePtr aRefPtr, GradientStops *aStops) final override
void AddGradientStops(ReferencePtr aRefPtr, GradientStops *aStops) final
{
mGradientStops.Put(aRefPtr, aStops);
}
void AddScaledFont(ReferencePtr aRefPtr, ScaledFont *aScaledFont) final override
void AddScaledFont(ReferencePtr aRefPtr, ScaledFont *aScaledFont) final
{
mScaledFonts.Put(aRefPtr, aScaledFont);
}
void AddUnscaledFont(ReferencePtr aRefPtr, UnscaledFont *aUnscaledFont) final override
void AddUnscaledFont(ReferencePtr aRefPtr, UnscaledFont *aUnscaledFont) final
{
mUnscaledFontTable.push_back(aUnscaledFont);
mUnscaledFonts.Put(aRefPtr, aUnscaledFont);
}
void AddNativeFontResource(uint64_t aKey,
NativeFontResource *aScaledFontResouce) final override
NativeFontResource *aScaledFontResouce) final
{
mNativeFontResources.Put(aKey, aScaledFontResouce);
}
void RemoveDrawTarget(ReferencePtr aRefPtr) final override
void RemoveDrawTarget(ReferencePtr aRefPtr) final
{
mDrawTargets.Remove(aRefPtr);
}
void RemovePath(ReferencePtr aRefPtr) final override
void RemovePath(ReferencePtr aRefPtr) final
{
mPaths.Remove(aRefPtr);
}
void RemoveSourceSurface(ReferencePtr aRefPtr) final override
void RemoveSourceSurface(ReferencePtr aRefPtr) final
{
mSourceSurfaces.Remove(aRefPtr);
}
void RemoveFilterNode(ReferencePtr aRefPtr) final override
void RemoveFilterNode(ReferencePtr aRefPtr) final
{
mFilterNodes.Remove(aRefPtr);
}
void RemoveGradientStops(ReferencePtr aRefPtr) final override
void RemoveGradientStops(ReferencePtr aRefPtr) final
{
mGradientStops.Remove(aRefPtr);
}
void RemoveScaledFont(ReferencePtr aRefPtr) final override
void RemoveScaledFont(ReferencePtr aRefPtr) final
{
mScaledFonts.Remove(aRefPtr);
}
void RemoveUnscaledFont(ReferencePtr aRefPtr) final override
void RemoveUnscaledFont(ReferencePtr aRefPtr) final
{
mUnscaledFonts.Remove(aRefPtr);
}
@ -176,11 +176,11 @@ public:
already_AddRefed<DrawTarget> CreateDrawTarget(ReferencePtr aRefPtr,
const gfx::IntSize &aSize,
gfx::SurfaceFormat aFormat) final override;
gfx::SurfaceFormat aFormat) final;
mozilla::gfx::DrawTarget* GetReferenceDrawTarget() final override { return mBaseDT; }
mozilla::gfx::DrawTarget* GetReferenceDrawTarget() final { return mBaseDT; }
void* GetFontContext() final override { return mFontContext; }
void* GetFontContext() final { return mFontContext; }
private:
RefPtr<DrawTarget> mBaseDT;

Просмотреть файл

@ -35,7 +35,7 @@ public:
already_AddRefed<UnscaledFont>
CreateUnscaledFont(uint32_t aIndex,
const uint8_t* aInstanceData,
uint32_t aInstanceDataLength) final override;
uint32_t aInstanceDataLength) final;
private:
NativeFontResourceDWrite(IDWriteFactory *aFactory,

Просмотреть файл

@ -25,7 +25,7 @@ public:
already_AddRefed<UnscaledFont>
CreateUnscaledFont(uint32_t aIndex,
const uint8_t* aInstanceData, uint32_t aInstanceDataLength) final override;
const uint8_t* aInstanceData, uint32_t aInstanceDataLength) final;
~NativeFontResourceFontconfig();

Просмотреть файл

@ -37,7 +37,7 @@ public:
already_AddRefed<UnscaledFont>
CreateUnscaledFont(uint32_t aIndex,
const uint8_t* aInstanceData,
uint32_t aInstanceDataLength) final override;
uint32_t aInstanceDataLength) final;
private:
explicit NativeFontResourceGDI(HANDLE aFontResourceHandle)

Просмотреть файл

@ -25,7 +25,7 @@ public:
already_AddRefed<UnscaledFont>
CreateUnscaledFont(uint32_t aIndex,
const uint8_t* aInstanceData,
uint32_t aInstanceDataLength) final override;
uint32_t aInstanceDataLength) final;
~NativeFontResourceMac()
{

Просмотреть файл

@ -256,6 +256,7 @@ public:
FONTDATA,
FONTDESC,
PUSHLAYER,
PUSHLAYERWITHBLEND,
POPLAYER,
UNSCALEDFONTCREATION,
UNSCALEDFONTDESTRUCTION,

Просмотреть файл

@ -530,6 +530,42 @@ private:
bool mCopyBackground;
};
class RecordedPushLayerWithBlend : public RecordedDrawingEvent<RecordedPushLayerWithBlend> {
public:
RecordedPushLayerWithBlend(DrawTarget* aDT, bool aOpaque, Float aOpacity,
SourceSurface* aMask, const Matrix& aMaskTransform,
const IntRect& aBounds, bool aCopyBackground,
CompositionOp aCompositionOp)
: RecordedDrawingEvent(PUSHLAYERWITHBLEND, aDT), mOpaque(aOpaque)
, mOpacity(aOpacity), mMask(aMask), mMaskTransform(aMaskTransform)
, mBounds(aBounds), mCopyBackground(aCopyBackground)
, mCompositionOp(aCompositionOp)
{
}
virtual bool PlayEvent(Translator *aTranslator) const override;
template<class S> void Record(S &aStream) const;
virtual void OutputSimpleEventInfo(std::stringstream &aStringStream) const override;
virtual std::string GetName() const override { return "PushLayerWithBlend"; }
private:
friend class RecordedEvent;
template<class S>
MOZ_IMPLICIT RecordedPushLayerWithBlend(S &aStream);
bool mOpaque;
Float mOpacity;
ReferencePtr mMask;
Matrix mMaskTransform;
IntRect mBounds;
bool mCopyBackground;
CompositionOp mCompositionOp;
};
class RecordedPopLayer : public RecordedDrawingEvent<RecordedPopLayer> {
public:
MOZ_IMPLICIT RecordedPopLayer(DrawTarget* aDT)
@ -2267,6 +2303,51 @@ RecordedPushLayer::OutputSimpleEventInfo(std::stringstream &aStringStream) const
", Opacity=" << mOpacity << ", Mask Ref=" << mMask << ") ";
}
inline bool
RecordedPushLayerWithBlend::PlayEvent(Translator *aTranslator) const
{
SourceSurface* mask = mMask ? aTranslator->LookupSourceSurface(mMask)
: nullptr;
aTranslator->LookupDrawTarget(mDT)->
PushLayerWithBlend(mOpaque, mOpacity, mask, mMaskTransform, mBounds, mCopyBackground, mCompositionOp);
return true;
}
template<class S>
void
RecordedPushLayerWithBlend::Record(S &aStream) const
{
RecordedDrawingEvent::Record(aStream);
WriteElement(aStream, mOpaque);
WriteElement(aStream, mOpacity);
WriteElement(aStream, mMask);
WriteElement(aStream, mMaskTransform);
WriteElement(aStream, mBounds);
WriteElement(aStream, mCopyBackground);
WriteElement(aStream, mCompositionOp);
}
template<class S>
RecordedPushLayerWithBlend::RecordedPushLayerWithBlend(S &aStream)
: RecordedDrawingEvent(PUSHLAYERWITHBLEND, aStream)
{
ReadElement(aStream, mOpaque);
ReadElement(aStream, mOpacity);
ReadElement(aStream, mMask);
ReadElement(aStream, mMaskTransform);
ReadElement(aStream, mBounds);
ReadElement(aStream, mCopyBackground);
ReadElement(aStream, mCompositionOp);
}
inline void
RecordedPushLayerWithBlend::OutputSimpleEventInfo(std::stringstream &aStringStream) const
{
aStringStream << "[" << mDT << "] PushLayerWithBlend (Opaque=" << mOpaque <<
", Opacity=" << mOpacity << ", Mask Ref=" << mMask << ") ";
}
inline bool
RecordedPopLayer::PlayEvent(Translator *aTranslator) const
{
@ -3411,6 +3492,7 @@ RecordedFilterNodeSetInput::OutputSimpleEventInfo(std::stringstream &aStringStre
f(FONTDATA, RecordedFontData); \
f(FONTDESC, RecordedFontDescriptor); \
f(PUSHLAYER, RecordedPushLayer); \
f(PUSHLAYERWITHBLEND, RecordedPushLayerWithBlend); \
f(POPLAYER, RecordedPopLayer); \
f(UNSCALEDFONTCREATION, RecordedUnscaledFontCreation); \
f(UNSCALEDFONTDESTRUCTION, RecordedUnscaledFontDestruction); \

Просмотреть файл

@ -42,7 +42,7 @@ public:
CreateDataTextureSource(TextureFlags aFlags = TextureFlags::NO_FLAGS) override;
virtual bool CanUseCanvasLayerForSize(const gfx::IntSize& aSize) override;
virtual int32_t GetMaxTextureSize() const final override;
int32_t GetMaxTextureSize() const final;
virtual void MakeCurrent(MakeCurrentFlags aFlags = 0) override {}

Просмотреть файл

@ -24,17 +24,17 @@ public:
PMPrintSettings aPrintSettings,
const IntSize& aSize);
virtual nsresult BeginPrinting(const nsAString& aTitle,
const nsAString& aPrintToFileName,
int32_t aStartPage,
int32_t aEndPage) final override;
virtual nsresult EndPrinting() final override;
virtual nsresult AbortPrinting() final override;
virtual nsresult BeginPage() final override;
virtual nsresult EndPage() final override;
nsresult BeginPrinting(const nsAString& aTitle,
const nsAString& aPrintToFileName,
int32_t aStartPage,
int32_t aEndPage) final;
nsresult EndPrinting() final;
nsresult AbortPrinting() final;
nsresult BeginPage() final;
nsresult EndPage() final;
virtual already_AddRefed<DrawTarget>
GetReferenceDrawTarget() final override;
GetReferenceDrawTarget() final;
private:
PrintTargetCG(PMPrintSession aPrintSession,

Просмотреть файл

@ -41,18 +41,18 @@ public:
nsresult BeginPrinting(const nsAString& aTitle,
const nsAString& aPrintToFileName,
int32_t aStartPage,
int32_t aEndPage) final override;
nsresult EndPrinting() final override;
nsresult AbortPrinting() final override;
nsresult BeginPage() final override;
nsresult EndPage() final override;
int32_t aEndPage) final;
nsresult EndPrinting() final;
nsresult AbortPrinting() final;
nsresult BeginPage() final;
nsresult EndPage() final;
already_AddRefed<DrawTarget>
MakeDrawTarget(const IntSize& aSize,
DrawEventRecorder* aRecorder = nullptr) final override;
DrawEventRecorder* aRecorder = nullptr) final;
already_AddRefed<DrawTarget>
GetReferenceDrawTarget() final override;
GetReferenceDrawTarget() final;
void ConvertToEMFDone(const nsresult& aResult, mozilla::ipc::Shmem&& aEMF);
bool IsSyncPagePrinting() const final { return false; }

Просмотреть файл

@ -39,12 +39,11 @@ public:
virtual nsresult BeginPage() override;
virtual nsresult EndPage() override;
virtual already_AddRefed<DrawTarget>
already_AddRefed<DrawTarget>
MakeDrawTarget(const IntSize& aSize,
DrawEventRecorder* aRecorder = nullptr) final override;
DrawEventRecorder* aRecorder = nullptr) final;
virtual already_AddRefed<DrawTarget>
GetReferenceDrawTarget() override final;
already_AddRefed<DrawTarget> GetReferenceDrawTarget() final;
private:
PrintTargetSkPDF(const IntSize& aSize,

Просмотреть файл

@ -43,7 +43,7 @@ public:
MakeDrawTarget(const IntSize& aSize,
DrawEventRecorder* aRecorder = nullptr) override;
virtual already_AddRefed<DrawTarget> GetReferenceDrawTarget() final override;
already_AddRefed<DrawTarget> GetReferenceDrawTarget() final;
private:

Просмотреть файл

@ -375,7 +375,7 @@ public:
TimeDuration mVsyncDuration;
};
Display& GetGlobalDisplay() final override { return GetDisplayInstance(); }
Display& GetGlobalDisplay() final { return GetDisplayInstance(); }
private:
virtual ~AndroidVsyncSource() {}

Просмотреть файл

@ -60,23 +60,23 @@ public:
mIsSystemFontFamily(aIsSystemFontFamily), mForceGDIClassic(false) {}
virtual ~gfxDWriteFontFamily();
void FindStyleVariations(FontInfoData *aFontInfoData = nullptr) final override;
void FindStyleVariations(FontInfoData *aFontInfoData = nullptr) final;
void LocalizedName(nsAString& aLocalizedName) final override;
void LocalizedName(nsAString& aLocalizedName) final;
void ReadFaceNames(gfxPlatformFontList *aPlatformFontList,
bool aNeedFullnamePostscriptNames,
FontInfoData *aFontInfoData = nullptr) final override;
FontInfoData *aFontInfoData = nullptr) final;
void SetForceGDIClassic(bool aForce) { mForceGDIClassic = aForce; }
void AddSizeOfExcludingThis(mozilla::MallocSizeOf aMallocSizeOf,
FontListSizes* aSizes) const final override;
FontListSizes* aSizes) const final;
void AddSizeOfIncludingThis(mozilla::MallocSizeOf aMallocSizeOf,
FontListSizes* aSizes) const final override;
FontListSizes* aSizes) const final;
bool FilterForFontList(nsAtom* aLangGroup,
const nsACString& aGeneric) const final override {
const nsACString& aGeneric) const final {
return !IsSymbolFontFamily();
}

Просмотреть файл

@ -229,7 +229,7 @@ public:
bool aIgnoreSizeTolerance) override;
bool FilterForFontList(nsAtom* aLangGroup,
const nsACString& aGeneric) const final override {
const nsACString& aGeneric) const final {
return SupportsLangGroup(aLangGroup);
}

Некоторые файлы не были показаны из-за слишком большого количества измененных файлов Показать больше