зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1477343 - Remove PBrowser::IsParentWindowMainWidgetVisible. r=mccr8,bzbarsky
Differential Revision: https://phabricator.services.mozilla.com/D2347 --HG-- extra : moz-landing-system : lando
This commit is contained in:
Родитель
02f535024e
Коммит
e4a0da7d25
|
@ -3551,6 +3551,10 @@ nsDOMWindowUtils::AllowScriptsToClose()
|
|||
NS_IMETHODIMP
|
||||
nsDOMWindowUtils::GetIsParentWindowMainWidgetVisible(bool* aIsVisible)
|
||||
{
|
||||
if (!XRE_IsParentProcess()) {
|
||||
MOZ_CRASH("IsParentWindowMainWidgetVisible is only available in the parent process");
|
||||
}
|
||||
|
||||
// this should reflect the "is parent window visible" logic in
|
||||
// nsWindowWatcher::OpenWindowInternal()
|
||||
nsCOMPtr<nsPIDOMWindowOuter> window = do_QueryReferent(mWindow);
|
||||
|
@ -3559,12 +3563,6 @@ nsDOMWindowUtils::GetIsParentWindowMainWidgetVisible(bool* aIsVisible)
|
|||
nsCOMPtr<nsIWidget> parentWidget;
|
||||
nsIDocShell *docShell = window->GetDocShell();
|
||||
if (docShell) {
|
||||
if (TabChild *tabChild = TabChild::GetFrom(docShell)) {
|
||||
if (!tabChild->SendIsParentWindowMainWidgetVisible(aIsVisible))
|
||||
return NS_ERROR_FAILURE;
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
nsCOMPtr<nsIDocShellTreeOwner> parentTreeOwner;
|
||||
docShell->GetTreeOwner(getter_AddRefs(parentTreeOwner));
|
||||
nsCOMPtr<nsIBaseWindow> parentWindow(do_GetInterface(parentTreeOwner));
|
||||
|
|
|
@ -359,8 +359,6 @@ parent:
|
|||
nested(inside_cpow) async SetInputContext(InputContext context,
|
||||
InputContextAction action);
|
||||
|
||||
sync IsParentWindowMainWidgetVisible() returns (bool visible);
|
||||
|
||||
/**
|
||||
* Set the native cursor.
|
||||
* @param value
|
||||
|
|
|
@ -2491,26 +2491,6 @@ TabParent::RecvSetInputContext(
|
|||
return IPC_OK();
|
||||
}
|
||||
|
||||
mozilla::ipc::IPCResult
|
||||
TabParent::RecvIsParentWindowMainWidgetVisible(bool* aIsVisible)
|
||||
{
|
||||
// XXXbz This looks unused; can we just remove it?
|
||||
nsCOMPtr<nsIContent> frame = do_QueryInterface(mFrameElement);
|
||||
if (!frame)
|
||||
return IPC_OK();
|
||||
nsGlobalWindowOuter* outer =
|
||||
nsGlobalWindowOuter::Cast(frame->OwnerDoc()->GetWindow());
|
||||
if (!outer)
|
||||
return IPC_OK();
|
||||
|
||||
nsCOMPtr<nsIDOMWindowUtils> windowUtils = outer->WindowUtils();
|
||||
nsresult rv = windowUtils->GetIsParentWindowMainWidgetVisible(aIsVisible);
|
||||
if (NS_FAILED(rv)) {
|
||||
return IPC_FAIL_NO_REASON(this);
|
||||
}
|
||||
return IPC_OK();
|
||||
}
|
||||
|
||||
already_AddRefed<nsIWidget>
|
||||
TabParent::GetTopLevelWidget()
|
||||
{
|
||||
|
|
|
@ -283,8 +283,6 @@ public:
|
|||
virtual mozilla::ipc::IPCResult RecvSetStatus(const uint32_t& aType,
|
||||
const nsString& aStatus) override;
|
||||
|
||||
virtual mozilla::ipc::IPCResult RecvIsParentWindowMainWidgetVisible(bool* aIsVisible) override;
|
||||
|
||||
virtual mozilla::ipc::IPCResult RecvShowTooltip(const uint32_t& aX,
|
||||
const uint32_t& aY,
|
||||
const nsString& aTooltip,
|
||||
|
|
|
@ -830,9 +830,6 @@ description =
|
|||
description =
|
||||
[PBrowser::GetInputContext]
|
||||
description =
|
||||
[PBrowser::IsParentWindowMainWidgetVisible]
|
||||
description =
|
||||
description =
|
||||
[PBrowser::RequestNativeKeyBindings]
|
||||
description =
|
||||
[PBrowser::DispatchWheelEvent]
|
||||
|
|
Загрузка…
Ссылка в новой задаче