mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-12 12:55:46 +00:00
Backed out changeset f1068bf18e64 (bug 978913) for bustage on most platforms.
CLOSED TREE
This commit is contained in:
parent
391d268b8b
commit
f8299a3c22
@ -503,12 +503,6 @@ child:
|
||||
*/
|
||||
SetIsDocShellActive(bool aIsActive);
|
||||
|
||||
/**
|
||||
* Tell the child that the UI resolution changed for the containing
|
||||
* window.
|
||||
*/
|
||||
UIResolutionChanged();
|
||||
|
||||
/*
|
||||
* FIXME: write protocol!
|
||||
|
||||
|
@ -2733,17 +2733,6 @@ TabChild::OnHideTooltip()
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
bool
|
||||
TabChild::RecvUIResolutionChanged()
|
||||
{
|
||||
static_cast<PuppetWidget*>(mWidget.get())->ClearBackingScaleCache();
|
||||
nsCOMPtr<nsIDocument> document(GetDocument());
|
||||
nsCOMPtr<nsIPresShell> presShell = document->GetShell();
|
||||
nsRefPtr<nsPresContext> presContext = presShell->GetPresContext();
|
||||
presContext->UIResolutionChanged();
|
||||
return true;
|
||||
}
|
||||
|
||||
TabChildGlobal::TabChildGlobal(TabChildBase* aTabChild)
|
||||
: mTabChild(aTabChild)
|
||||
{
|
||||
|
@ -456,8 +456,6 @@ public:
|
||||
return GetFrom(docShell);
|
||||
}
|
||||
|
||||
virtual bool RecvUIResolutionChanged() MOZ_OVERRIDE;
|
||||
|
||||
protected:
|
||||
virtual PRenderFrameChild* AllocPRenderFrameChild(ScrollingBehavior* aScrolling,
|
||||
TextureFactoryIdentifier* aTextureFactoryIdentifier,
|
||||
|
@ -509,17 +509,6 @@ TabParent::UpdateFrame(const FrameMetrics& aFrameMetrics)
|
||||
}
|
||||
}
|
||||
|
||||
void
|
||||
TabParent::UIResolutionChanged()
|
||||
{
|
||||
if (!mIsDestroyed) {
|
||||
// TryCacheDPIAndScale()'s cache is keyed off of
|
||||
// mDPI being greater than 0, so this invalidates it.
|
||||
mDPI = -1;
|
||||
unused << SendUIResolutionChanged();
|
||||
}
|
||||
}
|
||||
|
||||
void
|
||||
TabParent::AcknowledgeScrollUpdate(const ViewID& aScrollId, const uint32_t& aScrollGeneration)
|
||||
{
|
||||
|
@ -198,7 +198,6 @@ public:
|
||||
void Show(const nsIntSize& size);
|
||||
void UpdateDimensions(const nsRect& rect, const nsIntSize& size);
|
||||
void UpdateFrame(const layers::FrameMetrics& aFrameMetrics);
|
||||
void UIResolutionChanged();
|
||||
void AcknowledgeScrollUpdate(const ViewID& aScrollId, const uint32_t& aScrollGeneration);
|
||||
void HandleDoubleTap(const CSSPoint& aPoint,
|
||||
int32_t aModifiers,
|
||||
|
@ -49,14 +49,11 @@
|
||||
#include "mozilla/dom/MediaQueryList.h"
|
||||
#include "nsSMILAnimationController.h"
|
||||
#include "mozilla/css/ImageLoader.h"
|
||||
#include "mozilla/dom/PBrowserParent.h"
|
||||
#include "mozilla/dom/TabChild.h"
|
||||
#include "mozilla/dom/TabParent.h"
|
||||
#include "nsRefreshDriver.h"
|
||||
#include "Layers.h"
|
||||
#include "nsIDOMEvent.h"
|
||||
#include "gfxPrefs.h"
|
||||
#include "nsIDOMChromeWindow.h"
|
||||
|
||||
#include "nsContentUtils.h"
|
||||
#include "nsCxPusher.h"
|
||||
@ -1771,35 +1768,6 @@ nsPresContext::UIResolutionChangedInternal()
|
||||
AppUnitsPerDevPixelChanged();
|
||||
}
|
||||
|
||||
nsCOMPtr<nsIDOMChromeWindow> chromeWindow(do_QueryInterface(mDocument->GetWindow()));
|
||||
nsCOMPtr<nsIMessageBroadcaster> windowMM;
|
||||
if (chromeWindow) {
|
||||
chromeWindow->GetMessageManager(getter_AddRefs(windowMM));
|
||||
}
|
||||
if (windowMM) {
|
||||
uint32_t tabChildCount = 0;
|
||||
windowMM->GetChildCount(&tabChildCount);
|
||||
for (uint32_t j = 0; j < tabChildCount; ++j) {
|
||||
nsCOMPtr<nsIMessageListenerManager> childMM;
|
||||
windowMM->GetChildAt(j, getter_AddRefs(childMM));
|
||||
if (!childMM) {
|
||||
continue;
|
||||
}
|
||||
nsCOMPtr<nsIMessageSender> tabMM = do_QueryInterface(childMM);
|
||||
|
||||
mozilla::dom::ipc::MessageManagerCallback* cb =
|
||||
static_cast<nsFrameMessageManager*>(tabMM.get())->GetCallback();
|
||||
if (cb) {
|
||||
nsFrameLoader* fl = static_cast<nsFrameLoader*>(cb);
|
||||
PBrowserParent* remoteBrowser = fl->GetRemoteBrowser();
|
||||
TabParent* remote = static_cast<TabParent*>(remoteBrowser);
|
||||
if (remote) {
|
||||
remote->UIResolutionChanged();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
mDocument->EnumerateSubDocuments(UIResolutionChangedSubdocumentCallback,
|
||||
nullptr);
|
||||
}
|
||||
|
@ -183,11 +183,6 @@ public:
|
||||
virtual bool NeedsPaint() MOZ_OVERRIDE;
|
||||
|
||||
virtual TabChild* GetOwningTabChild() MOZ_OVERRIDE { return mTabChild; }
|
||||
virtual void ClearBackingScaleCache()
|
||||
{
|
||||
mDPI = -1;
|
||||
mDefaultScale = -1;
|
||||
}
|
||||
|
||||
private:
|
||||
nsresult Paint();
|
||||
|
Loading…
Reference in New Issue
Block a user