Bug 1676932 - Remove nsIContentPermissionRequester.onVisibilityChange. r=nika

Also unused.

Depends on D96881

Differential Revision: https://phabricator.services.mozilla.com/D96882
This commit is contained in:
Emilio Cobos Álvarez 2020-11-12 19:10:28 +00:00
Родитель 1239692187
Коммит fa458d34ab
2 изменённых файлов: 0 добавлений и 44 удалений

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

@ -455,29 +455,6 @@ nsContentPermissionRequester::~nsContentPermissionRequester() {
mListener = nullptr;
}
NS_IMETHODIMP
nsContentPermissionRequester::SetOnVisibilityChange(
nsIContentPermissionRequestCallback* aCallback) {
mListener->SetCallback(aCallback);
if (!aCallback) {
mListener->RemoveListener();
}
return NS_OK;
}
NS_IMETHODIMP
nsContentPermissionRequester::GetOnVisibilityChange(
nsIContentPermissionRequestCallback** aCallback) {
NS_ENSURE_ARG_POINTER(aCallback);
nsCOMPtr<nsIContentPermissionRequestCallback> callback =
mListener->GetCallback();
callback.forget(aCallback);
return NS_OK;
}
static nsIPrincipal* GetTopLevelPrincipal(nsPIDOMWindowInner* aWindow) {
MOZ_ASSERT(aWindow);
@ -770,23 +747,6 @@ NS_IMPL_ISUPPORTS(
nsContentPermissionRequestProxy::nsContentPermissionRequesterProxy,
nsIContentPermissionRequester)
NS_IMETHODIMP
nsContentPermissionRequestProxy::nsContentPermissionRequesterProxy ::
SetOnVisibilityChange(nsIContentPermissionRequestCallback* aCallback) {
mOnChangeCallback = aCallback;
return NS_OK;
}
NS_IMETHODIMP
nsContentPermissionRequestProxy::nsContentPermissionRequesterProxy ::
GetOnVisibilityChange(nsIContentPermissionRequestCallback** aCallback) {
NS_ENSURE_ARG_POINTER(aCallback);
nsCOMPtr<nsIContentPermissionRequestCallback> callback = mOnChangeCallback;
callback.forget(aCallback);
return NS_OK;
}
void nsContentPermissionRequestProxy::nsContentPermissionRequesterProxy ::
NotifyVisibilityResult(const bool& aIsVisible) {
if (mWaitGettingResult) {

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

@ -44,10 +44,6 @@ interface nsIContentPermissionRequestCallback : nsISupports {
*/
[scriptable, uuid(f8577124-6a5f-486f-ae04-c5bcae911eb5)]
interface nsIContentPermissionRequester : nsISupports {
/**
* The callback to get the notification of visibility change.
*/
attribute nsIContentPermissionRequestCallback onVisibilityChange;
};
/**