Commit 15792ce9 authored by Romain Courteaud's avatar Romain Courteaud

Release version 0.19.0

parent d0422855
This diff is collapsed.
This diff is collapsed.
......@@ -728,6 +728,19 @@ if (typeof document.contains !== 'function') {
Event, URL) {
"use strict";
/////////////////////////////////////////////////////////////////
// Error
/////////////////////////////////////////////////////////////////
function ScopeError(message) {
this.name = "scopeerror";
if ((message !== undefined) && (typeof message !== "string")) {
throw new TypeError('You must pass a string.');
}
this.message = message || "Scope Error";
}
ScopeError.prototype = new Error();
ScopeError.prototype.constructor = ScopeError;
function ensurePushableQueue(callback, argument_list, context) {
var result;
try {
......@@ -1848,13 +1861,15 @@ if (typeof document.contains !== 'function') {
.declareMethod('getDeclaredGadget',
function getDeclaredGadget(gadget_scope) {
if (!this.__sub_gadget_dict.hasOwnProperty(gadget_scope)) {
throw new Error("Gadget scope '" + gadget_scope + "' is not known.");
throw new ScopeError("Gadget scope '" + gadget_scope +
"' is not known.");
}
return this.__sub_gadget_dict[gadget_scope];
})
.declareMethod('dropGadget', function dropGadget(gadget_scope) {
if (!this.__sub_gadget_dict.hasOwnProperty(gadget_scope)) {
throw new Error("Gadget scope '" + gadget_scope + "' is not known.");
throw new ScopeError("Gadget scope '" + gadget_scope +
"' is not known.");
}
// http://perfectionkills.com/understanding-delete/
delete this.__sub_gadget_dict[gadget_scope];
......@@ -2171,6 +2186,7 @@ if (typeof document.contains !== 'function') {
// global
/////////////////////////////////////////////////////////////////
renderJS.Mutex = Mutex;
renderJS.ScopeError = ScopeError;
window.rJS = window.renderJS = renderJS;
window.__RenderJSGadget = RenderJSGadget;
window.__RenderJSEmbeddedGadget = RenderJSEmbeddedGadget;
......
This diff is collapsed.
{
"name": "renderjs",
"version": "0.18.0",
"version": "0.19.0",
"description": "RenderJs provides HTML5 gadgets",
"main": "dist/renderjs-latest.js",
"dependencies": {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment