Namespace: modal

modal

Source:

Classes

Dialog

Methods

(static) addHandler(handler)

Add handler that will be called when a global- or tab modal dialogue appears.

This is achieved by installing observers for common- and tab modal loaded events.

This function is a no-op if called on any other product than Firefox.

Parameters:
Name Type Description
handler function

The handler to be called, which is passed the subject (e.g. ChromeWindow) and the topic (one of {@code modal.COMMON_DIALOG_LOADED} or {@code modal.TABMODAL_DIALOG_LOADED}.

Source:

(static) findModalDialogs(context) → {modal.Dialog}

Check for already existing modal or tab modal dialogs

Parameters:
Name Type Description
context browser.Context

Reference to the browser context to check for existent dialogs.

Source:
Returns:

Returns instance of the Dialog class, or null if no modal dialog is present.

Type
modal.Dialog

(static) removeHandler(toRemove)

Remove modal dialogue handler by function reference.

This function is a no-op if called on any other product than Firefox.

Parameters:
Name Type Description
toRemove function

The handler previously passed to modal.addHandler which will now be removed.

Source: