A service that allows for managing of widgets in an Opera host.
The manager allows for installing new widgets to the host, upgrading existing ones or uninstalling widget. Widgets can be opened and closed to be shown to the user of the host.
The service also reports about any widget which is installed or uninstalled from the host, even those installed by the client. It also reports back any failures in downloading or installing a widget.
Existing widgets on the host can be queried by calling ListWidgets.
CloseWidget
Closes a widget on the host, the widget will no longer be usable until it is re-opened.
All persistent settings of the widget is kept while the widget is closed.
command CloseWidget(CloseWidgetArg)
returns (Default)
{
}
= 4;
CreateInstaller
Create a new installer in the host. The installer will keep a temporary file on the host which can be filled with binary data (one chunk at a time) by calling UpdateInstaller. It is also possible to specify a widget ID, if specified the installer will upgrade an existing widget to use a new widget file instead of installing a new one.
To use the installer call InstallWidget, to cancel the installer call RemoveInstaller.
command CreateInstaller(CreateInstallerArg)
{
-
optional string widgetID = 1;
If specified makes the installer perform an upgrade instead of a new installation. An upgrade causes the widget on the host to use the new widget file once installed.
-
optional Widget.Type widgetType = 2;
Which type the installer should be created for. The default is to create it for a widget installation.
{
-
WIDGET = 1;
Regular widget.
-
UNITE = 2;
Unite application or service.
-
EXTENSION = 3;
Browser extension.
}
-
}
returns (Installer)
= 5;
GetSettings
Returns the current settings of the host.
command GetSettings(Default)
{
}
returns (Settings)
{
-
required uint32 maxChunkSize = 1;
This host requires that the size of a chunk does not exceed this value. The host may run on a limited machine such as a mobile device and might not have enough memory to decode chunks larger than this size.
All clients must adhere to this maximum value and never send a larger chunk.
-
repeated string localeList = 2;
Contains the user agent locales used to determine localized content. e.g. "en", "en-us", "*"
}
= 1;
InstallWidget
Installs a widget by using the specified installer created by CreateInstaller. Once the widget is installed the installer and temporary file will be removed from the host.
If the installation succeded it will return INSTALL_SUCCESSFUL, otherwise INSTALL_FAILED.
A OnWidgetInstalled will be sent before the call is finished if the widget was installed.
command InstallWidget(InstallWidgetArg)
returns (WidgetInstallResult)
{
-
required Result result = 1;
Result of an installation attempt.
{
-
UNKNOWN = 1;
The install failed but the reason is unknown.
-
DOWNLOAD_FAILED = 2;
Failed to download widget from URL.
-
NOT_ENOUGH_SPACE = 3;
Not enough space to install widget file.
-
INSTALL_FAILED = 4;
Installation of widget failed.
-
INSTALL_SUCCESSFUL = 5;
Widget was successfully installed.
}
-
-
optional string url = 2;
The URL that was used to (download and) install the widget. Should be the same URL as InstallWidgetByURLArg.url Only set if it was installed from a URL.
}
= 8;
InstallWidgetByURL
Install a widget by telling the host to download the widget file from the specified URL first. If the file was succesfully downloaded it will be installed in the host.
If the download and installation succeded it will return INSTALL_SUCCESSFUL, otherwise it returns one of the failure types.
A OnWidgetInstalled will be sent before the call is finished if the widget was installed. A OnWidgetInstallFailed event is sent if the the download failed or the widget could not be installed.
command InstallWidgetByURL(InstallWidgetByURLArg)
{
-
required string url = 1;
Any URL which the host can reach can be used. This includes data URLs and file URLs available on the host.
The only requirements is that the MIME-Type is set when the resource is fetched and the MIME-Type must be a widget. For data URLs remember to set the MIME-Type and encoding, e.g.::
data:application/x-opera-widgets;base64,
}
returns (WidgetInstallResult)
{
-
required Result result = 1;
Result of an installation attempt.
{
-
UNKNOWN = 1;
The install failed but the reason is unknown.
-
DOWNLOAD_FAILED = 2;
Failed to download widget from URL.
-
NOT_ENOUGH_SPACE = 3;
Not enough space to install widget file.
-
INSTALL_FAILED = 4;
Installation of widget failed.
-
INSTALL_SUCCESSFUL = 5;
Widget was successfully installed.
}
-
-
optional string url = 2;
The URL that was used to (download and) install the widget. Should be the same URL as InstallWidgetByURLArg.url Only set if it was installed from a URL.
}
= 9;
ListWidgets
Lists all widgets installed in the host.
command ListWidgets(Default)
{
}
returns (WidgetList)
{
-
repeated Widget widgetList = 1;
{
-
Contains detailed information on a widget. The structure is modeled after the W3C spec but with additional information for opera specific widgets.
The same structure is also used for Unite apps/services and browser extensions.
-
required string widgetID = 1;
A unique identifier for the widget.
e.g. "wuid-351f0e9d-24f2-080b-07e7-13b724cdaef8"
-
required Type type = 2;
The major type for the widget, most fields are common among the types but certain fields are type specific.
{
-
WIDGET = 1;
Regular widget.
-
UNITE = 2;
Unite application or service.
-
EXTENSION = 3;
Browser extension.
}
-
-
required WidgetType widgetType = 3;
-
optional Name name = 4;
Represents the full human-readable name for a widget. This field will only be set if there is a name element defined in the widget specification.
Note: This is either the localized name that matches the gadget locales, or the unlocalized name.
{
-
Represents the full human-readable name for a widget that is used, for example, in an application menu or in other contexts.
-
required string text = 1;
The full human-readable name for the widget.
-
optional string shortName = 2;
A displayable string intended to represent a condensed name for a widget, e.g. as a name for an icon.
note: This is the unlocalized version.
-
optional string locale = 3;
The locale used for the name and shortName fields. If the fields are unlocalized the field is not set.
}
-
-
required Properties properties = 5;
{
-
Various properties specific to Opera
-
required bool isActive = 1;
Specifies whether the widget is currently running or not.
-
required bool isEnabled = 2;
Specifies whether the widget is enabled or not. If the widget is disabled details on this may be found in disabledDetails.
-
required bool isDockable = 3;
Specifies whether the widget is dockable or not. This is only used by older Opera widgets (not W3C), other types sets this to false.
-
required bool hasFileAccess = 4;
Specifies whether the widget as access to the filesystem or not.
-
required bool isPersistent = 5;
Specifies whether the widget is considered persistent or not. Persistent widgets cannot be removed. Widgets are by default not persistent.
-
required bool hasTransparentFeatures = 6;
True if the widget has transparent features or not, false otherwise.
-
required bool hasJSPluginsAccess = 8;
Specifies whether the widget can use JS plugins or not. This is specific to older Opera widget (not W3C), other types sets this to false.
-
required bool hasJILFilesystemAccess = 9;
Specific flag for JIL widgets, set to true if the widget has filesystem access.
-
required bool hasFeatureTagSupport = 10;
Is true if the widget namespace supports feature tags. Currently W3C and JIL widgets support this.
-
required string path = 11;
The entire path of the widget as it is stored on the host.
-
required string fileName = 12;
The filename of the widget as it stored on the host.
-
required string configFilePath = 13;
The relative path to the config file, this is usually config.xml but may differ depending on the widget namespace in use. e.g. "config.xml"
-
required string downloadURL = 14;
The URL which was used to download and install the widget. This may be empty in some cases even though it was downloaded from a URL.
-
required uint32 windowID = 15 [default = 0];
The ID of the window the widget was opened in or 0 if there is no window.
-
required bool publicNetwork = 16;
Set to true if the widget has access to public networks. Some widget namespaces allow this to be controlled per widget while others have it set globally.
-
required bool privateNetwork = 17;
Set to true if the widget has access to private networks. Some widget namespaces allow this to be controlled per widget while others have it set globally.
-
optional string disabledDetails = 18;
Details on why a widget is disabled. Only set when disabled.
}
-
-
optional Author author = 6;
Represents people or an organization attributed with the creation of the widget. This field will only be set if there is an author element defined in the widget specification.
{
-
Represents people or an organization attributed with the creation of the widget.
-
required string text = 1;
People or organization attributed with the creation of the widget.
-
optional string email = 2;
Email address associated with the author.
-
optional string href = 3;
URI that represents a link associated with the author.
-
optional string organization = 4;
Represents the name of an organization that the author is affiliated with.
}
-
-
optional string namespace = 7;
The namespaces this widget uses. If no namespace is defined the field is not set. e.g. "http://www.w3.org/ns/widgets" or "http://xmlns.opera.com/2006/widget"
-
optional string version = 8;
The version of the widget.
-
optional int32 width = 9;
If specified defines the preferred viewport width in pixels. The value, when set, is from 1 and up.
-
optional int32 height = 10;
If specified defines the preferred viewport height in pixels. The value, when set, is from 1 and up.
-
optional int32 currentWidth = 11;
The current width of the widget in pixels.
-
optional int32 currentHeight = 12;
The current height of the widget in pixels.
-
required ViewMode currentViewMode = 13;
The current viewmode used by the widget.
{
-
UNKNOWN = 1;
-
WIDGET = 2;
No chrome
-
FLOATING = 3;
Floating, same as widget (W3C mode)
-
DOCKED = 4;
-
APPLICATION = 5;
-
FULLSCREEN = 6;
-
MAXIMIZED = 7;
With chrome and occupying the entire screen.
-
MINIMIZED = 8;
Same as docked
-
WINDOWED = 9;
Same as widget
}
-
-
required ViewMode defaultViewMode = 14;
The default viewmode for the widget.
{
-
UNKNOWN = 1;
-
WIDGET = 2;
No chrome
-
FLOATING = 3;
Floating, same as widget (W3C mode)
-
DOCKED = 4;
-
APPLICATION = 5;
-
FULLSCREEN = 6;
-
MAXIMIZED = 7;
With chrome and occupying the entire screen.
-
MINIMIZED = 8;
Same as docked
-
WINDOWED = 9;
Same as widget
}
-
-
repeated ViewMode viewModeList = 15;
All viewmodes defined for this widget.
{
-
UNKNOWN = 1;
-
WIDGET = 2;
No chrome
-
FLOATING = 3;
Floating, same as widget (W3C mode)
-
DOCKED = 4;
-
APPLICATION = 5;
-
FULLSCREEN = 6;
-
MAXIMIZED = 7;
With chrome and occupying the entire screen.
-
MINIMIZED = 8;
Same as docked
-
WINDOWED = 9;
Same as widget
}
-
-
optional Description description = 16;
Represents a human-readable description of the widget. This field will only be set if there is a description element defined in the widget specification.
Note: This is either the localized description that matches the gadget locales, or the unlocalized description.
{
-
Represents a human-readable description of the widget.
-
required string text = 1;
The description text.
-
optional string locale = 2;
The locale used for the description field. If the field is unlocalized the field is not set.
}
-
-
optional License license = 17;
The license information for the widget if one is present. This field will only be set if there is a license element defined in the widget specification.
{
-
The software license for this widget.
-
required string text = 1;
The license text.
-
optional string href = 2;
A URL or path that points to a representation of a software and/or content license
-
optional string locale = 3;
The locale used for this license. If the field is unlocalized the field is not set.
}
-
-
repeated Icon iconList = 18;
All icons defined for the widget.
{
-
A custom icon for the widget.
7.11 http://www.w3.org/TR/widgets/#the-icon-element-and-its-attributes
-
required string src = 1;
A path attribute that points to a file inside the widget package.
-
optional uint32 width = 2;
The author's preferred width for the icon if any. Only set for values 1 and up.
-
optional uint32 height = 3;
The author's preferred height for the icon if any. Only set for values 1 and up.
}
-
-
optional Content content = 19;
Declare a custom start file the user agent is expected to use when it instantiates the widget. This field will only be set if there is a content element defined in the widget specification.
{
-
Defines the start file for a widget, the file is defined by a path and optionally which MIME-Type and encoding it has. If no content has been defined the widget is started from "index.html".
-
required string src = 1;
A path which points to a file within the widget package. e.g. "mywidget.html"
-
optional string type = 2;
Defines the MIME-Type for the file referenced in 'src'. The default MIME-Type is "text/html".
-
optional string encoding = 3;
Defines the encoding for the file referenced in 'src'. The default encoding is "UTF-8".
}
-
-
repeated Feature featureList = 20;
List of all features requested by the widget.
{
-
A feature is a URI identifiable runtime component. (e.g. an API).
-
required string name = 1;
An IRI attribute that identifies a feature that is needed by the widget at runtime (such as an API).
-
required bool isRequired = 2;
A boolean attribute that indicates whether or not this feature has to be available to the widget at runtime.
-
repeated Param paramList = 3;
List of parameters for the feature.
{
-
A parameter for a feature, defined as a name/value pair. The meaning of the name and value depends entirely on the feature.
-
required string name = 1;
-
required string value = 2;
}
-
}
-
-
repeated Preference preferenceList = 21;
List of all preferences defined by the widget.
{
-
The preference element allows authors to declare one or more preferences. Preferences are persistently stored in the browser.
-
required string name = 1;
The name of the preference e.g. "skin"
-
required string value = 2;
The value of the preference e.g. "alien"
-
required bool isReadOnly = 3 [default = false];
Controls whether this preference can, or cannot, be overwritten at runtime (e.g. via scripts).
}
-
-
optional Signature signature = 22;
If the widget was signed with a digital signature this is set with information on the signature.
{
-
required string id = 1;
Short name of the signature used.
-
required State state = 2;
The state of the signature, for instance whether verification failed or it was properly signed.
{
-
UNKNOWN = 1;
-
UNSIGNED = 2;
Widget is unsigned.
-
SIGNED = 3;
Widget is signed and signature is valid.
-
VERIFICATION_FAILED = 4;
Widget is signed but the signature is invalid.
-
PENDING = 5;
Signature verification is still in progress.
}
-
-
optional bool isPrivilegedCert = 3;
Set to true if the widget has been signed with a privileged certificate.
}
-
-
optional string updateURL = 23;
The URL used for updating the widget.
-
repeated Network networkAccessList = 24;
List of requests to access network resources.
{
-
Defines a request for permission to access a set of network resources. http://www.w3.org/TR/widgets-access/#the-access-element
-
required string origin = 1;
Defines the URL that the widget should get access to, e.g. "https://example.net" A special value of U+002A ASTERISK (*) means unrestricted access to any network resources.
-
required bool allowSubdomains = 2;
Indicates whether or not the host component part of origin applies to subdomains as well. The default is not to allow subdomains.
}
-
-
repeated SecurityAccess securityAccessList = 25;
Lists of security access the widget requests. Note: This only applies to Opera Widgets (namespace "http://xmlns.opera.com/2006/widget" and ""), not W3C and other widget formats.
{
-
Declares which protocols, hosts, ports, and paths the widget may use.
http://dev.opera.com/articles/view/opera-widgets-specification-1-0/#xmlsecurity
-
repeated string protocolList = 1;
The protocols the widget will be using to contact external servers. All protocols, except the file protocol is permitted. e.g. "http", "https" If the list is empty it means any protocol (excluding exceptions).
-
repeated string hostList = 2;
The hostnames/ip-addresses which the widget may use, e.g. "www.example.com" or "192.168.1.1" The hostnames is an exact match, so a widget specifying www.example.com will not be able to contact example.com. If the list is empty it means any host.
-
repeated Port portList = 3;
Ports which may be used by the widget. Each entry is a range of ports, e.g. 1024-2048 If the list is empty it means port.
{
-
Represents a range of ports the widget may use, e.g. 1024-2048 If only a single port is defined then both low and high will contain the same value.
-
required uint32 low = 1;
-
required uint32 high = 2;
}
-
-
repeated string pathList = 4;
The path elements the widget may contact, e.g. "/foo" If the list is empty it means any path.
}
-
-
optional string iriIdentifier = 26;
An IRI identifier chosen by widget itself.
-
optional ExtensionInfo extensionInfo = 27;
Additional information which is specific to extensions. Only set when it contains an extension.
{
-
required string includesPath = 1;
Specifies the includes folder for the extension.
-
required bool isRunning = 2;
True if the extension is currently running.
}
-
-
optional UniteInfo uniteInfo = 28;
Additional information which is specific to Unite apps and services. Only set when it contains a Unite app or service.
{
-
required Type type = 1;
{
-
Unite type
-
UNKNOWN = 1;
The Unite type is not known by the service.
-
SERVICE = 2;
-
APPLICATION = 3;
}
-
-
optional string servicePath = 2;
The service path, e.g. "fridge".
}
-
}
-
}
= 2;
OpenWidget
Opens a widget on the host, the widget will then be visible for the user of the host.
command OpenWidget(OpenWidgetArg)
{
-
required string widgetID = 1;
-
optional bool allowMutablePolicy = 2 [default = false];
Set this to true to give the widget programmatic access to the global security policy (the widget.setGlobalPolicy function).
This should only be set for widgets deployed for testing purposes.
-
optional string globalPolicy = 3;
Override the regular global policy. This field may contain a full XML global policy file, starting with the <widgets> tag. The 'allowMutablePolicy' must be set to true when using this field.
If a security policy was specified, but could not be parsed, this command fails and the widget will not be opened.
}
returns (Default)
{
}
= 3;
RemoveInstaller
Cancels an installation by removing the installer and the temporary file from the host.
command RemoveInstaller(RemoveInstallerArg)
returns (Default)
{
}
= 7;
UninstallWidget
Removes a widget from the host, the widget is closed and the widget file is removed.
A OnWidgetUninstalled will be sent if the widget could be uninstalled.
command UninstallWidget(UninstallWidgetArg)
returns (Default)
{
}
= 10;
UpdateInstaller
Adds additional data to an existing installer. The binary data will be appended to the temporary file.
Make sure the client does not send more data in one chunk than the host can deal with. The max chunk size can be attained by calling GetSettings.
command UpdateInstaller(UpdateInstallerArg)
{
-
required uint32 installerID = 1;
-
required bytes byteData = 2;
Byte data which will be appended to the temporary file.
Must not exceed the max size set by the host, see GetSettings.
}
returns (Default)
{
}
= 6;
OnWidgetInstallFailed
A widget failed to install in the host.
event OnWidgetInstallFailed returns (WidgetInstallResult)
{
-
required Result result = 1;
Result of an installation attempt.
{
-
UNKNOWN = 1;
The install failed but the reason is unknown.
-
DOWNLOAD_FAILED = 2;
Failed to download widget from URL.
-
NOT_ENOUGH_SPACE = 3;
Not enough space to install widget file.
-
INSTALL_FAILED = 4;
Installation of widget failed.
-
INSTALL_SUCCESSFUL = 5;
Widget was successfully installed.
}
-
-
optional string url = 2;
The URL that was used to (download and) install the widget. Should be the same URL as InstallWidgetByURLArg.url Only set if it was installed from a URL.
}
= 13;
OnWidgetInstalled
A new widget has been installed.
event OnWidgetInstalled returns (Widget)
{
-
Contains detailed information on a widget. The structure is modeled after the W3C spec but with additional information for opera specific widgets.
The same structure is also used for Unite apps/services and browser extensions.
-
required string widgetID = 1;
A unique identifier for the widget.
e.g. "wuid-351f0e9d-24f2-080b-07e7-13b724cdaef8"
-
required Type type = 2;
The major type for the widget, most fields are common among the types but certain fields are type specific.
{
-
WIDGET = 1;
Regular widget.
-
UNITE = 2;
Unite application or service.
-
EXTENSION = 3;
Browser extension.
}
-
-
required WidgetType widgetType = 3;
-
optional Name name = 4;
Represents the full human-readable name for a widget. This field will only be set if there is a name element defined in the widget specification.
Note: This is either the localized name that matches the gadget locales, or the unlocalized name.
{
-
Represents the full human-readable name for a widget that is used, for example, in an application menu or in other contexts.
-
required string text = 1;
The full human-readable name for the widget.
-
optional string shortName = 2;
A displayable string intended to represent a condensed name for a widget, e.g. as a name for an icon.
note: This is the unlocalized version.
-
optional string locale = 3;
The locale used for the name and shortName fields. If the fields are unlocalized the field is not set.
}
-
-
required Properties properties = 5;
{
-
Various properties specific to Opera
-
required bool isActive = 1;
Specifies whether the widget is currently running or not.
-
required bool isEnabled = 2;
Specifies whether the widget is enabled or not. If the widget is disabled details on this may be found in disabledDetails.
-
required bool isDockable = 3;
Specifies whether the widget is dockable or not. This is only used by older Opera widgets (not W3C), other types sets this to false.
-
required bool hasFileAccess = 4;
Specifies whether the widget as access to the filesystem or not.
-
required bool isPersistent = 5;
Specifies whether the widget is considered persistent or not. Persistent widgets cannot be removed. Widgets are by default not persistent.
-
required bool hasTransparentFeatures = 6;
True if the widget has transparent features or not, false otherwise.
-
required bool hasJSPluginsAccess = 8;
Specifies whether the widget can use JS plugins or not. This is specific to older Opera widget (not W3C), other types sets this to false.
-
required bool hasJILFilesystemAccess = 9;
Specific flag for JIL widgets, set to true if the widget has filesystem access.
-
required bool hasFeatureTagSupport = 10;
Is true if the widget namespace supports feature tags. Currently W3C and JIL widgets support this.
-
required string path = 11;
The entire path of the widget as it is stored on the host.
-
required string fileName = 12;
The filename of the widget as it stored on the host.
-
required string configFilePath = 13;
The relative path to the config file, this is usually config.xml but may differ depending on the widget namespace in use. e.g. "config.xml"
-
required string downloadURL = 14;
The URL which was used to download and install the widget. This may be empty in some cases even though it was downloaded from a URL.
-
required uint32 windowID = 15 [default = 0];
The ID of the window the widget was opened in or 0 if there is no window.
-
required bool publicNetwork = 16;
Set to true if the widget has access to public networks. Some widget namespaces allow this to be controlled per widget while others have it set globally.
-
required bool privateNetwork = 17;
Set to true if the widget has access to private networks. Some widget namespaces allow this to be controlled per widget while others have it set globally.
-
optional string disabledDetails = 18;
Details on why a widget is disabled. Only set when disabled.
}
-
-
optional Author author = 6;
Represents people or an organization attributed with the creation of the widget. This field will only be set if there is an author element defined in the widget specification.
{
-
Represents people or an organization attributed with the creation of the widget.
-
required string text = 1;
People or organization attributed with the creation of the widget.
-
optional string email = 2;
Email address associated with the author.
-
optional string href = 3;
URI that represents a link associated with the author.
-
optional string organization = 4;
Represents the name of an organization that the author is affiliated with.
}
-
-
optional string namespace = 7;
The namespaces this widget uses. If no namespace is defined the field is not set. e.g. "http://www.w3.org/ns/widgets" or "http://xmlns.opera.com/2006/widget"
-
optional string version = 8;
The version of the widget.
-
optional int32 width = 9;
If specified defines the preferred viewport width in pixels. The value, when set, is from 1 and up.
-
optional int32 height = 10;
If specified defines the preferred viewport height in pixels. The value, when set, is from 1 and up.
-
optional int32 currentWidth = 11;
The current width of the widget in pixels.
-
optional int32 currentHeight = 12;
The current height of the widget in pixels.
-
required ViewMode currentViewMode = 13;
The current viewmode used by the widget.
{
-
UNKNOWN = 1;
-
WIDGET = 2;
No chrome
-
FLOATING = 3;
Floating, same as widget (W3C mode)
-
DOCKED = 4;
-
APPLICATION = 5;
-
FULLSCREEN = 6;
-
MAXIMIZED = 7;
With chrome and occupying the entire screen.
-
MINIMIZED = 8;
Same as docked
-
WINDOWED = 9;
Same as widget
}
-
-
required ViewMode defaultViewMode = 14;
The default viewmode for the widget.
{
-
UNKNOWN = 1;
-
WIDGET = 2;
No chrome
-
FLOATING = 3;
Floating, same as widget (W3C mode)
-
DOCKED = 4;
-
APPLICATION = 5;
-
FULLSCREEN = 6;
-
MAXIMIZED = 7;
With chrome and occupying the entire screen.
-
MINIMIZED = 8;
Same as docked
-
WINDOWED = 9;
Same as widget
}
-
-
repeated ViewMode viewModeList = 15;
All viewmodes defined for this widget.
{
-
UNKNOWN = 1;
-
WIDGET = 2;
No chrome
-
FLOATING = 3;
Floating, same as widget (W3C mode)
-
DOCKED = 4;
-
APPLICATION = 5;
-
FULLSCREEN = 6;
-
MAXIMIZED = 7;
With chrome and occupying the entire screen.
-
MINIMIZED = 8;
Same as docked
-
WINDOWED = 9;
Same as widget
}
-
-
optional Description description = 16;
Represents a human-readable description of the widget. This field will only be set if there is a description element defined in the widget specification.
Note: This is either the localized description that matches the gadget locales, or the unlocalized description.
{
-
Represents a human-readable description of the widget.
-
required string text = 1;
The description text.
-
optional string locale = 2;
The locale used for the description field. If the field is unlocalized the field is not set.
}
-
-
optional License license = 17;
The license information for the widget if one is present. This field will only be set if there is a license element defined in the widget specification.
{
-
The software license for this widget.
-
required string text = 1;
The license text.
-
optional string href = 2;
A URL or path that points to a representation of a software and/or content license
-
optional string locale = 3;
The locale used for this license. If the field is unlocalized the field is not set.
}
-
-
repeated Icon iconList = 18;
All icons defined for the widget.
{
-
A custom icon for the widget.
7.11 http://www.w3.org/TR/widgets/#the-icon-element-and-its-attributes
-
required string src = 1;
A path attribute that points to a file inside the widget package.
-
optional uint32 width = 2;
The author's preferred width for the icon if any. Only set for values 1 and up.
-
optional uint32 height = 3;
The author's preferred height for the icon if any. Only set for values 1 and up.
}
-
-
optional Content content = 19;
Declare a custom start file the user agent is expected to use when it instantiates the widget. This field will only be set if there is a content element defined in the widget specification.
{
-
Defines the start file for a widget, the file is defined by a path and optionally which MIME-Type and encoding it has. If no content has been defined the widget is started from "index.html".
-
required string src = 1;
A path which points to a file within the widget package. e.g. "mywidget.html"
-
optional string type = 2;
Defines the MIME-Type for the file referenced in 'src'. The default MIME-Type is "text/html".
-
optional string encoding = 3;
Defines the encoding for the file referenced in 'src'. The default encoding is "UTF-8".
}
-
-
repeated Feature featureList = 20;
List of all features requested by the widget.
{
-
A feature is a URI identifiable runtime component. (e.g. an API).
-
required string name = 1;
An IRI attribute that identifies a feature that is needed by the widget at runtime (such as an API).
-
required bool isRequired = 2;
A boolean attribute that indicates whether or not this feature has to be available to the widget at runtime.
-
repeated Param paramList = 3;
List of parameters for the feature.
{
-
A parameter for a feature, defined as a name/value pair. The meaning of the name and value depends entirely on the feature.
-
required string name = 1;
-
required string value = 2;
}
-
}
-
-
repeated Preference preferenceList = 21;
List of all preferences defined by the widget.
{
-
The preference element allows authors to declare one or more preferences. Preferences are persistently stored in the browser.
-
required string name = 1;
The name of the preference e.g. "skin"
-
required string value = 2;
The value of the preference e.g. "alien"
-
required bool isReadOnly = 3 [default = false];
Controls whether this preference can, or cannot, be overwritten at runtime (e.g. via scripts).
}
-
-
optional Signature signature = 22;
If the widget was signed with a digital signature this is set with information on the signature.
{
-
required string id = 1;
Short name of the signature used.
-
required State state = 2;
The state of the signature, for instance whether verification failed or it was properly signed.
{
-
UNKNOWN = 1;
-
UNSIGNED = 2;
Widget is unsigned.
-
SIGNED = 3;
Widget is signed and signature is valid.
-
VERIFICATION_FAILED = 4;
Widget is signed but the signature is invalid.
-
PENDING = 5;
Signature verification is still in progress.
}
-
-
optional bool isPrivilegedCert = 3;
Set to true if the widget has been signed with a privileged certificate.
}
-
-
optional string updateURL = 23;
The URL used for updating the widget.
-
repeated Network networkAccessList = 24;
List of requests to access network resources.
{
-
Defines a request for permission to access a set of network resources. http://www.w3.org/TR/widgets-access/#the-access-element
-
required string origin = 1;
Defines the URL that the widget should get access to, e.g. "https://example.net" A special value of U+002A ASTERISK (*) means unrestricted access to any network resources.
-
required bool allowSubdomains = 2;
Indicates whether or not the host component part of origin applies to subdomains as well. The default is not to allow subdomains.
}
-
-
repeated SecurityAccess securityAccessList = 25;
Lists of security access the widget requests. Note: This only applies to Opera Widgets (namespace "http://xmlns.opera.com/2006/widget" and ""), not W3C and other widget formats.
{
-
Declares which protocols, hosts, ports, and paths the widget may use.
http://dev.opera.com/articles/view/opera-widgets-specification-1-0/#xmlsecurity
-
repeated string protocolList = 1;
The protocols the widget will be using to contact external servers. All protocols, except the file protocol is permitted. e.g. "http", "https" If the list is empty it means any protocol (excluding exceptions).
-
repeated string hostList = 2;
The hostnames/ip-addresses which the widget may use, e.g. "www.example.com" or "192.168.1.1" The hostnames is an exact match, so a widget specifying www.example.com will not be able to contact example.com. If the list is empty it means any host.
-
repeated Port portList = 3;
Ports which may be used by the widget. Each entry is a range of ports, e.g. 1024-2048 If the list is empty it means port.
{
-
Represents a range of ports the widget may use, e.g. 1024-2048 If only a single port is defined then both low and high will contain the same value.
-
required uint32 low = 1;
-
required uint32 high = 2;
}
-
-
repeated string pathList = 4;
The path elements the widget may contact, e.g. "/foo" If the list is empty it means any path.
}
-
-
optional string iriIdentifier = 26;
An IRI identifier chosen by widget itself.
-
optional ExtensionInfo extensionInfo = 27;
Additional information which is specific to extensions. Only set when it contains an extension.
{
-
required string includesPath = 1;
Specifies the includes folder for the extension.
-
required bool isRunning = 2;
True if the extension is currently running.
}
-
-
optional UniteInfo uniteInfo = 28;
Additional information which is specific to Unite apps and services. Only set when it contains a Unite app or service.
{
-
required Type type = 1;
{
-
Unite type
-
UNKNOWN = 1;
The Unite type is not known by the service.
-
SERVICE = 2;
-
APPLICATION = 3;
}
-
-
optional string servicePath = 2;
The service path, e.g. "fridge".
}
-
}
= 11;
OnWidgetUninstalled
A widget was uninstalled from the host.
event OnWidgetUninstalled returns (WidgetUninstalled)
= 14;
OnWidgetUpgraded
An existing widget has been upgraded to use a new widget file.
event OnWidgetUpgraded returns (Widget)
{
-
Contains detailed information on a widget. The structure is modeled after the W3C spec but with additional information for opera specific widgets.
The same structure is also used for Unite apps/services and browser extensions.
-
required string widgetID = 1;
A unique identifier for the widget.
e.g. "wuid-351f0e9d-24f2-080b-07e7-13b724cdaef8"
-
required Type type = 2;
The major type for the widget, most fields are common among the types but certain fields are type specific.
{
-
WIDGET = 1;
Regular widget.
-
UNITE = 2;
Unite application or service.
-
EXTENSION = 3;
Browser extension.
}
-
-
required WidgetType widgetType = 3;
-
optional Name name = 4;
Represents the full human-readable name for a widget. This field will only be set if there is a name element defined in the widget specification.
Note: This is either the localized name that matches the gadget locales, or the unlocalized name.
{
-
Represents the full human-readable name for a widget that is used, for example, in an application menu or in other contexts.
-
required string text = 1;
The full human-readable name for the widget.
-
optional string shortName = 2;
A displayable string intended to represent a condensed name for a widget, e.g. as a name for an icon.
note: This is the unlocalized version.
-
optional string locale = 3;
The locale used for the name and shortName fields. If the fields are unlocalized the field is not set.
}
-
-
required Properties properties = 5;
{
-
Various properties specific to Opera
-
required bool isActive = 1;
Specifies whether the widget is currently running or not.
-
required bool isEnabled = 2;
Specifies whether the widget is enabled or not. If the widget is disabled details on this may be found in disabledDetails.
-
required bool isDockable = 3;
Specifies whether the widget is dockable or not. This is only used by older Opera widgets (not W3C), other types sets this to false.
-
required bool hasFileAccess = 4;
Specifies whether the widget as access to the filesystem or not.
-
required bool isPersistent = 5;
Specifies whether the widget is considered persistent or not. Persistent widgets cannot be removed. Widgets are by default not persistent.
-
required bool hasTransparentFeatures = 6;
True if the widget has transparent features or not, false otherwise.
-
required bool hasJSPluginsAccess = 8;
Specifies whether the widget can use JS plugins or not. This is specific to older Opera widget (not W3C), other types sets this to false.
-
required bool hasJILFilesystemAccess = 9;
Specific flag for JIL widgets, set to true if the widget has filesystem access.
-
required bool hasFeatureTagSupport = 10;
Is true if the widget namespace supports feature tags. Currently W3C and JIL widgets support this.
-
required string path = 11;
The entire path of the widget as it is stored on the host.
-
required string fileName = 12;
The filename of the widget as it stored on the host.
-
required string configFilePath = 13;
The relative path to the config file, this is usually config.xml but may differ depending on the widget namespace in use. e.g. "config.xml"
-
required string downloadURL = 14;
The URL which was used to download and install the widget. This may be empty in some cases even though it was downloaded from a URL.
-
required uint32 windowID = 15 [default = 0];
The ID of the window the widget was opened in or 0 if there is no window.
-
required bool publicNetwork = 16;
Set to true if the widget has access to public networks. Some widget namespaces allow this to be controlled per widget while others have it set globally.
-
required bool privateNetwork = 17;
Set to true if the widget has access to private networks. Some widget namespaces allow this to be controlled per widget while others have it set globally.
-
optional string disabledDetails = 18;
Details on why a widget is disabled. Only set when disabled.
}
-
-
optional Author author = 6;
Represents people or an organization attributed with the creation of the widget. This field will only be set if there is an author element defined in the widget specification.
{
-
Represents people or an organization attributed with the creation of the widget.
-
required string text = 1;
People or organization attributed with the creation of the widget.
-
optional string email = 2;
Email address associated with the author.
-
optional string href = 3;
URI that represents a link associated with the author.
-
optional string organization = 4;
Represents the name of an organization that the author is affiliated with.
}
-
-
optional string namespace = 7;
The namespaces this widget uses. If no namespace is defined the field is not set. e.g. "http://www.w3.org/ns/widgets" or "http://xmlns.opera.com/2006/widget"
-
optional string version = 8;
The version of the widget.
-
optional int32 width = 9;
If specified defines the preferred viewport width in pixels. The value, when set, is from 1 and up.
-
optional int32 height = 10;
If specified defines the preferred viewport height in pixels. The value, when set, is from 1 and up.
-
optional int32 currentWidth = 11;
The current width of the widget in pixels.
-
optional int32 currentHeight = 12;
The current height of the widget in pixels.
-
required ViewMode currentViewMode = 13;
The current viewmode used by the widget.
{
-
UNKNOWN = 1;
-
WIDGET = 2;
No chrome
-
FLOATING = 3;
Floating, same as widget (W3C mode)
-
DOCKED = 4;
-
APPLICATION = 5;
-
FULLSCREEN = 6;
-
MAXIMIZED = 7;
With chrome and occupying the entire screen.
-
MINIMIZED = 8;
Same as docked
-
WINDOWED = 9;
Same as widget
}
-
-
required ViewMode defaultViewMode = 14;
The default viewmode for the widget.
{
-
UNKNOWN = 1;
-
WIDGET = 2;
No chrome
-
FLOATING = 3;
Floating, same as widget (W3C mode)
-
DOCKED = 4;
-
APPLICATION = 5;
-
FULLSCREEN = 6;
-
MAXIMIZED = 7;
With chrome and occupying the entire screen.
-
MINIMIZED = 8;
Same as docked
-
WINDOWED = 9;
Same as widget
}
-
-
repeated ViewMode viewModeList = 15;
All viewmodes defined for this widget.
{
-
UNKNOWN = 1;
-
WIDGET = 2;
No chrome
-
FLOATING = 3;
Floating, same as widget (W3C mode)
-
DOCKED = 4;
-
APPLICATION = 5;
-
FULLSCREEN = 6;
-
MAXIMIZED = 7;
With chrome and occupying the entire screen.
-
MINIMIZED = 8;
Same as docked
-
WINDOWED = 9;
Same as widget
}
-
-
optional Description description = 16;
Represents a human-readable description of the widget. This field will only be set if there is a description element defined in the widget specification.
Note: This is either the localized description that matches the gadget locales, or the unlocalized description.
{
-
Represents a human-readable description of the widget.
-
required string text = 1;
The description text.
-
optional string locale = 2;
The locale used for the description field. If the field is unlocalized the field is not set.
}
-
-
optional License license = 17;
The license information for the widget if one is present. This field will only be set if there is a license element defined in the widget specification.
{
-
The software license for this widget.
-
required string text = 1;
The license text.
-
optional string href = 2;
A URL or path that points to a representation of a software and/or content license
-
optional string locale = 3;
The locale used for this license. If the field is unlocalized the field is not set.
}
-
-
repeated Icon iconList = 18;
All icons defined for the widget.
{
-
A custom icon for the widget.
7.11 http://www.w3.org/TR/widgets/#the-icon-element-and-its-attributes
-
required string src = 1;
A path attribute that points to a file inside the widget package.
-
optional uint32 width = 2;
The author's preferred width for the icon if any. Only set for values 1 and up.
-
optional uint32 height = 3;
The author's preferred height for the icon if any. Only set for values 1 and up.
}
-
-
optional Content content = 19;
Declare a custom start file the user agent is expected to use when it instantiates the widget. This field will only be set if there is a content element defined in the widget specification.
{
-
Defines the start file for a widget, the file is defined by a path and optionally which MIME-Type and encoding it has. If no content has been defined the widget is started from "index.html".
-
required string src = 1;
A path which points to a file within the widget package. e.g. "mywidget.html"
-
optional string type = 2;
Defines the MIME-Type for the file referenced in 'src'. The default MIME-Type is "text/html".
-
optional string encoding = 3;
Defines the encoding for the file referenced in 'src'. The default encoding is "UTF-8".
}
-
-
repeated Feature featureList = 20;
List of all features requested by the widget.
{
-
A feature is a URI identifiable runtime component. (e.g. an API).
-
required string name = 1;
An IRI attribute that identifies a feature that is needed by the widget at runtime (such as an API).
-
required bool isRequired = 2;
A boolean attribute that indicates whether or not this feature has to be available to the widget at runtime.
-
repeated Param paramList = 3;
List of parameters for the feature.
{
-
A parameter for a feature, defined as a name/value pair. The meaning of the name and value depends entirely on the feature.
-
required string name = 1;
-
required string value = 2;
}
-
}
-
-
repeated Preference preferenceList = 21;
List of all preferences defined by the widget.
{
-
The preference element allows authors to declare one or more preferences. Preferences are persistently stored in the browser.
-
required string name = 1;
The name of the preference e.g. "skin"
-
required string value = 2;
The value of the preference e.g. "alien"
-
required bool isReadOnly = 3 [default = false];
Controls whether this preference can, or cannot, be overwritten at runtime (e.g. via scripts).
}
-
-
optional Signature signature = 22;
If the widget was signed with a digital signature this is set with information on the signature.
{
-
required string id = 1;
Short name of the signature used.
-
required State state = 2;
The state of the signature, for instance whether verification failed or it was properly signed.
{
-
UNKNOWN = 1;
-
UNSIGNED = 2;
Widget is unsigned.
-
SIGNED = 3;
Widget is signed and signature is valid.
-
VERIFICATION_FAILED = 4;
Widget is signed but the signature is invalid.
-
PENDING = 5;
Signature verification is still in progress.
}
-
-
optional bool isPrivilegedCert = 3;
Set to true if the widget has been signed with a privileged certificate.
}
-
-
optional string updateURL = 23;
The URL used for updating the widget.
-
repeated Network networkAccessList = 24;
List of requests to access network resources.
{
-
Defines a request for permission to access a set of network resources. http://www.w3.org/TR/widgets-access/#the-access-element
-
required string origin = 1;
Defines the URL that the widget should get access to, e.g. "https://example.net" A special value of U+002A ASTERISK (*) means unrestricted access to any network resources.
-
required bool allowSubdomains = 2;
Indicates whether or not the host component part of origin applies to subdomains as well. The default is not to allow subdomains.
}
-
-
repeated SecurityAccess securityAccessList = 25;
Lists of security access the widget requests. Note: This only applies to Opera Widgets (namespace "http://xmlns.opera.com/2006/widget" and ""), not W3C and other widget formats.
{
-
Declares which protocols, hosts, ports, and paths the widget may use.
http://dev.opera.com/articles/view/opera-widgets-specification-1-0/#xmlsecurity
-
repeated string protocolList = 1;
The protocols the widget will be using to contact external servers. All protocols, except the file protocol is permitted. e.g. "http", "https" If the list is empty it means any protocol (excluding exceptions).
-
repeated string hostList = 2;
The hostnames/ip-addresses which the widget may use, e.g. "www.example.com" or "192.168.1.1" The hostnames is an exact match, so a widget specifying www.example.com will not be able to contact example.com. If the list is empty it means any host.
-
repeated Port portList = 3;
Ports which may be used by the widget. Each entry is a range of ports, e.g. 1024-2048 If the list is empty it means port.
{
-
Represents a range of ports the widget may use, e.g. 1024-2048 If only a single port is defined then both low and high will contain the same value.
-
required uint32 low = 1;
-
required uint32 high = 2;
}
-
-
repeated string pathList = 4;
The path elements the widget may contact, e.g. "/foo" If the list is empty it means any path.
}
-
-
optional string iriIdentifier = 26;
An IRI identifier chosen by widget itself.
-
optional ExtensionInfo extensionInfo = 27;
Additional information which is specific to extensions. Only set when it contains an extension.
{
-
required string includesPath = 1;
Specifies the includes folder for the extension.
-
required bool isRunning = 2;
True if the extension is currently running.
}
-
-
optional UniteInfo uniteInfo = 28;
Additional information which is specific to Unite apps and services. Only set when it contains a Unite app or service.
{
-
required Type type = 1;
{
-
Unite type
-
UNKNOWN = 1;
The Unite type is not known by the service.
-
SERVICE = 2;
-
APPLICATION = 3;
}
-
-
optional string servicePath = 2;
The service path, e.g. "fridge".
}
-
}
= 12;