• Skip to main content
  • Select language
  • Skip to search
MDN Web Docs
  • Technologies
    • HTML
    • CSS
    • JavaScript
    • Graphics
    • HTTP
    • APIs / DOM
    • WebExtensions
    • MathML
  • References & Guides
    • Learn web development
    • Tutorials
    • References
    • Developer Guides
    • Accessibility
    • Game development
    • ...more docs
B2G OS
  1. MDN
  2. Archive of obsolete content
  3. B2G OS
  4. B2G OS APIs
  5. Navigator (Firefox OS extensions)
  6. Navigator.mozHasPendingMessage()

Navigator.mozHasPendingMessage()

In This Article
  1. Summary
  2. Syntax
    1. Parameters
  3. Return
  4. Browser compatibility
  5. See also

This API is available on Firefox OS for web content or higher privileged applications.

Summary

This method is used to know if there are pending messages of a given type (true) ot not (false).

When navigator.mozSetMessageHandler() is used to set a handler for the type, the pending messages will be asynchronously delivered to the application.

Syntax

navigator.mozHasPendingMessage(type);

Parameters

type
A string representing the kind of message the app wants to register a handler function for. For a full list of available types, see navigator.mozSetMessageHandler().

Return

A boolean.

Browser compatibility

  • Desktop
  • Mobile
Feature Chrome Firefox (Gecko) Internet Explorer Opera Safari (WebKit)
Basic support No support No support No support No support No support
Feature Android Firefox OS Firefox Mobile (Gecko) IE Mobile Opera Mobile Safari Mobile
Basic support No support 1.0 No support No support No support No support

See also

  • navigator.mozSetMessageHandler()
  • Web Activities
  • Discussion on the Mozilla WebAPI mailing list.

Document Tags and Contributors

Tags: 
  • alarm
  • API
  • B2G
  • Firefox OS
  • Method
  • Reference
  • Web Activities
  • WebAPI
 Contributors to this page: chrisdavidmills, teoli, fscholz, kscarfone, Sheppy, Jeremie, mounirlamouri
 Last updated by: chrisdavidmills, Feb 27, 2017, 2:43:08 AM
See also
  1. Archive
  2. Related pages for Firefox OS
    1. MozAlarmsManager
    2. MozMobileNetworkInfo
    3. MozWifiP2pGroupOwner