gecko-dev/dom/interfaces/notification/nsIDOMDesktopNotification.idl

40 строки
1.4 KiB
Plaintext

/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#include "domstubs.idl"
interface nsIDOMEventListener;
interface nsIDOMDesktopNotification;
interface nsIObserver;
[scriptable, uuid(CCEA6185-0A3D-45AB-9058-1004DD4B8C50)]
interface nsIDOMDesktopNotificationCenter : nsISupports
{
nsIDOMDesktopNotification createNotification(in DOMString title,
in DOMString description,
[optional] in DOMString iconURL);
};
[scriptable, uuid(77bc6adc-77d6-4b29-9844-7eaac25e995d)]
interface nsIDOMDesktopNotification : nsISupports
{
void show();
[implicit_jscontext] attribute jsval onclick;
[implicit_jscontext] attribute jsval onclose;
};
// Notification service that also provides the manifest URL
[scriptable, uuid(7fb4f0f9-ff5b-4620-8e1b-d82d723605af)]
interface nsIAppNotificationService : nsISupports
{
void showAppNotification(in AString imageUrl,
in AString title,
in AString text,
[optional] in boolean textClickable,
[optional] in AString manifestURL,
[optional] in nsIObserver alertListener);
};