diff --git a/accessible/jsat/EventManager.jsm b/accessible/jsat/EventManager.jsm index c9f72ec6f3b..b074469c740 100644 --- a/accessible/jsat/EventManager.jsm +++ b/accessible/jsat/EventManager.jsm @@ -266,7 +266,8 @@ this.EventManager.prototype = { case Events.DOCUMENT_LOAD_COMPLETE: { let position = this.contentControl.vc.position; - if (position && Utils.isInSubtree(position, aEvent.accessible)) { + if (aEvent.accessible === aEvent.accessibleDocument || + (position && Utils.isInSubtree(position, aEvent.accessible))) { // Do not automove into the document if the virtual cursor is already // positioned inside it. break; diff --git a/browser/base/content/tabbrowser.xml b/browser/base/content/tabbrowser.xml index 9ebd42bcc2a..bfa5180cf92 100644 --- a/browser/base/content/tabbrowser.xml +++ b/browser/base/content/tabbrowser.xml @@ -4834,7 +4834,8 @@ class="tab-content" align="center"> + role="presentation" + layer="true" /> @@ -405,7 +412,7 @@ loop.panel = (function(_, mozL10n) { }, render: function() { - if (navigator.mozLoop.userProfile) { + if (!navigator.mozLoop.fxAEnabled || navigator.mozLoop.userProfile) { return null; } return ( @@ -582,6 +589,7 @@ loop.panel = (function(_, mozL10n) { return { init: init, UserIdentity: UserIdentity, + AuthLink: AuthLink, AvailabilityDropdown: AvailabilityDropdown, CallUrlResult: CallUrlResult, PanelView: PanelView, diff --git a/browser/components/loop/test/desktop-local/panel_test.js b/browser/components/loop/test/desktop-local/panel_test.js index 0d805ea75af..8888dc43b65 100644 --- a/browser/components/loop/test/desktop-local/panel_test.js +++ b/browser/components/loop/test/desktop-local/panel_test.js @@ -25,6 +25,7 @@ describe("loop.panel", function() { navigator.mozLoop = { doNotDisturb: true, + fxAEnabled: true, getStrings: function() { return JSON.stringify({textContent: "fakeText"}); }, @@ -177,8 +178,19 @@ describe("loop.panel", function() { sinon.assert.calledOnce(navigator.mozLoop.logInToFxA); }); + + it("should be hidden if FxA is not enabled", + function() { + navigator.mozLoop.fxAEnabled = false; + var view = TestUtils.renderIntoDocument(loop.panel.AuthLink()); + expect(view.getDOMNode()).to.be.null; }); + afterEach(function() { + navigator.mozLoop.fxAEnabled = true; + }); + }); + describe("SettingsDropdown", function() { var view; @@ -188,6 +200,17 @@ describe("loop.panel", function() { navigator.mozLoop.openFxASettings = sandbox.stub(); }); + afterEach(function() { + navigator.mozLoop.fxAEnabled = true; + }); + + it("should be hidden if FxA is not enabled", + function() { + navigator.mozLoop.fxAEnabled = false; + var view = TestUtils.renderIntoDocument(loop.panel.SettingsDropdown()); + expect(view.getDOMNode()).to.be.null; + }); + it("should show a signin entry when user is not authenticated", function() { navigator.mozLoop.loggedInToFxA = false; diff --git a/browser/devtools/debugger/test/browser.ini b/browser/devtools/debugger/test/browser.ini index 1222b822c96..52f369a6784 100644 --- a/browser/devtools/debugger/test/browser.ini +++ b/browser/devtools/debugger/test/browser.ini @@ -139,6 +139,7 @@ skip-if = os == "mac" || e10s # Bug 895426 [browser_dbg_breakpoints-other-tabs.js] [browser_dbg_breakpoints-pane.js] [browser_dbg_breakpoints-reload.js] +skip-if = (os == "linux") && debug # Bug 1076830 [browser_dbg_chrome-create.js] [browser_dbg_chrome-debugging.js] [browser_dbg_clean-exit-window.js] diff --git a/browser/themes/linux/tabbrowser/connecting.png b/browser/themes/linux/tabbrowser/connecting.png index 33075734e9e..e564fb5708f 100644 Binary files a/browser/themes/linux/tabbrowser/connecting.png and b/browser/themes/linux/tabbrowser/connecting.png differ diff --git a/browser/themes/linux/tabbrowser/loading.png b/browser/themes/linux/tabbrowser/loading.png index a59c531602b..a2f9b797098 100644 Binary files a/browser/themes/linux/tabbrowser/loading.png and b/browser/themes/linux/tabbrowser/loading.png differ diff --git a/browser/themes/osx/tabbrowser/connecting.png b/browser/themes/osx/tabbrowser/connecting.png index 33075734e9e..e564fb5708f 100644 Binary files a/browser/themes/osx/tabbrowser/connecting.png and b/browser/themes/osx/tabbrowser/connecting.png differ diff --git a/browser/themes/osx/tabbrowser/connecting@2x.png b/browser/themes/osx/tabbrowser/connecting@2x.png index 439cfc39a5b..97e2b2eb67e 100644 Binary files a/browser/themes/osx/tabbrowser/connecting@2x.png and b/browser/themes/osx/tabbrowser/connecting@2x.png differ diff --git a/browser/themes/osx/tabbrowser/loading.png b/browser/themes/osx/tabbrowser/loading.png index 30bce927b44..b886c73eff9 100644 Binary files a/browser/themes/osx/tabbrowser/loading.png and b/browser/themes/osx/tabbrowser/loading.png differ diff --git a/browser/themes/osx/tabbrowser/loading@2x.png b/browser/themes/osx/tabbrowser/loading@2x.png index cf2ceb08bcf..ac928c58537 100644 Binary files a/browser/themes/osx/tabbrowser/loading@2x.png and b/browser/themes/osx/tabbrowser/loading@2x.png differ diff --git a/browser/themes/shared/tabs.inc.css b/browser/themes/shared/tabs.inc.css index b3360d3c960..db768b88d81 100644 --- a/browser/themes/shared/tabs.inc.css +++ b/browser/themes/shared/tabs.inc.css @@ -76,30 +76,12 @@ list-style-image: url("chrome://mozapps/skin/places/defaultFavicon.png"); } -@keyframes throbber-loading { - to { - transform: rotate(360deg); - } -} - -@keyframes throbber-connecting { - from { - transform: rotate(360deg); - } -} - .tab-throbber[busy] { list-style-image: url("chrome://browser/skin/tabbrowser/connecting.png"); - animation-duration: 960ms; - animation-iteration-count: infinite; - animation-name: throbber-connecting; - animation-timing-function: linear; } .tab-throbber[progress] { list-style-image: url("chrome://browser/skin/tabbrowser/loading.png"); - animation-duration: 800ms; - animation-name: throbber-loading; } .tab-throbber:not([pinned]), diff --git a/browser/themes/windows/tabbrowser/connecting.png b/browser/themes/windows/tabbrowser/connecting.png index b9e04449a16..e564fb5708f 100644 Binary files a/browser/themes/windows/tabbrowser/connecting.png and b/browser/themes/windows/tabbrowser/connecting.png differ diff --git a/browser/themes/windows/tabbrowser/loading.png b/browser/themes/windows/tabbrowser/loading.png index 5e36ba32a18..ba54836e983 100644 Binary files a/browser/themes/windows/tabbrowser/loading.png and b/browser/themes/windows/tabbrowser/loading.png differ diff --git a/content/base/public/FragmentOrElement.h b/content/base/public/FragmentOrElement.h index 0f6996fb28a..c53bf789467 100644 --- a/content/base/public/FragmentOrElement.h +++ b/content/base/public/FragmentOrElement.h @@ -51,7 +51,6 @@ public: explicit nsChildContentList(nsINode* aNode) : mNode(aNode) { - SetIsDOMBinding(); } NS_DECL_CYCLE_COLLECTING_ISUPPORTS diff --git a/content/base/public/nsDOMFile.h b/content/base/public/nsDOMFile.h index c6e3416629c..968317d4e25 100644 --- a/content/base/public/nsDOMFile.h +++ b/content/base/public/nsDOMFile.h @@ -754,7 +754,6 @@ class nsDOMFileList MOZ_FINAL : public nsIDOMFileList, public: explicit nsDOMFileList(nsISupports *aParent) : mParent(aParent) { - SetIsDOMBinding(); } NS_DECL_CYCLE_COLLECTING_ISUPPORTS diff --git a/content/base/public/nsINode.h b/content/base/public/nsINode.h index 3d20dfae834..9ea6b369d5b 100644 --- a/content/base/public/nsINode.h +++ b/content/base/public/nsINode.h @@ -320,7 +320,6 @@ public: mSubtreeRoot(MOZ_THIS_IN_INITIALIZER_LIST()), mSlots(nullptr) { - SetIsDOMBinding(); } #endif @@ -381,11 +380,7 @@ protected: * does some additional checks and fix-up that's common to all nodes. WrapNode * should just call the DOM binding's Wrap function. */ - virtual JSObject* WrapNode(JSContext *aCx) - { - MOZ_ASSERT(!IsDOMBinding(), "Someone forgot to override WrapNode"); - return nullptr; - } + virtual JSObject* WrapNode(JSContext *aCx) = 0; // Subclasses that wish to override the parent behavior should return the // result of GetParentObjectIntenral, which handles the XBL scope stuff. diff --git a/content/base/src/Attr.cpp b/content/base/src/Attr.cpp index 78f359038ab..b1f92f06eef 100644 --- a/content/base/src/Attr.cpp +++ b/content/base/src/Attr.cpp @@ -54,8 +54,6 @@ Attr::Attr(nsDOMAttributeMap *aAttrMap, // We don't add a reference to our content. It will tell us // to drop our reference when it goes away. - - SetIsDOMBinding(); } NS_IMPL_CYCLE_COLLECTION_CLASS(Attr) @@ -388,7 +386,7 @@ Attr::Shutdown() } JSObject* -Attr::WrapObject(JSContext* aCx) +Attr::WrapNode(JSContext* aCx) { return AttrBinding::Wrap(aCx, this); } diff --git a/content/base/src/Attr.h b/content/base/src/Attr.h index 756c260df65..3305a9e7519 100644 --- a/content/base/src/Attr.h +++ b/content/base/src/Attr.h @@ -82,7 +82,7 @@ public: virtual nsIDOMNode* AsDOMNode() { return this; } // WebIDL - virtual JSObject* WrapObject(JSContext* aCx) MOZ_OVERRIDE; + virtual JSObject* WrapNode(JSContext* aCx) MOZ_OVERRIDE; // XPCOM GetName() is OK // XPCOM GetValue() is OK diff --git a/content/base/src/DOMImplementation.h b/content/base/src/DOMImplementation.h index fb986b55674..1dd114cbb42 100644 --- a/content/base/src/DOMImplementation.h +++ b/content/base/src/DOMImplementation.h @@ -42,7 +42,6 @@ public: , mBaseURI(aBaseURI) { MOZ_ASSERT(aOwner); - SetIsDOMBinding(); } NS_DECL_CYCLE_COLLECTING_ISUPPORTS diff --git a/content/base/src/DOMMatrix.h b/content/base/src/DOMMatrix.h index ade2b5b6d5b..184f68d6644 100644 --- a/content/base/src/DOMMatrix.h +++ b/content/base/src/DOMMatrix.h @@ -28,7 +28,6 @@ public: explicit DOMMatrixReadOnly(nsISupports* aParent) : mParent(aParent), mMatrix2D(new gfx::Matrix()) { - SetIsDOMBinding(); } DOMMatrixReadOnly(nsISupports* aParent, const DOMMatrixReadOnly& other) @@ -39,8 +38,6 @@ public: } else { mMatrix3D = new gfx::Matrix4x4(*other.mMatrix3D); } - - SetIsDOMBinding(); } #define GetMatrixMember(entry2D, entry3D, default) \ diff --git a/content/base/src/DOMParser.cpp b/content/base/src/DOMParser.cpp index 01032cbc69c..04d169424ce 100644 --- a/content/base/src/DOMParser.cpp +++ b/content/base/src/DOMParser.cpp @@ -25,7 +25,6 @@ using namespace mozilla::dom; DOMParser::DOMParser() : mAttemptedInit(false) { - SetIsDOMBinding(); } DOMParser::~DOMParser() diff --git a/content/base/src/DOMParser.h b/content/base/src/DOMParser.h index b9002086a12..287426d4d3a 100644 --- a/content/base/src/DOMParser.h +++ b/content/base/src/DOMParser.h @@ -84,7 +84,6 @@ private: explicit DOMParser(nsISupports* aOwner) : mOwner(aOwner), mAttemptedInit(false) { MOZ_ASSERT(aOwner); - SetIsDOMBinding(); } nsresult InitInternal(nsISupports* aOwner, nsIPrincipal* prin, diff --git a/content/base/src/DOMPoint.h b/content/base/src/DOMPoint.h index b5c1631f45d..f89d4598656 100644 --- a/content/base/src/DOMPoint.h +++ b/content/base/src/DOMPoint.h @@ -31,7 +31,6 @@ public: , mZ(aZ) , mW(aW) { - SetIsDOMBinding(); } double X() const { return mX; } diff --git a/content/base/src/DOMQuad.cpp b/content/base/src/DOMQuad.cpp index 8435781c29d..2f0b912cdf2 100644 --- a/content/base/src/DOMQuad.cpp +++ b/content/base/src/DOMQuad.cpp @@ -23,7 +23,6 @@ NS_IMPL_CYCLE_COLLECTION_UNROOT_NATIVE(DOMQuad, Release) DOMQuad::DOMQuad(nsISupports* aParent, CSSPoint aPoints[4]) : mParent(aParent) { - SetIsDOMBinding(); for (uint32_t i = 0; i < 4; ++i) { mPoints[i] = new DOMPoint(aParent, aPoints[i].x, aPoints[i].y); } @@ -32,7 +31,6 @@ DOMQuad::DOMQuad(nsISupports* aParent, CSSPoint aPoints[4]) DOMQuad::DOMQuad(nsISupports* aParent) : mParent(aParent) { - SetIsDOMBinding(); } DOMQuad::~DOMQuad() diff --git a/content/base/src/DOMRect.h b/content/base/src/DOMRect.h index 61146b4a3d0..a3f8510f911 100644 --- a/content/base/src/DOMRect.h +++ b/content/base/src/DOMRect.h @@ -36,7 +36,6 @@ public: explicit DOMRectReadOnly(nsISupports* aParent) : mParent(aParent) { - SetIsDOMBinding(); } nsISupports* GetParentObject() const @@ -155,7 +154,6 @@ class DOMRectList MOZ_FINAL : public nsIDOMClientRectList, public: explicit DOMRectList(nsISupports *aParent) : mParent(aParent) { - SetIsDOMBinding(); } NS_DECL_CYCLE_COLLECTING_ISUPPORTS diff --git a/content/base/src/DOMStringList.h b/content/base/src/DOMStringList.h index bad5db70faf..87e9fd9c429 100644 --- a/content/base/src/DOMStringList.h +++ b/content/base/src/DOMStringList.h @@ -21,11 +21,6 @@ protected: virtual ~DOMStringList(); public: - DOMStringList() - { - SetIsDOMBinding(); - } - NS_DECL_CYCLE_COLLECTING_ISUPPORTS NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_CLASS(DOMStringList) diff --git a/content/base/src/Element.cpp b/content/base/src/Element.cpp index 072bfb9af6a..99c32e4f5e3 100644 --- a/content/base/src/Element.cpp +++ b/content/base/src/Element.cpp @@ -876,8 +876,6 @@ NS_IMPL_CYCLE_COLLECTING_RELEASE(DestinationInsertionPointList) DestinationInsertionPointList::DestinationInsertionPointList(Element* aElement) : mParent(aElement) { - SetIsDOMBinding(); - nsTArray* destPoints = aElement->GetExistingDestInsertionPoints(); if (destPoints) { for (uint32_t i = 0; i < destPoints->Length(); i++) { diff --git a/content/base/src/StyleSheetList.h b/content/base/src/StyleSheetList.h index 88badb55ede..be0006cb54f 100644 --- a/content/base/src/StyleSheetList.h +++ b/content/base/src/StyleSheetList.h @@ -20,11 +20,6 @@ class StyleSheetList : public nsIDOMStyleSheetList , public nsWrapperCache { public: - StyleSheetList() - { - SetIsDOMBinding(); - } - NS_DECL_CYCLE_COLLECTING_ISUPPORTS NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_CLASS(StyleSheetList) NS_DECL_NSIDOMSTYLESHEETLIST diff --git a/content/base/src/nsContentList.h b/content/base/src/nsContentList.h index 41223052863..30c8aef99a5 100644 --- a/content/base/src/nsContentList.h +++ b/content/base/src/nsContentList.h @@ -39,11 +39,6 @@ class Element; class nsBaseContentList : public nsINodeList { public: - nsBaseContentList() - { - SetIsDOMBinding(); - } - NS_DECL_CYCLE_COLLECTING_ISUPPORTS // nsIDOMNodeList diff --git a/content/base/src/nsDOMAttributeMap.cpp b/content/base/src/nsDOMAttributeMap.cpp index 7310e2ecb9a..1d63af7d778 100644 --- a/content/base/src/nsDOMAttributeMap.cpp +++ b/content/base/src/nsDOMAttributeMap.cpp @@ -34,7 +34,6 @@ nsDOMAttributeMap::nsDOMAttributeMap(Element* aContent) { // We don't add a reference to our content. If it goes away, // we'll be told to drop our reference - SetIsDOMBinding(); } /** diff --git a/content/base/src/nsDOMCaretPosition.cpp b/content/base/src/nsDOMCaretPosition.cpp index faaee946ec5..cbf68be7e19 100644 --- a/content/base/src/nsDOMCaretPosition.cpp +++ b/content/base/src/nsDOMCaretPosition.cpp @@ -13,7 +13,6 @@ using namespace mozilla::dom; nsDOMCaretPosition::nsDOMCaretPosition(nsINode* aNode, uint32_t aOffset) : mOffset(aOffset), mOffsetNode(aNode), mAnonymousContentNode(nullptr) { - SetIsDOMBinding(); } nsDOMCaretPosition::~nsDOMCaretPosition() diff --git a/content/base/src/nsDOMFileReader.cpp b/content/base/src/nsDOMFileReader.cpp index 0a622bb7441..f7f12d00280 100644 --- a/content/base/src/nsDOMFileReader.cpp +++ b/content/base/src/nsDOMFileReader.cpp @@ -87,7 +87,6 @@ nsDOMFileReader::nsDOMFileReader() mResultArrayBuffer(nullptr) { SetDOMStringToNull(mResult); - SetIsDOMBinding(); } nsDOMFileReader::~nsDOMFileReader() diff --git a/content/base/src/nsDOMMutationObserver.h b/content/base/src/nsDOMMutationObserver.h index 0020807b6e3..2fa0934231c 100644 --- a/content/base/src/nsDOMMutationObserver.h +++ b/content/base/src/nsDOMMutationObserver.h @@ -37,7 +37,6 @@ public: nsDOMMutationRecord(nsIAtom* aType, nsISupports* aOwner) : mType(aType), mAttrNamespace(NullString()), mPrevValue(NullString()), mOwner(aOwner) { - SetIsDOMBinding(); } nsISupports* GetParentObject() const @@ -347,7 +346,6 @@ public: : mOwner(aOwner), mLastPendingMutation(nullptr), mPendingMutationCount(0), mCallback(&aCb), mWaitingForRun(false), mId(++sCount) { - SetIsDOMBinding(); } NS_DECL_CYCLE_COLLECTING_ISUPPORTS NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_CLASS(nsDOMMutationObserver) diff --git a/content/base/src/nsDOMSerializer.cpp b/content/base/src/nsDOMSerializer.cpp index 8998a8347a7..cb26fb24538 100644 --- a/content/base/src/nsDOMSerializer.cpp +++ b/content/base/src/nsDOMSerializer.cpp @@ -18,7 +18,6 @@ using namespace mozilla; nsDOMSerializer::nsDOMSerializer() { - SetIsDOMBinding(); } nsDOMSerializer::~nsDOMSerializer() diff --git a/content/base/src/nsDOMSerializer.h b/content/base/src/nsDOMSerializer.h index 27c4d0877bc..b8459593829 100644 --- a/content/base/src/nsDOMSerializer.h +++ b/content/base/src/nsDOMSerializer.h @@ -59,7 +59,6 @@ private: explicit nsDOMSerializer(nsISupports* aOwner) : mOwner(aOwner) { MOZ_ASSERT(aOwner); - SetIsDOMBinding(); } nsCOMPtr mOwner; diff --git a/content/base/src/nsDOMTokenList.cpp b/content/base/src/nsDOMTokenList.cpp index 9a2d87bc595..856718566f5 100644 --- a/content/base/src/nsDOMTokenList.cpp +++ b/content/base/src/nsDOMTokenList.cpp @@ -24,7 +24,6 @@ nsDOMTokenList::nsDOMTokenList(Element* aElement, nsIAtom* aAttrAtom) { // We don't add a reference to our element. If it goes away, // we'll be told to drop our reference - SetIsDOMBinding(); } nsDOMTokenList::~nsDOMTokenList() { } diff --git a/content/base/src/nsFormData.cpp b/content/base/src/nsFormData.cpp index c5bd9edba32..b327a833623 100644 --- a/content/base/src/nsFormData.cpp +++ b/content/base/src/nsFormData.cpp @@ -16,7 +16,6 @@ nsFormData::nsFormData(nsISupports* aOwner) : nsFormSubmission(NS_LITERAL_CSTRING("UTF-8"), nullptr) , mOwner(aOwner) { - SetIsDOMBinding(); } // ------------------------------------------------------------------------- diff --git a/content/base/src/nsINode.cpp b/content/base/src/nsINode.cpp index 8e3a95c5567..f559e98a05d 100644 --- a/content/base/src/nsINode.cpp +++ b/content/base/src/nsINode.cpp @@ -2674,8 +2674,6 @@ nsINode::GetElementById(const nsAString& aId) JSObject* nsINode::WrapObject(JSContext *aCx) { - MOZ_ASSERT(IsDOMBinding()); - // Make sure one of these is true // (1) our owner document has a script handling object, // (2) Our owner document has had a script handling object, or has been marked diff --git a/content/base/src/nsInProcessTabChildGlobal.cpp b/content/base/src/nsInProcessTabChildGlobal.cpp index a80a5b2506c..04500690f86 100644 --- a/content/base/src/nsInProcessTabChildGlobal.cpp +++ b/content/base/src/nsInProcessTabChildGlobal.cpp @@ -103,6 +103,7 @@ nsInProcessTabChildGlobal::nsInProcessTabChildGlobal(nsIDocShell* aShell, : mDocShell(aShell), mInitialized(false), mLoadingScript(false), mOwner(aOwner), mChromeMessageManager(aChrome) { + SetIsNotDOMBinding(); mozilla::HoldJSObjects(this); // If owner corresponds to an