diff --git a/content/base/public/nsIFrameLoader.idl b/content/base/public/nsIFrameLoader.idl index f17c97658de..0d1bc55a182 100644 --- a/content/base/public/nsIFrameLoader.idl +++ b/content/base/public/nsIFrameLoader.idl @@ -141,7 +141,7 @@ interface nsIContentViewManager : nsISupports readonly attribute nsIContentView rootContentView; }; -[scriptable, uuid(50a67436-bb44-11df-8d9a-001e37d2764a)] +[scriptable, uuid(13c512d6-fba0-402a-9244-fe7941c43965)] interface nsIFrameLoader : nsISupports { /** @@ -217,16 +217,23 @@ interface nsIFrameLoader : nsISupports attribute boolean delayRemoteDialogs; + /** + * The default rendering mode is synchronous scrolling. In this + * mode, it's an error to try to set a target viewport. + */ + const unsigned long RENDER_MODE_DEFAULT = 0x00000000; /** - * DEPRECATED. Please QI to nsIContentViewManager. - * FIXME 615368 + * When asynchronous scrolling is enabled, a target viewport can be + * set to transform content pixels wrt its CSS viewport. + * + * NB: when async scrolling is enabled, it's the *user's* + * responsibility to update the target scroll offset. In effect, + * the platform hands over control of scroll offset to the user. */ - void scrollViewportTo(in float xPx, in float yPx); - void scrollViewportBy(in float dxPx, in float dyPx); - void setViewportScale(in float xScale, in float yScale); - readonly attribute float viewportScrollX; - readonly attribute float viewportScrollY; + const unsigned long RENDER_MODE_ASYNC_SCROLL = 0x00000001; + + attribute unsigned long renderMode; }; native alreadyAddRefed_nsFrameLoader(already_AddRefed); @@ -252,25 +259,3 @@ interface nsIFrameLoaderOwner : nsISupports */ void swapFrameLoaders(in nsIFrameLoaderOwner aOtherOwner); }; - -/** Please merge me into something else after 2.0 branches. */ -[scriptable, uuid(e3e2d3f8-1397-4984-abb3-435c29a1ca55)] -interface nsIFrameLoader_MOZILLA_2_0_BRANCH : nsISupports -{ - /** - * The default rendering mode is synchronous scrolling. In this - * mode, it's an error to try to set a target viewport. - */ - const unsigned long RENDER_MODE_DEFAULT = 0x00000000; - /** - * When asynchronous scrolling is enabled, a target viewport can be - * set to transform content pixels wrt its CSS viewport. - * - * NB: when async scrolling is enabled, it's the *user's* - * responsibility to update the target scroll offset. In effect, - * the platform hands over control of scroll offset to the user. - */ - const unsigned long RENDER_MODE_ASYNC_SCROLL = 0x00000001; - - attribute unsigned long renderMode; -}; diff --git a/content/base/src/nsFrameLoader.cpp b/content/base/src/nsFrameLoader.cpp index 8922a726a22..f10ab414b47 100644 --- a/content/base/src/nsFrameLoader.cpp +++ b/content/base/src/nsFrameLoader.cpp @@ -310,7 +310,6 @@ NS_IMPL_CYCLE_COLLECTING_RELEASE_AMBIGUOUS(nsFrameLoader, nsIFrameLoader) NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION(nsFrameLoader) NS_INTERFACE_MAP_ENTRY(nsIFrameLoader) - NS_INTERFACE_MAP_ENTRY(nsIFrameLoader_MOZILLA_2_0_BRANCH) NS_INTERFACE_MAP_ENTRY(nsIContentViewManager) NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(nsISupports, nsIFrameLoader) NS_INTERFACE_MAP_END @@ -1684,36 +1683,6 @@ nsFrameLoader::UpdateBaseWindowPositionAndSize(nsIFrame *aIFrame) return NS_OK; } -NS_IMETHODIMP -nsFrameLoader::ScrollViewportTo(float aXpx, float aYpx) -{ - return NS_ERROR_NOT_IMPLEMENTED; -} - -NS_IMETHODIMP -nsFrameLoader::ScrollViewportBy(float aDXpx, float aDYpx) -{ - return NS_ERROR_NOT_IMPLEMENTED; -} - -NS_IMETHODIMP -nsFrameLoader::SetViewportScale(float aXScale, float aYScale) -{ - return NS_ERROR_NOT_IMPLEMENTED; -} - -NS_IMETHODIMP -nsFrameLoader::GetViewportScrollX(float* aViewportScrollX) -{ - return NS_ERROR_NOT_IMPLEMENTED; -} - -NS_IMETHODIMP -nsFrameLoader::GetViewportScrollY(float* aViewportScrollY) -{ - return NS_ERROR_NOT_IMPLEMENTED; -} - NS_IMETHODIMP nsFrameLoader::GetRenderMode(PRUint32* aRenderMode) { diff --git a/content/base/src/nsFrameLoader.h b/content/base/src/nsFrameLoader.h index c34655a9e52..7df004da528 100644 --- a/content/base/src/nsFrameLoader.h +++ b/content/base/src/nsFrameLoader.h @@ -164,7 +164,6 @@ private: class nsFrameLoader : public nsIFrameLoader, - public nsIFrameLoader_MOZILLA_2_0_BRANCH, public nsIContentViewManager { friend class AutoResetInShow; @@ -196,7 +195,6 @@ public: NS_DECL_CYCLE_COLLECTING_ISUPPORTS NS_DECL_CYCLE_COLLECTION_CLASS_AMBIGUOUS(nsFrameLoader, nsIFrameLoader) NS_DECL_NSIFRAMELOADER - NS_DECL_NSIFRAMELOADER_MOZILLA_2_0_BRANCH NS_DECL_NSICONTENTVIEWMANAGER NS_HIDDEN_(nsresult) CheckForRecursiveLoad(nsIURI* aURI); nsresult ReallyStartLoading(); diff --git a/layout/ipc/test-ipcbrowser-chrome.js b/layout/ipc/test-ipcbrowser-chrome.js index dc1bb0558b3..f279ad4f886 100644 --- a/layout/ipc/test-ipcbrowser-chrome.js +++ b/layout/ipc/test-ipcbrowser-chrome.js @@ -22,9 +22,7 @@ function rootView() { } function enableAsyncScrolling() { - var i = Components.interfaces.nsIFrameLoader_MOZILLA_2_0_BRANCH; - var enabler = frameLoader().QueryInterface(i); - enabler.renderMode = i.RENDER_MODE_ASYNC_SCROLL; + frameLoader().renderMode = Components.interfaces.nsIFrameLoaer.RENDER_MODE_ASYNC_SCROLL; } // Functions affecting the content window. diff --git a/layout/tools/reftest/reftest-content.js b/layout/tools/reftest/reftest-content.js index 4b2abd2f69e..ddd735c1425 100644 --- a/layout/tools/reftest/reftest-content.js +++ b/layout/tools/reftest/reftest-content.js @@ -120,11 +120,6 @@ function windowUtils() { .getInterface(CI.nsIDOMWindowUtils); } -function windowUtils20() { - return windowUtils() - .QueryInterface(Components.interfaces.nsIDOMWindowUtils_MOZILLA_2_0_BRANCH); -} - function IDForEventTarget(event) { try { @@ -258,7 +253,7 @@ function setupDisplayport(contentRootElement) { var dph = attrOrDefault("reftest-displayport-h", 0); if (dpw !== 0 || dph !== 0) { LogInfo("Setting displayport to "); - windowUtils20().setDisplayPortForElement(0, 0, dpw, dph, content.document.documentElement); + windowUtils().setDisplayPortForElement(0, 0, dpw, dph, content.document.documentElement); } // XXX support resolution when needed