Editor:
Robin Berjon (Joost™) <robin@joost.com>
Revision:
0.9, last modified: 2008-01-16T14:34:23+01:00

Abstract

This document specifies the methods that are globally available (i.e. on window) in the context of widgets and overlays.

Any and all use of the Joost API is subject to the Joost API Terms of Use

The API may change and although we will try and keep these changes to a minimum, some API calls may be deprecated in the future.

Table of Contents

1. Overview

This document does not intend to list all of the globally available methods as most are precisely those typically found on window inside Gecko. It only lists the miscellaneous methods that have been added.

2. Global

The Global API is exposed as the window object which is the global context, and means that explicitly using window is not necessary.

The Global interface

interface Global {
  void navigate(in String url);
  void logMessage(in String message);
};

Methods

logMessage

This will cause the given string to be dumped to the error console, which is useful for debugging given the unavailability of alert().

Parameters
message of type String
The message to dump to the console.
No Return Value
No Exceptions
navigate

This method has two different behaviours depending on which URL type it is passed. If it is a Joost Link then the corresponding programme or channel will be played; if it is another type of URL then it will passed to the platform to be handled by the default application for that URL scheme (e.g. typically the Web browser for http URLs).

Parameters
url of type String
The URL that one wishes to navigate to.
No Return Value
No Exceptions

3. References