diff --git a/app/AjaxError.js b/app/AjaxError.js deleted file mode 100644 index 1a3c7d6..0000000 --- a/app/AjaxError.js +++ /dev/null @@ -1,48 +0,0 @@ -/** - * @licence GNU GPL v3 - * @author snater.com < wikimedia@snater.com > - */ -define( ['jquery', 'app/ApplicationError', 'dojo/i18n!./nls/AjaxError'], - function( $, ApplicationError, messages ) { -'use strict'; - -/** - * API Error - * @constructor - * - * @param {string} code - * @param {Object} ajaxOptions - * - * @throws {Error} if a required parameter is not defined. - */ -var AjaxError = function( code, ajaxOptions ) { - ApplicationError.call( this, code ); - - if( !ajaxOptions ) { - throw new Error( ajaxOptions ); - } - - this._ajaxOptions = ajaxOptions; -}; - -$.extend( AjaxError.prototype, ApplicationError.prototype, { - constructor: AjaxError, - - /** - * @type {Object} - */ - _ajaxOptions: null, - - /** - * @see ApplicationError.getMessage - */ - getMessage: function() { - // (Re-implemented to access correct messages.) - return messages[this._code] || messages['*']; - } - -} ); - -return AjaxError; - -} ); diff --git a/app/Api.js b/app/Api.js deleted file mode 100644 index a1944f6..0000000 --- a/app/Api.js +++ /dev/null @@ -1,441 +0,0 @@ -/** - * @licence GNU GPL v3 - * @author snater.com < wikimedia@snater.com > - */ -define( ['jquery', 'app/ImageInfo', 'app/WikiAssetPage', 'dojo/_base/config', 'app/AjaxError'], - function( $, ImageInfo, WikiAssetPage, config, AjaxError ) { -'use strict'; - -/** - * Commons API Handler. - * @constructor - * - * @param {string} defaultUrl - * - * @throws {Error} if a required parameter is omitted. - */ -var Api = function( defaultUrl ) { - if( !defaultUrl ) { - throw new Error( 'A required parameter has been omitted' ); - } - this._defaultUrl = defaultUrl; -}; - -$.extend( Api.prototype, { - /** - * Default API URL. - * @type {string} - */ - _defaultUrl: null, - - /** - * Returns the API's default URL. - * @return {string} - */ - getDefaultUrl: function() { - return this._defaultUrl; - }, - - /** - * Generates an Asset object for a specific filename. - * - * @param {string} prefixedFilename - * @param {string} [wikiUrl] - * @return {Object} jQuery Promise - * Resolved parameters: - * - {Asset} - * Rejected parameters: - * - {AjaxError} - */ - getAsset: function( prefixedFilename, wikiUrl ) { - var self = this, - deferred = $.Deferred(); - - this._getMetaData( prefixedFilename, wikiUrl ) - .done( function( metaData ) { - - self._getPageContent( prefixedFilename, wikiUrl ) - .done( function( $dom ) { - - self._getPageTemplates( prefixedFilename, wikiUrl ) - .done( function( templates ) { - var assetPage = new WikiAssetPage( - prefixedFilename, metaData.mediatype, $dom, templates, self, wikiUrl - ); - - deferred.resolve( assetPage.getAsset() ); - } ) - .fail( function( error ) { - deferred.reject( error ); - } ); - } ) - .fail( function( error ) { - deferred.reject( error ); - } ); - - } ) - .fail( function( error ) { - deferred.reject( error ); - } ); - - return deferred.promise(); - }, - - /** - * Retrieves the asset page content of a specific file. - * - * @param {string} prefixedFilename - * @param {string} [wikiUrl] - * @return {Object} jQuery Promise - * Resolved parameters: - * - {jQuery} Page content DOM - * Rejected parameters: - * - {AjaxError} - */ - _getPageContent: function( prefixedFilename, wikiUrl ) { - var deferred = $.Deferred(); - - this._query( prefixedFilename, 'revisions', wikiUrl, { - rvprop: 'content', - rvparse: 1 - } ) - .done( function( page, ajaxOptions ) { - if( !page.revisions || page.revisions.length === 0 || !page.revisions[0]['*'] ) { - deferred.reject( new AjaxError( 'revision-invalid', ajaxOptions ) ); - return; - } - - deferred.resolve( $( '
' ).html( page.revisions[0]['*'] ) ); - } ) - .fail( function( error ) { - deferred.reject( error ); - } ); - - return deferred.promise(); - }, - - /** - * Retrieves the Wikipage templates used on a specific file's description page. - * - * @param {string} prefixedFilename - * @param {string} [wikiUrl] - * @return {Object} jQuery Promise - * Resolved parameters: - * - {string[]} - * Rejected parameters: - * - {AjaxError} - */ - _getPageTemplates: function( prefixedFilename, wikiUrl ) { - var deferred = $.Deferred(); - - this._query( prefixedFilename, 'templates', wikiUrl, { - tlnamespace: 10, - tllimit: 100 - } ) - .done( function( page, ajaxOptions ) { - if( !page.templates ) { - deferred.reject( new AjaxError( 'templates-missing', ajaxOptions ) ); - return; - } - - var templates = []; - $.each( page.templates, function( i, template ) { - templates.push( template.title.replace( /^[^:]+:/, '' ) ); - } ); - - deferred.resolve( templates ); - } ) - .fail( function( error ) { - deferred.reject( error ); - } ); - - return deferred.promise(); - }, - - /** - * Retrieves image information for a specific file according to a specific image size. - * - * @param {string} prefixedFilename - * @param {number} size - * @param {string} [wikiUrl] - * @return {Object} jQuery Promise - * Resolved parameters: - * - {ImageInfo} - * Rejected parameters: - * - {AjaxError} - */ - getImageInfo: function( prefixedFilename, size, wikiUrl ) { - var deferred = $.Deferred(); - - this._query( prefixedFilename, 'imageinfo', wikiUrl, { - iiprop: 'url', - iiurlwidth: size, - iiurlheight: size - } ) - .done( function( page, ajaxOptions ) { - if( !page.imageinfo || page.imageinfo[0].length === 0 ) { - deferred.reject( new AjaxError( 'imageinfo-missing', ajaxOptions ) ); - return; - } - deferred.resolve( ImageInfo.newFromMediaWikiImageInfoJson( page.imageinfo[0] ) ); - } ) - .fail( function( error ) { - deferred.reject( error ); - } ); - - return deferred.promise(); - }, - - /** - * Retrieves a file's meta data. - * - * @param {string} prefixedFilename - * @param {string} [wikiUrl] - * @return {Object} jQuery Promise: - * Resolved parameters: - * - {Object} - * Rejected parameters: - * - {AjaxError} - */ - _getMetaData: function( prefixedFilename, wikiUrl ) { - var deferred = $.Deferred(); - - this._query( prefixedFilename, 'imageinfo', wikiUrl, { - iiprop: 'mediatype|url', - iilimit: 1 - } ) - .done( function( page, ajaxOptions ) { - if( !page.imageinfo ) { - deferred.resolve( 'unknown' ); - return; - } - - for( var i = 0; i < page.imageinfo.length; i++ ) { - var metaData = page.imageinfo[i]; - if( metaData.mediatype ) { - metaData.mediatype = metaData.mediatype.toLowerCase(); - } - deferred.resolve( metaData ); - return; - } - - deferred.reject( new AjaxError( 'mediatype-missing', ajaxOptions ) ); - } ) - .fail( function( error ) { - deferred.reject( error ); - } ); - - return deferred; - }, - - /** - * Checks a specific Wikipedia page for images returning the image info for each image used on - * the page. If the page itself is a description page of an image, the resolved promise - * transmits the title the function was called with. The resolved promise's second parameter is - * the original wiki URL or the full asset URL if the asset is not stored on the local Wiki. - * - * @param {string} title - * @param {string} [wikiUrl] - * @return {Object} jQuery Promise - * Resolved parameters: - * - {ImageInfo[]|string} - * - {string} - * Rejected parameters: - * - {AjaxError} - */ - getWikipediaPageImageInfo: function( title, wikiUrl ) { - var self = this, - deferred = $.Deferred(); - - this._getMetaData( title, wikiUrl ) - .done( function( metaData ) { - if( $.inArray( metaData.mediatype, config.custom.supportedMediaTypes ) !== -1 ) { - deferred.resolve( title, metaData.url ); - return; - } - - self._getWikipediaPageImages( title, wikiUrl ) - .done( function( imageTitles ) { - self._getWikipediaImageInfos( imageTitles, wikiUrl ) - .done( function( imageUrls ) { - deferred.resolve( imageUrls, wikiUrl ); - } ) - .fail( function( error ) { - deferred.reject( error ); - } ); - } ) - .fail( function( error ) { - deferred.reject( error ); - } ); - } ) - .fail( function( error ) { - deferred.reject( error ); - } ); - - return deferred.promise(); - }, - - /** - * Retrieves the titles of the images used on an specific Wikipedia page. - * - * @param {string} title - * @param {string} [wikiUrl] - * @return {Object} jQuery Promise - * Resolved parameters: - * - {string[]} - * Rejected parameters: - * - {AjaxError} - */ - _getWikipediaPageImages: function( title, wikiUrl ) { - var deferred = $.Deferred(); - - var params = { - imlimit: 100, - titles: title, - format: 'json' - }; - - this._query( title, 'images', wikiUrl, params ) - .done( function( page ) { - var imageTitles = []; - - for( var i = 0; i < page.images.length; i++ ) { - imageTitles.push( page.images[i].title ); - } - - deferred.resolve( imageTitles ); - } ) - .fail( function( error ) { - deferred.reject( error ); - } ); - - return deferred.promise(); - }, - - /** - * Retrieves image info for a list of images used on a specific Wikipedia. - * - * @param {string[]} imageTitles - * @param {string} [wikiUrl] - * @return {Object} jQuery Promise - * Resolved parameters: - * - {ImageInfo[]} - * Rejected parameters: - * - {AjaxError} - */ - _getWikipediaImageInfos: function( imageTitles, wikiUrl ) { - var deferred = $.Deferred(); - - if( imageTitles.length === 0 ) { - deferred.resolve( [] ); - return deferred.promise(); - } - - var params = { - iiprop: 'url', - iilimit: 1, - iiurlwidth: 300, - iiurlheight: 300 - }; - - this._query( imageTitles, 'imageinfo', wikiUrl, params ) - .done( function( pages ) { - if( !$.isArray( pages ) ) { - pages = [pages]; - } - - var imageInfos = []; - - $.each( pages, function( index, page ) { - imageInfos.push( ImageInfo.newFromMediaWikiImageInfoJson( page.imageinfo[0] ) ); - } ); - - deferred.resolve( imageInfos ); - } ) - .fail( function( error ) { - deferred.reject( error ); - } ); - - return deferred.promise(); - }, - - /** - * Issues a call to the Commons API of a Wikipedia API querying for a specific property of a - * file. - * - * @param {string|string[]} title Page title(s) - * @param {string} property - * @param {string} [wikiUrl] - * @param {Object} [params] API request parameter overwrites or additional parameters. - * @return {Object} jQuery Promise - * Resolved parameters: - * - {Object[]} - * - {Object} Options $.ajax() has been initiated with - * Rejected parameters: - * - {AjaxError} - */ - _query: function( title, property, wikiUrl, params ) { - var deferred = $.Deferred(); - - params = $.extend( { - action: 'query', - prop: property, - titles: $.isArray( title ) ? title.join( '|' ) : title, - format: 'json' - }, params ); - - var ajaxOptions = { - url: ( wikiUrl || this._defaultUrl ) + 'w/api.php', - crossDomain: true, - dataType: 'jsonp', - data: params, - timeout: 5000 - }; - - $.ajax( ajaxOptions ) - .done( function( response ) { - if( response.query === undefined || response.query.pages === undefined ) { - deferred.reject( new AjaxError( 'response-unexpected', ajaxOptions ) ); - return; - } - - var pages = [], - errorCode; - - $.each( response.query.pages, function( id, page ) { - var isSharedImage = property === 'imageinfo' && page.imagerepository === 'shared'; - - if( page.missing !== undefined && !isSharedImage ) { - errorCode = 'page-missing'; - } else if( page.invalid !== undefined ) { - errorCode = 'page-invalid'; - } else { - pages.push( page ); - } - - } ); - - if( pages.length === 1 ) { - deferred.resolve( pages[0], ajaxOptions ); - } else if( pages.length > 0 ) { - deferred.resolve( pages, ajaxOptions ); - } else if( errorCode ) { - deferred.reject( new AjaxError( errorCode, ajaxOptions ) ); - } else { - deferred.reject( new AjaxError( 'response-corrupted', ajaxOptions ) ); - } - } ) - .fail( function() { - // Since there is no error handling for jsonp requests, the error is a timeout in any - // and it does not make any sense to analyze the jqXHR object. - deferred.reject( new AjaxError( '*', ajaxOptions ) ); - } ); - - return deferred.promise(); - } - -} ); - -return Api; - -} ); diff --git a/app/Application.js b/app/Application.js deleted file mode 100644 index 4632a65..0000000 --- a/app/Application.js +++ /dev/null @@ -1,242 +0,0 @@ -/** - * @licence GNU GPL v3 - * @author snater.com < wikimedia@snater.com > - */ -define( - [ - 'jquery', - 'app/Navigation', - 'app/FrontPage', - 'app/Preview', - 'app/Questionnaire', - 'app/OptionContainer', - 'dojo/back' - ], - function( $, Navigation, FrontPage, Preview, Questionnaire, OptionContainer, back ) { -'use strict'; - -/** - * Application renderer - * @constructor - * - * @param {jQuery} $node - * @param {Object} [options] - * - * @throws {Error} if a required parameter is not defined. - */ -var Application = function( $node, options ) { - if( !$node ) { - throw new Error( 'Required parameter(s) not defined' ); - } - - this._$node = $node; - - this._options = $.extend( { - 'imageSize': 500 - }, ( options || {} ) ); -}; - -$.extend( Application.prototype, { - /** - * @type {jQuery} - */ - _$node: null, - - /** - * @type {Object} - */ - _options: null, - - /** - * @type {FrontPage|null} - */ - _frontPage: null, - - /** - * @type {Navigation|null} - */ - _navigation: null, - - /** - * @type {Preview|null} - */ - _preview: null, - - /** - * @type {Questionnaire|null} - */ - _questionnaire: null, - - /** - * @type {OptionContainer|null} - */ - _optionContainer: null, - - /** - * Starts the application. - * - * @param {string} [url] - */ - start: function( url ) { - var self = this; - - this._$node.empty(); - - this._navigation = new Navigation( this._$node ); - - var $frontPage = $( '
' ); - this._frontPage = new FrontPage( $frontPage, url ); - - $( this._frontPage ) - .on( 'asset', function( event, asset ) { - self._renderApplicationPage( asset ); - } ); - - if( this._questionnaire === null ) { - var initialState = { - back: function() { - self._questionnaire._currentStateIndex = -1; - $( self._questionnaire ).trigger( 'back', [ self._questionnaire._asset ] ); - } - }; - back.setInitialState( initialState ); - back.addToHistory( initialState ); - } - - this._$node - .append( this._navigation.create( false ) ) - .append( $frontPage ); - }, - - /** - * Renders the application page. - * - * @param {Asset} asset - */ - _renderApplicationPage: function( asset ) { - var self = this; - - var $preview = $( '
' ); - this._preview = new Preview( $preview, asset ); - - var $questionnaire = $( '
' ); - this._questionnaire = new Questionnaire( $questionnaire, asset ); - $( this._questionnaire ) - .on( 'restart', function() { - self._regenerateQuestionnaire(); - } ); - - this._addEventHandlers( this._questionnaire ); - - var $optionContainer = $( '
' ), - licence = asset.getLicence(), - renderRawText = licence && !licence.isInGroup( 'pd' ) && !licence.isInGroup( 'cc0' ); - - this._optionContainer = new OptionContainer( $optionContainer, asset ); - - if( renderRawText ) { - this._optionContainer.push( 'rawText' ); - } - - this._addEventHandlers( this._optionContainer ); - - this._$node - .empty() - .append( this._navigation.create() ) - .append( $preview ) - .append( $questionnaire ) - .append( $optionContainer ); - - this._questionnaire.start().done( function() { - self._optionContainer.render(); - - // Evaluate initial state to reflect the default attribution: - self._preview.update( - self._questionnaire.getAttributionGenerator(), - self._questionnaire.generateSupplement(), - self._getImageSize() - ).done( function() { - self._optionContainer.setAttributionGenerator( - self._questionnaire.getAttributionGenerator() - ); - } ); - } ); - }, - - _regenerateQuestionnaire: function() { - var self = this; - - this._$node - .empty() - .append( this._navigation.create() ) - .append( this._preview._$node ) - .append( this._questionnaire._$node ) - .append( this._optionContainer._$node ); - - this._questionnaire.restartQuestionnaire().done( function() { - self._optionContainer.render(); - - // Evaluate initial state to reflect the default attribution: - self._preview.update( - self._questionnaire.getAttributionGenerator(), - self._questionnaire.generateSupplement(), - self._getImageSize() - ).done( function() { - self._optionContainer.setAttributionGenerator( - self._questionnaire.getAttributionGenerator() - ); - } ); - } ); - }, - - /** - * Adds event handlers to the provided instance. - * - * @param {*} instance - */ - _addEventHandlers: function( instance ) { - var self = this; - - $( instance ).on( 'update', function() { - self._preview.update( - self._questionnaire.getAttributionGenerator(), - self._questionnaire.generateSupplement(), - self._getImageSize() - ).done( function( $attributedImageFrame ) { - if( instance instanceof Questionnaire ) { - self._optionContainer.push( 'htmlCode' ); - self._optionContainer.setAttributionGenerator( - self._questionnaire.getAttributionGenerator() - ); - - } else if( instance instanceof OptionContainer ) { - self._optionContainer.getOption( 'htmlCode' ) - .setImageHtml( $attributedImageFrame.clone() ); - } - } ); - } ); - - if( instance instanceof Questionnaire ) { - $( instance ).on( 'back', function( event, asset ) { - // Prevent opened underlay from remaining visible: - self._optionContainer.render(); - - self.start( asset.getUrl() ); - } ); - } - }, - - /** - * @return {number} - */ - _getImageSize: function() { - return this._optionContainer - ? this._optionContainer.getOption( 'imageSize' ).value() - : this._options.imageSize; - } - -} ); - -return Application; - -} ); diff --git a/app/ApplicationError.js b/app/ApplicationError.js deleted file mode 100644 index 14c5db2..0000000 --- a/app/ApplicationError.js +++ /dev/null @@ -1,43 +0,0 @@ -/** - * @licence GNU GPL v3 - * @author snater.com < wikimedia@snater.com > - */ -define( ['jquery', 'dojo/i18n!./nls/ApplicationError'], function( $, messages ) { -'use strict'; - -/** - * Application Error - * @constructor - * - * @param {string} code - * - * @throws {Error} if a required parameter is not defined properly. - */ -var ApplicationError = function( code ) { - if( !code || typeof code !== 'string' ) { - throw new Error( 'Required parameters are nor properly defined' ); - } - - this._code = code; -}; - -$.extend( ApplicationError.prototype, { - /** - * @param {string} - */ - _code: null, - - /** - * Returns the error's localized message. - * - * @return {string} - */ - getMessage: function() { - return messages[this._code] || messages['*']; - } - -} ); - -return ApplicationError; - -} ); diff --git a/app/Asset.js b/app/Asset.js deleted file mode 100644 index b51e082..0000000 --- a/app/Asset.js +++ /dev/null @@ -1,271 +0,0 @@ -/** - * @licence GNU GPL v3 - * @author snater.com < wikimedia@snater.com > - */ -define( ['jquery', 'app/Author', 'dojo/_base/declare'], function( $, Author, declare ) { -'use strict'; - -/** - * Represents an asset. - * @constructor - * - * @param {string} url - * @param {string} mediaType - * @param {Licence|null} [licence] - * @param {string|null} [title] - * @param {Author[]|null} [authors] - * @param {string} [url] - * @param {jQuery|null} [$attribution] - * @param {Api|null} [api] - * - * @throws {Error} if a required parameter is not defined. - */ -var Asset = declare( null, { - constructor: function( filename, mediaType, licence, title, authors, url, $attribution, api ) { - if( typeof filename !== 'string' || typeof mediaType !== 'string' ) { - throw new Error( 'No proper initialization parameters specified' ); - } - - this._filename = filename; - this._mediaType = mediaType; - this._licence = licence || null; - this._title = title || ''; - this._url = url || null; - this._authors = authors || []; - this._$attribution = $attribution || null; - this._api = api || null; - - this._imageInfo = {}; - }, - - /** - * @type {string} - */ - _filename: null, - - /** - * @type {string} - */ - _mediaType: null, - - /** - * @type {Licence|null} - */ - _licence: null, - - /** - * @type {string} - */ - _title: null, - - /** - * @type {Author[]} - */ - _authors: null, - - /** - * @type {string} - */ - _url: null, - - /** - * @type {jQuery|null} - */ - _$attribution: null, - - /** - * @type {Api} - */ - _api: null, - - /** - * @type {Object} - */ - _imageInfo: null, - - /** - * @return {string} - */ - getFilename: function() { - return this._filename; - }, - - /** - * @return {string} - */ - getMediaType: function() { - return this._mediaType; - }, - - /** - * @param {Licence} licence - */ - setLicence: function( licence ) { - this._licence = licence; - }, - - /** - * @return {Licence|null} - */ - getLicence: function() { - return this._licence; - }, - - /** - * @param {string} title - * - * @throws {Error} if the title is not of type "string". - */ - setTitle: function( title ) { - if( typeof title !== 'string' ) { - throw new Error( 'title needs to be a string' ); - } - this._title = title; - }, - - /** - * @return {string} - */ - getTitle: function() { - return this._title; - }, - - /** - * @param {string|null} url - * - * @throws {Error} if the URL is not specified properly. - */ - setUrl: function( url ) { - if( typeof url !== 'string' && url !== null ) { - throw new Error( 'URL needs to be a string or null' ); - } - this._url = url; - }, - - /** - * @return {string|null} - */ - getUrl: function() { - if( this._url === null ) { - return null; - } - - return this._url.indexOf( 'http' ) === 0 ? this._url : 'http://' + this._url; - }, - - /** - * @param {Author[]} authors - */ - setAuthors: function( authors ) { - this._authors = authors; - }, - - /** - * @param {options} [options] - * @return {Author[]|string} - */ - getAuthors: function( options ) { - options = options || {}; - - if( options.format !== 'string' ) { - return this._authors; - } - - var authors = []; - $.each( this._authors, function( index, author ) { - authors.push( author.getText() ); - } ); - - return authors.join( '; ' ); - }, - - /** - * @return {jQuery} - */ - getAttribution: function() { - return this._$attribution ? this._$attribution.clone() : null; - }, - - /** - * Retrieves the asset's image information. - * - * @param {number} imageSize - * @return {Object} jQuery Promise - * Resolve parameters: - * - {Object} Image information received from the API - * Rejected parameters: - * - {AjaxError} - */ - getImageInfo: function( imageSize ) { - var self = this, - deferred = $.Deferred(); - - if( this._imageInfo[imageSize] ) { - deferred.resolve( this._imageInfo[imageSize] ); - } else { - this._api.getImageInfo( this._filename, imageSize, this._wikiUrl ) - .done( function( imageInfo ) { - self._imageInfo[imageSize] = imageInfo; - deferred.resolve( imageInfo ); - } ) - .fail( function( error ) { - deferred.reject( error ); - } ); - } - - return deferred.promise(); - }, - - /** - * Checks if the asset object equals another asset object. - * - * @param {Asset} asset - * @return {boolean} - */ - equals: function( asset ) { - var authors = asset.getAuthors(); - - if( authors.length !== this._authors.length ) { - return false; - } - - for( var i = 0; i < this._authors.length; i++ ) { - if( authors[i].getText() !== this._authors[i].getText() ) { - return false; - } - } - - var haveLicences = asset.getLicence() && this.getLicence(), - sameLicence = !haveLicences || asset.getLicence().getId() === this.getLicence().getId(); - - return asset.getFilename() === this.getFilename() - && asset.getTitle() === this.getTitle() - && asset.getUrl() === this.getUrl() - && sameLicence; - } - -} ); - -Asset.extend( { - /** - * Clones the asset. - * - * @return {Asset} - */ - clone: function() { - return new Asset( - this._filename, - this._mediaType, - this._licence, - this._title, - this._authors, - this._url, - this._$attribution, - this._api - ); - } -} ); - -return Asset; - -} ); diff --git a/app/AttributionGenerator.js b/app/AttributionGenerator.js deleted file mode 100644 index 08382ed..0000000 --- a/app/AttributionGenerator.js +++ /dev/null @@ -1,247 +0,0 @@ -/** - * @licence GNU GPL v3 - * @author snater.com < wikimedia@snater.com > - */ -define( ['jquery'], function( $ ) { -'use strict'; - -/** - * Generator for attribution texts. - * @constructor - * - * @option {string|null} editor - * Editor of the asset. - * Default: null - * - * @option {string} format - * May either be "text" or "html". - * Default: 'text' - * - * @option {boolean} licenceOnly - * Whether to only display the licence without author, title and other attributions. - * Default: false - * - * @option {boolean} licenceLink - * Whether to show the link / link the licence to the licence's legal code. Instead of a - * link, the plain licence name will be shown in any case. - * Default: true - * - * @param {Asset} asset - * @param {Object} [options] - */ -var AttributionGenerator = function( asset, options ) { - this._asset = asset; - - this._options = $.extend( { - editor: null, - format: 'text', - licenceOnly: false, - licenceLink: true - }, options ); -}; - -$.extend( AttributionGenerator.prototype, { - /** - * @type {Asset} - */ - _asset: null, - - /** - * @type {Object} - */ - _options: null, - - /** - * @return {Asset} - */ - getAsset: function() { - return this._asset; - }, - - /** - * @return {Object} - */ - getOptions: function() { - return this._options; - }, - - /** - * Checks whether another AttributionGenerator instance equals this one. - * - * @param {AttributionGenerator} attributionGenerator - * @return {boolean} - */ - equals: function( attributionGenerator ) { - if( !( attributionGenerator instanceof AttributionGenerator ) ) { - return false; - } - - if( !attributionGenerator.getAsset().equals( this._asset ) ) { - return false; - } - - var otherOptions = attributionGenerator.getOptions(), - mismatch = false; - - $.each( this._options, function( k, v ) { - if( otherOptions[k] !== v ) { - mismatch = true; - return false; - } - } ); - - return !mismatch; - }, - - /** - * Generates an attribution tag line from the current set of answers. Returns "null" if the - * asset's licence does not require a tag line. - * - * @param {boolean} [raw] If "true", no styles and no DOM structure at all is applied to the - * licence text. - * @return {jQuery|null} - */ - generate: function( raw ) { - var licenceId = this._asset.getLicence().getId(); - - if( licenceId === 'PD' || licenceId === 'cc-zero' ) { - return null; - } - - var format = raw ? 'text' : this._options.format, - $attribution = $( '
' ).addClass( 'attribution' ), - $licence = this._generateLicence( format, this._options.licenceLink ); - - if( !this._options.licenceOnly ) { - var $author = this._generateAuthor( format ), - $title = this._generateTitle( format ), - $editor = this._generateEditor(); - - $attribution - .append( $author ); - - if( format === 'text' && this._asset.getUrl() ) { - $attribution - .append( document.createTextNode( ' ' ) ) - .append( $( '' ).addClass( 'attribution-url' ) - .append( document.createTextNode( '(' ) ) - .append( document.createTextNode( this._asset.getUrl() ) ) - .append( document.createTextNode( ')' ) ) - ); - } - - $attribution - .append( document.createTextNode( ', ' ) ) - .append( $title ); - - if( this._options.editor ) { - $attribution - .append( document.createTextNode( ', ' ) ) - .append( $editor ); - } - - $attribution.append( document.createTextNode( ', ' ) ); - } - - $attribution.append( $licence ); - - return raw ? $attribution.text() : $attribution; - }, - - /** - * Generates the author(s) DOM to be used in the tag line. - * - * @param {string} format - * @return {jQuery} - */ - _generateAuthor: function( format ) { - // Prefer attribution over author: - var $attribution = this._asset.getAttribution(); - if( $attribution ) { - if( $attribution.length && $attribution.text().length ) { - return format === 'html' ? $attribution : $attribution.text(); - } - } - - var authors = this._asset.getAuthors(), - $authors = $( '' ).addClass( 'attribution-author' ); - - for( var i = 0; i < authors.length; i++ ) { - var author = authors[i]; - - if( i > 0 ) { - $authors.append( document.createTextNode( ', ' ) ); - } - - $authors.append( format === 'html' ? author.getHtml() : author.getText() ); - } - - return $authors; - }, - - /** - * Generates the licence DOM to be used in the tag line. - * - * @param {string} format - * @param {boolean} licenceLink - * @return {jQuery} - */ - _generateLicence: function( format, licenceLink ) { - var licence = this._asset.getLicence(), - $licence = $( '' ).addClass( 'attribution-licence' ); - - if( !licenceLink || !licence.getUrl() ) { - return $licence.text( licence.getName() ); - } - - if( format === 'html' ) { - $licence.append( - $( '' ).attr( 'href', licence.getUrl() ).text( licence.getName() ) - ); - } else { - $licence.text( licence.getUrl() ); - } - - return $licence; - }, - - /** - * Generates the asset title DOM to be used in the tag line. - * - * @return {jQuery} - */ - _generateTitle: function( format ) { - var title = '„' + this._asset.getTitle() + '“', - $title = $( '' ).addClass( 'attribution-title' ); - - if( format === 'html' ) { - $title.append( $( '' ).attr( 'href', this._asset.getUrl() ).text( title ) ); - } else { - $title.text( title ); - } - - return $title; - }, - - /** - * Generates the editor DOM to be use in the tag line. If no editor is specified, an empty - * jQuery object will be returned. - * - * @return {jQuery} - */ - _generateEditor: function() { - var editor = this._options.editor, - $editor = $(); - - if( editor ) { - $editor = $( '' ).addClass( 'attribution-editor' ).text( editor ); - } - - return $editor; - } - -} ); - -return AttributionGenerator; - -} ); diff --git a/app/Author.js b/app/Author.js deleted file mode 100644 index f9f92a2..0000000 --- a/app/Author.js +++ /dev/null @@ -1,42 +0,0 @@ -/** - * @licence GNU GPL v3 - * @author snater.com < wikimedia@snater.com > - */ -define( ['jquery'], function( $ ) { -'use strict'; - -/** - * Represents a Commons author. - * - * @param {jQuery} $author - * @constructor - */ -var Author = function( $author ) { - this._$author = $author; -}; - -$.extend( Author.prototype, { - /** - * @type {jQuery} - */ - _$author: null, - - /** - * @return {jQuery} - */ - getHtml: function() { - return this._$author.clone(); - }, - - /** - * @return {string} - */ - getText: function() { - return $.trim( this._$author.text() ); - } - -} ); - -return Author; - -} ); diff --git a/app/FrontPage.js b/app/FrontPage.js deleted file mode 100644 index f183fa8..0000000 --- a/app/FrontPage.js +++ /dev/null @@ -1,307 +0,0 @@ -/** - * @licence GNU GPL v3 - * @author snater.com < wikimedia@snater.com > - */ -define( [ - 'jquery', - 'dojo/_base/config', - 'dojo/i18n!./nls/FrontPage', - 'templates/registry', - 'app/ApplicationError', - 'app/Api', - 'app/InputHandler', - 'app/NoApi', - 'app/WikiAsset' -], function( - $, - config, - messages, - templateRegistry, - ApplicationError, - Api, - InputHandler, - NoApi, - WikiAsset -) { -'use strict'; - -/** - * Front-page renderer. - * @constructor - * - * @param {jQuery} $node - * @param {string} url - * - * @throws {Error} if a required parameter is not defined. - * - * @event asset - * Triggered when processing the input has successfully resulted in instantiating an Asset - * object. - * (1) {jQuery.Event} - * (2) {Asset} - */ -var FrontPage = function( $node, url ) { - if( !$node ) { - throw new Error( 'Required parameters are not properly defined' ); - } - - this._$node = $node.addClass( 'frontpage' ); - - document.title = messages['attribution generator']; - - this._render( url ); -}; - -$.extend( FrontPage.prototype, { - /** - * @type {jQuery} - */ - _$node: null, - - /** - * @type {InputHandler} - */ - _inputHandler: null, - - /** - * @type {string|null} - */ - _initialPaddingTop: null, - - /** - * Renders the front page. - * - * @param {string} [url] - */ - _render: function( url ) { - var self = this; - - var $input = $( '' ) - .attr( 'placeholder', messages['input placeholder'] ) - .on( 'keypress', function( event ) { - if( event.keyCode === 13 ) { - event.preventDefault(); - self._submit(); - } - } ); - - if( url ) { - $input.val( url ); - } - - this._$node - .append( $( '

' ).text( messages['attribution generator'] ) ) - .append( $( '
' ).addClass( 'frontpage-container-input' ).append( $input ) ) - .append( $( ' +
+ +

+
+
+ + + + + + diff --git a/redesign/js/app/Api.js b/js/app/Api.js similarity index 100% rename from redesign/js/app/Api.js rename to js/app/Api.js diff --git a/redesign/js/app/ApplicationError.js b/js/app/ApplicationError.js similarity index 100% rename from redesign/js/app/ApplicationError.js rename to js/app/ApplicationError.js diff --git a/redesign/js/app/Asset.js b/js/app/Asset.js similarity index 100% rename from redesign/js/app/Asset.js rename to js/app/Asset.js diff --git a/redesign/js/app/AttributionDialogue.js b/js/app/AttributionDialogue.js similarity index 100% rename from redesign/js/app/AttributionDialogue.js rename to js/app/AttributionDialogue.js diff --git a/redesign/js/app/Author.js b/js/app/Author.js similarity index 100% rename from redesign/js/app/Author.js rename to js/app/Author.js diff --git a/redesign/js/app/Dialogue.js b/js/app/Dialogue.js similarity index 100% rename from redesign/js/app/Dialogue.js rename to js/app/Dialogue.js diff --git a/redesign/js/app/DialogueEvaluation.js b/js/app/DialogueEvaluation.js similarity index 100% rename from redesign/js/app/DialogueEvaluation.js rename to js/app/DialogueEvaluation.js diff --git a/redesign/js/app/DialogueStep.js b/js/app/DialogueStep.js similarity index 100% rename from redesign/js/app/DialogueStep.js rename to js/app/DialogueStep.js diff --git a/redesign/js/app/FileForm.js b/js/app/FileForm.js similarity index 100% rename from redesign/js/app/FileForm.js rename to js/app/FileForm.js diff --git a/redesign/js/app/ImageInfo.js b/js/app/ImageInfo.js similarity index 100% rename from redesign/js/app/ImageInfo.js rename to js/app/ImageInfo.js diff --git a/redesign/js/app/InputHandler.js b/js/app/InputHandler.js similarity index 100% rename from redesign/js/app/InputHandler.js rename to js/app/InputHandler.js diff --git a/redesign/js/app/LICENCES.js b/js/app/LICENCES.js similarity index 100% rename from redesign/js/app/LICENCES.js rename to js/app/LICENCES.js diff --git a/redesign/js/app/Licence.js b/js/app/Licence.js similarity index 100% rename from redesign/js/app/Licence.js rename to js/app/Licence.js diff --git a/redesign/js/app/LicenceStep.js b/js/app/LicenceStep.js similarity index 100% rename from redesign/js/app/LicenceStep.js rename to js/app/LicenceStep.js diff --git a/redesign/js/app/LicenceStore.js b/js/app/LicenceStore.js similarity index 100% rename from redesign/js/app/LicenceStore.js rename to js/app/LicenceStore.js diff --git a/redesign/js/app/Messages.js b/js/app/Messages.js similarity index 100% rename from redesign/js/app/Messages.js rename to js/app/Messages.js diff --git a/redesign/js/app/WikiAsset.js b/js/app/WikiAsset.js similarity index 100% rename from redesign/js/app/WikiAsset.js rename to js/app/WikiAsset.js diff --git a/redesign/js/app/WikiAssetPage.js b/js/app/WikiAssetPage.js similarity index 100% rename from redesign/js/app/WikiAssetPage.js rename to js/app/WikiAssetPage.js diff --git a/redesign/js/app/templates/Attribution.handlebars b/js/app/templates/Attribution.handlebars similarity index 100% rename from redesign/js/app/templates/Attribution.handlebars rename to js/app/templates/Attribution.handlebars diff --git a/redesign/js/app/templates/AuthorStep.handlebars b/js/app/templates/AuthorStep.handlebars similarity index 100% rename from redesign/js/app/templates/AuthorStep.handlebars rename to js/app/templates/AuthorStep.handlebars diff --git a/redesign/js/app/templates/ChangeStep.handlebars b/js/app/templates/ChangeStep.handlebars similarity index 100% rename from redesign/js/app/templates/ChangeStep.handlebars rename to js/app/templates/ChangeStep.handlebars diff --git a/redesign/js/app/templates/CompilationStep.handlebars b/js/app/templates/CompilationStep.handlebars similarity index 100% rename from redesign/js/app/templates/CompilationStep.handlebars rename to js/app/templates/CompilationStep.handlebars diff --git a/redesign/js/app/templates/CreatorStep.handlebars b/js/app/templates/CreatorStep.handlebars similarity index 100% rename from redesign/js/app/templates/CreatorStep.handlebars rename to js/app/templates/CreatorStep.handlebars diff --git a/redesign/js/app/templates/Dialogue.handlebars b/js/app/templates/Dialogue.handlebars similarity index 100% rename from redesign/js/app/templates/Dialogue.handlebars rename to js/app/templates/Dialogue.handlebars diff --git a/redesign/js/app/templates/DialogueScreen.handlebars b/js/app/templates/DialogueScreen.handlebars similarity index 100% rename from redesign/js/app/templates/DialogueScreen.handlebars rename to js/app/templates/DialogueScreen.handlebars diff --git a/redesign/js/app/templates/Done.handlebars b/js/app/templates/Done.handlebars similarity index 100% rename from redesign/js/app/templates/Done.handlebars rename to js/app/templates/Done.handlebars diff --git a/redesign/js/app/templates/DosAndDonts.handlebars b/js/app/templates/DosAndDonts.handlebars similarity index 100% rename from redesign/js/app/templates/DosAndDonts.handlebars rename to js/app/templates/DosAndDonts.handlebars diff --git a/redesign/js/app/templates/EditingStep.handlebars b/js/app/templates/EditingStep.handlebars similarity index 100% rename from redesign/js/app/templates/EditingStep.handlebars rename to js/app/templates/EditingStep.handlebars diff --git a/redesign/js/app/templates/ImagePreview.handlebars b/js/app/templates/ImagePreview.handlebars similarity index 100% rename from redesign/js/app/templates/ImagePreview.handlebars rename to js/app/templates/ImagePreview.handlebars diff --git a/redesign/js/app/templates/ImageSuggestion.handlebars b/js/app/templates/ImageSuggestion.handlebars similarity index 100% rename from redesign/js/app/templates/ImageSuggestion.handlebars rename to js/app/templates/ImageSuggestion.handlebars diff --git a/redesign/js/app/templates/InfoBox.handlebars b/js/app/templates/InfoBox.handlebars similarity index 100% rename from redesign/js/app/templates/InfoBox.handlebars rename to js/app/templates/InfoBox.handlebars diff --git a/redesign/js/app/templates/LicenceStep.handlebars b/js/app/templates/LicenceStep.handlebars similarity index 100% rename from redesign/js/app/templates/LicenceStep.handlebars rename to js/app/templates/LicenceStep.handlebars diff --git a/redesign/js/app/templates/ProgressBar.handlebars b/js/app/templates/ProgressBar.handlebars similarity index 100% rename from redesign/js/app/templates/ProgressBar.handlebars rename to js/app/templates/ProgressBar.handlebars diff --git a/redesign/js/app/templates/PublicDomain.handlebars b/js/app/templates/PublicDomain.handlebars similarity index 100% rename from redesign/js/app/templates/PublicDomain.handlebars rename to js/app/templates/PublicDomain.handlebars diff --git a/redesign/js/app/templates/QuestionMark.handlebars b/js/app/templates/QuestionMark.handlebars similarity index 100% rename from redesign/js/app/templates/QuestionMark.handlebars rename to js/app/templates/QuestionMark.handlebars diff --git a/redesign/js/app/templates/SmallButton.handlebars b/js/app/templates/SmallButton.handlebars similarity index 100% rename from redesign/js/app/templates/SmallButton.handlebars rename to js/app/templates/SmallButton.handlebars diff --git a/redesign/js/app/templates/TypeOfUseStep.handlebars b/js/app/templates/TypeOfUseStep.handlebars similarity index 100% rename from redesign/js/app/templates/TypeOfUseStep.handlebars rename to js/app/templates/TypeOfUseStep.handlebars diff --git a/redesign/js/app/views/AttributionDialogueView.js b/js/app/views/AttributionDialogueView.js similarity index 100% rename from redesign/js/app/views/AttributionDialogueView.js rename to js/app/views/AttributionDialogueView.js diff --git a/redesign/js/app/views/DialogueEvaluationView.js b/js/app/views/DialogueEvaluationView.js similarity index 100% rename from redesign/js/app/views/DialogueEvaluationView.js rename to js/app/views/DialogueEvaluationView.js diff --git a/redesign/js/app/views/DialogueScreen.js b/js/app/views/DialogueScreen.js similarity index 100% rename from redesign/js/app/views/DialogueScreen.js rename to js/app/views/DialogueScreen.js diff --git a/redesign/js/app/views/DialogueStepView.js b/js/app/views/DialogueStepView.js similarity index 100% rename from redesign/js/app/views/DialogueStepView.js rename to js/app/views/DialogueStepView.js diff --git a/redesign/js/app/views/ImageSuggestionView.js b/js/app/views/ImageSuggestionView.js similarity index 100% rename from redesign/js/app/views/ImageSuggestionView.js rename to js/app/views/ImageSuggestionView.js diff --git a/redesign/js/app/views/InfoBoxView.js b/js/app/views/InfoBoxView.js similarity index 100% rename from redesign/js/app/views/InfoBoxView.js rename to js/app/views/InfoBoxView.js diff --git a/redesign/js/app/views/LicenceStepView.js b/js/app/views/LicenceStepView.js similarity index 100% rename from redesign/js/app/views/LicenceStepView.js rename to js/app/views/LicenceStepView.js diff --git a/redesign/js/app/views/ProgressBarView.js b/js/app/views/ProgressBarView.js similarity index 100% rename from redesign/js/app/views/ProgressBarView.js rename to js/app/views/ProgressBarView.js diff --git a/redesign/js/app/views/PublicDomainDialogueView.js b/js/app/views/PublicDomainDialogueView.js similarity index 100% rename from redesign/js/app/views/PublicDomainDialogueView.js rename to js/app/views/PublicDomainDialogueView.js diff --git a/redesign/js/background.js b/js/background.js similarity index 100% rename from redesign/js/background.js rename to js/background.js diff --git a/redesign/js/config.json b/js/config.json similarity index 100% rename from redesign/js/config.json rename to js/config.json diff --git a/redesign/js/i18n.json b/js/i18n.json similarity index 100% rename from redesign/js/i18n.json rename to js/i18n.json diff --git a/redesign/js/main.js b/js/main.js similarity index 100% rename from redesign/js/main.js rename to js/main.js diff --git a/redesign/js/scrolling_effects.js b/js/scrolling_effects.js similarity index 100% rename from redesign/js/scrolling_effects.js rename to js/scrolling_effects.js diff --git a/redesign/js/tracking.js b/js/tracking.js similarity index 100% rename from redesign/js/tracking.js rename to js/tracking.js diff --git a/redesign/js/view_helpers.js b/js/view_helpers.js similarity index 100% rename from redesign/js/view_helpers.js rename to js/view_helpers.js diff --git a/lib/dojo/AdapterRegistry.js b/lib/dojo/AdapterRegistry.js deleted file mode 100644 index 4ed7b8a..0000000 --- a/lib/dojo/AdapterRegistry.js +++ /dev/null @@ -1,38 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/AdapterRegistry",["./_base/kernel","./_base/lang"],function(_1,_2){ -var _3=_1.AdapterRegistry=function(_4){ -this.pairs=[]; -this.returnWrappers=_4||false; -}; -_2.extend(_3,{register:function(_5,_6,_7,_8,_9){ -this.pairs[((_9)?"unshift":"push")]([_5,_6,_7,_8]); -},match:function(){ -for(var i=0;i..." to unstage) -# -# modified: somefile.js -# -$ git commit -m "Corrects some defect, fixes #12345, refs #12346" -[t12345 0000000] Corrects some defect, fixes #12345, refs #12346 - 1 file changed, 2 insertions(+), 2 deletions(-) -``` - -## 5. Rebase and Push Changes - -If you have been working on your contribution for a while, the upstream repository may have changed. You may want to -ensure your work is on top of the latest changes so your pull request can be applied cleanly: - -```bash -$ git pull --rebase upstream master -``` - -When you are ready to push your commit to your GitHub repository for the first time on this branch you would do the -following: - -```bash -$ git push -u origin t12345 -``` - -After the first time, you simply need to do: - -```bash -$ git push -``` - -## 6. Issue a Pull Request - -In order to have your commits merged into the main repository, you need to create a pull request. The instructions for -this can be found in the GitHub Help Article [Creating a Pull Request][]. Essentially you do the following: - -1. Go to the site for your repository. -2. Click the Pull Request button. -3. Select the feature branch from your repository. -4. Enter a title and description of your pull request mentioning the corresponding [bug database][] ticket in the description. -5. Review the commit and files changed tabs. -6. Click `Send Pull Request` - -You will get notified about the status of your pull request based on your GitHub settings. - -## 7. Request is Reviewed and Merged - -Your request will be reviewed. It may be merged directly, or you may receive feedback or questions on your pull -request. - -# What Makes a Successful Pull Request? - -Having your contribution accepted is more than just the mechanics of getting your contribution into a pull request, -there are several other things that are expected when contributing to the Dojo Toolkit which are covered below. - -## Coding Style and Linting - -Dojo has a very specific [coding style][styleguide]. All pull requests should adhere to this. - -## Inline Documentation - -Dojo has an inline API documentation called [DojoDoc][]. Any pull request should ensure it has updated the inline -documentation appropriately or added the appropriate inline documentation. - -## Test Cases - -If the pull request changes the functional behaviour or is fixing a defect, the unit test cases should be modified to -reflect this. The committer reviewing your pull request is likely to request the appropriate changes in the test -cases. Dojo utilises its own test harness called [D.O.H.][] and is available as part of the [dojo/util][] repository. - -It is expected that you will have tested your changes against the existing test cases and appropriate platforms prior to -submitting your pull request. - -## Licensing - -All of your submissions are licensed under a dual "New" BSD/AFL license. - -## Expect Discussion and Rework - -Unless you have been working with contributing to Dojo for a while, expect a significant amount of feedback on your -pull requests. We are a very passionate community and even the committers often will provide robust feedback to each -other about their code. Don't be offended by such feedback or feel that your contributions aren't welcome, it is just -that we are quite passionate and Dojo has a long history with many things that are the "Dojo-way" which may be -unfamiliar to those who are just starting to contribute. - -[help documentation]: http://help.github.com/send-pull-requests -[bug database]: http://bugs.dojotoolkit.org/ -[support forum]: http://dojotoolkit.org/community/ -[dojo-contrib]: http://mail.dojotoolkit.org/mailman/listinfo/dojo-contributors -[cla]: http://dojofoundation.org/about/cla -[claCheck]: http://dojofoundation.org/about/claCheck -[Creating a Pull Request]: https://help.github.com/articles/creating-a-pull-request -[Fork a Repo]: https://help.github.com/articles/fork-a-repo -[styleguide]: http://dojotoolkit.org/reference-guide/developer/styleguide.html -[DojoDoc]: http://dojotoolkit.org/reference-guide/developer/markup.html -[D.O.H.]: http://dojotoolkit.org/reference-guide/util/doh.html -[dojo/util]: https://github.com/dojo/util -[interactive rebase]: http://git-scm.com/book/en/Git-Tools-Rewriting-History#Changing-Multiple-Commit-Messages -[rebasing]: http://git-scm.com/book/en/Git-Branching-Rebasing diff --git a/lib/dojo/Deferred.js b/lib/dojo/Deferred.js deleted file mode 100644 index afa9405..0000000 --- a/lib/dojo/Deferred.js +++ /dev/null @@ -1,184 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/Deferred",["./has","./_base/lang","./errors/CancelError","./promise/Promise","./promise/instrumentation"],function(_1,_2,_3,_4,_5){ -"use strict"; -var _6=0,_7=1,_8=2; -var _9="This deferred has already been fulfilled."; -var _a=Object.freeze||function(){ -}; -var _b=function(_c,_d,_e,_f,_10){ -if(1){ -if(_d===_8&&_11.instrumentRejected&&_c.length===0){ -_11.instrumentRejected(_e,false,_f,_10); -} -} -for(var i=0;i<_c.length;i++){ -_12(_c[i],_d,_e,_f); -} -}; -var _12=function(_13,_14,_15,_16){ -var _17=_13[_14]; -var _18=_13.deferred; -if(_17){ -try{ -var _19=_17(_15); -if(_14===_6){ -if(typeof _19!=="undefined"){ -_1a(_18,_14,_19); -} -}else{ -if(_19&&typeof _19.then==="function"){ -_13.cancel=_19.cancel; -_19.then(_1b(_18,_7),_1b(_18,_8),_1b(_18,_6)); -return; -} -_1a(_18,_7,_19); -} -} -catch(error){ -_1a(_18,_8,error); -} -}else{ -_1a(_18,_14,_15); -} -if(1){ -if(_14===_8&&_11.instrumentRejected){ -_11.instrumentRejected(_15,!!_17,_16,_18.promise); -} -} -}; -var _1b=function(_1c,_1d){ -return function(_1e){ -_1a(_1c,_1d,_1e); -}; -}; -var _1a=function(_1f,_20,_21){ -if(!_1f.isCanceled()){ -switch(_20){ -case _6: -_1f.progress(_21); -break; -case _7: -_1f.resolve(_21); -break; -case _8: -_1f.reject(_21); -break; -} -} -}; -var _11=function(_22){ -var _23=this.promise=new _4(); -var _24=this; -var _25,_26,_27; -var _28=false; -var _29=[]; -if(1&&Error.captureStackTrace){ -Error.captureStackTrace(_24,_11); -Error.captureStackTrace(_23,_11); -} -this.isResolved=_23.isResolved=function(){ -return _25===_7; -}; -this.isRejected=_23.isRejected=function(){ -return _25===_8; -}; -this.isFulfilled=_23.isFulfilled=function(){ -return !!_25; -}; -this.isCanceled=_23.isCanceled=function(){ -return _28; -}; -this.progress=function(_2a,_2b){ -if(!_25){ -_b(_29,_6,_2a,null,_24); -return _23; -}else{ -if(_2b===true){ -throw new Error(_9); -}else{ -return _23; -} -} -}; -this.resolve=function(_2c,_2d){ -if(!_25){ -_b(_29,_25=_7,_26=_2c,null,_24); -_29=null; -return _23; -}else{ -if(_2d===true){ -throw new Error(_9); -}else{ -return _23; -} -} -}; -var _2e=this.reject=function(_2f,_30){ -if(!_25){ -if(1&&Error.captureStackTrace){ -Error.captureStackTrace(_27={},_2e); -} -_b(_29,_25=_8,_26=_2f,_27,_24); -_29=null; -return _23; -}else{ -if(_30===true){ -throw new Error(_9); -}else{ -return _23; -} -} -}; -this.then=_23.then=function(_31,_32,_33){ -var _34=[_33,_31,_32]; -_34.cancel=_23.cancel; -_34.deferred=new _11(function(_35){ -return _34.cancel&&_34.cancel(_35); -}); -if(_25&&!_29){ -_12(_34,_25,_26,_27); -}else{ -_29.push(_34); -} -return _34.deferred.promise; -}; -this.cancel=_23.cancel=function(_36,_37){ -if(!_25){ -if(_22){ -var _38=_22(_36); -_36=typeof _38==="undefined"?_36:_38; -} -_28=true; -if(!_25){ -if(typeof _36==="undefined"){ -_36=new _3(); -} -_2e(_36); -return _36; -}else{ -if(_25===_8&&_26===_36){ -return _36; -} -} -}else{ -if(_37===true){ -throw new Error(_9); -} -} -}; -_a(_23); -}; -_11.prototype.toString=function(){ -return "[object Deferred]"; -}; -if(_5){ -_5(_11); -} -return _11; -}); diff --git a/lib/dojo/Deferred.js.uncompressed.js b/lib/dojo/Deferred.js.uncompressed.js deleted file mode 100644 index f78dbd1..0000000 --- a/lib/dojo/Deferred.js.uncompressed.js +++ /dev/null @@ -1,320 +0,0 @@ -define("dojo/Deferred", [ - "./has", - "./_base/lang", - "./errors/CancelError", - "./promise/Promise", - "./promise/instrumentation" -], function(has, lang, CancelError, Promise, instrumentation){ - "use strict"; - - // module: - // dojo/Deferred - - var PROGRESS = 0, - RESOLVED = 1, - REJECTED = 2; - var FULFILLED_ERROR_MESSAGE = "This deferred has already been fulfilled."; - - var freezeObject = Object.freeze || function(){}; - - var signalWaiting = function(waiting, type, result, rejection, deferred){ - if( 1 ){ - if(type === REJECTED && Deferred.instrumentRejected && waiting.length === 0){ - Deferred.instrumentRejected(result, false, rejection, deferred); - } - } - - for(var i = 0; i < waiting.length; i++){ - signalListener(waiting[i], type, result, rejection); - } - }; - - var signalListener = function(listener, type, result, rejection){ - var func = listener[type]; - var deferred = listener.deferred; - if(func){ - try{ - var newResult = func(result); - if(type === PROGRESS){ - if(typeof newResult !== "undefined"){ - signalDeferred(deferred, type, newResult); - } - }else{ - if(newResult && typeof newResult.then === "function"){ - listener.cancel = newResult.cancel; - newResult.then( - // Only make resolvers if they're actually going to be used - makeDeferredSignaler(deferred, RESOLVED), - makeDeferredSignaler(deferred, REJECTED), - makeDeferredSignaler(deferred, PROGRESS)); - return; - } - signalDeferred(deferred, RESOLVED, newResult); - } - }catch(error){ - signalDeferred(deferred, REJECTED, error); - } - }else{ - signalDeferred(deferred, type, result); - } - - if( 1 ){ - if(type === REJECTED && Deferred.instrumentRejected){ - Deferred.instrumentRejected(result, !!func, rejection, deferred.promise); - } - } - }; - - var makeDeferredSignaler = function(deferred, type){ - return function(value){ - signalDeferred(deferred, type, value); - }; - }; - - var signalDeferred = function(deferred, type, result){ - if(!deferred.isCanceled()){ - switch(type){ - case PROGRESS: - deferred.progress(result); - break; - case RESOLVED: - deferred.resolve(result); - break; - case REJECTED: - deferred.reject(result); - break; - } - } - }; - - var Deferred = function(canceler){ - // summary: - // Creates a new deferred. This API is preferred over - // `dojo/_base/Deferred`. - // description: - // Creates a new deferred, as an abstraction over (primarily) - // asynchronous operations. The deferred is the private interface - // that should not be returned to calling code. That's what the - // `promise` is for. See `dojo/promise/Promise`. - // canceler: Function? - // Will be invoked if the deferred is canceled. The canceler - // receives the reason the deferred was canceled as its argument. - // The deferred is rejected with its return value, or a new - // `dojo/errors/CancelError` instance. - - // promise: dojo/promise/Promise - // The public promise object that clients can add callbacks to. - var promise = this.promise = new Promise(); - - var deferred = this; - var fulfilled, result, rejection; - var canceled = false; - var waiting = []; - - if( 1 && Error.captureStackTrace){ - Error.captureStackTrace(deferred, Deferred); - Error.captureStackTrace(promise, Deferred); - } - - this.isResolved = promise.isResolved = function(){ - // summary: - // Checks whether the deferred has been resolved. - // returns: Boolean - - return fulfilled === RESOLVED; - }; - - this.isRejected = promise.isRejected = function(){ - // summary: - // Checks whether the deferred has been rejected. - // returns: Boolean - - return fulfilled === REJECTED; - }; - - this.isFulfilled = promise.isFulfilled = function(){ - // summary: - // Checks whether the deferred has been resolved or rejected. - // returns: Boolean - - return !!fulfilled; - }; - - this.isCanceled = promise.isCanceled = function(){ - // summary: - // Checks whether the deferred has been canceled. - // returns: Boolean - - return canceled; - }; - - this.progress = function(update, strict){ - // summary: - // Emit a progress update on the deferred. - // description: - // Emit a progress update on the deferred. Progress updates - // can be used to communicate updates about the asynchronous - // operation before it has finished. - // update: any - // The progress update. Passed to progbacks. - // strict: Boolean? - // If strict, will throw an error if the deferred has already - // been fulfilled and consequently no progress can be emitted. - // returns: dojo/promise/Promise - // Returns the original promise for the deferred. - - if(!fulfilled){ - signalWaiting(waiting, PROGRESS, update, null, deferred); - return promise; - }else if(strict === true){ - throw new Error(FULFILLED_ERROR_MESSAGE); - }else{ - return promise; - } - }; - - this.resolve = function(value, strict){ - // summary: - // Resolve the deferred. - // description: - // Resolve the deferred, putting it in a success state. - // value: any - // The result of the deferred. Passed to callbacks. - // strict: Boolean? - // If strict, will throw an error if the deferred has already - // been fulfilled and consequently cannot be resolved. - // returns: dojo/promise/Promise - // Returns the original promise for the deferred. - - if(!fulfilled){ - // Set fulfilled, store value. After signaling waiting listeners unset - // waiting. - signalWaiting(waiting, fulfilled = RESOLVED, result = value, null, deferred); - waiting = null; - return promise; - }else if(strict === true){ - throw new Error(FULFILLED_ERROR_MESSAGE); - }else{ - return promise; - } - }; - - var reject = this.reject = function(error, strict){ - // summary: - // Reject the deferred. - // description: - // Reject the deferred, putting it in an error state. - // error: any - // The error result of the deferred. Passed to errbacks. - // strict: Boolean? - // If strict, will throw an error if the deferred has already - // been fulfilled and consequently cannot be rejected. - // returns: dojo/promise/Promise - // Returns the original promise for the deferred. - - if(!fulfilled){ - if( 1 && Error.captureStackTrace){ - Error.captureStackTrace(rejection = {}, reject); - } - signalWaiting(waiting, fulfilled = REJECTED, result = error, rejection, deferred); - waiting = null; - return promise; - }else if(strict === true){ - throw new Error(FULFILLED_ERROR_MESSAGE); - }else{ - return promise; - } - }; - - this.then = promise.then = function(callback, errback, progback){ - // summary: - // Add new callbacks to the deferred. - // description: - // Add new callbacks to the deferred. Callbacks can be added - // before or after the deferred is fulfilled. - // callback: Function? - // Callback to be invoked when the promise is resolved. - // Receives the resolution value. - // errback: Function? - // Callback to be invoked when the promise is rejected. - // Receives the rejection error. - // progback: Function? - // Callback to be invoked when the promise emits a progress - // update. Receives the progress update. - // returns: dojo/promise/Promise - // Returns a new promise for the result of the callback(s). - // This can be used for chaining many asynchronous operations. - - var listener = [progback, callback, errback]; - // Ensure we cancel the promise we're waiting for, or if callback/errback - // have returned a promise, cancel that one. - listener.cancel = promise.cancel; - listener.deferred = new Deferred(function(reason){ - // Check whether cancel is really available, returned promises are not - // required to expose `cancel` - return listener.cancel && listener.cancel(reason); - }); - if(fulfilled && !waiting){ - signalListener(listener, fulfilled, result, rejection); - }else{ - waiting.push(listener); - } - return listener.deferred.promise; - }; - - this.cancel = promise.cancel = function(reason, strict){ - // summary: - // Inform the deferred it may cancel its asynchronous operation. - // description: - // Inform the deferred it may cancel its asynchronous operation. - // The deferred's (optional) canceler is invoked and the - // deferred will be left in a rejected state. Can affect other - // promises that originate with the same deferred. - // reason: any - // A message that may be sent to the deferred's canceler, - // explaining why it's being canceled. - // strict: Boolean? - // If strict, will throw an error if the deferred has already - // been fulfilled and consequently cannot be canceled. - // returns: any - // Returns the rejection reason if the deferred was canceled - // normally. - - if(!fulfilled){ - // Cancel can be called even after the deferred is fulfilled - if(canceler){ - var returnedReason = canceler(reason); - reason = typeof returnedReason === "undefined" ? reason : returnedReason; - } - canceled = true; - if(!fulfilled){ - // Allow canceler to provide its own reason, but fall back to a CancelError - if(typeof reason === "undefined"){ - reason = new CancelError(); - } - reject(reason); - return reason; - }else if(fulfilled === REJECTED && result === reason){ - return reason; - } - }else if(strict === true){ - throw new Error(FULFILLED_ERROR_MESSAGE); - } - }; - - freezeObject(promise); - }; - - Deferred.prototype.toString = function(){ - // returns: String - // Returns `[object Deferred]`. - - return "[object Deferred]"; - }; - - if(instrumentation){ - instrumentation(Deferred); - } - - return Deferred; -}); diff --git a/lib/dojo/DeferredList.js b/lib/dojo/DeferredList.js deleted file mode 100644 index bd06d5f..0000000 --- a/lib/dojo/DeferredList.js +++ /dev/null @@ -1,57 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/DeferredList",["./_base/kernel","./_base/Deferred","./_base/array"],function(_1,_2,_3){ -_1.DeferredList=function(_4,_5,_6,_7,_8){ -var _9=[]; -_2.call(this); -var _a=this; -if(_4.length===0&&!_5){ -this.resolve([0,[]]); -} -var _b=0; -_3.forEach(_4,function(_c,i){ -_c.then(function(_d){ -if(_5){ -_a.resolve([i,_d]); -}else{ -_e(true,_d); -} -},function(_f){ -if(_6){ -_a.reject(_f); -}else{ -_e(false,_f); -} -if(_7){ -return null; -} -throw _f; -}); -function _e(_10,_11){ -_9[i]=[_10,_11]; -_b++; -if(_b===_4.length){ -_a.resolve(_9); -} -}; -}); -}; -_1.DeferredList.prototype=new _2(); -_1.DeferredList.prototype.gatherResults=function(_12){ -var d=new _1.DeferredList(_12,false,true,false); -d.addCallback(function(_13){ -var ret=[]; -_3.forEach(_13,function(_14){ -ret.push(_14[1]); -}); -return ret; -}); -return d; -}; -return _1.DeferredList; -}); diff --git a/lib/dojo/DeferredList.js.uncompressed.js b/lib/dojo/DeferredList.js.uncompressed.js deleted file mode 100644 index 26c36a9..0000000 --- a/lib/dojo/DeferredList.js.uncompressed.js +++ /dev/null @@ -1,84 +0,0 @@ -define("dojo/DeferredList", ["./_base/kernel", "./_base/Deferred", "./_base/array"], function(dojo, Deferred, darray){ - // module: - // dojo/DeferredList - - -dojo.DeferredList = function(/*Array*/ list, /*Boolean?*/ fireOnOneCallback, /*Boolean?*/ fireOnOneErrback, /*Boolean?*/ consumeErrors, /*Function?*/ canceller){ - // summary: - // Deprecated, use dojo/promise/all instead. - // Provides event handling for a group of Deferred objects. - // description: - // DeferredList takes an array of existing deferreds and returns a new deferred of its own - // this new deferred will typically have its callback fired when all of the deferreds in - // the given list have fired their own deferreds. The parameters `fireOnOneCallback` and - // fireOnOneErrback, will fire before all the deferreds as appropriate - // list: - // The list of deferreds to be synchronizied with this DeferredList - // fireOnOneCallback: - // Will cause the DeferredLists callback to be fired as soon as any - // of the deferreds in its list have been fired instead of waiting until - // the entire list has finished - // fireonOneErrback: - // Will cause the errback to fire upon any of the deferreds errback - // canceller: - // A deferred canceller function, see dojo.Deferred - var resultList = []; - Deferred.call(this); - var self = this; - if(list.length === 0 && !fireOnOneCallback){ - this.resolve([0, []]); - } - var finished = 0; - darray.forEach(list, function(item, i){ - item.then(function(result){ - if(fireOnOneCallback){ - self.resolve([i, result]); - }else{ - addResult(true, result); - } - },function(error){ - if(fireOnOneErrback){ - self.reject(error); - }else{ - addResult(false, error); - } - if(consumeErrors){ - return null; - } - throw error; - }); - function addResult(succeeded, result){ - resultList[i] = [succeeded, result]; - finished++; - if(finished === list.length){ - self.resolve(resultList); - } - - } - }); -}; -dojo.DeferredList.prototype = new Deferred(); - -dojo.DeferredList.prototype.gatherResults = function(deferredList){ - // summary: - // Gathers the results of the deferreds for packaging - // as the parameters to the Deferred Lists' callback - // deferredList: dojo/DeferredList - // The deferred list from which this function gathers results. - // returns: dojo/DeferredList - // The newly created deferred list which packs results as - // parameters to its callback. - - var d = new dojo.DeferredList(deferredList, false, true, false); - d.addCallback(function(results){ - var ret = []; - darray.forEach(results, function(result){ - ret.push(result[1]); - }); - return ret; - }); - return d; -}; - -return dojo.DeferredList; -}); diff --git a/lib/dojo/Evented.js b/lib/dojo/Evented.js deleted file mode 100644 index 96704ef..0000000 --- a/lib/dojo/Evented.js +++ /dev/null @@ -1,23 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/Evented",["./aspect","./on"],function(_1,on){ -"use strict"; -var _2=_1.after; -function _3(){ -}; -_3.prototype={on:function(_4,_5){ -return on.parse(this,_4,_5,function(_6,_7){ -return _2(_6,"on"+_7,_5,true); -}); -},emit:function(_8,_9){ -var _a=[this]; -_a.push.apply(_a,arguments); -return on.emit.apply(on,_a); -}}; -return _3; -}); diff --git a/lib/dojo/Evented.js.uncompressed.js b/lib/dojo/Evented.js.uncompressed.js deleted file mode 100644 index 515c2a1..0000000 --- a/lib/dojo/Evented.js.uncompressed.js +++ /dev/null @@ -1,36 +0,0 @@ -define("dojo/Evented", ["./aspect", "./on"], function(aspect, on){ - // module: - // dojo/Evented - - "use strict"; - var after = aspect.after; - function Evented(){ - // summary: - // A class that can be used as a mixin or base class, - // to add on() and emit() methods to a class - // for listening for events and emitting events: - // example: - // | define(["dojo/Evented", "dojo/_base/declare", "dojo/Stateful" - // | ], function(Evented, declare, Stateful){ - // | var EventedStateful = declare([Evented, Stateful], {...}); - // | var instance = new EventedStateful(); - // | instance.on("open", function(event){ - // | ... do something with event - // | }); - // | - // | instance.emit("open", {name:"some event", ...}); - } - Evented.prototype = { - on: function(type, listener){ - return on.parse(this, type, listener, function(target, type){ - return after(target, 'on' + type, listener, true); - }); - }, - emit: function(type, event){ - var args = [this]; - args.push.apply(args, arguments); - return on.emit.apply(on, args); - } - }; - return Evented; -}); diff --git a/lib/dojo/LICENSE b/lib/dojo/LICENSE deleted file mode 100644 index 2640cee..0000000 --- a/lib/dojo/LICENSE +++ /dev/null @@ -1,195 +0,0 @@ -Dojo is available under *either* the terms of the modified BSD license *or* the -Academic Free License version 2.1. As a recipient of Dojo, you may choose which -license to receive this code under (except as noted in per-module LICENSE -files). Some modules may not be the copyright of the Dojo Foundation. These -modules contain explicit declarations of copyright in both the LICENSE files in -the directories in which they reside and in the code itself. No external -contributions are allowed under licenses which are fundamentally incompatible -with the AFL or BSD licenses that Dojo is distributed under. - -The text of the AFL and BSD licenses is reproduced below. - -------------------------------------------------------------------------------- -The "New" BSD License: -********************** - -Copyright (c) 2005-2014, The Dojo Foundation -All rights reserved. - -Redistribution and use in source and binary forms, with or without -modification, are permitted provided that the following conditions are met: - - * Redistributions of source code must retain the above copyright notice, this - list of conditions and the following disclaimer. - * Redistributions in binary form must reproduce the above copyright notice, - this list of conditions and the following disclaimer in the documentation - and/or other materials provided with the distribution. - * Neither the name of the Dojo Foundation nor the names of its contributors - may be used to endorse or promote products derived from this software - without specific prior written permission. - -THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND -ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED -WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE -FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL -DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER -CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, -OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -------------------------------------------------------------------------------- -The Academic Free License, v. 2.1: -********************************** - -This Academic Free License (the "License") applies to any original work of -authorship (the "Original Work") whose owner (the "Licensor") has placed the -following notice immediately following the copyright notice for the Original -Work: - -Licensed under the Academic Free License version 2.1 - -1) Grant of Copyright License. Licensor hereby grants You a world-wide, -royalty-free, non-exclusive, perpetual, sublicenseable license to do the -following: - -a) to reproduce the Original Work in copies; - -b) to prepare derivative works ("Derivative Works") based upon the Original -Work; - -c) to distribute copies of the Original Work and Derivative Works to the -public; - -d) to perform the Original Work publicly; and - -e) to display the Original Work publicly. - -2) Grant of Patent License. Licensor hereby grants You a world-wide, -royalty-free, non-exclusive, perpetual, sublicenseable license, under patent -claims owned or controlled by the Licensor that are embodied in the Original -Work as furnished by the Licensor, to make, use, sell and offer for sale the -Original Work and Derivative Works. - -3) Grant of Source Code License. The term "Source Code" means the preferred -form of the Original Work for making modifications to it and all available -documentation describing how to modify the Original Work. Licensor hereby -agrees to provide a machine-readable copy of the Source Code of the Original -Work along with each copy of the Original Work that Licensor distributes. -Licensor reserves the right to satisfy this obligation by placing a -machine-readable copy of the Source Code in an information repository -reasonably calculated to permit inexpensive and convenient access by You for as -long as Licensor continues to distribute the Original Work, and by publishing -the address of that information repository in a notice immediately following -the copyright notice that applies to the Original Work. - -4) Exclusions From License Grant. Neither the names of Licensor, nor the names -of any contributors to the Original Work, nor any of their trademarks or -service marks, may be used to endorse or promote products derived from this -Original Work without express prior written permission of the Licensor. Nothing -in this License shall be deemed to grant any rights to trademarks, copyrights, -patents, trade secrets or any other intellectual property of Licensor except as -expressly stated herein. No patent license is granted to make, use, sell or -offer to sell embodiments of any patent claims other than the licensed claims -defined in Section 2. No right is granted to the trademarks of Licensor even if -such marks are included in the Original Work. Nothing in this License shall be -interpreted to prohibit Licensor from licensing under different terms from this -License any Original Work that Licensor otherwise would have a right to -license. - -5) This section intentionally omitted. - -6) Attribution Rights. You must retain, in the Source Code of any Derivative -Works that You create, all copyright, patent or trademark notices from the -Source Code of the Original Work, as well as any notices of licensing and any -descriptive text identified therein as an "Attribution Notice." You must cause -the Source Code for any Derivative Works that You create to carry a prominent -Attribution Notice reasonably calculated to inform recipients that You have -modified the Original Work. - -7) Warranty of Provenance and Disclaimer of Warranty. Licensor warrants that -the copyright in and to the Original Work and the patent rights granted herein -by Licensor are owned by the Licensor or are sublicensed to You under the terms -of this License with the permission of the contributor(s) of those copyrights -and patent rights. Except as expressly stated in the immediately proceeding -sentence, the Original Work is provided under this License on an "AS IS" BASIS -and WITHOUT WARRANTY, either express or implied, including, without limitation, -the warranties of NON-INFRINGEMENT, MERCHANTABILITY or FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY OF THE ORIGINAL WORK IS WITH YOU. -This DISCLAIMER OF WARRANTY constitutes an essential part of this License. No -license to Original Work is granted hereunder except under this disclaimer. - -8) Limitation of Liability. Under no circumstances and under no legal theory, -whether in tort (including negligence), contract, or otherwise, shall the -Licensor be liable to any person for any direct, indirect, special, incidental, -or consequential damages of any character arising as a result of this License -or the use of the Original Work including, without limitation, damages for loss -of goodwill, work stoppage, computer failure or malfunction, or any and all -other commercial damages or losses. This limitation of liability shall not -apply to liability for death or personal injury resulting from Licensor's -negligence to the extent applicable law prohibits such limitation. Some -jurisdictions do not allow the exclusion or limitation of incidental or -consequential damages, so this exclusion and limitation may not apply to You. - -9) Acceptance and Termination. If You distribute copies of the Original Work or -a Derivative Work, You must make a reasonable effort under the circumstances to -obtain the express assent of recipients to the terms of this License. Nothing -else but this License (or another written agreement between Licensor and You) -grants You permission to create Derivative Works based upon the Original Work -or to exercise any of the rights granted in Section 1 herein, and any attempt -to do so except under the terms of this License (or another written agreement -between Licensor and You) is expressly prohibited by U.S. copyright law, the -equivalent laws of other countries, and by international treaty. Therefore, by -exercising any of the rights granted to You in Section 1 herein, You indicate -Your acceptance of this License and all of its terms and conditions. - -10) Termination for Patent Action. This License shall terminate automatically -and You may no longer exercise any of the rights granted to You by this License -as of the date You commence an action, including a cross-claim or counterclaim, -against Licensor or any licensee alleging that the Original Work infringes a -patent. This termination provision shall not apply for an action alleging -patent infringement by combinations of the Original Work with other software or -hardware. - -11) Jurisdiction, Venue and Governing Law. Any action or suit relating to this -License may be brought only in the courts of a jurisdiction wherein the -Licensor resides or in which Licensor conducts its primary business, and under -the laws of that jurisdiction excluding its conflict-of-law provisions. The -application of the United Nations Convention on Contracts for the International -Sale of Goods is expressly excluded. Any use of the Original Work outside the -scope of this License or after its termination shall be subject to the -requirements and penalties of the U.S. Copyright Act, 17 U.S.C. § 101 et -seq., the equivalent laws of other countries, and international treaty. This -section shall survive the termination of this License. - -12) Attorneys Fees. In any action to enforce the terms of this License or -seeking damages relating thereto, the prevailing party shall be entitled to -recover its costs and expenses, including, without limitation, reasonable -attorneys' fees and costs incurred in connection with such action, including -any appeal of such action. This section shall survive the termination of this -License. - -13) Miscellaneous. This License represents the complete agreement concerning -the subject matter hereof. If any provision of this License is held to be -unenforceable, such provision shall be reformed only to the extent necessary to -make it enforceable. - -14) Definition of "You" in This License. "You" throughout this License, whether -in upper or lower case, means an individual or a legal entity exercising rights -under, and complying with all of the terms of, this License. For legal -entities, "You" includes any entity that controls, is controlled by, or is -under common control with you. For purposes of this definition, "control" means -(i) the power, direct or indirect, to cause the direction or management of such -entity, whether by contract or otherwise, or (ii) ownership of fifty percent -(50%) or more of the outstanding shares, or (iii) beneficial ownership of such -entity. - -15) Right to Use. You may use the Original Work in all ways not otherwise -restricted or conditioned by this License or by law, and Licensor promises not -to interfere with or be responsible for such uses by You. - -This license is Copyright (C) 2003-2004 Lawrence E. Rosen. All rights reserved. -Permission is hereby granted to copy and distribute this license without -modification. This license may not be modified without the express written -permission of its copyright owner. diff --git a/lib/dojo/NodeList-data.js b/lib/dojo/NodeList-data.js deleted file mode 100644 index 000bb9a..0000000 --- a/lib/dojo/NodeList-data.js +++ /dev/null @@ -1,59 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/NodeList-data",["./_base/kernel","./query","./_base/lang","./_base/array","./dom-attr"],function(_1,_2,_3,_4,_5){ -var _6=_2.NodeList; -var _7={},x=0,_8="data-dojo-dataid",_9=function(_a){ -var _b=_5.get(_a,_8); -if(!_b){ -_b="pid"+(x++); -_5.set(_a,_8,_b); -} -return _b; -}; -var _c=_1._nodeData=function(_d,_e,_f){ -var pid=_9(_d),r; -if(!_7[pid]){ -_7[pid]={}; -} -if(arguments.length==1){ -return _7[pid]; -} -if(typeof _e=="string"){ -if(arguments.length>2){ -_7[pid][_e]=_f; -}else{ -r=_7[pid][_e]; -} -}else{ -r=_3.mixin(_7[pid],_e); -} -return r; -}; -var _10=_1._removeNodeData=function(_11,key){ -var pid=_9(_11); -if(_7[pid]){ -if(key){ -delete _7[pid][key]; -}else{ -delete _7[pid]; -} -} -}; -_6._gcNodeData=_1._gcNodeData=function(){ -var _12=_2("["+_8+"]").map(_9); -for(var i in _7){ -if(_4.indexOf(_12,i)<0){ -delete _7[i]; -} -} -}; -_3.extend(_6,{data:_6._adaptWithCondition(_c,function(a){ -return a.length===0||a.length==1&&(typeof a[0]=="string"); -}),removeData:_6._adaptAsForEach(_10)}); -return _6; -}); diff --git a/lib/dojo/NodeList-data.js.uncompressed.js b/lib/dojo/NodeList-data.js.uncompressed.js deleted file mode 100644 index ab5981e..0000000 --- a/lib/dojo/NodeList-data.js.uncompressed.js +++ /dev/null @@ -1,198 +0,0 @@ -define("dojo/NodeList-data", [ - "./_base/kernel", "./query", "./_base/lang", "./_base/array", "./dom-attr" -], function(dojo, query, lang, array, attr){ - - // module: - // dojo/NodeList-data - - /*===== - return function(){ - // summary: - // Adds data() and removeData() methods to NodeList, and returns NodeList constructor. - }; - =====*/ - - var NodeList = query.NodeList; - - var dataCache = {}, x = 0, dataattr = "data-dojo-dataid", - dopid = function(node){ - // summary: - // Return a uniqueish ID for the passed node reference - var pid = attr.get(node, dataattr); - if(!pid){ - pid = "pid" + (x++); - attr.set(node, dataattr, pid); - } - return pid; - } - ; - - - var dodata = dojo._nodeData = function(node, key, value){ - // summary: - // Private helper for dojo/NodeList.data for single node data access. Refer to NodeList.data - // documentation for more information. - // - // node: String|DomNode - // The node to associate data with - // - // key: Object|String? - // If an object, act as a setter and iterate over said object setting data items as defined. - // If a string, and `value` present, set the data for defined `key` to `value` - // If a string, and `value` absent, act as a getter, returning the data associated with said `key` - // - // value: Anything? - // The value to set for said `key`, provided `key` is a string (and not an object) - // - var pid = dopid(node), r; - if(!dataCache[pid]){ dataCache[pid] = {}; } - - // API discrepency: calling with only a node returns the whole object. $.data throws - if(arguments.length == 1){ return dataCache[pid]; } - if(typeof key == "string"){ - // either getter or setter, based on `value` presence - if(arguments.length > 2){ - dataCache[pid][key] = value; - }else{ - r = dataCache[pid][key]; - } - }else{ - // must be a setter, mix `value` into data hash - // API discrepency: using object as setter works here - r = lang.mixin(dataCache[pid], key); - } - - return r; // Object|Anything|Nothing - }; - - var removeData = dojo._removeNodeData = function(node, key){ - // summary: - // Remove some data from this node - // node: String|DomNode - // The node reference to remove data from - // key: String? - // If omitted, remove all data in this dataset. - // If passed, remove only the passed `key` in the associated dataset - var pid = dopid(node); - if(dataCache[pid]){ - if(key){ - delete dataCache[pid][key]; - }else{ - delete dataCache[pid]; - } - } - }; - - NodeList._gcNodeData = dojo._gcNodeData = function(){ - // summary: - // super expensive: GC all data in the data for nodes that no longer exist in the dom. - // description: - // super expensive: GC all data in the data for nodes that no longer exist in the dom. - // MUCH safer to do this yourself, manually, on a per-node basis (via `NodeList.removeData()`) - // provided as a stop-gap for exceptionally large/complex applications with constantly changing - // content regions (eg: a dijit/layout/ContentPane with replacing data) - // There is NO automatic GC going on. If you dojo.destroy() a node, you should _removeNodeData - // prior to destruction. - var livePids = query("[" + dataattr + "]").map(dopid); - for(var i in dataCache){ - if(array.indexOf(livePids, i) < 0){ delete dataCache[i]; } - } - }; - - // make nodeData and removeNodeData public on dojo/NodeList: - lang.extend(NodeList, { - data: NodeList._adaptWithCondition(dodata, function(a){ - return a.length === 0 || a.length == 1 && (typeof a[0] == "string"); - }), - removeData: NodeList._adaptAsForEach(removeData) - }); - - /*===== - lang.extend(NodeList, { - data: function(key, value){ - // summary: - // stash or get some arbitrary data on/from these nodes. - // - // description: - // Stash or get some arbitrary data on/from these nodes. This private _data function is - // exposed publicly on `dojo/NodeList`, eg: as the result of a `dojo/query` call. - // DIFFERS from jQuery.data in that when used as a getter, the entire list is ALWAYS - // returned. EVEN WHEN THE LIST IS length == 1. - // - // A single-node version of this function is provided as `dojo._nodeData`, which follows - // the same signature, though expects a String ID or DomNode reference in the first - // position, before key/value arguments. - // - // node: String|DomNode - // The node to associate data with - // - // key: Object|String? - // If an object, act as a setter and iterate over said object setting data items as defined. - // If a string, and `value` present, set the data for defined `key` to `value` - // If a string, and `value` absent, act as a getter, returning the data associated with said `key` - // - // value: Anything? - // The value to set for said `key`, provided `key` is a string (and not an object) - // - // example: - // Set a key `bar` to some data, then retrieve it. - // | require(["dojo/query", "dojo/NodeList-data"], function(query){ - // | query(".foo").data("bar", "touched"); - // | var touched = query(".foo").data("bar"); - // | if(touched[0] == "touched"){ alert('win'); } - // | }); - // - // example: - // Get all the data items for a given node. - // | require(["dojo/query", "dojo/NodeList-data"], function(query){ - // | var list = query(".foo").data(); - // | var first = list[0]; - // | }); - // - // example: - // Set the data to a complex hash. Overwrites existing keys with new value - // | require(["dojo/query", "dojo/NodeList-data"], function(query){ - // | query(".foo").data({ bar:"baz", foo:"bar" }); - // Then get some random key: - // | query(".foo").data("foo"); // returns [`bar`] - // | }); - // - // returns: Object|Anything|Nothing - // When used as a setter via `dojo/NodeList`, a NodeList instance is returned - // for further chaining. When used as a getter via `dojo/NodeList` an ARRAY - // of items is returned. The items in the array correspond to the elements - // in the original list. This is true even when the list length is 1, eg: - // when looking up a node by ID (#foo) - }, - - removeData: function(key){ - // summary: - // Remove the data associated with these nodes. - // key: String? - // If omitted, clean all data for this node. - // If passed, remove the data item found at `key` - } - }); - =====*/ - -// TODO: this is the basic implementation of adaptWithConditionAndWhenMappedConsiderLength, for lack of a better API name -// it conflicts with the the `dojo/NodeList` way: always always return an arrayLike thinger. Consider for 2.0: -// -// NodeList.prototype.data = function(key, value){ -// var a = arguments, r; -// if(a.length === 0 || a.length == 1 && (typeof a[0] == "string")){ -// r = this.map(function(node){ -// return d._data(node, key); -// }); -// if(r.length == 1){ r = r[0]; } // the offending line, and the diff on adaptWithCondition -// }else{ -// r = this.forEach(function(node){ -// d._data(node, key, value); -// }); -// } -// return r; // NodeList|Array|SingleItem -// }; - - return NodeList; - -}); diff --git a/lib/dojo/NodeList-dom.js b/lib/dojo/NodeList-dom.js deleted file mode 100644 index dc1afd0..0000000 --- a/lib/dojo/NodeList-dom.js +++ /dev/null @@ -1,126 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/NodeList-dom",["./_base/kernel","./query","./_base/array","./_base/lang","./dom-class","./dom-construct","./dom-geometry","./dom-attr","./dom-style"],function(_1,_2,_3,_4,_5,_6,_7,_8,_9){ -var _a=function(a){ -return a.length==1&&(typeof a[0]=="string"); -}; -var _b=function(_c){ -var p=_c.parentNode; -if(p){ -p.removeChild(_c); -} -}; -var _d=_2.NodeList,_e=_d._adaptWithCondition,_f=_d._adaptAsForEach,aam=_d._adaptAsMap; -function _10(_11){ -return function(_12,_13,_14){ -if(arguments.length==2){ -return _11[typeof _13=="string"?"get":"set"](_12,_13); -} -return _11.set(_12,_13,_14); -}; -}; -_4.extend(_d,{_normalize:function(_15,_16){ -var _17=_15.parse===true; -if(typeof _15.template=="string"){ -var _18=_15.templateFunc||(_1.string&&_1.string.substitute); -_15=_18?_18(_15.template,_15):_15; -} -var _19=(typeof _15); -if(_19=="string"||_19=="number"){ -_15=_6.toDom(_15,(_16&&_16.ownerDocument)); -if(_15.nodeType==11){ -_15=_4._toArray(_15.childNodes); -}else{ -_15=[_15]; -} -}else{ -if(!_4.isArrayLike(_15)){ -_15=[_15]; -}else{ -if(!_4.isArray(_15)){ -_15=_4._toArray(_15); -} -} -} -if(_17){ -_15._runParse=true; -} -return _15; -},_cloneNode:function(_1a){ -return _1a.cloneNode(true); -},_place:function(ary,_1b,_1c,_1d){ -if(_1b.nodeType!=1&&_1c=="only"){ -return; -} -var _1e=_1b,_1f; -var _20=ary.length; -for(var i=_20-1;i>=0;i--){ -var _21=(_1d?this._cloneNode(ary[i]):ary[i]); -if(ary._runParse&&_1.parser&&_1.parser.parse){ -if(!_1f){ -_1f=_1e.ownerDocument.createElement("div"); -} -_1f.appendChild(_21); -_1.parser.parse(_1f); -_21=_1f.firstChild; -while(_1f.firstChild){ -_1f.removeChild(_1f.firstChild); -} -} -if(i==_20-1){ -_6.place(_21,_1e,_1c); -}else{ -_1e.parentNode.insertBefore(_21,_1e); -} -_1e=_21; -} -},position:aam(_7.position),attr:_e(_10(_8),_a),style:_e(_10(_9),_a),addClass:_f(_5.add),removeClass:_f(_5.remove),toggleClass:_f(_5.toggle),replaceClass:_f(_5.replace),empty:_f(_6.empty),removeAttr:_f(_8.remove),marginBox:aam(_7.getMarginBox),place:function(_22,_23){ -var _24=_2(_22)[0]; -return this.forEach(function(_25){ -_6.place(_25,_24,_23); -}); -},orphan:function(_26){ -return (_26?_2._filterResult(this,_26):this).forEach(_b); -},adopt:function(_27,_28){ -return _2(_27).place(this[0],_28)._stash(this); -},query:function(_29){ -if(!_29){ -return this; -} -var ret=new _d; -this.map(function(_2a){ -_2(_29,_2a).forEach(function(_2b){ -if(_2b!==undefined){ -ret.push(_2b); -} -}); -}); -return ret._stash(this); -},filter:function(_2c){ -var a=arguments,_2d=this,_2e=0; -if(typeof _2c=="string"){ -_2d=_2._filterResult(this,a[0]); -if(a.length==1){ -return _2d._stash(this); -} -_2e=1; -} -return this._wrap(_3.filter(_2d,a[_2e],a[_2e+1]),this); -},addContent:function(_2f,_30){ -_2f=this._normalize(_2f,this[0]); -for(var i=0,_31;(_31=this[i]);i++){ -if(_2f.length){ -this._place(_2f,_31,_30,i>0); -}else{ -_6.empty(_31); -} -} -return this; -}}); -return _d; -}); diff --git a/lib/dojo/NodeList-dom.js.uncompressed.js b/lib/dojo/NodeList-dom.js.uncompressed.js deleted file mode 100644 index 20d24ef..0000000 --- a/lib/dojo/NodeList-dom.js.uncompressed.js +++ /dev/null @@ -1,543 +0,0 @@ -define("dojo/NodeList-dom", ["./_base/kernel", "./query", "./_base/array", "./_base/lang", "./dom-class", "./dom-construct", "./dom-geometry", "./dom-attr", "./dom-style"], function(dojo, query, array, lang, domCls, domCtr, domGeom, domAttr, domStyle){ - - // module: - // dojo/NodeList-dom.js - - /*===== - return function(){ - // summary: - // Adds DOM related methods to NodeList, and returns NodeList constructor. - }; - =====*/ - - var magicGuard = function(a){ - // summary: - // the guard function for dojo/dom-attr() and dojo/dom-style() - return a.length == 1 && (typeof a[0] == "string"); // inline'd type check - }; - - var orphan = function(node){ - // summary: - // function to orphan nodes - var p = node.parentNode; - if(p){ - p.removeChild(node); - } - }; - // FIXME: should we move orphan() to dojo/_base/html? - - var NodeList = query.NodeList, - awc = NodeList._adaptWithCondition, - aafe = NodeList._adaptAsForEach, - aam = NodeList._adaptAsMap; - - function getSet(module){ - return function(node, name, value){ - if(arguments.length == 2){ - return module[typeof name == "string" ? "get" : "set"](node, name); - } - // setter - return module.set(node, name, value); - }; - } - - lang.extend(NodeList, { - _normalize: function(/*String||Element||Object||NodeList*/content, /*DOMNode?*/refNode){ - // summary: - // normalizes data to an array of items to insert. - // description: - // If content is an object, it can have special properties "template" and - // "parse". If "template" is defined, then the template value is run through - // dojo/string.substitute (if dojo/string.substitute() has been required elsewhere), - // or if templateFunc is a function on the content, that function will be used to - // transform the template into a final string to be used for for passing to dojo/dom-construct.toDom(). - // If content.parse is true, then it is remembered for later, for when the content - // nodes are inserted into the DOM. At that point, the nodes will be parsed for widgets - // (if dojo/parser has been required elsewhere). - - //Wanted to just use a DocumentFragment, but for the array/NodeList - //case that meant using cloneNode, but we may not want that. - //Cloning should only happen if the node operations span - //multiple refNodes. Also, need a real array, not a NodeList from the - //DOM since the node movements could change those NodeLists. - - var parse = content.parse === true; - - //Do we have an object that needs to be run through a template? - if(typeof content.template == "string"){ - var templateFunc = content.templateFunc || (dojo.string && dojo.string.substitute); - content = templateFunc ? templateFunc(content.template, content) : content; - } - - var type = (typeof content); - if(type == "string" || type == "number"){ - content = domCtr.toDom(content, (refNode && refNode.ownerDocument)); - if(content.nodeType == 11){ - //DocumentFragment. It cannot handle cloneNode calls, so pull out the children. - content = lang._toArray(content.childNodes); - }else{ - content = [content]; - } - }else if(!lang.isArrayLike(content)){ - content = [content]; - }else if(!lang.isArray(content)){ - //To get to this point, content is array-like, but - //not an array, which likely means a DOM NodeList. Convert it now. - content = lang._toArray(content); - } - - //Pass around the parse info - if(parse){ - content._runParse = true; - } - return content; //Array - }, - - _cloneNode: function(/*DOMNode*/ node){ - // summary: - // private utility to clone a node. Not very interesting in the vanilla - // dojo/NodeList case, but delegates could do interesting things like - // clone event handlers if that is derivable from the node. - return node.cloneNode(true); - }, - - _place: function(/*Array*/ary, /*DOMNode*/refNode, /*String*/position, /*Boolean*/useClone){ - // summary: - // private utility to handle placing an array of nodes relative to another node. - // description: - // Allows for cloning the nodes in the array, and for - // optionally parsing widgets, if ary._runParse is true. - - //Avoid a disallowed operation if trying to do an innerHTML on a non-element node. - if(refNode.nodeType != 1 && position == "only"){ - return; - } - var rNode = refNode, tempNode; - - //Always cycle backwards in case the array is really a - //DOM NodeList and the DOM operations take it out of the live collection. - var length = ary.length; - for(var i = length - 1; i >= 0; i--){ - var node = (useClone ? this._cloneNode(ary[i]) : ary[i]); - - //If need widget parsing, use a temp node, instead of waiting after inserting into - //real DOM because we need to start widget parsing at one node up from current node, - //which could cause some already parsed widgets to be parsed again. - if(ary._runParse && dojo.parser && dojo.parser.parse){ - if(!tempNode){ - tempNode = rNode.ownerDocument.createElement("div"); - } - tempNode.appendChild(node); - dojo.parser.parse(tempNode); - node = tempNode.firstChild; - while(tempNode.firstChild){ - tempNode.removeChild(tempNode.firstChild); - } - } - - if(i == length - 1){ - domCtr.place(node, rNode, position); - }else{ - rNode.parentNode.insertBefore(node, rNode); - } - rNode = node; - } - }, - - - position: aam(domGeom.position), - /*===== - position: function(){ - // summary: - // Returns border-box objects (x/y/w/h) of all elements in a node list - // as an Array (*not* a NodeList). Acts like `dojo/dom-geometry-position`, though - // assumes the node passed is each node in this list. - - return dojo.map(this, dojo.position); // Array - }, - =====*/ - - attr: awc(getSet(domAttr), magicGuard), - /*===== - attr: function(property, value){ - // summary: - // gets or sets the DOM attribute for every element in the - // NodeList. See also `dojo/dom-attr` - // property: String - // the attribute to get/set - // value: String? - // optional. The value to set the property to - // returns: - // if no value is passed, the result is an array of attribute values - // If a value is passed, the return is this NodeList - // example: - // Make all nodes with a particular class focusable: - // | require(["dojo/query", "dojo/NodeList-dom"], function(query){ - // | query(".focusable").attr("tabIndex", -1); - // | }); - // example: - // Disable a group of buttons: - // | require(["dojo/query", "dojo/NodeList-dom"], function(query){ - // | query("button.group").attr("disabled", true); - // | }); - // example: - // innerHTML can be assigned or retrieved as well: - // | // get the innerHTML (as an array) for each list item - // | require(["dojo/query", "dojo/NodeList-dom"], function(query){ - // | var ih = query("li.replaceable").attr("innerHTML"); - // | }); - return; // dojo/NodeList|Array - }, - =====*/ - - style: awc(getSet(domStyle), magicGuard), - /*===== - style: function(property, value){ - // summary: - // gets or sets the CSS property for every element in the NodeList - // property: String - // the CSS property to get/set, in JavaScript notation - // ("lineHieght" instead of "line-height") - // value: String? - // optional. The value to set the property to - // returns: - // if no value is passed, the result is an array of strings. - // If a value is passed, the return is this NodeList - return; // dojo/NodeList - return; // Array - }, - =====*/ - - addClass: aafe(domCls.add), - /*===== - addClass: function(className){ - // summary: - // adds the specified class to every node in the list - // className: String|Array - // A String class name to add, or several space-separated class names, - // or an array of class names. - return; // dojo/NodeList - }, - =====*/ - - removeClass: aafe(domCls.remove), - /*===== - removeClass: function(className){ - // summary: - // removes the specified class from every node in the list - // className: String|Array? - // An optional String class name to remove, or several space-separated - // class names, or an array of class names. If omitted, all class names - // will be deleted. - // returns: - // this list - return; // dojo/NodeList - }, - =====*/ - - toggleClass: aafe(domCls.toggle), - /*===== - toggleClass: function(className, condition){ - // summary: - // Adds a class to node if not present, or removes if present. - // Pass a boolean condition if you want to explicitly add or remove. - // condition: Boolean? - // If passed, true means to add the class, false means to remove. - // className: String - // the CSS class to add - return; // dojo/NodeList - }, - =====*/ - - replaceClass: aafe(domCls.replace), - /*===== - replaceClass: function(addClassStr, removeClassStr){ - // summary: - // Replaces one or more classes on a node if not present. - // Operates more quickly than calling `removeClass()` and `addClass()` - // addClassStr: String|Array - // A String class name to add, or several space-separated class names, - // or an array of class names. - // removeClassStr: String|Array? - // A String class name to remove, or several space-separated class names, - // or an array of class names. - return; // dojo/NodeList - }, - =====*/ - - empty: aafe(domCtr.empty), - /*===== - empty: function(){ - // summary: - // clears all content from each node in the list. Effectively - // equivalent to removing all child nodes from every item in - // the list. - return this.forEach("item.innerHTML='';"); // dojo/NodeList - // FIXME: should we be checking for and/or disposing of widgets below these nodes? - }, - =====*/ - - removeAttr: aafe(domAttr.remove), - /*===== - removeAttr: function(name){ - // summary: - // Removes an attribute from each node in the list. - // name: String - // the name of the attribute to remove - return; // dojo/NodeList - }, - =====*/ - - marginBox: aam(domGeom.getMarginBox), - /*===== - marginBox: function(){ - // summary: - // Returns margin-box size of nodes - return; // dojo/NodeList - }, - =====*/ - - // FIXME: connectPublisher()? connectRunOnce()? - - /* - destroy: function(){ - // summary: - // destroys every item in the list. - this.forEach(d.destroy); - // FIXME: should we be checking for and/or disposing of widgets below these nodes? - }, - */ - - place: function(/*String||Node*/ queryOrNode, /*String*/ position){ - // summary: - // places elements of this node list relative to the first element matched - // by queryOrNode. Returns the original NodeList. See: `dojo/dom-construct.place` - // queryOrNode: - // may be a string representing any valid CSS3 selector or a DOM node. - // In the selector case, only the first matching element will be used - // for relative positioning. - // position: - // can be one of: - // - // - "last" (default) - // - "first" - // - "before" - // - "after" - // - "only" - // - "replace" - // - // or an offset in the childNodes property - var item = query(queryOrNode)[0]; - return this.forEach(function(node){ domCtr.place(node, item, position); }); // dojo/NodeList - }, - - orphan: function(/*String?*/ filter){ - // summary: - // removes elements in this list that match the filter - // from their parents and returns them as a new NodeList. - // filter: - // CSS selector like ".foo" or "div > span" - // returns: - // NodeList containing the orphaned elements - return (filter ? query._filterResult(this, filter) : this).forEach(orphan); // dojo/NodeList - }, - - adopt: function(/*String||Array||DomNode*/ queryOrListOrNode, /*String?*/ position){ - // summary: - // places any/all elements in queryOrListOrNode at a - // position relative to the first element in this list. - // Returns a dojo/NodeList of the adopted elements. - // queryOrListOrNode: - // a DOM node or a query string or a query result. - // Represents the nodes to be adopted relative to the - // first element of this NodeList. - // position: - // can be one of: - // - // - "last" (default) - // - "first" - // - "before" - // - "after" - // - "only" - // - "replace" - // - // or an offset in the childNodes property - return query(queryOrListOrNode).place(this[0], position)._stash(this); // dojo/NodeList - }, - - // FIXME: do we need this? - query: function(/*String*/ queryStr){ - // summary: - // Returns a new list whose members match the passed query, - // assuming elements of the current NodeList as the root for - // each search. - // example: - // assume a DOM created by this markup: - // |
- // |

- // | bacon is tasty, dontcha think? - // |

- // |
- // |
- // |

great comedians may not be funny in person

- // |
- // If we are presented with the following definition for a NodeList: - // | require(["dojo/dom", "dojo/query", "dojo/NodeList-dom" - // | ], function(dom, query){ - // | var l = new NodeList(dom.byId("foo"), dom.byId("bar")); - // it's possible to find all span elements under paragraphs - // contained by these elements with this sub-query: - // | var spans = l.query("p span"); - // | }); - - // FIXME: probably slow - if(!queryStr){ return this; } - var ret = new NodeList; - this.map(function(node){ - // FIXME: why would we ever get undefined here? - query(queryStr, node).forEach(function(subNode){ - if(subNode !== undefined){ - ret.push(subNode); - } - }); - }); - return ret._stash(this); // dojo/NodeList - }, - - filter: function(/*String|Function*/ filter){ - // summary: - // "masks" the built-in javascript filter() method (supported - // in Dojo via `dojo.filter`) to support passing a simple - // string filter in addition to supporting filtering function - // objects. - // filter: - // If a string, a CSS rule like ".thinger" or "div > span". - // example: - // "regular" JS filter syntax as exposed in dojo.filter: - // | require(["dojo/query", "dojo/NodeList-dom" - // | ], function(query){ - // | query("*").filter(function(item){ - // | // highlight every paragraph - // | return (item.nodeName == "p"); - // | }).style("backgroundColor", "yellow"); - // | }); - // example: - // the same filtering using a CSS selector - // | require(["dojo/query", "dojo/NodeList-dom" - // | ], function(query){ - // | query("*").filter("p").styles("backgroundColor", "yellow"); - // | }); - var a = arguments, items = this, start = 0; - if(typeof filter == "string"){ // inline'd type check - items = query._filterResult(this, a[0]); - if(a.length == 1){ - // if we only got a string query, pass back the filtered results - return items._stash(this); // dojo/NodeList - } - // if we got a callback, run it over the filtered items - start = 1; - } - return this._wrap(array.filter(items, a[start], a[start + 1]), this); // dojo/NodeList - }, - - /* - // FIXME: should this be "copyTo" and include parenting info? - clone: function(){ - // summary: - // creates node clones of each element of this list - // and returns a new list containing the clones - }, - */ - - addContent: function(/*String||DomNode||Object||dojo/NodeList*/ content, /*String||Integer?*/ position){ - // summary: - // add a node, NodeList or some HTML as a string to every item in the - // list. Returns the original list. - // description: - // a copy of the HTML content is added to each item in the - // list, with an optional position argument. If no position - // argument is provided, the content is appended to the end of - // each item. - // content: - // DOM node, HTML in string format, a NodeList or an Object. If a DOM node or - // NodeList, the content will be cloned if the current NodeList has more than one - // element. Only the DOM nodes are cloned, no event handlers. If it is an Object, - // it should be an object with at "template" String property that has the HTML string - // to insert. If dojo.string has already been dojo.required, then dojo.string.substitute - // will be used on the "template" to generate the final HTML string. Other allowed - // properties on the object are: "parse" if the HTML - // string should be parsed for widgets (dojo.require("dojo.parser") to get that - // option to work), and "templateFunc" if a template function besides dojo.string.substitute - // should be used to transform the "template". - // position: - // can be one of: - // - // - "last"||"end" (default) - // - "first||"start" - // - "before" - // - "after" - // - "replace" (replaces nodes in this NodeList with new content) - // - "only" (removes other children of the nodes so new content is the only child) - // - // or an offset in the childNodes property - // example: - // appends content to the end if the position is omitted - // | require(["dojo/query", "dojo/NodeList-dom" - // | ], function(query){ - // | query("h3 > p").addContent("hey there!"); - // | }); - // example: - // add something to the front of each element that has a - // "thinger" property: - // | require(["dojo/query", "dojo/NodeList-dom" - // | ], function(query){ - // | query("[thinger]").addContent("...", "first"); - // | }); - // example: - // adds a header before each element of the list - // | require(["dojo/query", "dojo/NodeList-dom" - // | ], function(query){ - // | query(".note").addContent("

NOTE:

", "before"); - // | }); - // example: - // add a clone of a DOM node to the end of every element in - // the list, removing it from its existing parent. - // | require(["dojo/dom", "dojo/query", "dojo/NodeList-dom" - // | ], function(dom, query){ - // | query(".note").addContent(dom.byId("foo")); - // | }); - // example: - // Append nodes from a templatized string. - // | require(["dojo/string", "dojo/query", "dojo/NodeList-dom" - // | ], function(string, query){ - // | query(".note").addContent({ - // | template: '${id}: ${name}', - // | id: "user332", - // | name: "Mr. Anderson" - // | }); - // | }); - // example: - // Append nodes from a templatized string that also has widgets parsed. - // | require(["dojo/string", "dojo/parser", "dojo/query", "dojo/NodeList-dom" - // | ], function(string, parser, query){ - // | var notes = query(".note").addContent({ - // | template: '', - // | parse: true, - // | text: "Send" - // | }); - // | }); - content = this._normalize(content, this[0]); - for(var i = 0, node; (node = this[i]); i++){ - if(content.length){ - this._place(content, node, position, i > 0); - }else{ - // if it is an empty array, we empty the target node - domCtr.empty(node); - } - } - return this; // dojo/NodeList - } - }); - - return NodeList; -}); diff --git a/lib/dojo/NodeList-fx.js b/lib/dojo/NodeList-fx.js deleted file mode 100644 index e062c72..0000000 --- a/lib/dojo/NodeList-fx.js +++ /dev/null @@ -1,40 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/NodeList-fx",["./query","./_base/lang","./aspect","./_base/fx","./fx"],function(_1,_2,_3,_4,_5){ -var _6=_1.NodeList; -_2.extend(_6,{_anim:function(_7,_8,_9){ -_9=_9||{}; -var a=_5.combine(this.map(function(_a){ -var _b={node:_a}; -_2.mixin(_b,_9); -return _7[_8](_b); -})); -return _9.auto?a.play()&&this:a; -},wipeIn:function(_c){ -return this._anim(_5,"wipeIn",_c); -},wipeOut:function(_d){ -return this._anim(_5,"wipeOut",_d); -},slideTo:function(_e){ -return this._anim(_5,"slideTo",_e); -},fadeIn:function(_f){ -return this._anim(_4,"fadeIn",_f); -},fadeOut:function(_10){ -return this._anim(_4,"fadeOut",_10); -},animateProperty:function(_11){ -return this._anim(_4,"animateProperty",_11); -},anim:function(_12,_13,_14,_15,_16){ -var _17=_5.combine(this.map(function(_18){ -return _4.animateProperty({node:_18,properties:_12,duration:_13||350,easing:_14}); -})); -if(_15){ -_3.after(_17,"onEnd",_15,true); -} -return _17.play(_16||0); -}}); -return _6; -}); diff --git a/lib/dojo/NodeList-fx.js.uncompressed.js b/lib/dojo/NodeList-fx.js.uncompressed.js deleted file mode 100644 index 83dfebd..0000000 --- a/lib/dojo/NodeList-fx.js.uncompressed.js +++ /dev/null @@ -1,257 +0,0 @@ -define("dojo/NodeList-fx", ["./query", "./_base/lang", "./aspect", "./_base/fx", "./fx"], -function(query, lang, aspect, baseFx, coreFx){ - -// module: -// dojo/NodeList-fx - -/*===== -return function(){ - // summary: - // Adds dojo.fx animation support to dojo.query() by extending the NodeList class - // with additional FX functions. NodeList is the array-like object used to hold query results. -}; -=====*/ - -var NodeList = query.NodeList; - -lang.extend(NodeList, { - _anim: function(obj, method, args){ - args = args||{}; - var a = coreFx.combine( - this.map(function(item){ - var tmpArgs = { node: item }; - lang.mixin(tmpArgs, args); - return obj[method](tmpArgs); - }) - ); - return args.auto ? a.play() && this : a; // dojo/_base/fx.Animation|dojo/NodeList - }, - - wipeIn: function(args){ - // summary: - // wipe in all elements of this NodeList via `dojo/fx.wipeIn()` - // - // args: Object? - // Additional dojo/_base/fx.Animation arguments to mix into this set with the addition of - // an `auto` parameter. - // - // returns: dojo/_base/fx.Animation|dojo/NodeList - // A special args member `auto` can be passed to automatically play the animation. - // If args.auto is present, the original dojo/NodeList will be returned for further - // chaining. Otherwise the dojo/_base/fx.Animation instance is returned and must be .play()'ed - // - // example: - // Fade in all tables with class "blah": - // | require(["dojo/query", "dojo/NodeList-fx" - // | ], function(query){ - // | query("table.blah").wipeIn().play(); - // | }); - // - // example: - // Utilizing `auto` to get the NodeList back: - // | require(["dojo/query", "dojo/NodeList-fx" - // | ], function(query){ - // | query(".titles").wipeIn({ auto:true }).onclick(someFunction); - // | }); - // - return this._anim(coreFx, "wipeIn", args); // dojo/_base/fx.Animation|dojo/NodeList - }, - - wipeOut: function(args){ - // summary: - // wipe out all elements of this NodeList via `dojo/fx.wipeOut()` - // - // args: Object? - // Additional dojo/_base/fx.Animation arguments to mix into this set with the addition of - // an `auto` parameter. - // - // returns: dojo/_base/fx.Animation|dojo/NodeList - // A special args member `auto` can be passed to automatically play the animation. - // If args.auto is present, the original dojo/NodeList will be returned for further - // chaining. Otherwise the dojo/_base/fx.Animation instance is returned and must be .play()'ed - // - // example: - // Wipe out all tables with class "blah": - // | require(["dojo/query", "dojo/NodeList-fx" - // | ], function(query){ - // | query("table.blah").wipeOut().play(); - // | }); - return this._anim(coreFx, "wipeOut", args); // dojo/_base/fx.Animation|dojo/NodeList - }, - - slideTo: function(args){ - // summary: - // slide all elements of the node list to the specified place via `dojo/fx.slideTo()` - // - // args: Object? - // Additional dojo/_base/fx.Animation arguments to mix into this set with the addition of - // an `auto` parameter. - // - // returns: dojo/_base/fx.Animation|dojo/NodeList - // A special args member `auto` can be passed to automatically play the animation. - // If args.auto is present, the original dojo/NodeList will be returned for further - // chaining. Otherwise the dojo/_base/fx.Animation instance is returned and must be .play()'ed - // - // example: - // | Move all tables with class "blah" to 300/300: - // | require(["dojo/query", "dojo/NodeList-fx" - // | ], function(query){ - // | query("table.blah").slideTo({ - // | left: 40, - // | top: 50 - // | }).play(); - // | }); - return this._anim(coreFx, "slideTo", args); // dojo/_base/fx.Animation|dojo/NodeList - }, - - - fadeIn: function(args){ - // summary: - // fade in all elements of this NodeList via `dojo.fadeIn` - // - // args: Object? - // Additional dojo/_base/fx.Animation arguments to mix into this set with the addition of - // an `auto` parameter. - // - // returns: dojo/_base/fx.Animation|dojo/NodeList - // A special args member `auto` can be passed to automatically play the animation. - // If args.auto is present, the original dojo/NodeList will be returned for further - // chaining. Otherwise the dojo/_base/fx.Animation instance is returned and must be .play()'ed - // - // example: - // Fade in all tables with class "blah": - // | require(["dojo/query", "dojo/NodeList-fx" - // | ], function(query){ - // | query("table.blah").fadeIn().play(); - // | }); - return this._anim(baseFx, "fadeIn", args); // dojo/_base/fx.Animation|dojo/NodeList - }, - - fadeOut: function(args){ - // summary: - // fade out all elements of this NodeList via `dojo.fadeOut` - // - // args: Object? - // Additional dojo/_base/fx.Animation arguments to mix into this set with the addition of - // an `auto` parameter. - // - // returns: dojo/_base/fx.Animation|dojo/NodeList - // A special args member `auto` can be passed to automatically play the animation. - // If args.auto is present, the original dojo/NodeList will be returned for further - // chaining. Otherwise the dojo/_base/fx.Animation instance is returned and must be .play()'ed - // - // example: - // Fade out all elements with class "zork": - // | require(["dojo/query", "dojo/NodeList-fx" - // | ], function(query){ - // | query(".zork").fadeOut().play(); - // | }); - // example: - // Fade them on a delay and do something at the end: - // | require(["dojo/query", "dojo/aspect", "dojo/NodeList-fx" - // | ], function(query, aspect){ - // | var fo = query(".zork").fadeOut(); - // | aspect.after(fo, "onEnd", function(){ /*...*/ }, true); - // | fo.play(); - // | }); - // example: - // Using `auto`: - // | require(["dojo/query", "dojo/NodeList-fx" - // | ], function(query){ - // | query("li").fadeOut({ auto:true }).filter(filterFn).forEach(doit); - // | }); - // - return this._anim(baseFx, "fadeOut", args); // dojo/_base/fx.Animation|dojo/NodeList - }, - - animateProperty: function(args){ - // summary: - // Animate all elements of this NodeList across the properties specified. - // syntax identical to `dojo.animateProperty` - // - // args: Object? - // Additional dojo/_base/fx.Animation arguments to mix into this set with the addition of - // an `auto` parameter. - // - // returns: dojo/_base/fx.Animation|dojo/NodeList - // A special args member `auto` can be passed to automatically play the animation. - // If args.auto is present, the original dojo/NodeList will be returned for further - // chaining. Otherwise the dojo/_base/fx.Animation instance is returned and must be .play()'ed - // - // example: - // | require(["dojo/query", "dojo/NodeList-fx" - // | ], function(query){ - // | query(".zork").animateProperty({ - // | duration: 500, - // | properties: { - // | color: { start: "black", end: "white" }, - // | left: { end: 300 } - // | } - // | }).play(); - // | }); - // - // example: - // | require(["dojo/query", "dojo/NodeList-fx" - // | ], function(query){ - // | query(".grue").animateProperty({ - // | auto:true, - // | properties: { - // | height:240 - // | } - // | }).onclick(handler); - // | }); - return this._anim(baseFx, "animateProperty", args); // dojo/_base/fx.Animation|dojo/NodeList - }, - - anim: function( /*Object*/ properties, - /*Integer?*/ duration, - /*Function?*/ easing, - /*Function?*/ onEnd, - /*Integer?*/ delay){ - // summary: - // Animate one or more CSS properties for all nodes in this list. - // The returned animation object will already be playing when it - // is returned. See the docs for `dojo.anim` for full details. - // properties: Object - // the properties to animate. does NOT support the `auto` parameter like other - // NodeList-fx methods. - // duration: Integer? - // Optional. The time to run the animations for - // easing: Function? - // Optional. The easing function to use. - // onEnd: Function? - // A function to be called when the animation ends - // delay: - // how long to delay playing the returned animation - // example: - // Another way to fade out: - // | require(["dojo/query", "dojo/NodeList-fx" - // | ], function(query){ - // | query(".thinger").anim({ opacity: 0 }); - // | }); - // example: - // animate all elements with the "thigner" class to a width of 500 - // pixels over half a second - // | require(["dojo/query", "dojo/NodeList-fx" - // | ], function(query){ - // | query(".thinger").anim({ width: 500 }, 700); - // | }); - var canim = coreFx.combine( - this.map(function(item){ - return baseFx.animateProperty({ - node: item, - properties: properties, - duration: duration||350, - easing: easing - }); - }) - ); - if(onEnd){ - aspect.after(canim, "onEnd", onEnd, true); - } - return canim.play(delay||0); // dojo/_base/fx.Animation - } -}); - -return NodeList; -}); diff --git a/lib/dojo/NodeList-html.js b/lib/dojo/NodeList-html.js deleted file mode 100644 index f685da4..0000000 --- a/lib/dojo/NodeList-html.js +++ /dev/null @@ -1,20 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/NodeList-html",["./query","./_base/lang","./html"],function(_1,_2,_3){ -var _4=_1.NodeList; -_2.extend(_4,{html:function(_5,_6){ -var _7=new _3._ContentSetter(_6||{}); -this.forEach(function(_8){ -_7.node=_8; -_7.set(_5); -_7.tearDown(); -}); -return this; -}}); -return _4; -}); diff --git a/lib/dojo/NodeList-html.js.uncompressed.js b/lib/dojo/NodeList-html.js.uncompressed.js deleted file mode 100644 index 54c1710..0000000 --- a/lib/dojo/NodeList-html.js.uncompressed.js +++ /dev/null @@ -1,56 +0,0 @@ -define("dojo/NodeList-html", ["./query", "./_base/lang", "./html"], function(query, lang, html){ - -// module: -// dojo/NodeList-html - -/*===== -return function(){ - // summary: - // Adds a chainable html method to dojo/query() / NodeList instances for setting/replacing node content -}; -=====*/ - -var NodeList = query.NodeList; - - -lang.extend(NodeList, { - html: function(/* String|DomNode|NodeList? */ content, /* Object? */params){ - // summary: - // see `dojo/html.set()`. Set the content of all elements of this NodeList - // - // content: - // An html string, node or enumerable list of nodes for insertion into the dom - // - // params: - // Optional flags/properties to configure the content-setting. See dojo/html._ContentSetter - // - // description: - // Based around `dojo/html.set()`, set the content of the Elements in a - // NodeList to the given content (string/node/nodelist), with optional arguments - // to further tune the set content behavior. - // - // example: - // | require(["dojo/query", "dojo/NodeList-html" - // | ], function(query){ - // | query(".thingList").html("
  • 1
  • 2
  • 3
  • ", - // | { - // | parseContent: true, - // | onBegin: function(){ - // | this.content = this.content.replace(/([0-9])/g, this.id + ": $1"); - // | this.inherited("onBegin", arguments); - // | } - // | }).removeClass("notdone").addClass("done"); - // | }); - - var dhs = new html._ContentSetter(params || {}); - this.forEach(function(elm){ - dhs.node = elm; - dhs.set(content); - dhs.tearDown(); - }); - return this; // dojo/NodeList - } -}); - -return NodeList; -}); diff --git a/lib/dojo/NodeList-manipulate.js b/lib/dojo/NodeList-manipulate.js deleted file mode 100644 index 665f469..0000000 --- a/lib/dojo/NodeList-manipulate.js +++ /dev/null @@ -1,196 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/NodeList-manipulate",["./query","./_base/lang","./_base/array","./dom-construct","./dom-attr","./NodeList-dom"],function(_1,_2,_3,_4,_5){ -var _6=_1.NodeList; -function _7(_8){ -while(_8.childNodes[0]&&_8.childNodes[0].nodeType==1){ -_8=_8.childNodes[0]; -} -return _8; -}; -function _9(_a,_b){ -if(typeof _a=="string"){ -_a=_4.toDom(_a,(_b&&_b.ownerDocument)); -if(_a.nodeType==11){ -_a=_a.childNodes[0]; -} -}else{ -if(_a.nodeType==1&&_a.parentNode){ -_a=_a.cloneNode(false); -} -} -return _a; -}; -_2.extend(_6,{_placeMultiple:function(_c,_d){ -var _e=typeof _c=="string"||_c.nodeType?_1(_c):_c; -var _f=[]; -for(var i=0;i<_e.length;i++){ -var _10=_e[i]; -var _11=this.length; -for(var j=_11-1,_12;_12=this[j];j--){ -if(i>0){ -_12=this._cloneNode(_12); -_f.unshift(_12); -} -if(j==_11-1){ -_4.place(_12,_10,_d); -}else{ -_10.parentNode.insertBefore(_12,_10); -} -_10=_12; -} -} -if(_f.length){ -_f.unshift(0); -_f.unshift(this.length-1); -Array.prototype.splice.apply(this,_f); -} -return this; -},innerHTML:function(_13){ -if(arguments.length){ -return this.addContent(_13,"only"); -}else{ -return this[0].innerHTML; -} -},text:function(_14){ -if(arguments.length){ -for(var i=0,_15;_15=this[i];i++){ -if(_15.nodeType==1){ -_5.set(_15,"textContent",_14); -} -} -return this; -}else{ -var _16=""; -for(i=0;_15=this[i];i++){ -_16+=_5.get(_15,"textContent"); -} -return _16; -} -},val:function(_17){ -if(arguments.length){ -var _18=_2.isArray(_17); -for(var _19=0,_1a;_1a=this[_19];_19++){ -var _1b=_1a.nodeName.toUpperCase(); -var _1c=_1a.type; -var _1d=_18?_17[_19]:_17; -if(_1b=="SELECT"){ -var _1e=_1a.options; -for(var i=0;i<_1e.length;i++){ -var opt=_1e[i]; -if(_1a.multiple){ -opt.selected=(_3.indexOf(_17,opt.value)!=-1); -}else{ -opt.selected=(opt.value==_1d); -} -} -}else{ -if(_1c=="checkbox"||_1c=="radio"){ -_1a.checked=(_1a.value==_1d); -}else{ -_1a.value=_1d; -} -} -} -return this; -}else{ -_1a=this[0]; -if(!_1a||_1a.nodeType!=1){ -return undefined; -} -_17=_1a.value||""; -if(_1a.nodeName.toUpperCase()=="SELECT"&&_1a.multiple){ -_17=[]; -_1e=_1a.options; -for(i=0;i<_1e.length;i++){ -opt=_1e[i]; -if(opt.selected){ -_17.push(opt.value); -} -} -if(!_17.length){ -_17=null; -} -} -return _17; -} -},append:function(_1f){ -return this.addContent(_1f,"last"); -},appendTo:function(_20){ -return this._placeMultiple(_20,"last"); -},prepend:function(_21){ -return this.addContent(_21,"first"); -},prependTo:function(_22){ -return this._placeMultiple(_22,"first"); -},after:function(_23){ -return this.addContent(_23,"after"); -},insertAfter:function(_24){ -return this._placeMultiple(_24,"after"); -},before:function(_25){ -return this.addContent(_25,"before"); -},insertBefore:function(_26){ -return this._placeMultiple(_26,"before"); -},remove:_6.prototype.orphan,wrap:function(_27){ -if(this[0]){ -_27=_9(_27,this[0]); -for(var i=0,_28;_28=this[i];i++){ -var _29=this._cloneNode(_27); -if(_28.parentNode){ -_28.parentNode.replaceChild(_29,_28); -} -var _2a=_7(_29); -_2a.appendChild(_28); -} -} -return this; -},wrapAll:function(_2b){ -if(this[0]){ -_2b=_9(_2b,this[0]); -this[0].parentNode.replaceChild(_2b,this[0]); -var _2c=_7(_2b); -for(var i=0,_2d;_2d=this[i];i++){ -_2c.appendChild(_2d); -} -} -return this; -},wrapInner:function(_2e){ -if(this[0]){ -_2e=_9(_2e,this[0]); -for(var i=0;i0); -_31.parentNode.removeChild(_31); -} -return this; -},replaceAll:function(_32){ -var nl=_1(_32); -var _33=this._normalize(this,this[0]); -for(var i=0,_34;_34=nl[i];i++){ -this._place(_33,_34,"before",i>0); -_34.parentNode.removeChild(_34); -} -return this; -},clone:function(){ -var ary=[]; -for(var i=0;i 0){ - //Need to clone the item. This also means - //it needs to be added to the current NodeList - //so it can also be the target of other chaining operations. - item = this._cloneNode(item); - toAdd.unshift(item); - } - if(j == length - 1){ - construct.place(item, refNode, position); - }else{ - refNode.parentNode.insertBefore(item, refNode); - } - refNode = item; - } - } - - if(toAdd.length){ - //Add the toAdd items to the current NodeList. Build up list of args - //to pass to splice. - toAdd.unshift(0); - toAdd.unshift(this.length - 1); - Array.prototype.splice.apply(this, toAdd); - } - - return this; // dojo/NodeList - }, - - innerHTML: function(/*String|DOMNode|NodeList?*/ value){ - // summary: - // allows setting the innerHTML of each node in the NodeList, - // if there is a value passed in, otherwise, reads the innerHTML value of the first node. - // description: - // This method is simpler than the dojo/NodeList.html() method provided by - // `dojo/NodeList-html`. This method just does proper innerHTML insertion of HTML fragments, - // and it allows for the innerHTML to be read for the first node in the node list. - // Since dojo/NodeList-html already took the "html" name, this method is called - // "innerHTML". However, if dojo/NodeList-html has not been loaded yet, this - // module will define an "html" method that can be used instead. Be careful if you - // are working in an environment where it is possible that dojo/NodeList-html could - // have been loaded, since its definition of "html" will take precedence. - // The nodes represented by the value argument will be cloned if more than one - // node is in this NodeList. The nodes in this NodeList are returned in the "set" - // usage of this method, not the HTML that was inserted. - // returns: - // if no value is passed, the result is String, the innerHTML of the first node. - // If a value is passed, the return is this dojo/NodeList - // example: - // assume a DOM created by this markup: - // |
    - // |
    - // This code inserts `

    Hello World

    ` into both divs: - // | require(["dojo/query", "dojo/NodeList-manipulate" - // | ], function(query){ - // | query("div").innerHTML("

    Hello World

    "); - // | }); - // example: - // assume a DOM created by this markup: - // |

    Hello Mars

    - // |

    Hello World

    - // This code returns `

    Hello Mars

    `: - // | require(["dojo/query", "dojo/NodeList-manipulate" - // | ], function(query){ - // | var message = query("div").innerHTML(); - // | }); - if(arguments.length){ - return this.addContent(value, "only"); // dojo/NodeList - }else{ - return this[0].innerHTML; //String - } - }, - - /*===== - html: function(value){ - // summary: - // see the information for "innerHTML". "html" is an alias for "innerHTML", but is - // only defined if dojo/NodeList-html has not been loaded. - // description: - // An alias for the "innerHTML" method, but only defined if there is not an existing - // "html" method on dojo/NodeList. Be careful if you are working in an environment - // where it is possible that dojo/NodeList-html could have been loaded, since its - // definition of "html" will take precedence. If you are not sure if dojo/NodeList-html - // could be loaded, use the "innerHTML" method. - // value: String|DOMNode|NodeList? - // The HTML fragment to use as innerHTML. If value is not passed, then the innerHTML - // of the first element in this NodeList is returned. - // returns: - // if no value is passed, the result is String, the innerHTML of the first node. - // If a value is passed, the return is this dojo/NodeList - return; // dojo/NodeList|String - }, - =====*/ - - text: function(/*String*/value){ - // summary: - // allows setting the text value of each node in the NodeList, - // if there is a value passed in, otherwise, returns the text value for all the - // nodes in the NodeList in one string. - // example: - // assume a DOM created by this markup: - // |
    - // |
    - // This code inserts "Hello World" into both divs: - // | require(["dojo/query", "dojo/NodeList-manipulate" - // | ], function(query){ - // | query("div").text("Hello World"); - // | }); - // example: - // assume a DOM created by this markup: - // |

    Hello Mars today

    - // |

    Hello World

    - // This code returns "Hello Mars today": - // | require(["dojo/query", "dojo/NodeList-manipulate" - // | ], function(query){ - // | var message = query("div").text(); - // | }); - // returns: - // if no value is passed, the result is String, the text value of the first node. - // If a value is passed, the return is this dojo/NodeList - if(arguments.length){ - for(var i = 0, node; node = this[i]; i++){ - if(node.nodeType == 1){ - attr.set(node, 'textContent', value); - } - } - return this; // dojo/NodeList - }else{ - var result = ""; - for(i = 0; node = this[i]; i++){ - result += attr.get(node, 'textContent'); - } - return result; //String - } - }, - - val: function(/*String||Array*/value){ - // summary: - // If a value is passed, allows seting the value property of form elements in this - // NodeList, or properly selecting/checking the right value for radio/checkbox/select - // elements. If no value is passed, the value of the first node in this NodeList - // is returned. - // returns: - // if no value is passed, the result is String or an Array, for the value of the - // first node. - // If a value is passed, the return is this dojo/NodeList - // example: - // assume a DOM created by this markup: - // | - // | - // This code gets and sets the values for the form fields above: - // | require(["dojo/query", "dojo/NodeList-manipulate" - // | ], function(query){ - // | query('[type="text"]').val(); //gets value foo - // | query('[type="text"]').val("bar"); //sets the input's value to "bar" - // | query("select").val() //gets array value ["red", "yellow"] - // | query("select").val(["blue", "yellow"]) //Sets the blue and yellow options to selected. - // | }); - - //Special work for input elements. - if(arguments.length){ - var isArray = lang.isArray(value); - for(var index = 0, node; node = this[index]; index++){ - var name = node.nodeName.toUpperCase(); - var type = node.type; - var newValue = isArray ? value[index] : value; - - if(name == "SELECT"){ - var opts = node.options; - for(var i = 0; i < opts.length; i++){ - var opt = opts[i]; - if(node.multiple){ - opt.selected = (array.indexOf(value, opt.value) != -1); - }else{ - opt.selected = (opt.value == newValue); - } - } - }else if(type == "checkbox" || type == "radio"){ - node.checked = (node.value == newValue); - }else{ - node.value = newValue; - } - } - return this; // dojo/NodeList - }else{ - //node already declared above. - node = this[0]; - if(!node || node.nodeType != 1){ - return undefined; - } - value = node.value || ""; - if(node.nodeName.toUpperCase() == "SELECT" && node.multiple){ - //A multivalued selectbox. Do the pain. - value = []; - //opts declared above in if block. - opts = node.options; - //i declared above in if block; - for(i = 0; i < opts.length; i++){ - //opt declared above in if block - opt = opts[i]; - if(opt.selected){ - value.push(opt.value); - } - } - if(!value.length){ - value = null; - } - } - return value; //String||Array - } - }, - - append: function(/*String||DOMNode||NodeList*/content){ - // summary: - // appends the content to every node in the NodeList. - // description: - // The content will be cloned if the length of NodeList - // is greater than 1. Only the DOM nodes are cloned, not - // any attached event handlers. - // returns: - // dojo/NodeList, the nodes currently in this NodeList will be returned, - // not the appended content. - // example: - // assume a DOM created by this markup: - // |

    Hello Mars

    - // |

    Hello World

    - // Running this code: - // | require(["dojo/query", "dojo/NodeList-manipulate" - // | ], function(query){ - // | query("div").append("append"); - // | }); - // Results in this DOM structure: - // |

    Hello Mars

    append
    - // |

    Hello World

    append
    - return this.addContent(content, "last"); // dojo/NodeList - }, - - appendTo: function(/*String*/query){ - // summary: - // appends nodes in this NodeList to the nodes matched by - // the query passed to appendTo. - // description: - // The nodes in this NodeList will be cloned if the query - // matches more than one element. Only the DOM nodes are cloned, not - // any attached event handlers. - // returns: - // dojo/NodeList, the nodes currently in this NodeList will be returned, - // not the matched nodes from the query. - // example: - // assume a DOM created by this markup: - // | append - // |

    Hello Mars

    - // |

    Hello World

    - // Running this code: - // | require(["dojo/query", "dojo/NodeList-manipulate" - // | ], function(query){ - // | query("span").appendTo("p"); - // | }); - // Results in this DOM structure: - // |

    Hello Marsappend

    - // |

    Hello Worldappend

    - return this._placeMultiple(query, "last"); // dojo/NodeList - }, - - prepend: function(/*String||DOMNode||NodeList*/content){ - // summary: - // prepends the content to every node in the NodeList. - // description: - // The content will be cloned if the length of NodeList - // is greater than 1. Only the DOM nodes are cloned, not - // any attached event handlers. - // returns: - // dojo/NodeList, the nodes currently in this NodeList will be returned, - // not the appended content. - // assume a DOM created by this markup: - // |

    Hello Mars

    - // |

    Hello World

    - // Running this code: - // | require(["dojo/query", "dojo/NodeList-manipulate" - // | ], function(query){ - // | query("div").prepend("prepend"); - // | }); - // Results in this DOM structure: - // |
    prepend

    Hello Mars

    - // |
    prepend

    Hello World

    - return this.addContent(content, "first"); // dojo/NodeList - }, - - prependTo: function(/*String*/query){ - // summary: - // prepends nodes in this NodeList to the nodes matched by - // the query passed to prependTo. - // description: - // The nodes in this NodeList will be cloned if the query - // matches more than one element. Only the DOM nodes are cloned, not - // any attached event handlers. - // returns: - // dojo/NodeList, the nodes currently in this NodeList will be returned, - // not the matched nodes from the query. - // example: - // assume a DOM created by this markup: - // | prepend - // |

    Hello Mars

    - // |

    Hello World

    - // Running this code: - // | require(["dojo/query", "dojo/NodeList-manipulate" - // | ], function(query){ - // | query("span").prependTo("p"); - // | }); - // Results in this DOM structure: - // |

    prependHello Mars

    - // |

    prependHello World

    - return this._placeMultiple(query, "first"); // dojo/NodeList - }, - - after: function(/*String||Element||NodeList*/content){ - // summary: - // Places the content after every node in the NodeList. - // description: - // The content will be cloned if the length of NodeList - // is greater than 1. Only the DOM nodes are cloned, not - // any attached event handlers. - // returns: - // dojo/NodeList, the nodes currently in this NodeList will be returned, - // not the appended content. - // example: - // assume a DOM created by this markup: - // |

    Hello Mars

    - // |

    Hello World

    - // Running this code: - // | require(["dojo/query", "dojo/NodeList-manipulate" - // | ], function(query){ - // | query("div").after("after"); - // | }); - // Results in this DOM structure: - // |

    Hello Mars

    after - // |

    Hello World

    after - return this.addContent(content, "after"); // dojo/NodeList - }, - - insertAfter: function(/*String*/query){ - // summary: - // The nodes in this NodeList will be placed after the nodes - // matched by the query passed to insertAfter. - // description: - // The nodes in this NodeList will be cloned if the query - // matches more than one element. Only the DOM nodes are cloned, not - // any attached event handlers. - // returns: - // dojo/NodeList, the nodes currently in this NodeList will be returned, - // not the matched nodes from the query. - // example: - // assume a DOM created by this markup: - // | after - // |

    Hello Mars

    - // |

    Hello World

    - // Running this code: - // | require(["dojo/query", "dojo/NodeList-manipulate" - // | ], function(query){ - // | query("span").insertAfter("p"); - // | }); - // Results in this DOM structure: - // |

    Hello Mars

    after - // |

    Hello World

    after - return this._placeMultiple(query, "after"); // dojo/NodeList - }, - - before: function(/*String||DOMNode||NodeList*/content){ - // summary: - // Places the content before every node in the NodeList. - // description: - // The content will be cloned if the length of NodeList - // is greater than 1. Only the DOM nodes are cloned, not - // any attached event handlers. - // returns: - // dojo/NodeList, the nodes currently in this NodeList will be returned, - // not the appended content. - // example: - // assume a DOM created by this markup: - // |

    Hello Mars

    - // |

    Hello World

    - // Running this code: - // | require(["dojo/query", "dojo/NodeList-manipulate" - // | ], function(query){ - // | query("div").before("before"); - // | }); - // Results in this DOM structure: - // | before

    Hello Mars

    - // | before

    Hello World

    - return this.addContent(content, "before"); // dojo/NodeList - }, - - insertBefore: function(/*String*/query){ - // summary: - // The nodes in this NodeList will be placed after the nodes - // matched by the query passed to insertAfter. - // description: - // The nodes in this NodeList will be cloned if the query - // matches more than one element. Only the DOM nodes are cloned, not - // any attached event handlers. - // returns: - // dojo/NodeList, the nodes currently in this NodeList will be returned, - // not the matched nodes from the query. - // example: - // assume a DOM created by this markup: - // | before - // |

    Hello Mars

    - // |

    Hello World

    - // Running this code: - // | require(["dojo/query", "dojo/NodeList-manipulate" - // | ], function(query){ - // | query("span").insertBefore("p"); - // | }); - // Results in this DOM structure: - // | before

    Hello Mars

    - // | before

    Hello World

    - return this._placeMultiple(query, "before"); // dojo/NodeList - }, - - /*===== - remove: function(simpleFilter){ - // summary: - // alias for dojo/NodeList's orphan method. Removes elements - // in this list that match the simple filter from their parents - // and returns them as a new NodeList. - // simpleFilter: String - // single-expression CSS rule. For example, ".thinger" or - // "#someId[attrName='value']" but not "div > span". In short, - // anything which does not invoke a descent to evaluate but - // can instead be used to test a single node is acceptable. - - return; // dojo/NodeList - }, - =====*/ - remove: NodeList.prototype.orphan, - - wrap: function(/*String||DOMNode*/html){ - // summary: - // Wrap each node in the NodeList with html passed to wrap. - // description: - // html will be cloned if the NodeList has more than one - // element. Only DOM nodes are cloned, not any attached - // event handlers. - // returns: - // the nodes in the current NodeList will be returned, - // not the nodes from html argument. - // example: - // assume a DOM created by this markup: - // | one - // | two - // Running this code: - // | require(["dojo/query", "dojo/NodeList-manipulate" - // | ], function(query){ - // | query("b").wrap("
    "); - // | }); - // Results in this DOM structure: - // |
    one
    - // |
    two
    - if(this[0]){ - html = makeWrapNode(html, this[0]); - - //Now cycle through the elements and do the insertion. - for(var i = 0, node; node = this[i]; i++){ - //Always clone because if html is used to hold one of - //the "this" nodes, then on the clone of html it will contain - //that "this" node, and that would be bad. - var clone = this._cloneNode(html); - if(node.parentNode){ - node.parentNode.replaceChild(clone, node); - } - //Find deepest element and insert old node in it. - var insertion = getWrapInsertion(clone); - insertion.appendChild(node); - } - } - return this; // dojo/NodeList - }, - - wrapAll: function(/*String||DOMNode*/html){ - // summary: - // Insert html where the first node in this NodeList lives, then place all - // nodes in this NodeList as the child of the html. - // returns: - // the nodes in the current NodeList will be returned, - // not the nodes from html argument. - // example: - // assume a DOM created by this markup: - // |
    - // |
    Red One
    - // |
    Blue One
    - // |
    Red Two
    - // |
    Blue Two
    - // |
    - // Running this code: - // | require(["dojo/query", "dojo/NodeList-manipulate" - // | ], function(query){ - // | query(".red").wrapAll('
    '); - // | }); - // Results in this DOM structure: - // |
    - // |
    - // |
    Red One
    - // |
    Red Two
    - // |
    - // |
    Blue One
    - // |
    Blue Two
    - // |
    - if(this[0]){ - html = makeWrapNode(html, this[0]); - - //Place the wrap HTML in place of the first node. - this[0].parentNode.replaceChild(html, this[0]); - - //Now cycle through the elements and move them inside - //the wrap. - var insertion = getWrapInsertion(html); - for(var i = 0, node; node = this[i]; i++){ - insertion.appendChild(node); - } - } - return this; // dojo/NodeList - }, - - wrapInner: function(/*String||DOMNode*/html){ - // summary: - // For each node in the NodeList, wrap all its children with the passed in html. - // description: - // html will be cloned if the NodeList has more than one - // element. Only DOM nodes are cloned, not any attached - // event handlers. - // returns: - // the nodes in the current NodeList will be returned, - // not the nodes from html argument. - // example: - // assume a DOM created by this markup: - // |
    - // |
    Red One
    - // |
    Blue One
    - // |
    Red Two
    - // |
    Blue Two
    - // |
    - // Running this code: - // | require(["dojo/query", "dojo/NodeList-manipulate" - // | ], function(query){ - // | query(".red").wrapInner(''); - // | }); - // Results in this DOM structure: - // |
    - // |
    Red One
    - // |
    Blue One
    - // |
    Red Two
    - // |
    Blue Two
    - // |
    - if(this[0]){ - html = makeWrapNode(html, this[0]); - for(var i = 0; i < this.length; i++){ - //Always clone because if html is used to hold one of - //the "this" nodes, then on the clone of html it will contain - //that "this" node, and that would be bad. - var clone = this._cloneNode(html); - - //Need to convert the childNodes to an array since wrapAll modifies the - //DOM and can change the live childNodes NodeList. - this._wrap(lang._toArray(this[i].childNodes), null, this._NodeListCtor).wrapAll(clone); - } - } - return this; // dojo/NodeList - }, - - replaceWith: function(/*String||DOMNode||NodeList*/content){ - // summary: - // Replaces each node in ths NodeList with the content passed to replaceWith. - // description: - // The content will be cloned if the length of NodeList - // is greater than 1. Only the DOM nodes are cloned, not - // any attached event handlers. - // returns: - // The nodes currently in this NodeList will be returned, not the replacing content. - // Note that the returned nodes have been removed from the DOM. - // example: - // assume a DOM created by this markup: - // |
    - // |
    Red One
    - // |
    Blue One
    - // |
    Red Two
    - // |
    Blue Two
    - // |
    - // Running this code: - // | require(["dojo/query", "dojo/NodeList-manipulate" - // | ], function(query){ - // | query(".red").replaceWith('
    Green
    '); - // | }); - // Results in this DOM structure: - // |
    - // |
    Green
    - // |
    Blue One
    - // |
    Green
    - // |
    Blue Two
    - // |
    - content = this._normalize(content, this[0]); - for(var i = 0, node; node = this[i]; i++){ - this._place(content, node, "before", i > 0); - node.parentNode.removeChild(node); - } - return this; // dojo/NodeList - }, - - replaceAll: function(/*String*/query){ - // summary: - // replaces nodes matched by the query passed to replaceAll with the nodes - // in this NodeList. - // description: - // The nodes in this NodeList will be cloned if the query - // matches more than one element. Only the DOM nodes are cloned, not - // any attached event handlers. - // returns: - // The nodes currently in this NodeList will be returned, not the matched nodes - // from the query. The nodes currently in this NodeLIst could have - // been cloned, so the returned NodeList will include the cloned nodes. - // example: - // assume a DOM created by this markup: - // |
    - // |
    ___
    - // |
    Red One
    - // |
    ___
    - // |
    Blue One
    - // |
    ___
    - // |
    Red Two
    - // |
    ___
    - // |
    Blue Two
    - // |
    - // Running this code: - // | require(["dojo/query", "dojo/NodeList-manipulate" - // | ], function(query){ - // | query(".red").replaceAll(".blue"); - // | }); - // Results in this DOM structure: - // |
    - // |
    ___
    - // |
    ___
    - // |
    Red One
    - // |
    Red Two
    - // |
    ___
    - // |
    ___
    - // |
    Red One
    - // |
    Red Two
    - // |
    - var nl = dquery(query); - var content = this._normalize(this, this[0]); - for(var i = 0, node; node = nl[i]; i++){ - this._place(content, node, "before", i > 0); - node.parentNode.removeChild(node); - } - return this; // dojo/NodeList - }, - - clone: function(){ - // summary: - // Clones all the nodes in this NodeList and returns them as a new NodeList. - // description: - // Only the DOM nodes are cloned, not any attached event handlers. - // returns: - // a cloned set of the original nodes. - // example: - // assume a DOM created by this markup: - // |
    - // |
    Red One
    - // |
    Blue One
    - // |
    Red Two
    - // |
    Blue Two
    - // |
    - // Running this code: - // | require(["dojo/query", "dojo/NodeList-manipulate" - // | ], function(query){ - // | query(".red").clone().appendTo(".container"); - // | }); - // Results in this DOM structure: - // |
    - // |
    Red One
    - // |
    Blue One
    - // |
    Red Two
    - // |
    Blue Two
    - // |
    Red One
    - // |
    Red Two
    - // |
    - - //TODO: need option to clone events? - var ary = []; - for(var i = 0; i < this.length; i++){ - ary.push(this._cloneNode(this[i])); - } - return this._wrap(ary, this, this._NodeListCtor); // dojo/NodeList - } - }); - - //set up html method if one does not exist - if(!NodeList.prototype.html){ - NodeList.prototype.html = NodeList.prototype.innerHTML; - } - - return NodeList; -}); diff --git a/lib/dojo/NodeList-traverse.js b/lib/dojo/NodeList-traverse.js deleted file mode 100644 index c850def..0000000 --- a/lib/dojo/NodeList-traverse.js +++ /dev/null @@ -1,124 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/NodeList-traverse",["./query","./_base/lang","./_base/array"],function(_1,_2,_3){ -var _4=_1.NodeList; -_2.extend(_4,{_buildArrayFromCallback:function(_5){ -var _6=[]; -for(var i=0;i - // |
    Red One
    - // | Some Text - // |
    Blue One
    - // |
    Red Two
    - // |
    Blue Two
    - // |
    - // Running this code: - // | require(["dojo/query", "dojo/NodeList-traverse" - // | ], function(query){ - // | query(".container").children(); - // | }); - // returns the four divs that are children of the container div. - // Running this code: - // | dojo.query(".container").children(".red"); - // returns the two divs that have the class "red". - return this._getRelatedUniqueNodes(query, function(node, ary){ - return lang._toArray(node.childNodes); - }); // dojo/NodeList - }, - - closest: function(/*String*/ query, /*String|DOMNode?*/ root){ - // summary: - // Returns closest parent that matches query, including current node in this - // dojo/NodeList if it matches the query. - // description: - // .end() can be used on the returned dojo/NodeList to get back to the - // original dojo/NodeList. - // query: - // a CSS selector. - // root: - // If specified, query is relative to "root" rather than document body. - // returns: - // the closest parent that matches the query, including the current - // node in this dojo/NodeList if it matches the query. - // example: - // assume a DOM created by this markup: - // |
    - // |
    Red One
    - // | Some Text - // |
    Blue One
    - // |
    Red Two
    - // |
    Blue Two
    - // |
    - // Running this code: - // | require(["dojo/query", "dojo/NodeList-traverse" - // | ], function(query){ - // | query(".red").closest(".container"); - // | }); - // returns the div with class "container". - return this._getRelatedUniqueNodes(null, function(node, ary){ - do{ - if(dquery._filterResult([node], query, root).length){ - return node; - } - }while(node != root && (node = node.parentNode) && node.nodeType == 1); - return null; //To make rhino strict checking happy. - }); // dojo/NodeList - }, - - parent: function(/*String?*/ query){ - // summary: - // Returns immediate parent elements for nodes in this dojo/NodeList. - // Optionally takes a query to filter the parent elements. - // description: - // .end() can be used on the returned dojo/NodeList to get back to the - // original dojo/NodeList. - // query: - // a CSS selector. - // returns: - // immediate parent elements for nodes in this dojo/NodeList. - // example: - // assume a DOM created by this markup: - // |
    - // |
    Red One
    - // |
    Blue One
    - // |
    Red Two
    - // |
    Blue Two
    - // |
    - // Running this code: - // | require(["dojo/query", "dojo/NodeList-traverse" - // | ], function(query){ - // | query(".text").parent(); - // | }); - // returns the two divs with class "blue". - // Running this code: - // | query(".text").parent(".first"); - // returns the one div with class "blue" and "first". - return this._getRelatedUniqueNodes(query, function(node, ary){ - return node.parentNode; - }); // dojo/NodeList - }, - - parents: function(/*String?*/ query){ - // summary: - // Returns all parent elements for nodes in this dojo/NodeList. - // Optionally takes a query to filter the child elements. - // description: - // .end() can be used on the returned dojo/NodeList to get back to the - // original dojo/NodeList. - // query: - // a CSS selector. - // returns: - // all parent elements for nodes in this dojo/NodeList. - // example: - // assume a DOM created by this markup: - // |
    - // |
    Red One
    - // |
    Blue One
    - // |
    Red Two
    - // |
    Blue Two
    - // |
    - // Running this code: - // | require(["dojo/query", "dojo/NodeList-traverse" - // | ], function(query){ - // | query(".text").parents(); - // | }); - // returns the two divs with class "blue", the div with class "container", - // | the body element and the html element. - // Running this code: - // | query(".text").parents(".container"); - // returns the one div with class "container". - return this._getRelatedUniqueNodes(query, function(node, ary){ - var pary = []; - while(node.parentNode){ - node = node.parentNode; - pary.push(node); - } - return pary; - }); // dojo/NodeList - }, - - siblings: function(/*String?*/ query){ - // summary: - // Returns all sibling elements for nodes in this dojo/NodeList. - // Optionally takes a query to filter the sibling elements. - // description: - // .end() can be used on the returned dojo/NodeList to get back to the - // original dojo/NodeList. - // query: - // a CSS selector. - // returns: - // all sibling elements for nodes in this dojo/NodeList. - // example: - // assume a DOM created by this markup: - // |
    - // |
    Red One
    - // | Some Text - // |
    Blue One
    - // |
    Red Two
    - // |
    Blue Two
    - // |
    - // Running this code: - // | require(["dojo/query", "dojo/NodeList-traverse" - // | ], function(query){ - // | query(".first").siblings(); - // | }); - // returns the two divs with class "red" and the other div - // | with class "blue" that does not have "first". - // Running this code: - // | query(".first").siblings(".red"); - // returns the two div with class "red". - return this._getRelatedUniqueNodes(query, function(node, ary){ - var pary = []; - var nodes = (node.parentNode && node.parentNode.childNodes); - for(var i = 0; i < nodes.length; i++){ - if(nodes[i] != node){ - pary.push(nodes[i]); - } - } - return pary; - }); // dojo/NodeList - }, - - next: function(/*String?*/ query){ - // summary: - // Returns the next element for nodes in this dojo/NodeList. - // Optionally takes a query to filter the next elements. - // description: - // .end() can be used on the returned dojo/NodeList to get back to the - // original dojo/NodeList. - // query: - // a CSS selector. - // returns: - // the next element for nodes in this dojo/NodeList. - // example: - // assume a DOM created by this markup: - // |
    - // |
    Red One
    - // | Some Text - // |
    Blue One
    - // |
    Red Two
    - // |
    Blue Two
    - // |
    - // Running this code: - // | require(["dojo/query", "dojo/NodeList-traverse" - // | ], function(query){ - // | query(".first").next(); - // | }); - // returns the div with class "red" and has innerHTML of "Red Two". - // Running this code: - // | dojo.query(".last").next(".red"); - // does not return any elements. - return this._getRelatedUniqueNodes(query, function(node, ary){ - var next = node.nextSibling; - while(next && next.nodeType != 1){ - next = next.nextSibling; - } - return next; - }); // dojo/NodeList - }, - - nextAll: function(/*String?*/ query){ - // summary: - // Returns all sibling elements that come after the nodes in this dojo/NodeList. - // Optionally takes a query to filter the sibling elements. - // description: - // .end() can be used on the returned dojo/NodeList to get back to the - // original dojo/NodeList. - // query: - // a CSS selector. - // returns: - // all sibling elements that come after the nodes in this dojo/NodeList. - // example: - // assume a DOM created by this markup: - // |
    - // |
    Red One
    - // | Some Text - // |
    Blue One
    - // | - // | - // |
    - // Running this code: - // | require(["dojo/query", "dojo/NodeList-traverse" - // | ], function(query){ - // | query(".first").nextAll(); - // | }); - // returns the two divs with class of "next". - // Running this code: - // | query(".first").nextAll(".red"); - // returns the one div with class "red" and innerHTML "Red Two". - return this._getRelatedUniqueNodes(query, function(node, ary){ - var pary = []; - var next = node; - while((next = next.nextSibling)){ - if(next.nodeType == 1){ - pary.push(next); - } - } - return pary; - }); // dojo/NodeList - }, - - prev: function(/*String?*/ query){ - // summary: - // Returns the previous element for nodes in this dojo/NodeList. - // Optionally takes a query to filter the previous elements. - // description: - // .end() can be used on the returned dojo/NodeList to get back to the - // original dojo/NodeList. - // query: - // a CSS selector. - // returns: - // the previous element for nodes in this dojo/NodeList. - // example: - // assume a DOM created by this markup: - // |
    - // |
    Red One
    - // | Some Text - // |
    Blue One
    - // |
    Red Two
    - // |
    Blue Two
    - // |
    - // Running this code: - // | require(["dojo/query", "dojo/NodeList-traverse" - // | ], function(query){ - // | query(".first").prev(); - // | }); - // returns the div with class "red" and has innerHTML of "Red One". - // Running this code: - // | query(".first").prev(".blue"); - // does not return any elements. - return this._getRelatedUniqueNodes(query, function(node, ary){ - var prev = node.previousSibling; - while(prev && prev.nodeType != 1){ - prev = prev.previousSibling; - } - return prev; - }); // dojo/NodeList - }, - - prevAll: function(/*String?*/ query){ - // summary: - // Returns all sibling elements that come before the nodes in this dojo/NodeList. - // Optionally takes a query to filter the sibling elements. - // description: - // The returned nodes will be in reverse DOM order -- the first node in the list will - // be the node closest to the original node/NodeList. - // .end() can be used on the returned dojo/NodeList to get back to the - // original dojo/NodeList. - // query: - // a CSS selector. - // returns: - // all sibling elements that come before the nodes in this dojo/NodeList. - // example: - // assume a DOM created by this markup: - // |
    - // | - // | Some Text - // | - // |
    Red Two
    - // |
    Blue Two
    - // |
    - // Running this code: - // | require(["dojo/query", "dojo/NodeList-traverse" - // | ], function(query){ - // | query(".second").prevAll(); - // | }); - // returns the two divs with class of "prev". - // Running this code: - // | query(".first").prevAll(".red"); - // returns the one div with class "red prev" and innerHTML "Red One". - return this._getRelatedUniqueNodes(query, function(node, ary){ - var pary = []; - var prev = node; - while((prev = prev.previousSibling)){ - if(prev.nodeType == 1){ - pary.push(prev); - } - } - return pary; - }); // dojo/NodeList - }, - - andSelf: function(){ - // summary: - // Adds the nodes from the previous dojo/NodeList to the current dojo/NodeList. - // description: - // .end() can be used on the returned dojo/NodeList to get back to the - // original dojo/NodeList. - // example: - // assume a DOM created by this markup: - // |
    - // | - // | Some Text - // | - // |
    Red Two
    - // |
    Blue Two
    - // |
    - // Running this code: - // | require(["dojo/query", "dojo/NodeList-traverse" - // | ], function(query){ - // | query(".second").prevAll().andSelf(); - // | }); - // returns the two divs with class of "prev", as well as the div with class "second". - return this.concat(this._parent); // dojo/NodeList - }, - - //Alternate methods for the :first/:last/:even/:odd pseudos. - first: function(){ - // summary: - // Returns the first node in this dojo/NodeList as a dojo/NodeList. - // description: - // .end() can be used on the returned dojo/NodeList to get back to the - // original dojo/NodeList. - // returns: - // the first node in this dojo/NodeList - // example: - // assume a DOM created by this markup: - // |
    - // |
    Red One
    - // |
    Blue One
    - // |
    Red Two
    - // |
    Blue Two
    - // |
    - // Running this code: - // | require(["dojo/query", "dojo/NodeList-traverse" - // | ], function(query){ - // | query(".blue").first(); - // | }); - // returns the div with class "blue" and "first". - return this._wrap(((this[0] && [this[0]]) || []), this); // dojo/NodeList - }, - - last: function(){ - // summary: - // Returns the last node in this dojo/NodeList as a dojo/NodeList. - // description: - // .end() can be used on the returned dojo/NodeList to get back to the - // original dojo/NodeList. - // returns: - // the last node in this dojo/NodeList - // example: - // assume a DOM created by this markup: - // |
    - // |
    Red One
    - // |
    Blue One
    - // |
    Red Two
    - // |
    Blue Two
    - // |
    - // Running this code: - // | require(["dojo/query", "dojo/NodeList-traverse" - // | ], function(query){ - // | query(".blue").last(); - // | }); - // returns the last div with class "blue", - return this._wrap((this.length ? [this[this.length - 1]] : []), this); // dojo/NodeList - }, - - even: function(){ - // summary: - // Returns the even nodes in this dojo/NodeList as a dojo/NodeList. - // description: - // .end() can be used on the returned dojo/NodeList to get back to the - // original dojo/NodeList. - // returns: - // the even nodes in this dojo/NodeList - // example: - // assume a DOM created by this markup: - // |
    - // |
    Red One
    - // |
    Blue One
    - // |
    Red Two
    - // |
    Blue Two
    - // |
    - // Running this code: - // | require(["dojo/query", "dojo/NodeList-traverse" - // | ], function(query){ - // | query(".interior").even(); - // | }); - // returns the two divs with class "blue" - return this.filter(function(item, i){ - return i % 2 != 0; - }); // dojo/NodeList - }, - - odd: function(){ - // summary: - // Returns the odd nodes in this dojo/NodeList as a dojo/NodeList. - // description: - // .end() can be used on the returned dojo/NodeList to get back to the - // original dojo/NodeList. - // returns: - // the odd nodes in this dojo/NodeList - // example: - // assume a DOM created by this markup: - // |
    - // |
    Red One
    - // |
    Blue One
    - // |
    Red Two
    - // |
    Blue Two
    - // |
    - // Running this code: - // | require(["dojo/query", "dojo/NodeList-traverse" - // | ], function(query){ - // | query(".interior").odd(); - // | }); - // returns the two divs with class "red" - return this.filter(function(item, i){ - return i % 2 == 0; - }); // dojo/NodeList - } -}); - -return NodeList; -}); diff --git a/lib/dojo/NodeList.js b/lib/dojo/NodeList.js deleted file mode 100644 index 694e230..0000000 --- a/lib/dojo/NodeList.js +++ /dev/null @@ -1,10 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/NodeList",["./query"],function(_1){ -return _1.NodeList; -}); diff --git a/lib/dojo/NodeList.js.uncompressed.js b/lib/dojo/NodeList.js.uncompressed.js deleted file mode 100644 index 680e325..0000000 --- a/lib/dojo/NodeList.js.uncompressed.js +++ /dev/null @@ -1,6 +0,0 @@ -define("dojo/NodeList", ["./query"], function(query){ - // This class is just for documentation purposes, so NodeList shows up well in the API viewer, - // and to simplify writing API doc for all the methods that take NodeList as a parameter, or return a NodeList. - return query.NodeList; -}); - diff --git a/lib/dojo/OpenAjax.js b/lib/dojo/OpenAjax.js deleted file mode 100644 index 0b3c891..0000000 --- a/lib/dojo/OpenAjax.js +++ /dev/null @@ -1,192 +0,0 @@ -/******************************************************************************* - * OpenAjax.js - * - * Reference implementation of the OpenAjax Hub, as specified by OpenAjax Alliance. - * Specification is under development at: - * - * http://www.openajax.org/member/wiki/OpenAjax_Hub_Specification - * - * Copyright 2006-2007 OpenAjax Alliance - * - * Licensed under the Apache License, Version 2.0 (the "License"); you may not - * use this file except in compliance with the License. You may obtain a copy - * of the License at http://www.apache.org/licenses/LICENSE-2.0 . Unless - * required by applicable law or agreed to in writing, software distributed - * under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR - * CONDITIONS OF ANY KIND, either express or implied. See the License for the - * specific language governing permissions and limitations under the License. - * - ******************************************************************************/ - -// prevent re-definition of the OpenAjax object -if(!window["OpenAjax"]){ - OpenAjax = new function(){ - // summary: - // the OpenAjax hub - // description: - // see http://www.openajax.org/member/wiki/OpenAjax_Hub_Specification - - var libs = {}; - var ooh = "org.openajax.hub."; - - var h = {}; - this.hub = h; - h.implementer = "http://openajax.org"; - h.implVersion = "0.6"; - h.specVersion = "0.6"; - h.implExtraData = {}; - h.libraries = libs; - - h.registerLibrary = function(prefix, nsURL, version, extra){ - libs[prefix] = { - prefix: prefix, - namespaceURI: nsURL, - version: version, - extraData: extra - }; - this.publish(ooh+"registerLibrary", libs[prefix]); - }; - h.unregisterLibrary = function(prefix){ - this.publish(ooh+"unregisterLibrary", libs[prefix]); - delete libs[prefix]; - }; - - h._subscriptions = { c:{}, s:[] }; - h._cleanup = []; - h._subIndex = 0; - h._pubDepth = 0; - - h.subscribe = function(name, callback, scope, subscriberData, filter){ - if(!scope){ - scope = window; - } - var handle = name + "." + this._subIndex; - var sub = { scope: scope, cb: callback, fcb: filter, data: subscriberData, sid: this._subIndex++, hdl: handle }; - var path = name.split("."); - this._subscribe(this._subscriptions, path, 0, sub); - return handle; - }; - - h.publish = function(name, message){ - var path = name.split("."); - this._pubDepth++; - this._publish(this._subscriptions, path, 0, name, message); - this._pubDepth--; - if((this._cleanup.length > 0) && (this._pubDepth == 0)){ - for(var i = 0; i < this._cleanup.length; i++){ - this.unsubscribe(this._cleanup[i].hdl); - } - delete(this._cleanup); - this._cleanup = []; - } - }; - - h.unsubscribe = function(sub){ - var path = sub.split("."); - var sid = path.pop(); - this._unsubscribe(this._subscriptions, path, 0, sid); - }; - - h._subscribe = function(tree, path, index, sub){ - var token = path[index]; - if(index == path.length){ - tree.s.push(sub); - }else{ - if(typeof tree.c == "undefined"){ - tree.c = {}; - } - if(typeof tree.c[token] == "undefined"){ - tree.c[token] = { c: {}, s: [] }; - } - this._subscribe(tree.c[token], path, index + 1, sub); - } - }; - - h._publish = function(tree, path, index, name, msg){ - if(typeof tree != "undefined"){ - var node; - if(index == path.length){ - node = tree; - }else{ - this._publish(tree.c[path[index]], path, index + 1, name, msg); - this._publish(tree.c["*"], path, index + 1, name, msg); - node = tree.c["**"]; - } - if(typeof node != "undefined"){ - var callbacks = node.s; - var max = callbacks.length; - for(var i = 0; i < max; i++){ - if(callbacks[i].cb){ - var sc = callbacks[i].scope; - var cb = callbacks[i].cb; - var fcb = callbacks[i].fcb; - var d = callbacks[i].data; - if(typeof cb == "string"){ - // get a function object - cb = sc[cb]; - } - if(typeof fcb == "string"){ - // get a function object - fcb = sc[fcb]; - } - if((!fcb) || - (fcb.call(sc, name, msg, d))){ - cb.call(sc, name, msg, d); - } - } - } - } - } - }; - - h._unsubscribe = function(tree, path, index, sid){ - if(typeof tree != "undefined"){ - if(index < path.length){ - var childNode = tree.c[path[index]]; - this._unsubscribe(childNode, path, index + 1, sid); - if(childNode.s.length == 0){ - for(var x in childNode.c) - return; - delete tree.c[path[index]]; - } - return; - } - else{ - var callbacks = tree.s; - var max = callbacks.length; - for(var i = 0; i < max; i++){ - if(sid == callbacks[i].sid){ - if(this._pubDepth > 0){ - callbacks[i].cb = null; - this._cleanup.push(callbacks[i]); - } - else - callbacks.splice(i, 1); - return; - } - } - } - } - }; - - // The following function is provided for automatic testing purposes. - // It is not expected to be deployed in run-time OpenAjax Hub implementations. - h.reinit = function(){ - for (var lib in OpenAjax.hub.libraries){ - delete OpenAjax.hub.libraries[lib]; - } - OpenAjax.hub.registerLibrary("OpenAjax", "http://openajax.org/hub", "0.6", {}); - - delete OpenAjax._subscriptions; - OpenAjax._subscriptions = {c:{},s:[]}; - delete OpenAjax._cleanup; - OpenAjax._cleanup = []; - OpenAjax._subIndex = 0; - OpenAjax._pubDepth = 0; - }; - }; - - // Register the OpenAjax Hub itself as a library. - OpenAjax.hub.registerLibrary("OpenAjax", "http://openajax.org/hub", "0.6", {}); - -} diff --git a/lib/dojo/README.md b/lib/dojo/README.md deleted file mode 100644 index 5eb5ac3..0000000 --- a/lib/dojo/README.md +++ /dev/null @@ -1,31 +0,0 @@ -# dojo - -**dojo** is the foundation package of the Dojo Toolkit. Sometimes referred to as the “core”, it contains the most -generally applicable sub-packages and modules. The dojo package covers a wide range of functionality like AJAX, DOM -manipulation, class-type programming, events, promises, data stores, drag-and-drop and internationalization libraries. - -## Installing - -Installation instructions are available at [dojotoolkit.org/download][download]. - -## Getting Started - -If you are starting out with Dojo, the following resources are available to you: - -* [Tutorials][] -* [Reference Guide][] -* [API Documentation][] -* [Community Forum][] - -## License and Copyright - -The Dojo Toolkit (including this package) is dual licensed under BSD 3-Clause and AFL. For more information on the -license please see the [License Information][]. The Dojo Toolkit is Copyright (c) 2005-2013, The Dojo Foundation. All -rights reserved. - -[download]: http://dojotoolkit.org/download/ -[Tutorials]: http://dojotoolkit.org/documentation/ -[Reference Guide]: http://dojotoolkit.org/reference-guide/ -[API Documentation]: http://dojotoolkit.org/api/ -[Community Forum]: http://dojotoolkit.org/community/ -[License Information]: http://dojotoolkit.org/license \ No newline at end of file diff --git a/lib/dojo/Stateful.js b/lib/dojo/Stateful.js deleted file mode 100644 index cee48d0..0000000 --- a/lib/dojo/Stateful.js +++ /dev/null @@ -1,91 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/Stateful",["./_base/declare","./_base/lang","./_base/array","./when"],function(_1,_2,_3,_4){ -return _1("dojo.Stateful",null,{_attrPairNames:{},_getAttrNames:function(_5){ -var _6=this._attrPairNames; -if(_6[_5]){ -return _6[_5]; -} -return (_6[_5]={s:"_"+_5+"Setter",g:"_"+_5+"Getter"}); -},postscript:function(_7){ -if(_7){ -this.set(_7); -} -},_get:function(_8,_9){ -return typeof this[_9.g]==="function"?this[_9.g]():this[_8]; -},get:function(_a){ -return this._get(_a,this._getAttrNames(_a)); -},set:function(_b,_c){ -if(typeof _b==="object"){ -for(var x in _b){ -if(_b.hasOwnProperty(x)&&x!="_watchCallbacks"){ -this.set(x,_b[x]); -} -} -return this; -} -var _d=this._getAttrNames(_b),_e=this._get(_b,_d),_f=this[_d.s],_10; -if(typeof _f==="function"){ -_10=_f.apply(this,Array.prototype.slice.call(arguments,1)); -}else{ -this[_b]=_c; -} -if(this._watchCallbacks){ -var _11=this; -_4(_10,function(){ -_11._watchCallbacks(_b,_e,_c); -}); -} -return this; -},_changeAttrValue:function(_12,_13){ -var _14=this.get(_12); -this[_12]=_13; -if(this._watchCallbacks){ -this._watchCallbacks(_12,_14,_13); -} -return this; -},watch:function(_15,_16){ -var _17=this._watchCallbacks; -if(!_17){ -var _18=this; -_17=this._watchCallbacks=function(_19,_1a,_1b,_1c){ -var _1d=function(_1e){ -if(_1e){ -_1e=_1e.slice(); -for(var i=0,l=_1e.length;i-1){ -_1f.splice(_21,1); -} -}; -return _20; -}}); -}); diff --git a/lib/dojo/Stateful.js.uncompressed.js b/lib/dojo/Stateful.js.uncompressed.js deleted file mode 100644 index ad8cbb6..0000000 --- a/lib/dojo/Stateful.js.uncompressed.js +++ /dev/null @@ -1,218 +0,0 @@ -define("dojo/Stateful", ["./_base/declare", "./_base/lang", "./_base/array", "./when"], function(declare, lang, array, when){ - // module: - // dojo/Stateful - -return declare("dojo.Stateful", null, { - // summary: - // Base class for objects that provide named properties with optional getter/setter - // control and the ability to watch for property changes - // - // The class also provides the functionality to auto-magically manage getters - // and setters for object attributes/properties. - // - // Getters and Setters should follow the format of _xxxGetter or _xxxSetter where - // the xxx is a name of the attribute to handle. So an attribute of "foo" - // would have a custom getter of _fooGetter and a custom setter of _fooSetter. - // - // example: - // | require(["dojo/Stateful", function(Stateful) { - // | var obj = new Stateful(); - // | obj.watch("foo", function(){ - // | console.log("foo changed to " + this.get("foo")); - // | }); - // | obj.set("foo","bar"); - // | }); - - // _attrPairNames: Hash - // Used across all instances a hash to cache attribute names and their getter - // and setter names. - _attrPairNames: {}, - - _getAttrNames: function(name){ - // summary: - // Helper function for get() and set(). - // Caches attribute name values so we don't do the string ops every time. - // tags: - // private - - var apn = this._attrPairNames; - if(apn[name]){ return apn[name]; } - return (apn[name] = { - s: "_" + name + "Setter", - g: "_" + name + "Getter" - }); - }, - - postscript: function(/*Object?*/ params){ - // Automatic setting of params during construction - if (params){ this.set(params); } - }, - - _get: function(name, names){ - // summary: - // Private function that does a get based off a hash of names - // names: - // Hash of names of custom attributes - return typeof this[names.g] === "function" ? this[names.g]() : this[name]; - }, - get: function(/*String*/name){ - // summary: - // Get a property on a Stateful instance. - // name: - // The property to get. - // returns: - // The property value on this Stateful instance. - // description: - // Get a named property on a Stateful object. The property may - // potentially be retrieved via a getter method in subclasses. In the base class - // this just retrieves the object's property. - // example: - // | require(["dojo/Stateful", function(Stateful) { - // | var stateful = new Stateful({foo: 3}); - // | stateful.get("foo") // returns 3 - // | stateful.foo // returns 3 - // | }); - - return this._get(name, this._getAttrNames(name)); //Any - }, - set: function(/*String*/name, /*Object*/value){ - // summary: - // Set a property on a Stateful instance - // name: - // The property to set. - // value: - // The value to set in the property. - // returns: - // The function returns this dojo.Stateful instance. - // description: - // Sets named properties on a stateful object and notifies any watchers of - // the property. A programmatic setter may be defined in subclasses. - // example: - // | require(["dojo/Stateful", function(Stateful) { - // | var stateful = new Stateful(); - // | stateful.watch(function(name, oldValue, value){ - // | // this will be called on the set below - // | } - // | stateful.set(foo, 5); - // set() may also be called with a hash of name/value pairs, ex: - // | stateful.set({ - // | foo: "Howdy", - // | bar: 3 - // | }); - // | }); - // This is equivalent to calling set(foo, "Howdy") and set(bar, 3) - - // If an object is used, iterate through object - if(typeof name === "object"){ - for(var x in name){ - if(name.hasOwnProperty(x) && x !="_watchCallbacks"){ - this.set(x, name[x]); - } - } - return this; - } - - var names = this._getAttrNames(name), - oldValue = this._get(name, names), - setter = this[names.s], - result; - if(typeof setter === "function"){ - // use the explicit setter - result = setter.apply(this, Array.prototype.slice.call(arguments, 1)); - }else{ - // no setter so set attribute directly - this[name] = value; - } - if(this._watchCallbacks){ - var self = this; - // If setter returned a promise, wait for it to complete, otherwise call watches immediately - when(result, function(){ - self._watchCallbacks(name, oldValue, value); - }); - } - return this; // dojo/Stateful - }, - _changeAttrValue: function(name, value){ - // summary: - // Internal helper for directly changing an attribute value. - // - // name: String - // The property to set. - // value: Mixed - // The value to set in the property. - // - // description: - // Directly change the value of an attribute on an object, bypassing any - // accessor setter. Also handles the calling of watch and emitting events. - // It is designed to be used by descendant class when there are two values - // of attributes that are linked, but calling .set() is not appropriate. - - var oldValue = this.get(name); - this[name] = value; - if(this._watchCallbacks){ - this._watchCallbacks(name, oldValue, value); - } - return this; // dojo/Stateful - }, - watch: function(/*String?*/name, /*Function*/callback){ - // summary: - // Watches a property for changes - // name: - // Indicates the property to watch. This is optional (the callback may be the - // only parameter), and if omitted, all the properties will be watched - // returns: - // An object handle for the watch. The unwatch method of this object - // can be used to discontinue watching this property: - // | var watchHandle = obj.watch("foo", callback); - // | watchHandle.unwatch(); // callback won't be called now - // callback: - // The function to execute when the property changes. This will be called after - // the property has been changed. The callback will be called with the |this| - // set to the instance, the first argument as the name of the property, the - // second argument as the old value and the third argument as the new value. - - var callbacks = this._watchCallbacks; - if(!callbacks){ - var self = this; - callbacks = this._watchCallbacks = function(name, oldValue, value, ignoreCatchall){ - var notify = function(propertyCallbacks){ - if(propertyCallbacks){ - propertyCallbacks = propertyCallbacks.slice(); - for(var i = 0, l = propertyCallbacks.length; i < l; i++){ - propertyCallbacks[i].call(self, name, oldValue, value); - } - } - }; - notify(callbacks['_' + name]); - if(!ignoreCatchall){ - notify(callbacks["*"]); // the catch-all - } - }; // we use a function instead of an object so it will be ignored by JSON conversion - } - if(!callback && typeof name === "function"){ - callback = name; - name = "*"; - }else{ - // prepend with dash to prevent name conflicts with function (like "name" property) - name = '_' + name; - } - var propertyCallbacks = callbacks[name]; - if(typeof propertyCallbacks !== "object"){ - propertyCallbacks = callbacks[name] = []; - } - propertyCallbacks.push(callback); - - // TODO: Remove unwatch in 2.0 - var handle = {}; - handle.unwatch = handle.remove = function(){ - var index = array.indexOf(propertyCallbacks, callback); - if(index > -1){ - propertyCallbacks.splice(index, 1); - } - }; - return handle; //Object - } - -}); - -}); diff --git a/lib/dojo/_base/Color.js b/lib/dojo/_base/Color.js deleted file mode 100644 index e16aeb1..0000000 --- a/lib/dojo/_base/Color.js +++ /dev/null @@ -1,96 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/_base/Color",["./kernel","./lang","./array","./config"],function(_1,_2,_3,_4){ -var _5=_1.Color=function(_6){ -if(_6){ -this.setColor(_6); -} -}; -_5.named={"black":[0,0,0],"silver":[192,192,192],"gray":[128,128,128],"white":[255,255,255],"maroon":[128,0,0],"red":[255,0,0],"purple":[128,0,128],"fuchsia":[255,0,255],"green":[0,128,0],"lime":[0,255,0],"olive":[128,128,0],"yellow":[255,255,0],"navy":[0,0,128],"blue":[0,0,255],"teal":[0,128,128],"aqua":[0,255,255],"transparent":_4.transparentColor||[0,0,0,0]}; -_2.extend(_5,{r:255,g:255,b:255,a:1,_set:function(r,g,b,a){ -var t=this; -t.r=r; -t.g=g; -t.b=b; -t.a=a; -},setColor:function(_7){ -if(_2.isString(_7)){ -_5.fromString(_7,this); -}else{ -if(_2.isArray(_7)){ -_5.fromArray(_7,this); -}else{ -this._set(_7.r,_7.g,_7.b,_7.a); -if(!(_7 instanceof _5)){ -this.sanitize(); -} -} -} -return this; -},sanitize:function(){ -return this; -},toRgb:function(){ -var t=this; -return [t.r,t.g,t.b]; -},toRgba:function(){ -var t=this; -return [t.r,t.g,t.b,t.a]; -},toHex:function(){ -var _8=_3.map(["r","g","b"],function(x){ -var s=this[x].toString(16); -return s.length<2?"0"+s:s; -},this); -return "#"+_8.join(""); -},toCss:function(_9){ -var t=this,_a=t.r+", "+t.g+", "+t.b; -return (_9?"rgba("+_a+", "+t.a:"rgb("+_a)+")"; -},toString:function(){ -return this.toCss(true); -}}); -_5.blendColors=_1.blendColors=function(_b,_c,_d,_e){ -var t=_e||new _5(); -_3.forEach(["r","g","b","a"],function(x){ -t[x]=_b[x]+(_c[x]-_b[x])*_d; -if(x!="a"){ -t[x]=Math.round(t[x]); -} -}); -return t.sanitize(); -}; -_5.fromRgb=_1.colorFromRgb=function(_f,obj){ -var m=_f.toLowerCase().match(/^rgba?\(([\s\.,0-9]+)\)/); -return m&&_5.fromArray(m[1].split(/\s*,\s*/),obj); -}; -_5.fromHex=_1.colorFromHex=function(_10,obj){ -var t=obj||new _5(),_11=(_10.length==4)?4:8,_12=(1<<_11)-1; -_10=Number("0x"+_10.substr(1)); -if(isNaN(_10)){ -return null; -} -_3.forEach(["b","g","r"],function(x){ -var c=_10&_12; -_10>>=_11; -t[x]=_11==4?17*c:c; -}); -t.a=1; -return t; -}; -_5.fromArray=_1.colorFromArray=function(a,obj){ -var t=obj||new _5(); -t._set(Number(a[0]),Number(a[1]),Number(a[2]),Number(a[3])); -if(isNaN(t.a)){ -t.a=1; -} -return t.sanitize(); -}; -_5.fromString=_1.colorFromString=function(str,obj){ -var a=_5.named[str]; -return a&&_5.fromArray(a,obj)||_5.fromRgb(str,obj)||_5.fromHex(str,obj); -}; -return _5; -}); diff --git a/lib/dojo/_base/Color.js.uncompressed.js b/lib/dojo/_base/Color.js.uncompressed.js deleted file mode 100644 index 52eeb63..0000000 --- a/lib/dojo/_base/Color.js.uncompressed.js +++ /dev/null @@ -1,229 +0,0 @@ -define("dojo/_base/Color", ["./kernel", "./lang", "./array", "./config"], function(dojo, lang, ArrayUtil, config){ - - var Color = dojo.Color = function(/*Array|String|Object*/ color){ - // summary: - // Takes a named string, hex string, array of rgb or rgba values, - // an object with r, g, b, and a properties, or another `Color` object - // and creates a new Color instance to work from. - // - // example: - // Work with a Color instance: - // | require(["dojo/_base/color"], function(Color){ - // | var c = new Color(); - // | c.setColor([0,0,0]); // black - // | var hex = c.toHex(); // #000000 - // | }); - // - // example: - // Work with a node's color: - // | - // | require(["dojo/_base/color", "dojo/dom-style"], function(Color, domStyle){ - // | var color = domStyle("someNode", "backgroundColor"); - // | var n = new Color(color); - // | // adjust the color some - // | n.r *= .5; - // | console.log(n.toString()); // rgb(128, 255, 255); - // | }); - if(color){ this.setColor(color); } - }; - - // FIXME: - // there's got to be a more space-efficient way to encode or discover - // these!! Use hex? - Color.named = { - // summary: - // Dictionary list of all CSS named colors, by name. Values are 3-item arrays with corresponding RG and B values. - "black": [0,0,0], - "silver": [192,192,192], - "gray": [128,128,128], - "white": [255,255,255], - "maroon": [128,0,0], - "red": [255,0,0], - "purple": [128,0,128], - "fuchsia":[255,0,255], - "green": [0,128,0], - "lime": [0,255,0], - "olive": [128,128,0], - "yellow": [255,255,0], - "navy": [0,0,128], - "blue": [0,0,255], - "teal": [0,128,128], - "aqua": [0,255,255], - "transparent": config.transparentColor || [0,0,0,0] - }; - - lang.extend(Color, { - r: 255, g: 255, b: 255, a: 1, - _set: function(r, g, b, a){ - var t = this; t.r = r; t.g = g; t.b = b; t.a = a; - }, - setColor: function(/*Array|String|Object*/ color){ - // summary: - // Takes a named string, hex string, array of rgb or rgba values, - // an object with r, g, b, and a properties, or another `Color` object - // and sets this color instance to that value. - // - // example: - // | require(["dojo/_base/color"], function(Color){ - // | var c = new Color(); // no color - // | c.setColor("#ededed"); // greyish - // | }); - if(lang.isString(color)){ - Color.fromString(color, this); - }else if(lang.isArray(color)){ - Color.fromArray(color, this); - }else{ - this._set(color.r, color.g, color.b, color.a); - if(!(color instanceof Color)){ this.sanitize(); } - } - return this; // Color - }, - sanitize: function(){ - // summary: - // Ensures the object has correct attributes - // description: - // the default implementation does nothing, include dojo.colors to - // augment it with real checks - return this; // Color - }, - toRgb: function(){ - // summary: - // Returns 3 component array of rgb values - // example: - // | require(["dojo/_base/color"], function(Color){ - // | var c = new Color("#000000"); - // | console.log(c.toRgb()); // [0,0,0] - // | }); - var t = this; - return [t.r, t.g, t.b]; // Array - }, - toRgba: function(){ - // summary: - // Returns a 4 component array of rgba values from the color - // represented by this object. - var t = this; - return [t.r, t.g, t.b, t.a]; // Array - }, - toHex: function(){ - // summary: - // Returns a CSS color string in hexadecimal representation - // example: - // | require(["dojo/_base/color"], function(Color){ - // | console.log(new Color([0,0,0]).toHex()); // #000000 - // | }); - var arr = ArrayUtil.map(["r", "g", "b"], function(x){ - var s = this[x].toString(16); - return s.length < 2 ? "0" + s : s; - }, this); - return "#" + arr.join(""); // String - }, - toCss: function(/*Boolean?*/ includeAlpha){ - // summary: - // Returns a css color string in rgb(a) representation - // example: - // | require(["dojo/_base/color"], function(Color){ - // | var c = new Color("#FFF").toCss(); - // | console.log(c); // rgb('255','255','255') - // | }); - var t = this, rgb = t.r + ", " + t.g + ", " + t.b; - return (includeAlpha ? "rgba(" + rgb + ", " + t.a : "rgb(" + rgb) + ")"; // String - }, - toString: function(){ - // summary: - // Returns a visual representation of the color - return this.toCss(true); // String - } - }); - - Color.blendColors = dojo.blendColors = function( - /*Color*/ start, - /*Color*/ end, - /*Number*/ weight, - /*Color?*/ obj - ){ - // summary: - // Blend colors end and start with weight from 0 to 1, 0.5 being a 50/50 blend, - // can reuse a previously allocated Color object for the result - var t = obj || new Color(); - ArrayUtil.forEach(["r", "g", "b", "a"], function(x){ - t[x] = start[x] + (end[x] - start[x]) * weight; - if(x != "a"){ t[x] = Math.round(t[x]); } - }); - return t.sanitize(); // Color - }; - - Color.fromRgb = dojo.colorFromRgb = function(/*String*/ color, /*Color?*/ obj){ - // summary: - // Returns a `Color` instance from a string of the form - // "rgb(...)" or "rgba(...)". Optionally accepts a `Color` - // object to update with the parsed value and return instead of - // creating a new object. - // returns: - // A Color object. If obj is passed, it will be the return value. - var m = color.toLowerCase().match(/^rgba?\(([\s\.,0-9]+)\)/); - return m && Color.fromArray(m[1].split(/\s*,\s*/), obj); // Color - }; - - Color.fromHex = dojo.colorFromHex = function(/*String*/ color, /*Color?*/ obj){ - // summary: - // Converts a hex string with a '#' prefix to a color object. - // Supports 12-bit #rgb shorthand. Optionally accepts a - // `Color` object to update with the parsed value. - // - // returns: - // A Color object. If obj is passed, it will be the return value. - // - // example: - // | require(["dojo/_base/color"], function(Color){ - // | var thing = new Color().fromHex("#ededed"); // grey, longhand - // | var thing2 = new Color().fromHex("#000"); // black, shorthand - // | }); - var t = obj || new Color(), - bits = (color.length == 4) ? 4 : 8, - mask = (1 << bits) - 1; - color = Number("0x" + color.substr(1)); - if(isNaN(color)){ - return null; // Color - } - ArrayUtil.forEach(["b", "g", "r"], function(x){ - var c = color & mask; - color >>= bits; - t[x] = bits == 4 ? 17 * c : c; - }); - t.a = 1; - return t; // Color - }; - - Color.fromArray = dojo.colorFromArray = function(/*Array*/ a, /*Color?*/ obj){ - // summary: - // Builds a `Color` from a 3 or 4 element array, mapping each - // element in sequence to the rgb(a) values of the color. - // example: - // | require(["dojo/_base/color"], function(Color){ - // | var myColor = new Color().fromArray([237,237,237,0.5]); // grey, 50% alpha - // | }); - // returns: - // A Color object. If obj is passed, it will be the return value. - var t = obj || new Color(); - t._set(Number(a[0]), Number(a[1]), Number(a[2]), Number(a[3])); - if(isNaN(t.a)){ t.a = 1; } - return t.sanitize(); // Color - }; - - Color.fromString = dojo.colorFromString = function(/*String*/ str, /*Color?*/ obj){ - // summary: - // Parses `str` for a color value. Accepts hex, rgb, and rgba - // style color values. - // description: - // Acceptable input values for str may include arrays of any form - // accepted by dojo.colorFromArray, hex strings such as "#aaaaaa", or - // rgb or rgba strings such as "rgb(133, 200, 16)" or "rgba(10, 10, - // 10, 50)" - // returns: - // A Color object. If obj is passed, it will be the return value. - var a = Color.named[str]; - return a && Color.fromArray(a, obj) || Color.fromRgb(str, obj) || Color.fromHex(str, obj); // Color - }; - - return Color; -}); diff --git a/lib/dojo/_base/Deferred.js b/lib/dojo/_base/Deferred.js deleted file mode 100644 index 6d7b2d5..0000000 --- a/lib/dojo/_base/Deferred.js +++ /dev/null @@ -1,142 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/_base/Deferred",["./kernel","../Deferred","../promise/Promise","../errors/CancelError","../has","./lang","../when"],function(_1,_2,_3,_4,_5,_6,_7){ -var _8=function(){ -}; -var _9=Object.freeze||function(){ -}; -var _a=_1.Deferred=function(_b){ -var _c,_d,_e,_f,_10,_11,_12; -var _13=(this.promise=new _3()); -function _14(_15){ -if(_d){ -throw new Error("This deferred has already been resolved"); -} -_c=_15; -_d=true; -_16(); -}; -function _16(){ -var _17; -while(!_17&&_12){ -var _18=_12; -_12=_12.next; -if((_17=(_18.progress==_8))){ -_d=false; -} -var _19=(_10?_18.error:_18.resolved); -if(_5("config-useDeferredInstrumentation")){ -if(_10&&_2.instrumentRejected){ -_2.instrumentRejected(_c,!!_19); -} -} -if(_19){ -try{ -var _1a=_19(_c); -if(_1a&&typeof _1a.then==="function"){ -_1a.then(_6.hitch(_18.deferred,"resolve"),_6.hitch(_18.deferred,"reject"),_6.hitch(_18.deferred,"progress")); -continue; -} -var _1b=_17&&_1a===undefined; -if(_17&&!_1b){ -_10=_1a instanceof Error; -} -_18.deferred[_1b&&_10?"reject":"resolve"](_1b?_c:_1a); -} -catch(e){ -_18.deferred.reject(e); -} -}else{ -if(_10){ -_18.deferred.reject(_c); -}else{ -_18.deferred.resolve(_c); -} -} -} -}; -this.isResolved=_13.isResolved=function(){ -return _f==0; -}; -this.isRejected=_13.isRejected=function(){ -return _f==1; -}; -this.isFulfilled=_13.isFulfilled=function(){ -return _f>=0; -}; -this.isCanceled=_13.isCanceled=function(){ -return _e; -}; -this.resolve=this.callback=function(_1c){ -this.fired=_f=0; -this.results=[_1c,null]; -_14(_1c); -}; -this.reject=this.errback=function(_1d){ -_10=true; -this.fired=_f=1; -if(_5("config-useDeferredInstrumentation")){ -if(_2.instrumentRejected){ -_2.instrumentRejected(_1d,!!_12); -} -} -_14(_1d); -this.results=[null,_1d]; -}; -this.progress=function(_1e){ -var _1f=_12; -while(_1f){ -var _20=_1f.progress; -_20&&_20(_1e); -_1f=_1f.next; -} -}; -this.addCallbacks=function(_21,_22){ -this.then(_21,_22,_8); -return this; -}; -_13.then=this.then=function(_23,_24,_25){ -var _26=_25==_8?this:new _a(_13.cancel); -var _27={resolved:_23,error:_24,progress:_25,deferred:_26}; -if(_12){ -_11=_11.next=_27; -}else{ -_12=_11=_27; -} -if(_d){ -_16(); -} -return _26.promise; -}; -var _28=this; -_13.cancel=this.cancel=function(){ -if(!_d){ -var _29=_b&&_b(_28); -if(!_d){ -if(!(_29 instanceof Error)){ -_29=new _4(_29); -} -_29.log=false; -_28.reject(_29); -} -} -_e=true; -}; -_9(_13); -}; -_6.extend(_a,{addCallback:function(_2a){ -return this.addCallbacks(_6.hitch.apply(_1,arguments)); -},addErrback:function(_2b){ -return this.addCallbacks(null,_6.hitch.apply(_1,arguments)); -},addBoth:function(_2c){ -var _2d=_6.hitch.apply(_1,arguments); -return this.addCallbacks(_2d,_2d); -},fired:-1}); -_a.when=_1.when=_7; -return _a; -}); diff --git a/lib/dojo/_base/Deferred.js.uncompressed.js b/lib/dojo/_base/Deferred.js.uncompressed.js deleted file mode 100644 index 45800cf..0000000 --- a/lib/dojo/_base/Deferred.js.uncompressed.js +++ /dev/null @@ -1,383 +0,0 @@ -define("dojo/_base/Deferred", [ - "./kernel", - "../Deferred", - "../promise/Promise", - "../errors/CancelError", - "../has", - "./lang", - "../when" -], function(dojo, NewDeferred, Promise, CancelError, has, lang, when){ - // module: - // dojo/_base/Deferred - - var mutator = function(){}; - var freeze = Object.freeze || function(){}; - // A deferred provides an API for creating and resolving a promise. - var Deferred = dojo.Deferred = function(/*Function?*/ canceller){ - // summary: - // Deprecated. This module defines the legacy dojo/_base/Deferred API. - // New code should use dojo/Deferred instead. - // description: - // The Deferred API is based on the concept of promises that provide a - // generic interface into the eventual completion of an asynchronous action. - // The motivation for promises fundamentally is about creating a - // separation of concerns that allows one to achieve the same type of - // call patterns and logical data flow in asynchronous code as can be - // achieved in synchronous code. Promises allows one - // to be able to call a function purely with arguments needed for - // execution, without conflating the call with concerns of whether it is - // sync or async. One shouldn't need to alter a call's arguments if the - // implementation switches from sync to async (or vice versa). By having - // async functions return promises, the concerns of making the call are - // separated from the concerns of asynchronous interaction (which are - // handled by the promise). - // - // The Deferred is a type of promise that provides methods for fulfilling the - // promise with a successful result or an error. The most important method for - // working with Dojo's promises is the then() method, which follows the - // CommonJS proposed promise API. An example of using a Dojo promise: - // - // | var resultingPromise = someAsyncOperation.then(function(result){ - // | ... handle result ... - // | }, - // | function(error){ - // | ... handle error ... - // | }); - // - // The .then() call returns a new promise that represents the result of the - // execution of the callback. The callbacks will never affect the original promises value. - // - // The Deferred instances also provide the following functions for backwards compatibility: - // - // - addCallback(handler) - // - addErrback(handler) - // - callback(result) - // - errback(result) - // - // Callbacks are allowed to return promises themselves, so - // you can build complicated sequences of events with ease. - // - // The creator of the Deferred may specify a canceller. The canceller - // is a function that will be called if Deferred.cancel is called - // before the Deferred fires. You can use this to implement clean - // aborting of an XMLHttpRequest, etc. Note that cancel will fire the - // deferred with a CancelledError (unless your canceller returns - // another kind of error), so the errbacks should be prepared to - // handle that error for cancellable Deferreds. - // example: - // | var deferred = new Deferred(); - // | setTimeout(function(){ deferred.callback({success: true}); }, 1000); - // | return deferred; - // example: - // Deferred objects are often used when making code asynchronous. It - // may be easiest to write functions in a synchronous manner and then - // split code using a deferred to trigger a response to a long-lived - // operation. For example, instead of register a callback function to - // denote when a rendering operation completes, the function can - // simply return a deferred: - // - // | // callback style: - // | function renderLotsOfData(data, callback){ - // | var success = false - // | try{ - // | for(var x in data){ - // | renderDataitem(data[x]); - // | } - // | success = true; - // | }catch(e){ } - // | if(callback){ - // | callback(success); - // | } - // | } - // - // | // using callback style - // | renderLotsOfData(someDataObj, function(success){ - // | // handles success or failure - // | if(!success){ - // | promptUserToRecover(); - // | } - // | }); - // | // NOTE: no way to add another callback here!! - // example: - // Using a Deferred doesn't simplify the sending code any, but it - // provides a standard interface for callers and senders alike, - // providing both with a simple way to service multiple callbacks for - // an operation and freeing both sides from worrying about details - // such as "did this get called already?". With Deferreds, new - // callbacks can be added at any time. - // - // | // Deferred style: - // | function renderLotsOfData(data){ - // | var d = new Deferred(); - // | try{ - // | for(var x in data){ - // | renderDataitem(data[x]); - // | } - // | d.callback(true); - // | }catch(e){ - // | d.errback(new Error("rendering failed")); - // | } - // | return d; - // | } - // - // | // using Deferred style - // | renderLotsOfData(someDataObj).then(null, function(){ - // | promptUserToRecover(); - // | }); - // | // NOTE: addErrback and addCallback both return the Deferred - // | // again, so we could chain adding callbacks or save the - // | // deferred for later should we need to be notified again. - // example: - // In this example, renderLotsOfData is synchronous and so both - // versions are pretty artificial. Putting the data display on a - // timeout helps show why Deferreds rock: - // - // | // Deferred style and async func - // | function renderLotsOfData(data){ - // | var d = new Deferred(); - // | setTimeout(function(){ - // | try{ - // | for(var x in data){ - // | renderDataitem(data[x]); - // | } - // | d.callback(true); - // | }catch(e){ - // | d.errback(new Error("rendering failed")); - // | } - // | }, 100); - // | return d; - // | } - // - // | // using Deferred style - // | renderLotsOfData(someDataObj).then(null, function(){ - // | promptUserToRecover(); - // | }); - // - // Note that the caller doesn't have to change his code at all to - // handle the asynchronous case. - - var result, finished, canceled, fired, isError, head, nextListener; - var promise = (this.promise = new Promise()); - - function complete(value){ - if(finished){ - throw new Error("This deferred has already been resolved"); - } - result = value; - finished = true; - notify(); - } - function notify(){ - var mutated; - while(!mutated && nextListener){ - var listener = nextListener; - nextListener = nextListener.next; - if((mutated = (listener.progress == mutator))){ // assignment and check - finished = false; - } - - var func = (isError ? listener.error : listener.resolved); - if(has("config-useDeferredInstrumentation")){ - if(isError && NewDeferred.instrumentRejected){ - NewDeferred.instrumentRejected(result, !!func); - } - } - if(func){ - try{ - var newResult = func(result); - if (newResult && typeof newResult.then === "function"){ - newResult.then(lang.hitch(listener.deferred, "resolve"), lang.hitch(listener.deferred, "reject"), lang.hitch(listener.deferred, "progress")); - continue; - } - var unchanged = mutated && newResult === undefined; - if(mutated && !unchanged){ - isError = newResult instanceof Error; - } - listener.deferred[unchanged && isError ? "reject" : "resolve"](unchanged ? result : newResult); - }catch(e){ - listener.deferred.reject(e); - } - }else{ - if(isError){ - listener.deferred.reject(result); - }else{ - listener.deferred.resolve(result); - } - } - } - } - - this.isResolved = promise.isResolved = function(){ - // summary: - // Checks whether the deferred has been resolved. - // returns: Boolean - - return fired == 0; - }; - - this.isRejected = promise.isRejected = function(){ - // summary: - // Checks whether the deferred has been rejected. - // returns: Boolean - - return fired == 1; - }; - - this.isFulfilled = promise.isFulfilled = function(){ - // summary: - // Checks whether the deferred has been resolved or rejected. - // returns: Boolean - - return fired >= 0; - }; - - this.isCanceled = promise.isCanceled = function(){ - // summary: - // Checks whether the deferred has been canceled. - // returns: Boolean - - return canceled; - }; - - // calling resolve will resolve the promise - this.resolve = this.callback = function(value){ - // summary: - // Fulfills the Deferred instance successfully with the provide value - this.fired = fired = 0; - this.results = [value, null]; - complete(value); - }; - - - // calling error will indicate that the promise failed - this.reject = this.errback = function(error){ - // summary: - // Fulfills the Deferred instance as an error with the provided error - isError = true; - this.fired = fired = 1; - if(has("config-useDeferredInstrumentation")){ - if(NewDeferred.instrumentRejected){ - NewDeferred.instrumentRejected(error, !!nextListener); - } - } - complete(error); - this.results = [null, error]; - }; - // call progress to provide updates on the progress on the completion of the promise - this.progress = function(update){ - // summary: - // Send progress events to all listeners - var listener = nextListener; - while(listener){ - var progress = listener.progress; - progress && progress(update); - listener = listener.next; - } - }; - this.addCallbacks = function(callback, errback){ - // summary: - // Adds callback and error callback for this deferred instance. - // callback: Function? - // The callback attached to this deferred object. - // errback: Function? - // The error callback attached to this deferred object. - // returns: - // Returns this deferred object. - this.then(callback, errback, mutator); - return this; // Deferred - }; - // provide the implementation of the promise - promise.then = this.then = function(/*Function?*/resolvedCallback, /*Function?*/errorCallback, /*Function?*/progressCallback){ - // summary: - // Adds a fulfilledHandler, errorHandler, and progressHandler to be called for - // completion of a promise. The fulfilledHandler is called when the promise - // is fulfilled. The errorHandler is called when a promise fails. The - // progressHandler is called for progress events. All arguments are optional - // and non-function values are ignored. The progressHandler is not only an - // optional argument, but progress events are purely optional. Promise - // providers are not required to ever create progress events. - // - // This function will return a new promise that is fulfilled when the given - // fulfilledHandler or errorHandler callback is finished. This allows promise - // operations to be chained together. The value returned from the callback - // handler is the fulfillment value for the returned promise. If the callback - // throws an error, the returned promise will be moved to failed state. - // - // returns: - // Returns a new promise that represents the result of the - // execution of the callback. The callbacks will never affect the original promises value. - // example: - // An example of using a CommonJS compliant promise: - // | asyncComputeTheAnswerToEverything(). - // | then(addTwo). - // | then(printResult, onError); - // | >44 - // - var returnDeferred = progressCallback == mutator ? this : new Deferred(promise.cancel); - var listener = { - resolved: resolvedCallback, - error: errorCallback, - progress: progressCallback, - deferred: returnDeferred - }; - if(nextListener){ - head = head.next = listener; - } - else{ - nextListener = head = listener; - } - if(finished){ - notify(); - } - return returnDeferred.promise; // Promise - }; - var deferred = this; - promise.cancel = this.cancel = function(){ - // summary: - // Cancels the asynchronous operation - if(!finished){ - var error = canceller && canceller(deferred); - if(!finished){ - if (!(error instanceof Error)){ - error = new CancelError(error); - } - error.log = false; - deferred.reject(error); - } - } - canceled = true; - }; - freeze(promise); - }; - lang.extend(Deferred, { - addCallback: function(/*Function*/ callback){ - // summary: - // Adds successful callback for this deferred instance. - // returns: - // Returns this deferred object. - return this.addCallbacks(lang.hitch.apply(dojo, arguments)); // Deferred - }, - - addErrback: function(/*Function*/ errback){ - // summary: - // Adds error callback for this deferred instance. - // returns: - // Returns this deferred object. - return this.addCallbacks(null, lang.hitch.apply(dojo, arguments)); // Deferred - }, - - addBoth: function(/*Function*/ callback){ - // summary: - // Add handler as both successful callback and error callback for this deferred instance. - // returns: - // Returns this deferred object. - var enclosed = lang.hitch.apply(dojo, arguments); - return this.addCallbacks(enclosed, enclosed); // Deferred - }, - fired: -1 - }); - - Deferred.when = dojo.when = when; - - return Deferred; -}); diff --git a/lib/dojo/_base/NodeList.js b/lib/dojo/_base/NodeList.js deleted file mode 100644 index 4a176ad..0000000 --- a/lib/dojo/_base/NodeList.js +++ /dev/null @@ -1,23 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/_base/NodeList",["./kernel","../query","./array","./html","../NodeList-dom"],function(_1,_2,_3){ -var _4=_2.NodeList,_5=_4.prototype; -_5.connect=_4._adaptAsForEach(function(){ -return _1.connect.apply(this,arguments); -}); -_5.coords=_4._adaptAsMap(_1.coords); -_4.events=["blur","focus","change","click","error","keydown","keypress","keyup","load","mousedown","mouseenter","mouseleave","mousemove","mouseout","mouseover","mouseup","submit"]; -_3.forEach(_4.events,function(_6){ -var _7="on"+_6; -_5[_7]=function(a,b){ -return this.connect(_7,a,b); -}; -}); -_1.NodeList=_4; -return _4; -}); diff --git a/lib/dojo/_base/NodeList.js.uncompressed.js b/lib/dojo/_base/NodeList.js.uncompressed.js deleted file mode 100644 index f9e9070..0000000 --- a/lib/dojo/_base/NodeList.js.uncompressed.js +++ /dev/null @@ -1,110 +0,0 @@ -define("dojo/_base/NodeList", ["./kernel", "../query", "./array", "./html", "../NodeList-dom"], function(dojo, query, array){ - // module: - // dojo/_base/NodeList - - /*===== - return { - // summary: - // This module extends dojo/NodeList with the legacy connect(), coords(), - // blur(), focus(), change(), click(), error(), keydown(), keypress(), - // keyup(), load(), mousedown(), mouseenter(), mouseleave(), mousemove(), - // mouseout(), mouseover(), mouseup(), and submit() methods. - }; - =====*/ - - var NodeList = query.NodeList, - nlp = NodeList.prototype; - - nlp.connect = NodeList._adaptAsForEach(function(){ - // don't bind early to dojo.connect since we no longer explicitly depend on it - return dojo.connect.apply(this, arguments); - }); - /*===== - nlp.connect = function(methodName, objOrFunc, funcName){ - // summary: - // Attach event handlers to every item of the NodeList. Uses dojo.connect() - // so event properties are normalized. - // - // Application must manually require() "dojo/_base/connect" before using this method. - // methodName: String - // the name of the method to attach to. For DOM events, this should be - // the lower-case name of the event - // objOrFunc: Object|Function|String - // if 2 arguments are passed (methodName, objOrFunc), objOrFunc should - // reference a function or be the name of the function in the global - // namespace to attach. If 3 arguments are provided - // (methodName, objOrFunc, funcName), objOrFunc must be the scope to - // locate the bound function in - // funcName: String? - // optional. A string naming the function in objOrFunc to bind to the - // event. May also be a function reference. - // example: - // add an onclick handler to every button on the page - // | query("div:nth-child(odd)").connect("onclick", function(e){ - // | console.log("clicked!"); - // | }); - // example: - // attach foo.bar() to every odd div's onmouseover - // | query("div:nth-child(odd)").connect("onmouseover", foo, "bar"); - - return null; // NodeList - }; - =====*/ - - nlp.coords = NodeList._adaptAsMap(dojo.coords); - /*===== - nlp.coords = function(){ - // summary: - // Deprecated: Use position() for border-box x/y/w/h - // or marginBox() for margin-box w/h/l/t. - // Returns the box objects of all elements in a node list as - // an Array (*not* a NodeList). Acts like `domGeom.coords`, though assumes - // the node passed is each node in this list. - - return []; // Array - }; - =====*/ - - NodeList.events = [ - // summary: - // list of all DOM events used in NodeList - "blur", "focus", "change", "click", "error", "keydown", "keypress", - "keyup", "load", "mousedown", "mouseenter", "mouseleave", "mousemove", - "mouseout", "mouseover", "mouseup", "submit" - ]; - - // FIXME: pseudo-doc the above automatically generated on-event functions - - // syntactic sugar for DOM events - array.forEach(NodeList.events, function(evt){ - var _oe = "on" + evt; - nlp[_oe] = function(a, b){ - return this.connect(_oe, a, b); - }; - // FIXME: should these events trigger publishes? - /* - return (a ? this.connect(_oe, a, b) : - this.forEach(function(n){ - // FIXME: - // listeners get buried by - // addEventListener and can't be dug back - // out to be triggered externally. - // see: - // http://developer.mozilla.org/en/docs/DOM:element - - console.log(n, evt, _oe); - - // FIXME: need synthetic event support! - var _e = { target: n, faux: true, type: evt }; - // dojo._event_listener._synthesizeEvent({}, { target: n, faux: true, type: evt }); - try{ n[evt](_e); }catch(e){ console.log(e); } - try{ n[_oe](_e); }catch(e){ console.log(e); } - }) - ); - */ - } - ); - - dojo.NodeList = NodeList; - return NodeList; -}); diff --git a/lib/dojo/_base/array.js b/lib/dojo/_base/array.js deleted file mode 100644 index 65ac6ec..0000000 --- a/lib/dojo/_base/array.js +++ /dev/null @@ -1,138 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/_base/array",["./kernel","../has","./lang"],function(_1,_2,_3){ -var _4={},u; -function _5(fn){ -return _4[fn]=new Function("item","index","array",fn); -}; -function _6(_7){ -var _8=!_7; -return function(a,fn,o){ -var i=0,l=a&&a.length||0,_9; -if(l&&typeof a=="string"){ -a=a.split(""); -} -if(typeof fn=="string"){ -fn=_4[fn]||_5(fn); -} -if(o){ -for(;i0){ -return _10.lastIndexOf(a,x,_e); -} -var l=a&&a.length||0,end=up?l+_d:_c,i; -if(_e===u){ -i=up?_c:l+_d; -}else{ -if(_e<0){ -i=l+_e; -if(i<0){ -i=_c; -} -}else{ -i=_e>=l?l+_d:_e; -} -} -if(l&&typeof a=="string"){ -a=a.split(""); -} -for(;i!=end;i+=_b){ -if(a[i]==x){ -return i; -} -} -return -1; -}; -}; -var _10={every:_6(false),some:_6(true),indexOf:_a(true),lastIndexOf:_a(false),forEach:function(arr,_11,_12){ -var i=0,l=arr&&arr.length||0; -if(l&&typeof arr=="string"){ -arr=arr.split(""); -} -if(typeof _11=="string"){ -_11=_4[_11]||_5(_11); -} -if(_12){ -for(;i 0){ - // TODO: why do we use a non-standard signature? why do we need "last"? - return array.lastIndexOf(a, x, from); - } - var l = a && a.length || 0, end = up ? l + uOver : lOver, i; - if(from === u){ - i = up ? lOver : l + uOver; - }else{ - if(from < 0){ - i = l + from; - if(i < 0){ - i = lOver; - } - }else{ - i = from >= l ? l + uOver : from; - } - } - if(l && typeof a == "string") a = a.split(""); - for(; i != end; i += delta){ - if(a[i] == x){ - return i; // Number - } - } - return -1; // Number - }; - } - - var array = { - // summary: - // The Javascript v1.6 array extensions. - - every: everyOrSome(false), - /*===== - every: function(arr, callback, thisObject){ - // summary: - // Determines whether or not every item in arr satisfies the - // condition implemented by callback. - // arr: Array|String - // the array to iterate on. If a string, operates on individual characters. - // callback: Function|String - // a function is invoked with three arguments: item, index, - // and array and returns true if the condition is met. - // thisObject: Object? - // may be used to scope the call to callback - // returns: Boolean - // description: - // This function corresponds to the JavaScript 1.6 Array.every() method, with one difference: when - // run over sparse arrays, this implementation passes the "holes" in the sparse array to - // the callback function with a value of undefined. JavaScript 1.6's every skips the holes in the sparse array. - // For more details, see: - // https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Objects/Array/every - // example: - // | // returns false - // | array.every([1, 2, 3, 4], function(item){ return item>1; }); - // example: - // | // returns true - // | array.every([1, 2, 3, 4], function(item){ return item>0; }); - }, - =====*/ - - some: everyOrSome(true), - /*===== - some: function(arr, callback, thisObject){ - // summary: - // Determines whether or not any item in arr satisfies the - // condition implemented by callback. - // arr: Array|String - // the array to iterate over. If a string, operates on individual characters. - // callback: Function|String - // a function is invoked with three arguments: item, index, - // and array and returns true if the condition is met. - // thisObject: Object? - // may be used to scope the call to callback - // returns: Boolean - // description: - // This function corresponds to the JavaScript 1.6 Array.some() method, with one difference: when - // run over sparse arrays, this implementation passes the "holes" in the sparse array to - // the callback function with a value of undefined. JavaScript 1.6's some skips the holes in the sparse array. - // For more details, see: - // https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Objects/Array/some - // example: - // | // is true - // | array.some([1, 2, 3, 4], function(item){ return item>1; }); - // example: - // | // is false - // | array.some([1, 2, 3, 4], function(item){ return item<1; }); - }, - =====*/ - - indexOf: index(true), - /*===== - indexOf: function(arr, value, fromIndex, findLast){ - // summary: - // locates the first index of the provided value in the - // passed array. If the value is not found, -1 is returned. - // description: - // This method corresponds to the JavaScript 1.6 Array.indexOf method, with two differences: - // - // 1. when run over sparse arrays, the Dojo function invokes the callback for every index - // whereas JavaScript 1.6's indexOf skips the holes in the sparse array. - // 2. uses equality (==) rather than strict equality (===) - // - // For details on this method, see: - // https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Objects/Array/indexOf - // arr: Array - // value: Object - // fromIndex: Integer? - // findLast: Boolean? - // Makes indexOf() work like lastIndexOf(). Used internally; not meant for external usage. - // returns: Number - }, - =====*/ - - lastIndexOf: index(false), - /*===== - lastIndexOf: function(arr, value, fromIndex){ - // summary: - // locates the last index of the provided value in the passed - // array. If the value is not found, -1 is returned. - // description: - // This method corresponds to the JavaScript 1.6 Array.lastIndexOf method, with two differences: - // - // 1. when run over sparse arrays, the Dojo function invokes the callback for every index - // whereas JavaScript 1.6's lasIndexOf skips the holes in the sparse array. - // 2. uses equality (==) rather than strict equality (===) - // - // For details on this method, see: - // https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Objects/Array/lastIndexOf - // arr: Array, - // value: Object, - // fromIndex: Integer? - // returns: Number - }, - =====*/ - - forEach: function(arr, callback, thisObject){ - // summary: - // for every item in arr, callback is invoked. Return values are ignored. - // If you want to break out of the loop, consider using array.every() or array.some(). - // forEach does not allow breaking out of the loop over the items in arr. - // arr: - // the array to iterate over. If a string, operates on individual characters. - // callback: - // a function is invoked with three arguments: item, index, and array - // thisObject: - // may be used to scope the call to callback - // description: - // This function corresponds to the JavaScript 1.6 Array.forEach() method, with one difference: when - // run over sparse arrays, this implementation passes the "holes" in the sparse array to - // the callback function with a value of undefined. JavaScript 1.6's forEach skips the holes in the sparse array. - // For more details, see: - // https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Objects/Array/forEach - // example: - // | // log out all members of the array: - // | array.forEach( - // | [ "thinger", "blah", "howdy", 10 ], - // | function(item){ - // | console.log(item); - // | } - // | ); - // example: - // | // log out the members and their indexes - // | array.forEach( - // | [ "thinger", "blah", "howdy", 10 ], - // | function(item, idx, arr){ - // | console.log(item, "at index:", idx); - // | } - // | ); - // example: - // | // use a scoped object member as the callback - // | - // | var obj = { - // | prefix: "logged via obj.callback:", - // | callback: function(item){ - // | console.log(this.prefix, item); - // | } - // | }; - // | - // | // specifying the scope function executes the callback in that scope - // | array.forEach( - // | [ "thinger", "blah", "howdy", 10 ], - // | obj.callback, - // | obj - // | ); - // | - // | // alternately, we can accomplish the same thing with lang.hitch() - // | array.forEach( - // | [ "thinger", "blah", "howdy", 10 ], - // | lang.hitch(obj, "callback") - // | ); - // arr: Array|String - // callback: Function|String - // thisObject: Object? - - var i = 0, l = arr && arr.length || 0; - if(l && typeof arr == "string") arr = arr.split(""); - if(typeof callback == "string") callback = cache[callback] || buildFn(callback); - if(thisObject){ - for(; i < l; ++i){ - callback.call(thisObject, arr[i], i, arr); - } - }else{ - for(; i < l; ++i){ - callback(arr[i], i, arr); - } - } - }, - - map: function(arr, callback, thisObject, Ctr){ - // summary: - // applies callback to each element of arr and returns - // an Array with the results - // arr: Array|String - // the array to iterate on. If a string, operates on - // individual characters. - // callback: Function|String - // a function is invoked with three arguments, (item, index, - // array), and returns a value - // thisObject: Object? - // may be used to scope the call to callback - // returns: Array - // description: - // This function corresponds to the JavaScript 1.6 Array.map() method, with one difference: when - // run over sparse arrays, this implementation passes the "holes" in the sparse array to - // the callback function with a value of undefined. JavaScript 1.6's map skips the holes in the sparse array. - // For more details, see: - // https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Objects/Array/map - // example: - // | // returns [2, 3, 4, 5] - // | array.map([1, 2, 3, 4], function(item){ return item+1 }); - - // TODO: why do we have a non-standard signature here? do we need "Ctr"? - var i = 0, l = arr && arr.length || 0, out = new (Ctr || Array)(l); - if(l && typeof arr == "string") arr = arr.split(""); - if(typeof callback == "string") callback = cache[callback] || buildFn(callback); - if(thisObject){ - for(; i < l; ++i){ - out[i] = callback.call(thisObject, arr[i], i, arr); - } - }else{ - for(; i < l; ++i){ - out[i] = callback(arr[i], i, arr); - } - } - return out; // Array - }, - - filter: function(arr, callback, thisObject){ - // summary: - // Returns a new Array with those items from arr that match the - // condition implemented by callback. - // arr: Array - // the array to iterate over. - // callback: Function|String - // a function that is invoked with three arguments (item, - // index, array). The return of this function is expected to - // be a boolean which determines whether the passed-in item - // will be included in the returned array. - // thisObject: Object? - // may be used to scope the call to callback - // returns: Array - // description: - // This function corresponds to the JavaScript 1.6 Array.filter() method, with one difference: when - // run over sparse arrays, this implementation passes the "holes" in the sparse array to - // the callback function with a value of undefined. JavaScript 1.6's filter skips the holes in the sparse array. - // For more details, see: - // https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Objects/Array/filter - // example: - // | // returns [2, 3, 4] - // | array.filter([1, 2, 3, 4], function(item){ return item>1; }); - - // TODO: do we need "Ctr" here like in map()? - var i = 0, l = arr && arr.length || 0, out = [], value; - if(l && typeof arr == "string") arr = arr.split(""); - if(typeof callback == "string") callback = cache[callback] || buildFn(callback); - if(thisObject){ - for(; i < l; ++i){ - value = arr[i]; - if(callback.call(thisObject, value, i, arr)){ - out.push(value); - } - } - }else{ - for(; i < l; ++i){ - value = arr[i]; - if(callback(value, i, arr)){ - out.push(value); - } - } - } - return out; // Array - }, - - clearCache: function(){ - cache = {}; - } - }; - - - 1 && lang.mixin(dojo, array); - - return array; -}); diff --git a/lib/dojo/_base/browser.js b/lib/dojo/_base/browser.js deleted file mode 100644 index 6ad031c..0000000 --- a/lib/dojo/_base/browser.js +++ /dev/null @@ -1,13 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -if(require.has){ -require.has.add("config-selectorEngine","acme"); -} -define("dojo/_base/browser",["../ready","./kernel","./connect","./unload","./window","./event","./html","./NodeList","../query","./xhr","./fx"],function(_1){ -return _1; -}); diff --git a/lib/dojo/_base/browser.js.uncompressed.js b/lib/dojo/_base/browser.js.uncompressed.js deleted file mode 100644 index 4c607fd..0000000 --- a/lib/dojo/_base/browser.js.uncompressed.js +++ /dev/null @@ -1,28 +0,0 @@ -if(require.has){ - require.has.add("config-selectorEngine", "acme"); -} -define("dojo/_base/browser", [ - "../ready", - "./kernel", - "./connect", // until we decide if connect is going back into non-browser environments - "./unload", - "./window", - "./event", - "./html", - "./NodeList", - "../query", - "./xhr", - "./fx"], function(dojo){ - - // module: - // dojo/_base/browser - - /*===== - return { - // summary: - // This module causes the browser-only base modules to be loaded. - }; - =====*/ - - return dojo; -}); diff --git a/lib/dojo/_base/config.js b/lib/dojo/_base/config.js deleted file mode 100644 index 771a39e..0000000 --- a/lib/dojo/_base/config.js +++ /dev/null @@ -1,32 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/_base/config",["../has","require"],function(_1,_2){ -var _3={}; -if(1){ -var _4=_2.rawConfig,p; -for(p in _4){ -_3[p]=_4[p]; -} -}else{ -var _5=function(_6,_7,_8){ -for(p in _6){ -p!="has"&&_1.add(_7+p,_6[p],0,_8); -} -}; -_3=1?_2.rawConfig:this.dojoConfig||this.djConfig||{}; -_5(_3,"config",1); -_5(_3.has,"",1); -} -if(!_3.locale&&typeof navigator!="undefined"){ -var _9=(navigator.language||navigator.userLanguage); -if(_9){ -_3.locale=_9.toLowerCase(); -} -} -return _3; -}); diff --git a/lib/dojo/_base/config.js.uncompressed.js b/lib/dojo/_base/config.js.uncompressed.js deleted file mode 100644 index def9f69..0000000 --- a/lib/dojo/_base/config.js.uncompressed.js +++ /dev/null @@ -1,196 +0,0 @@ -define("dojo/_base/config", ["../has", "require"], function(has, require){ - // module: - // dojo/_base/config - -/*===== -return { - // summary: - // This module defines the user configuration during bootstrap. - // description: - // By defining user configuration as a module value, an entire configuration can be specified in a build, - // thereby eliminating the need for sniffing and or explicitly setting in the global variable dojoConfig. - // Also, when multiple instances of dojo exist in a single application, each will necessarily be located - // at an unique absolute module identifier as given by the package configuration. Implementing configuration - // as a module allows for specifying unique, per-instance configurations. - // example: - // Create a second instance of dojo with a different, instance-unique configuration (assume the loader and - // dojo.js are already loaded). - // | // specify a configuration that creates a new instance of dojo at the absolute module identifier "myDojo" - // | require({ - // | packages:[{ - // | name:"myDojo", - // | location:".", //assume baseUrl points to dojo.js - // | }] - // | }); - // | - // | // specify a configuration for the myDojo instance - // | define("myDojo/config", { - // | // normal configuration variables go here, e.g., - // | locale:"fr-ca" - // | }); - // | - // | // load and use the new instance of dojo - // | require(["myDojo"], function(dojo){ - // | // dojo is the new instance of dojo - // | // use as required - // | }); - - // isDebug: Boolean - // Defaults to `false`. If set to `true`, ensures that Dojo provides - // extended debugging feedback via Firebug. If Firebug is not available - // on your platform, setting `isDebug` to `true` will force Dojo to - // pull in (and display) the version of Firebug Lite which is - // integrated into the Dojo distribution, thereby always providing a - // debugging/logging console when `isDebug` is enabled. Note that - // Firebug's `console.*` methods are ALWAYS defined by Dojo. If - // `isDebug` is false and you are on a platform without Firebug, these - // methods will be defined as no-ops. - isDebug: false, - - // locale: String - // The locale to assume for loading localized resources in this page, - // specified according to [RFC 3066](http://www.ietf.org/rfc/rfc3066.txt). - // Must be specified entirely in lowercase, e.g. `en-us` and `zh-cn`. - // See the documentation for `dojo.i18n` and `dojo.requireLocalization` - // for details on loading localized resources. If no locale is specified, - // Dojo assumes the locale of the user agent, according to `navigator.userLanguage` - // or `navigator.language` properties. - locale: undefined, - - // extraLocale: Array - // No default value. Specifies additional locales whose - // resources should also be loaded alongside the default locale when - // calls to `dojo.requireLocalization()` are processed. - extraLocale: undefined, - - // baseUrl: String - // The directory in which `dojo.js` is located. Under normal - // conditions, Dojo auto-detects the correct location from which it - // was loaded. You may need to manually configure `baseUrl` in cases - // where you have renamed `dojo.js` or in which `` tags confuse - // some browsers (e.g. IE 6). The variable `dojo.baseUrl` is assigned - // either the value of `djConfig.baseUrl` if one is provided or the - // auto-detected root if not. Other modules are located relative to - // this path. The path should end in a slash. - baseUrl: undefined, - - // modulePaths: [deprecated] Object - // A map of module names to paths relative to `dojo.baseUrl`. The - // key/value pairs correspond directly to the arguments which - // `dojo.registerModulePath` accepts. Specifying - // `djConfig.modulePaths = { "foo": "../../bar" }` is the equivalent - // of calling `dojo.registerModulePath("foo", "../../bar");`. Multiple - // modules may be configured via `djConfig.modulePaths`. - modulePaths: {}, - - // addOnLoad: Function|Array - // Adds a callback via dojo/ready. Useful when Dojo is added after - // the page loads and djConfig.afterOnLoad is true. Supports the same - // arguments as dojo/ready. When using a function reference, use - // `djConfig.addOnLoad = function(){};`. For object with function name use - // `djConfig.addOnLoad = [myObject, "functionName"];` and for object with - // function reference use - // `djConfig.addOnLoad = [myObject, function(){}];` - addOnLoad: null, - - // parseOnLoad: Boolean - // Run the parser after the page is loaded - parseOnLoad: false, - - // require: String[] - // An array of module names to be loaded immediately after dojo.js has been included - // in a page. - require: [], - - // defaultDuration: Number - // Default duration, in milliseconds, for wipe and fade animations within dijits. - // Assigned to dijit.defaultDuration. - defaultDuration: 200, - - // dojoBlankHtmlUrl: String - // Used by some modules to configure an empty iframe. Used by dojo/io/iframe and - // dojo/back, and dijit/popup support in IE where an iframe is needed to make sure native - // controls do not bleed through the popups. Normally this configuration variable - // does not need to be set, except when using cross-domain/CDN Dojo builds. - // Save dojo/resources/blank.html to your domain and set `djConfig.dojoBlankHtmlUrl` - // to the path on your domain your copy of blank.html. - dojoBlankHtmlUrl: undefined, - - // ioPublish: Boolean? - // Set this to true to enable publishing of topics for the different phases of - // IO operations. Publishing is done via dojo/topic.publish(). See dojo/main.__IoPublish for a list - // of topics that are published. - ioPublish: false, - - // useCustomLogger: Anything? - // If set to a value that evaluates to true such as a string or array and - // isDebug is true and Firebug is not available or running, then it bypasses - // the creation of Firebug Lite allowing you to define your own console object. - useCustomLogger: undefined, - - // transparentColor: Array - // Array containing the r, g, b components used as transparent color in dojo.Color; - // if undefined, [255,255,255] (white) will be used. - transparentColor: undefined, - - // deps: Function|Array - // Defines dependencies to be used before the loader has been loaded. - // When provided, they cause the loader to execute require(deps, callback) - // once it has finished loading. Should be used with callback. - deps: undefined, - - // callback: Function|Array - // Defines a callback to be used when dependencies are defined before - // the loader has been loaded. When provided, they cause the loader to - // execute require(deps, callback) once it has finished loading. - // Should be used with deps. - callback: undefined, - - // deferredInstrumentation: Boolean - // Whether deferred instrumentation should be loaded or included - // in builds. - deferredInstrumentation: true, - - // useDeferredInstrumentation: Boolean|String - // Whether the deferred instrumentation should be used. - // - // * `"report-rejections"`: report each rejection as it occurs. - // * `true` or `1` or `"report-unhandled-rejections"`: wait 1 second - // in an attempt to detect unhandled rejections. - useDeferredInstrumentation: "report-unhandled-rejections" -}; -=====*/ - - var result = {}; - if( 1 ){ - // must be the dojo loader; take a shallow copy of require.rawConfig - var src = require.rawConfig, p; - for(p in src){ - result[p] = src[p]; - } - }else{ - var adviseHas = function(featureSet, prefix, booting){ - for(p in featureSet){ - p!="has" && has.add(prefix + p, featureSet[p], 0, booting); - } - }; - result = 1 ? - // must be a built version of the dojo loader; all config stuffed in require.rawConfig - require.rawConfig : - // a foreign loader - this.dojoConfig || this.djConfig || {}; - adviseHas(result, "config", 1); - adviseHas(result.has, "", 1); - } - - if(!result.locale && typeof navigator != "undefined"){ - // Default locale for browsers. - var language = (navigator.language || navigator.userLanguage); - if(language){ - result.locale = language.toLowerCase(); - } - } - - return result; -}); - diff --git a/lib/dojo/_base/configFirefoxExtension.js b/lib/dojo/_base/configFirefoxExtension.js deleted file mode 100644 index 4115c61..0000000 --- a/lib/dojo/_base/configFirefoxExtension.js +++ /dev/null @@ -1,336 +0,0 @@ -// TODO: this file needs to be converted to the v1.7 loader - -// a host environment specifically built for Mozilla extensions, but derived -// from the browser host environment -if(typeof window != 'undefined'){ - dojo.isBrowser = true; - dojo._name = "browser"; - - - // FIXME: PORTME - // http://developer.mozilla.org/en/mozIJSSubScriptLoader - - - // attempt to figure out the path to dojo if it isn't set in the config - (function(){ - // this is a scope protection closure. We set browser versions and grab - // the URL we were loaded from here. - - // FIXME: need to probably use a different reference to "document" to get the hosting XUL environment - - dojo.baseUrl = dojo.config.baseUrl; - - // fill in the rendering support information in dojo.render.* - var n = navigator; - var dua = n.userAgent; - var dav = n.appVersion; - var tv = parseFloat(dav); - - dojo.isMozilla = dojo.isMoz = tv; - if(dojo.isMoz){ - dojo.isFF = parseFloat(dua.split("Firefox/")[1]) || undefined; - } - - // FIXME - dojo.isQuirks = document.compatMode == "BackCompat"; - - // FIXME - // TODO: is the HTML LANG attribute relevant? - dojo.locale = dojo.config.locale || n.language.toLowerCase(); - - dojo._xhrObj = function(){ - return new XMLHttpRequest(); - }; - - // monkey-patch _loadUri to handle file://, chrome://, and resource:// url's - var oldLoadUri = dojo._loadUri; - dojo._loadUri = function(uri, cb){ - var handleLocal = ["file:", "chrome:", "resource:"].some(function(prefix){ - return String(uri).indexOf(prefix) == 0; - }); - if(handleLocal){ - // see: - // http://developer.mozilla.org/en/mozIJSSubScriptLoader - var l = Components.classes["@mozilla.org/moz/jssubscript-loader;1"] - .getService(Components.interfaces.mozIJSSubScriptLoader); - var value = l.loadSubScript(uri, dojo.global); - if(cb){ cb(value); } - return true; - }else{ - // otherwise, call the pre-existing version - return oldLoadUri.apply(dojo, arguments); - } - }; - - // FIXME: PORTME - dojo._isDocumentOk = function(http){ - var stat = http.status || 0; - return (stat >= 200 && stat < 300) || // Boolean - stat == 304 || // allow any 2XX response code - stat == 1223 || // get it out of the cache - (!stat && (location.protocol == "file:" || location.protocol == "chrome:") ); - }; - - // FIXME: PORTME - // var owloc = window.location+""; - // var base = document.getElementsByTagName("base"); - // var hasBase = (base && base.length > 0); - var hasBase = false; - - dojo._getText = function(/*URI*/ uri, /*Boolean*/ fail_ok){ - // summary: - // Read the contents of the specified uri and return those contents. - // uri: - // A relative or absolute uri. If absolute, it still must be in - // the same "domain" as we are. - // fail_ok: - // Default false. If fail_ok and loading fails, return null - // instead of throwing. - // returns: - // The response text. null is returned when there is a - // failure and failure is okay (an exception otherwise) - - // alert("_getText: " + uri); - - // NOTE: must be declared before scope switches ie. this._xhrObj() - var http = dojo._xhrObj(); - - if(!hasBase && dojo._Url){ - uri = (new dojo._Url(uri)).toString(); - } - if(dojo.config.cacheBust){ - //Make sure we have a string before string methods are used on uri - uri += ""; - uri += (uri.indexOf("?") == -1 ? "?" : "&") + String(dojo.config.cacheBust).replace(/\W+/g, ""); - } - var handleLocal = ["file:", "chrome:", "resource:"].some(function(prefix){ - return String(uri).indexOf(prefix) == 0; - }); - if(handleLocal){ - // see: - // http://forums.mozillazine.org/viewtopic.php?p=921150#921150 - var ioService = Components.classes["@mozilla.org/network/io-service;1"] - .getService(Components.interfaces.nsIIOService); - var scriptableStream = Components - .classes["@mozilla.org/scriptableinputstream;1"] - .getService(Components.interfaces.nsIScriptableInputStream); - - var channel = ioService.newChannel(uri, null, null); - var input = channel.open(); - scriptableStream.init(input); - var str = scriptableStream.read(input.available()); - scriptableStream.close(); - input.close(); - return str; - }else{ - http.open('GET', uri, false); - try{ - http.send(null); - // alert(http); - if(!dojo._isDocumentOk(http)){ - var err = Error("Unable to load " + uri + " status:" + http.status); - err.status = http.status; - err.responseText = http.responseText; - throw err; - } - }catch(e){ - if(fail_ok){ - return null; - } // null - // rethrow the exception - throw e; - } - return http.responseText; // String - } - }; - - dojo._windowUnloaders = []; - - // FIXME: PORTME - dojo.windowUnloaded = function(){ - // summary: - // signal fired by impending window destruction. You may use - // dojo.addOnWIndowUnload() or dojo.connect() to this method to perform - // page/application cleanup methods. See dojo.addOnWindowUnload for more info. - var mll = dojo._windowUnloaders; - while(mll.length){ - (mll.pop())(); - } - }; - - // FIXME: PORTME - dojo.addOnWindowUnload = function(/*Object?*/obj, /*String|Function?*/functionName){ - // summary: - // registers a function to be triggered when window.onunload fires. - // Be careful trying to modify the DOM or access JavaScript properties - // during this phase of page unloading: they may not always be available. - // Consider dojo.addOnUnload() if you need to modify the DOM or do heavy - // JavaScript work. - // example: - // | dojo.addOnWindowUnload(functionPointer) - // | dojo.addOnWindowUnload(object, "functionName") - // | dojo.addOnWindowUnload(object, function(){ /* ... */}); - - dojo._onto(dojo._windowUnloaders, obj, functionName); - }; - - // XUL specific APIs - var contexts = []; - var current = null; - dojo._defaultContext = [ window, document ]; - - dojo.pushContext = function(/*Object|String?*/g, /*MDocumentElement?*/d){ - // summary: - // causes subsequent calls to Dojo methods to assume the - // passed object and, optionally, document as the default - // scopes to use. A 2-element array of the previous global and - // document are returned. - // description: - // dojo.pushContext treats contexts as a stack. The - // auto-detected contexts which are initially provided using - // dojo.setContext() require authors to keep state in order to - // "return" to a previous context, whereas the - // dojo.pushContext and dojo.popContext methods provide a more - // natural way to augment blocks of code to ensure that they - // execute in a different window or frame without issue. If - // called without any arguments, the default context (the - // context when Dojo is first loaded) is instead pushed into - // the stack. If only a single string is passed, a node in the - // intitial context's document is looked up and its - // contextWindow and contextDocument properties are used as - // the context to push. This means that iframes can be given - // an ID and code can be executed in the scope of the iframe's - // document in subsequent calls easily. - // g: - // The global context. If a string, the id of the frame to - // search for a context and document. - // d: - // The document element to execute subsequent code with. - var old = [dojo.global, dojo.doc]; - contexts.push(old); - var n; - if(!g && !d){ - n = dojo._defaultContext; - }else{ - n = [ g, d ]; - if(!d && dojo.isString(g)){ - var t = document.getElementById(g); - if(t.contentDocument){ - n = [t.contentWindow, t.contentDocument]; - } - } - } - current = n; - dojo.setContext.apply(dojo, n); - return old; // Array - }; - - dojo.popContext = function(){ - // summary: - // If the context stack contains elements, ensure that - // subsequent code executes in the *previous* context to the - // current context. The current context set ([global, - // document]) is returned. - var oc = current; - if(!contexts.length){ - return oc; - } - dojo.setContext.apply(dojo, contexts.pop()); - return oc; - }; - - // FIXME: - // don't really like the current arguments and order to - // _inContext, so don't make it public until it's right! - dojo._inContext = function(g, d, f){ - var a = dojo._toArray(arguments); - f = a.pop(); - if(a.length == 1){ - d = null; - } - dojo.pushContext(g, d); - var r = f(); - dojo.popContext(); - return r; - }; - - })(); - - dojo._initFired = false; - // BEGIN DOMContentLoaded, from Dean Edwards (http://dean.edwards.name/weblog/2006/06/again/) - dojo._loadInit = function(e){ - dojo._initFired = true; - // allow multiple calls, only first one will take effect - // A bug in khtml calls events callbacks for document for event which isnt supported - // for example a created contextmenu event calls DOMContentLoaded, workaround - var type = (e && e.type) ? e.type.toLowerCase() : "load"; - if(arguments.callee.initialized || (type != "domcontentloaded" && type != "load")){ return; } - arguments.callee.initialized = true; - if(dojo._inFlightCount == 0){ - dojo._modulesLoaded(); - } - }; - - /* - (function(){ - var _w = window; - var _handleNodeEvent = function(evtName, fp){ - // summary: - // non-destructively adds the specified function to the node's - // evtName handler. - // evtName: should be in the form "onclick" for "onclick" handlers. - // Make sure you pass in the "on" part. - var oldHandler = _w[evtName] || function(){}; - _w[evtName] = function(){ - fp.apply(_w, arguments); - oldHandler.apply(_w, arguments); - }; - }; - // FIXME: PORT - // FIXME: dojo.unloaded requires dojo scope, so using anon function wrapper. - _handleNodeEvent("onbeforeunload", function(){ dojo.unloaded(); }); - _handleNodeEvent("onunload", function(){ dojo.windowUnloaded(); }); - })(); - */ - - - // FIXME: PORTME - // this event fires a lot, namely for all plugin XUL overlays and for - // all iframes (in addition to window navigations). We only want - // Dojo's to fire once..but we might care if pages navigate. We'll - // probably need an extension-specific API - if(!dojo.config.afterOnLoad){ - window.addEventListener("DOMContentLoaded", function(e){ - dojo._loadInit(e); - // console.log("DOM content loaded", e); - }, false); - } - -} //if (typeof window != 'undefined') - -//Register any module paths set up in djConfig. Need to do this -//in the hostenvs since hostenv_browser can read djConfig from a -//script tag's attribute. -(function(){ - var mp = dojo.config["modulePaths"]; - if(mp){ - for(var param in mp){ - dojo.registerModulePath(param, mp[param]); - } - } -})(); - -//Load debug code if necessary. -if(dojo.config.isDebug){ - // logging stub for extension logging - console.log = function(m){ - var s = Components.classes["@mozilla.org/consoleservice;1"].getService( - Components.interfaces.nsIConsoleService - ); - s.logStringMessage(m); - }; - console.debug = function(){ - console.log(dojo._toArray(arguments).join(" ")); - }; - // FIXME: what about the rest of the console.* methods? And is there any way to reach into firebug and log into it directly? -} diff --git a/lib/dojo/_base/configNode.js b/lib/dojo/_base/configNode.js deleted file mode 100644 index 1866795..0000000 --- a/lib/dojo/_base/configNode.js +++ /dev/null @@ -1,87 +0,0 @@ -exports.config = function(config){ - // summary: - // This module provides bootstrap configuration for running dojo in node.js - - // any command line arguments with the load flag are pushed into deps - for(var deps = [], args = [], i = 0; i < process.argv.length; i++){ - var arg = (process.argv[i] + "").split("="); - if(arg[0] == "load"){ - deps.push(arg[1]); - }else{ - args.push(arg); - } - } - - var fs = require("fs"); - - // make sure global require exists - //if (typeof global.require=="undefined"){ - // global.require= {}; - //} - - // reset the has cache with node-appropriate values; - var hasCache = { - "host-node":1, - "host-browser":0, - "dom":0, - "dojo-has-api":1, - "dojo-xhr-factory":0, - "dojo-inject-api":1, - "dojo-timeout-api":0, - "dojo-trace-api":1, - "dojo-dom-ready-api":0, - "dojo-publish-privates":1, - "dojo-sniff":0, - "dojo-loader":1, - "dojo-test-xd":0, - "dojo-test-sniff":0 - }; - for(var p in hasCache){ - config.hasCache[p] = hasCache[p]; - } - - var vm = require('vm'), - path = require('path'); - - // reset some configuration switches with node-appropriate values - var nodeConfig = { - baseUrl: path.dirname(process.argv[1]), - commandLineArgs:args, - deps:deps, - timeout:0, - - // TODO: really get the locale - locale:"en-us", - - loaderPatch: { - log:function(item){ - // define debug for console messages during dev instead of console.log - // (node's heavy async makes console.log confusing sometimes) - var util = require("util"); - util.debug(util.inspect(item)); - }, - - eval: function(__text, __urlHint){ - return vm.runInThisContext(__text, __urlHint); - }, - - injectUrl: function(url, callback){ - try{ - vm.runInThisContext(fs.readFileSync(url, "utf8"), url); - callback(); - }catch(e){ - this.log("failed to load resource (" + url + ")"); - this.log(e); - } - }, - - getText: function(url, sync, onLoad){ - // TODO: implement async and http/https handling - onLoad(fs.readFileSync(url, "utf8")); - } - } - }; - for(p in nodeConfig){ - config[p] = nodeConfig[p]; - } -}; diff --git a/lib/dojo/_base/configRhino.js b/lib/dojo/_base/configRhino.js deleted file mode 100644 index 2cbbf88..0000000 --- a/lib/dojo/_base/configRhino.js +++ /dev/null @@ -1,121 +0,0 @@ -function rhinoDojoConfig(config, baseUrl, rhinoArgs){ - // summary: - // This module provides bootstrap configuration for running dojo in rhino. - - // TODO: v1.6 tries to set dojo.doc and dojo.body in rhino; why? - - // get a minimal console up - var log = function(hint, args){ - print((hint ? hint + ":" : "") + args[0]); - for(var i = 1; i < args.length; i++){ - print(", " + args[i]); - } - }; - // intentionally define console in the global namespace - console= { - log: function(){ log(0, arguments); }, - error: function(){ log("ERROR", arguments); }, - warn: function(){ log("WARN", arguments); } - }; - - // any command line arguments with the load flag are pushed into deps - for(var deps = [], i = 0; i < rhinoArgs.length; i++){ - var arg = (rhinoArgs[i] + "").split("="); - if(arg[0] == "load"){ - deps.push(arg[1]); - } - } - - // provides timed callbacks using Java threads - if(typeof setTimeout == "undefined" || typeof clearTimeout == "undefined"){ - var timeouts = []; - clearTimeout = function(idx){ - if(!timeouts[idx]){ return; } - timeouts[idx].stop(); - }; - - setTimeout = function(func, delay){ - var def = { - sleepTime:delay, - hasSlept:false, - - run:function(){ - if(!this.hasSlept){ - this.hasSlept = true; - java.lang.Thread.currentThread().sleep(this.sleepTime); - } - try{ - func(); - }catch(e){ - console.debug("Error running setTimeout thread:" + e); - } - } - }; - - var runnable = new java.lang.Runnable(def); - var thread = new java.lang.Thread(runnable); - thread.start(); - return timeouts.push(thread) - 1; - }; - } - - var isLocal = function(url){ - return (new java.io.File(url)).exists(); - }; - - // reset the has cache with node-appropriate values; - var hasCache = { - "host-rhino":1, - "host-browser":0, - "dom":0, - "dojo-has-api":1, - "dojo-xhr-factory":0, - "dojo-inject-api":1, - "dojo-timeout-api":0, - "dojo-trace-api":1, - "dojo-loader-catches":1, - "dojo-dom-ready-api":0, - "dojo-publish-privates":1, - "dojo-sniff":0, - "dojo-loader":1, - "dojo-test-xd":0, - "dojo-test-sniff":0 - }; - for(var p in hasCache){ - config.hasCache[p] = hasCache[p]; - } - - // reset some configuration switches with rhino-appropriate values - var rhinoConfig = { - baseUrl:baseUrl, - commandLineArgs:rhinoArgs, - deps:deps, - timeout:0, - locale:String(java.util.Locale.getDefault().toString().replace('_', '-').toLowerCase()), - - loaderPatch:{ - injectUrl: function(url, callback){ - try{ - if(isLocal(url)){ - load(url); - }else{ - require.eval(readUrl(url, "UTF-8")); - } - callback(); - }catch(e){ - console.log("failed to load resource (" + url + ")"); - console.log(e); - } - }, - - getText: function(url, sync, onLoad){ - // TODO: test https://bugzilla.mozilla.org/show_bug.cgi?id=471005; see v1.6 hostenv_rhino - // note: async mode not supported in rhino - onLoad(isLocal(url) ? readFile(url, "UTF-8") : readUrl(url, "UTF-8")); - } - } - }; - for(p in rhinoConfig){ - config[p] = rhinoConfig[p]; - } -} diff --git a/lib/dojo/_base/configSpidermonkey.js b/lib/dojo/_base/configSpidermonkey.js deleted file mode 100644 index af16fda..0000000 --- a/lib/dojo/_base/configSpidermonkey.js +++ /dev/null @@ -1,80 +0,0 @@ -// TODO: this file needs to be converted to the v1.7 loader - -// module: -// configSpidermonkey -// summary: -// SpiderMonkey host environment - -if(dojo.config["baseUrl"]){ - dojo.baseUrl = dojo.config["baseUrl"]; -}else{ - dojo.baseUrl = "./"; -} - -dojo._name = 'spidermonkey'; - - - -dojo.isSpidermonkey = true; -dojo.exit = function(exitcode){ - quit(exitcode); -}; - -if(typeof print == "function"){ - console.debug = print; -} - -if(typeof line2pc == 'undefined'){ - throw new Error("attempt to use SpiderMonkey host environment when no 'line2pc' global"); -} - -dojo._spidermonkeyCurrentFile = function(depth){ - // - // This is a hack that determines the current script file by parsing a - // generated stack trace (relying on the non-standard "stack" member variable - // of the SpiderMonkey Error object). - // - // If param depth is passed in, it'll return the script file which is that far down - // the stack, but that does require that you know how deep your stack is when you are - // calling. - // - var s = ''; - try{ - throw Error("whatever"); - }catch(e){ - s = e.stack; - } - // lines are like: bu_getCurrentScriptURI_spidermonkey("ScriptLoader.js")@burst/Runtime.js:101 - var matches = s.match(/[^@]*\.js/gi); - if(!matches){ - throw Error("could not parse stack string: '" + s + "'"); - } - var fname = (typeof depth != 'undefined' && depth) ? matches[depth + 1] : matches[matches.length - 1]; - if(!fname){ - throw Error("could not find file name in stack string '" + s + "'"); - } - //print("SpiderMonkeyRuntime got fname '" + fname + "' from stack string '" + s + "'"); - return fname; -}; - -// print(dojo._spidermonkeyCurrentFile(0)); - -dojo._loadUri = function(uri){ - // spidermonkey load() evaluates the contents into the global scope (which - // is what we want). - // TODO: sigh, load() does not return a useful value. - // Perhaps it is returning the value of the last thing evaluated? - // var ok = - load(uri); - // console.log("spidermonkey load(", uri, ") returned ", ok); - return 1; -}; - -//Register any module paths set up in djConfig. Need to do this -//in the hostenvs since hostenv_browser can read djConfig from a -//script tag's attribute. -if(dojo.config["modulePaths"]){ - for(var param in dojo.config["modulePaths"]){ - dojo.registerModulePath(param, dojo.config["modulePaths"][param]); - } -} diff --git a/lib/dojo/_base/connect.js b/lib/dojo/_base/connect.js deleted file mode 100644 index 77d0ab9..0000000 --- a/lib/dojo/_base/connect.js +++ /dev/null @@ -1,163 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/_base/connect",["./kernel","../on","../topic","../aspect","./event","../mouse","./sniff","./lang","../keys"],function(_1,on,_2,_3,_4,_5,_6,_7){ -_6.add("events-keypress-typed",function(){ -var _8={charCode:0}; -try{ -_8=document.createEvent("KeyboardEvent"); -(_8.initKeyboardEvent||_8.initKeyEvent).call(_8,"keypress",true,true,null,false,false,false,false,9,3); -} -catch(e){ -} -return _8.charCode==0&&!_6("opera"); -}); -function _9(_a,_b,_c,_d,_e){ -_d=_7.hitch(_c,_d); -if(!_a||!(_a.addEventListener||_a.attachEvent)){ -return _3.after(_a||_1.global,_b,_d,true); -} -if(typeof _b=="string"&&_b.substring(0,2)=="on"){ -_b=_b.substring(2); -} -if(!_a){ -_a=_1.global; -} -if(!_e){ -switch(_b){ -case "keypress": -_b=_f; -break; -case "mouseenter": -_b=_5.enter; -break; -case "mouseleave": -_b=_5.leave; -break; -} -} -return on(_a,_b,_d,_e); -}; -var _10={106:42,111:47,186:59,187:43,188:44,189:45,190:46,191:47,192:96,219:91,220:92,221:93,222:39,229:113}; -var _11=_6("mac")?"metaKey":"ctrlKey"; -var _12=function(evt,_13){ -var _14=_7.mixin({},evt,_13); -_15(_14); -_14.preventDefault=function(){ -evt.preventDefault(); -}; -_14.stopPropagation=function(){ -evt.stopPropagation(); -}; -return _14; -}; -function _15(evt){ -evt.keyChar=evt.charCode?String.fromCharCode(evt.charCode):""; -evt.charOrCode=evt.keyChar||evt.keyCode; -}; -var _f; -if(_6("events-keypress-typed")){ -var _16=function(e,_17){ -try{ -return (e.keyCode=_17); -} -catch(e){ -return 0; -} -}; -_f=function(_18,_19){ -var _1a=on(_18,"keydown",function(evt){ -var k=evt.keyCode; -var _1b=(k!=13)&&k!=32&&(k!=27||!_6("ie"))&&(k<48||k>90)&&(k<96||k>111)&&(k<186||k>192)&&(k<219||k>222)&&k!=229; -if(_1b||evt.ctrlKey){ -var c=_1b?0:k; -if(evt.ctrlKey){ -if(k==3||k==13){ -return _19.call(evt.currentTarget,evt); -}else{ -if(c>95&&c<106){ -c-=48; -}else{ -if((!evt.shiftKey)&&(c>=65&&c<=90)){ -c+=32; -}else{ -c=_10[c]||c; -} -} -} -} -var _1c=_12(evt,{type:"keypress",faux:true,charCode:c}); -_19.call(evt.currentTarget,_1c); -if(_6("ie")){ -_16(evt,_1c.keyCode); -} -} -}); -var _1d=on(_18,"keypress",function(evt){ -var c=evt.charCode; -c=c>=32?c:0; -evt=_12(evt,{charCode:c,faux:true}); -return _19.call(this,evt); -}); -return {remove:function(){ -_1a.remove(); -_1d.remove(); -}}; -}; -}else{ -if(_6("opera")){ -_f=function(_1e,_1f){ -return on(_1e,"keypress",function(evt){ -var c=evt.which; -if(c==3){ -c=99; -} -c=c<32&&!evt.shiftKey?0:c; -if(evt.ctrlKey&&!evt.shiftKey&&c>=65&&c<=90){ -c+=32; -} -return _1f.call(this,_12(evt,{charCode:c})); -}); -}; -}else{ -_f=function(_20,_21){ -return on(_20,"keypress",function(evt){ -_15(evt); -return _21.call(this,evt); -}); -}; -} -} -var _22={_keypress:_f,connect:function(obj,_23,_24,_25,_26){ -var a=arguments,_27=[],i=0; -_27.push(typeof a[0]=="string"?null:a[i++],a[i++]); -var a1=a[i+1]; -_27.push(typeof a1=="string"||typeof a1=="function"?a[i++]:null,a[i++]); -for(var l=a.length;i90) && (k<96||k>111) && (k<186||k>192) && (k<219||k>222) && k!=229; - // synthesize keypress for most unprintables and CTRL-keys - if(unprintable||evt.ctrlKey){ - var c = unprintable ? 0 : k; - if(evt.ctrlKey){ - if(k==3 || k==13){ - return listener.call(evt.currentTarget, evt); // IE will post CTRL-BREAK, CTRL-ENTER as keypress natively - }else if(c>95 && c<106){ - c -= 48; // map CTRL-[numpad 0-9] to ASCII - }else if((!evt.shiftKey)&&(c>=65&&c<=90)){ - c += 32; // map CTRL-[A-Z] to lowercase - }else{ - c = _punctMap[c] || c; // map other problematic CTRL combinations to ASCII - } - } - // simulate a keypress event - var faux = _synthesizeEvent(evt, {type: 'keypress', faux: true, charCode: c}); - listener.call(evt.currentTarget, faux); - if(has("ie")){ - _trySetKeyCode(evt, faux.keyCode); - } - } - }); - var keypressSignal = on(object, "keypress", function(evt){ - var c = evt.charCode; - c = c>=32 ? c : 0; - evt = _synthesizeEvent(evt, {charCode: c, faux: true}); - return listener.call(this, evt); - }); - return { - remove: function(){ - keydownSignal.remove(); - keypressSignal.remove(); - } - }; - }; -}else{ - if(has("opera")){ - keypress = function(object, listener){ - return on(object, "keypress", function(evt){ - var c = evt.which; - if(c==3){ - c=99; // Mozilla maps CTRL-BREAK to CTRL-c - } - // can't trap some keys at all, like INSERT and DELETE - // there is no differentiating info between DELETE and ".", or INSERT and "-" - c = c<32 && !evt.shiftKey ? 0 : c; - if(evt.ctrlKey && !evt.shiftKey && c>=65 && c<=90){ - // lowercase CTRL-[A-Z] keys - c += 32; - } - return listener.call(this, _synthesizeEvent(evt, { charCode: c })); - }); - }; - }else{ - keypress = function(object, listener){ - return on(object, "keypress", function(evt){ - setKeyChar(evt); - return listener.call(this, evt); - }); - }; - } -} - -var connect = { - // summary: - // This module defines the dojo.connect API. - // This modules also provides keyboard event handling helpers. - // This module exports an extension event for emulating Firefox's keypress handling. - // However, this extension event exists primarily for backwards compatibility and - // is not recommended. WebKit and IE uses an alternate keypress handling (only - // firing for printable characters, to distinguish from keydown events), and most - // consider the WebKit/IE behavior more desirable. - - _keypress:keypress, - - connect:function(obj, event, context, method, dontFix){ - // summary: - // `dojo.connect` is a deprecated event handling and delegation method in - // Dojo. It allows one function to "listen in" on the execution of - // any other, triggering the second whenever the first is called. Many - // listeners may be attached to a function, and source functions may - // be either regular function calls or DOM events. - // - // description: - // Connects listeners to actions, so that after event fires, a - // listener is called with the same arguments passed to the original - // function. - // - // Since `dojo.connect` allows the source of events to be either a - // "regular" JavaScript function or a DOM event, it provides a uniform - // interface for listening to all the types of events that an - // application is likely to deal with though a single, unified - // interface. DOM programmers may want to think of it as - // "addEventListener for everything and anything". - // - // When setting up a connection, the `event` parameter must be a - // string that is the name of the method/event to be listened for. If - // `obj` is null, `kernel.global` is assumed, meaning that connections - // to global methods are supported but also that you may inadvertently - // connect to a global by passing an incorrect object name or invalid - // reference. - // - // `dojo.connect` generally is forgiving. If you pass the name of a - // function or method that does not yet exist on `obj`, connect will - // not fail, but will instead set up a stub method. Similarly, null - // arguments may simply be omitted such that fewer than 4 arguments - // may be required to set up a connection See the examples for details. - // - // The return value is a handle that is needed to - // remove this connection with `dojo.disconnect`. - // - // obj: Object? - // The source object for the event function. - // Defaults to `kernel.global` if null. - // If obj is a DOM node, the connection is delegated - // to the DOM event manager (unless dontFix is true). - // - // event: String - // String name of the event function in obj. - // I.e. identifies a property `obj[event]`. - // - // context: Object|null - // The object that method will receive as "this". - // - // If context is null and method is a function, then method - // inherits the context of event. - // - // If method is a string then context must be the source - // object object for method (context[method]). If context is null, - // kernel.global is used. - // - // method: String|Function - // A function reference, or name of a function in context. - // The function identified by method fires after event does. - // method receives the same arguments as the event. - // See context argument comments for information on method's scope. - // - // dontFix: Boolean? - // If obj is a DOM node, set dontFix to true to prevent delegation - // of this connection to the DOM event manager. - // - // example: - // When obj.onchange(), do ui.update(): - // | dojo.connect(obj, "onchange", ui, "update"); - // | dojo.connect(obj, "onchange", ui, ui.update); // same - // - // example: - // Using return value for disconnect: - // | var link = dojo.connect(obj, "onchange", ui, "update"); - // | ... - // | dojo.disconnect(link); - // - // example: - // When onglobalevent executes, watcher.handler is invoked: - // | dojo.connect(null, "onglobalevent", watcher, "handler"); - // - // example: - // When ob.onCustomEvent executes, customEventHandler is invoked: - // | dojo.connect(ob, "onCustomEvent", null, "customEventHandler"); - // | dojo.connect(ob, "onCustomEvent", "customEventHandler"); // same - // - // example: - // When ob.onCustomEvent executes, customEventHandler is invoked - // with the same scope (this): - // | dojo.connect(ob, "onCustomEvent", null, customEventHandler); - // | dojo.connect(ob, "onCustomEvent", customEventHandler); // same - // - // example: - // When globalEvent executes, globalHandler is invoked - // with the same scope (this): - // | dojo.connect(null, "globalEvent", null, globalHandler); - // | dojo.connect("globalEvent", globalHandler); // same - - // normalize arguments - var a=arguments, args=[], i=0; - // if a[0] is a String, obj was omitted - args.push(typeof a[0] == "string" ? null : a[i++], a[i++]); - // if the arg-after-next is a String or Function, context was NOT omitted - var a1 = a[i+1]; - args.push(typeof a1 == "string" || typeof a1 == "function" ? a[i++] : null, a[i++]); - // absorb any additional arguments - for(var l=a.length; i= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/_base/declare",["./kernel","../has","./lang"],function(_1,_2,_3){ -var _4=_3.mixin,op=Object.prototype,_5=op.toString,_6=new Function,_7=0,_8="constructor"; -function _9(_a,_b){ -throw new Error("declare"+(_b?" "+_b:"")+": "+_a); -}; -function _c(_d,_e){ -var _f=[],_10=[{cls:0,refs:[]}],_11={},_12=1,l=_d.length,i=0,j,lin,_13,top,_14,rec,_15,_16; -for(;i=0;--j){ -_14=lin[j].prototype; -if(!_14.hasOwnProperty("declaredClass")){ -_14.declaredClass="uniqName_"+(_7++); -} -_15=_14.declaredClass; -if(!_11.hasOwnProperty(_15)){ -_11[_15]={count:0,refs:[],cls:lin[j]}; -++_12; -} -rec=_11[_15]; -if(top&&top!==rec){ -rec.refs.push(top); -++top.count; -} -top=rec; -} -++top.count; -_10[0].refs.push(top); -} -while(_10.length){ -top=_10.pop(); -_f.push(top.cls); ---_12; -while(_16=top.refs,_16.length==1){ -top=_16[0]; -if(!top||--top.count){ -top=0; -break; -} -_f.push(top.cls); ---_12; -} -if(top){ -for(i=0,l=_16.length;i=0;--i){ -f=_3a[i]; -m=f._meta; -f=m?m.ctor:f; -if(f){ -f.apply(this,_3d?_3d[i]:a); -} -} -f=this.postscript; -if(f){ -f.apply(this,_3c); -} -}; -}; -function _3f(_40,_41){ -return function(){ -var a=arguments,t=a,a0=a[0],f; -if(!(this instanceof a.callee)){ -return _3e(a); -} -if(_41){ -if(a0){ -f=a0.preamble; -if(f){ -t=f.apply(this,t)||t; -} -} -f=this.preamble; -if(f){ -f.apply(this,t); -} -} -if(_40){ -_40.apply(this,a); -} -f=this.postscript; -if(f){ -f.apply(this,a); -} -}; -}; -function _42(_43){ -return function(){ -var a=arguments,i=0,f,m; -if(!(this instanceof a.callee)){ -return _3e(a); -} -for(;f=_43[i];++i){ -m=f._meta; -f=m?m.ctor:f; -if(f){ -f.apply(this,a); -break; -} -} -f=this.postscript; -if(f){ -f.apply(this,a); -} -}; -}; -function _44(_45,_46,_47){ -return function(){ -var b,m,f,i=0,_48=1; -if(_47){ -i=_46.length-1; -_48=-1; -} -for(;b=_46[i];i+=_48){ -m=b._meta; -f=(m?m.hidden:b.prototype)[_45]; -if(f){ -f.apply(this,arguments); -} -} -}; -}; -function _49(_4a){ -_6.prototype=_4a.prototype; -var t=new _6; -_6.prototype=null; -return t; -}; -function _3e(_4b){ -var _4c=_4b.callee,t=_49(_4c); -_4c.apply(t,_4b); -return t; -}; -function _35(_4d,_4e,_4f){ -if(typeof _4d!="string"){ -_4f=_4e; -_4e=_4d; -_4d=""; -} -_4f=_4f||{}; -var _50,i,t,_51,_52,_53,_54,_55=1,_56=_4e; -if(_5.call(_4e)=="[object Array]"){ -_53=_c(_4e,_4d); -t=_53[0]; -_55=_53.length-t; -_4e=_53[_55]; -}else{ -_53=[0]; -if(_4e){ -if(_5.call(_4e)=="[object Function]"){ -t=_4e._meta; -_53=_53.concat(t?t.bases:_4e); -}else{ -_9("base class is not a callable constructor.",_4d); -} -}else{ -if(_4e!==null){ -_9("unknown base class. Did you use dojo.require to pull it in?",_4d); -} -} -} -if(_4e){ -for(i=_55-1;;--i){ -_50=_49(_4e); -if(!i){ -break; -} -t=_53[i]; -(t._meta?_29:_4)(_50,t.prototype); -_51=new Function; -_51.superclass=_4e; -_51.prototype=_50; -_4e=_50.constructor=_51; -} -}else{ -_50={}; -} -_35.safeMixin(_50,_4f); -t=_4f.constructor; -if(t!==op.constructor){ -t.nom=_8; -_50.constructor=t; -} -for(i=_55-1;i;--i){ -t=_53[i]._meta; -if(t&&t.chains){ -_54=_4(_54||{},t.chains); -} -} -if(_50["-chains-"]){ -_54=_4(_54||{},_50["-chains-"]); -} -t=!_54||!_54.hasOwnProperty(_8); -_53[0]=_51=(_54&&_54.constructor==="manual")?_42(_53):(_53.length==1?_3f(_4f.constructor,t):_39(_53,t)); -_51._meta={bases:_53,hidden:_4f,chains:_54,parents:_56,ctor:_4f.constructor}; -_51.superclass=_4e&&_4e.prototype; -_51.extend=_33; -_51.createSubclass=_36; -_51.prototype=_50; -_50.constructor=_51; -_50.getInherited=_21; -_50.isInstanceOf=_27; -_50.inherited=_26; -_50.__inherited=_17; -if(_4d){ -_50.declaredClass=_4d; -_3.setObject(_4d,_51); -} -if(_54){ -for(_52 in _54){ -if(_50[_52]&&typeof _54[_52]=="string"&&_52!=_8){ -t=_50[_52]=_44(_52,_53,_54[_52]==="after"); -t.nom=_52; -} -} -} -return _51; -}; -_1.safeMixin=_35.safeMixin=_2e; -_1.declare=_35; -return _35; -}); diff --git a/lib/dojo/_base/declare.js.uncompressed.js b/lib/dojo/_base/declare.js.uncompressed.js deleted file mode 100644 index bc22ff2..0000000 --- a/lib/dojo/_base/declare.js.uncompressed.js +++ /dev/null @@ -1,1098 +0,0 @@ -define("dojo/_base/declare", ["./kernel", "../has", "./lang"], function(dojo, has, lang){ - // module: - // dojo/_base/declare - - var mix = lang.mixin, op = Object.prototype, opts = op.toString, - xtor = new Function, counter = 0, cname = "constructor"; - - function err(msg, cls){ throw new Error("declare" + (cls ? " " + cls : "") + ": " + msg); } - - // C3 Method Resolution Order (see http://www.python.org/download/releases/2.3/mro/) - function c3mro(bases, className){ - var result = [], roots = [{cls: 0, refs: []}], nameMap = {}, clsCount = 1, - l = bases.length, i = 0, j, lin, base, top, proto, rec, name, refs; - - // build a list of bases naming them if needed - for(; i < l; ++i){ - base = bases[i]; - if(!base){ - err("mixin #" + i + " is unknown. Did you use dojo.require to pull it in?", className); - }else if(opts.call(base) != "[object Function]"){ - err("mixin #" + i + " is not a callable constructor.", className); - } - lin = base._meta ? base._meta.bases : [base]; - top = 0; - // add bases to the name map - for(j = lin.length - 1; j >= 0; --j){ - proto = lin[j].prototype; - if(!proto.hasOwnProperty("declaredClass")){ - proto.declaredClass = "uniqName_" + (counter++); - } - name = proto.declaredClass; - if(!nameMap.hasOwnProperty(name)){ - nameMap[name] = {count: 0, refs: [], cls: lin[j]}; - ++clsCount; - } - rec = nameMap[name]; - if(top && top !== rec){ - rec.refs.push(top); - ++top.count; - } - top = rec; - } - ++top.count; - roots[0].refs.push(top); - } - - // remove classes without external references recursively - while(roots.length){ - top = roots.pop(); - result.push(top.cls); - --clsCount; - // optimization: follow a single-linked chain - while(refs = top.refs, refs.length == 1){ - top = refs[0]; - if(!top || --top.count){ - // branch or end of chain => do not end to roots - top = 0; - break; - } - result.push(top.cls); - --clsCount; - } - if(top){ - // branch - for(i = 0, l = refs.length; i < l; ++i){ - top = refs[i]; - if(!--top.count){ - roots.push(top); - } - } - } - } - if(clsCount){ - err("can't build consistent linearization", className); - } - - // calculate the superclass offset - base = bases[0]; - result[0] = base ? - base._meta && base === result[result.length - base._meta.bases.length] ? - base._meta.bases.length : 1 : 0; - - return result; - } - - function inherited(args, a, f){ - var name, chains, bases, caller, meta, base, proto, opf, pos, - cache = this._inherited = this._inherited || {}; - - // crack arguments - if(typeof args == "string"){ - name = args; - args = a; - a = f; - } - f = 0; - - caller = args.callee; - name = name || caller.nom; - if(!name){ - err("can't deduce a name to call inherited()", this.declaredClass); - } - - meta = this.constructor._meta; - bases = meta.bases; - - pos = cache.p; - if(name != cname){ - // method - if(cache.c !== caller){ - // cache bust - pos = 0; - base = bases[0]; - meta = base._meta; - if(meta.hidden[name] !== caller){ - // error detection - chains = meta.chains; - if(chains && typeof chains[name] == "string"){ - err("calling chained method with inherited: " + name, this.declaredClass); - } - // find caller - do{ - meta = base._meta; - proto = base.prototype; - if(meta && (proto[name] === caller && proto.hasOwnProperty(name) || meta.hidden[name] === caller)){ - break; - } - }while(base = bases[++pos]); // intentional assignment - pos = base ? pos : -1; - } - } - // find next - base = bases[++pos]; - if(base){ - proto = base.prototype; - if(base._meta && proto.hasOwnProperty(name)){ - f = proto[name]; - }else{ - opf = op[name]; - do{ - proto = base.prototype; - f = proto[name]; - if(f && (base._meta ? proto.hasOwnProperty(name) : f !== opf)){ - break; - } - }while(base = bases[++pos]); // intentional assignment - } - } - f = base && f || op[name]; - }else{ - // constructor - if(cache.c !== caller){ - // cache bust - pos = 0; - meta = bases[0]._meta; - if(meta && meta.ctor !== caller){ - // error detection - chains = meta.chains; - if(!chains || chains.constructor !== "manual"){ - err("calling chained constructor with inherited", this.declaredClass); - } - // find caller - while(base = bases[++pos]){ // intentional assignment - meta = base._meta; - if(meta && meta.ctor === caller){ - break; - } - } - pos = base ? pos : -1; - } - } - // find next - while(base = bases[++pos]){ // intentional assignment - meta = base._meta; - f = meta ? meta.ctor : base; - if(f){ - break; - } - } - f = base && f; - } - - // cache the found super method - cache.c = f; - cache.p = pos; - - // now we have the result - if(f){ - return a === true ? f : f.apply(this, a || args); - } - // intentionally no return if a super method was not found - } - - function getInherited(name, args){ - if(typeof name == "string"){ - return this.__inherited(name, args, true); - } - return this.__inherited(name, true); - } - - function inherited__debug(args, a1, a2){ - var f = this.getInherited(args, a1); - if(f){ return f.apply(this, a2 || a1 || args); } - // intentionally no return if a super method was not found - } - - var inheritedImpl = dojo.config.isDebug ? inherited__debug : inherited; - - // emulation of "instanceof" - function isInstanceOf(cls){ - var bases = this.constructor._meta.bases; - for(var i = 0, l = bases.length; i < l; ++i){ - if(bases[i] === cls){ - return true; - } - } - return this instanceof cls; - } - - function mixOwn(target, source){ - // add props adding metadata for incoming functions skipping a constructor - for(var name in source){ - if(name != cname && source.hasOwnProperty(name)){ - target[name] = source[name]; - } - } - if(has("bug-for-in-skips-shadowed")){ - for(var extraNames= lang._extraNames, i= extraNames.length; i;){ - name = extraNames[--i]; - if(name != cname && source.hasOwnProperty(name)){ - target[name] = source[name]; - } - } - } - } - - // implementation of safe mixin function - function safeMixin(target, source){ - // summary: - // Mix in properties skipping a constructor and decorating functions - // like it is done by declare(). - // target: Object - // Target object to accept new properties. - // source: Object - // Source object for new properties. - // description: - // This function is used to mix in properties like lang.mixin does, - // but it skips a constructor property and decorates functions like - // declare() does. - // - // It is meant to be used with classes and objects produced with - // declare. Functions mixed in with dojo.safeMixin can use - // this.inherited() like normal methods. - // - // This function is used to implement extend() method of a constructor - // produced with declare(). - // - // example: - // | var A = declare(null, { - // | m1: function(){ - // | console.log("A.m1"); - // | }, - // | m2: function(){ - // | console.log("A.m2"); - // | } - // | }); - // | var B = declare(A, { - // | m1: function(){ - // | this.inherited(arguments); - // | console.log("B.m1"); - // | } - // | }); - // | B.extend({ - // | m2: function(){ - // | this.inherited(arguments); - // | console.log("B.m2"); - // | } - // | }); - // | var x = new B(); - // | dojo.safeMixin(x, { - // | m1: function(){ - // | this.inherited(arguments); - // | console.log("X.m1"); - // | }, - // | m2: function(){ - // | this.inherited(arguments); - // | console.log("X.m2"); - // | } - // | }); - // | x.m2(); - // | // prints: - // | // A.m1 - // | // B.m1 - // | // X.m1 - - var name, t; - // add props adding metadata for incoming functions skipping a constructor - for(name in source){ - t = source[name]; - if((t !== op[name] || !(name in op)) && name != cname){ - if(opts.call(t) == "[object Function]"){ - // non-trivial function method => attach its name - t.nom = name; - } - target[name] = t; - } - } - if(has("bug-for-in-skips-shadowed")){ - for(var extraNames= lang._extraNames, i= extraNames.length; i;){ - name = extraNames[--i]; - t = source[name]; - if((t !== op[name] || !(name in op)) && name != cname){ - if(opts.call(t) == "[object Function]"){ - // non-trivial function method => attach its name - t.nom = name; - } - target[name] = t; - } - } - } - return target; - } - - function extend(source){ - declare.safeMixin(this.prototype, source); - return this; - } - - function createSubclass(mixins, props){ - // crack parameters - if(!(mixins instanceof Array || typeof mixins == 'function')){ - props = mixins; - mixins = undefined; - } - - props = props || {}; - mixins = mixins || []; - - return declare([this].concat(mixins), props); - } - - // chained constructor compatible with the legacy declare() - function chainedConstructor(bases, ctorSpecial){ - return function(){ - var a = arguments, args = a, a0 = a[0], f, i, m, - l = bases.length, preArgs; - - if(!(this instanceof a.callee)){ - // not called via new, so force it - return applyNew(a); - } - - //this._inherited = {}; - // perform the shaman's rituals of the original declare() - // 1) call two types of the preamble - if(ctorSpecial && (a0 && a0.preamble || this.preamble)){ - // full blown ritual - preArgs = new Array(bases.length); - // prepare parameters - preArgs[0] = a; - for(i = 0;;){ - // process the preamble of the 1st argument - a0 = a[0]; - if(a0){ - f = a0.preamble; - if(f){ - a = f.apply(this, a) || a; - } - } - // process the preamble of this class - f = bases[i].prototype; - f = f.hasOwnProperty("preamble") && f.preamble; - if(f){ - a = f.apply(this, a) || a; - } - // one peculiarity of the preamble: - // it is called if it is not needed, - // e.g., there is no constructor to call - // let's watch for the last constructor - // (see ticket #9795) - if(++i == l){ - break; - } - preArgs[i] = a; - } - } - // 2) call all non-trivial constructors using prepared arguments - for(i = l - 1; i >= 0; --i){ - f = bases[i]; - m = f._meta; - f = m ? m.ctor : f; - if(f){ - f.apply(this, preArgs ? preArgs[i] : a); - } - } - // 3) continue the original ritual: call the postscript - f = this.postscript; - if(f){ - f.apply(this, args); - } - }; - } - - - // chained constructor compatible with the legacy declare() - function singleConstructor(ctor, ctorSpecial){ - return function(){ - var a = arguments, t = a, a0 = a[0], f; - - if(!(this instanceof a.callee)){ - // not called via new, so force it - return applyNew(a); - } - - //this._inherited = {}; - // perform the shaman's rituals of the original declare() - // 1) call two types of the preamble - if(ctorSpecial){ - // full blown ritual - if(a0){ - // process the preamble of the 1st argument - f = a0.preamble; - if(f){ - t = f.apply(this, t) || t; - } - } - f = this.preamble; - if(f){ - // process the preamble of this class - f.apply(this, t); - // one peculiarity of the preamble: - // it is called even if it is not needed, - // e.g., there is no constructor to call - // let's watch for the last constructor - // (see ticket #9795) - } - } - // 2) call a constructor - if(ctor){ - ctor.apply(this, a); - } - // 3) continue the original ritual: call the postscript - f = this.postscript; - if(f){ - f.apply(this, a); - } - }; - } - - // plain vanilla constructor (can use inherited() to call its base constructor) - function simpleConstructor(bases){ - return function(){ - var a = arguments, i = 0, f, m; - - if(!(this instanceof a.callee)){ - // not called via new, so force it - return applyNew(a); - } - - //this._inherited = {}; - // perform the shaman's rituals of the original declare() - // 1) do not call the preamble - // 2) call the top constructor (it can use this.inherited()) - for(; f = bases[i]; ++i){ // intentional assignment - m = f._meta; - f = m ? m.ctor : f; - if(f){ - f.apply(this, a); - break; - } - } - // 3) call the postscript - f = this.postscript; - if(f){ - f.apply(this, a); - } - }; - } - - function chain(name, bases, reversed){ - return function(){ - var b, m, f, i = 0, step = 1; - if(reversed){ - i = bases.length - 1; - step = -1; - } - for(; b = bases[i]; i += step){ // intentional assignment - m = b._meta; - f = (m ? m.hidden : b.prototype)[name]; - if(f){ - f.apply(this, arguments); - } - } - }; - } - - // forceNew(ctor) - // return a new object that inherits from ctor.prototype but - // without actually running ctor on the object. - function forceNew(ctor){ - // create object with correct prototype using a do-nothing - // constructor - xtor.prototype = ctor.prototype; - var t = new xtor; - xtor.prototype = null; // clean up - return t; - } - - // applyNew(args) - // just like 'new ctor()' except that the constructor and its arguments come - // from args, which must be an array or an arguments object - function applyNew(args){ - // create an object with ctor's prototype but without - // calling ctor on it. - var ctor = args.callee, t = forceNew(ctor); - // execute the real constructor on the new object - ctor.apply(t, args); - return t; - } - - function declare(className, superclass, props){ - // summary: - // Create a feature-rich constructor from compact notation. - // className: String? - // The optional name of the constructor (loosely, a "class") - // stored in the "declaredClass" property in the created prototype. - // It will be used as a global name for a created constructor. - // superclass: Function|Function[] - // May be null, a Function, or an Array of Functions. This argument - // specifies a list of bases (the left-most one is the most deepest - // base). - // props: Object - // An object whose properties are copied to the created prototype. - // Add an instance-initialization function by making it a property - // named "constructor". - // returns: dojo/_base/declare.__DeclareCreatedObject - // New constructor function. - // description: - // Create a constructor using a compact notation for inheritance and - // prototype extension. - // - // Mixin ancestors provide a type of multiple inheritance. - // Prototypes of mixin ancestors are copied to the new class: - // changes to mixin prototypes will not affect classes to which - // they have been mixed in. - // - // Ancestors can be compound classes created by this version of - // declare(). In complex cases all base classes are going to be - // linearized according to C3 MRO algorithm - // (see http://www.python.org/download/releases/2.3/mro/ for more - // details). - // - // "className" is cached in "declaredClass" property of the new class, - // if it was supplied. The immediate super class will be cached in - // "superclass" property of the new class. - // - // Methods in "props" will be copied and modified: "nom" property - // (the declared name of the method) will be added to all copied - // functions to help identify them for the internal machinery. Be - // very careful, while reusing methods: if you use the same - // function under different names, it can produce errors in some - // cases. - // - // It is possible to use constructors created "manually" (without - // declare()) as bases. They will be called as usual during the - // creation of an instance, their methods will be chained, and even - // called by "this.inherited()". - // - // Special property "-chains-" governs how to chain methods. It is - // a dictionary, which uses method names as keys, and hint strings - // as values. If a hint string is "after", this method will be - // called after methods of its base classes. If a hint string is - // "before", this method will be called before methods of its base - // classes. - // - // If "constructor" is not mentioned in "-chains-" property, it will - // be chained using the legacy mode: using "after" chaining, - // calling preamble() method before each constructor, if available, - // and calling postscript() after all constructors were executed. - // If the hint is "after", it is chained as a regular method, but - // postscript() will be called after the chain of constructors. - // "constructor" cannot be chained "before", but it allows - // a special hint string: "manual", which means that constructors - // are not going to be chained in any way, and programmer will call - // them manually using this.inherited(). In the latter case - // postscript() will be called after the construction. - // - // All chaining hints are "inherited" from base classes and - // potentially can be overridden. Be very careful when overriding - // hints! Make sure that all chained methods can work in a proposed - // manner of chaining. - // - // Once a method was chained, it is impossible to unchain it. The - // only exception is "constructor". You don't need to define a - // method in order to supply a chaining hint. - // - // If a method is chained, it cannot use this.inherited() because - // all other methods in the hierarchy will be called automatically. - // - // Usually constructors and initializers of any kind are chained - // using "after" and destructors of any kind are chained as - // "before". Note that chaining assumes that chained methods do not - // return any value: any returned value will be discarded. - // - // example: - // | declare("my.classes.bar", my.classes.foo, { - // | // properties to be added to the class prototype - // | someValue: 2, - // | // initialization function - // | constructor: function(){ - // | this.myComplicatedObject = new ReallyComplicatedObject(); - // | }, - // | // other functions - // | someMethod: function(){ - // | doStuff(); - // | } - // | }); - // - // example: - // | var MyBase = declare(null, { - // | // constructor, properties, and methods go here - // | // ... - // | }); - // | var MyClass1 = declare(MyBase, { - // | // constructor, properties, and methods go here - // | // ... - // | }); - // | var MyClass2 = declare(MyBase, { - // | // constructor, properties, and methods go here - // | // ... - // | }); - // | var MyDiamond = declare([MyClass1, MyClass2], { - // | // constructor, properties, and methods go here - // | // ... - // | }); - // - // example: - // | var F = function(){ console.log("raw constructor"); }; - // | F.prototype.method = function(){ - // | console.log("raw method"); - // | }; - // | var A = declare(F, { - // | constructor: function(){ - // | console.log("A.constructor"); - // | }, - // | method: function(){ - // | console.log("before calling F.method..."); - // | this.inherited(arguments); - // | console.log("...back in A"); - // | } - // | }); - // | new A().method(); - // | // will print: - // | // raw constructor - // | // A.constructor - // | // before calling F.method... - // | // raw method - // | // ...back in A - // - // example: - // | var A = declare(null, { - // | "-chains-": { - // | destroy: "before" - // | } - // | }); - // | var B = declare(A, { - // | constructor: function(){ - // | console.log("B.constructor"); - // | }, - // | destroy: function(){ - // | console.log("B.destroy"); - // | } - // | }); - // | var C = declare(B, { - // | constructor: function(){ - // | console.log("C.constructor"); - // | }, - // | destroy: function(){ - // | console.log("C.destroy"); - // | } - // | }); - // | new C().destroy(); - // | // prints: - // | // B.constructor - // | // C.constructor - // | // C.destroy - // | // B.destroy - // - // example: - // | var A = declare(null, { - // | "-chains-": { - // | constructor: "manual" - // | } - // | }); - // | var B = declare(A, { - // | constructor: function(){ - // | // ... - // | // call the base constructor with new parameters - // | this.inherited(arguments, [1, 2, 3]); - // | // ... - // | } - // | }); - // - // example: - // | var A = declare(null, { - // | "-chains-": { - // | m1: "before" - // | }, - // | m1: function(){ - // | console.log("A.m1"); - // | }, - // | m2: function(){ - // | console.log("A.m2"); - // | } - // | }); - // | var B = declare(A, { - // | "-chains-": { - // | m2: "after" - // | }, - // | m1: function(){ - // | console.log("B.m1"); - // | }, - // | m2: function(){ - // | console.log("B.m2"); - // | } - // | }); - // | var x = new B(); - // | x.m1(); - // | // prints: - // | // B.m1 - // | // A.m1 - // | x.m2(); - // | // prints: - // | // A.m2 - // | // B.m2 - - // crack parameters - if(typeof className != "string"){ - props = superclass; - superclass = className; - className = ""; - } - props = props || {}; - - var proto, i, t, ctor, name, bases, chains, mixins = 1, parents = superclass; - - // build a prototype - if(opts.call(superclass) == "[object Array]"){ - // C3 MRO - bases = c3mro(superclass, className); - t = bases[0]; - mixins = bases.length - t; - superclass = bases[mixins]; - }else{ - bases = [0]; - if(superclass){ - if(opts.call(superclass) == "[object Function]"){ - t = superclass._meta; - bases = bases.concat(t ? t.bases : superclass); - }else{ - err("base class is not a callable constructor.", className); - } - }else if(superclass !== null){ - err("unknown base class. Did you use dojo.require to pull it in?", className); - } - } - if(superclass){ - for(i = mixins - 1;; --i){ - proto = forceNew(superclass); - if(!i){ - // stop if nothing to add (the last base) - break; - } - // mix in properties - t = bases[i]; - (t._meta ? mixOwn : mix)(proto, t.prototype); - // chain in new constructor - ctor = new Function; - ctor.superclass = superclass; - ctor.prototype = proto; - superclass = proto.constructor = ctor; - } - }else{ - proto = {}; - } - // add all properties - declare.safeMixin(proto, props); - // add constructor - t = props.constructor; - if(t !== op.constructor){ - t.nom = cname; - proto.constructor = t; - } - - // collect chains and flags - for(i = mixins - 1; i; --i){ // intentional assignment - t = bases[i]._meta; - if(t && t.chains){ - chains = mix(chains || {}, t.chains); - } - } - if(proto["-chains-"]){ - chains = mix(chains || {}, proto["-chains-"]); - } - - // build ctor - t = !chains || !chains.hasOwnProperty(cname); - bases[0] = ctor = (chains && chains.constructor === "manual") ? simpleConstructor(bases) : - (bases.length == 1 ? singleConstructor(props.constructor, t) : chainedConstructor(bases, t)); - - // add meta information to the constructor - ctor._meta = {bases: bases, hidden: props, chains: chains, - parents: parents, ctor: props.constructor}; - ctor.superclass = superclass && superclass.prototype; - ctor.extend = extend; - ctor.createSubclass = createSubclass; - ctor.prototype = proto; - proto.constructor = ctor; - - // add "standard" methods to the prototype - proto.getInherited = getInherited; - proto.isInstanceOf = isInstanceOf; - proto.inherited = inheritedImpl; - proto.__inherited = inherited; - - // add name if specified - if(className){ - proto.declaredClass = className; - lang.setObject(className, ctor); - } - - // build chains and add them to the prototype - if(chains){ - for(name in chains){ - if(proto[name] && typeof chains[name] == "string" && name != cname){ - t = proto[name] = chain(name, bases, chains[name] === "after"); - t.nom = name; - } - } - } - // chained methods do not return values - // no need to chain "invisible" functions - - return ctor; // Function - } - - /*===== - declare.__DeclareCreatedObject = { - // summary: - // dojo/_base/declare() returns a constructor `C`. `new C()` returns an Object with the following - // methods, in addition to the methods and properties specified via the arguments passed to declare(). - - inherited: function(name, args, newArgs){ - // summary: - // Calls a super method. - // name: String? - // The optional method name. Should be the same as the caller's - // name. Usually "name" is specified in complex dynamic cases, when - // the calling method was dynamically added, undecorated by - // declare(), and it cannot be determined. - // args: Arguments - // The caller supply this argument, which should be the original - // "arguments". - // newArgs: Object? - // If "true", the found function will be returned without - // executing it. - // If Array, it will be used to call a super method. Otherwise - // "args" will be used. - // returns: - // Whatever is returned by a super method, or a super method itself, - // if "true" was specified as newArgs. - // description: - // This method is used inside method of classes produced with - // declare() to call a super method (next in the chain). It is - // used for manually controlled chaining. Consider using the regular - // chaining, because it is faster. Use "this.inherited()" only in - // complex cases. - // - // This method cannot me called from automatically chained - // constructors including the case of a special (legacy) - // constructor chaining. It cannot be called from chained methods. - // - // If "this.inherited()" cannot find the next-in-chain method, it - // does nothing and returns "undefined". The last method in chain - // can be a default method implemented in Object, which will be - // called last. - // - // If "name" is specified, it is assumed that the method that - // received "args" is the parent method for this call. It is looked - // up in the chain list and if it is found the next-in-chain method - // is called. If it is not found, the first-in-chain method is - // called. - // - // If "name" is not specified, it will be derived from the calling - // method (using a methoid property "nom"). - // - // example: - // | var B = declare(A, { - // | method1: function(a, b, c){ - // | this.inherited(arguments); - // | }, - // | method2: function(a, b){ - // | return this.inherited(arguments, [a + b]); - // | } - // | }); - // | // next method is not in the chain list because it is added - // | // manually after the class was created. - // | B.prototype.method3 = function(){ - // | console.log("This is a dynamically-added method."); - // | this.inherited("method3", arguments); - // | }; - // example: - // | var B = declare(A, { - // | method: function(a, b){ - // | var super = this.inherited(arguments, true); - // | // ... - // | if(!super){ - // | console.log("there is no super method"); - // | return 0; - // | } - // | return super.apply(this, arguments); - // | } - // | }); - return {}; // Object - }, - - getInherited: function(name, args){ - // summary: - // Returns a super method. - // name: String? - // The optional method name. Should be the same as the caller's - // name. Usually "name" is specified in complex dynamic cases, when - // the calling method was dynamically added, undecorated by - // declare(), and it cannot be determined. - // args: Arguments - // The caller supply this argument, which should be the original - // "arguments". - // returns: - // Returns a super method (Function) or "undefined". - // description: - // This method is a convenience method for "this.inherited()". - // It uses the same algorithm but instead of executing a super - // method, it returns it, or "undefined" if not found. - // - // example: - // | var B = declare(A, { - // | method: function(a, b){ - // | var super = this.getInherited(arguments); - // | // ... - // | if(!super){ - // | console.log("there is no super method"); - // | return 0; - // | } - // | return super.apply(this, arguments); - // | } - // | }); - return {}; // Object - }, - - isInstanceOf: function(cls){ - // summary: - // Checks the inheritance chain to see if it is inherited from this - // class. - // cls: Function - // Class constructor. - // returns: - // "true", if this object is inherited from this class, "false" - // otherwise. - // description: - // This method is used with instances of classes produced with - // declare() to determine of they support a certain interface or - // not. It models "instanceof" operator. - // - // example: - // | var A = declare(null, { - // | // constructor, properties, and methods go here - // | // ... - // | }); - // | var B = declare(null, { - // | // constructor, properties, and methods go here - // | // ... - // | }); - // | var C = declare([A, B], { - // | // constructor, properties, and methods go here - // | // ... - // | }); - // | var D = declare(A, { - // | // constructor, properties, and methods go here - // | // ... - // | }); - // | - // | var a = new A(), b = new B(), c = new C(), d = new D(); - // | - // | console.log(a.isInstanceOf(A)); // true - // | console.log(b.isInstanceOf(A)); // false - // | console.log(c.isInstanceOf(A)); // true - // | console.log(d.isInstanceOf(A)); // true - // | - // | console.log(a.isInstanceOf(B)); // false - // | console.log(b.isInstanceOf(B)); // true - // | console.log(c.isInstanceOf(B)); // true - // | console.log(d.isInstanceOf(B)); // false - // | - // | console.log(a.isInstanceOf(C)); // false - // | console.log(b.isInstanceOf(C)); // false - // | console.log(c.isInstanceOf(C)); // true - // | console.log(d.isInstanceOf(C)); // false - // | - // | console.log(a.isInstanceOf(D)); // false - // | console.log(b.isInstanceOf(D)); // false - // | console.log(c.isInstanceOf(D)); // false - // | console.log(d.isInstanceOf(D)); // true - return {}; // Object - }, - - extend: function(source){ - // summary: - // Adds all properties and methods of source to constructor's - // prototype, making them available to all instances created with - // constructor. This method is specific to constructors created with - // declare(). - // source: Object - // Source object which properties are going to be copied to the - // constructor's prototype. - // description: - // Adds source properties to the constructor's prototype. It can - // override existing properties. - // - // This method is similar to dojo.extend function, but it is specific - // to constructors produced by declare(). It is implemented - // using dojo.safeMixin, and it skips a constructor property, - // and properly decorates copied functions. - // - // example: - // | var A = declare(null, { - // | m1: function(){}, - // | s1: "Popokatepetl" - // | }); - // | A.extend({ - // | m1: function(){}, - // | m2: function(){}, - // | f1: true, - // | d1: 42 - // | }); - }, - - createSubclass: function(mixins, props){ - // summary: - // Create a subclass of the declared class from a list of base classes. - // mixins: Function[] - // Specifies a list of bases (the left-most one is the most deepest - // base). - // props: Object? - // An optional object whose properties are copied to the created prototype. - // returns: dojo/_base/declare.__DeclareCreatedObject - // New constructor function. - // description: - // Create a constructor using a compact notation for inheritance and - // prototype extension. - // - // Mixin ancestors provide a type of multiple inheritance. - // Prototypes of mixin ancestors are copied to the new class: - // changes to mixin prototypes will not affect classes to which - // they have been mixed in. - // - // example: - // | var A = declare(null, { - // | m1: function(){}, - // | s1: "bar" - // | }); - // | var B = declare(null, { - // | m2: function(){}, - // | s2: "foo" - // | }); - // | var C = declare(null, { - // | }); - // | var D1 = A.createSubclass([B, C], { - // | m1: function(){}, - // | d1: 42 - // | }); - // | var d1 = new D1(); - // | - // | // this is equivalent to: - // | var D2 = declare([A, B, C], { - // | m1: function(){}, - // | d1: 42 - // | }); - // | var d2 = new D2(); - } - }; - =====*/ - - // For back-compat, remove for 2.0 - dojo.safeMixin = declare.safeMixin = safeMixin; - dojo.declare = declare; - - return declare; -}); diff --git a/lib/dojo/_base/event.js b/lib/dojo/_base/event.js deleted file mode 100644 index eb72029..0000000 --- a/lib/dojo/_base/event.js +++ /dev/null @@ -1,39 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/_base/event",["./kernel","../on","../has","../dom-geometry"],function(_1,on,_2,_3){ -if(on._fixEvent){ -var _4=on._fixEvent; -on._fixEvent=function(_5,se){ -_5=_4(_5,se); -if(_5){ -_3.normalizeEvent(_5); -} -return _5; -}; -} -var _6={fix:function(_7,_8){ -if(on._fixEvent){ -return on._fixEvent(_7,_8); -} -return _7; -},stop:function(_9){ -if(_2("dom-addeventlistener")||(_9&&_9.preventDefault)){ -_9.preventDefault(); -_9.stopPropagation(); -}else{ -_9=_9||window.event; -_9.cancelBubble=true; -on._preventDefault.call(_9); -} -}}; -if(1){ -_1.fixEvent=_6.fix; -_1.stopEvent=_6.stop; -} -return _6; -}); diff --git a/lib/dojo/_base/event.js.uncompressed.js b/lib/dojo/_base/event.js.uncompressed.js deleted file mode 100644 index 8a0597f..0000000 --- a/lib/dojo/_base/event.js.uncompressed.js +++ /dev/null @@ -1,59 +0,0 @@ -define("dojo/_base/event", ["./kernel", "../on", "../has", "../dom-geometry"], function(dojo, on, has, dom){ - // module: - // dojo/_base/event - - if(on._fixEvent){ - var fixEvent = on._fixEvent; - on._fixEvent = function(evt, se){ - // add some additional normalization for back-compat, this isn't in on.js because it is somewhat more expensive - evt = fixEvent(evt, se); - if(evt){ - dom.normalizeEvent(evt); - } - return evt; - }; - } - - var ret = { - // summary: - // This module defines dojo DOM event API. Usually you should use dojo/on, and evt.stopPropagation() + - // evt.preventDefault(), rather than this module. - - fix: function(/*Event*/ evt, /*DOMNode*/ sender){ - // summary: - // normalizes properties on the event object including event - // bubbling methods, keystroke normalization, and x/y positions - // evt: Event - // native event object - // sender: DOMNode - // node to treat as "currentTarget" - if(on._fixEvent){ - return on._fixEvent(evt, sender); - } - return evt; // Event - }, - - stop: function(/*Event*/ evt){ - // summary: - // prevents propagation and clobbers the default action of the - // passed event - // evt: Event - // The event object. If omitted, window.event is used on IE. - if(has("dom-addeventlistener") || (evt && evt.preventDefault)){ - evt.preventDefault(); - evt.stopPropagation(); - }else{ - evt = evt || window.event; - evt.cancelBubble = true; - on._preventDefault.call(evt); - } - } - }; - - if( 1 ){ - dojo.fixEvent = ret.fix; - dojo.stopEvent = ret.stop; - } - - return ret; -}); diff --git a/lib/dojo/_base/fx.js b/lib/dojo/_base/fx.js deleted file mode 100644 index 640e06b..0000000 --- a/lib/dojo/_base/fx.js +++ /dev/null @@ -1,301 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/_base/fx",["./kernel","./config","./lang","../Evented","./Color","../aspect","../sniff","../dom","../dom-style"],function(_1,_2,_3,_4,_5,_6,_7,_8,_9){ -var _a=_3.mixin; -var _b={}; -var _c=_b._Line=function(_d,_e){ -this.start=_d; -this.end=_e; -}; -_c.prototype.getValue=function(n){ -return ((this.end-this.start)*n)+this.start; -}; -var _f=_b.Animation=function(_10){ -_a(this,_10); -if(_3.isArray(this.curve)){ -this.curve=new _c(this.curve[0],this.curve[1]); -} -}; -_f.prototype=new _4(); -_3.extend(_f,{duration:350,repeat:0,rate:20,_percent:0,_startRepeatCount:0,_getStep:function(){ -var _11=this._percent,_12=this.easing; -return _12?_12(_11):_11; -},_fire:function(evt,_13){ -var a=_13||[]; -if(this[evt]){ -if(_2.debugAtAllCosts){ -this[evt].apply(this,a); -}else{ -try{ -this[evt].apply(this,a); -} -catch(e){ -console.error("exception in animation handler for:",evt); -console.error(e); -} -} -} -return this; -},play:function(_14,_15){ -var _16=this; -if(_16._delayTimer){ -_16._clearTimer(); -} -if(_15){ -_16._stopTimer(); -_16._active=_16._paused=false; -_16._percent=0; -}else{ -if(_16._active&&!_16._paused){ -return _16; -} -} -_16._fire("beforeBegin",[_16.node]); -var de=_14||_16.delay,_17=_3.hitch(_16,"_play",_15); -if(de>0){ -_16._delayTimer=setTimeout(_17,de); -return _16; -} -_17(); -return _16; -},_play:function(_18){ -var _19=this; -if(_19._delayTimer){ -_19._clearTimer(); -} -_19._startTime=new Date().valueOf(); -if(_19._paused){ -_19._startTime-=_19.duration*_19._percent; -} -_19._active=true; -_19._paused=false; -var _1a=_19.curve.getValue(_19._getStep()); -if(!_19._percent){ -if(!_19._startRepeatCount){ -_19._startRepeatCount=_19.repeat; -} -_19._fire("onBegin",[_1a]); -} -_19._fire("onPlay",[_1a]); -_19._cycle(); -return _19; -},pause:function(){ -var _1b=this; -if(_1b._delayTimer){ -_1b._clearTimer(); -} -_1b._stopTimer(); -if(!_1b._active){ -return _1b; -} -_1b._paused=true; -_1b._fire("onPause",[_1b.curve.getValue(_1b._getStep())]); -return _1b; -},gotoPercent:function(_1c,_1d){ -var _1e=this; -_1e._stopTimer(); -_1e._active=_1e._paused=true; -_1e._percent=_1c; -if(_1d){ -_1e.play(); -} -return _1e; -},stop:function(_1f){ -var _20=this; -if(_20._delayTimer){ -_20._clearTimer(); -} -if(!_20._timer){ -return _20; -} -_20._stopTimer(); -if(_1f){ -_20._percent=1; -} -_20._fire("onStop",[_20.curve.getValue(_20._getStep())]); -_20._active=_20._paused=false; -return _20; -},destroy:function(){ -this.stop(); -},status:function(){ -if(this._active){ -return this._paused?"paused":"playing"; -} -return "stopped"; -},_cycle:function(){ -var _21=this; -if(_21._active){ -var _22=new Date().valueOf(); -var _23=_21.duration===0?1:(_22-_21._startTime)/(_21.duration); -if(_23>=1){ -_23=1; -} -_21._percent=_23; -if(_21.easing){ -_23=_21.easing(_23); -} -_21._fire("onAnimate",[_21.curve.getValue(_23)]); -if(_21._percent<1){ -_21._startTimer(); -}else{ -_21._active=false; -if(_21.repeat>0){ -_21.repeat--; -_21.play(null,true); -}else{ -if(_21.repeat==-1){ -_21.play(null,true); -}else{ -if(_21._startRepeatCount){ -_21.repeat=_21._startRepeatCount; -_21._startRepeatCount=0; -} -} -} -_21._percent=0; -_21._fire("onEnd",[_21.node]); -!_21.repeat&&_21._stopTimer(); -} -} -return _21; -},_clearTimer:function(){ -clearTimeout(this._delayTimer); -delete this._delayTimer; -}}); -var ctr=0,_24=null,_25={run:function(){ -}}; -_3.extend(_f,{_startTimer:function(){ -if(!this._timer){ -this._timer=_6.after(_25,"run",_3.hitch(this,"_cycle"),true); -ctr++; -} -if(!_24){ -_24=setInterval(_3.hitch(_25,"run"),this.rate); -} -},_stopTimer:function(){ -if(this._timer){ -this._timer.remove(); -this._timer=null; -ctr--; -} -if(ctr<=0){ -clearInterval(_24); -_24=null; -ctr=0; -} -}}); -var _26=_7("ie")?function(_27){ -var ns=_27.style; -if(!ns.width.length&&_9.get(_27,"width")=="auto"){ -ns.width="auto"; -} -}:function(){ -}; -_b._fade=function(_28){ -_28.node=_8.byId(_28.node); -var _29=_a({properties:{}},_28),_2a=(_29.properties.opacity={}); -_2a.start=!("start" in _29)?function(){ -return +_9.get(_29.node,"opacity")||0; -}:_29.start; -_2a.end=_29.end; -var _2b=_b.animateProperty(_29); -_6.after(_2b,"beforeBegin",_3.partial(_26,_29.node),true); -return _2b; -}; -_b.fadeIn=function(_2c){ -return _b._fade(_a({end:1},_2c)); -}; -_b.fadeOut=function(_2d){ -return _b._fade(_a({end:0},_2d)); -}; -_b._defaultEasing=function(n){ -return 0.5+((Math.sin((n+1.5)*Math.PI))/2); -}; -var _2e=function(_2f){ -this._properties=_2f; -for(var p in _2f){ -var _30=_2f[p]; -if(_30.start instanceof _5){ -_30.tempColor=new _5(); -} -} -}; -_2e.prototype.getValue=function(r){ -var ret={}; -for(var p in this._properties){ -var _31=this._properties[p],_32=_31.start; -if(_32 instanceof _5){ -ret[p]=_5.blendColors(_32,_31.end,r,_31.tempColor).toCss(); -}else{ -if(!_3.isArray(_32)){ -ret[p]=((_31.end-_32)*r)+_32+(p!="opacity"?_31.units||"px":0); -} -} -} -return ret; -}; -_b.animateProperty=function(_33){ -var n=_33.node=_8.byId(_33.node); -if(!_33.easing){ -_33.easing=_1._defaultEasing; -} -var _34=new _f(_33); -_6.after(_34,"beforeBegin",_3.hitch(_34,function(){ -var pm={}; -for(var p in this.properties){ -if(p=="width"||p=="height"){ -this.node.display="block"; -} -var _35=this.properties[p]; -if(_3.isFunction(_35)){ -_35=_35(n); -} -_35=pm[p]=_a({},(_3.isObject(_35)?_35:{end:_35})); -if(_3.isFunction(_35.start)){ -_35.start=_35.start(n); -} -if(_3.isFunction(_35.end)){ -_35.end=_35.end(n); -} -var _36=(p.toLowerCase().indexOf("color")>=0); -function _37(_38,p){ -var v={height:_38.offsetHeight,width:_38.offsetWidth}[p]; -if(v!==undefined){ -return v; -} -v=_9.get(_38,p); -return (p=="opacity")?+v:(_36?v:parseFloat(v)); -}; -if(!("end" in _35)){ -_35.end=_37(n,p); -}else{ -if(!("start" in _35)){ -_35.start=_37(n,p); -} -} -if(_36){ -_35.start=new _5(_35.start); -_35.end=new _5(_35.end); -}else{ -_35.start=(p=="opacity")?+_35.start:parseFloat(_35.start); -} -} -this.curve=new _2e(pm); -}),true); -_6.after(_34,"onAnimate",_3.hitch(_9,"set",_34.node),true); -return _34; -}; -_b.anim=function(_39,_3a,_3b,_3c,_3d,_3e){ -return _b.animateProperty({node:_39,duration:_3b||_f.prototype.duration,properties:_3a,easing:_3c,onEnd:_3d}).play(_3e||0); -}; -if(1){ -_a(_1,_b); -_1._Animation=_f; -} -return _b; -}); diff --git a/lib/dojo/_base/fx.js.uncompressed.js b/lib/dojo/_base/fx.js.uncompressed.js deleted file mode 100644 index 208edbe..0000000 --- a/lib/dojo/_base/fx.js.uncompressed.js +++ /dev/null @@ -1,676 +0,0 @@ -define("dojo/_base/fx", ["./kernel", "./config", /*===== "./declare", =====*/ "./lang", "../Evented", "./Color", "../aspect", "../sniff", "../dom", "../dom-style"], - function(dojo, config, /*===== declare, =====*/ lang, Evented, Color, aspect, has, dom, style){ - // module: - // dojo/_base/fx - // notes: - // Animation loosely package based on Dan Pupius' work, contributed under CLA; see - // http://pupius.co.uk/js/Toolkit.Drawing.js - - var _mixin = lang.mixin; - - // Module export - var basefx = { - // summary: - // This module defines the base dojo/_base/fx implementation. - }; - - var _Line = basefx._Line = function(/*int*/ start, /*int*/ end){ - // summary: - // Object used to generate values from a start value to an end value - // start: int - // Beginning value for range - // end: int - // Ending value for range - this.start = start; - this.end = end; - }; - - _Line.prototype.getValue = function(/*float*/ n){ - // summary: - // Returns the point on the line - // n: - // a floating point number greater than 0 and less than 1 - return ((this.end - this.start) * n) + this.start; // Decimal - }; - - var Animation = basefx.Animation = function(args){ - // summary: - // A generic animation class that fires callbacks into its handlers - // object at various states. - // description: - // A generic animation class that fires callbacks into its handlers - // object at various states. Nearly all dojo animation functions - // return an instance of this method, usually without calling the - // .play() method beforehand. Therefore, you will likely need to - // call .play() on instances of `Animation` when one is - // returned. - // args: Object - // The 'magic argument', mixing all the properties into this - // animation instance. - - _mixin(this, args); - if(lang.isArray(this.curve)){ - this.curve = new _Line(this.curve[0], this.curve[1]); - } - - }; - Animation.prototype = new Evented(); - - lang.extend(Animation, { - // duration: Integer - // The time in milliseconds the animation will take to run - duration: 350, - - /*===== - // curve: _Line|Array - // A two element array of start and end values, or a `_Line` instance to be - // used in the Animation. - curve: null, - - // easing: Function? - // A Function to adjust the acceleration (or deceleration) of the progress - // across a _Line - easing: null, - =====*/ - - // repeat: Integer? - // The number of times to loop the animation - repeat: 0, - - // rate: Integer? - // the time in milliseconds to wait before advancing to next frame - // (used as a fps timer: 1000/rate = fps) - rate: 20 /* 50 fps */, - - /*===== - // delay: Integer? - // The time in milliseconds to wait before starting animation after it - // has been .play()'ed - delay: null, - - // beforeBegin: Event? - // Synthetic event fired before a Animation begins playing (synchronous) - beforeBegin: null, - - // onBegin: Event? - // Synthetic event fired as a Animation begins playing (useful?) - onBegin: null, - - // onAnimate: Event? - // Synthetic event fired at each interval of the Animation - onAnimate: null, - - // onEnd: Event? - // Synthetic event fired after the final frame of the Animation - onEnd: null, - - // onPlay: Event? - // Synthetic event fired any time the Animation is play()'ed - onPlay: null, - - // onPause: Event? - // Synthetic event fired when the Animation is paused - onPause: null, - - // onStop: Event - // Synthetic event fires when the Animation is stopped - onStop: null, - - =====*/ - - _percent: 0, - _startRepeatCount: 0, - - _getStep: function(){ - var _p = this._percent, - _e = this.easing - ; - return _e ? _e(_p) : _p; - }, - _fire: function(/*Event*/ evt, /*Array?*/ args){ - // summary: - // Convenience function. Fire event "evt" and pass it the - // arguments specified in "args". - // description: - // Convenience function. Fire event "evt" and pass it the - // arguments specified in "args". - // Fires the callback in the scope of this Animation - // instance. - // evt: - // The event to fire. - // args: - // The arguments to pass to the event. - var a = args||[]; - if(this[evt]){ - if(config.debugAtAllCosts){ - this[evt].apply(this, a); - }else{ - try{ - this[evt].apply(this, a); - }catch(e){ - // squelch and log because we shouldn't allow exceptions in - // synthetic event handlers to cause the internal timer to run - // amuck, potentially pegging the CPU. I'm not a fan of this - // squelch, but hopefully logging will make it clear what's - // going on - console.error("exception in animation handler for:", evt); - console.error(e); - } - } - } - return this; // Animation - }, - - play: function(/*int?*/ delay, /*Boolean?*/ gotoStart){ - // summary: - // Start the animation. - // delay: - // How many milliseconds to delay before starting. - // gotoStart: - // If true, starts the animation from the beginning; otherwise, - // starts it from its current position. - // returns: Animation - // The instance to allow chaining. - - var _t = this; - if(_t._delayTimer){ _t._clearTimer(); } - if(gotoStart){ - _t._stopTimer(); - _t._active = _t._paused = false; - _t._percent = 0; - }else if(_t._active && !_t._paused){ - return _t; - } - - _t._fire("beforeBegin", [_t.node]); - - var de = delay || _t.delay, - _p = lang.hitch(_t, "_play", gotoStart); - - if(de > 0){ - _t._delayTimer = setTimeout(_p, de); - return _t; - } - _p(); - return _t; // Animation - }, - - _play: function(gotoStart){ - var _t = this; - if(_t._delayTimer){ _t._clearTimer(); } - _t._startTime = new Date().valueOf(); - if(_t._paused){ - _t._startTime -= _t.duration * _t._percent; - } - - _t._active = true; - _t._paused = false; - var value = _t.curve.getValue(_t._getStep()); - if(!_t._percent){ - if(!_t._startRepeatCount){ - _t._startRepeatCount = _t.repeat; - } - _t._fire("onBegin", [value]); - } - - _t._fire("onPlay", [value]); - - _t._cycle(); - return _t; // Animation - }, - - pause: function(){ - // summary: - // Pauses a running animation. - var _t = this; - if(_t._delayTimer){ _t._clearTimer(); } - _t._stopTimer(); - if(!_t._active){ return _t; /*Animation*/ } - _t._paused = true; - _t._fire("onPause", [_t.curve.getValue(_t._getStep())]); - return _t; // Animation - }, - - gotoPercent: function(/*Decimal*/ percent, /*Boolean?*/ andPlay){ - // summary: - // Sets the progress of the animation. - // percent: - // A percentage in decimal notation (between and including 0.0 and 1.0). - // andPlay: - // If true, play the animation after setting the progress. - var _t = this; - _t._stopTimer(); - _t._active = _t._paused = true; - _t._percent = percent; - if(andPlay){ _t.play(); } - return _t; // Animation - }, - - stop: function(/*boolean?*/ gotoEnd){ - // summary: - // Stops a running animation. - // gotoEnd: - // If true, the animation will end. - var _t = this; - if(_t._delayTimer){ _t._clearTimer(); } - if(!_t._timer){ return _t; /* Animation */ } - _t._stopTimer(); - if(gotoEnd){ - _t._percent = 1; - } - _t._fire("onStop", [_t.curve.getValue(_t._getStep())]); - _t._active = _t._paused = false; - return _t; // Animation - }, - - destroy: function(){ - // summary: - // cleanup the animation - this.stop(); - }, - - status: function(){ - // summary: - // Returns a string token representation of the status of - // the animation, one of: "paused", "playing", "stopped" - if(this._active){ - return this._paused ? "paused" : "playing"; // String - } - return "stopped"; // String - }, - - _cycle: function(){ - var _t = this; - if(_t._active){ - var curr = new Date().valueOf(); - // Allow durations of 0 (instant) by setting step to 1 - see #13798 - var step = _t.duration === 0 ? 1 : (curr - _t._startTime) / (_t.duration); - - if(step >= 1){ - step = 1; - } - _t._percent = step; - - // Perform easing - if(_t.easing){ - step = _t.easing(step); - } - - _t._fire("onAnimate", [_t.curve.getValue(step)]); - - if(_t._percent < 1){ - _t._startTimer(); - }else{ - _t._active = false; - - if(_t.repeat > 0){ - _t.repeat--; - _t.play(null, true); - }else if(_t.repeat == -1){ - _t.play(null, true); - }else{ - if(_t._startRepeatCount){ - _t.repeat = _t._startRepeatCount; - _t._startRepeatCount = 0; - } - } - _t._percent = 0; - _t._fire("onEnd", [_t.node]); - !_t.repeat && _t._stopTimer(); - } - } - return _t; // Animation - }, - - _clearTimer: function(){ - // summary: - // Clear the play delay timer - clearTimeout(this._delayTimer); - delete this._delayTimer; - } - - }); - - // the local timer, stubbed into all Animation instances - var ctr = 0, - timer = null, - runner = { - run: function(){} - }; - - lang.extend(Animation, { - - _startTimer: function(){ - if(!this._timer){ - this._timer = aspect.after(runner, "run", lang.hitch(this, "_cycle"), true); - ctr++; - } - if(!timer){ - timer = setInterval(lang.hitch(runner, "run"), this.rate); - } - }, - - _stopTimer: function(){ - if(this._timer){ - this._timer.remove(); - this._timer = null; - ctr--; - } - if(ctr <= 0){ - clearInterval(timer); - timer = null; - ctr = 0; - } - } - - }); - - var _makeFadeable = - has("ie") ? function(node){ - // only set the zoom if the "tickle" value would be the same as the - // default - var ns = node.style; - // don't set the width to auto if it didn't already cascade that way. - // We don't want to f anyones designs - if(!ns.width.length && style.get(node, "width") == "auto"){ - ns.width = "auto"; - } - } : - function(){}; - - basefx._fade = function(/*Object*/ args){ - // summary: - // Returns an animation that will fade the node defined by - // args.node from the start to end values passed (args.start - // args.end) (end is mandatory, start is optional) - - args.node = dom.byId(args.node); - var fArgs = _mixin({ properties: {} }, args), - props = (fArgs.properties.opacity = {}); - - props.start = !("start" in fArgs) ? - function(){ - return +style.get(fArgs.node, "opacity")||0; - } : fArgs.start; - props.end = fArgs.end; - - var anim = basefx.animateProperty(fArgs); - aspect.after(anim, "beforeBegin", lang.partial(_makeFadeable, fArgs.node), true); - - return anim; // Animation - }; - - /*===== - var __FadeArgs = declare(null, { - // node: DOMNode|String - // The node referenced in the animation - // duration: Integer? - // Duration of the animation in milliseconds. - // easing: Function? - // An easing function. - }); - =====*/ - - basefx.fadeIn = function(/*__FadeArgs*/ args){ - // summary: - // Returns an animation that will fade node defined in 'args' from - // its current opacity to fully opaque. - return basefx._fade(_mixin({ end: 1 }, args)); // Animation - }; - - basefx.fadeOut = function(/*__FadeArgs*/ args){ - // summary: - // Returns an animation that will fade node defined in 'args' - // from its current opacity to fully transparent. - return basefx._fade(_mixin({ end: 0 }, args)); // Animation - }; - - basefx._defaultEasing = function(/*Decimal?*/ n){ - // summary: - // The default easing function for Animation(s) - return 0.5 + ((Math.sin((n + 1.5) * Math.PI)) / 2); // Decimal - }; - - var PropLine = function(properties){ - // PropLine is an internal class which is used to model the values of - // an a group of CSS properties across an animation lifecycle. In - // particular, the "getValue" function handles getting interpolated - // values between start and end for a particular CSS value. - this._properties = properties; - for(var p in properties){ - var prop = properties[p]; - if(prop.start instanceof Color){ - // create a reusable temp color object to keep intermediate results - prop.tempColor = new Color(); - } - } - }; - - PropLine.prototype.getValue = function(r){ - var ret = {}; - for(var p in this._properties){ - var prop = this._properties[p], - start = prop.start; - if(start instanceof Color){ - ret[p] = Color.blendColors(start, prop.end, r, prop.tempColor).toCss(); - }else if(!lang.isArray(start)){ - ret[p] = ((prop.end - start) * r) + start + (p != "opacity" ? prop.units || "px" : 0); - } - } - return ret; - }; - - /*===== - var __AnimArgs = declare(__FadeArgs, { - // properties: Object? - // A hash map of style properties to Objects describing the transition, - // such as the properties of _Line with an additional 'units' property - properties: {} - - //TODOC: add event callbacks - }); - =====*/ - - basefx.animateProperty = function(/*__AnimArgs*/ args){ - // summary: - // Returns an animation that will transition the properties of - // node defined in `args` depending how they are defined in - // `args.properties` - // - // description: - // Foundation of most `dojo/_base/fx` - // animations. It takes an object of "properties" corresponding to - // style properties, and animates them in parallel over a set - // duration. - // - // example: - // A simple animation that changes the width of the specified node. - // | basefx.animateProperty({ - // | node: "nodeId", - // | properties: { width: 400 }, - // | }).play(); - // Dojo figures out the start value for the width and converts the - // integer specified for the width to the more expressive but - // verbose form `{ width: { end: '400', units: 'px' } }` which you - // can also specify directly. Defaults to 'px' if omitted. - // - // example: - // Animate width, height, and padding over 2 seconds... the - // pedantic way: - // | basefx.animateProperty({ node: node, duration:2000, - // | properties: { - // | width: { start: '200', end: '400', units:"px" }, - // | height: { start:'200', end: '400', units:"px" }, - // | paddingTop: { start:'5', end:'50', units:"px" } - // | } - // | }).play(); - // Note 'paddingTop' is used over 'padding-top'. Multi-name CSS properties - // are written using "mixed case", as the hyphen is illegal as an object key. - // - // example: - // Plug in a different easing function and register a callback for - // when the animation ends. Easing functions accept values between - // zero and one and return a value on that basis. In this case, an - // exponential-in curve. - // | basefx.animateProperty({ - // | node: "nodeId", - // | // dojo figures out the start value - // | properties: { width: { end: 400 } }, - // | easing: function(n){ - // | return (n==0) ? 0 : Math.pow(2, 10 * (n - 1)); - // | }, - // | onEnd: function(node){ - // | // called when the animation finishes. The animation - // | // target is passed to this function - // | } - // | }).play(500); // delay playing half a second - // - // example: - // Like all `Animation`s, animateProperty returns a handle to the - // Animation instance, which fires the events common to Dojo FX. Use `aspect.after` - // to access these events outside of the Animation definition: - // | var anim = basefx.animateProperty({ - // | node:"someId", - // | properties:{ - // | width:400, height:500 - // | } - // | }); - // | aspect.after(anim, "onEnd", function(){ - // | console.log("animation ended"); - // | }, true); - // | // play the animation now: - // | anim.play(); - // - // example: - // Each property can be a function whose return value is substituted along. - // Additionally, each measurement (eg: start, end) can be a function. The node - // reference is passed directly to callbacks. - // | basefx.animateProperty({ - // | node:"mine", - // | properties:{ - // | height:function(node){ - // | // shrink this node by 50% - // | return domGeom.position(node).h / 2 - // | }, - // | width:{ - // | start:function(node){ return 100; }, - // | end:function(node){ return 200; } - // | } - // | } - // | }).play(); - // - - var n = args.node = dom.byId(args.node); - if(!args.easing){ args.easing = dojo._defaultEasing; } - - var anim = new Animation(args); - aspect.after(anim, "beforeBegin", lang.hitch(anim, function(){ - var pm = {}; - for(var p in this.properties){ - // Make shallow copy of properties into pm because we overwrite - // some values below. In particular if start/end are functions - // we don't want to overwrite them or the functions won't be - // called if the animation is reused. - if(p == "width" || p == "height"){ - this.node.display = "block"; - } - var prop = this.properties[p]; - if(lang.isFunction(prop)){ - prop = prop(n); - } - prop = pm[p] = _mixin({}, (lang.isObject(prop) ? prop: { end: prop })); - - if(lang.isFunction(prop.start)){ - prop.start = prop.start(n); - } - if(lang.isFunction(prop.end)){ - prop.end = prop.end(n); - } - var isColor = (p.toLowerCase().indexOf("color") >= 0); - function getStyle(node, p){ - // domStyle.get(node, "height") can return "auto" or "" on IE; this is more reliable: - var v = { height: node.offsetHeight, width: node.offsetWidth }[p]; - if(v !== undefined){ return v; } - v = style.get(node, p); - return (p == "opacity") ? +v : (isColor ? v : parseFloat(v)); - } - if(!("end" in prop)){ - prop.end = getStyle(n, p); - }else if(!("start" in prop)){ - prop.start = getStyle(n, p); - } - - if(isColor){ - prop.start = new Color(prop.start); - prop.end = new Color(prop.end); - }else{ - prop.start = (p == "opacity") ? +prop.start : parseFloat(prop.start); - } - } - this.curve = new PropLine(pm); - }), true); - aspect.after(anim, "onAnimate", lang.hitch(style, "set", anim.node), true); - return anim; // Animation - }; - - basefx.anim = function( /*DOMNode|String*/ node, - /*Object*/ properties, - /*Integer?*/ duration, - /*Function?*/ easing, - /*Function?*/ onEnd, - /*Integer?*/ delay){ - // summary: - // A simpler interface to `animateProperty()`, also returns - // an instance of `Animation` but begins the animation - // immediately, unlike nearly every other Dojo animation API. - // description: - // Simpler (but somewhat less powerful) version - // of `animateProperty`. It uses defaults for many basic properties - // and allows for positional parameters to be used in place of the - // packed "property bag" which is used for other Dojo animation - // methods. - // - // The `Animation` object returned will be already playing, so - // calling play() on it again is (usually) a no-op. - // node: - // a DOM node or the id of a node to animate CSS properties on - // duration: - // The number of milliseconds over which the animation - // should run. Defaults to the global animation default duration - // (350ms). - // easing: - // An easing function over which to calculate acceleration - // and deceleration of the animation through its duration. - // A default easing algorithm is provided, but you may - // plug in any you wish. A large selection of easing algorithms - // are available in `dojo/fx/easing`. - // onEnd: - // A function to be called when the animation finishes - // running. - // delay: - // The number of milliseconds to delay beginning the - // animation by. The default is 0. - // example: - // Fade out a node - // | basefx.anim("id", { opacity: 0 }); - // example: - // Fade out a node over a full second - // | basefx.anim("id", { opacity: 0 }, 1000); - return basefx.animateProperty({ // Animation - node: node, - duration: duration || Animation.prototype.duration, - properties: properties, - easing: easing, - onEnd: onEnd - }).play(delay || 0); - }; - - - if( 1 ){ - _mixin(dojo, basefx); - // Alias to drop come 2.0: - dojo._Animation = Animation; - } - - return basefx; -}); diff --git a/lib/dojo/_base/html.js b/lib/dojo/_base/html.js deleted file mode 100644 index ec884b6..0000000 --- a/lib/dojo/_base/html.js +++ /dev/null @@ -1,88 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/_base/html",["./kernel","../dom","../dom-style","../dom-attr","../dom-prop","../dom-class","../dom-construct","../dom-geometry"],function(_1,_2,_3,_4,_5,_6,_7,_8){ -_1.byId=_2.byId; -_1.isDescendant=_2.isDescendant; -_1.setSelectable=_2.setSelectable; -_1.getAttr=_4.get; -_1.setAttr=_4.set; -_1.hasAttr=_4.has; -_1.removeAttr=_4.remove; -_1.getNodeProp=_4.getNodeProp; -_1.attr=function(_9,_a,_b){ -if(arguments.length==2){ -return _4[typeof _a=="string"?"get":"set"](_9,_a); -} -return _4.set(_9,_a,_b); -}; -_1.hasClass=_6.contains; -_1.addClass=_6.add; -_1.removeClass=_6.remove; -_1.toggleClass=_6.toggle; -_1.replaceClass=_6.replace; -_1._toDom=_1.toDom=_7.toDom; -_1.place=_7.place; -_1.create=_7.create; -_1.empty=function(_c){ -_7.empty(_c); -}; -_1._destroyElement=_1.destroy=function(_d){ -_7.destroy(_d); -}; -_1._getPadExtents=_1.getPadExtents=_8.getPadExtents; -_1._getBorderExtents=_1.getBorderExtents=_8.getBorderExtents; -_1._getPadBorderExtents=_1.getPadBorderExtents=_8.getPadBorderExtents; -_1._getMarginExtents=_1.getMarginExtents=_8.getMarginExtents; -_1._getMarginSize=_1.getMarginSize=_8.getMarginSize; -_1._getMarginBox=_1.getMarginBox=_8.getMarginBox; -_1.setMarginBox=_8.setMarginBox; -_1._getContentBox=_1.getContentBox=_8.getContentBox; -_1.setContentSize=_8.setContentSize; -_1._isBodyLtr=_1.isBodyLtr=_8.isBodyLtr; -_1._docScroll=_1.docScroll=_8.docScroll; -_1._getIeDocumentElementOffset=_1.getIeDocumentElementOffset=_8.getIeDocumentElementOffset; -_1._fixIeBiDiScrollLeft=_1.fixIeBiDiScrollLeft=_8.fixIeBiDiScrollLeft; -_1.position=_8.position; -_1.marginBox=function marginBox(_e,_f){ -return _f?_8.setMarginBox(_e,_f):_8.getMarginBox(_e); -}; -_1.contentBox=function contentBox(_10,box){ -return box?_8.setContentSize(_10,box):_8.getContentBox(_10); -}; -_1.coords=function(_11,_12){ -_1.deprecated("dojo.coords()","Use dojo.position() or dojo.marginBox()."); -_11=_2.byId(_11); -var s=_3.getComputedStyle(_11),mb=_8.getMarginBox(_11,s); -var abs=_8.position(_11,_12); -mb.x=abs.x; -mb.y=abs.y; -return mb; -}; -_1.getProp=_5.get; -_1.setProp=_5.set; -_1.prop=function(_13,_14,_15){ -if(arguments.length==2){ -return _5[typeof _14=="string"?"get":"set"](_13,_14); -} -return _5.set(_13,_14,_15); -}; -_1.getStyle=_3.get; -_1.setStyle=_3.set; -_1.getComputedStyle=_3.getComputedStyle; -_1.__toPixelValue=_1.toPixelValue=_3.toPixelValue; -_1.style=function(_16,_17,_18){ -switch(arguments.length){ -case 1: -return _3.get(_16); -case 2: -return _3[typeof _17=="string"?"get":"set"](_16,_17); -} -return _3.set(_16,_17,_18); -}; -return _1; -}); diff --git a/lib/dojo/_base/html.js.uncompressed.js b/lib/dojo/_base/html.js.uncompressed.js deleted file mode 100644 index f439d0d..0000000 --- a/lib/dojo/_base/html.js.uncompressed.js +++ /dev/null @@ -1,392 +0,0 @@ -define("dojo/_base/html", ["./kernel", "../dom", "../dom-style", "../dom-attr", "../dom-prop", "../dom-class", "../dom-construct", "../dom-geometry"], function(dojo, dom, style, attr, prop, cls, ctr, geom){ - // module: - // dojo/dom - - /*===== - return { - // summary: - // This module is a stub for the core dojo DOM API. - }; - =====*/ - - // mix-in dom - dojo.byId = dom.byId; - dojo.isDescendant = dom.isDescendant; - dojo.setSelectable = dom.setSelectable; - - // mix-in dom-attr - dojo.getAttr = attr.get; - dojo.setAttr = attr.set; - dojo.hasAttr = attr.has; - dojo.removeAttr = attr.remove; - dojo.getNodeProp = attr.getNodeProp; - - dojo.attr = function(node, name, value){ - // summary: - // Gets or sets an attribute on an HTML element. - // description: - // Handles normalized getting and setting of attributes on DOM - // Nodes. If 2 arguments are passed, and a the second argument is a - // string, acts as a getter. - // - // If a third argument is passed, or if the second argument is a - // map of attributes, acts as a setter. - // - // When passing functions as values, note that they will not be - // directly assigned to slots on the node, but rather the default - // behavior will be removed and the new behavior will be added - // using `dojo.connect()`, meaning that event handler properties - // will be normalized and that some caveats with regards to - // non-standard behaviors for onsubmit apply. Namely that you - // should cancel form submission using `dojo.stopEvent()` on the - // passed event object instead of returning a boolean value from - // the handler itself. - // node: DOMNode|String - // id or reference to the element to get or set the attribute on - // name: String|Object - // the name of the attribute to get or set. - // value: String? - // The value to set for the attribute - // returns: - // when used as a getter, the value of the requested attribute - // or null if that attribute does not have a specified or - // default value; - // - // when used as a setter, the DOM node - // - // example: - // | // get the current value of the "foo" attribute on a node - // | dojo.attr(dojo.byId("nodeId"), "foo"); - // | // or we can just pass the id: - // | dojo.attr("nodeId", "foo"); - // - // example: - // | // use attr() to set the tab index - // | dojo.attr("nodeId", "tabIndex", 3); - // | - // - // example: - // Set multiple values at once, including event handlers: - // | dojo.attr("formId", { - // | "foo": "bar", - // | "tabIndex": -1, - // | "method": "POST", - // | "onsubmit": function(e){ - // | // stop submitting the form. Note that the IE behavior - // | // of returning true or false will have no effect here - // | // since our handler is connect()ed to the built-in - // | // onsubmit behavior and so we need to use - // | // dojo.stopEvent() to ensure that the submission - // | // doesn't proceed. - // | dojo.stopEvent(e); - // | - // | // submit the form with Ajax - // | dojo.xhrPost({ form: "formId" }); - // | } - // | }); - // - // example: - // Style is s special case: Only set with an object hash of styles - // | dojo.attr("someNode",{ - // | id:"bar", - // | style:{ - // | width:"200px", height:"100px", color:"#000" - // | } - // | }); - // - // example: - // Again, only set style as an object hash of styles: - // | var obj = { color:"#fff", backgroundColor:"#000" }; - // | dojo.attr("someNode", "style", obj); - // | - // | // though shorter to use `dojo.style()` in this case: - // | dojo.style("someNode", obj); - - if(arguments.length == 2){ - return attr[typeof name == "string" ? "get" : "set"](node, name); - } - return attr.set(node, name, value); - }; - - // mix-in dom-class - dojo.hasClass = cls.contains; - dojo.addClass = cls.add; - dojo.removeClass = cls.remove; - dojo.toggleClass = cls.toggle; - dojo.replaceClass = cls.replace; - - // mix-in dom-construct - dojo._toDom = dojo.toDom = ctr.toDom; - dojo.place = ctr.place; - dojo.create = ctr.create; - dojo.empty = function(node){ ctr.empty(node); }; - dojo._destroyElement = dojo.destroy = function(node){ ctr.destroy(node); }; - - // mix-in dom-geometry - dojo._getPadExtents = dojo.getPadExtents = geom.getPadExtents; - dojo._getBorderExtents = dojo.getBorderExtents = geom.getBorderExtents; - dojo._getPadBorderExtents = dojo.getPadBorderExtents = geom.getPadBorderExtents; - dojo._getMarginExtents = dojo.getMarginExtents = geom.getMarginExtents; - dojo._getMarginSize = dojo.getMarginSize = geom.getMarginSize; - dojo._getMarginBox = dojo.getMarginBox = geom.getMarginBox; - dojo.setMarginBox = geom.setMarginBox; - dojo._getContentBox = dojo.getContentBox = geom.getContentBox; - dojo.setContentSize = geom.setContentSize; - dojo._isBodyLtr = dojo.isBodyLtr = geom.isBodyLtr; - dojo._docScroll = dojo.docScroll = geom.docScroll; - dojo._getIeDocumentElementOffset = dojo.getIeDocumentElementOffset = geom.getIeDocumentElementOffset; - dojo._fixIeBiDiScrollLeft = dojo.fixIeBiDiScrollLeft = geom.fixIeBiDiScrollLeft; - dojo.position = geom.position; - - dojo.marginBox = function marginBox(/*DomNode|String*/node, /*Object?*/box){ - // summary: - // Getter/setter for the margin-box of node. - // description: - // Getter/setter for the margin-box of node. - // Returns an object in the expected format of box (regardless - // if box is passed). The object might look like: - // `{ l: 50, t: 200, w: 300: h: 150 }` - // for a node offset from its parent 50px to the left, 200px from - // the top with a margin width of 300px and a margin-height of - // 150px. - // node: - // id or reference to DOM Node to get/set box for - // box: - // If passed, denotes that dojo.marginBox() should - // update/set the margin box for node. Box is an object in the - // above format. All properties are optional if passed. - // example: - // Retrieve the margin box of a passed node - // | var box = dojo.marginBox("someNodeId"); - // | console.dir(box); - // - // example: - // Set a node's margin box to the size of another node - // | var box = dojo.marginBox("someNodeId"); - // | dojo.marginBox("someOtherNode", box); - return box ? geom.setMarginBox(node, box) : geom.getMarginBox(node); // Object - }; - - dojo.contentBox = function contentBox(/*DomNode|String*/node, /*Object?*/box){ - // summary: - // Getter/setter for the content-box of node. - // description: - // Returns an object in the expected format of box (regardless if box is passed). - // The object might look like: - // `{ l: 50, t: 200, w: 300: h: 150 }` - // for a node offset from its parent 50px to the left, 200px from - // the top with a content width of 300px and a content-height of - // 150px. Note that the content box may have a much larger border - // or margin box, depending on the box model currently in use and - // CSS values set/inherited for node. - // While the getter will return top and left values, the - // setter only accepts setting the width and height. - // node: - // id or reference to DOM Node to get/set box for - // box: - // If passed, denotes that dojo.contentBox() should - // update/set the content box for node. Box is an object in the - // above format, but only w (width) and h (height) are supported. - // All properties are optional if passed. - return box ? geom.setContentSize(node, box) : geom.getContentBox(node); // Object - }; - - dojo.coords = function(/*DomNode|String*/node, /*Boolean?*/includeScroll){ - // summary: - // Deprecated: Use position() for border-box x/y/w/h - // or marginBox() for margin-box w/h/l/t. - // - // Returns an object that measures margin-box (w)idth/(h)eight - // and absolute position x/y of the border-box. Also returned - // is computed (l)eft and (t)op values in pixels from the - // node's offsetParent as returned from marginBox(). - // Return value will be in the form: - //| { l: 50, t: 200, w: 300: h: 150, x: 100, y: 300 } - // Does not act as a setter. If includeScroll is passed, the x and - // y params are affected as one would expect in dojo.position(). - dojo.deprecated("dojo.coords()", "Use dojo.position() or dojo.marginBox()."); - node = dom.byId(node); - var s = style.getComputedStyle(node), mb = geom.getMarginBox(node, s); - var abs = geom.position(node, includeScroll); - mb.x = abs.x; - mb.y = abs.y; - return mb; // Object - }; - - // mix-in dom-prop - dojo.getProp = prop.get; - dojo.setProp = prop.set; - - dojo.prop = function(/*DomNode|String*/node, /*String|Object*/name, /*String?*/value){ - // summary: - // Gets or sets a property on an HTML element. - // description: - // Handles normalized getting and setting of properties on DOM - // Nodes. If 2 arguments are passed, and a the second argument is a - // string, acts as a getter. - // - // If a third argument is passed, or if the second argument is a - // map of attributes, acts as a setter. - // - // When passing functions as values, note that they will not be - // directly assigned to slots on the node, but rather the default - // behavior will be removed and the new behavior will be added - // using `dojo.connect()`, meaning that event handler properties - // will be normalized and that some caveats with regards to - // non-standard behaviors for onsubmit apply. Namely that you - // should cancel form submission using `dojo.stopEvent()` on the - // passed event object instead of returning a boolean value from - // the handler itself. - // node: - // id or reference to the element to get or set the property on - // name: - // the name of the property to get or set. - // value: - // The value to set for the property - // returns: - // when used as a getter, the value of the requested property - // or null if that attribute does not have a specified or - // default value; - // - // when used as a setter, the DOM node - // - // example: - // | // get the current value of the "foo" property on a node - // | dojo.prop(dojo.byId("nodeId"), "foo"); - // | // or we can just pass the id: - // | dojo.prop("nodeId", "foo"); - // - // example: - // | // use prop() to set the tab index - // | dojo.prop("nodeId", "tabIndex", 3); - // | - // - // example: - // Set multiple values at once, including event handlers: - // | dojo.prop("formId", { - // | "foo": "bar", - // | "tabIndex": -1, - // | "method": "POST", - // | "onsubmit": function(e){ - // | // stop submitting the form. Note that the IE behavior - // | // of returning true or false will have no effect here - // | // since our handler is connect()ed to the built-in - // | // onsubmit behavior and so we need to use - // | // dojo.stopEvent() to ensure that the submission - // | // doesn't proceed. - // | dojo.stopEvent(e); - // | - // | // submit the form with Ajax - // | dojo.xhrPost({ form: "formId" }); - // | } - // | }); - // - // example: - // Style is s special case: Only set with an object hash of styles - // | dojo.prop("someNode",{ - // | id:"bar", - // | style:{ - // | width:"200px", height:"100px", color:"#000" - // | } - // | }); - // - // example: - // Again, only set style as an object hash of styles: - // | var obj = { color:"#fff", backgroundColor:"#000" }; - // | dojo.prop("someNode", "style", obj); - // | - // | // though shorter to use `dojo.style()` in this case: - // | dojo.style("someNode", obj); - - if(arguments.length == 2){ - return prop[typeof name == "string" ? "get" : "set"](node, name); - } - // setter - return prop.set(node, name, value); - }; - - // mix-in dom-style - dojo.getStyle = style.get; - dojo.setStyle = style.set; - dojo.getComputedStyle = style.getComputedStyle; - dojo.__toPixelValue = dojo.toPixelValue = style.toPixelValue; - - dojo.style = function(node, name, value){ - // summary: - // Accesses styles on a node. If 2 arguments are - // passed, acts as a getter. If 3 arguments are passed, acts - // as a setter. - // description: - // Getting the style value uses the computed style for the node, so the value - // will be a calculated value, not just the immediate node.style value. - // Also when getting values, use specific style names, - // like "borderBottomWidth" instead of "border" since compound values like - // "border" are not necessarily reflected as expected. - // If you want to get node dimensions, use `dojo.marginBox()`, - // `dojo.contentBox()` or `dojo.position()`. - // node: DOMNode|String - // id or reference to node to get/set style for - // name: String|Object? - // the style property to set in DOM-accessor format - // ("borderWidth", not "border-width") or an object with key/value - // pairs suitable for setting each property. - // value: String? - // If passed, sets value on the node for style, handling - // cross-browser concerns. When setting a pixel value, - // be sure to include "px" in the value. For instance, top: "200px". - // Otherwise, in some cases, some browsers will not apply the style. - // returns: - // when used as a getter, return the computed style of the node if passing in an ID or node, - // or return the normalized, computed value for the property when passing in a node and a style property - // example: - // Passing only an ID or node returns the computed style object of - // the node: - // | dojo.style("thinger"); - // example: - // Passing a node and a style property returns the current - // normalized, computed value for that property: - // | dojo.style("thinger", "opacity"); // 1 by default - // - // example: - // Passing a node, a style property, and a value changes the - // current display of the node and returns the new computed value - // | dojo.style("thinger", "opacity", 0.5); // == 0.5 - // - // example: - // Passing a node, an object-style style property sets each of the values in turn and returns the computed style object of the node: - // | dojo.style("thinger", { - // | "opacity": 0.5, - // | "border": "3px solid black", - // | "height": "300px" - // | }); - // - // example: - // When the CSS style property is hyphenated, the JavaScript property is camelCased. - // font-size becomes fontSize, and so on. - // | dojo.style("thinger",{ - // | fontSize:"14pt", - // | letterSpacing:"1.2em" - // | }); - // - // example: - // dojo/NodeList implements .style() using the same syntax, omitting the "node" parameter, calling - // dojo.style() on every element of the list. See: `dojo/query` and `dojo/NodeList` - // | dojo.query(".someClassName").style("visibility","hidden"); - // | // or - // | dojo.query("#baz > div").style({ - // | opacity:0.75, - // | fontSize:"13pt" - // | }); - - switch(arguments.length){ - case 1: - return style.get(node); - case 2: - return style[typeof name == "string" ? "get" : "set"](node, name); - } - // setter - return style.set(node, name, value); - }; - - return dojo; -}); diff --git a/lib/dojo/_base/json.js b/lib/dojo/_base/json.js deleted file mode 100644 index b4d4b71..0000000 --- a/lib/dojo/_base/json.js +++ /dev/null @@ -1,26 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/_base/json",["./kernel","../json"],function(_1,_2){ -_1.fromJson=function(js){ -return eval("("+js+")"); -}; -_1._escapeString=_2.stringify; -_1.toJsonIndentStr="\t"; -_1.toJson=function(it,_3){ -return _2.stringify(it,function(_4,_5){ -if(_5){ -var tf=_5.__json__||_5.json; -if(typeof tf=="function"){ -return tf.call(_5); -} -} -return _5; -},_3&&_1.toJsonIndentStr); -}; -return _1; -}); diff --git a/lib/dojo/_base/json.js.uncompressed.js b/lib/dojo/_base/json.js.uncompressed.js deleted file mode 100644 index 525c048..0000000 --- a/lib/dojo/_base/json.js.uncompressed.js +++ /dev/null @@ -1,91 +0,0 @@ -define("dojo/_base/json", ["./kernel", "../json"], function(dojo, json){ - -// module: -// dojo/_base/json - -/*===== -return { - // summary: - // This module defines the dojo JSON API. -}; -=====*/ - -dojo.fromJson = function(/*String*/ js){ - // summary: - // Parses a JavaScript expression and returns a JavaScript value. - // description: - // Throws for invalid JavaScript expressions. It does not use a strict JSON parser. It - // always delegates to eval(). The content passed to this method must therefore come - // from a trusted source. - // It is recommend that you use dojo/json's parse function for an - // implementation uses the (faster) native JSON parse when available. - // js: - // a string literal of a JavaScript expression, for instance: - // `'{ "foo": [ "bar", 1, { "baz": "thud" } ] }'` - - return eval("(" + js + ")"); // Object -}; - -/*===== -dojo._escapeString = function(){ - // summary: - // Adds escape sequences for non-visual characters, double quote and - // backslash and surrounds with double quotes to form a valid string - // literal. -}; -=====*/ -dojo._escapeString = json.stringify; // just delegate to json.stringify - -dojo.toJsonIndentStr = "\t"; -dojo.toJson = function(/*Object*/ it, /*Boolean?*/ prettyPrint){ - // summary: - // Returns a [JSON](http://json.org) serialization of an object. - // description: - // Returns a [JSON](http://json.org) serialization of an object. - // Note that this doesn't check for infinite recursion, so don't do that! - // It is recommend that you use dojo/json's stringify function for an lighter - // and faster implementation that matches the native JSON API and uses the - // native JSON serializer when available. - // it: - // an object to be serialized. Objects may define their own - // serialization via a special "__json__" or "json" function - // property. If a specialized serializer has been defined, it will - // be used as a fallback. - // Note that in 1.6, toJson would serialize undefined, but this no longer supported - // since it is not supported by native JSON serializer. - // prettyPrint: - // if true, we indent objects and arrays to make the output prettier. - // The variable `dojo.toJsonIndentStr` is used as the indent string -- - // to use something other than the default (tab), change that variable - // before calling dojo.toJson(). - // Note that if native JSON support is available, it will be used for serialization, - // and native implementations vary on the exact spacing used in pretty printing. - // returns: - // A JSON string serialization of the passed-in object. - // example: - // simple serialization of a trivial object - // | var jsonStr = dojo.toJson({ howdy: "stranger!", isStrange: true }); - // | doh.is('{"howdy":"stranger!","isStrange":true}', jsonStr); - // example: - // a custom serializer for an objects of a particular class: - // | dojo.declare("Furby", null, { - // | furbies: "are strange", - // | furbyCount: 10, - // | __json__: function(){ - // | }, - // | }); - - // use dojo/json - return json.stringify(it, function(key, value){ - if(value){ - var tf = value.__json__||value.json; - if(typeof tf == "function"){ - return tf.call(value); - } - } - return value; - }, prettyPrint && dojo.toJsonIndentStr); // String -}; - -return dojo; -}); diff --git a/lib/dojo/_base/kernel.js b/lib/dojo/_base/kernel.js deleted file mode 100644 index 94fc9e7..0000000 --- a/lib/dojo/_base/kernel.js +++ /dev/null @@ -1,111 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/_base/kernel",["../has","./config","require","module"],function(_1,_2,_3,_4){ -var i,p,_5={},_6={},_7={config:_2,global:this,dijit:_5,dojox:_6}; -var _8={dojo:["dojo",_7],dijit:["dijit",_5],dojox:["dojox",_6]},_9=(_3.map&&_3.map[_4.id.match(/[^\/]+/)[0]]),_a; -for(p in _9){ -if(_8[p]){ -_8[p][0]=_9[p]; -}else{ -_8[p]=[_9[p],{}]; -} -} -for(p in _8){ -_a=_8[p]; -_a[1]._scopeName=_a[0]; -if(!_2.noGlobals){ -this[_a[0]]=_a[1]; -} -} -_7.scopeMap=_8; -_7.baseUrl=_7.config.baseUrl=_3.baseUrl; -_7.isAsync=!1||_3.async; -_7.locale=_2.locale; -var _b="$Rev: e124479 $".match(/[0-9a-f]{7,}/); -_7.version={major:1,minor:10,patch:0,flag:"",revision:_b?_b[0]:NaN,toString:function(){ -var v=_7.version; -return v.major+"."+v.minor+"."+v.patch+v.flag+" ("+v.revision+")"; -}}; -1||_1.add("extend-dojo",1); -(Function("d","d.eval = function(){return d.global.eval ? d.global.eval(arguments[0]) : eval(arguments[0]);}"))(_7); -if(0){ -_7.exit=function(_c){ -quit(_c); -}; -}else{ -_7.exit=function(){ -}; -} -1||_1.add("dojo-guarantee-console",1); -if(1){ -typeof console!="undefined"||(console={}); -var cn=["assert","count","debug","dir","dirxml","error","group","groupEnd","info","profile","profileEnd","time","timeEnd","trace","warn","log"]; -var tn; -i=0; -while((tn=cn[i++])){ -if(!console[tn]){ -(function(){ -var _d=tn+""; -console[_d]=("log" in console)?function(){ -var a=Array.prototype.slice.call(arguments); -a.unshift(_d+":"); -console["log"](a.join(" ")); -}:function(){ -}; -console[_d]._fake=true; -})(); -} -} -} -_1.add("dojo-debug-messages",!!_2.isDebug); -_7.deprecated=_7.experimental=function(){ -}; -if(_1("dojo-debug-messages")){ -_7.deprecated=function(_e,_f,_10){ -var _11="DEPRECATED: "+_e; -if(_f){ -_11+=" "+_f; -} -if(_10){ -_11+=" -- will be removed in version: "+_10; -} -console.warn(_11); -}; -_7.experimental=function(_12,_13){ -var _14="EXPERIMENTAL: "+_12+" -- APIs subject to change without notice."; -if(_13){ -_14+=" "+_13; -} -console.warn(_14); -}; -} -1||_1.add("dojo-modulePaths",1); -if(1){ -if(_2.modulePaths){ -_7.deprecated("dojo.modulePaths","use paths configuration"); -var _15={}; -for(p in _2.modulePaths){ -_15[p.replace(/\./g,"/")]=_2.modulePaths[p]; -} -_3({paths:_15}); -} -} -1||_1.add("dojo-moduleUrl",1); -if(1){ -_7.moduleUrl=function(_16,url){ -_7.deprecated("dojo.moduleUrl()","use require.toUrl","2.0"); -var _17=null; -if(_16){ -_17=_3.toUrl(_16.replace(/\./g,"/")+(url?("/"+url):"")+"/*.*").replace(/\/\*\.\*/,"")+(url?"":"/"); -} -return _17; -}; -} -_7._hasResource={}; -return _7; -}); diff --git a/lib/dojo/_base/kernel.js.uncompressed.js b/lib/dojo/_base/kernel.js.uncompressed.js deleted file mode 100644 index 42a8c1b..0000000 --- a/lib/dojo/_base/kernel.js.uncompressed.js +++ /dev/null @@ -1,299 +0,0 @@ -define("dojo/_base/kernel", ["../has", "./config", "require", "module"], function(has, config, require, module){ - // module: - // dojo/_base/kernel - - // This module is the foundational module of the dojo boot sequence; it defines the dojo object. - - var - // loop variables for this module - i, p, - - // create dojo, dijit, and dojox - // FIXME: in 2.0 remove dijit, dojox being created by dojo - dijit = {}, - dojox = {}, - dojo = { - // summary: - // This module is the foundational module of the dojo boot sequence; it defines the dojo object. - - // notice dojo takes ownership of the value of the config module - config:config, - global:this, - dijit:dijit, - dojox:dojox - }; - - - // Configure the scope map. For a 100% AMD application, the scope map is not needed other than to provide - // a _scopeName property for the dojo, dijit, and dojox root object so those packages can create - // unique names in the global space. - // - // Built, legacy modules use the scope map to allow those modules to be expressed as if dojo, dijit, and dojox, - // where global when in fact they are either global under different names or not global at all. In v1.6-, the - // config variable "scopeMap" was used to map names as used within a module to global names. This has been - // subsumed by the AMD map configuration variable which can relocate packages to different names. For backcompat, - // only the "*" mapping is supported. See http://livedocs.dojotoolkit.org/developer/design/loader#legacy-cross-domain-mode for details. - // - // The following computations contort the packageMap for this dojo instance into a scopeMap. - var scopeMap = - // a map from a name used in a legacy module to the (global variable name, object addressed by that name) - // always map dojo, dijit, and dojox - { - dojo:["dojo", dojo], - dijit:["dijit", dijit], - dojox:["dojox", dojox] - }, - - packageMap = - // the package map for this dojo instance; note, a foreign loader or no pacakgeMap results in the above default config - (require.map && require.map[module.id.match(/[^\/]+/)[0]]), - - item; - - - // process all mapped top-level names for this instance of dojo - for(p in packageMap){ - if(scopeMap[p]){ - // mapped dojo, dijit, or dojox - scopeMap[p][0] = packageMap[p]; - }else{ - // some other top-level name - scopeMap[p] = [packageMap[p], {}]; - } - } - - // publish those names to _scopeName and, optionally, the global namespace - for(p in scopeMap){ - item = scopeMap[p]; - item[1]._scopeName = item[0]; - if(!config.noGlobals){ - this[item[0]] = item[1]; - } - } - dojo.scopeMap = scopeMap; - - /*===== dojo.__docParserConfigureScopeMap(scopeMap); =====*/ - - // FIXME: dojo.baseUrl and dojo.config.baseUrl should be deprecated - dojo.baseUrl = dojo.config.baseUrl = require.baseUrl; - dojo.isAsync = ! 1 || require.async; - dojo.locale = config.locale; - - var rev = "$Rev: e124479 $".match(/[0-9a-f]{7,}/); - dojo.version = { - // summary: - // Version number of the Dojo Toolkit - // description: - // Hash about the version, including - // - // - major: Integer: Major version. If total version is "1.2.0beta1", will be 1 - // - minor: Integer: Minor version. If total version is "1.2.0beta1", will be 2 - // - patch: Integer: Patch version. If total version is "1.2.0beta1", will be 0 - // - flag: String: Descriptor flag. If total version is "1.2.0beta1", will be "beta1" - // - revision: Number: The Git rev from which dojo was pulled - - major: 1, minor: 10, patch: 0, flag: "", - revision: rev ? rev[0] : NaN, - toString: function(){ - var v = dojo.version; - return v.major + "." + v.minor + "." + v.patch + v.flag + " (" + v.revision + ")"; // String - } - }; - - // If 1 is truthy, then as a dojo module is defined it should push it's definitions - // into the dojo object, and conversely. In 2.0, it will likely be unusual to augment another object - // as a result of defining a module. This has feature gives a way to force 2.0 behavior as the code - // is migrated. Absent specific advice otherwise, set extend-dojo to truthy. - 1 || has.add("extend-dojo", 1); - - - (Function("d", "d.eval = function(){return d.global.eval ? d.global.eval(arguments[0]) : eval(arguments[0]);}"))(dojo); - /*===== - dojo.eval = function(scriptText){ - // summary: - // A legacy method created for use exclusively by internal Dojo methods. Do not use this method - // directly unless you understand its possibly-different implications on the platforms your are targeting. - // description: - // Makes an attempt to evaluate scriptText in the global scope. The function works correctly for browsers - // that support indirect eval. - // - // As usual, IE does not. On IE, the only way to implement global eval is to - // use execScript. Unfortunately, execScript does not return a value and breaks some current usages of dojo.eval. - // This implementation uses the technique of executing eval in the scope of a function that is a single scope - // frame below the global scope; thereby coming close to the global scope. Note carefully that - // - // dojo.eval("var pi = 3.14;"); - // - // will define global pi in non-IE environments, but define pi only in a temporary local scope for IE. If you want - // to define a global variable using dojo.eval, write something like - // - // dojo.eval("window.pi = 3.14;") - // scriptText: - // The text to evaluation. - // returns: - // The result of the evaluation. Often `undefined` - }; - =====*/ - - - if( 0 ){ - dojo.exit = function(exitcode){ - quit(exitcode); - }; - }else{ - dojo.exit = function(){ - }; - } - - 1 || has.add("dojo-guarantee-console", - // ensure that console.log, console.warn, etc. are defined - 1 - ); - if( 1 ){ - typeof console != "undefined" || (console = {}); - // Be careful to leave 'log' always at the end - var cn = [ - "assert", "count", "debug", "dir", "dirxml", "error", "group", - "groupEnd", "info", "profile", "profileEnd", "time", "timeEnd", - "trace", "warn", "log" - ]; - var tn; - i = 0; - while((tn = cn[i++])){ - if(!console[tn]){ - (function(){ - var tcn = tn + ""; - console[tcn] = ('log' in console) ? function(){ - var a = Array.prototype.slice.call(arguments); - a.unshift(tcn + ":"); - console["log"](a.join(" ")); - } : function(){}; - console[tcn]._fake = true; - })(); - } - } - } - - has.add("dojo-debug-messages", - // include dojo.deprecated/dojo.experimental implementations - !!config.isDebug - ); - dojo.deprecated = dojo.experimental = function(){}; - if(has("dojo-debug-messages")){ - dojo.deprecated = function(/*String*/ behaviour, /*String?*/ extra, /*String?*/ removal){ - // summary: - // Log a debug message to indicate that a behavior has been - // deprecated. - // behaviour: String - // The API or behavior being deprecated. Usually in the form - // of "myApp.someFunction()". - // extra: String? - // Text to append to the message. Often provides advice on a - // new function or facility to achieve the same goal during - // the deprecation period. - // removal: String? - // Text to indicate when in the future the behavior will be - // removed. Usually a version number. - // example: - // | dojo.deprecated("myApp.getTemp()", "use myApp.getLocaleTemp() instead", "1.0"); - - var message = "DEPRECATED: " + behaviour; - if(extra){ message += " " + extra; } - if(removal){ message += " -- will be removed in version: " + removal; } - console.warn(message); - }; - - dojo.experimental = function(/* String */ moduleName, /* String? */ extra){ - // summary: - // Marks code as experimental. - // description: - // This can be used to mark a function, file, or module as - // experimental. Experimental code is not ready to be used, and the - // APIs are subject to change without notice. Experimental code may be - // completed deleted without going through the normal deprecation - // process. - // moduleName: String - // The name of a module, or the name of a module file or a specific - // function - // extra: String? - // some additional message for the user - // example: - // | dojo.experimental("dojo.data.Result"); - // example: - // | dojo.experimental("dojo.weather.toKelvin()", "PENDING approval from NOAA"); - - var message = "EXPERIMENTAL: " + moduleName + " -- APIs subject to change without notice."; - if(extra){ message += " " + extra; } - console.warn(message); - }; - } - - 1 || has.add("dojo-modulePaths", - // consume dojo.modulePaths processing - 1 - ); - if( 1 ){ - // notice that modulePaths won't be applied to any require's before the dojo/_base/kernel factory is run; - // this is the v1.6- behavior. - if(config.modulePaths){ - dojo.deprecated("dojo.modulePaths", "use paths configuration"); - var paths = {}; - for(p in config.modulePaths){ - paths[p.replace(/\./g, "/")] = config.modulePaths[p]; - } - require({paths:paths}); - } - } - - 1 || has.add("dojo-moduleUrl", - // include dojo.moduleUrl - 1 - ); - if( 1 ){ - dojo.moduleUrl = function(/*String*/module, /*String?*/url){ - // summary: - // Returns a URL relative to a module. - // example: - // | var pngPath = dojo.moduleUrl("acme","images/small.png"); - // | console.dir(pngPath); // list the object properties - // | // create an image and set it's source to pngPath's value: - // | var img = document.createElement("img"); - // | img.src = pngPath; - // | // add our image to the document - // | dojo.body().appendChild(img); - // example: - // you may de-reference as far as you like down the package - // hierarchy. This is sometimes handy to avoid lengthy relative - // urls or for building portable sub-packages. In this example, - // the `acme.widget` and `acme.util` directories may be located - // under different roots (see `dojo.registerModulePath`) but the - // the modules which reference them can be unaware of their - // relative locations on the filesystem: - // | // somewhere in a configuration block - // | dojo.registerModulePath("acme.widget", "../../acme/widget"); - // | dojo.registerModulePath("acme.util", "../../util"); - // | - // | // ... - // | - // | // code in a module using acme resources - // | var tmpltPath = dojo.moduleUrl("acme.widget","templates/template.html"); - // | var dataPath = dojo.moduleUrl("acme.util","resources/data.json"); - - dojo.deprecated("dojo.moduleUrl()", "use require.toUrl", "2.0"); - - // require.toUrl requires a filetype; therefore, just append the suffix "/*.*" to guarantee a filetype, then - // remove the suffix from the result. This way clients can request a url w/out a filetype. This should be - // rare, but it maintains backcompat for the v1.x line (note: dojo.moduleUrl will be removed in v2.0). - // Notice * is an illegal filename so it won't conflict with any real path map that may exist the paths config. - var result = null; - if(module){ - result = require.toUrl(module.replace(/\./g, "/") + (url ? ("/" + url) : "") + "/*.*").replace(/\/\*\.\*/, "") + (url ? "" : "/"); - } - return result; - }; - } - - dojo._hasResource = {}; // for backward compatibility with layers built with 1.6 tooling - - return dojo; -}); diff --git a/lib/dojo/_base/lang.js b/lib/dojo/_base/lang.js deleted file mode 100644 index a65b081..0000000 --- a/lib/dojo/_base/lang.js +++ /dev/null @@ -1,184 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/_base/lang",["./kernel","../has","../sniff"],function(_1,_2){ -_2.add("bug-for-in-skips-shadowed",function(){ -for(var i in {toString:1}){ -return 0; -} -return 1; -}); -var _3=_2("bug-for-in-skips-shadowed")?"hasOwnProperty.valueOf.isPrototypeOf.propertyIsEnumerable.toLocaleString.toString.constructor".split("."):[],_4=_3.length,_5=function(_6,_7,_8){ -if(!_8){ -if(_6[0]&&_1.scopeMap[_6[0]]){ -_8=_1.scopeMap[_6.shift()][1]; -}else{ -_8=_1.global; -} -} -try{ -for(var i=0;i<_6.length;i++){ -var p=_6[i]; -if(!(p in _8)){ -if(_7){ -_8[p]={}; -}else{ -return; -} -} -_8=_8[p]; -} -return _8; -} -catch(e){ -} -},_9=Object.prototype.toString,_a=function(_b,_c,_d){ -return (_d||[]).concat(Array.prototype.slice.call(_b,_c||0)); -},_e=/\{([^\}]+)\}/g; -var _f={_extraNames:_3,_mixin:function(_10,_11,_12){ -var _13,s,i,_14={}; -for(_13 in _11){ -s=_11[_13]; -if(!(_13 in _10)||(_10[_13]!==s&&(!(_13 in _14)||_14[_13]!==s))){ -_10[_13]=_12?_12(s):s; -} -} -if(_2("bug-for-in-skips-shadowed")){ -if(_11){ -for(i=0;i<_4;++i){ -_13=_3[i]; -s=_11[_13]; -if(!(_13 in _10)||(_10[_13]!==s&&(!(_13 in _14)||_14[_13]!==s))){ -_10[_13]=_12?_12(s):s; -} -} -} -} -return _10; -},mixin:function(_15,_16){ -if(!_15){ -_15={}; -} -for(var i=1,l=arguments.length;i2){ -return _f._hitchArgs.apply(_1,arguments); -} -if(!_26){ -_26=_25; -_25=null; -} -if(_f.isString(_26)){ -_25=_25||_1.global; -if(!_25[_26]){ -throw (["lang.hitch: scope[\"",_26,"\"] is null (scope=\"",_25,"\")"].join("")); -} -return function(){ -return _25[_26].apply(_25,arguments||[]); -}; -} -return !_25?_26:function(){ -return _26.apply(_25,arguments||[]); -}; -},delegate:(function(){ -function TMP(){ -}; -return function(obj,_27){ -TMP.prototype=obj; -var tmp=new TMP(); -TMP.prototype=null; -if(_27){ -_f._mixin(tmp,_27); -} -return tmp; -}; -})(),_toArray:_2("ie")?(function(){ -function _28(obj,_29,_2a){ -var arr=_2a||[]; -for(var x=_29||0;x 2){ - return lang._hitchArgs.apply(dojo, arguments); // Function - } - if(!method){ - method = scope; - scope = null; - } - if(lang.isString(method)){ - scope = scope || dojo.global; - if(!scope[method]){ throw(['lang.hitch: scope["', method, '"] is null (scope="', scope, '")'].join('')); } - return function(){ return scope[method].apply(scope, arguments || []); }; // Function - } - return !scope ? method : function(){ return method.apply(scope, arguments || []); }; // Function - }, - - delegate: (function(){ - // boodman/crockford delegation w/ cornford optimization - function TMP(){} - return function(obj, props){ - TMP.prototype = obj; - var tmp = new TMP(); - TMP.prototype = null; - if(props){ - lang._mixin(tmp, props); - } - return tmp; // Object - }; - })(), - /*===== - delegate: function(obj, props){ - // summary: - // Returns a new object which "looks" to obj for properties which it - // does not have a value for. Optionally takes a bag of properties to - // seed the returned object with initially. - // description: - // This is a small implementation of the Boodman/Crockford delegation - // pattern in JavaScript. An intermediate object constructor mediates - // the prototype chain for the returned object, using it to delegate - // down to obj for property lookup when object-local lookup fails. - // This can be thought of similarly to ES4's "wrap", save that it does - // not act on types but rather on pure objects. - // obj: Object - // The object to delegate to for properties not found directly on the - // return object or in props. - // props: Object... - // an object containing properties to assign to the returned object - // returns: - // an Object of anonymous type - // example: - // | var foo = { bar: "baz" }; - // | var thinger = lang.delegate(foo, { thud: "xyzzy"}); - // | thinger.bar == "baz"; // delegated to foo - // | foo.thud == undefined; // by definition - // | thinger.thud == "xyzzy"; // mixed in from props - // | foo.bar = "thonk"; - // | thinger.bar == "thonk"; // still delegated to foo's bar - }, - =====*/ - - _toArray: has("ie") ? - (function(){ - function slow(obj, offset, startWith){ - var arr = startWith||[]; - for(var x = offset || 0; x < obj.length; x++){ - arr.push(obj[x]); - } - return arr; - } - return function(obj){ - return ((obj.item) ? slow : efficient).apply(this, arguments); - }; - })() : efficient, - /*===== - _toArray: function(obj, offset, startWith){ - // summary: - // Converts an array-like object (i.e. arguments, DOMCollection) to an - // array. Returns a new Array with the elements of obj. - // obj: Object - // the object to "arrayify". We expect the object to have, at a - // minimum, a length property which corresponds to integer-indexed - // properties. - // offset: Number? - // the location in obj to start iterating from. Defaults to 0. - // Optional. - // startWith: Array? - // An array to pack with the properties of obj. If provided, - // properties in obj are appended at the end of startWith and - // startWith is the returned array. - }, - =====*/ - - partial: function(/*Function|String*/ method /*, ...*/){ - // summary: - // similar to hitch() except that the scope object is left to be - // whatever the execution context eventually becomes. - // description: - // Calling lang.partial is the functional equivalent of calling: - // | lang.hitch(null, funcName, ...); - // method: - // The function to "wrap" - var arr = [ null ]; - return lang.hitch.apply(dojo, arr.concat(lang._toArray(arguments))); // Function - }, - - clone: function(/*anything*/ src){ - // summary: - // Clones objects (including DOM nodes) and all children. - // Warning: do not clone cyclic structures. - // src: - // The object to clone - if(!src || typeof src != "object" || lang.isFunction(src)){ - // null, undefined, any non-object, or function - return src; // anything - } - if(src.nodeType && "cloneNode" in src){ - // DOM Node - return src.cloneNode(true); // Node - } - if(src instanceof Date){ - // Date - return new Date(src.getTime()); // Date - } - if(src instanceof RegExp){ - // RegExp - return new RegExp(src); // RegExp - } - var r, i, l; - if(lang.isArray(src)){ - // array - r = []; - for(i = 0, l = src.length; i < l; ++i){ - if(i in src){ - r.push(lang.clone(src[i])); - } - } - // we don't clone functions for performance reasons - // }else if(d.isFunction(src)){ - // // function - // r = function(){ return src.apply(this, arguments); }; - }else{ - // generic objects - r = src.constructor ? new src.constructor() : {}; - } - return lang._mixin(r, src, lang.clone); - }, - - - trim: String.prototype.trim ? - function(str){ return str.trim(); } : - function(str){ return str.replace(/^\s\s*/, '').replace(/\s\s*$/, ''); }, - /*===== - trim: function(str){ - // summary: - // Trims whitespace from both sides of the string - // str: String - // String to be trimmed - // returns: String - // Returns the trimmed string - // description: - // This version of trim() was selected for inclusion into the base due - // to its compact size and relatively good performance - // (see [Steven Levithan's blog](http://blog.stevenlevithan.com/archives/faster-trim-javascript) - // Uses String.prototype.trim instead, if available. - // The fastest but longest version of this function is located at - // lang.string.trim() - }, - =====*/ - - replace: function(tmpl, map, pattern){ - // summary: - // Performs parameterized substitutions on a string. Throws an - // exception if any parameter is unmatched. - // tmpl: String - // String to be used as a template. - // map: Object|Function - // If an object, it is used as a dictionary to look up substitutions. - // If a function, it is called for every substitution with following parameters: - // a whole match, a name, an offset, and the whole template - // string (see https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/String/replace - // for more details). - // pattern: RegEx? - // Optional regular expression objects that overrides the default pattern. - // Must be global and match one item. The default is: /\{([^\}]+)\}/g, - // which matches patterns like that: "{xxx}", where "xxx" is any sequence - // of characters, which doesn't include "}". - // returns: String - // Returns the substituted string. - // example: - // | // uses a dictionary for substitutions: - // | lang.replace("Hello, {name.first} {name.last} AKA {nick}!", - // | { - // | nick: "Bob", - // | name: { - // | first: "Robert", - // | middle: "X", - // | last: "Cringely" - // | } - // | }); - // | // returns: Hello, Robert Cringely AKA Bob! - // example: - // | // uses an array for substitutions: - // | lang.replace("Hello, {0} {2}!", - // | ["Robert", "X", "Cringely"]); - // | // returns: Hello, Robert Cringely! - // example: - // | // uses a function for substitutions: - // | function sum(a){ - // | var t = 0; - // | arrayforEach(a, function(x){ t += x; }); - // | return t; - // | } - // | lang.replace( - // | "{count} payments averaging {avg} USD per payment.", - // | lang.hitch( - // | { payments: [11, 16, 12] }, - // | function(_, key){ - // | switch(key){ - // | case "count": return this.payments.length; - // | case "min": return Math.min.apply(Math, this.payments); - // | case "max": return Math.max.apply(Math, this.payments); - // | case "sum": return sum(this.payments); - // | case "avg": return sum(this.payments) / this.payments.length; - // | } - // | } - // | ) - // | ); - // | // prints: 3 payments averaging 13 USD per payment. - // example: - // | // uses an alternative PHP-like pattern for substitutions: - // | lang.replace("Hello, ${0} ${2}!", - // | ["Robert", "X", "Cringely"], /\$\{([^\}]+)\}/g); - // | // returns: Hello, Robert Cringely! - - return tmpl.replace(pattern || _pattern, lang.isFunction(map) ? - map : function(_, k){ return lang.getObject(k, false, map); }); - } - }; - - 1 && lang.mixin(dojo, lang); - - return lang; -}); - diff --git a/lib/dojo/_base/loader.js b/lib/dojo/_base/loader.js deleted file mode 100644 index 41fcb5d..0000000 --- a/lib/dojo/_base/loader.js +++ /dev/null @@ -1,283 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/_base/loader",["./kernel","../has","require","module","../json","./lang","./array"],function(_1,_2,_3,_4,_5,_6,_7){ -if(!1){ -console.error("cannot load the Dojo v1.x loader with a foreign loader"); -return 0; -} -1||_2.add("dojo-fast-sync-require",1); -var _8=function(id){ -return {src:_4.id,id:id}; -},_9=function(_a){ -return _a.replace(/\./g,"/"); -},_b=/\/\/>>built/,_c=[],_d=[],_e=function(_f,_10,_11){ -_c.push(_11); -_7.forEach(_f.split(","),function(mid){ -var _12=_13(mid,_10.module); -_d.push(_12); -_14(_12); -}); -_15(); -},_15=(1?function(){ -var _16,mid; -for(mid in _17){ -_16=_17[mid]; -if(_16.noReqPluginCheck===undefined){ -_16.noReqPluginCheck=/loadInit\!/.test(mid)||/require\!/.test(mid)?1:0; -} -if(!_16.executed&&!_16.noReqPluginCheck&&_16.injected==_18){ -return; -} -} -_19(function(){ -var _1a=_c; -_c=[]; -_7.forEach(_1a,function(cb){ -cb(1); -}); -}); -}:(function(){ -var _1b,_1c=function(m){ -_1b[m.mid]=1; -for(var t,_1d,_1e=m.deps||[],i=0;i<_1e.length;i++){ -_1d=_1e[i]; -if(!(t=_1b[_1d.mid])){ -if(t===0||!_1c(_1d)){ -_1b[m.mid]=0; -return false; -} -} -} -return true; -}; -return function(){ -var _1f,mid; -_1b={}; -for(mid in _17){ -_1f=_17[mid]; -if(_1f.executed||_1f.noReqPluginCheck){ -_1b[mid]=1; -}else{ -if(_1f.noReqPluginCheck!==0){ -_1f.noReqPluginCheck=/loadInit\!/.test(mid)||/require\!/.test(mid)?1:0; -} -if(_1f.noReqPluginCheck){ -_1b[mid]=1; -}else{ -if(_1f.injected!==_51){ -_1b[mid]=0; -} -} -} -} -for(var t,i=0,end=_d.length;i>pure-amd - - if (! 1 ){ - console.error("cannot load the Dojo v1.x loader with a foreign loader"); - return 0; - } - - 1 || has.add("dojo-fast-sync-require", 1); - - - var makeErrorToken = function(id){ - return {src:thisModule.id, id:id}; - }, - - slashName = function(name){ - return name.replace(/\./g, "/"); - }, - - buildDetectRe = /\/\/>>built/, - - dojoRequireCallbacks = [], - dojoRequireModuleStack = [], - - dojoRequirePlugin = function(mid, require, loaded){ - dojoRequireCallbacks.push(loaded); - array.forEach(mid.split(","), function(mid){ - var module = getModule(mid, require.module); - dojoRequireModuleStack.push(module); - injectModule(module); - }); - checkDojoRequirePlugin(); - }, - - checkDojoRequirePlugin = ( 1 ? - // This version of checkDojoRequirePlugin makes the observation that all dojoRequireCallbacks can be released - // when all *non-dojo/require!, dojo/loadInit!* modules are either executed, not requested, or arrived. This is - // the case since there are no more modules the loader is waiting for, therefore, dojo/require! must have - // everything it needs on board. - // - // The potential weakness of this algorithm is that dojo/require will not execute callbacks until *all* dependency - // trees are ready. It is possible that some trees may be ready earlier than others, and this extra wait is non-optimal. - // Still, for big projects, this seems better than the original algorithm below that proved slow in some cases. - // Note, however, the original algorithm had the potential to execute partial trees, but that potential was never enabled. - // There are also other optimization available with the original algorithm that have not been explored. - function(){ - var module, mid; - for(mid in modules){ - module = modules[mid]; - if(module.noReqPluginCheck===undefined){ - // tag the module as either a loadInit or require plugin or not for future reference - module.noReqPluginCheck = /loadInit\!/.test(mid) || /require\!/.test(mid) ? 1 : 0; - } - if(!module.executed && !module.noReqPluginCheck && module.injected==requested){ - return; - } - } - - guardCheckComplete(function(){ - var oldCallbacks = dojoRequireCallbacks; - dojoRequireCallbacks = []; - array.forEach(oldCallbacks, function(cb){cb(1);}); - }); - } : (function(){ - // Note: this is the original checkDojoRequirePlugin that is much slower than the algorithm above. However, we know it - // works, so we leave it here in case the algorithm above fails in some corner case. - // - // checkDojoRequirePlugin inspects all of the modules demanded by a dojo/require! dependency - // to see if they have arrived. The loader does not release *any* of these modules to be instantiated - // until *all* of these modules are on board, thereby preventing the evaluation of a module with dojo.require's - // that reference modules that are not available. - // - // The algorithm works by traversing the dependency graphs (remember, there can be cycles so they are not trees) - // of each module in the dojoRequireModuleStack array (which contains the list of modules demanded by dojo/require!). - // The moment a single module is discovered that is missing, the algorithm gives up and indicates that not all - // modules are on board. dojo/loadInit! and dojo/require! are ignored because there dependencies are inserted - // directly in dojoRequireModuleStack. For example, if "your/module" module depends on "dojo/require!my/module", then - // *both* "dojo/require!my/module" and "my/module" will be in dojoRequireModuleStack. Obviously, if "my/module" - // is on board, then "dojo/require!my/module" is also satisfied, so the algorithm doesn't check for "dojo/require!my/module". - // - // Note: inserting a dojo/require! dependency in the dojoRequireModuleStack achieves nothing - // with the current algorithm; however, having such modules present makes it possible to optimize the algorithm - // - // Note: prior versions of this algorithm had an optimization that signaled loaded on dojo/require! dependencies - // individually (rather than waiting for them all to be resolved). The implementation proved problematic with cycles - // and plugins. However, it is possible to reattach that strategy in the future. - - // a set from module-id to {undefined | 1 | 0}, where... - // undefined => the module has not been inspected - // 0 => the module or at least one of its dependencies has not arrived - // 1 => the module is a loadInit! or require! plugin resource, or is currently being traversed (therefore, assume - // OK until proven otherwise), or has been completely traversed and all dependencies have arrived - - var touched, - traverse = function(m){ - touched[m.mid] = 1; - for(var t, module, deps = m.deps || [], i= 0; i a built module, always AMD - // extractResult==0 => no sync API - return 0; - } - - // manufacture a synthetic module id that can never be a real mdule id (just like require does) - id = module.mid + "-*loadInit"; - - // construct the dojo/loadInit names vector which causes any relocated names to be defined as lexical variables under their not-relocated name - // the dojo/loadInit plugin assumes the first name in names is "dojo" - - for(var p in getModule("dojo", module).result.scopeMap){ - names.push(p); - namesAsStrings.push('"' + p + '"'); - } - - // rewrite the module as a synthetic dojo/loadInit plugin resource + the module expressed as an AMD module that depends on this synthetic resource - // don't have to map dojo/init since that will occur when the dependency is resolved - return "// xdomain rewrite of " + module.mid + "\n" + - "define('" + id + "',{\n" + - "\tnames:" + json.stringify(names) + ",\n" + - "\tdef:function(" + names.join(",") + "){" + extractResult[1] + "}" + - "});\n\n" + - "define(" + json.stringify(names.concat(["dojo/loadInit!"+id])) + ", function(" + names.join(",") + "){\n" + extractResult[0] + "});"; - }, - - loaderVars = require.initSyncLoader(dojoRequirePlugin, checkDojoRequirePlugin, transformToAmd), - - sync = - loaderVars.sync, - - requested = - loaderVars.requested, - - arrived = - loaderVars.arrived, - - nonmodule = - loaderVars.nonmodule, - - executing = - loaderVars.executing, - - executed = - loaderVars.executed, - - syncExecStack = - loaderVars.syncExecStack, - - modules = - loaderVars.modules, - - execQ = - loaderVars.execQ, - - getModule = - loaderVars.getModule, - - injectModule = - loaderVars.injectModule, - - setArrived = - loaderVars.setArrived, - - signal = - loaderVars.signal, - - finishExec = - loaderVars.finishExec, - - execModule = - loaderVars.execModule, - - getLegacyMode = - loaderVars.getLegacyMode, - - guardCheckComplete = - loaderVars.guardCheckComplete; - - // there is exactly one dojoRequirePlugin among possibly-many dojo/_base/loader's (owing to mapping) - dojoRequirePlugin = loaderVars.dojoRequirePlugin; - - dojo.provide = function(mid){ - var executingModule = syncExecStack[0], - module = lang.mixin(getModule(slashName(mid), require.module), { - executed:executing, - result:lang.getObject(mid, true) - }); - setArrived(module); - if(executingModule){ - (executingModule.provides || (executingModule.provides = [])).push(function(){ - module.result = lang.getObject(mid); - delete module.provides; - module.executed!==executed && finishExec(module); - }); - }// else dojo.provide called not consequent to loading; therefore, give up trying to publish module value to loader namespace - return module.result; - }; - - has.add("config-publishRequireResult", 1, 0, 0); - - dojo.require = function(moduleName, omitModuleCheck) { - // summary: - // loads a Javascript module from the appropriate URI - // - // moduleName: String - // module name to load, using periods for separators, - // e.g. "dojo.date.locale". Module paths are de-referenced by dojo's - // internal mapping of locations to names and are disambiguated by - // longest prefix. See `dojo.registerModulePath()` for details on - // registering new modules. - // - // omitModuleCheck: Boolean? - // if `true`, omitModuleCheck skips the step of ensuring that the - // loaded file actually defines the symbol it is referenced by. - // For example if it called as `dojo.require("a.b.c")` and the - // file located at `a/b/c.js` does not define an object `a.b.c`, - // and exception will be throws whereas no exception is raised - // when called as `dojo.require("a.b.c", true)` - // - // description: - // Modules are loaded via dojo.require by using one of two loaders: the normal loader - // and the xdomain loader. The xdomain loader is used when dojo was built with a - // custom build that specified loader=xdomain and the module lives on a modulePath - // that is a whole URL, with protocol and a domain. The versions of Dojo that are on - // the Google and AOL CDNs use the xdomain loader. - // - // If the module is loaded via the xdomain loader, it is an asynchronous load, since - // the module is added via a dynamically created script tag. This - // means that dojo.require() can return before the module has loaded. However, this - // should only happen in the case where you do dojo.require calls in the top-level - // HTML page, or if you purposely avoid the loader checking for dojo.require - // dependencies in your module by using a syntax like dojo["require"] to load the module. - // - // Sometimes it is useful to not have the loader detect the dojo.require calls in the - // module so that you can dynamically load the modules as a result of an action on the - // page, instead of right at module load time. - // - // Also, for script blocks in an HTML page, the loader does not pre-process them, so - // it does not know to download the modules before the dojo.require calls occur. - // - // So, in those two cases, when you want on-the-fly module loading or for script blocks - // in the HTML page, special care must be taken if the dojo.required code is loaded - // asynchronously. To make sure you can execute code that depends on the dojo.required - // modules, be sure to add the code that depends on the modules in a dojo.addOnLoad() - // callback. dojo.addOnLoad waits for all outstanding modules to finish loading before - // executing. - // - // This type of syntax works with both xdomain and normal loaders, so it is good - // practice to always use this idiom for on-the-fly code loading and in HTML script - // blocks. If at some point you change loaders and where the code is loaded from, - // it will all still work. - // - // More on how dojo.require - // `dojo.require("A.B")` first checks to see if symbol A.B is - // defined. If it is, it is simply returned (nothing to do). - // - // If it is not defined, it will look for `A/B.js` in the script root - // directory. - // - // `dojo.require` throws an exception if it cannot find a file - // to load, or if the symbol `A.B` is not defined after loading. - // - // It returns the object `A.B`, but note the caveats above about on-the-fly loading and - // HTML script blocks when the xdomain loader is loading a module. - // - // `dojo.require()` does nothing about importing symbols into - // the current namespace. It is presumed that the caller will - // take care of that. - // - // example: - // To use dojo.require in conjunction with dojo.ready: - // - // | dojo.require("foo"); - // | dojo.require("bar"); - // | dojo.addOnLoad(function(){ - // | //you can now safely do something with foo and bar - // | }); - // - // example: - // For example, to import all symbols into a local block, you might write: - // - // | with (dojo.require("A.B")) { - // | ... - // | } - // - // And to import just the leaf symbol to a local variable: - // - // | var B = dojo.require("A.B"); - // | ... - // - // returns: - // the required namespace object - function doRequire(mid, omitModuleCheck){ - var module = getModule(slashName(mid), require.module); - if(syncExecStack.length && syncExecStack[0].finish){ - // switched to async loading in the middle of evaluating a legacy module; stop - // applying dojo.require so the remaining dojo.requires are applied in order - syncExecStack[0].finish.push(mid); - return undefined; - } - - // recall module.executed has values {0, executing, executed}; therefore, truthy indicates executing or executed - if(module.executed){ - return module.result; - } - omitModuleCheck && (module.result = nonmodule); - - // rcg...why here and in two lines?? - var currentMode = getLegacyMode(); - - // recall, in sync mode to inject is to *eval* the module text - // if the module is a legacy module, this is the same as executing - // but if the module is an AMD module, this means defining, not executing - injectModule(module); - // the inject may have changed the mode - currentMode = getLegacyMode(); - - // in sync mode to dojo.require is to execute - if(module.executed!==executed && module.injected===arrived){ - // the module was already here before injectModule was called probably finishing up a xdomain - // load, but maybe a module given to the loader directly rather than having the loader retrieve it - - loaderVars.guardCheckComplete(function(){ - execModule(module); - }); - } - if(module.executed){ - return module.result; - } - - if(currentMode==sync){ - // the only way to get here is in sync mode and dojo.required a module that - // * was loaded async in the injectModule application a few lines up - // * was an AMD module that had deps that are being loaded async and therefore couldn't execute - if(module.cjs){ - // the module was an AMD module; unshift, not push, which causes the current traversal to be reattempted from the top - execQ.unshift(module); - }else{ - // the module was a legacy module - syncExecStack.length && (syncExecStack[0].finish= [mid]); - } - }else{ - // the loader wasn't in sync mode on entry; probably async mode; therefore, no expectation of getting - // the module value synchronously; make sure it gets executed though - execQ.push(module); - } - - return undefined; - } - - var result = doRequire(moduleName, omitModuleCheck); - if(has("config-publishRequireResult") && !lang.exists(moduleName) && result!==undefined){ - lang.setObject(moduleName, result); - } - return result; - }; - - dojo.loadInit = function(f) { - f(); - }; - - dojo.registerModulePath = function(/*String*/moduleName, /*String*/prefix){ - // summary: - // Maps a module name to a path - // description: - // An unregistered module is given the default path of ../[module], - // relative to Dojo root. For example, module acme is mapped to - // ../acme. If you want to use a different module name, use - // dojo.registerModulePath. - // example: - // If your dojo.js is located at this location in the web root: - // | /myapp/js/dojo/dojo/dojo.js - // and your modules are located at: - // | /myapp/js/foo/bar.js - // | /myapp/js/foo/baz.js - // | /myapp/js/foo/thud/xyzzy.js - // Your application can tell Dojo to locate the "foo" namespace by calling: - // | dojo.registerModulePath("foo", "../../foo"); - // At which point you can then use dojo.require() to load the - // modules (assuming they provide() the same things which are - // required). The full code might be: - // | - // | - - var paths = {}; - paths[moduleName.replace(/\./g, "/")] = prefix; - require({paths:paths}); - }; - - dojo.platformRequire = function(/*Object*/modMap){ - // summary: - // require one or more modules based on which host environment - // Dojo is currently operating in - // description: - // This method takes a "map" of arrays which one can use to - // optionally load dojo modules. The map is indexed by the - // possible dojo.name_ values, with two additional values: - // "default" and "common". The items in the "default" array will - // be loaded if none of the other items have been chosen based on - // dojo.name_, set by your host environment. The items in the - // "common" array will *always* be loaded, regardless of which - // list is chosen. - // example: - // | dojo.platformRequire({ - // | browser: [ - // | "foo.sample", // simple module - // | "foo.test", - // | ["foo.bar.baz", true] // skip object check in _loadModule (dojo.require) - // | ], - // | default: [ "foo.sample._base" ], - // | common: [ "important.module.common" ] - // | }); - - var result = (modMap.common || []).concat(modMap[dojo._name] || modMap["default"] || []), - temp; - while(result.length){ - if(lang.isArray(temp = result.shift())){ - dojo.require.apply(dojo, temp); - }else{ - dojo.require(temp); - } - } - }; - - dojo.requireIf = dojo.requireAfterIf = function(/*Boolean*/ condition, /*String*/ moduleName, /*Boolean?*/omitModuleCheck){ - // summary: - // If the condition is true then call `dojo.require()` for the specified - // resource - // - // example: - // | dojo.requireIf(dojo.isBrowser, "my.special.Module"); - - if(condition){ - dojo.require(moduleName, omitModuleCheck); - } - }; - - dojo.requireLocalization = function(/*String*/moduleName, /*String*/bundleName, /*String?*/locale){ - require(["../i18n"], function(i18n){ - i18n.getLocalization(moduleName, bundleName, locale); - }); - }; - - return { - // summary: - // This module defines the v1.x synchronous loader API. - - extractLegacyApiApplications:extractLegacyApiApplications, - require:dojoRequirePlugin, - loadInit:dojoLoadInitPlugin - }; -}); diff --git a/lib/dojo/_base/query.js b/lib/dojo/_base/query.js deleted file mode 100644 index 0223f10..0000000 --- a/lib/dojo/_base/query.js +++ /dev/null @@ -1,10 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/_base/query",["../query","./NodeList"],function(_1){ -return _1; -}); diff --git a/lib/dojo/_base/query.js.uncompressed.js b/lib/dojo/_base/query.js.uncompressed.js deleted file mode 100644 index d354bbc..0000000 --- a/lib/dojo/_base/query.js.uncompressed.js +++ /dev/null @@ -1,13 +0,0 @@ -define("dojo/_base/query", ["../query", "./NodeList"], function(query){ - // module: - // dojo/_base/query - - /*===== - return { - // summary: - // Deprecated. Use dojo/query instead. - }; - =====*/ - - return query; -}); diff --git a/lib/dojo/_base/sniff.js b/lib/dojo/_base/sniff.js deleted file mode 100644 index 8935408..0000000 --- a/lib/dojo/_base/sniff.js +++ /dev/null @@ -1,15 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/_base/sniff",["./kernel","./lang","../sniff"],function(_1,_2,_3){ -if(!1){ -return _3; -} -_1._name="browser"; -_2.mixin(_1,{isBrowser:true,isFF:_3("ff"),isIE:_3("ie"),isKhtml:_3("khtml"),isWebKit:_3("webkit"),isMozilla:_3("mozilla"),isMoz:_3("mozilla"),isOpera:_3("opera"),isSafari:_3("safari"),isChrome:_3("chrome"),isMac:_3("mac"),isIos:_3("ios"),isAndroid:_3("android"),isWii:_3("wii"),isQuirks:_3("quirks"),isAir:_3("air")}); -return _3; -}); diff --git a/lib/dojo/_base/sniff.js.uncompressed.js b/lib/dojo/_base/sniff.js.uncompressed.js deleted file mode 100644 index 780918d..0000000 --- a/lib/dojo/_base/sniff.js.uncompressed.js +++ /dev/null @@ -1,93 +0,0 @@ -define("dojo/_base/sniff", ["./kernel", "./lang", "../sniff"], function(dojo, lang, has){ - // module: - // dojo/_base/sniff - - /*===== - return { - // summary: - // Deprecated. New code should use dojo/sniff. - // This module populates the dojo browser version sniffing properties like dojo.isIE. - }; - =====*/ - - if(! 1 ){ - return has; - } - - // no idea what this is for, or if it's used - dojo._name = "browser"; - - lang.mixin(dojo, { - // isBrowser: Boolean - // True if the client is a web-browser - isBrowser: true, - - // isFF: Number|undefined - // Version as a Number if client is FireFox. undefined otherwise. Corresponds to - // major detected FireFox version (1.5, 2, 3, etc.) - isFF: has("ff"), - - // isIE: Number|undefined - // Version as a Number if client is MSIE(PC). undefined otherwise. Corresponds to - // major detected IE version (6, 7, 8, etc.) - isIE: has("ie"), - - // isKhtml: Number|undefined - // Version as a Number if client is a KHTML browser. undefined otherwise. Corresponds to major - // detected version. - isKhtml: has("khtml"), - - // isWebKit: Number|undefined - // Version as a Number if client is a WebKit-derived browser (Konqueror, - // Safari, Chrome, etc.). undefined otherwise. - isWebKit: has("webkit"), - - // isMozilla: Number|undefined - // Version as a Number if client is a Mozilla-based browser (Firefox, - // SeaMonkey). undefined otherwise. Corresponds to major detected version. - isMozilla: has("mozilla"), - // isMoz: Number|undefined - // Version as a Number if client is a Mozilla-based browser (Firefox, - // SeaMonkey). undefined otherwise. Corresponds to major detected version. - isMoz: has("mozilla"), - - // isOpera: Number|undefined - // Version as a Number if client is Opera. undefined otherwise. Corresponds to - // major detected version. - isOpera: has("opera"), - - // isSafari: Number|undefined - // Version as a Number if client is Safari or iPhone. undefined otherwise. - isSafari: has("safari"), - - // isChrome: Number|undefined - // Version as a Number if client is Chrome browser. undefined otherwise. - isChrome: has("chrome"), - - // isMac: Boolean - // True if the client runs on Mac - isMac: has("mac"), - - // isIos: Number|undefined - // Version as a Number if client is iPhone, iPod, or iPad. undefined otherwise. - isIos: has("ios"), - - // isAndroid: Number|undefined - // Version as a Number if client is android browser. undefined otherwise. - isAndroid: has("android"), - - // isWii: Boolean - // True if client is Wii - isWii: has("wii"), - - // isQuirks: Boolean - // Page is in quirks mode. - isQuirks: has("quirks"), - - // isAir: Boolean - // True if client is Adobe Air - isAir: has("air") - }); - - return has; -}); diff --git a/lib/dojo/_base/unload.js b/lib/dojo/_base/unload.js deleted file mode 100644 index a770e4d..0000000 --- a/lib/dojo/_base/unload.js +++ /dev/null @@ -1,22 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/_base/unload",["./kernel","./lang","../on"],function(_1,_2,on){ -var _3=window; -var _4={addOnWindowUnload:function(_5,_6){ -if(!_1.windowUnloaded){ -on(_3,"unload",(_1.windowUnloaded=function(){ -})); -} -on(_3,"unload",_2.hitch(_5,_6)); -},addOnUnload:function(_7,_8){ -on(_3,"beforeunload",_2.hitch(_7,_8)); -}}; -_1.addOnWindowUnload=_4.addOnWindowUnload; -_1.addOnUnload=_4.addOnUnload; -return _4; -}); diff --git a/lib/dojo/_base/unload.js.uncompressed.js b/lib/dojo/_base/unload.js.uncompressed.js deleted file mode 100644 index 115703b..0000000 --- a/lib/dojo/_base/unload.js.uncompressed.js +++ /dev/null @@ -1,95 +0,0 @@ -define("dojo/_base/unload", ["./kernel", "./lang", "../on"], function(dojo, lang, on){ - -// module: -// dojo/unload - -var win = window; - -var unload = { - // summary: - // This module contains the document and window unload detection API. - // This module is deprecated. Use on(window, "unload", func) - // and on(window, "beforeunload", func) instead. - - addOnWindowUnload: function(/*Object|Function?*/ obj, /*String|Function?*/ functionName){ - // summary: - // Registers a function to be triggered when window.onunload fires. - // Deprecated, use on(window, "unload", lang.hitch(obj, functionName)) instead. - // description: - // The first time that addOnWindowUnload is called Dojo - // will register a page listener to trigger your unload - // handler with. Note that registering these handlers may - // destroy "fastback" page caching in browsers that support - // it. Be careful trying to modify the DOM or access - // JavaScript properties during this phase of page unloading: - // they may not always be available. Consider - // addOnUnload() if you need to modify the DOM or do - // heavy JavaScript work since it fires at the equivalent of - // the page's "onbeforeunload" event. - // example: - // | var afunc = function() {console.log("global function");}; - // | require(["dojo/_base/unload"], function(unload) { - // | var foo = {bar: function(){ console.log("bar unloading...");}, - // | data: "mydata"}; - // | unload.addOnWindowUnload(afunc); - // | unload.addOnWindowUnload(foo, "bar"); - // | unload.addOnWindowUnload(foo, function(){console.log("", this.data);}); - // | }); - - if (!dojo.windowUnloaded){ - on(win, "unload", (dojo.windowUnloaded = function(){ - // summary: - // signal fired by impending window destruction. You may use - // dojo.addOnWindowUnload() to register a listener for this - // event. NOTE: if you wish to dojo.connect() to this method - // to perform page/application cleanup, be aware that this - // event WILL NOT fire if no handler has been registered with - // addOnWindowUnload(). This behavior started in Dojo 1.3. - // Previous versions always triggered windowUnloaded(). See - // addOnWindowUnload for more info. - })); - } - on(win, "unload", lang.hitch(obj, functionName)); - }, - - addOnUnload: function(/*Object?|Function?*/ obj, /*String|Function?*/ functionName){ - // summary: - // Registers a function to be triggered when the page unloads. - // Deprecated, use on(window, "beforeunload", lang.hitch(obj, functionName)) instead. - // description: - // The first time that addOnUnload is called Dojo will - // register a page listener to trigger your unload handler - // with. - // - // In a browser environment, the functions will be triggered - // during the window.onbeforeunload event. Be careful of doing - // too much work in an unload handler. onbeforeunload can be - // triggered if a link to download a file is clicked, or if - // the link is a javascript: link. In these cases, the - // onbeforeunload event fires, but the document is not - // actually destroyed. So be careful about doing destructive - // operations in a dojo.addOnUnload callback. - // - // Further note that calling dojo.addOnUnload will prevent - // browsers from using a "fast back" cache to make page - // loading via back button instantaneous. - // example: - // | var afunc = function() {console.log("global function");}; - // | require(["dojo/_base/unload"], function(unload) { - // | var foo = {bar: function(){ console.log("bar unloading...");}, - // | data: "mydata"}; - // | unload.addOnUnload(afunc); - // | unload.addOnUnload(foo, "bar"); - // | unload.addOnUnload(foo, function(){console.log("", this.data);}); - // | }); - - on(win, "beforeunload", lang.hitch(obj, functionName)); - } -}; - -dojo.addOnWindowUnload = unload.addOnWindowUnload; -dojo.addOnUnload = unload.addOnUnload; - -return unload; - -}); diff --git a/lib/dojo/_base/url.js b/lib/dojo/_base/url.js deleted file mode 100644 index 02ecd4c..0000000 --- a/lib/dojo/_base/url.js +++ /dev/null @@ -1,88 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/_base/url",["./kernel"],function(_1){ -var _2=new RegExp("^(([^:/?#]+):)?(//([^/?#]*))?([^?#]*)(\\?([^#]*))?(#(.*))?$"),_3=new RegExp("^((([^\\[:]+):)?([^@]+)@)?(\\[([^\\]]+)\\]|([^\\[:]*))(:([0-9]+))?$"),_4=function(){ -var n=null,_5=arguments,_6=[_5[0]]; -for(var i=1;i<_5.length;i++){ -if(!_5[i]){ -continue; -} -var _7=new _4(_5[i]+""),_8=new _4(_6[0]+""); -if(_7.path==""&&!_7.scheme&&!_7.authority&&!_7.query){ -if(_7.fragment!=n){ -_8.fragment=_7.fragment; -} -_7=_8; -}else{ -if(!_7.scheme){ -_7.scheme=_8.scheme; -if(!_7.authority){ -_7.authority=_8.authority; -if(_7.path.charAt(0)!="/"){ -var _9=_8.path.substring(0,_8.path.lastIndexOf("/")+1)+_7.path; -var _a=_9.split("/"); -for(var j=0;j<_a.length;j++){ -if(_a[j]=="."){ -if(j==_a.length-1){ -_a[j]=""; -}else{ -_a.splice(j,1); -j--; -} -}else{ -if(j>0&&!(j==1&&_a[0]=="")&&_a[j]==".."&&_a[j-1]!=".."){ -if(j==(_a.length-1)){ -_a.splice(j,1); -_a[j-1]=""; -}else{ -_a.splice(j-1,2); -j-=2; -} -} -} -} -_7.path=_a.join("/"); -} -} -} -} -_6=[]; -if(_7.scheme){ -_6.push(_7.scheme,":"); -} -if(_7.authority){ -_6.push("//",_7.authority); -} -_6.push(_7.path); -if(_7.query){ -_6.push("?",_7.query); -} -if(_7.fragment){ -_6.push("#",_7.fragment); -} -} -this.uri=_6.join(""); -var r=this.uri.match(_2); -this.scheme=r[2]||(r[1]?"":n); -this.authority=r[4]||(r[3]?"":n); -this.path=r[5]; -this.query=r[7]||(r[6]?"":n); -this.fragment=r[9]||(r[8]?"":n); -if(this.authority!=n){ -r=this.authority.match(_3); -this.user=r[3]||n; -this.password=r[4]||n; -this.host=r[6]||r[7]; -this.port=r[9]||n; -} -}; -_4.prototype.toString=function(){ -return this.uri; -}; -return _1._Url=_4; -}); diff --git a/lib/dojo/_base/url.js.uncompressed.js b/lib/dojo/_base/url.js.uncompressed.js deleted file mode 100644 index c83e1a2..0000000 --- a/lib/dojo/_base/url.js.uncompressed.js +++ /dev/null @@ -1,109 +0,0 @@ -define("dojo/_base/url", ["./kernel"], function(dojo){ - // module: - // dojo/url - - var - ore = new RegExp("^(([^:/?#]+):)?(//([^/?#]*))?([^?#]*)(\\?([^#]*))?(#(.*))?$"), - ire = new RegExp("^((([^\\[:]+):)?([^@]+)@)?(\\[([^\\]]+)\\]|([^\\[:]*))(:([0-9]+))?$"), - _Url = function(){ - var n = null, - _a = arguments, - uri = [_a[0]]; - // resolve uri components relative to each other - for(var i = 1; i<_a.length; i++){ - if(!_a[i]){ continue; } - - // Safari doesn't support this.constructor so we have to be explicit - // FIXME: Tracked (and fixed) in Webkit bug 3537. - // http://bugs.webkit.org/show_bug.cgi?id=3537 - var relobj = new _Url(_a[i]+""), - uriobj = new _Url(uri[0]+""); - - if( - relobj.path == "" && - !relobj.scheme && - !relobj.authority && - !relobj.query - ){ - if(relobj.fragment != n){ - uriobj.fragment = relobj.fragment; - } - relobj = uriobj; - }else if(!relobj.scheme){ - relobj.scheme = uriobj.scheme; - - if(!relobj.authority){ - relobj.authority = uriobj.authority; - - if(relobj.path.charAt(0) != "/"){ - var path = uriobj.path.substring(0, - uriobj.path.lastIndexOf("/") + 1) + relobj.path; - - var segs = path.split("/"); - for(var j = 0; j < segs.length; j++){ - if(segs[j] == "."){ - // flatten "./" references - if(j == segs.length - 1){ - segs[j] = ""; - }else{ - segs.splice(j, 1); - j--; - } - }else if(j > 0 && !(j == 1 && segs[0] == "") && - segs[j] == ".." && segs[j-1] != ".."){ - // flatten "../" references - if(j == (segs.length - 1)){ - segs.splice(j, 1); - segs[j - 1] = ""; - }else{ - segs.splice(j - 1, 2); - j -= 2; - } - } - } - relobj.path = segs.join("/"); - } - } - } - - uri = []; - if(relobj.scheme){ - uri.push(relobj.scheme, ":"); - } - if(relobj.authority){ - uri.push("//", relobj.authority); - } - uri.push(relobj.path); - if(relobj.query){ - uri.push("?", relobj.query); - } - if(relobj.fragment){ - uri.push("#", relobj.fragment); - } - } - - this.uri = uri.join(""); - - // break the uri into its main components - var r = this.uri.match(ore); - - this.scheme = r[2] || (r[1] ? "" : n); - this.authority = r[4] || (r[3] ? "" : n); - this.path = r[5]; // can never be undefined - this.query = r[7] || (r[6] ? "" : n); - this.fragment = r[9] || (r[8] ? "" : n); - - if(this.authority != n){ - // server based naming authority - r = this.authority.match(ire); - - this.user = r[3] || n; - this.password = r[4] || n; - this.host = r[6] || r[7]; // ipv6 || ipv4 - this.port = r[9] || n; - } - }; - _Url.prototype.toString = function(){ return this.uri; }; - - return dojo._Url = _Url; -}); diff --git a/lib/dojo/_base/window.js b/lib/dojo/_base/window.js deleted file mode 100644 index 8a2636d..0000000 --- a/lib/dojo/_base/window.js +++ /dev/null @@ -1,52 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/_base/window",["./kernel","./lang","../sniff"],function(_1,_2,_3){ -var _4={global:_1.global,doc:this["document"]||null,body:function(_5){ -_5=_5||_1.doc; -return _5.body||_5.getElementsByTagName("body")[0]; -},setContext:function(_6,_7){ -_1.global=_4.global=_6; -_1.doc=_4.doc=_7; -},withGlobal:function(_8,_9,_a,_b){ -var _c=_1.global; -try{ -_1.global=_4.global=_8; -return _4.withDoc.call(null,_8.document,_9,_a,_b); -} -finally{ -_1.global=_4.global=_c; -} -},withDoc:function(_d,_e,_f,_10){ -var _11=_4.doc,_12=_3("quirks"),_13=_3("ie"),_14,_15,_16; -try{ -_1.doc=_4.doc=_d; -_1.isQuirks=_3.add("quirks",_1.doc.compatMode=="BackCompat",true,true); -if(_3("ie")){ -if((_16=_d.parentWindow)&&_16.navigator){ -_14=parseFloat(_16.navigator.appVersion.split("MSIE ")[1])||undefined; -_15=_d.documentMode; -if(_15&&_15!=5&&Math.floor(_14)!=_15){ -_14=_15; -} -_1.isIE=_3.add("ie",_14,true,true); -} -} -if(_f&&typeof _e=="string"){ -_e=_f[_e]; -} -return _e.apply(_f,_10||[]); -} -finally{ -_1.doc=_4.doc=_11; -_1.isQuirks=_3.add("quirks",_12,true,true); -_1.isIE=_3.add("ie",_13,true,true); -} -}}; -1&&_2.mixin(_1,_4); -return _4; -}); diff --git a/lib/dojo/_base/window.js.uncompressed.js b/lib/dojo/_base/window.js.uncompressed.js deleted file mode 100644 index 3d23c3a..0000000 --- a/lib/dojo/_base/window.js.uncompressed.js +++ /dev/null @@ -1,134 +0,0 @@ -define("dojo/_base/window", ["./kernel", "./lang", "../sniff"], function(dojo, lang, has){ -// module: -// dojo/_base/window - -var ret = { - // summary: - // API to save/set/restore the global/document scope. - - global: dojo.global, - /*===== - global: { - // summary: - // Alias for the current window. 'global' can be modified - // for temporary context shifting. See also withGlobal(). - // description: - // Use this rather than referring to 'window' to ensure your code runs - // correctly in managed contexts. - }, - =====*/ - - doc: this["document"] || null, - /*===== - doc: { - // summary: - // Alias for the current document. 'doc' can be modified - // for temporary context shifting. See also withDoc(). - // description: - // Use this rather than referring to 'window.document' to ensure your code runs - // correctly in managed contexts. - // example: - // | n.appendChild(dojo.doc.createElement('div')); - }, - =====*/ - - body: function(/*Document?*/ doc){ - // summary: - // Return the body element of the specified document or of dojo/_base/window::doc. - // example: - // | win.body().appendChild(dojo.doc.createElement('div')); - - // Note: document.body is not defined for a strict xhtml document - // Would like to memoize this, but dojo.doc can change vi dojo.withDoc(). - doc = doc || dojo.doc; - return doc.body || doc.getElementsByTagName("body")[0]; // Node - }, - - setContext: function(/*Object*/ globalObject, /*DocumentElement*/ globalDocument){ - // summary: - // changes the behavior of many core Dojo functions that deal with - // namespace and DOM lookup, changing them to work in a new global - // context (e.g., an iframe). The varibles dojo.global and dojo.doc - // are modified as a result of calling this function and the result of - // `dojo.body()` likewise differs. - dojo.global = ret.global = globalObject; - dojo.doc = ret.doc = globalDocument; - }, - - withGlobal: function( /*Object*/ globalObject, - /*Function*/ callback, - /*Object?*/ thisObject, - /*Array?*/ cbArguments){ - // summary: - // Invoke callback with globalObject as dojo.global and - // globalObject.document as dojo.doc. - // description: - // Invoke callback with globalObject as dojo.global and - // globalObject.document as dojo.doc. If provided, globalObject - // will be executed in the context of object thisObject - // When callback() returns or throws an error, the dojo.global - // and dojo.doc will be restored to its previous state. - - var oldGlob = dojo.global; - try{ - dojo.global = ret.global = globalObject; - return ret.withDoc.call(null, globalObject.document, callback, thisObject, cbArguments); - }finally{ - dojo.global = ret.global = oldGlob; - } - }, - - withDoc: function( /*DocumentElement*/ documentObject, - /*Function*/ callback, - /*Object?*/ thisObject, - /*Array?*/ cbArguments){ - // summary: - // Invoke callback with documentObject as dojo/_base/window::doc. - // description: - // Invoke callback with documentObject as dojo/_base/window::doc. If provided, - // callback will be executed in the context of object thisObject - // When callback() returns or throws an error, the dojo/_base/window::doc will - // be restored to its previous state. - - var oldDoc = ret.doc, - oldQ = has("quirks"), - oldIE = has("ie"), isIE, mode, pwin; - - try{ - dojo.doc = ret.doc = documentObject; - // update dojo.isQuirks and the value of the has feature "quirks". - // remove setting dojo.isQuirks and dojo.isIE for 2.0 - dojo.isQuirks = has.add("quirks", dojo.doc.compatMode == "BackCompat", true, true); // no need to check for QuirksMode which was Opera 7 only - - if(has("ie")){ - if((pwin = documentObject.parentWindow) && pwin.navigator){ - // re-run IE detection logic and update dojo.isIE / has("ie") - // (the only time parentWindow/navigator wouldn't exist is if we were not - // passed an actual legitimate document object) - isIE = parseFloat(pwin.navigator.appVersion.split("MSIE ")[1]) || undefined; - mode = documentObject.documentMode; - if(mode && mode != 5 && Math.floor(isIE) != mode){ - isIE = mode; - } - dojo.isIE = has.add("ie", isIE, true, true); - } - } - - if(thisObject && typeof callback == "string"){ - callback = thisObject[callback]; - } - - return callback.apply(thisObject, cbArguments || []); - }finally{ - dojo.doc = ret.doc = oldDoc; - dojo.isQuirks = has.add("quirks", oldQ, true, true); - dojo.isIE = has.add("ie", oldIE, true, true); - } - } -}; - - 1 && lang.mixin(dojo, ret); - -return ret; - -}); diff --git a/lib/dojo/_base/xhr.js b/lib/dojo/_base/xhr.js deleted file mode 100644 index 774649a..0000000 --- a/lib/dojo/_base/xhr.js +++ /dev/null @@ -1,273 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/_base/xhr",["./kernel","./sniff","require","../io-query","../dom","../dom-form","./Deferred","./config","./json","./lang","./array","../on","../aspect","../request/watch","../request/xhr","../request/util"],function(_1,_2,_3,_4,_5,_6,_7,_8,_9,_a,_b,on,_c,_d,_e,_f){ -_1._xhrObj=_e._create; -var cfg=_1.config; -_1.objectToQuery=_4.objectToQuery; -_1.queryToObject=_4.queryToObject; -_1.fieldToObject=_6.fieldToObject; -_1.formToObject=_6.toObject; -_1.formToQuery=_6.toQuery; -_1.formToJson=_6.toJson; -_1._blockAsync=false; -var _10=_1._contentHandlers=_1.contentHandlers={"text":function(xhr){ -return xhr.responseText; -},"json":function(xhr){ -return _9.fromJson(xhr.responseText||null); -},"json-comment-filtered":function(xhr){ -if(!_8.useCommentedJson){ -console.warn("Consider using the standard mimetype:application/json."+" json-commenting can introduce security issues. To"+" decrease the chances of hijacking, use the standard the 'json' handler and"+" prefix your json with: {}&&\n"+"Use djConfig.useCommentedJson=true to turn off this message."); -} -var _11=xhr.responseText; -var _12=_11.indexOf("/*"); -var _13=_11.lastIndexOf("*/"); -if(_12==-1||_13==-1){ -throw new Error("JSON was not comment filtered"); -} -return _9.fromJson(_11.substring(_12+2,_13)); -},"javascript":function(xhr){ -return _1.eval(xhr.responseText); -},"xml":function(xhr){ -var _14=xhr.responseXML; -if(_14&&_2("dom-qsa2.1")&&!_14.querySelectorAll&&_2("dom-parser")){ -_14=new DOMParser().parseFromString(xhr.responseText,"application/xml"); -} -if(_2("ie")){ -if((!_14||!_14.documentElement)){ -var ms=function(n){ -return "MSXML"+n+".DOMDocument"; -}; -var dp=["Microsoft.XMLDOM",ms(6),ms(4),ms(3),ms(2)]; -_b.some(dp,function(p){ -try{ -var dom=new ActiveXObject(p); -dom.async=false; -dom.loadXML(xhr.responseText); -_14=dom; -} -catch(e){ -return false; -} -return true; -}); -} -} -return _14; -},"json-comment-optional":function(xhr){ -if(xhr.responseText&&/^[^{\[]*\/\*/.test(xhr.responseText)){ -return _10["json-comment-filtered"](xhr); -}else{ -return _10["json"](xhr); -} -}}; -_1._ioSetArgs=function(_15,_16,_17,_18){ -var _19={args:_15,url:_15.url}; -var _1a=null; -if(_15.form){ -var _1b=_5.byId(_15.form); -var _1c=_1b.getAttributeNode("action"); -_19.url=_19.url||(_1c?_1c.value:null); -_1a=_6.toObject(_1b); -} -var _1d=[{}]; -if(_1a){ -_1d.push(_1a); -} -if(_15.content){ -_1d.push(_15.content); -} -if(_15.preventCache){ -_1d.push({"dojo.preventCache":new Date().valueOf()}); -} -_19.query=_4.objectToQuery(_a.mixin.apply(null,_1d)); -_19.handleAs=_15.handleAs||"text"; -var d=new _7(function(dfd){ -dfd.canceled=true; -_16&&_16(dfd); -var err=dfd.ioArgs.error; -if(!err){ -err=new Error("request cancelled"); -err.dojoType="cancel"; -dfd.ioArgs.error=err; -} -return err; -}); -d.addCallback(_17); -var ld=_15.load; -if(ld&&_a.isFunction(ld)){ -d.addCallback(function(_1e){ -return ld.call(_15,_1e,_19); -}); -} -var err=_15.error; -if(err&&_a.isFunction(err)){ -d.addErrback(function(_1f){ -return err.call(_15,_1f,_19); -}); -} -var _20=_15.handle; -if(_20&&_a.isFunction(_20)){ -d.addBoth(function(_21){ -return _20.call(_15,_21,_19); -}); -} -d.addErrback(function(_22){ -return _18(_22,d); -}); -if(cfg.ioPublish&&_1.publish&&_19.args.ioPublish!==false){ -d.addCallbacks(function(res){ -_1.publish("/dojo/io/load",[d,res]); -return res; -},function(res){ -_1.publish("/dojo/io/error",[d,res]); -return res; -}); -d.addBoth(function(res){ -_1.publish("/dojo/io/done",[d,res]); -return res; -}); -} -d.ioArgs=_19; -return d; -}; -var _23=function(dfd){ -var ret=_10[dfd.ioArgs.handleAs](dfd.ioArgs.xhr); -return ret===undefined?null:ret; -}; -var _24=function(_25,dfd){ -if(!dfd.ioArgs.args.failOk){ -console.error(_25); -} -return _25; -}; -var _26=function(dfd){ -if(_27<=0){ -_27=0; -if(cfg.ioPublish&&_1.publish&&(!dfd||dfd&&dfd.ioArgs.args.ioPublish!==false)){ -_1.publish("/dojo/io/stop"); -} -} -}; -var _27=0; -_c.after(_d,"_onAction",function(){ -_27-=1; -}); -_c.after(_d,"_onInFlight",_26); -_1._ioCancelAll=_d.cancelAll; -_1._ioNotifyStart=function(dfd){ -if(cfg.ioPublish&&_1.publish&&dfd.ioArgs.args.ioPublish!==false){ -if(!_27){ -_1.publish("/dojo/io/start"); -} -_27+=1; -_1.publish("/dojo/io/send",[dfd]); -} -}; -_1._ioWatch=function(dfd,_28,_29,_2a){ -var _2b=dfd.ioArgs.options=dfd.ioArgs.args; -_a.mixin(dfd,{response:dfd.ioArgs,isValid:function(_2c){ -return _28(dfd); -},isReady:function(_2d){ -return _29(dfd); -},handleResponse:function(_2e){ -return _2a(dfd); -}}); -_d(dfd); -_26(dfd); -}; -var _2f="application/x-www-form-urlencoded"; -_1._ioAddQueryToUrl=function(_30){ -if(_30.query.length){ -_30.url+=(_30.url.indexOf("?")==-1?"?":"&")+_30.query; -_30.query=null; -} -}; -_1.xhr=function(_31,_32,_33){ -var _34; -var dfd=_1._ioSetArgs(_32,function(dfd){ -_34&&_34.cancel(); -},_23,_24); -var _35=dfd.ioArgs; -if("postData" in _32){ -_35.query=_32.postData; -}else{ -if("putData" in _32){ -_35.query=_32.putData; -}else{ -if("rawBody" in _32){ -_35.query=_32.rawBody; -}else{ -if((arguments.length>2&&!_33)||"POST|PUT".indexOf(_31.toUpperCase())===-1){ -_1._ioAddQueryToUrl(_35); -} -} -} -} -var _36={method:_31,handleAs:"text",timeout:_32.timeout,withCredentials:_32.withCredentials,ioArgs:_35}; -if(typeof _32.headers!=="undefined"){ -_36.headers=_32.headers; -} -if(typeof _32.contentType!=="undefined"){ -if(!_36.headers){ -_36.headers={}; -} -_36.headers["Content-Type"]=_32.contentType; -} -if(typeof _35.query!=="undefined"){ -_36.data=_35.query; -} -if(typeof _32.sync!=="undefined"){ -_36.sync=_32.sync; -} -_1._ioNotifyStart(dfd); -try{ -_34=_e(_35.url,_36,true); -} -catch(e){ -dfd.cancel(); -return dfd; -} -dfd.ioArgs.xhr=_34.response.xhr; -_34.then(function(){ -dfd.resolve(dfd); -}).otherwise(function(_37){ -_35.error=_37; -if(_37.response){ -_37.status=_37.response.status; -_37.responseText=_37.response.text; -_37.xhr=_37.response.xhr; -} -dfd.reject(_37); -}); -return dfd; -}; -_1.xhrGet=function(_38){ -return _1.xhr("GET",_38); -}; -_1.rawXhrPost=_1.xhrPost=function(_39){ -return _1.xhr("POST",_39,true); -}; -_1.rawXhrPut=_1.xhrPut=function(_3a){ -return _1.xhr("PUT",_3a,true); -}; -_1.xhrDelete=function(_3b){ -return _1.xhr("DELETE",_3b); -}; -_1._isDocumentOk=function(x){ -return _f.checkStatus(x.status); -}; -_1._getText=function(url){ -var _3c; -_1.xhrGet({url:url,sync:true,load:function(_3d){ -_3c=_3d; -}}); -return _3c; -}; -_a.mixin(_1.xhr,{_xhrObj:_1._xhrObj,fieldToObject:_6.fieldToObject,formToObject:_6.toObject,objectToQuery:_4.objectToQuery,formToQuery:_6.toQuery,formToJson:_6.toJson,queryToObject:_4.queryToObject,contentHandlers:_10,_ioSetArgs:_1._ioSetArgs,_ioCancelAll:_1._ioCancelAll,_ioNotifyStart:_1._ioNotifyStart,_ioWatch:_1._ioWatch,_ioAddQueryToUrl:_1._ioAddQueryToUrl,_isDocumentOk:_1._isDocumentOk,_getText:_1._getText,get:_1.xhrGet,post:_1.xhrPost,put:_1.xhrPut,del:_1.xhrDelete}); -return _1.xhr; -}); diff --git a/lib/dojo/_base/xhr.js.uncompressed.js b/lib/dojo/_base/xhr.js.uncompressed.js deleted file mode 100644 index 647a3ec..0000000 --- a/lib/dojo/_base/xhr.js.uncompressed.js +++ /dev/null @@ -1,718 +0,0 @@ -define("dojo/_base/xhr", [ - "./kernel", - "./sniff", - "require", - "../io-query", - /*===== "./declare", =====*/ - "../dom", - "../dom-form", - "./Deferred", - "./config", - "./json", - "./lang", - "./array", - "../on", - "../aspect", - "../request/watch", - "../request/xhr", - "../request/util" -], function(dojo, has, require, ioq, /*===== declare, =====*/ dom, domForm, Deferred, config, json, lang, array, on, aspect, watch, _xhr, util){ - // module: - // dojo/_base/xhr - - /*===== - dojo._xhrObj = function(){ - // summary: - // does the work of portably generating a new XMLHTTPRequest object. - }; - =====*/ - dojo._xhrObj = _xhr._create; - - var cfg = dojo.config; - - // mix in io-query and dom-form - dojo.objectToQuery = ioq.objectToQuery; - dojo.queryToObject = ioq.queryToObject; - dojo.fieldToObject = domForm.fieldToObject; - dojo.formToObject = domForm.toObject; - dojo.formToQuery = domForm.toQuery; - dojo.formToJson = domForm.toJson; - - // need to block async callbacks from snatching this thread as the result - // of an async callback might call another sync XHR, this hangs khtml forever - // must checked by watchInFlight() - - dojo._blockAsync = false; - - // MOW: remove dojo._contentHandlers alias in 2.0 - var handlers = dojo._contentHandlers = dojo.contentHandlers = { - // summary: - // A map of available XHR transport handle types. Name matches the - // `handleAs` attribute passed to XHR calls. - // description: - // A map of available XHR transport handle types. Name matches the - // `handleAs` attribute passed to XHR calls. Each contentHandler is - // called, passing the xhr object for manipulation. The return value - // from the contentHandler will be passed to the `load` or `handle` - // functions defined in the original xhr call. - // example: - // Creating a custom content-handler: - // | xhr.contentHandlers.makeCaps = function(xhr){ - // | return xhr.responseText.toUpperCase(); - // | } - // | // and later: - // | dojo.xhrGet({ - // | url:"foo.txt", - // | handleAs:"makeCaps", - // | load: function(data){ /* data is a toUpper version of foo.txt */ } - // | }); - - "text": function(xhr){ - // summary: - // A contentHandler which simply returns the plaintext response data - return xhr.responseText; - }, - "json": function(xhr){ - // summary: - // A contentHandler which returns a JavaScript object created from the response data - return json.fromJson(xhr.responseText || null); - }, - "json-comment-filtered": function(xhr){ - // summary: - // A contentHandler which expects comment-filtered JSON. - // description: - // A contentHandler which expects comment-filtered JSON. - // the json-comment-filtered option was implemented to prevent - // "JavaScript Hijacking", but it is less secure than standard JSON. Use - // standard JSON instead. JSON prefixing can be used to subvert hijacking. - // - // Will throw a notice suggesting to use application/json mimetype, as - // json-commenting can introduce security issues. To decrease the chances of hijacking, - // use the standard `json` contentHandler, and prefix your "JSON" with: {}&& - // - // use djConfig.useCommentedJson = true to turn off the notice - if(!config.useCommentedJson){ - console.warn("Consider using the standard mimetype:application/json." - + " json-commenting can introduce security issues. To" - + " decrease the chances of hijacking, use the standard the 'json' handler and" - + " prefix your json with: {}&&\n" - + "Use djConfig.useCommentedJson=true to turn off this message."); - } - - var value = xhr.responseText; - var cStartIdx = value.indexOf("\/*"); - var cEndIdx = value.lastIndexOf("*\/"); - if(cStartIdx == -1 || cEndIdx == -1){ - throw new Error("JSON was not comment filtered"); - } - return json.fromJson(value.substring(cStartIdx+2, cEndIdx)); - }, - "javascript": function(xhr){ - // summary: - // A contentHandler which evaluates the response data, expecting it to be valid JavaScript - - // FIXME: try Moz and IE specific eval variants? - return dojo.eval(xhr.responseText); - }, - "xml": function(xhr){ - // summary: - // A contentHandler returning an XML Document parsed from the response data - var result = xhr.responseXML; - - if(result && has("dom-qsa2.1") && !result.querySelectorAll && has("dom-parser")){ - // http://bugs.dojotoolkit.org/ticket/15631 - // IE9 supports a CSS3 querySelectorAll implementation, but the DOM implementation - // returned by IE9 xhr.responseXML does not. Manually create the XML DOM to gain - // the fuller-featured implementation and avoid bugs caused by the inconsistency - result = new DOMParser().parseFromString(xhr.responseText, "application/xml"); - } - - if(has("ie")){ - if((!result || !result.documentElement)){ - //WARNING: this branch used by the xml handling in dojo.io.iframe, - //so be sure to test dojo.io.iframe if making changes below. - var ms = function(n){ return "MSXML" + n + ".DOMDocument"; }; - var dp = ["Microsoft.XMLDOM", ms(6), ms(4), ms(3), ms(2)]; - array.some(dp, function(p){ - try{ - var dom = new ActiveXObject(p); - dom.async = false; - dom.loadXML(xhr.responseText); - result = dom; - }catch(e){ return false; } - return true; - }); - } - } - return result; // DOMDocument - }, - "json-comment-optional": function(xhr){ - // summary: - // A contentHandler which checks the presence of comment-filtered JSON and - // alternates between the `json` and `json-comment-filtered` contentHandlers. - if(xhr.responseText && /^[^{\[]*\/\*/.test(xhr.responseText)){ - return handlers["json-comment-filtered"](xhr); - }else{ - return handlers["json"](xhr); - } - } - }; - - /*===== - - // kwargs function parameter definitions. Assigning to dojo namespace rather than making them local variables - // because they are used by dojo/io modules too - - dojo.__IoArgs = declare(null, { - // url: String - // URL to server endpoint. - // content: Object? - // Contains properties with string values. These - // properties will be serialized as name1=value2 and - // passed in the request. - // timeout: Integer? - // Milliseconds to wait for the response. If this time - // passes, the then error callbacks are called. - // form: DOMNode? - // DOM node for a form. Used to extract the form values - // and send to the server. - // preventCache: Boolean? - // Default is false. If true, then a - // "dojo.preventCache" parameter is sent in the request - // with a value that changes with each request - // (timestamp). Useful only with GET-type requests. - // handleAs: String? - // Acceptable values depend on the type of IO - // transport (see specific IO calls for more information). - // rawBody: String? - // Sets the raw body for an HTTP request. If this is used, then the content - // property is ignored. This is mostly useful for HTTP methods that have - // a body to their requests, like PUT or POST. This property can be used instead - // of postData and putData for dojo/_base/xhr.rawXhrPost and dojo/_base/xhr.rawXhrPut respectively. - // ioPublish: Boolean? - // Set this explicitly to false to prevent publishing of topics related to - // IO operations. Otherwise, if djConfig.ioPublish is set to true, topics - // will be published via dojo/topic.publish() for different phases of an IO operation. - // See dojo/main.__IoPublish for a list of topics that are published. - - load: function(response, ioArgs){ - // summary: - // This function will be - // called on a successful HTTP response code. - // ioArgs: dojo/main.__IoCallbackArgs - // Provides additional information about the request. - // response: Object - // The response in the format as defined with handleAs. - }, - - error: function(response, ioArgs){ - // summary: - // This function will - // be called when the request fails due to a network or server error, the url - // is invalid, etc. It will also be called if the load or handle callback throws an - // exception, unless djConfig.debugAtAllCosts is true. This allows deployed applications - // to continue to run even when a logic error happens in the callback, while making - // it easier to troubleshoot while in debug mode. - // ioArgs: dojo/main.__IoCallbackArgs - // Provides additional information about the request. - // response: Object - // The response in the format as defined with handleAs. - }, - - handle: function(loadOrError, response, ioArgs){ - // summary: - // This function will - // be called at the end of every request, whether or not an error occurs. - // loadOrError: String - // Provides a string that tells you whether this function - // was called because of success (load) or failure (error). - // response: Object - // The response in the format as defined with handleAs. - // ioArgs: dojo/main.__IoCallbackArgs - // Provides additional information about the request. - } - }); - - dojo.__IoCallbackArgs = declare(null, { - // args: Object - // the original object argument to the IO call. - // xhr: XMLHttpRequest - // For XMLHttpRequest calls only, the - // XMLHttpRequest object that was used for the - // request. - // url: String - // The final URL used for the call. Many times it - // will be different than the original args.url - // value. - // query: String - // For non-GET requests, the - // name1=value1&name2=value2 parameters sent up in - // the request. - // handleAs: String - // The final indicator on how the response will be - // handled. - // id: String - // For dojo/io/script calls only, the internal - // script ID used for the request. - // canDelete: Boolean - // For dojo/io/script calls only, indicates - // whether the script tag that represents the - // request can be deleted after callbacks have - // been called. Used internally to know when - // cleanup can happen on JSONP-type requests. - // json: Object - // For dojo/io/script calls only: holds the JSON - // response for JSONP-type requests. Used - // internally to hold on to the JSON responses. - // You should not need to access it directly -- - // the same object should be passed to the success - // callbacks directly. - }); - - dojo.__IoPublish = declare(null, { - // summary: - // This is a list of IO topics that can be published - // if djConfig.ioPublish is set to true. IO topics can be - // published for any Input/Output, network operation. So, - // dojo.xhr, dojo.io.script and dojo.io.iframe can all - // trigger these topics to be published. - // start: String - // "/dojo/io/start" is sent when there are no outstanding IO - // requests, and a new IO request is started. No arguments - // are passed with this topic. - // send: String - // "/dojo/io/send" is sent whenever a new IO request is started. - // It passes the dojo.Deferred for the request with the topic. - // load: String - // "/dojo/io/load" is sent whenever an IO request has loaded - // successfully. It passes the response and the dojo.Deferred - // for the request with the topic. - // error: String - // "/dojo/io/error" is sent whenever an IO request has errored. - // It passes the error and the dojo.Deferred - // for the request with the topic. - // done: String - // "/dojo/io/done" is sent whenever an IO request has completed, - // either by loading or by erroring. It passes the error and - // the dojo.Deferred for the request with the topic. - // stop: String - // "/dojo/io/stop" is sent when all outstanding IO requests have - // finished. No arguments are passed with this topic. - }); - =====*/ - - - dojo._ioSetArgs = function(/*dojo/main.__IoArgs*/args, - /*Function*/canceller, - /*Function*/okHandler, - /*Function*/errHandler){ - // summary: - // sets up the Deferred and ioArgs property on the Deferred so it - // can be used in an io call. - // args: - // The args object passed into the public io call. Recognized properties on - // the args object are: - // canceller: - // The canceller function used for the Deferred object. The function - // will receive one argument, the Deferred object that is related to the - // canceller. - // okHandler: - // The first OK callback to be registered with Deferred. It has the opportunity - // to transform the OK response. It will receive one argument -- the Deferred - // object returned from this function. - // errHandler: - // The first error callback to be registered with Deferred. It has the opportunity - // to do cleanup on an error. It will receive two arguments: error (the - // Error object) and dfd, the Deferred object returned from this function. - - var ioArgs = {args: args, url: args.url}; - - //Get values from form if requested. - var formObject = null; - if(args.form){ - var form = dom.byId(args.form); - //IE requires going through getAttributeNode instead of just getAttribute in some form cases, - //so use it for all. See #2844 - var actnNode = form.getAttributeNode("action"); - ioArgs.url = ioArgs.url || (actnNode ? actnNode.value : null); - formObject = domForm.toObject(form); - } - - // set up the query params - var miArgs = [{}]; - - if(formObject){ - // potentially over-ride url-provided params w/ form values - miArgs.push(formObject); - } - if(args.content){ - // stuff in content over-rides what's set by form - miArgs.push(args.content); - } - if(args.preventCache){ - miArgs.push({"dojo.preventCache": new Date().valueOf()}); - } - ioArgs.query = ioq.objectToQuery(lang.mixin.apply(null, miArgs)); - - // .. and the real work of getting the deferred in order, etc. - ioArgs.handleAs = args.handleAs || "text"; - var d = new Deferred(function(dfd){ - dfd.canceled = true; - canceller && canceller(dfd); - - var err = dfd.ioArgs.error; - if(!err){ - err = new Error("request cancelled"); - err.dojoType="cancel"; - dfd.ioArgs.error = err; - } - return err; - }); - d.addCallback(okHandler); - - //Support specifying load, error and handle callback functions from the args. - //For those callbacks, the "this" object will be the args object. - //The callbacks will get the deferred result value as the - //first argument and the ioArgs object as the second argument. - var ld = args.load; - if(ld && lang.isFunction(ld)){ - d.addCallback(function(value){ - return ld.call(args, value, ioArgs); - }); - } - var err = args.error; - if(err && lang.isFunction(err)){ - d.addErrback(function(value){ - return err.call(args, value, ioArgs); - }); - } - var handle = args.handle; - if(handle && lang.isFunction(handle)){ - d.addBoth(function(value){ - return handle.call(args, value, ioArgs); - }); - } - - // Attach error handler last (not including topic publishing) - // to catch any errors that may have been generated from load - // or handle functions. - d.addErrback(function(error){ - return errHandler(error, d); - }); - - //Plug in topic publishing, if dojo.publish is loaded. - if(cfg.ioPublish && dojo.publish && ioArgs.args.ioPublish !== false){ - d.addCallbacks( - function(res){ - dojo.publish("/dojo/io/load", [d, res]); - return res; - }, - function(res){ - dojo.publish("/dojo/io/error", [d, res]); - return res; - } - ); - d.addBoth(function(res){ - dojo.publish("/dojo/io/done", [d, res]); - return res; - }); - } - - d.ioArgs = ioArgs; - - // FIXME: need to wire up the xhr object's abort method to something - // analogous in the Deferred - return d; - }; - - var _deferredOk = function(/*Deferred*/dfd){ - // summary: - // okHandler function for dojo._ioSetArgs call. - - var ret = handlers[dfd.ioArgs.handleAs](dfd.ioArgs.xhr); - return ret === undefined ? null : ret; - }; - var _deferError = function(/*Error*/error, /*Deferred*/dfd){ - // summary: - // errHandler function for dojo._ioSetArgs call. - - if(!dfd.ioArgs.args.failOk){ - console.error(error); - } - return error; - }; - - //Use a separate count for knowing if we are starting/stopping io calls. - var _checkPubCount = function(dfd){ - if(_pubCount <= 0){ - _pubCount = 0; - if(cfg.ioPublish && dojo.publish && (!dfd || dfd && dfd.ioArgs.args.ioPublish !== false)){ - dojo.publish("/dojo/io/stop"); - } - } - }; - - var _pubCount = 0; - aspect.after(watch, "_onAction", function(){ - _pubCount -= 1; - }); - aspect.after(watch, "_onInFlight", _checkPubCount); - - dojo._ioCancelAll = watch.cancelAll; - /*===== - dojo._ioCancelAll = function(){ - // summary: - // Cancels all pending IO requests, regardless of IO type - // (xhr, script, iframe). - }; - =====*/ - - dojo._ioNotifyStart = function(/*Deferred*/dfd){ - // summary: - // If dojo.publish is available, publish topics - // about the start of a request queue and/or the - // the beginning of request. - // - // Used by IO transports. An IO transport should - // call this method before making the network connection. - if(cfg.ioPublish && dojo.publish && dfd.ioArgs.args.ioPublish !== false){ - if(!_pubCount){ - dojo.publish("/dojo/io/start"); - } - _pubCount += 1; - dojo.publish("/dojo/io/send", [dfd]); - } - }; - - dojo._ioWatch = function(dfd, validCheck, ioCheck, resHandle){ - // summary: - // Watches the io request represented by dfd to see if it completes. - // dfd: Deferred - // The Deferred object to watch. - // validCheck: Function - // Function used to check if the IO request is still valid. Gets the dfd - // object as its only argument. - // ioCheck: Function - // Function used to check if basic IO call worked. Gets the dfd - // object as its only argument. - // resHandle: Function - // Function used to process response. Gets the dfd - // object as its only argument. - - var args = dfd.ioArgs.options = dfd.ioArgs.args; - lang.mixin(dfd, { - response: dfd.ioArgs, - isValid: function(response){ - return validCheck(dfd); - }, - isReady: function(response){ - return ioCheck(dfd); - }, - handleResponse: function(response){ - return resHandle(dfd); - } - }); - watch(dfd); - - _checkPubCount(dfd); - }; - - var _defaultContentType = "application/x-www-form-urlencoded"; - - dojo._ioAddQueryToUrl = function(/*dojo.__IoCallbackArgs*/ioArgs){ - // summary: - // Adds query params discovered by the io deferred construction to the URL. - // Only use this for operations which are fundamentally GET-type operations. - if(ioArgs.query.length){ - ioArgs.url += (ioArgs.url.indexOf("?") == -1 ? "?" : "&") + ioArgs.query; - ioArgs.query = null; - } - }; - - /*===== - dojo.__XhrArgs = declare(dojo.__IoArgs, { - // summary: - // In addition to the properties listed for the dojo._IoArgs type, - // the following properties are allowed for dojo.xhr* methods. - // handleAs: String? - // Acceptable values are: text (default), json, json-comment-optional, - // json-comment-filtered, javascript, xml. See `dojo/_base/xhr.contentHandlers` - // sync: Boolean? - // false is default. Indicates whether the request should - // be a synchronous (blocking) request. - // headers: Object? - // Additional HTTP headers to send in the request. - // failOk: Boolean? - // false is default. Indicates whether a request should be - // allowed to fail (and therefore no console error message in - // the event of a failure) - // contentType: String|Boolean - // "application/x-www-form-urlencoded" is default. Set to false to - // prevent a Content-Type header from being sent, or to a string - // to send a different Content-Type. - }); - =====*/ - - dojo.xhr = function(/*String*/ method, /*dojo.__XhrArgs*/ args, /*Boolean?*/ hasBody){ - // summary: - // Deprecated. Use dojo/request instead. - // description: - // Sends an HTTP request with the given method. - // See also dojo.xhrGet(), xhrPost(), xhrPut() and dojo.xhrDelete() for shortcuts - // for those HTTP methods. There are also methods for "raw" PUT and POST methods - // via dojo.rawXhrPut() and dojo.rawXhrPost() respectively. - // method: - // HTTP method to be used, such as GET, POST, PUT, DELETE. Should be uppercase. - // hasBody: - // If the request has an HTTP body, then pass true for hasBody. - - var rDfd; - //Make the Deferred object for this xhr request. - var dfd = dojo._ioSetArgs(args, function(dfd){ - rDfd && rDfd.cancel(); - }, _deferredOk, _deferError); - var ioArgs = dfd.ioArgs; - - //Allow for specifying the HTTP body completely. - if("postData" in args){ - ioArgs.query = args.postData; - }else if("putData" in args){ - ioArgs.query = args.putData; - }else if("rawBody" in args){ - ioArgs.query = args.rawBody; - }else if((arguments.length > 2 && !hasBody) || "POST|PUT".indexOf(method.toUpperCase()) === -1){ - //Check for hasBody being passed. If no hasBody, - //then only append query string if not a POST or PUT request. - dojo._ioAddQueryToUrl(ioArgs); - } - - var options = { - method: method, - handleAs: "text", - timeout: args.timeout, - withCredentials: args.withCredentials, - ioArgs: ioArgs - }; - - if(typeof args.headers !== 'undefined'){ - options.headers = args.headers; - } - if(typeof args.contentType !== 'undefined'){ - if(!options.headers){ - options.headers = {}; - } - options.headers['Content-Type'] = args.contentType; - } - if(typeof ioArgs.query !== 'undefined'){ - options.data = ioArgs.query; - } - if(typeof args.sync !== 'undefined'){ - options.sync = args.sync; - } - - dojo._ioNotifyStart(dfd); - try{ - rDfd = _xhr(ioArgs.url, options, true); - }catch(e){ - // If XHR creation fails, dojo/request/xhr throws - // When this happens, cancel the deferred - dfd.cancel(); - return dfd; - } - - // sync ioArgs - dfd.ioArgs.xhr = rDfd.response.xhr; - - rDfd.then(function(){ - dfd.resolve(dfd); - }).otherwise(function(error){ - ioArgs.error = error; - if(error.response){ - error.status = error.response.status; - error.responseText = error.response.text; - error.xhr = error.response.xhr; - } - dfd.reject(error); - }); - return dfd; // dojo/_base/Deferred - }; - - dojo.xhrGet = function(/*dojo.__XhrArgs*/ args){ - // summary: - // Sends an HTTP GET request to the server. - return dojo.xhr("GET", args); // dojo/_base/Deferred - }; - - dojo.rawXhrPost = dojo.xhrPost = function(/*dojo.__XhrArgs*/ args){ - // summary: - // Sends an HTTP POST request to the server. In addition to the properties - // listed for the dojo.__XhrArgs type, the following property is allowed: - // postData: - // String. Send raw data in the body of the POST request. - return dojo.xhr("POST", args, true); // dojo/_base/Deferred - }; - - dojo.rawXhrPut = dojo.xhrPut = function(/*dojo.__XhrArgs*/ args){ - // summary: - // Sends an HTTP PUT request to the server. In addition to the properties - // listed for the dojo.__XhrArgs type, the following property is allowed: - // putData: - // String. Send raw data in the body of the PUT request. - return dojo.xhr("PUT", args, true); // dojo/_base/Deferred - }; - - dojo.xhrDelete = function(/*dojo.__XhrArgs*/ args){ - // summary: - // Sends an HTTP DELETE request to the server. - return dojo.xhr("DELETE", args); // dojo/_base/Deferred - }; - - /* - dojo.wrapForm = function(formNode){ - // summary: - // A replacement for FormBind, but not implemented yet. - - // FIXME: need to think harder about what extensions to this we might - // want. What should we allow folks to do w/ this? What events to - // set/send? - throw new Error("dojo.wrapForm not yet implemented"); - } - */ - - dojo._isDocumentOk = function(x){ - return util.checkStatus(x.status); - }; - - dojo._getText = function(url){ - var result; - dojo.xhrGet({url:url, sync:true, load:function(text){ - result = text; - }}); - return result; - }; - - // Add aliases for static functions to dojo.xhr since dojo.xhr is what's returned from this module - lang.mixin(dojo.xhr, { - _xhrObj: dojo._xhrObj, - fieldToObject: domForm.fieldToObject, - formToObject: domForm.toObject, - objectToQuery: ioq.objectToQuery, - formToQuery: domForm.toQuery, - formToJson: domForm.toJson, - queryToObject: ioq.queryToObject, - contentHandlers: handlers, - _ioSetArgs: dojo._ioSetArgs, - _ioCancelAll: dojo._ioCancelAll, - _ioNotifyStart: dojo._ioNotifyStart, - _ioWatch: dojo._ioWatch, - _ioAddQueryToUrl: dojo._ioAddQueryToUrl, - _isDocumentOk: dojo._isDocumentOk, - _getText: dojo._getText, - get: dojo.xhrGet, - post: dojo.xhrPost, - put: dojo.xhrPut, - del: dojo.xhrDelete // because "delete" is a reserved word - }); - - return dojo.xhr; -}); diff --git a/lib/dojo/_firebug/LICENSE b/lib/dojo/_firebug/LICENSE deleted file mode 100644 index 8c777a2..0000000 --- a/lib/dojo/_firebug/LICENSE +++ /dev/null @@ -1,37 +0,0 @@ -License Disclaimer: - -All contents of this directory are Copyright (c) the Dojo Foundation, with the -following exceptions: -------------------------------------------------------------------------------- - -firebug.html, firebug.js, errIcon.png, infoIcon.png, warningIcon.png: - * Copyright (c) 2006-2007, Joe Hewitt, All rights reserved. - Distributed under the terms of the BSD License (see below) - -------------------------------------------------------------------------------- - -Copyright (c) 2006-2007, Joe Hewitt -All rights reserved. - -Redistribution and use in source and binary forms, with or without -modification, are permitted provided that the following conditions are met: - - * Redistributions of source code must retain the above copyright notice, this - list of conditions and the following disclaimer. - * Redistributions in binary form must reproduce the above copyright notice, - this list of conditions and the following disclaimer in the documentation - and/or other materials provided with the distribution. - * Neither the name of the Dojo Foundation nor the names of its contributors - may be used to endorse or promote products derived from this software - without specific prior written permission. - -THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND -ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED -WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE -FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL -DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER -CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, -OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/lib/dojo/_firebug/errorIcon.png b/lib/dojo/_firebug/errorIcon.png deleted file mode 100644 index 2d75261..0000000 Binary files a/lib/dojo/_firebug/errorIcon.png and /dev/null differ diff --git a/lib/dojo/_firebug/firebug.css b/lib/dojo/_firebug/firebug.css deleted file mode 100644 index 3b6f4f9..0000000 --- a/lib/dojo/_firebug/firebug.css +++ /dev/null @@ -1,208 +0,0 @@ -.firebug { - margin: 0; - background:#fff; - font-family: Lucida Grande, Tahoma, sans-serif; - font-size: 11px; - overflow: hidden; - border: 1px solid black; - position: relative; -} -.firebug a { - text-decoration: none; -} -.firebug a:hover { - text-decoration: underline; -} -.firebug a:visited{ - color:#0000FF; -} -.firebug #firebugToolbar { - height: 18px; - line-height:18px; - border-top: 1px solid ThreeDHighlight; - border-bottom: 1px solid ThreeDShadow; - padding: 2px 6px; - - background:#f0f0f0; -} -.firebug #firebugLog, .firebug #objectLog { - overflow: auto; - position: absolute; - left: 0; - width: 100%; -} -#objectLog{ - overflow:scroll; - height:258px; -} -.firebug #firebugCommandLine { - position: absolute; - bottom: 0; - left: 0; - width: 100%; - height: 18px; - border: none; - border-top: 1px solid ThreeDShadow; -} -.firebug .logRow { - position: relative; - border-bottom: 1px solid #D7D7D7; - padding: 2px 4px 1px 6px; - background-color: #FFFFFF; -} -.firebug .logRow-command { - font-family: Monaco, monospace; - color: blue; -} -.firebug .objectBox-null { - padding: 0 2px; - border: 1px solid #666666; - background-color: #888888; - color: #FFFFFF; -} -.firebug .objectBox-string { - font-family: Monaco, monospace; - color: red; - white-space: pre; -} -.firebug .objectBox-number { - color: #000088; -} -.firebug .objectBox-function { - font-family: Monaco, monospace; - color: DarkGreen; -} -.firebug .objectBox-object { - color: DarkGreen; - font-weight: bold; -} -.firebug .logRow-info, -.firebug .logRow-error, -.firebug .logRow-warning - { - background: #00FFFF no-repeat 2px 2px; - padding-left: 20px; - padding-bottom: 3px; -} -.firebug .logRow-info { - background: #FFF url(infoIcon.png) no-repeat 2px 2px; - padding-left: 20px; - padding-bottom: 3px; -} -.firebug .logRow-warning { - - background: #00FFFF url(warningIcon.png) no-repeat 2px 2px; - padding-left: 20px; - padding-bottom: 3px; -} -.firebug .logRow-error { - background: LightYellow url(errorIcon.png) no-repeat 2px 2px; - padding-left: 20px; - padding-bottom: 3px; -} -.firebug .errorMessage { - vertical-align: top; - color: #FF0000; -} -.firebug .objectBox-sourceLink { - position: absolute; - right: 4px; - top: 2px; - padding-left: 8px; - font-family: Lucida Grande, sans-serif; - font-weight: bold; - color: #0000FF; -} -.firebug .logRow-group { - background: #EEEEEE; - border-bottom: none; -} -.firebug .logGroup { - background: #EEEEEE; -} -.firebug .logGroupBox { - margin-left: 24px; - border-top: 1px solid #D7D7D7; - border-left: 1px solid #D7D7D7; -} -.firebug .selectorTag, -.firebug .selectorId, -.firebug .selectorClass { - font-family: Monaco, monospace; - font-weight: normal; -} -.firebug .selectorTag { - color: #0000FF; -} -.firebug .selectorId { - color: DarkBlue; -} -.firebug .selectorClass { - color: red; -} -.firebug .objectBox-element { - font-family: Monaco, monospace; - color: #000088; -} -.firebug .nodeChildren { - margin-left: 16px; -} -.firebug .nodeTag { - color: blue; -} -.firebug .nodeValue { - color: #FF0000; - font-weight: normal; -} -.firebug .nodeText, -.firebug .nodeComment { - margin: 0 2px; - vertical-align: top; -} -.firebug .nodeText { - color: #333333; -} -.firebug .nodeComment { - color: DarkGreen; -} -.firebug .propertyNameCell { - vertical-align: top; -} -.firebug .propertyName { - font-weight: bold; -} -#firebugToolbar ul.tabs{ - margin:0 !important; - padding:0; -} -#firebugToolbar ul.tabs li{ - list-style:none; - background:transparent url(tab_lft_norm.png) no-repeat left; - line-height:18px; - float:left; - margin-left:5px; -} -#firebugToolbar ul.tabs li.right{ - float:right; - margin-right:5px; - margin-left:0; -} -#firebugToolbar ul.tabs li.gap{ - margin-left:20px; -} -#firebugToolbar .tabs a{ - text-decoration:none; - background:transparent url(tab_rgt_norm.png) no-repeat right; - line-height:18px; - padding:3px 9px 4px 0px; - margin-left:9px; - color:#333333; -} -#firebugToolbar .tabs li:hover{ - background:transparent url(tab_lft_over.png) no-repeat left; -} -#firebugToolbar .tabs a:hover{ - text-decoration:none; - background:transparent url(tab_rgt_over.png) no-repeat right; - color:#FFFFFF; -} diff --git a/lib/dojo/_firebug/firebug.js b/lib/dojo/_firebug/firebug.js deleted file mode 100644 index adbb692..0000000 --- a/lib/dojo/_firebug/firebug.js +++ /dev/null @@ -1,898 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/_firebug/firebug",["../_base/kernel","require","../_base/html","../sniff","../_base/array","../_base/lang","../_base/event","../_base/unload"],function(_1,_2,_3,_4){ -var _5=(/Trident/.test(window.navigator.userAgent)); -if(_5){ -var _6=["log","info","debug","warn","error"]; -for(var i=0;i<_6.length;i++){ -var m=_6[i]; -if(!console[m]||console[m]._fake){ -continue; -} -var n="_"+_6[i]; -console[n]=console[m]; -console[m]=(function(){ -var _7=n; -return function(){ -console[_7](Array.prototype.join.call(arguments," ")); -}; -})(); -} -try{ -console.clear(); -} -catch(e){ -} -} -if(_4("ff")||_4("chrome")||_4("safari")||_5||window.firebug||(typeof console!="undefined"&&console.firebug)||_1.config.useCustomLogger||_4("air")){ -return; -} -try{ -if(window!=window.parent){ -if(window.parent["console"]){ -window.console=window.parent.console; -} -return; -} -} -catch(e){ -} -var _8=document; -var _9=window; -var _a=0; -var _b=null; -var _c=null; -var _d=null; -var _e=null; -var _f=null; -var _10=null; -var _11=false; -var _12=[]; -var _13=[]; -var _14={}; -var _15={}; -var _16=null; -var _17; -var _18; -var _19=false; -var _1a=null; -var _1b=document.createElement("div"); -var _1c; -var _1d; -window.console={_connects:[],log:function(){ -_1e(arguments,""); -},debug:function(){ -_1e(arguments,"debug"); -},info:function(){ -_1e(arguments,"info"); -},warn:function(){ -_1e(arguments,"warning"); -},error:function(){ -_1e(arguments,"error"); -},assert:function(_1f,_20){ -if(!_1f){ -var _21=[]; -for(var i=1;i"); -str=str.replace(/\t/g,"    "); -_23([str],"dir"); -},dirxml:function(_24){ -var _25=[]; -_26(_24,_25); -_23(_25,"dirxml"); -},group:function(){ -_23(arguments,"group",_27); -},groupEnd:function(){ -_23(arguments,"",_28); -},time:function(_29){ -_14[_29]=new Date().getTime(); -},timeEnd:function(_2a){ -if(_2a in _14){ -var _2b=(new Date()).getTime()-_14[_2a]; -_1e([_2a+":",_2b+"ms"]); -delete _14[_2a]; -} -},count:function(_2c){ -if(!_15[_2c]){ -_15[_2c]=0; -} -_15[_2c]++; -_1e([_2c+": "+_15[_2c]]); -},trace:function(_2d){ -var _2e=_2d||3; -var f=console.trace.caller; -for(var i=0;i<_2e;i++){ -var _2f=f.toString(); -var _30=[]; -for(var a=0;a=0&&s.href){ -var h=s.href.replace(/(&|%5C?)forceReload=\d+/,""); -s.href=h+(h.indexOf("?")>=0?"&":"?")+"forceReload="+new Date().valueOf(); -} -} -}}; -function _31(_35){ -_11=_35||!_11; -if(_b){ -_b.style.display=_11?"block":"none"; -} -}; -function _36(){ -_31(true); -if(_f){ -_f.focus(); -} -}; -function _37(x,y,w,h){ -var win=window.open("","_firebug","status=0,menubar=0,resizable=1,top="+y+",left="+x+",width="+w+",height="+h+",scrollbars=1,addressbar=0"); -if(!win){ -var msg="Firebug Lite could not open a pop-up window, most likely because of a blocker.\n"+"Either enable pop-ups for this domain, or change the djConfig to popup=false."; -alert(msg); -} -_38(win); -var _39=win.document; -var _3a="Firebug Lite\n"+"\n"+"
    "+""; -_39.write(_3a); -_39.close(); -return win; -}; -function _38(wn){ -var d=new Date(); -d.setTime(d.getTime()+(60*24*60*60*1000)); -d=d.toUTCString(); -var dc=wn.document,_3b; -if(wn.innerWidth){ -_3b=function(){ -return {w:wn.innerWidth,h:wn.innerHeight}; -}; -}else{ -if(dc.documentElement&&dc.documentElement.clientWidth){ -_3b=function(){ -return {w:dc.documentElement.clientWidth,h:dc.documentElement.clientHeight}; -}; -}else{ -if(dc.body){ -_3b=function(){ -return {w:dc.body.clientWidth,h:dc.body.clientHeight}; -}; -} -} -} -window.onFirebugResize=function(){ -_49(_3b().h); -clearInterval(wn._firebugWin_resize); -wn._firebugWin_resize=setTimeout(function(){ -var x=wn.screenLeft,y=wn.screenTop,w=wn.outerWidth||wn.document.body.offsetWidth,h=wn.outerHeight||wn.document.body.offsetHeight; -document.cookie="_firebugPosition="+[x,y,w,h].join(",")+"; expires="+d+"; path=/"; -},5000); -}; -}; -function _3c(){ -if(_b){ -return; -} -_31(true); -if(_1.config.popup){ -var _3d="100%"; -var _3e=document.cookie.match(/(?:^|; )_firebugPosition=([^;]*)/); -var p=_3e?_3e[1].split(","):[2,2,320,480]; -_9=_37(p[0],p[1],p[2],p[3]); -_8=_9.document; -_1.config.debugContainerId="fb"; -_9.console=window.console; -_9.dojo=window.dojo; -}else{ -_8=document; -_3d=(_1.config.debugHeight||300)+"px"; -} -var _3f=_8.createElement("link"); -_3f.href=_2.toUrl("./firebug.css"); -_3f.rel="stylesheet"; -_3f.type="text/css"; -var _40=_8.getElementsByTagName("head"); -if(_40){ -_40=_40[0]; -} -if(!_40){ -_40=_8.getElementsByTagName("html")[0]; -} -if(_4("ie")){ -window.setTimeout(function(){ -_40.appendChild(_3f); -},0); -}else{ -_40.appendChild(_3f); -} -if(_1.config.debugContainerId){ -_b=_8.getElementById(_1.config.debugContainerId); -} -if(!_b){ -_b=_8.createElement("div"); -_8.body.appendChild(_b); -} -_b.className+=" firebug"; -_b.id="firebug"; -_b.style.height=_3d; -_b.style.display=(_11?"block":"none"); -var _41=function(_42,_43,_44,_45){ -return "
  • "+_42+"
  • "; -}; -_b.innerHTML="
    "+"
      "+_41("Clear","Remove All Console Logs","clear","")+_41("ReCSS","Refresh CSS without reloading page","recss","")+_41("Console","Show Console Logs","openConsole","gap")+_41("DOM","Show DOM Inspector","openDomInspector","")+_41("Object","Show Object Inspector","openObjectInspector","")+((_1.config.popup)?"":_41("Close","Close the console","close","gap"))+"\t
    "+"
    "+""+"
    "+"
    Click on an object in the Log display
    "+"
    Hover over HTML elements in the main page. Click to hold selection.
    "; -_10=_8.getElementById("firebugToolbar"); -_f=_8.getElementById("firebugCommandLine"); -_46(_f,"keydown",_47); -_46(_8,_4("ie")||_4("safari")?"keydown":"keypress",_48); -_c=_8.getElementById("firebugLog"); -_d=_8.getElementById("objectLog"); -_16=_8.getElementById("domInspect"); -_e=_8.getElementById("fireBugTabs"); -_49(); -_4a(); -}; -_1.addOnLoad(_3c); -function _4b(){ -_8=null; -if(_9.console){ -_9.console.clear(); -} -_9=null; -_b=null; -_c=null; -_d=null; -_16=null; -_f=null; -_12=[]; -_13=[]; -_14={}; -}; -function _4c(){ -var _4d=_f.value; -_f.value=""; -_23(["> ",_4d],"command"); -var _4e; -try{ -_4e=eval(_4d); -} -catch(e){ -} -}; -function _49(h){ -var _4f=25; -var _50=h?h-(_4f+_f.offsetHeight+25+(h*0.01))+"px":(_b.offsetHeight-_4f-_f.offsetHeight)+"px"; -_c.style.top=_4f+"px"; -_c.style.height=_50; -_d.style.height=_50; -_d.style.top=_4f+"px"; -_16.style.height=_50; -_16.style.top=_4f+"px"; -_f.style.bottom=0; -_1.addOnWindowUnload(_4b); -}; -function _23(_51,_52,_53){ -if(_c){ -_54(_51,_52,_53); -}else{ -_12.push([_51,_52,_53]); -} -}; -function _4a(){ -var _55=_12; -_12=[]; -for(var i=0;i<_55.length;++i){ -_54(_55[i][0],_55[i][1],_55[i][2]); -} -}; -function _54(_56,_57,_58){ -var _59=_c.scrollTop+_c.offsetHeight>=_c.scrollHeight; -_58=_58||_5a; -_58(_56,_57); -if(_59){ -_c.scrollTop=_c.scrollHeight-_c.offsetHeight; -} -}; -function _5b(row){ -var _5c=_13.length?_13[_13.length-1]:_c; -_5c.appendChild(row); -}; -function _5a(_5d,_5e){ -var row=_c.ownerDocument.createElement("div"); -row.className="logRow"+(_5e?" logRow-"+_5e:""); -row.innerHTML=_5d.join(""); -_5b(row); -}; -function _27(_5f,_60){ -_1e(_5f,_60); -var _61=_c.ownerDocument.createElement("div"); -_61.className="logGroupBox"; -_5b(_61); -_13.push(_61); -}; -function _28(){ -_13.pop(); -}; -function _1e(_62,_63){ -var _64=[]; -var _65=_62[0]; -var _66=0; -if(typeof (_65)!="string"){ -_65=""; -_66=-1; -} -var _67=_68(_65); -for(var i=0;i<_67.length;++i){ -var _69=_67[i]; -if(_69&&typeof _69=="object"){ -_69.appender(_62[++_66],_64); -}else{ -_6a(_69,_64); -} -} -var ids=[]; -var obs=[]; -for(i=_66+1;i<_62.length;++i){ -_6a(" ",_64); -var _6b=_62[i]; -if(_6b===undefined||_6b===null){ -_6c(_6b,_64); -}else{ -if(typeof (_6b)=="string"){ -_6a(_6b,_64); -}else{ -if(_6b instanceof Date){ -_6a(_6b.toString(),_64); -}else{ -if(_6b.nodeType==9){ -_6a("[ XmlDoc ]",_64); -}else{ -var id="_a"+_a++; -ids.push(id); -obs.push(_6b); -var str=""+_6d(_6b)+""; -_6e(str,_64); -} -} -} -} -} -_23(_64,_63); -for(i=0;i"; -})); -} -}; -function _68(_6f){ -var _70=[]; -var reg=/((^%|[^\\]%)(\d+)?(\.)([a-zA-Z]))|((^%|[^\\]%)([a-zA-Z]))/; -var _71={s:_6a,d:_72,i:_72,f:_73}; -for(var m=reg.exec(_6f);m;m=reg.exec(_6f)){ -var _74=m[8]?m[8]:m[5]; -var _75=_74 in _71?_71[_74]:_76; -var _77=m[3]?parseInt(m[3]):(m[4]=="."?-1:0); -_70.push(_6f.substr(0,m[0][0]=="%"?m.index:m.index+1)); -_70.push({appender:_75,precision:_77}); -_6f=_6f.substr(m.index+m[0].length); -} -_70.push(_6f); -return _70; -}; -function _78(_79){ -function _7a(ch){ -switch(ch){ -case "<": -return "<"; -case ">": -return ">"; -case "&": -return "&"; -case "'": -return "'"; -case "\"": -return """; -} -return "?"; -}; -return String(_79).replace(/[<>&"']/g,_7a); -}; -function _7b(_7c){ -try{ -return _7c+""; -} -catch(e){ -return null; -} -}; -function _6e(_7d,_7e){ -_7e.push(_7b(_7d)); -}; -function _6a(_7f,_80){ -_80.push(_78(_7b(_7f))); -}; -function _6c(_81,_82){ -_82.push("",_78(_7b(_81)),""); -}; -function _83(_84,_85){ -_85.push(""",_78(_7b(_84)),"""); -}; -function _72(_86,_87){ -_87.push("",_78(_7b(_86)),""); -}; -function _73(_88,_89){ -_89.push("",_78(_7b(_88)),""); -}; -function _8a(_8b,_8c){ -_8c.push("",_6d(_8b),""); -}; -function _76(_8d,_8e){ -try{ -if(_8d===undefined){ -_6c("undefined",_8e); -}else{ -if(_8d===null){ -_6c("null",_8e); -}else{ -if(typeof _8d=="string"){ -_83(_8d,_8e); -}else{ -if(typeof _8d=="number"){ -_72(_8d,_8e); -}else{ -if(typeof _8d=="function"){ -_8a(_8d,_8e); -}else{ -if(_8d.nodeType==1){ -_8f(_8d,_8e); -}else{ -if(typeof _8d=="object"){ -_90(_8d,_8e); -}else{ -_6a(_8d,_8e); -} -} -} -} -} -} -} -} -catch(e){ -} -}; -function _90(_91,_92){ -var _93=_7b(_91); -var _94=/\[object (.*?)\]/; -var m=_94.exec(_93); -_92.push("",m?m[1]:_93,""); -}; -function _8f(_95,_96){ -_96.push(""); -_96.push("",_78(_95.nodeName.toLowerCase()),""); -if(_95.id){ -_96.push("#",_78(_95.id),""); -} -if(_95.className){ -_96.push(".",_78(_95.className),""); -} -_96.push(""); -}; -function _26(_97,_98){ -if(_97.nodeType==1){ -_98.push("
    ","<",_97.nodeName.toLowerCase(),""); -for(var i=0;i<_97.attributes.length;++i){ -var _99=_97.attributes[i]; -if(!_99.specified){ -continue; -} -_98.push(" ",_99.nodeName.toLowerCase(),"="",_78(_99.nodeValue),"""); -} -if(_97.firstChild){ -_98.push(">
    "); -for(var _9a=_97.firstChild;_9a;_9a=_9a.nextSibling){ -_26(_9a,_98); -} -_98.push("
    </",_97.nodeName.toLowerCase(),">
    "); -}else{ -_98.push("/>
    "); -} -}else{ -if(_97.nodeType==3){ -_98.push("
    ",_78(_97.nodeValue),"
    "); -} -} -}; -function _46(_9b,_9c,_9d){ -if(document.all){ -_9b.attachEvent("on"+_9c,_9d); -}else{ -_9b.addEventListener(_9c,_9d,false); -} -}; -function _9e(_9f,_a0,_a1){ -if(document.all){ -_9f.detachEvent("on"+_a0,_a1); -}else{ -_9f.removeEventListener(_a0,_a1,false); -} -}; -function _a2(_a3){ -if(document.all){ -_a3.cancelBubble=true; -}else{ -_a3.stopPropagation(); -} -}; -function _a4(msg,_a5,_a6){ -var _a7=_a5.lastIndexOf("/"); -var _a8=_a7==-1?_a5:_a5.substr(_a7+1); -var _a9=["",msg,"","
    ",_a8," (line ",_a6,")
    "]; -_23(_a9,"error"); -}; -var _aa=new Date().getTime(); -function _48(_ab){ -var _ac=(new Date()).getTime(); -if(_ac>_aa+200){ -_ab=_1.fixEvent(_ab); -var _ad=_1.keys; -var ekc=_ab.keyCode; -_aa=_ac; -if(ekc==_ad.F12){ -_31(); -}else{ -if((ekc==_ad.NUMPAD_ENTER||ekc==76)&&_ab.shiftKey&&(_ab.metaKey||_ab.ctrlKey)){ -_36(); -}else{ -return; -} -} -_a2(_ab); -} -}; -function _47(e){ -var dk=_1.keys; -if(e.keyCode==13&&_f.value){ -_ae(_f.value); -_4c(); -}else{ -if(e.keyCode==27){ -_f.value=""; -}else{ -if(e.keyCode==dk.UP_ARROW||e.charCode==dk.UP_ARROW){ -_af("older"); -}else{ -if(e.keyCode==dk.DOWN_ARROW||e.charCode==dk.DOWN_ARROW){ -_af("newer"); -}else{ -if(e.keyCode==dk.HOME||e.charCode==dk.HOME){ -_b0=1; -_af("older"); -}else{ -if(e.keyCode==dk.END||e.charCode==dk.END){ -_b0=999999; -_af("newer"); -} -} -} -} -} -} -}; -var _b0=-1; -var _b1=null; -function _ae(_b2){ -var _b3=_b4("firebug_history"); -_b3=(_b3)?_1.fromJson(_b3):[]; -var pos=_1.indexOf(_b3,_b2); -if(pos!=-1){ -_b3.splice(pos,1); -} -_b3.push(_b2); -_b4("firebug_history",_1.toJson(_b3),30); -while(_b3.length&&!_b4("firebug_history")){ -_b3.shift(); -_b4("firebug_history",_1.toJson(_b3),30); -} -_b1=null; -_b0=-1; -}; -function _af(_b5){ -var _b6=_b4("firebug_history"); -_b6=(_b6)?_1.fromJson(_b6):[]; -if(!_b6.length){ -return; -} -if(_b1===null){ -_b1=_f.value; -} -if(_b0==-1){ -_b0=_b6.length; -} -if(_b5=="older"){ ---_b0; -if(_b0<0){ -_b0=0; -} -}else{ -if(_b5=="newer"){ -++_b0; -if(_b0>_b6.length){ -_b0=_b6.length; -} -} -} -if(_b0==_b6.length){ -_f.value=_b1; -_b1=null; -}else{ -_f.value=_b6[_b0]; -} -}; -function _b4(_b7,_b8){ -var c=document.cookie; -if(arguments.length==1){ -var _b9=c.match(new RegExp("(?:^|; )"+_b7+"=([^;]*)")); -return _b9?decodeURIComponent(_b9[1]):undefined; -}else{ -var d=new Date(); -d.setMonth(d.getMonth()+1); -document.cookie=_b7+"="+encodeURIComponent(_b8)+((d.toUtcString)?"; expires="+d.toUTCString():""); -} -}; -function _ba(it){ -return it&&it instanceof Array||typeof it=="array"; -}; -function _bb(o){ -var cnt=0; -for(var nm in o){ -cnt++; -} -return cnt; -}; -function _22(o,i,txt,_bc){ -var ind=" \t"; -txt=txt||""; -i=i||ind; -_bc=_bc||[]; -var _bd; -if(o&&o.nodeType==1){ -var _be=[]; -_26(o,_be); -return _be.join(""); -} -var br=",\n",cnt=0,_bf=_bb(o); -if(o instanceof Date){ -return i+o.toString()+br; -} -looking: -for(var nm in o){ -cnt++; -if(cnt==_bf){ -br="\n"; -} -if(o[nm]===window||o[nm]===document){ -}else{ -if(o[nm]===null){ -txt+=i+nm+" : NULL"+br; -}else{ -if(o[nm]&&o[nm].nodeType){ -if(o[nm].nodeType==1){ -}else{ -if(o[nm].nodeType==3){ -txt+=i+nm+" : [ TextNode "+o[nm].data+" ]"+br; -} -} -}else{ -if(typeof o[nm]=="object"&&(o[nm] instanceof String||o[nm] instanceof Number||o[nm] instanceof Boolean)){ -txt+=i+nm+" : "+o[nm]+","+br; -}else{ -if(o[nm] instanceof Date){ -txt+=i+nm+" : "+o[nm].toString()+br; -}else{ -if(typeof (o[nm])=="object"&&o[nm]){ -for(var j=0,_c0;_c0=_bc[j];j++){ -if(o[nm]===_c0){ -txt+=i+nm+" : RECURSION"+br; -continue looking; -} -} -_bc.push(o[nm]); -_bd=(_ba(o[nm]))?["[","]"]:["{","}"]; -txt+=i+nm+" : "+_bd[0]+"\n"; -txt+=_22(o[nm],i+ind,"",_bc); -txt+=i+_bd[1]+br; -}else{ -if(typeof o[nm]=="undefined"){ -txt+=i+nm+" : undefined"+br; -}else{ -if(nm=="toString"&&typeof o[nm]=="function"){ -var _c1=o[nm](); -if(typeof _c1=="string"&&_c1.match(/function ?(.*?)\(/)){ -_c1=_78(_6d(o[nm])); -} -txt+=i+nm+" : "+_c1+br; -}else{ -txt+=i+nm+" : "+_78(_6d(o[nm]))+br; -} -} -} -} -} -} -} -} -} -return txt; -}; -function _6d(obj){ -var _c2=(obj instanceof Error); -if(obj.nodeType==1){ -return _78("< "+obj.tagName.toLowerCase()+" id=\""+obj.id+"\" />"); -} -if(obj.nodeType==3){ -return _78("[TextNode: \""+obj.nodeValue+"\"]"); -} -var nm=(obj&&(obj.id||obj.name||obj.ObjectID||obj.widgetId)); -if(!_c2&&nm){ -return "{"+nm+"}"; -} -var _c3=2; -var _c4=4; -var cnt=0; -if(_c2){ -nm="[ Error: "+(obj.message||obj.description||obj)+" ]"; -}else{ -if(_ba(obj)){ -nm="["+obj.slice(0,_c4).join(","); -if(obj.length>_c4){ -nm+=" ... ("+obj.length+" items)"; -} -nm+="]"; -}else{ -if(typeof obj=="function"){ -nm=obj+""; -var reg=/function\s*([^\(]*)(\([^\)]*\))[^\{]*\{/; -var m=reg.exec(nm); -if(m){ -if(!m[1]){ -m[1]="function"; -} -nm=m[1]+m[2]; -}else{ -nm="function()"; -} -}else{ -if(typeof obj!="object"||typeof obj=="string"){ -nm=obj+""; -}else{ -nm="{"; -for(var i in obj){ -cnt++; -if(cnt>_c3){ -break; -} -nm+=i+":"+_78(obj[i])+" "; -} -nm+="}"; -} -} -} -} -return nm; -}; -_46(document,_4("ie")||_4("safari")?"keydown":"keypress",_48); -if((document.documentElement.getAttribute("debug")=="true")||(_1.config.isDebug)){ -_31(true); -} -_1.addOnWindowUnload(function(){ -_9e(document,_4("ie")||_4("safari")?"keydown":"keypress",_48); -window.onFirebugResize=null; -window.console=null; -}); -}); diff --git a/lib/dojo/_firebug/firebug.js.uncompressed.js b/lib/dojo/_firebug/firebug.js.uncompressed.js deleted file mode 100644 index 872c165..0000000 --- a/lib/dojo/_firebug/firebug.js.uncompressed.js +++ /dev/null @@ -1,1191 +0,0 @@ -define("dojo/_firebug/firebug", [ - "../_base/kernel", - "require", - "../_base/html", - "../sniff", - "../_base/array", - "../_base/lang", - "../_base/event", - "../_base/unload"], function(dojo, require, html, has){ - - // module: - // dojo/_firebug/firebug - // summary: - // Firebug Lite, the baby brother to Joe Hewitt's Firebug for Mozilla Firefox - // description: - // Opens a console for logging, debugging, and error messages. - // Contains partial functionality to Firebug. See function list below. - // - // NOTE: - // Firebug is a Firefox extension created by Joe Hewitt (see license). You do not need Dojo to run Firebug. - // Firebug Lite is included in Dojo by permission from Joe Hewitt - // If you are new to Firebug, or used to the Dojo 0.4 dojo.debug, you can learn Firebug - // functionality by reading the function comments below or visiting http://www.getfirebug.com/docs.html - // - // NOTE: - // To test Firebug Lite in Firefox: - // - // - FF2: set "console = null" before loading dojo and set djConfig.isDebug=true - // - FF3: disable Firebug and set djConfig.isDebug=true - // - // example: - // Supports inline objects in object inspector window (only simple trace of dom nodes, however) - // | console.log("my object", {foo:"bar"}) - // example: - // Option for console to open in popup window - // | var djConfig = {isDebug: true, popup:true }; - // example: - // Option for console height (ignored for popup) - // | var djConfig = {isDebug: true, debugHeight:100 } - - - var isNewIE = (/Trident/.test(window.navigator.userAgent)); - if(isNewIE){ - // Fixing IE's console - // IE doesn't insert space between arguments. How annoying. - var calls = ["log", "info", "debug", "warn", "error"]; - for(var i=0;i"); - str = str.replace(/\t/g, "    "); - logRow([str], "dir"); - }, - - dirxml: function(node){ - var html = []; - appendNode(node, html); - logRow(html, "dirxml"); - }, - - group: function(){ - // summary: - // collects log messages into a group, starting with this call and ending with - // groupEnd(). Missing collapse functionality - logRow(arguments, "group", pushGroup); - }, - - groupEnd: function(){ - // summary: - // Closes group. See above - logRow(arguments, "", popGroup); - }, - - time: function(name){ - // summary: - // Starts timers assigned to name given in argument. Timer stops and displays on timeEnd(title); - // example: - // | console.time("load"); - // | console.time("myFunction"); - // | console.timeEnd("load"); - // | console.timeEnd("myFunction"); - timeMap[name] = new Date().getTime(); - }, - - timeEnd: function(name){ - // summary: - // See above. - if(name in timeMap){ - var delta = (new Date()).getTime() - timeMap[name]; - logFormatted([name+ ":", delta+"ms"]); - delete timeMap[name]; - } - }, - - count: function(name){ - // summary: - // Not supported - if(!countMap[name]) countMap[name] = 0; - countMap[name]++; - logFormatted([name+": "+countMap[name]]); - }, - - trace: function(_value){ - var stackAmt = _value || 3; - var f = console.trace.caller; //function that called trace - console.log(">>> console.trace(stack)"); - for(var i=0;i=0&&s.href){ - var h=s.href.replace(/(&|%5C?)forceReload=\d+/,''); - s.href=h+(h.indexOf('?')>=0?'&':'?')+'forceReload='+new Date().valueOf(); - } - } - } - }; - - // *************************************************************************** - - function toggleConsole(forceOpen){ - frameVisible = forceOpen || !frameVisible; - if(consoleFrame){ - consoleFrame.style.display = frameVisible ? "block" : "none"; - } - } - - function focusCommandLine(){ - toggleConsole(true); - if(commandLine){ - commandLine.focus(); - } - } - - function openWin(x,y,w,h){ - var win = window.open("","_firebug","status=0,menubar=0,resizable=1,top="+y+",left="+x+",width="+w+",height="+h+",scrollbars=1,addressbar=0"); - if(!win){ - var msg = "Firebug Lite could not open a pop-up window, most likely because of a blocker.\n" + - "Either enable pop-ups for this domain, or change the djConfig to popup=false."; - alert(msg); - } - createResizeHandler(win); - var newDoc=win.document; - //Safari needs an HTML height - var HTMLstring= 'Firebug Lite\n' + - '\n' + - '
    ' + - ''; - - newDoc.write(HTMLstring); - newDoc.close(); - return win; - } - - function createResizeHandler(wn){ - // summary: - // Creates handle for onresize window. Called from script in popup's body tag (so that it will work with IE). - // - - var d = new Date(); - d.setTime(d.getTime()+(60*24*60*60*1000)); // 60 days - d = d.toUTCString(); - - var dc = wn.document, - getViewport; - - if (wn.innerWidth){ - getViewport = function(){ - return{w:wn.innerWidth, h:wn.innerHeight}; - }; - }else if (dc.documentElement && dc.documentElement.clientWidth){ - getViewport = function(){ - return{w:dc.documentElement.clientWidth, h:dc.documentElement.clientHeight}; - }; - }else if (dc.body){ - getViewport = function(){ - return{w:dc.body.clientWidth, h:dc.body.clientHeight}; - }; - } - - - window.onFirebugResize = function(){ - - //resize the height of the console log body - layout(getViewport().h); - - clearInterval(wn._firebugWin_resize); - wn._firebugWin_resize = setTimeout(function(){ - var x = wn.screenLeft, - y = wn.screenTop, - w = wn.outerWidth || wn.document.body.offsetWidth, - h = wn.outerHeight || wn.document.body.offsetHeight; - - document.cookie = "_firebugPosition=" + [x,y,w,h].join(",") + "; expires="+d+"; path=/"; - - }, 5000); //can't capture window.onMove - long timeout gives better chance of capturing a resize, then the move - - }; - } - - - /*****************************************************************************/ - - - function createFrame(){ - if(consoleFrame){ - return; - } - toggleConsole(true); - if(dojo.config.popup){ - var containerHeight = "100%"; - var cookieMatch = document.cookie.match(/(?:^|; )_firebugPosition=([^;]*)/); - var p = cookieMatch ? cookieMatch[1].split(",") : [2,2,320,480]; - - _firebugWin = openWin(p[0],p[1],p[2],p[3]); // global - _firebugDoc = _firebugWin.document; // global - - dojo.config.debugContainerId = 'fb'; - - // connecting popup - _firebugWin.console = window.console; - _firebugWin.dojo = window.dojo; - }else{ - _firebugDoc = document; - containerHeight = (dojo.config.debugHeight || 300) + "px"; - } - - var styleElement = _firebugDoc.createElement("link"); - styleElement.href = require.toUrl("./firebug.css"); - styleElement.rel = "stylesheet"; - styleElement.type = "text/css"; - var styleParent = _firebugDoc.getElementsByTagName("head"); - if(styleParent){ - styleParent = styleParent[0]; - } - if(!styleParent){ - styleParent = _firebugDoc.getElementsByTagName("html")[0]; - } - if(has("ie")){ - window.setTimeout(function(){ styleParent.appendChild(styleElement); }, 0); - }else{ - styleParent.appendChild(styleElement); - } - - if(dojo.config.debugContainerId){ - consoleFrame = _firebugDoc.getElementById(dojo.config.debugContainerId); - } - if(!consoleFrame){ - consoleFrame = _firebugDoc.createElement("div"); - _firebugDoc.body.appendChild(consoleFrame); - } - consoleFrame.className += " firebug"; - consoleFrame.id = "firebug"; - consoleFrame.style.height = containerHeight; - consoleFrame.style.display = (frameVisible ? "block" : "none"); - - var buildLink = function(label, title, method, _class){ - return '
  • '+label+'
  • '; - }; - consoleFrame.innerHTML = - '
    ' - + '
      ' - - + buildLink("Clear", "Remove All Console Logs", "clear", "") - + buildLink("ReCSS", "Refresh CSS without reloading page", "recss", "") - - + buildLink("Console", "Show Console Logs", "openConsole", "gap") - + buildLink("DOM", "Show DOM Inspector", "openDomInspector", "") - + buildLink("Object", "Show Object Inspector", "openObjectInspector", "") - + ((dojo.config.popup) ? "" : buildLink("Close", "Close the console", "close", "gap")) - - + '
    ' - + '
    ' - + '' - + '
    ' - + '' - + ''; - - - consoleToolbar = _firebugDoc.getElementById("firebugToolbar"); - - commandLine = _firebugDoc.getElementById("firebugCommandLine"); - addEvent(commandLine, "keydown", onCommandLineKeyDown); - - addEvent(_firebugDoc, has("ie") || has("safari") ? "keydown" : "keypress", onKeyDown); - - consoleBody = _firebugDoc.getElementById("firebugLog"); - consoleObjectInspector = _firebugDoc.getElementById("objectLog"); - consoleDomInspector = _firebugDoc.getElementById("domInspect"); - fireBugTabs = _firebugDoc.getElementById("fireBugTabs"); - layout(); - flush(); - } - - dojo.addOnLoad(createFrame); - - function clearFrame(){ - _firebugDoc = null; - - if(_firebugWin.console){ - _firebugWin.console.clear(); - } - _firebugWin = null; - consoleFrame = null; - consoleBody = null; - consoleObjectInspector = null; - consoleDomInspector = null; - commandLine = null; - messageQueue = []; - groupStack = []; - timeMap = {}; - } - - - function evalCommandLine(){ - var text = commandLine.value; - commandLine.value = ""; - - logRow(["> ", text], "command"); - - var value; - try{ - value = eval(text); - }catch(e){ - console.debug(e); // put exception on the console - } - - console.log(value); - } - - function layout(h){ - var tHeight = 25; //consoleToolbar.offsetHeight; // tab style not ready on load - throws off layout - var height = h ? - h - (tHeight + commandLine.offsetHeight +25 + (h*.01)) + "px" : - (consoleFrame.offsetHeight - tHeight - commandLine.offsetHeight) + "px"; - - consoleBody.style.top = tHeight + "px"; - consoleBody.style.height = height; - consoleObjectInspector.style.height = height; - consoleObjectInspector.style.top = tHeight + "px"; - consoleDomInspector.style.height = height; - consoleDomInspector.style.top = tHeight + "px"; - commandLine.style.bottom = 0; - - dojo.addOnWindowUnload(clearFrame); - } - - function logRow(message, className, handler){ - if(consoleBody){ - writeMessage(message, className, handler); - }else{ - messageQueue.push([message, className, handler]); - } - } - - function flush(){ - var queue = messageQueue; - messageQueue = []; - - for(var i = 0; i < queue.length; ++i){ - writeMessage(queue[i][0], queue[i][1], queue[i][2]); - } - } - - function writeMessage(message, className, handler){ - var isScrolledToBottom = - consoleBody.scrollTop + consoleBody.offsetHeight >= consoleBody.scrollHeight; - - handler = handler||writeRow; - - handler(message, className); - - if(isScrolledToBottom){ - consoleBody.scrollTop = consoleBody.scrollHeight - consoleBody.offsetHeight; - } - } - - function appendRow(row){ - var container = groupStack.length ? groupStack[groupStack.length-1] : consoleBody; - container.appendChild(row); - } - - function writeRow(message, className){ - var row = consoleBody.ownerDocument.createElement("div"); - row.className = "logRow" + (className ? " logRow-"+className : ""); - row.innerHTML = message.join(""); - appendRow(row); - } - - function pushGroup(message, className){ - logFormatted(message, className); - - //var groupRow = consoleBody.ownerDocument.createElement("div"); - //groupRow.className = "logGroup"; - var groupRowBox = consoleBody.ownerDocument.createElement("div"); - groupRowBox.className = "logGroupBox"; - //groupRow.appendChild(groupRowBox); - appendRow(groupRowBox); - groupStack.push(groupRowBox); - } - - function popGroup(){ - groupStack.pop(); - } - - // *************************************************************************** - - function logFormatted(objects, className){ - var html = []; - - var format = objects[0]; - var objIndex = 0; - - if(typeof(format) != "string"){ - format = ""; - objIndex = -1; - } - - var parts = parseFormat(format); - - for(var i = 0; i < parts.length; ++i){ - var part = parts[i]; - if(part && typeof part == "object"){ - part.appender(objects[++objIndex], html); - }else{ - appendText(part, html); - } - } - - - var ids = []; - var obs = []; - for(i = objIndex+1; i < objects.length; ++i){ - appendText(" ", html); - - var object = objects[i]; - if(object === undefined || object === null ){ - appendNull(object, html); - - }else if(typeof(object) == "string"){ - appendText(object, html); - - }else if(object instanceof Date){ - appendText(object.toString(), html); - - }else if(object.nodeType == 9){ - appendText("[ XmlDoc ]", html); - - }else{ - // Create link for object inspector - // need to create an ID for this link, since it is currently text - var id = "_a" + __consoleAnchorId__++; - ids.push(id); - // need to save the object, so the arrays line up - obs.push(object); - var str = ''+getObjectAbbr(object)+''; - - appendLink( str , html); - } - } - - logRow(html, className); - - // Now that the row is inserted in the DOM, loop through all of the links that were just created - for(i=0; i"; - })); - } - } - - function parseFormat(format){ - var parts = []; - - var reg = /((^%|[^\\]%)(\d+)?(\.)([a-zA-Z]))|((^%|[^\\]%)([a-zA-Z]))/; - var appenderMap = {s: appendText, d: appendInteger, i: appendInteger, f: appendFloat}; - - for(var m = reg.exec(format); m; m = reg.exec(format)){ - var type = m[8] ? m[8] : m[5]; - var appender = type in appenderMap ? appenderMap[type] : appendObject; - var precision = m[3] ? parseInt(m[3]) : (m[4] == "." ? -1 : 0); - - parts.push(format.substr(0, m[0][0] == "%" ? m.index : m.index+1)); - parts.push({appender: appender, precision: precision}); - - format = format.substr(m.index+m[0].length); - } - - parts.push(format); - - return parts; - } - - function escapeHTML(value){ - function replaceChars(ch){ - switch(ch){ - case "<": - return "<"; - case ">": - return ">"; - case "&": - return "&"; - case "'": - return "'"; - case '"': - return """; - } - return "?"; - } - return String(value).replace(/[<>&"']/g, replaceChars); - } - - function objectToString(object){ - try{ - return object+""; - }catch(e){ - return null; - } - } - - // *************************************************************************** - function appendLink(object, html){ - // needed for object links - no HTML escaping - html.push( objectToString(object) ); - } - - function appendText(object, html){ - html.push(escapeHTML(objectToString(object))); - } - - function appendNull(object, html){ - html.push('', escapeHTML(objectToString(object)), ''); - } - - function appendString(object, html){ - html.push('"', escapeHTML(objectToString(object)), - '"'); - } - - function appendInteger(object, html){ - html.push('', escapeHTML(objectToString(object)), ''); - } - - function appendFloat(object, html){ - html.push('', escapeHTML(objectToString(object)), ''); - } - - function appendFunction(object, html){ - html.push('', getObjectAbbr(object), ''); - } - - function appendObject(object, html){ - try{ - if(object === undefined){ - appendNull("undefined", html); - }else if(object === null){ - appendNull("null", html); - }else if(typeof object == "string"){ - appendString(object, html); - }else if(typeof object == "number"){ - appendInteger(object, html); - }else if(typeof object == "function"){ - appendFunction(object, html); - }else if(object.nodeType == 1){ - appendSelector(object, html); - }else if(typeof object == "object"){ - appendObjectFormatted(object, html); - }else{ - appendText(object, html); - } - }catch(e){ - /* squelch */ - } - } - - function appendObjectFormatted(object, html){ - var text = objectToString(object); - var reObject = /\[object (.*?)\]/; - - var m = reObject.exec(text); - html.push('', m ? m[1] : text, ''); - } - - function appendSelector(object, html){ - html.push(''); - - html.push('', escapeHTML(object.nodeName.toLowerCase()), ''); - if(object.id){ - html.push('#', escapeHTML(object.id), ''); - } - if(object.className){ - html.push('.', escapeHTML(object.className), ''); - } - - html.push(''); - } - - function appendNode(node, html){ - if(node.nodeType == 1){ - html.push( - '
    ', - '<', node.nodeName.toLowerCase(), ''); - - for(var i = 0; i < node.attributes.length; ++i){ - var attr = node.attributes[i]; - if(!attr.specified){ continue; } - - html.push(' ', attr.nodeName.toLowerCase(), - '="', escapeHTML(attr.nodeValue), - '"'); - } - - if(node.firstChild){ - html.push('>
    '); - - for(var child = node.firstChild; child; child = child.nextSibling){ - appendNode(child, html); - } - - html.push('
    </', - node.nodeName.toLowerCase(), '>
    '); - }else{ - html.push('/>
    '); - } - }else if (node.nodeType == 3){ - html.push('
    ', escapeHTML(node.nodeValue), - '
    '); - } - } - - // *************************************************************************** - - function addEvent(object, name, handler){ - if(document.all){ - object.attachEvent("on"+name, handler); - }else{ - object.addEventListener(name, handler, false); - } - } - - function removeEvent(object, name, handler){ - if(document.all){ - object.detachEvent("on"+name, handler); - }else{ - object.removeEventListener(name, handler, false); - } - } - - function cancelEvent(event){ - if(document.all){ - event.cancelBubble = true; - }else{ - event.stopPropagation(); - } - } - - function onError(msg, href, lineNo){ - var lastSlash = href.lastIndexOf("/"); - var fileName = lastSlash == -1 ? href : href.substr(lastSlash+1); - - var html = [ - '', msg, '', - '' - ]; - - logRow(html, "error"); - } - - - //After converting to div instead of iframe, now getting two keydowns right away in IE 6. - //Make sure there is a little bit of delay. - var onKeyDownTime = new Date().getTime(); - - function onKeyDown(event){ - var timestamp = (new Date()).getTime(); - if(timestamp > onKeyDownTime + 200){ - event = dojo.fixEvent(event); - var keys = dojo.keys; - var ekc = event.keyCode; - onKeyDownTime = timestamp; - if(ekc == keys.F12){ - toggleConsole(); - }else if( - (ekc == keys.NUMPAD_ENTER || ekc == 76) && - event.shiftKey && - (event.metaKey || event.ctrlKey) - ){ - focusCommandLine(); - }else{ - return; - } - cancelEvent(event); - } - } - - function onCommandLineKeyDown(e){ - var dk = dojo.keys; - if(e.keyCode == 13 && commandLine.value){ - addToHistory(commandLine.value); - evalCommandLine(); - }else if(e.keyCode == 27){ - commandLine.value = ""; - }else if(e.keyCode == dk.UP_ARROW || e.charCode == dk.UP_ARROW){ - navigateHistory("older"); - }else if(e.keyCode == dk.DOWN_ARROW || e.charCode == dk.DOWN_ARROW){ - navigateHistory("newer"); - }else if(e.keyCode == dk.HOME || e.charCode == dk.HOME){ - historyPosition = 1; - navigateHistory("older"); - }else if(e.keyCode == dk.END || e.charCode == dk.END){ - historyPosition = 999999; - navigateHistory("newer"); - } - } - - var historyPosition = -1; - var historyCommandLine = null; - - function addToHistory(value){ - var history = cookie("firebug_history"); - history = (history) ? dojo.fromJson(history) : []; - var pos = dojo.indexOf(history, value); - if (pos != -1){ - history.splice(pos, 1); - } - history.push(value); - cookie("firebug_history", dojo.toJson(history), 30); - while(history.length && !cookie("firebug_history")){ - history.shift(); - cookie("firebug_history", dojo.toJson(history), 30); - } - historyCommandLine = null; - historyPosition = -1; - } - - function navigateHistory(direction){ - var history = cookie("firebug_history"); - history = (history) ? dojo.fromJson(history) : []; - if(!history.length){ - return; - } - - if(historyCommandLine === null){ - historyCommandLine = commandLine.value; - } - - if(historyPosition == -1){ - historyPosition = history.length; - } - - if(direction == "older"){ - --historyPosition; - if(historyPosition < 0){ - historyPosition = 0; - } - }else if(direction == "newer"){ - ++historyPosition; - if(historyPosition > history.length){ - historyPosition = history.length; - } - } - - if(historyPosition == history.length){ - commandLine.value = historyCommandLine; - historyCommandLine = null; - }else{ - commandLine.value = history[historyPosition]; - } - } - - function cookie(name, value){ - var c = document.cookie; - if(arguments.length == 1){ - var matches = c.match(new RegExp("(?:^|; )" + name + "=([^;]*)")); - return matches ? decodeURIComponent(matches[1]) : undefined; // String or undefined - }else{ - var d = new Date(); - d.setMonth(d.getMonth()+1); - document.cookie = name + "=" + encodeURIComponent(value) + ((d.toUtcString) ? "; expires=" + d.toUTCString() : ""); - } - } - - function isArray(it){ - return it && it instanceof Array || typeof it == "array"; - } - - //*************************************************************************************************** - // Print Object Helpers - function objectLength(o){ - var cnt = 0; - for(var nm in o){ - cnt++; - } - return cnt; - } - - function printObject(o, i, txt, used){ - // Recursively trace object, indenting to represent depth for display in object inspector - var ind = " \t"; - txt = txt || ""; - i = i || ind; - used = used || []; - var opnCls; - - if(o && o.nodeType == 1){ - var html = []; - appendNode(o, html); - return html.join(""); - } - - var br=",\n", cnt = 0, length = objectLength(o); - - if(o instanceof Date){ - return i + o.toString() + br; - } - looking: - for(var nm in o){ - cnt++; - if(cnt==length){br = "\n";} - if(o[nm] === window || o[nm] === document){ - // do nothing - }else if(o[nm] === null){ - txt += i+nm + " : NULL" + br; - }else if(o[nm] && o[nm].nodeType){ - if(o[nm].nodeType == 1){ - //txt += i+nm + " : < "+o[nm].tagName+" id=\""+ o[nm].id+"\" />" + br; - }else if(o[nm].nodeType == 3){ - txt += i+nm + " : [ TextNode "+o[nm].data + " ]" + br; - } - - }else if(typeof o[nm] == "object" && (o[nm] instanceof String || o[nm] instanceof Number || o[nm] instanceof Boolean)){ - txt += i+nm + " : " + o[nm] + "," + br; - - }else if(o[nm] instanceof Date){ - txt += i+nm + " : " + o[nm].toString() + br; - - }else if(typeof(o[nm]) == "object" && o[nm]){ - for(var j = 0, seen; seen = used[j]; j++){ - if(o[nm] === seen){ - txt += i+nm + " : RECURSION" + br; - continue looking; - } - } - used.push(o[nm]); - - opnCls = (isArray(o[nm]))?["[","]"]:["{","}"]; - txt += i+nm +" : " + opnCls[0] + "\n";//non-standard break, (no comma) - txt += printObject(o[nm], i+ind, "", used); - txt += i + opnCls[1] + br; - - }else if(typeof o[nm] == "undefined"){ - txt += i+nm + " : undefined" + br; - }else if(nm == "toString" && typeof o[nm] == "function"){ - var toString = o[nm](); - if(typeof toString == "string" && toString.match(/function ?(.*?)\(/)){ - toString = escapeHTML(getObjectAbbr(o[nm])); - } - txt += i+nm +" : " + toString + br; - }else{ - txt += i+nm +" : "+ escapeHTML(getObjectAbbr(o[nm])) + br; - } - } - return txt; - } - - function getObjectAbbr(obj){ - // Gets an abbreviation of an object for display in log - // X items in object, including id - // X items in an array - // TODO: Firebug Sr. actually goes by char count - var isError = (obj instanceof Error); - if(obj.nodeType == 1){ - return escapeHTML('< '+obj.tagName.toLowerCase()+' id=\"'+ obj.id+ '\" />'); - } - if(obj.nodeType == 3){ - return escapeHTML('[TextNode: "'+obj.nodeValue+'"]'); - } - var nm = (obj && (obj.id || obj.name || obj.ObjectID || obj.widgetId)); - if(!isError && nm){ return "{"+nm+"}"; } - - var obCnt = 2; - var arCnt = 4; - var cnt = 0; - - if(isError){ - nm = "[ Error: "+(obj.message || obj.description || obj)+" ]"; - }else if(isArray(obj)){ - nm = "[" + obj.slice(0,arCnt).join(","); - if(obj.length > arCnt){ - nm += " ... ("+obj.length+" items)"; - } - nm += "]"; - }else if(typeof obj == "function"){ - nm = obj + ""; - var reg = /function\s*([^\(]*)(\([^\)]*\))[^\{]*\{/; - var m = reg.exec(nm); - if(m){ - if(!m[1]){ - m[1] = "function"; - } - nm = m[1] + m[2]; - }else{ - nm = "function()"; - } - }else if(typeof obj != "object" || typeof obj == "string"){ - nm = obj + ""; - }else{ - nm = "{"; - for(var i in obj){ - cnt++; - if(cnt > obCnt){ break; } - nm += i+":"+escapeHTML(obj[i])+" "; - } - nm+="}"; - } - - return nm; - } - - //************************************************************************************* - - //window.onerror = onError; - - addEvent(document, has("ie") || has("safari") ? "keydown" : "keypress", onKeyDown); - - if( (document.documentElement.getAttribute("debug") == "true")|| - (dojo.config.isDebug) - ){ - toggleConsole(true); - } - - dojo.addOnWindowUnload(function(){ - // Erase the globals and event handlers I created, to prevent spurious leak warnings - removeEvent(document, has("ie") || has("safari") ? "keydown" : "keypress", onKeyDown); - window.onFirebugResize = null; - window.console = null; - }); - -}); diff --git a/lib/dojo/_firebug/infoIcon.png b/lib/dojo/_firebug/infoIcon.png deleted file mode 100644 index da1e533..0000000 Binary files a/lib/dojo/_firebug/infoIcon.png and /dev/null differ diff --git a/lib/dojo/_firebug/tab_lft_norm.png b/lib/dojo/_firebug/tab_lft_norm.png deleted file mode 100644 index f0479a2..0000000 Binary files a/lib/dojo/_firebug/tab_lft_norm.png and /dev/null differ diff --git a/lib/dojo/_firebug/tab_lft_over.png b/lib/dojo/_firebug/tab_lft_over.png deleted file mode 100644 index 2f36cca..0000000 Binary files a/lib/dojo/_firebug/tab_lft_over.png and /dev/null differ diff --git a/lib/dojo/_firebug/tab_rgt_norm.png b/lib/dojo/_firebug/tab_rgt_norm.png deleted file mode 100644 index 464af3e..0000000 Binary files a/lib/dojo/_firebug/tab_rgt_norm.png and /dev/null differ diff --git a/lib/dojo/_firebug/tab_rgt_over.png b/lib/dojo/_firebug/tab_rgt_over.png deleted file mode 100644 index 2bc2cd0..0000000 Binary files a/lib/dojo/_firebug/tab_rgt_over.png and /dev/null differ diff --git a/lib/dojo/_firebug/warningIcon.png b/lib/dojo/_firebug/warningIcon.png deleted file mode 100644 index de51084..0000000 Binary files a/lib/dojo/_firebug/warningIcon.png and /dev/null differ diff --git a/lib/dojo/aspect.js b/lib/dojo/aspect.js deleted file mode 100644 index 031cb85..0000000 --- a/lib/dojo/aspect.js +++ /dev/null @@ -1,108 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/aspect",[],function(){ -"use strict"; -var _1,_2=0; -function _3(_4,_5,_6,_7){ -var _8=_4[_5]; -var _9=_5=="around"; -var _a; -if(_9){ -var _b=_6(function(){ -return _8.advice(this,arguments); -}); -_a={remove:function(){ -if(_b){ -_b=_4=_6=null; -} -},advice:function(_c,_d){ -return _b?_b.apply(_c,_d):_8.advice(_c,_d); -}}; -}else{ -_a={remove:function(){ -if(_a.advice){ -var _e=_a.previous; -var _f=_a.next; -if(!_f&&!_e){ -delete _4[_5]; -}else{ -if(_e){ -_e.next=_f; -}else{ -_4[_5]=_f; -} -if(_f){ -_f.previous=_e; -} -} -_4=_6=_a.advice=null; -} -},id:_2++,advice:_6,receiveArguments:_7}; -} -if(_8&&!_9){ -if(_5=="after"){ -while(_8.next&&(_8=_8.next)){ -} -_8.next=_a; -_a.previous=_8; -}else{ -if(_5=="before"){ -_4[_5]=_a; -_a.next=_8; -_8.previous=_a; -} -} -}else{ -_4[_5]=_a; -} -return _a; -}; -function _10(_11){ -return function(_12,_13,_14,_15){ -var _16=_12[_13],_17; -if(!_16||_16.target!=_12){ -_12[_13]=_17=function(){ -var _18=_2; -var _19=arguments; -var _1a=_17.before; -while(_1a){ -_19=_1a.advice.apply(this,_19)||_19; -_1a=_1a.next; -} -if(_17.around){ -var _1b=_17.around.advice(this,_19); -} -var _1c=_17.after; -while(_1c&&_1c.id<_18){ -if(_1c.receiveArguments){ -var _1d=_1c.advice.apply(this,_19); -_1b=_1d===_1?_1b:_1d; -}else{ -_1b=_1c.advice.call(this,_1b,_19); -} -_1c=_1c.next; -} -return _1b; -}; -if(_16){ -_17.around={advice:function(_1e,_1f){ -return _16.apply(_1e,_1f); -}}; -} -_17.target=_12; -} -var _20=_3((_17||_16),_11,_14,_15); -_14=null; -return _20; -}; -}; -var _21=_10("after"); -var _22=_10("before"); -var _23=_10("around"); -return {before:_22,around:_23,after:_21}; -}); diff --git a/lib/dojo/aspect.js.uncompressed.js b/lib/dojo/aspect.js.uncompressed.js deleted file mode 100644 index 157a1bb..0000000 --- a/lib/dojo/aspect.js.uncompressed.js +++ /dev/null @@ -1,223 +0,0 @@ -define("dojo/aspect", [], function(){ - - // module: - // dojo/aspect - - "use strict"; - var undefined, nextId = 0; - function advise(dispatcher, type, advice, receiveArguments){ - var previous = dispatcher[type]; - var around = type == "around"; - var signal; - if(around){ - var advised = advice(function(){ - return previous.advice(this, arguments); - }); - signal = { - remove: function(){ - if(advised){ - advised = dispatcher = advice = null; - } - }, - advice: function(target, args){ - return advised ? - advised.apply(target, args) : // called the advised function - previous.advice(target, args); // cancelled, skip to next one - } - }; - }else{ - // create the remove handler - signal = { - remove: function(){ - if(signal.advice){ - var previous = signal.previous; - var next = signal.next; - if(!next && !previous){ - delete dispatcher[type]; - }else{ - if(previous){ - previous.next = next; - }else{ - dispatcher[type] = next; - } - if(next){ - next.previous = previous; - } - } - - // remove the advice to signal that this signal has been removed - dispatcher = advice = signal.advice = null; - } - }, - id: nextId++, - advice: advice, - receiveArguments: receiveArguments - }; - } - if(previous && !around){ - if(type == "after"){ - // add the listener to the end of the list - // note that we had to change this loop a little bit to workaround a bizarre IE10 JIT bug - while(previous.next && (previous = previous.next)){} - previous.next = signal; - signal.previous = previous; - }else if(type == "before"){ - // add to beginning - dispatcher[type] = signal; - signal.next = previous; - previous.previous = signal; - } - }else{ - // around or first one just replaces - dispatcher[type] = signal; - } - return signal; - } - function aspect(type){ - return function(target, methodName, advice, receiveArguments){ - var existing = target[methodName], dispatcher; - if(!existing || existing.target != target){ - // no dispatcher in place - target[methodName] = dispatcher = function(){ - var executionId = nextId; - // before advice - var args = arguments; - var before = dispatcher.before; - while(before){ - args = before.advice.apply(this, args) || args; - before = before.next; - } - // around advice - if(dispatcher.around){ - var results = dispatcher.around.advice(this, args); - } - // after advice - var after = dispatcher.after; - while(after && after.id < executionId){ - if(after.receiveArguments){ - var newResults = after.advice.apply(this, args); - // change the return value only if a new value was returned - results = newResults === undefined ? results : newResults; - }else{ - results = after.advice.call(this, results, args); - } - after = after.next; - } - return results; - }; - if(existing){ - dispatcher.around = {advice: function(target, args){ - return existing.apply(target, args); - }}; - } - dispatcher.target = target; - } - var results = advise((dispatcher || existing), type, advice, receiveArguments); - advice = null; - return results; - }; - } - - // TODOC: after/before/around return object - - var after = aspect("after"); - /*===== - after = function(target, methodName, advice, receiveArguments){ - // summary: - // The "after" export of the aspect module is a function that can be used to attach - // "after" advice to a method. This function will be executed after the original method - // is executed. By default the function will be called with a single argument, the return - // value of the original method, or the the return value of the last executed advice (if a previous one exists). - // The fourth (optional) argument can be set to true to so the function receives the original - // arguments (from when the original method was called) rather than the return value. - // If there are multiple "after" advisors, they are executed in the order they were registered. - // target: Object - // This is the target object - // methodName: String - // This is the name of the method to attach to. - // advice: Function - // This is function to be called after the original method - // receiveArguments: Boolean? - // If this is set to true, the advice function receives the original arguments (from when the original mehtod - // was called) rather than the return value of the original/previous method. - // returns: - // A signal object that can be used to cancel the advice. If remove() is called on this signal object, it will - // stop the advice function from being executed. - }; - =====*/ - - var before = aspect("before"); - /*===== - before = function(target, methodName, advice){ - // summary: - // The "before" export of the aspect module is a function that can be used to attach - // "before" advice to a method. This function will be executed before the original method - // is executed. This function will be called with the arguments used to call the method. - // This function may optionally return an array as the new arguments to use to call - // the original method (or the previous, next-to-execute before advice, if one exists). - // If the before method doesn't return anything (returns undefined) the original arguments - // will be preserved. - // If there are multiple "before" advisors, they are executed in the reverse order they were registered. - // target: Object - // This is the target object - // methodName: String - // This is the name of the method to attach to. - // advice: Function - // This is function to be called before the original method - }; - =====*/ - - var around = aspect("around"); - /*===== - around = function(target, methodName, advice){ - // summary: - // The "around" export of the aspect module is a function that can be used to attach - // "around" advice to a method. The advisor function is immediately executed when - // the around() is called, is passed a single argument that is a function that can be - // called to continue execution of the original method (or the next around advisor). - // The advisor function should return a function, and this function will be called whenever - // the method is called. It will be called with the arguments used to call the method. - // Whatever this function returns will be returned as the result of the method call (unless after advise changes it). - // example: - // If there are multiple "around" advisors, the most recent one is executed first, - // which can then delegate to the next one and so on. For example: - // | around(obj, "foo", function(originalFoo){ - // | return function(){ - // | var start = new Date().getTime(); - // | var results = originalFoo.apply(this, arguments); // call the original - // | var end = new Date().getTime(); - // | console.log("foo execution took " + (end - start) + " ms"); - // | return results; - // | }; - // | }); - // target: Object - // This is the target object - // methodName: String - // This is the name of the method to attach to. - // advice: Function - // This is function to be called around the original method - }; - =====*/ - - return { - // summary: - // provides aspect oriented programming functionality, allowing for - // one to add before, around, or after advice on existing methods. - // example: - // | define(["dojo/aspect"], function(aspect){ - // | var signal = aspect.after(targetObject, "methodName", function(someArgument){ - // | this will be called when targetObject.methodName() is called, after the original function is called - // | }); - // - // example: - // The returned signal object can be used to cancel the advice. - // | signal.remove(); // this will stop the advice from being executed anymore - // | aspect.before(targetObject, "methodName", function(someArgument){ - // | // this will be called when targetObject.methodName() is called, before the original function is called - // | }); - - before: before, - around: around, - after: after - }; -}); diff --git a/lib/dojo/back.js b/lib/dojo/back.js deleted file mode 100644 index 1e3c4a8..0000000 --- a/lib/dojo/back.js +++ /dev/null @@ -1,239 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/back",["./_base/config","./_base/lang","./sniff","./dom","./dom-construct","./_base/window","require"],function(_1,_2,_3,_4,_5,_6,_7){ -var _8={}; -1&&_2.setObject("dojo.back",_8); -var _9=_8.getHash=function(){ -var h=window.location.hash; -if(h.charAt(0)=="#"){ -h=h.substring(1); -} -return _3("mozilla")?h:decodeURIComponent(h); -},_a=_8.setHash=function(h){ -if(!h){ -h=""; -} -window.location.hash=encodeURIComponent(h); -_b=history.length; -}; -var _c=(typeof (window)!=="undefined")?window.location.href:""; -var _d=(typeof (window)!=="undefined")?_9():""; -var _e=null; -var _f=null; -var _10=null; -var _11=null; -var _12=[]; -var _13=[]; -var _14=false; -var _15=false; -var _b; -function _16(){ -var _17=_13.pop(); -if(!_17){ -return; -} -var _18=_13[_13.length-1]; -if(!_18&&_13.length==0){ -_18=_e; -} -if(_18){ -if(_18.kwArgs["back"]){ -_18.kwArgs["back"](); -}else{ -if(_18.kwArgs["backButton"]){ -_18.kwArgs["backButton"](); -}else{ -if(_18.kwArgs["handle"]){ -_18.kwArgs.handle("back"); -} -} -} -} -_12.push(_17); -}; -_8.goBack=_16; -function _19(){ -var _1a=_12.pop(); -if(!_1a){ -return; -} -if(_1a.kwArgs["forward"]){ -_1a.kwArgs.forward(); -}else{ -if(_1a.kwArgs["forwardButton"]){ -_1a.kwArgs.forwardButton(); -}else{ -if(_1a.kwArgs["handle"]){ -_1a.kwArgs.handle("forward"); -} -} -} -_13.push(_1a); -}; -_8.goForward=_19; -function _1b(url,_1c,_1d){ -return {"url":url,"kwArgs":_1c,"urlHash":_1d}; -}; -function _1e(url){ -var _1f=url.split("?"); -if(_1f.length<2){ -return null; -}else{ -return _1f[1]; -} -}; -function _20(){ -var url=(_1["dojoIframeHistoryUrl"]||_7.toUrl("./resources/iframe_history.html"))+"?"+(new Date()).getTime(); -_14=true; -if(_11){ -_3("webkit")?_11.location=url:window.frames[_11.name].location=url; -}else{ -} -return url; -}; -function _21(){ -if(!_15){ -var hsl=_13.length; -var _22=_9(); -if((_22===_d||window.location.href==_c)&&(hsl==1)){ -_16(); -return; -} -if(_12.length>0){ -if(_12[_12.length-1].urlHash===_22){ -_19(); -return; -} -} -if((hsl>=2)&&(_13[hsl-2])){ -if(_13[hsl-2].urlHash===_22){ -_16(); -} -} -} -}; -_8.init=function(){ -if(_4.byId("dj_history")){ -return; -} -var src=_1["dojoIframeHistoryUrl"]||_7.toUrl("./resources/iframe_history.html"); -if(_1.afterOnLoad){ -console.error("dojo/back::init() must be called before the DOM has loaded. "+"Include dojo/back in a build layer."); -}else{ -document.write(""); -} -}; -_8.setInitialState=function(_23){ -_e=_1b(_c,_23,_d); -}; -_8.addToHistory=function(_24){ -_12=[]; -var _25=null; -var url=null; -if(!_11){ -if(_1["useXDomain"]&&!_1["dojoIframeHistoryUrl"]){ -console.warn("dojo/back: When using cross-domain Dojo builds,"+" please save iframe_history.html to your domain and set djConfig.dojoIframeHistoryUrl"+" to the path on your domain to iframe_history.html"); -} -_11=window.frames["dj_history"]; -} -if(!_10){ -_10=_5.create("a",{style:{display:"none"}},_6.body()); -} -if(_24["changeUrl"]){ -_25=""+((_24["changeUrl"]!==true)?_24["changeUrl"]:(new Date()).getTime()); -if(_13.length==0&&_e.urlHash==_25){ -_e=_1b(url,_24,_25); -return; -}else{ -if(_13.length>0&&_13[_13.length-1].urlHash==_25){ -_13[_13.length-1]=_1b(url,_24,_25); -return; -} -} -_15=true; -setTimeout(function(){ -_a(_25); -_15=false; -},1); -_10.href=_25; -if(_3("ie")){ -url=_20(); -var _26=_24["back"]||_24["backButton"]||_24["handle"]; -var tcb=function(_27){ -if(_9()!=""){ -setTimeout(function(){ -_a(_25); -},1); -} -_26.apply(this,[_27]); -}; -if(_24["back"]){ -_24.back=tcb; -}else{ -if(_24["backButton"]){ -_24.backButton=tcb; -}else{ -if(_24["handle"]){ -_24.handle=tcb; -} -} -} -var _28=_24["forward"]||_24["forwardButton"]||_24["handle"]; -var tfw=function(_29){ -if(_9()!=""){ -_a(_25); -} -if(_28){ -_28.apply(this,[_29]); -} -}; -if(_24["forward"]){ -_24.forward=tfw; -}else{ -if(_24["forwardButton"]){ -_24.forwardButton=tfw; -}else{ -if(_24["handle"]){ -_24.handle=tfw; -} -} -} -}else{ -if(!_3("ie")){ -if(!_f){ -_f=setInterval(_21,200); -} -} -} -}else{ -url=_20(); -} -_13.push(_1b(url,_24,_25)); -}; -_8._iframeLoaded=function(evt,_2a){ -var _2b=_1e(_2a.href); -if(_2b==null){ -if(_13.length==1){ -_16(); -} -return; -} -if(_14){ -_14=false; -return; -} -if(_13.length>=2&&_2b==_1e(_13[_13.length-2].url)){ -_16(); -}else{ -if(_12.length>0&&_2b==_1e(_12[_12.length-1].url)){ -_19(); -} -} -}; -return _8; -}); diff --git a/lib/dojo/back.js.uncompressed.js b/lib/dojo/back.js.uncompressed.js deleted file mode 100644 index f19052b..0000000 --- a/lib/dojo/back.js.uncompressed.js +++ /dev/null @@ -1,397 +0,0 @@ -define("dojo/back", ["./_base/config", "./_base/lang", "./sniff", "./dom", "./dom-construct", "./_base/window", "require"], - function(config, lang, has, dom, domConstruct, baseWindow, require){ - // module: - // dojo/back - - var back = { - // summary: - // Browser history management resources - }; - 1 && lang.setObject("dojo.back", back); - - // everyone deals with encoding the hash slightly differently - - var getHash = back.getHash = function(){ - var h = window.location.hash; - if(h.charAt(0) == "#"){ h = h.substring(1); } - return has("mozilla") ? h : decodeURIComponent(h); - }, - - setHash = back.setHash = function(h){ - if(!h){ h = ""; } - window.location.hash = encodeURIComponent(h); - historyCounter = history.length; - }; - - var initialHref = (typeof(window) !== "undefined") ? window.location.href : ""; - var initialHash = (typeof(window) !== "undefined") ? getHash() : ""; - var initialState = null; - - var locationTimer = null; - var bookmarkAnchor = null; - var historyIframe = null; - var forwardStack = []; - var historyStack = []; - var moveForward = false; - var changingUrl = false; - var historyCounter; - - function handleBackButton(){ - // summary: - // private method. Do not call this directly. - - //The "current" page is always at the top of the history stack. - var current = historyStack.pop(); - if(!current){ return; } - var last = historyStack[historyStack.length-1]; - if(!last && historyStack.length == 0){ - last = initialState; - } - if(last){ - if(last.kwArgs["back"]){ - last.kwArgs["back"](); - }else if(last.kwArgs["backButton"]){ - last.kwArgs["backButton"](); - }else if(last.kwArgs["handle"]){ - last.kwArgs.handle("back"); - } - } - forwardStack.push(current); - } - - back.goBack = handleBackButton; - - function handleForwardButton(){ - // summary: - // private method. Do not call this directly. - var last = forwardStack.pop(); - if(!last){ return; } - if(last.kwArgs["forward"]){ - last.kwArgs.forward(); - }else if(last.kwArgs["forwardButton"]){ - last.kwArgs.forwardButton(); - }else if(last.kwArgs["handle"]){ - last.kwArgs.handle("forward"); - } - historyStack.push(last); - } - - back.goForward = handleForwardButton; - - function createState(url, args, hash){ - // summary: - // private method. Do not call this directly. - return {"url": url, "kwArgs": args, "urlHash": hash}; //Object - } - - function getUrlQuery(url){ - // summary: - // private method. Do not call this directly. - var segments = url.split("?"); - if(segments.length < 2){ - return null; //null - } - else{ - return segments[1]; //String - } - } - - function loadIframeHistory(){ - // summary: - // private method. Do not call this directly. - var url = (config["dojoIframeHistoryUrl"] || require.toUrl("./resources/iframe_history.html")) + "?" + (new Date()).getTime(); - moveForward = true; - if(historyIframe){ - has("webkit") ? historyIframe.location = url : window.frames[historyIframe.name].location = url; - }else{ - //console.warn("dojo/back: Not initialised. You need to call back.init() from a - // - return new NodeList(); // dojo/NodeList - }; - =====*/ - - // the query that is returned from this module is slightly different than dojo.query, - // because dojo.query has to maintain backwards compatibility with returning a - // true array which has performance problems. The query returned from the module - // does not use true arrays, but rather inherits from Array, making it much faster to - // instantiate. - dojo.query = queryForEngine(defaultEngine, function(array){ - // call it without the new operator to invoke the back-compat behavior that returns a true array - return NodeList(array); // dojo/NodeList - }); - - query.load = function(id, parentRequire, loaded){ - // summary: - // can be used as AMD plugin to conditionally load new query engine - // example: - // | require(["dojo/query!custom"], function(qsa){ - // | // loaded selector/custom.js as engine - // | qsa("#foobar").forEach(...); - // | }); - loader.load(id, parentRequire, function(engine){ - loaded(queryForEngine(engine, NodeList)); - }); - }; - - dojo._filterQueryResult = query._filterResult = function(nodes, selector, root){ - return new NodeList(query.filter(nodes, selector, root)); - }; - dojo.NodeList = query.NodeList = NodeList; - return query; -}); - -}, -'dojo/has':function(){ -define(["require", "module"], function(require, module){ - // module: - // dojo/has - // summary: - // Defines the has.js API and several feature tests used by dojo. - // description: - // This module defines the has API as described by the project has.js with the following additional features: - // - // - the has test cache is exposed at has.cache. - // - the method has.add includes a forth parameter that controls whether or not existing tests are replaced - // - the loader's has cache may be optionally copied into this module's has cahce. - // - // This module adopted from https://github.com/phiggins42/has.js; thanks has.js team! - - // try to pull the has implementation from the loader; both the dojo loader and bdLoad provide one - // if using a foreign loader, then the has cache may be initialized via the config object for this module - // WARNING: if a foreign loader defines require.has to be something other than the has.js API, then this implementation fail - var has = require.has || function(){}; - if(! 1 ){ - var - isBrowser = - // the most fundamental decision: are we in the browser? - typeof window != "undefined" && - typeof location != "undefined" && - typeof document != "undefined" && - window.location == location && window.document == document, - - // has API variables - global = this, - doc = isBrowser && document, - element = doc && doc.createElement("DiV"), - cache = (module.config && module.config()) || {}; - - has = function(name){ - // summary: - // Return the current value of the named feature. - // - // name: String|Integer - // The name (if a string) or identifier (if an integer) of the feature to test. - // - // description: - // Returns the value of the feature named by name. The feature must have been - // previously added to the cache by has.add. - - return typeof cache[name] == "function" ? (cache[name] = cache[name](global, doc, element)) : cache[name]; // Boolean - }; - - has.cache = cache; - - has.add = function(name, test, now, force){ - // summary: - // Register a new feature test for some named feature. - // name: String|Integer - // The name (if a string) or identifier (if an integer) of the feature to test. - // test: Function - // A test function to register. If a function, queued for testing until actually - // needed. The test function should return a boolean indicating - // the presence of a feature or bug. - // now: Boolean? - // Optional. Omit if `test` is not a function. Provides a way to immediately - // run the test and cache the result. - // force: Boolean? - // Optional. If the test already exists and force is truthy, then the existing - // test will be replaced; otherwise, add does not replace an existing test (that - // is, by default, the first test advice wins). - // example: - // A redundant test, testFn with immediate execution: - // | has.add("javascript", function(){ return true; }, true); - // - // example: - // Again with the redundantness. You can do this in your tests, but we should - // not be doing this in any internal has.js tests - // | has.add("javascript", true); - // - // example: - // Three things are passed to the testFunction. `global`, `document`, and a generic element - // from which to work your test should the need arise. - // | has.add("bug-byid", function(g, d, el){ - // | // g == global, typically window, yadda yadda - // | // d == document object - // | // el == the generic element. a `has` element. - // | return false; // fake test, byid-when-form-has-name-matching-an-id is slightly longer - // | }); - - (typeof cache[name]=="undefined" || force) && (cache[name]= test); - return now && has(name); - }; - - // since we're operating under a loader that doesn't provide a has API, we must explicitly initialize - // has as it would have otherwise been initialized by the dojo loader; use has.add to the builder - // can optimize these away iff desired - 1 || has.add("host-browser", isBrowser); - 0 && has.add("host-node", (typeof process == "object" && process.versions && process.versions.node && process.versions.v8)); - 0 && has.add("host-rhino", (typeof load == "function" && (typeof Packages == "function" || typeof Packages == "object"))); - 1 || has.add("dom", isBrowser); - 1 || has.add("dojo-dom-ready-api", 1); - 1 || has.add("dojo-sniff", 1); - } - - if( 1 ){ - // Common application level tests - has.add("dom-addeventlistener", !!document.addEventListener); - - // Do the device and browser have touch capability? - has.add("touch", "ontouchstart" in document - || ("onpointerdown" in document && navigator.maxTouchPoints > 0) - || window.navigator.msMaxTouchPoints); - - // Touch events support - has.add("touch-events", "ontouchstart" in document); - - // Pointer Events support - has.add("pointer-events", "onpointerdown" in document); - has.add("MSPointer", "msMaxTouchPoints" in navigator); //IE10 (+IE11 preview) - - // I don't know if any of these tests are really correct, just a rough guess - has.add("device-width", screen.availWidth || innerWidth); - - // Tests for DOMNode.attributes[] behavior: - // - dom-attributes-explicit - attributes[] only lists explicitly user specified attributes - // - dom-attributes-specified-flag (IE8) - need to check attr.specified flag to skip attributes user didn't specify - // - Otherwise, in IE6-7. attributes[] will list hundreds of values, so need to do outerHTML to get attrs instead. - var form = document.createElement("form"); - has.add("dom-attributes-explicit", form.attributes.length == 0); // W3C - has.add("dom-attributes-specified-flag", form.attributes.length > 0 && form.attributes.length < 40); // IE8 - } - - has.clearElement = function(element){ - // summary: - // Deletes the contents of the element passed to test functions. - element.innerHTML= ""; - return element; - }; - - has.normalize = function(id, toAbsMid){ - // summary: - // Resolves id into a module id based on possibly-nested tenary expression that branches on has feature test value(s). - // - // toAbsMid: Function - // Resolves a relative module id into an absolute module id - var - tokens = id.match(/[\?:]|[^:\?]*/g), i = 0, - get = function(skip){ - var term = tokens[i++]; - if(term == ":"){ - // empty string module name, resolves to 0 - return 0; - }else{ - // postfixed with a ? means it is a feature to branch on, the term is the name of the feature - if(tokens[i++] == "?"){ - if(!skip && has(term)){ - // matched the feature, get the first value from the options - return get(); - }else{ - // did not match, get the second value, passing over the first - get(true); - return get(skip); - } - } - // a module - return term || 0; - } - }; - id = get(); - return id && toAbsMid(id); - }; - - has.load = function(id, parentRequire, loaded){ - // summary: - // Conditional loading of AMD modules based on a has feature test value. - // id: String - // Gives the resolved module id to load. - // parentRequire: Function - // The loader require function with respect to the module that contained the plugin resource in it's - // dependency list. - // loaded: Function - // Callback to loader that consumes result of plugin demand. - - if(id){ - parentRequire([id], loaded); - }else{ - loaded(); - } - }; - - return has; -}); - -}, -'dojo/_base/loader':function(){ -define(["./kernel", "../has", "require", "module", "../json", "./lang", "./array"], function(dojo, has, require, thisModule, json, lang, array) { - // module: - // dojo/_base/loader - - // This module defines the v1.x synchronous loader API. - - // signal the loader in sync mode... - //>>pure-amd - - if (! 1 ){ - console.error("cannot load the Dojo v1.x loader with a foreign loader"); - return 0; - } - - 1 || has.add("dojo-fast-sync-require", 1); - - - var makeErrorToken = function(id){ - return {src:thisModule.id, id:id}; - }, - - slashName = function(name){ - return name.replace(/\./g, "/"); - }, - - buildDetectRe = /\/\/>>built/, - - dojoRequireCallbacks = [], - dojoRequireModuleStack = [], - - dojoRequirePlugin = function(mid, require, loaded){ - dojoRequireCallbacks.push(loaded); - array.forEach(mid.split(","), function(mid){ - var module = getModule(mid, require.module); - dojoRequireModuleStack.push(module); - injectModule(module); - }); - checkDojoRequirePlugin(); - }, - - checkDojoRequirePlugin = ( 1 ? - // This version of checkDojoRequirePlugin makes the observation that all dojoRequireCallbacks can be released - // when all *non-dojo/require!, dojo/loadInit!* modules are either executed, not requested, or arrived. This is - // the case since there are no more modules the loader is waiting for, therefore, dojo/require! must have - // everything it needs on board. - // - // The potential weakness of this algorithm is that dojo/require will not execute callbacks until *all* dependency - // trees are ready. It is possible that some trees may be ready earlier than others, and this extra wait is non-optimal. - // Still, for big projects, this seems better than the original algorithm below that proved slow in some cases. - // Note, however, the original algorithm had the potential to execute partial trees, but that potential was never enabled. - // There are also other optimization available with the original algorithm that have not been explored. - function(){ - var module, mid; - for(mid in modules){ - module = modules[mid]; - if(module.noReqPluginCheck===undefined){ - // tag the module as either a loadInit or require plugin or not for future reference - module.noReqPluginCheck = /loadInit\!/.test(mid) || /require\!/.test(mid) ? 1 : 0; - } - if(!module.executed && !module.noReqPluginCheck && module.injected==requested){ - return; - } - } - - guardCheckComplete(function(){ - var oldCallbacks = dojoRequireCallbacks; - dojoRequireCallbacks = []; - array.forEach(oldCallbacks, function(cb){cb(1);}); - }); - } : (function(){ - // Note: this is the original checkDojoRequirePlugin that is much slower than the algorithm above. However, we know it - // works, so we leave it here in case the algorithm above fails in some corner case. - // - // checkDojoRequirePlugin inspects all of the modules demanded by a dojo/require! dependency - // to see if they have arrived. The loader does not release *any* of these modules to be instantiated - // until *all* of these modules are on board, thereby preventing the evaluation of a module with dojo.require's - // that reference modules that are not available. - // - // The algorithm works by traversing the dependency graphs (remember, there can be cycles so they are not trees) - // of each module in the dojoRequireModuleStack array (which contains the list of modules demanded by dojo/require!). - // The moment a single module is discovered that is missing, the algorithm gives up and indicates that not all - // modules are on board. dojo/loadInit! and dojo/require! are ignored because there dependencies are inserted - // directly in dojoRequireModuleStack. For example, if "your/module" module depends on "dojo/require!my/module", then - // *both* "dojo/require!my/module" and "my/module" will be in dojoRequireModuleStack. Obviously, if "my/module" - // is on board, then "dojo/require!my/module" is also satisfied, so the algorithm doesn't check for "dojo/require!my/module". - // - // Note: inserting a dojo/require! dependency in the dojoRequireModuleStack achieves nothing - // with the current algorithm; however, having such modules present makes it possible to optimize the algorithm - // - // Note: prior versions of this algorithm had an optimization that signaled loaded on dojo/require! dependencies - // individually (rather than waiting for them all to be resolved). The implementation proved problematic with cycles - // and plugins. However, it is possible to reattach that strategy in the future. - - // a set from module-id to {undefined | 1 | 0}, where... - // undefined => the module has not been inspected - // 0 => the module or at least one of its dependencies has not arrived - // 1 => the module is a loadInit! or require! plugin resource, or is currently being traversed (therefore, assume - // OK until proven otherwise), or has been completely traversed and all dependencies have arrived - - var touched, - traverse = function(m){ - touched[m.mid] = 1; - for(var t, module, deps = m.deps || [], i= 0; i a built module, always AMD - // extractResult==0 => no sync API - return 0; - } - - // manufacture a synthetic module id that can never be a real mdule id (just like require does) - id = module.mid + "-*loadInit"; - - // construct the dojo/loadInit names vector which causes any relocated names to be defined as lexical variables under their not-relocated name - // the dojo/loadInit plugin assumes the first name in names is "dojo" - - for(var p in getModule("dojo", module).result.scopeMap){ - names.push(p); - namesAsStrings.push('"' + p + '"'); - } - - // rewrite the module as a synthetic dojo/loadInit plugin resource + the module expressed as an AMD module that depends on this synthetic resource - // don't have to map dojo/init since that will occur when the dependency is resolved - return "// xdomain rewrite of " + module.mid + "\n" + - "define('" + id + "',{\n" + - "\tnames:" + json.stringify(names) + ",\n" + - "\tdef:function(" + names.join(",") + "){" + extractResult[1] + "}" + - "});\n\n" + - "define(" + json.stringify(names.concat(["dojo/loadInit!"+id])) + ", function(" + names.join(",") + "){\n" + extractResult[0] + "});"; - }, - - loaderVars = require.initSyncLoader(dojoRequirePlugin, checkDojoRequirePlugin, transformToAmd), - - sync = - loaderVars.sync, - - requested = - loaderVars.requested, - - arrived = - loaderVars.arrived, - - nonmodule = - loaderVars.nonmodule, - - executing = - loaderVars.executing, - - executed = - loaderVars.executed, - - syncExecStack = - loaderVars.syncExecStack, - - modules = - loaderVars.modules, - - execQ = - loaderVars.execQ, - - getModule = - loaderVars.getModule, - - injectModule = - loaderVars.injectModule, - - setArrived = - loaderVars.setArrived, - - signal = - loaderVars.signal, - - finishExec = - loaderVars.finishExec, - - execModule = - loaderVars.execModule, - - getLegacyMode = - loaderVars.getLegacyMode, - - guardCheckComplete = - loaderVars.guardCheckComplete; - - // there is exactly one dojoRequirePlugin among possibly-many dojo/_base/loader's (owing to mapping) - dojoRequirePlugin = loaderVars.dojoRequirePlugin; - - dojo.provide = function(mid){ - var executingModule = syncExecStack[0], - module = lang.mixin(getModule(slashName(mid), require.module), { - executed:executing, - result:lang.getObject(mid, true) - }); - setArrived(module); - if(executingModule){ - (executingModule.provides || (executingModule.provides = [])).push(function(){ - module.result = lang.getObject(mid); - delete module.provides; - module.executed!==executed && finishExec(module); - }); - }// else dojo.provide called not consequent to loading; therefore, give up trying to publish module value to loader namespace - return module.result; - }; - - has.add("config-publishRequireResult", 1, 0, 0); - - dojo.require = function(moduleName, omitModuleCheck) { - // summary: - // loads a Javascript module from the appropriate URI - // - // moduleName: String - // module name to load, using periods for separators, - // e.g. "dojo.date.locale". Module paths are de-referenced by dojo's - // internal mapping of locations to names and are disambiguated by - // longest prefix. See `dojo.registerModulePath()` for details on - // registering new modules. - // - // omitModuleCheck: Boolean? - // if `true`, omitModuleCheck skips the step of ensuring that the - // loaded file actually defines the symbol it is referenced by. - // For example if it called as `dojo.require("a.b.c")` and the - // file located at `a/b/c.js` does not define an object `a.b.c`, - // and exception will be throws whereas no exception is raised - // when called as `dojo.require("a.b.c", true)` - // - // description: - // Modules are loaded via dojo.require by using one of two loaders: the normal loader - // and the xdomain loader. The xdomain loader is used when dojo was built with a - // custom build that specified loader=xdomain and the module lives on a modulePath - // that is a whole URL, with protocol and a domain. The versions of Dojo that are on - // the Google and AOL CDNs use the xdomain loader. - // - // If the module is loaded via the xdomain loader, it is an asynchronous load, since - // the module is added via a dynamically created script tag. This - // means that dojo.require() can return before the module has loaded. However, this - // should only happen in the case where you do dojo.require calls in the top-level - // HTML page, or if you purposely avoid the loader checking for dojo.require - // dependencies in your module by using a syntax like dojo["require"] to load the module. - // - // Sometimes it is useful to not have the loader detect the dojo.require calls in the - // module so that you can dynamically load the modules as a result of an action on the - // page, instead of right at module load time. - // - // Also, for script blocks in an HTML page, the loader does not pre-process them, so - // it does not know to download the modules before the dojo.require calls occur. - // - // So, in those two cases, when you want on-the-fly module loading or for script blocks - // in the HTML page, special care must be taken if the dojo.required code is loaded - // asynchronously. To make sure you can execute code that depends on the dojo.required - // modules, be sure to add the code that depends on the modules in a dojo.addOnLoad() - // callback. dojo.addOnLoad waits for all outstanding modules to finish loading before - // executing. - // - // This type of syntax works with both xdomain and normal loaders, so it is good - // practice to always use this idiom for on-the-fly code loading and in HTML script - // blocks. If at some point you change loaders and where the code is loaded from, - // it will all still work. - // - // More on how dojo.require - // `dojo.require("A.B")` first checks to see if symbol A.B is - // defined. If it is, it is simply returned (nothing to do). - // - // If it is not defined, it will look for `A/B.js` in the script root - // directory. - // - // `dojo.require` throws an exception if it cannot find a file - // to load, or if the symbol `A.B` is not defined after loading. - // - // It returns the object `A.B`, but note the caveats above about on-the-fly loading and - // HTML script blocks when the xdomain loader is loading a module. - // - // `dojo.require()` does nothing about importing symbols into - // the current namespace. It is presumed that the caller will - // take care of that. - // - // example: - // To use dojo.require in conjunction with dojo.ready: - // - // | dojo.require("foo"); - // | dojo.require("bar"); - // | dojo.addOnLoad(function(){ - // | //you can now safely do something with foo and bar - // | }); - // - // example: - // For example, to import all symbols into a local block, you might write: - // - // | with (dojo.require("A.B")) { - // | ... - // | } - // - // And to import just the leaf symbol to a local variable: - // - // | var B = dojo.require("A.B"); - // | ... - // - // returns: - // the required namespace object - function doRequire(mid, omitModuleCheck){ - var module = getModule(slashName(mid), require.module); - if(syncExecStack.length && syncExecStack[0].finish){ - // switched to async loading in the middle of evaluating a legacy module; stop - // applying dojo.require so the remaining dojo.requires are applied in order - syncExecStack[0].finish.push(mid); - return undefined; - } - - // recall module.executed has values {0, executing, executed}; therefore, truthy indicates executing or executed - if(module.executed){ - return module.result; - } - omitModuleCheck && (module.result = nonmodule); - - // rcg...why here and in two lines?? - var currentMode = getLegacyMode(); - - // recall, in sync mode to inject is to *eval* the module text - // if the module is a legacy module, this is the same as executing - // but if the module is an AMD module, this means defining, not executing - injectModule(module); - // the inject may have changed the mode - currentMode = getLegacyMode(); - - // in sync mode to dojo.require is to execute - if(module.executed!==executed && module.injected===arrived){ - // the module was already here before injectModule was called probably finishing up a xdomain - // load, but maybe a module given to the loader directly rather than having the loader retrieve it - - loaderVars.guardCheckComplete(function(){ - execModule(module); - }); - } - if(module.executed){ - return module.result; - } - - if(currentMode==sync){ - // the only way to get here is in sync mode and dojo.required a module that - // * was loaded async in the injectModule application a few lines up - // * was an AMD module that had deps that are being loaded async and therefore couldn't execute - if(module.cjs){ - // the module was an AMD module; unshift, not push, which causes the current traversal to be reattempted from the top - execQ.unshift(module); - }else{ - // the module was a legacy module - syncExecStack.length && (syncExecStack[0].finish= [mid]); - } - }else{ - // the loader wasn't in sync mode on entry; probably async mode; therefore, no expectation of getting - // the module value synchronously; make sure it gets executed though - execQ.push(module); - } - - return undefined; - } - - var result = doRequire(moduleName, omitModuleCheck); - if(has("config-publishRequireResult") && !lang.exists(moduleName) && result!==undefined){ - lang.setObject(moduleName, result); - } - return result; - }; - - dojo.loadInit = function(f) { - f(); - }; - - dojo.registerModulePath = function(/*String*/moduleName, /*String*/prefix){ - // summary: - // Maps a module name to a path - // description: - // An unregistered module is given the default path of ../[module], - // relative to Dojo root. For example, module acme is mapped to - // ../acme. If you want to use a different module name, use - // dojo.registerModulePath. - // example: - // If your dojo.js is located at this location in the web root: - // | /myapp/js/dojo/dojo/dojo.js - // and your modules are located at: - // | /myapp/js/foo/bar.js - // | /myapp/js/foo/baz.js - // | /myapp/js/foo/thud/xyzzy.js - // Your application can tell Dojo to locate the "foo" namespace by calling: - // | dojo.registerModulePath("foo", "../../foo"); - // At which point you can then use dojo.require() to load the - // modules (assuming they provide() the same things which are - // required). The full code might be: - // | - // | - - var paths = {}; - paths[moduleName.replace(/\./g, "/")] = prefix; - require({paths:paths}); - }; - - dojo.platformRequire = function(/*Object*/modMap){ - // summary: - // require one or more modules based on which host environment - // Dojo is currently operating in - // description: - // This method takes a "map" of arrays which one can use to - // optionally load dojo modules. The map is indexed by the - // possible dojo.name_ values, with two additional values: - // "default" and "common". The items in the "default" array will - // be loaded if none of the other items have been chosen based on - // dojo.name_, set by your host environment. The items in the - // "common" array will *always* be loaded, regardless of which - // list is chosen. - // example: - // | dojo.platformRequire({ - // | browser: [ - // | "foo.sample", // simple module - // | "foo.test", - // | ["foo.bar.baz", true] // skip object check in _loadModule (dojo.require) - // | ], - // | default: [ "foo.sample._base" ], - // | common: [ "important.module.common" ] - // | }); - - var result = (modMap.common || []).concat(modMap[dojo._name] || modMap["default"] || []), - temp; - while(result.length){ - if(lang.isArray(temp = result.shift())){ - dojo.require.apply(dojo, temp); - }else{ - dojo.require(temp); - } - } - }; - - dojo.requireIf = dojo.requireAfterIf = function(/*Boolean*/ condition, /*String*/ moduleName, /*Boolean?*/omitModuleCheck){ - // summary: - // If the condition is true then call `dojo.require()` for the specified - // resource - // - // example: - // | dojo.requireIf(dojo.isBrowser, "my.special.Module"); - - if(condition){ - dojo.require(moduleName, omitModuleCheck); - } - }; - - dojo.requireLocalization = function(/*String*/moduleName, /*String*/bundleName, /*String?*/locale){ - require(["../i18n"], function(i18n){ - i18n.getLocalization(moduleName, bundleName, locale); - }); - }; - - return { - // summary: - // This module defines the v1.x synchronous loader API. - - extractLegacyApiApplications:extractLegacyApiApplications, - require:dojoRequirePlugin, - loadInit:dojoLoadInitPlugin - }; -}); - -}, -'dojo/json':function(){ -define(["./has"], function(has){ - "use strict"; - var hasJSON = typeof JSON != "undefined"; - has.add("json-parse", hasJSON); // all the parsers work fine - // Firefox 3.5/Gecko 1.9 fails to use replacer in stringify properly https://bugzilla.mozilla.org/show_bug.cgi?id=509184 - has.add("json-stringify", hasJSON && JSON.stringify({a:0}, function(k,v){return v||1;}) == '{"a":1}'); - - /*===== - return { - // summary: - // Functions to parse and serialize JSON - - parse: function(str, strict){ - // summary: - // Parses a [JSON](http://json.org) string to return a JavaScript object. - // description: - // This function follows [native JSON API](https://developer.mozilla.org/en/JSON) - // Throws for invalid JSON strings. This delegates to eval() if native JSON - // support is not available. By default this will evaluate any valid JS expression. - // With the strict parameter set to true, the parser will ensure that only - // valid JSON strings are parsed (otherwise throwing an error). Without the strict - // parameter, the content passed to this method must come - // from a trusted source. - // str: - // a string literal of a JSON item, for instance: - // `'{ "foo": [ "bar", 1, { "baz": "thud" } ] }'` - // strict: - // When set to true, this will ensure that only valid, secure JSON is ever parsed. - // Make sure this is set to true for untrusted content. Note that on browsers/engines - // without native JSON support, setting this to true will run slower. - }, - stringify: function(value, replacer, spacer){ - // summary: - // Returns a [JSON](http://json.org) serialization of an object. - // description: - // Returns a [JSON](http://json.org) serialization of an object. - // This function follows [native JSON API](https://developer.mozilla.org/en/JSON) - // Note that this doesn't check for infinite recursion, so don't do that! - // value: - // A value to be serialized. - // replacer: - // A replacer function that is called for each value and can return a replacement - // spacer: - // A spacer string to be used for pretty printing of JSON - // example: - // simple serialization of a trivial object - // | define(["dojo/json"], function(JSON){ - // | var jsonStr = JSON.stringify({ howdy: "stranger!", isStrange: true }); - // | doh.is('{"howdy":"stranger!","isStrange":true}', jsonStr); - } - }; - =====*/ - - if(has("json-stringify")){ - return JSON; - }else{ - var escapeString = function(/*String*/str){ - // summary: - // Adds escape sequences for non-visual characters, double quote and - // backslash and surrounds with double quotes to form a valid string - // literal. - return ('"' + str.replace(/(["\\])/g, '\\$1') + '"'). - replace(/[\f]/g, "\\f").replace(/[\b]/g, "\\b").replace(/[\n]/g, "\\n"). - replace(/[\t]/g, "\\t").replace(/[\r]/g, "\\r"); // string - }; - return { - parse: has("json-parse") ? JSON.parse : function(str, strict){ - if(strict && !/^([\s\[\{]*(?:"(?:\\.|[^"])*"|-?\d[\d\.]*(?:[Ee][+-]?\d+)?|null|true|false|)[\s\]\}]*(?:,|:|$))+$/.test(str)){ - throw new SyntaxError("Invalid characters in JSON"); - } - return eval('(' + str + ')'); - }, - stringify: function(value, replacer, spacer){ - var undef; - if(typeof replacer == "string"){ - spacer = replacer; - replacer = null; - } - function stringify(it, indent, key){ - if(replacer){ - it = replacer(key, it); - } - var val, objtype = typeof it; - if(objtype == "number"){ - return isFinite(it) ? it + "" : "null"; - } - if(objtype == "boolean"){ - return it + ""; - } - if(it === null){ - return "null"; - } - if(typeof it == "string"){ - return escapeString(it); - } - if(objtype == "function" || objtype == "undefined"){ - return undef; // undefined - } - // short-circuit for objects that support "json" serialization - // if they return "self" then just pass-through... - if(typeof it.toJSON == "function"){ - return stringify(it.toJSON(key), indent, key); - } - if(it instanceof Date){ - return '"{FullYear}-{Month+}-{Date}T{Hours}:{Minutes}:{Seconds}Z"'.replace(/\{(\w+)(\+)?\}/g, function(t, prop, plus){ - var num = it["getUTC" + prop]() + (plus ? 1 : 0); - return num < 10 ? "0" + num : num; - }); - } - if(it.valueOf() !== it){ - // primitive wrapper, try again unwrapped: - return stringify(it.valueOf(), indent, key); - } - var nextIndent= spacer ? (indent + spacer) : ""; - /* we used to test for DOM nodes and throw, but FF serializes them as {}, so cross-browser consistency is probably not efficiently attainable */ - - var sep = spacer ? " " : ""; - var newLine = spacer ? "\n" : ""; - - // array - if(it instanceof Array){ - var itl = it.length, res = []; - for(key = 0; key < itl; key++){ - var obj = it[key]; - val = stringify(obj, nextIndent, key); - if(typeof val != "string"){ - val = "null"; - } - res.push(newLine + nextIndent + val); - } - return "[" + res.join(",") + newLine + indent + "]"; - } - // generic object code path - var output = []; - for(key in it){ - var keyStr; - if(it.hasOwnProperty(key)){ - if(typeof key == "number"){ - keyStr = '"' + key + '"'; - }else if(typeof key == "string"){ - keyStr = escapeString(key); - }else{ - // skip non-string or number keys - continue; - } - val = stringify(it[key], nextIndent, key); - if(typeof val != "string"){ - // skip non-serializable values - continue; - } - // At this point, the most non-IE browsers don't get in this branch - // (they have native JSON), so push is definitely the way to - output.push(newLine + nextIndent + keyStr + ":" + sep + val); - } - } - return "{" + output.join(",") + newLine + indent + "}"; // String - } - return stringify(value, "", ""); - } - }; - } -}); - -}, -'dojo/_base/declare':function(){ -define(["./kernel", "../has", "./lang"], function(dojo, has, lang){ - // module: - // dojo/_base/declare - - var mix = lang.mixin, op = Object.prototype, opts = op.toString, - xtor = new Function, counter = 0, cname = "constructor"; - - function err(msg, cls){ throw new Error("declare" + (cls ? " " + cls : "") + ": " + msg); } - - // C3 Method Resolution Order (see http://www.python.org/download/releases/2.3/mro/) - function c3mro(bases, className){ - var result = [], roots = [{cls: 0, refs: []}], nameMap = {}, clsCount = 1, - l = bases.length, i = 0, j, lin, base, top, proto, rec, name, refs; - - // build a list of bases naming them if needed - for(; i < l; ++i){ - base = bases[i]; - if(!base){ - err("mixin #" + i + " is unknown. Did you use dojo.require to pull it in?", className); - }else if(opts.call(base) != "[object Function]"){ - err("mixin #" + i + " is not a callable constructor.", className); - } - lin = base._meta ? base._meta.bases : [base]; - top = 0; - // add bases to the name map - for(j = lin.length - 1; j >= 0; --j){ - proto = lin[j].prototype; - if(!proto.hasOwnProperty("declaredClass")){ - proto.declaredClass = "uniqName_" + (counter++); - } - name = proto.declaredClass; - if(!nameMap.hasOwnProperty(name)){ - nameMap[name] = {count: 0, refs: [], cls: lin[j]}; - ++clsCount; - } - rec = nameMap[name]; - if(top && top !== rec){ - rec.refs.push(top); - ++top.count; - } - top = rec; - } - ++top.count; - roots[0].refs.push(top); - } - - // remove classes without external references recursively - while(roots.length){ - top = roots.pop(); - result.push(top.cls); - --clsCount; - // optimization: follow a single-linked chain - while(refs = top.refs, refs.length == 1){ - top = refs[0]; - if(!top || --top.count){ - // branch or end of chain => do not end to roots - top = 0; - break; - } - result.push(top.cls); - --clsCount; - } - if(top){ - // branch - for(i = 0, l = refs.length; i < l; ++i){ - top = refs[i]; - if(!--top.count){ - roots.push(top); - } - } - } - } - if(clsCount){ - err("can't build consistent linearization", className); - } - - // calculate the superclass offset - base = bases[0]; - result[0] = base ? - base._meta && base === result[result.length - base._meta.bases.length] ? - base._meta.bases.length : 1 : 0; - - return result; - } - - function inherited(args, a, f){ - var name, chains, bases, caller, meta, base, proto, opf, pos, - cache = this._inherited = this._inherited || {}; - - // crack arguments - if(typeof args == "string"){ - name = args; - args = a; - a = f; - } - f = 0; - - caller = args.callee; - name = name || caller.nom; - if(!name){ - err("can't deduce a name to call inherited()", this.declaredClass); - } - - meta = this.constructor._meta; - bases = meta.bases; - - pos = cache.p; - if(name != cname){ - // method - if(cache.c !== caller){ - // cache bust - pos = 0; - base = bases[0]; - meta = base._meta; - if(meta.hidden[name] !== caller){ - // error detection - chains = meta.chains; - if(chains && typeof chains[name] == "string"){ - err("calling chained method with inherited: " + name, this.declaredClass); - } - // find caller - do{ - meta = base._meta; - proto = base.prototype; - if(meta && (proto[name] === caller && proto.hasOwnProperty(name) || meta.hidden[name] === caller)){ - break; - } - }while(base = bases[++pos]); // intentional assignment - pos = base ? pos : -1; - } - } - // find next - base = bases[++pos]; - if(base){ - proto = base.prototype; - if(base._meta && proto.hasOwnProperty(name)){ - f = proto[name]; - }else{ - opf = op[name]; - do{ - proto = base.prototype; - f = proto[name]; - if(f && (base._meta ? proto.hasOwnProperty(name) : f !== opf)){ - break; - } - }while(base = bases[++pos]); // intentional assignment - } - } - f = base && f || op[name]; - }else{ - // constructor - if(cache.c !== caller){ - // cache bust - pos = 0; - meta = bases[0]._meta; - if(meta && meta.ctor !== caller){ - // error detection - chains = meta.chains; - if(!chains || chains.constructor !== "manual"){ - err("calling chained constructor with inherited", this.declaredClass); - } - // find caller - while(base = bases[++pos]){ // intentional assignment - meta = base._meta; - if(meta && meta.ctor === caller){ - break; - } - } - pos = base ? pos : -1; - } - } - // find next - while(base = bases[++pos]){ // intentional assignment - meta = base._meta; - f = meta ? meta.ctor : base; - if(f){ - break; - } - } - f = base && f; - } - - // cache the found super method - cache.c = f; - cache.p = pos; - - // now we have the result - if(f){ - return a === true ? f : f.apply(this, a || args); - } - // intentionally no return if a super method was not found - } - - function getInherited(name, args){ - if(typeof name == "string"){ - return this.__inherited(name, args, true); - } - return this.__inherited(name, true); - } - - function inherited__debug(args, a1, a2){ - var f = this.getInherited(args, a1); - if(f){ return f.apply(this, a2 || a1 || args); } - // intentionally no return if a super method was not found - } - - var inheritedImpl = dojo.config.isDebug ? inherited__debug : inherited; - - // emulation of "instanceof" - function isInstanceOf(cls){ - var bases = this.constructor._meta.bases; - for(var i = 0, l = bases.length; i < l; ++i){ - if(bases[i] === cls){ - return true; - } - } - return this instanceof cls; - } - - function mixOwn(target, source){ - // add props adding metadata for incoming functions skipping a constructor - for(var name in source){ - if(name != cname && source.hasOwnProperty(name)){ - target[name] = source[name]; - } - } - if(has("bug-for-in-skips-shadowed")){ - for(var extraNames= lang._extraNames, i= extraNames.length; i;){ - name = extraNames[--i]; - if(name != cname && source.hasOwnProperty(name)){ - target[name] = source[name]; - } - } - } - } - - // implementation of safe mixin function - function safeMixin(target, source){ - // summary: - // Mix in properties skipping a constructor and decorating functions - // like it is done by declare(). - // target: Object - // Target object to accept new properties. - // source: Object - // Source object for new properties. - // description: - // This function is used to mix in properties like lang.mixin does, - // but it skips a constructor property and decorates functions like - // declare() does. - // - // It is meant to be used with classes and objects produced with - // declare. Functions mixed in with dojo.safeMixin can use - // this.inherited() like normal methods. - // - // This function is used to implement extend() method of a constructor - // produced with declare(). - // - // example: - // | var A = declare(null, { - // | m1: function(){ - // | console.log("A.m1"); - // | }, - // | m2: function(){ - // | console.log("A.m2"); - // | } - // | }); - // | var B = declare(A, { - // | m1: function(){ - // | this.inherited(arguments); - // | console.log("B.m1"); - // | } - // | }); - // | B.extend({ - // | m2: function(){ - // | this.inherited(arguments); - // | console.log("B.m2"); - // | } - // | }); - // | var x = new B(); - // | dojo.safeMixin(x, { - // | m1: function(){ - // | this.inherited(arguments); - // | console.log("X.m1"); - // | }, - // | m2: function(){ - // | this.inherited(arguments); - // | console.log("X.m2"); - // | } - // | }); - // | x.m2(); - // | // prints: - // | // A.m1 - // | // B.m1 - // | // X.m1 - - var name, t; - // add props adding metadata for incoming functions skipping a constructor - for(name in source){ - t = source[name]; - if((t !== op[name] || !(name in op)) && name != cname){ - if(opts.call(t) == "[object Function]"){ - // non-trivial function method => attach its name - t.nom = name; - } - target[name] = t; - } - } - if(has("bug-for-in-skips-shadowed")){ - for(var extraNames= lang._extraNames, i= extraNames.length; i;){ - name = extraNames[--i]; - t = source[name]; - if((t !== op[name] || !(name in op)) && name != cname){ - if(opts.call(t) == "[object Function]"){ - // non-trivial function method => attach its name - t.nom = name; - } - target[name] = t; - } - } - } - return target; - } - - function extend(source){ - declare.safeMixin(this.prototype, source); - return this; - } - - function createSubclass(mixins, props){ - // crack parameters - if(!(mixins instanceof Array || typeof mixins == 'function')){ - props = mixins; - mixins = undefined; - } - - props = props || {}; - mixins = mixins || []; - - return declare([this].concat(mixins), props); - } - - // chained constructor compatible with the legacy declare() - function chainedConstructor(bases, ctorSpecial){ - return function(){ - var a = arguments, args = a, a0 = a[0], f, i, m, - l = bases.length, preArgs; - - if(!(this instanceof a.callee)){ - // not called via new, so force it - return applyNew(a); - } - - //this._inherited = {}; - // perform the shaman's rituals of the original declare() - // 1) call two types of the preamble - if(ctorSpecial && (a0 && a0.preamble || this.preamble)){ - // full blown ritual - preArgs = new Array(bases.length); - // prepare parameters - preArgs[0] = a; - for(i = 0;;){ - // process the preamble of the 1st argument - a0 = a[0]; - if(a0){ - f = a0.preamble; - if(f){ - a = f.apply(this, a) || a; - } - } - // process the preamble of this class - f = bases[i].prototype; - f = f.hasOwnProperty("preamble") && f.preamble; - if(f){ - a = f.apply(this, a) || a; - } - // one peculiarity of the preamble: - // it is called if it is not needed, - // e.g., there is no constructor to call - // let's watch for the last constructor - // (see ticket #9795) - if(++i == l){ - break; - } - preArgs[i] = a; - } - } - // 2) call all non-trivial constructors using prepared arguments - for(i = l - 1; i >= 0; --i){ - f = bases[i]; - m = f._meta; - f = m ? m.ctor : f; - if(f){ - f.apply(this, preArgs ? preArgs[i] : a); - } - } - // 3) continue the original ritual: call the postscript - f = this.postscript; - if(f){ - f.apply(this, args); - } - }; - } - - - // chained constructor compatible with the legacy declare() - function singleConstructor(ctor, ctorSpecial){ - return function(){ - var a = arguments, t = a, a0 = a[0], f; - - if(!(this instanceof a.callee)){ - // not called via new, so force it - return applyNew(a); - } - - //this._inherited = {}; - // perform the shaman's rituals of the original declare() - // 1) call two types of the preamble - if(ctorSpecial){ - // full blown ritual - if(a0){ - // process the preamble of the 1st argument - f = a0.preamble; - if(f){ - t = f.apply(this, t) || t; - } - } - f = this.preamble; - if(f){ - // process the preamble of this class - f.apply(this, t); - // one peculiarity of the preamble: - // it is called even if it is not needed, - // e.g., there is no constructor to call - // let's watch for the last constructor - // (see ticket #9795) - } - } - // 2) call a constructor - if(ctor){ - ctor.apply(this, a); - } - // 3) continue the original ritual: call the postscript - f = this.postscript; - if(f){ - f.apply(this, a); - } - }; - } - - // plain vanilla constructor (can use inherited() to call its base constructor) - function simpleConstructor(bases){ - return function(){ - var a = arguments, i = 0, f, m; - - if(!(this instanceof a.callee)){ - // not called via new, so force it - return applyNew(a); - } - - //this._inherited = {}; - // perform the shaman's rituals of the original declare() - // 1) do not call the preamble - // 2) call the top constructor (it can use this.inherited()) - for(; f = bases[i]; ++i){ // intentional assignment - m = f._meta; - f = m ? m.ctor : f; - if(f){ - f.apply(this, a); - break; - } - } - // 3) call the postscript - f = this.postscript; - if(f){ - f.apply(this, a); - } - }; - } - - function chain(name, bases, reversed){ - return function(){ - var b, m, f, i = 0, step = 1; - if(reversed){ - i = bases.length - 1; - step = -1; - } - for(; b = bases[i]; i += step){ // intentional assignment - m = b._meta; - f = (m ? m.hidden : b.prototype)[name]; - if(f){ - f.apply(this, arguments); - } - } - }; - } - - // forceNew(ctor) - // return a new object that inherits from ctor.prototype but - // without actually running ctor on the object. - function forceNew(ctor){ - // create object with correct prototype using a do-nothing - // constructor - xtor.prototype = ctor.prototype; - var t = new xtor; - xtor.prototype = null; // clean up - return t; - } - - // applyNew(args) - // just like 'new ctor()' except that the constructor and its arguments come - // from args, which must be an array or an arguments object - function applyNew(args){ - // create an object with ctor's prototype but without - // calling ctor on it. - var ctor = args.callee, t = forceNew(ctor); - // execute the real constructor on the new object - ctor.apply(t, args); - return t; - } - - function declare(className, superclass, props){ - // summary: - // Create a feature-rich constructor from compact notation. - // className: String? - // The optional name of the constructor (loosely, a "class") - // stored in the "declaredClass" property in the created prototype. - // It will be used as a global name for a created constructor. - // superclass: Function|Function[] - // May be null, a Function, or an Array of Functions. This argument - // specifies a list of bases (the left-most one is the most deepest - // base). - // props: Object - // An object whose properties are copied to the created prototype. - // Add an instance-initialization function by making it a property - // named "constructor". - // returns: dojo/_base/declare.__DeclareCreatedObject - // New constructor function. - // description: - // Create a constructor using a compact notation for inheritance and - // prototype extension. - // - // Mixin ancestors provide a type of multiple inheritance. - // Prototypes of mixin ancestors are copied to the new class: - // changes to mixin prototypes will not affect classes to which - // they have been mixed in. - // - // Ancestors can be compound classes created by this version of - // declare(). In complex cases all base classes are going to be - // linearized according to C3 MRO algorithm - // (see http://www.python.org/download/releases/2.3/mro/ for more - // details). - // - // "className" is cached in "declaredClass" property of the new class, - // if it was supplied. The immediate super class will be cached in - // "superclass" property of the new class. - // - // Methods in "props" will be copied and modified: "nom" property - // (the declared name of the method) will be added to all copied - // functions to help identify them for the internal machinery. Be - // very careful, while reusing methods: if you use the same - // function under different names, it can produce errors in some - // cases. - // - // It is possible to use constructors created "manually" (without - // declare()) as bases. They will be called as usual during the - // creation of an instance, their methods will be chained, and even - // called by "this.inherited()". - // - // Special property "-chains-" governs how to chain methods. It is - // a dictionary, which uses method names as keys, and hint strings - // as values. If a hint string is "after", this method will be - // called after methods of its base classes. If a hint string is - // "before", this method will be called before methods of its base - // classes. - // - // If "constructor" is not mentioned in "-chains-" property, it will - // be chained using the legacy mode: using "after" chaining, - // calling preamble() method before each constructor, if available, - // and calling postscript() after all constructors were executed. - // If the hint is "after", it is chained as a regular method, but - // postscript() will be called after the chain of constructors. - // "constructor" cannot be chained "before", but it allows - // a special hint string: "manual", which means that constructors - // are not going to be chained in any way, and programmer will call - // them manually using this.inherited(). In the latter case - // postscript() will be called after the construction. - // - // All chaining hints are "inherited" from base classes and - // potentially can be overridden. Be very careful when overriding - // hints! Make sure that all chained methods can work in a proposed - // manner of chaining. - // - // Once a method was chained, it is impossible to unchain it. The - // only exception is "constructor". You don't need to define a - // method in order to supply a chaining hint. - // - // If a method is chained, it cannot use this.inherited() because - // all other methods in the hierarchy will be called automatically. - // - // Usually constructors and initializers of any kind are chained - // using "after" and destructors of any kind are chained as - // "before". Note that chaining assumes that chained methods do not - // return any value: any returned value will be discarded. - // - // example: - // | declare("my.classes.bar", my.classes.foo, { - // | // properties to be added to the class prototype - // | someValue: 2, - // | // initialization function - // | constructor: function(){ - // | this.myComplicatedObject = new ReallyComplicatedObject(); - // | }, - // | // other functions - // | someMethod: function(){ - // | doStuff(); - // | } - // | }); - // - // example: - // | var MyBase = declare(null, { - // | // constructor, properties, and methods go here - // | // ... - // | }); - // | var MyClass1 = declare(MyBase, { - // | // constructor, properties, and methods go here - // | // ... - // | }); - // | var MyClass2 = declare(MyBase, { - // | // constructor, properties, and methods go here - // | // ... - // | }); - // | var MyDiamond = declare([MyClass1, MyClass2], { - // | // constructor, properties, and methods go here - // | // ... - // | }); - // - // example: - // | var F = function(){ console.log("raw constructor"); }; - // | F.prototype.method = function(){ - // | console.log("raw method"); - // | }; - // | var A = declare(F, { - // | constructor: function(){ - // | console.log("A.constructor"); - // | }, - // | method: function(){ - // | console.log("before calling F.method..."); - // | this.inherited(arguments); - // | console.log("...back in A"); - // | } - // | }); - // | new A().method(); - // | // will print: - // | // raw constructor - // | // A.constructor - // | // before calling F.method... - // | // raw method - // | // ...back in A - // - // example: - // | var A = declare(null, { - // | "-chains-": { - // | destroy: "before" - // | } - // | }); - // | var B = declare(A, { - // | constructor: function(){ - // | console.log("B.constructor"); - // | }, - // | destroy: function(){ - // | console.log("B.destroy"); - // | } - // | }); - // | var C = declare(B, { - // | constructor: function(){ - // | console.log("C.constructor"); - // | }, - // | destroy: function(){ - // | console.log("C.destroy"); - // | } - // | }); - // | new C().destroy(); - // | // prints: - // | // B.constructor - // | // C.constructor - // | // C.destroy - // | // B.destroy - // - // example: - // | var A = declare(null, { - // | "-chains-": { - // | constructor: "manual" - // | } - // | }); - // | var B = declare(A, { - // | constructor: function(){ - // | // ... - // | // call the base constructor with new parameters - // | this.inherited(arguments, [1, 2, 3]); - // | // ... - // | } - // | }); - // - // example: - // | var A = declare(null, { - // | "-chains-": { - // | m1: "before" - // | }, - // | m1: function(){ - // | console.log("A.m1"); - // | }, - // | m2: function(){ - // | console.log("A.m2"); - // | } - // | }); - // | var B = declare(A, { - // | "-chains-": { - // | m2: "after" - // | }, - // | m1: function(){ - // | console.log("B.m1"); - // | }, - // | m2: function(){ - // | console.log("B.m2"); - // | } - // | }); - // | var x = new B(); - // | x.m1(); - // | // prints: - // | // B.m1 - // | // A.m1 - // | x.m2(); - // | // prints: - // | // A.m2 - // | // B.m2 - - // crack parameters - if(typeof className != "string"){ - props = superclass; - superclass = className; - className = ""; - } - props = props || {}; - - var proto, i, t, ctor, name, bases, chains, mixins = 1, parents = superclass; - - // build a prototype - if(opts.call(superclass) == "[object Array]"){ - // C3 MRO - bases = c3mro(superclass, className); - t = bases[0]; - mixins = bases.length - t; - superclass = bases[mixins]; - }else{ - bases = [0]; - if(superclass){ - if(opts.call(superclass) == "[object Function]"){ - t = superclass._meta; - bases = bases.concat(t ? t.bases : superclass); - }else{ - err("base class is not a callable constructor.", className); - } - }else if(superclass !== null){ - err("unknown base class. Did you use dojo.require to pull it in?", className); - } - } - if(superclass){ - for(i = mixins - 1;; --i){ - proto = forceNew(superclass); - if(!i){ - // stop if nothing to add (the last base) - break; - } - // mix in properties - t = bases[i]; - (t._meta ? mixOwn : mix)(proto, t.prototype); - // chain in new constructor - ctor = new Function; - ctor.superclass = superclass; - ctor.prototype = proto; - superclass = proto.constructor = ctor; - } - }else{ - proto = {}; - } - // add all properties - declare.safeMixin(proto, props); - // add constructor - t = props.constructor; - if(t !== op.constructor){ - t.nom = cname; - proto.constructor = t; - } - - // collect chains and flags - for(i = mixins - 1; i; --i){ // intentional assignment - t = bases[i]._meta; - if(t && t.chains){ - chains = mix(chains || {}, t.chains); - } - } - if(proto["-chains-"]){ - chains = mix(chains || {}, proto["-chains-"]); - } - - // build ctor - t = !chains || !chains.hasOwnProperty(cname); - bases[0] = ctor = (chains && chains.constructor === "manual") ? simpleConstructor(bases) : - (bases.length == 1 ? singleConstructor(props.constructor, t) : chainedConstructor(bases, t)); - - // add meta information to the constructor - ctor._meta = {bases: bases, hidden: props, chains: chains, - parents: parents, ctor: props.constructor}; - ctor.superclass = superclass && superclass.prototype; - ctor.extend = extend; - ctor.createSubclass = createSubclass; - ctor.prototype = proto; - proto.constructor = ctor; - - // add "standard" methods to the prototype - proto.getInherited = getInherited; - proto.isInstanceOf = isInstanceOf; - proto.inherited = inheritedImpl; - proto.__inherited = inherited; - - // add name if specified - if(className){ - proto.declaredClass = className; - lang.setObject(className, ctor); - } - - // build chains and add them to the prototype - if(chains){ - for(name in chains){ - if(proto[name] && typeof chains[name] == "string" && name != cname){ - t = proto[name] = chain(name, bases, chains[name] === "after"); - t.nom = name; - } - } - } - // chained methods do not return values - // no need to chain "invisible" functions - - return ctor; // Function - } - - /*===== - declare.__DeclareCreatedObject = { - // summary: - // dojo/_base/declare() returns a constructor `C`. `new C()` returns an Object with the following - // methods, in addition to the methods and properties specified via the arguments passed to declare(). - - inherited: function(name, args, newArgs){ - // summary: - // Calls a super method. - // name: String? - // The optional method name. Should be the same as the caller's - // name. Usually "name" is specified in complex dynamic cases, when - // the calling method was dynamically added, undecorated by - // declare(), and it cannot be determined. - // args: Arguments - // The caller supply this argument, which should be the original - // "arguments". - // newArgs: Object? - // If "true", the found function will be returned without - // executing it. - // If Array, it will be used to call a super method. Otherwise - // "args" will be used. - // returns: - // Whatever is returned by a super method, or a super method itself, - // if "true" was specified as newArgs. - // description: - // This method is used inside method of classes produced with - // declare() to call a super method (next in the chain). It is - // used for manually controlled chaining. Consider using the regular - // chaining, because it is faster. Use "this.inherited()" only in - // complex cases. - // - // This method cannot me called from automatically chained - // constructors including the case of a special (legacy) - // constructor chaining. It cannot be called from chained methods. - // - // If "this.inherited()" cannot find the next-in-chain method, it - // does nothing and returns "undefined". The last method in chain - // can be a default method implemented in Object, which will be - // called last. - // - // If "name" is specified, it is assumed that the method that - // received "args" is the parent method for this call. It is looked - // up in the chain list and if it is found the next-in-chain method - // is called. If it is not found, the first-in-chain method is - // called. - // - // If "name" is not specified, it will be derived from the calling - // method (using a methoid property "nom"). - // - // example: - // | var B = declare(A, { - // | method1: function(a, b, c){ - // | this.inherited(arguments); - // | }, - // | method2: function(a, b){ - // | return this.inherited(arguments, [a + b]); - // | } - // | }); - // | // next method is not in the chain list because it is added - // | // manually after the class was created. - // | B.prototype.method3 = function(){ - // | console.log("This is a dynamically-added method."); - // | this.inherited("method3", arguments); - // | }; - // example: - // | var B = declare(A, { - // | method: function(a, b){ - // | var super = this.inherited(arguments, true); - // | // ... - // | if(!super){ - // | console.log("there is no super method"); - // | return 0; - // | } - // | return super.apply(this, arguments); - // | } - // | }); - return {}; // Object - }, - - getInherited: function(name, args){ - // summary: - // Returns a super method. - // name: String? - // The optional method name. Should be the same as the caller's - // name. Usually "name" is specified in complex dynamic cases, when - // the calling method was dynamically added, undecorated by - // declare(), and it cannot be determined. - // args: Arguments - // The caller supply this argument, which should be the original - // "arguments". - // returns: - // Returns a super method (Function) or "undefined". - // description: - // This method is a convenience method for "this.inherited()". - // It uses the same algorithm but instead of executing a super - // method, it returns it, or "undefined" if not found. - // - // example: - // | var B = declare(A, { - // | method: function(a, b){ - // | var super = this.getInherited(arguments); - // | // ... - // | if(!super){ - // | console.log("there is no super method"); - // | return 0; - // | } - // | return super.apply(this, arguments); - // | } - // | }); - return {}; // Object - }, - - isInstanceOf: function(cls){ - // summary: - // Checks the inheritance chain to see if it is inherited from this - // class. - // cls: Function - // Class constructor. - // returns: - // "true", if this object is inherited from this class, "false" - // otherwise. - // description: - // This method is used with instances of classes produced with - // declare() to determine of they support a certain interface or - // not. It models "instanceof" operator. - // - // example: - // | var A = declare(null, { - // | // constructor, properties, and methods go here - // | // ... - // | }); - // | var B = declare(null, { - // | // constructor, properties, and methods go here - // | // ... - // | }); - // | var C = declare([A, B], { - // | // constructor, properties, and methods go here - // | // ... - // | }); - // | var D = declare(A, { - // | // constructor, properties, and methods go here - // | // ... - // | }); - // | - // | var a = new A(), b = new B(), c = new C(), d = new D(); - // | - // | console.log(a.isInstanceOf(A)); // true - // | console.log(b.isInstanceOf(A)); // false - // | console.log(c.isInstanceOf(A)); // true - // | console.log(d.isInstanceOf(A)); // true - // | - // | console.log(a.isInstanceOf(B)); // false - // | console.log(b.isInstanceOf(B)); // true - // | console.log(c.isInstanceOf(B)); // true - // | console.log(d.isInstanceOf(B)); // false - // | - // | console.log(a.isInstanceOf(C)); // false - // | console.log(b.isInstanceOf(C)); // false - // | console.log(c.isInstanceOf(C)); // true - // | console.log(d.isInstanceOf(C)); // false - // | - // | console.log(a.isInstanceOf(D)); // false - // | console.log(b.isInstanceOf(D)); // false - // | console.log(c.isInstanceOf(D)); // false - // | console.log(d.isInstanceOf(D)); // true - return {}; // Object - }, - - extend: function(source){ - // summary: - // Adds all properties and methods of source to constructor's - // prototype, making them available to all instances created with - // constructor. This method is specific to constructors created with - // declare(). - // source: Object - // Source object which properties are going to be copied to the - // constructor's prototype. - // description: - // Adds source properties to the constructor's prototype. It can - // override existing properties. - // - // This method is similar to dojo.extend function, but it is specific - // to constructors produced by declare(). It is implemented - // using dojo.safeMixin, and it skips a constructor property, - // and properly decorates copied functions. - // - // example: - // | var A = declare(null, { - // | m1: function(){}, - // | s1: "Popokatepetl" - // | }); - // | A.extend({ - // | m1: function(){}, - // | m2: function(){}, - // | f1: true, - // | d1: 42 - // | }); - }, - - createSubclass: function(mixins, props){ - // summary: - // Create a subclass of the declared class from a list of base classes. - // mixins: Function[] - // Specifies a list of bases (the left-most one is the most deepest - // base). - // props: Object? - // An optional object whose properties are copied to the created prototype. - // returns: dojo/_base/declare.__DeclareCreatedObject - // New constructor function. - // description: - // Create a constructor using a compact notation for inheritance and - // prototype extension. - // - // Mixin ancestors provide a type of multiple inheritance. - // Prototypes of mixin ancestors are copied to the new class: - // changes to mixin prototypes will not affect classes to which - // they have been mixed in. - // - // example: - // | var A = declare(null, { - // | m1: function(){}, - // | s1: "bar" - // | }); - // | var B = declare(null, { - // | m2: function(){}, - // | s2: "foo" - // | }); - // | var C = declare(null, { - // | }); - // | var D1 = A.createSubclass([B, C], { - // | m1: function(){}, - // | d1: 42 - // | }); - // | var d1 = new D1(); - // | - // | // this is equivalent to: - // | var D2 = declare([A, B, C], { - // | m1: function(){}, - // | d1: 42 - // | }); - // | var d2 = new D2(); - } - }; - =====*/ - - // For back-compat, remove for 2.0 - dojo.safeMixin = declare.safeMixin = safeMixin; - dojo.declare = declare; - - return declare; -}); - -}, -'dojo/dom':function(){ -define(["./sniff", "./_base/window"], - function(has, win){ - // module: - // dojo/dom - - // FIXME: need to add unit tests for all the semi-public methods - - if(has("ie") <= 7){ - try{ - document.execCommand("BackgroundImageCache", false, true); - }catch(e){ - // sane browsers don't have cache "issues" - } - } - - // ============================= - // DOM Functions - // ============================= - - // the result object - var dom = { - // summary: - // This module defines the core dojo DOM API. - }; - - if(has("ie")){ - dom.byId = function(id, doc){ - if(typeof id != "string"){ - return id; - } - var _d = doc || win.doc, te = id && _d.getElementById(id); - // attributes.id.value is better than just id in case the - // user has a name=id inside a form - if(te && (te.attributes.id.value == id || te.id == id)){ - return te; - }else{ - var eles = _d.all[id]; - if(!eles || eles.nodeName){ - eles = [eles]; - } - // if more than 1, choose first with the correct id - var i = 0; - while((te = eles[i++])){ - if((te.attributes && te.attributes.id && te.attributes.id.value == id) || te.id == id){ - return te; - } - } - } - }; - }else{ - dom.byId = function(id, doc){ - // inline'd type check. - // be sure to return null per documentation, to match IE branch. - return ((typeof id == "string") ? (doc || win.doc).getElementById(id) : id) || null; // DOMNode - }; - } - /*===== - dom.byId = function(id, doc){ - // summary: - // Returns DOM node with matching `id` attribute or falsy value (ex: null or undefined) - // if not found. If `id` is a DomNode, this function is a no-op. - // - // id: String|DOMNode - // A string to match an HTML id attribute or a reference to a DOM Node - // - // doc: Document? - // Document to work in. Defaults to the current value of - // dojo/_base/window.doc. Can be used to retrieve - // node references from other documents. - // - // example: - // Look up a node by ID: - // | require(["dojo/dom"], function(dom){ - // | var n = dom.byId("foo"); - // | }); - // - // example: - // Check if a node exists, and use it. - // | require(["dojo/dom"], function(dom){ - // | var n = dom.byId("bar"); - // | if(n){ doStuff() ... } - // | }); - // - // example: - // Allow string or DomNode references to be passed to a custom function: - // | require(["dojo/dom"], function(dom){ - // | var foo = function(nodeOrId){ - // | nodeOrId = dom.byId(nodeOrId); - // | // ... more stuff - // | } - // | }); - }; - =====*/ - - dom.isDescendant = function(/*DOMNode|String*/ node, /*DOMNode|String*/ ancestor){ - // summary: - // Returns true if node is a descendant of ancestor - // node: DOMNode|String - // string id or node reference to test - // ancestor: DOMNode|String - // string id or node reference of potential parent to test against - // - // example: - // Test is node id="bar" is a descendant of node id="foo" - // | require(["dojo/dom"], function(dom){ - // | if(dom.isDescendant("bar", "foo")){ ... } - // | }); - - try{ - node = dom.byId(node); - ancestor = dom.byId(ancestor); - while(node){ - if(node == ancestor){ - return true; // Boolean - } - node = node.parentNode; - } - }catch(e){ /* squelch, return false */ } - return false; // Boolean - }; - - - // TODO: do we need setSelectable in the base? - - // Add feature test for user-select CSS property - // (currently known to work in all but IE < 10 and Opera) - // TODO: The user-select CSS property as of May 2014 is no longer part of - // any CSS specification. In IE, -ms-user-select does not do the same thing - // as the unselectable attribute on elements; namely, dijit Editor buttons - // do not properly prevent the content of the editable content frame from - // unblurring. As a result, the -ms- prefixed version is omitted here. - has.add("css-user-select", function(global, doc, element){ - // Avoid exception when dom.js is loaded in non-browser environments - if(!element){ return false; } - - var style = element.style; - var prefixes = ["Khtml", "O", "Moz", "Webkit"], - i = prefixes.length, - name = "userSelect", - prefix; - - // Iterate prefixes from most to least likely - do{ - if(typeof style[name] !== "undefined"){ - // Supported; return property name - return name; - } - }while(i-- && (name = prefixes[i] + "UserSelect")); - - // Not supported if we didn't return before now - return false; - }); - - /*===== - dom.setSelectable = function(node, selectable){ - // summary: - // Enable or disable selection on a node - // node: DOMNode|String - // id or reference to node - // selectable: Boolean - // state to put the node in. false indicates unselectable, true - // allows selection. - // example: - // Make the node id="bar" unselectable - // | require(["dojo/dom"], function(dom){ - // | dom.setSelectable("bar"); - // | }); - // example: - // Make the node id="bar" selectable - // | require(["dojo/dom"], function(dom){ - // | dom.setSelectable("bar", true); - // | }); - }; - =====*/ - - var cssUserSelect = has("css-user-select"); - dom.setSelectable = cssUserSelect ? function(node, selectable){ - // css-user-select returns a (possibly vendor-prefixed) CSS property name - dom.byId(node).style[cssUserSelect] = selectable ? "" : "none"; - } : function(node, selectable){ - node = dom.byId(node); - - // (IE < 10 / Opera) Fall back to setting/removing the - // unselectable attribute on the element and all its children - var nodes = node.getElementsByTagName("*"), - i = nodes.length; - - if(selectable){ - node.removeAttribute("unselectable"); - while(i--){ - nodes[i].removeAttribute("unselectable"); - } - }else{ - node.setAttribute("unselectable", "on"); - while(i--){ - nodes[i].setAttribute("unselectable", "on"); - } - } - }; - - return dom; -}); - -}, -'dojo/_base/browser':function(){ -if(require.has){ - require.has.add("config-selectorEngine", "acme"); -} -define([ - "../ready", - "./kernel", - "./connect", // until we decide if connect is going back into non-browser environments - "./unload", - "./window", - "./event", - "./html", - "./NodeList", - "../query", - "./xhr", - "./fx"], function(dojo){ - - // module: - // dojo/_base/browser - - /*===== - return { - // summary: - // This module causes the browser-only base modules to be loaded. - }; - =====*/ - - return dojo; -}); - -}, -'dojo/selector/acme':function(){ -define([ - "../dom", "../sniff", "../_base/array", "../_base/lang", "../_base/window" -], function(dom, has, array, lang, win){ - - // module: - // dojo/selector/acme - -/* - acme architectural overview: - - acme is a relatively full-featured CSS3 query library. It is - designed to take any valid CSS3 selector and return the nodes matching - the selector. To do this quickly, it processes queries in several - steps, applying caching where profitable. - - The steps (roughly in reverse order of the way they appear in the code): - 1.) check to see if we already have a "query dispatcher" - - if so, use that with the given parameterization. Skip to step 4. - 2.) attempt to determine which branch to dispatch the query to: - - JS (optimized DOM iteration) - - native (FF3.1+, Safari 3.1+, IE 8+) - 3.) tokenize and convert to executable "query dispatcher" - - this is where the lion's share of the complexity in the - system lies. In the DOM version, the query dispatcher is - assembled as a chain of "yes/no" test functions pertaining to - a section of a simple query statement (".blah:nth-child(odd)" - but not "div div", which is 2 simple statements). Individual - statement dispatchers are cached (to prevent re-definition) - as are entire dispatch chains (to make re-execution of the - same query fast) - 4.) the resulting query dispatcher is called in the passed scope - (by default the top-level document) - - for DOM queries, this results in a recursive, top-down - evaluation of nodes based on each simple query section - - for native implementations, this may mean working around spec - bugs. So be it. - 5.) matched nodes are pruned to ensure they are unique (if necessary) -*/ - - - //////////////////////////////////////////////////////////////////////// - // Toolkit aliases - //////////////////////////////////////////////////////////////////////// - - // if you are extracting acme for use in your own system, you will - // need to provide these methods and properties. No other porting should be - // necessary, save for configuring the system to use a class other than - // dojo/NodeList as the return instance instantiator - var trim = lang.trim; - var each = array.forEach; - - var getDoc = function(){ return win.doc; }; - // NOTE(alex): the spec is idiotic. CSS queries should ALWAYS be case-sensitive, but nooooooo - var cssCaseBug = (getDoc().compatMode) == "BackCompat"; - - //////////////////////////////////////////////////////////////////////// - // Global utilities - //////////////////////////////////////////////////////////////////////// - - - var specials = ">~+"; - - // global thunk to determine whether we should treat the current query as - // case sensitive or not. This switch is flipped by the query evaluator - // based on the document passed as the context to search. - var caseSensitive = false; - - // how high? - var yesman = function(){ return true; }; - - //////////////////////////////////////////////////////////////////////// - // Tokenizer - //////////////////////////////////////////////////////////////////////// - - var getQueryParts = function(query){ - // summary: - // state machine for query tokenization - // description: - // instead of using a brittle and slow regex-based CSS parser, - // acme implements an AST-style query representation. This - // representation is only generated once per query. For example, - // the same query run multiple times or under different root nodes - // does not re-parse the selector expression but instead uses the - // cached data structure. The state machine implemented here - // terminates on the last " " (space) character and returns an - // ordered array of query component structures (or "parts"). Each - // part represents an operator or a simple CSS filtering - // expression. The structure for parts is documented in the code - // below. - - - // NOTE: - // this code is designed to run fast and compress well. Sacrifices - // to readability and maintainability have been made. Your best - // bet when hacking the tokenizer is to put The Donnas on *really* - // loud (may we recommend their "Spend The Night" release?) and - // just assume you're gonna make mistakes. Keep the unit tests - // open and run them frequently. Knowing is half the battle ;-) - if(specials.indexOf(query.slice(-1)) >= 0){ - // if we end with a ">", "+", or "~", that means we're implicitly - // searching all children, so make it explicit - query += " * "; - }else{ - // if you have not provided a terminator, one will be provided for - // you... - query += " "; - } - - var ts = function(/*Integer*/ s, /*Integer*/ e){ - // trim and slice. - - // take an index to start a string slice from and an end position - // and return a trimmed copy of that sub-string - return trim(query.slice(s, e)); - }; - - // the overall data graph of the full query, as represented by queryPart objects - var queryParts = []; - - - // state keeping vars - var inBrackets = -1, inParens = -1, inMatchFor = -1, - inPseudo = -1, inClass = -1, inId = -1, inTag = -1, currentQuoteChar, - lc = "", cc = "", pStart; - - // iteration vars - var x = 0, // index in the query - ql = query.length, - currentPart = null, // data structure representing the entire clause - _cp = null; // the current pseudo or attr matcher - - // several temporary variables are assigned to this structure during a - // potential sub-expression match: - // attr: - // a string representing the current full attribute match in a - // bracket expression - // type: - // if there's an operator in a bracket expression, this is - // used to keep track of it - // value: - // the internals of parenthetical expression for a pseudo. for - // :nth-child(2n+1), value might be "2n+1" - - var endTag = function(){ - // called when the tokenizer hits the end of a particular tag name. - // Re-sets state variables for tag matching and sets up the matcher - // to handle the next type of token (tag or operator). - if(inTag >= 0){ - var tv = (inTag == x) ? null : ts(inTag, x); // .toLowerCase(); - currentPart[ (specials.indexOf(tv) < 0) ? "tag" : "oper" ] = tv; - inTag = -1; - } - }; - - var endId = function(){ - // called when the tokenizer might be at the end of an ID portion of a match - if(inId >= 0){ - currentPart.id = ts(inId, x).replace(/\\/g, ""); - inId = -1; - } - }; - - var endClass = function(){ - // called when the tokenizer might be at the end of a class name - // match. CSS allows for multiple classes, so we augment the - // current item with another class in its list - if(inClass >= 0){ - currentPart.classes.push(ts(inClass + 1, x).replace(/\\/g, "")); - inClass = -1; - } - }; - - var endAll = function(){ - // at the end of a simple fragment, so wall off the matches - endId(); - endTag(); - endClass(); - }; - - var endPart = function(){ - endAll(); - if(inPseudo >= 0){ - currentPart.pseudos.push({ name: ts(inPseudo + 1, x) }); - } - // hint to the selector engine to tell it whether or not it - // needs to do any iteration. Many simple selectors don't, and - // we can avoid significant construction-time work by advising - // the system to skip them - currentPart.loops = ( - currentPart.pseudos.length || - currentPart.attrs.length || - currentPart.classes.length ); - - currentPart.oquery = currentPart.query = ts(pStart, x); // save the full expression as a string - - - // otag/tag are hints to suggest to the system whether or not - // it's an operator or a tag. We save a copy of otag since the - // tag name is cast to upper-case in regular HTML matches. The - // system has a global switch to figure out if the current - // expression needs to be case sensitive or not and it will use - // otag or tag accordingly - currentPart.otag = currentPart.tag = (currentPart["oper"]) ? null : (currentPart.tag || "*"); - - if(currentPart.tag){ - // if we're in a case-insensitive HTML doc, we likely want - // the toUpperCase when matching on element.tagName. If we - // do it here, we can skip the string op per node - // comparison - currentPart.tag = currentPart.tag.toUpperCase(); - } - - // add the part to the list - if(queryParts.length && (queryParts[queryParts.length-1].oper)){ - // operators are always infix, so we remove them from the - // list and attach them to the next match. The evaluator is - // responsible for sorting out how to handle them. - currentPart.infixOper = queryParts.pop(); - currentPart.query = currentPart.infixOper.query + " " + currentPart.query; - /* - console.debug( "swapping out the infix", - currentPart.infixOper, - "and attaching it to", - currentPart); - */ - } - queryParts.push(currentPart); - - currentPart = null; - }; - - // iterate over the query, character by character, building up a - // list of query part objects - for(; lc=cc, cc=query.charAt(x), x < ql; x++){ - // cc: the current character in the match - // lc: the last character (if any) - - // someone is trying to escape something, so don't try to match any - // fragments. We assume we're inside a literal. - if(lc == "\\"){ continue; } - if(!currentPart){ // a part was just ended or none has yet been created - // NOTE: I hate all this alloc, but it's shorter than writing tons of if's - pStart = x; - // rules describe full CSS sub-expressions, like: - // #someId - // .className:first-child - // but not: - // thinger > div.howdy[type=thinger] - // the indidual components of the previous query would be - // split into 3 parts that would be represented a structure like: - // [ - // { - // query: "thinger", - // tag: "thinger", - // }, - // { - // query: "div.howdy[type=thinger]", - // classes: ["howdy"], - // infixOper: { - // query: ">", - // oper: ">", - // } - // }, - // ] - currentPart = { - query: null, // the full text of the part's rule - pseudos: [], // CSS supports multiple pseud-class matches in a single rule - attrs: [], // CSS supports multi-attribute match, so we need an array - classes: [], // class matches may be additive, e.g.: .thinger.blah.howdy - tag: null, // only one tag... - oper: null, // ...or operator per component. Note that these wind up being exclusive. - id: null, // the id component of a rule - getTag: function(){ - return caseSensitive ? this.otag : this.tag; - } - }; - - // if we don't have a part, we assume we're going to start at - // the beginning of a match, which should be a tag name. This - // might fault a little later on, but we detect that and this - // iteration will still be fine. - inTag = x; - } - - // Skip processing all quoted characters. - // If we are inside quoted text then currentQuoteChar stores the character that began the quote, - // thus that character that will end it. - if(currentQuoteChar){ - if(cc == currentQuoteChar){ - currentQuoteChar = null; - } - continue; - }else if (cc == "'" || cc == '"'){ - currentQuoteChar = cc; - continue; - } - - if(inBrackets >= 0){ - // look for a the close first - if(cc == "]"){ // if we're in a [...] clause and we end, do assignment - if(!_cp.attr){ - // no attribute match was previously begun, so we - // assume this is an attribute existence match in the - // form of [someAttributeName] - _cp.attr = ts(inBrackets+1, x); - }else{ - // we had an attribute already, so we know that we're - // matching some sort of value, as in [attrName=howdy] - _cp.matchFor = ts((inMatchFor||inBrackets+1), x); - } - var cmf = _cp.matchFor; - if(cmf){ - // try to strip quotes from the matchFor value. We want - // [attrName=howdy] to match the same - // as [attrName = 'howdy' ] - if( (cmf.charAt(0) == '"') || (cmf.charAt(0) == "'") ){ - _cp.matchFor = cmf.slice(1, -1); - } - } - // remove backslash escapes from an attribute match, since DOM - // querying will get attribute values without backslashes - if(_cp.matchFor){ - _cp.matchFor = _cp.matchFor.replace(/\\/g, ""); - } - - // end the attribute by adding it to the list of attributes. - currentPart.attrs.push(_cp); - _cp = null; // necessary? - inBrackets = inMatchFor = -1; - }else if(cc == "="){ - // if the last char was an operator prefix, make sure we - // record it along with the "=" operator. - var addToCc = ("|~^$*".indexOf(lc) >=0 ) ? lc : ""; - _cp.type = addToCc+cc; - _cp.attr = ts(inBrackets+1, x-addToCc.length); - inMatchFor = x+1; - } - // now look for other clause parts - }else if(inParens >= 0){ - // if we're in a parenthetical expression, we need to figure - // out if it's attached to a pseudo-selector rule like - // :nth-child(1) - if(cc == ")"){ - if(inPseudo >= 0){ - _cp.value = ts(inParens+1, x); - } - inPseudo = inParens = -1; - } - }else if(cc == "#"){ - // start of an ID match - endAll(); - inId = x+1; - }else if(cc == "."){ - // start of a class match - endAll(); - inClass = x; - }else if(cc == ":"){ - // start of a pseudo-selector match - endAll(); - inPseudo = x; - }else if(cc == "["){ - // start of an attribute match. - endAll(); - inBrackets = x; - // provide a new structure for the attribute match to fill-in - _cp = { - /*===== - attr: null, type: null, matchFor: null - =====*/ - }; - }else if(cc == "("){ - // we really only care if we've entered a parenthetical - // expression if we're already inside a pseudo-selector match - if(inPseudo >= 0){ - // provide a new structure for the pseudo match to fill-in - _cp = { - name: ts(inPseudo+1, x), - value: null - }; - currentPart.pseudos.push(_cp); - } - inParens = x; - }else if( - (cc == " ") && - // if it's a space char and the last char is too, consume the - // current one without doing more work - (lc != cc) - ){ - endPart(); - } - } - return queryParts; - }; - - - //////////////////////////////////////////////////////////////////////// - // DOM query infrastructure - //////////////////////////////////////////////////////////////////////// - - var agree = function(first, second){ - // the basic building block of the yes/no chaining system. agree(f1, - // f2) generates a new function which returns the boolean results of - // both of the passed functions to a single logical-anded result. If - // either are not passed, the other is used exclusively. - if(!first){ return second; } - if(!second){ return first; } - - return function(){ - return first.apply(window, arguments) && second.apply(window, arguments); - }; - }; - - var getArr = function(i, arr){ - // helps us avoid array alloc when we don't need it - var r = arr||[]; // FIXME: should this be 'new d._NodeListCtor()' ? - if(i){ r.push(i); } - return r; - }; - - var _isElement = function(n){ return (1 == n.nodeType); }; - - // FIXME: need to coalesce _getAttr with defaultGetter - var blank = ""; - var _getAttr = function(elem, attr){ - if(!elem){ return blank; } - if(attr == "class"){ - return elem.className || blank; - } - if(attr == "for"){ - return elem.htmlFor || blank; - } - if(attr == "style"){ - return elem.style.cssText || blank; - } - return (caseSensitive ? elem.getAttribute(attr) : elem.getAttribute(attr, 2)) || blank; - }; - - var attrs = { - "*=": function(attr, value){ - return function(elem){ - // E[foo*="bar"] - // an E element whose "foo" attribute value contains - // the substring "bar" - return (_getAttr(elem, attr).indexOf(value)>=0); - }; - }, - "^=": function(attr, value){ - // E[foo^="bar"] - // an E element whose "foo" attribute value begins exactly - // with the string "bar" - return function(elem){ - return (_getAttr(elem, attr).indexOf(value)==0); - }; - }, - "$=": function(attr, value){ - // E[foo$="bar"] - // an E element whose "foo" attribute value ends exactly - // with the string "bar" - return function(elem){ - var ea = " "+_getAttr(elem, attr); - var lastIndex = ea.lastIndexOf(value); - return lastIndex > -1 && (lastIndex==(ea.length-value.length)); - }; - }, - "~=": function(attr, value){ - // E[foo~="bar"] - // an E element whose "foo" attribute value is a list of - // space-separated values, one of which is exactly equal - // to "bar" - - // return "[contains(concat(' ',@"+attr+",' '), ' "+ value +" ')]"; - var tval = " "+value+" "; - return function(elem){ - var ea = " "+_getAttr(elem, attr)+" "; - return (ea.indexOf(tval)>=0); - }; - }, - "|=": function(attr, value){ - // E[hreflang|="en"] - // an E element whose "hreflang" attribute has a - // hyphen-separated list of values beginning (from the - // left) with "en" - var valueDash = value+"-"; - return function(elem){ - var ea = _getAttr(elem, attr); - return ( - (ea == value) || - (ea.indexOf(valueDash)==0) - ); - }; - }, - "=": function(attr, value){ - return function(elem){ - return (_getAttr(elem, attr) == value); - }; - } - }; - - // avoid testing for node type if we can. Defining this in the negative - // here to avoid negation in the fast path. - var _noNES = (typeof getDoc().firstChild.nextElementSibling == "undefined"); - var _ns = !_noNES ? "nextElementSibling" : "nextSibling"; - var _ps = !_noNES ? "previousElementSibling" : "previousSibling"; - var _simpleNodeTest = (_noNES ? _isElement : yesman); - - var _lookLeft = function(node){ - // look left - while(node = node[_ps]){ - if(_simpleNodeTest(node)){ return false; } - } - return true; - }; - - var _lookRight = function(node){ - // look right - while(node = node[_ns]){ - if(_simpleNodeTest(node)){ return false; } - } - return true; - }; - - var getNodeIndex = function(node){ - var root = node.parentNode; - root = root.nodeType != 7 ? root : root.nextSibling; // PROCESSING_INSTRUCTION_NODE - var i = 0, - tret = root.children || root.childNodes, - ci = (node["_i"]||node.getAttribute("_i")||-1), - cl = (root["_l"]|| (typeof root.getAttribute !== "undefined" ? root.getAttribute("_l") : -1)); - - if(!tret){ return -1; } - var l = tret.length; - - // we calculate the parent length as a cheap way to invalidate the - // cache. It's not 100% accurate, but it's much more honest than what - // other libraries do - if( cl == l && ci >= 0 && cl >= 0 ){ - // if it's legit, tag and release - return ci; - } - - // else re-key things - if(has("ie") && typeof root.setAttribute !== "undefined"){ - root.setAttribute("_l", l); - }else{ - root["_l"] = l; - } - ci = -1; - for(var te = root["firstElementChild"]||root["firstChild"]; te; te = te[_ns]){ - if(_simpleNodeTest(te)){ - if(has("ie")){ - te.setAttribute("_i", ++i); - }else{ - te["_i"] = ++i; - } - if(node === te){ - // NOTE: - // shortcutting the return at this step in indexing works - // very well for benchmarking but we avoid it here since - // it leads to potential O(n^2) behavior in sequential - // getNodexIndex operations on a previously un-indexed - // parent. We may revisit this at a later time, but for - // now we just want to get the right answer more often - // than not. - ci = i; - } - } - } - return ci; - }; - - var isEven = function(elem){ - return !((getNodeIndex(elem)) % 2); - }; - - var isOdd = function(elem){ - return ((getNodeIndex(elem)) % 2); - }; - - var pseudos = { - "checked": function(name, condition){ - return function(elem){ - return !!("checked" in elem ? elem.checked : elem.selected); - }; - }, - "disabled": function(name, condition){ - return function(elem){ - return elem.disabled; - }; - }, - "enabled": function(name, condition){ - return function(elem){ - return !elem.disabled; - }; - }, - "first-child": function(){ return _lookLeft; }, - "last-child": function(){ return _lookRight; }, - "only-child": function(name, condition){ - return function(node){ - return _lookLeft(node) && _lookRight(node); - }; - }, - "empty": function(name, condition){ - return function(elem){ - // DomQuery and jQuery get this wrong, oddly enough. - // The CSS 3 selectors spec is pretty explicit about it, too. - var cn = elem.childNodes; - var cnl = elem.childNodes.length; - // if(!cnl){ return true; } - for(var x=cnl-1; x >= 0; x--){ - var nt = cn[x].nodeType; - if((nt === 1)||(nt == 3)){ return false; } - } - return true; - }; - }, - "contains": function(name, condition){ - var cz = condition.charAt(0); - if( cz == '"' || cz == "'" ){ //remove quote - condition = condition.slice(1, -1); - } - return function(elem){ - return (elem.innerHTML.indexOf(condition) >= 0); - }; - }, - "not": function(name, condition){ - var p = getQueryParts(condition)[0]; - var ignores = { el: 1 }; - if(p.tag != "*"){ - ignores.tag = 1; - } - if(!p.classes.length){ - ignores.classes = 1; - } - var ntf = getSimpleFilterFunc(p, ignores); - return function(elem){ - return (!ntf(elem)); - }; - }, - "nth-child": function(name, condition){ - var pi = parseInt; - // avoid re-defining function objects if we can - if(condition == "odd"){ - return isOdd; - }else if(condition == "even"){ - return isEven; - } - // FIXME: can we shorten this? - if(condition.indexOf("n") != -1){ - var tparts = condition.split("n", 2); - var pred = tparts[0] ? ((tparts[0] == '-') ? -1 : pi(tparts[0])) : 1; - var idx = tparts[1] ? pi(tparts[1]) : 0; - var lb = 0, ub = -1; - if(pred > 0){ - if(idx < 0){ - idx = (idx % pred) && (pred + (idx % pred)); - }else if(idx>0){ - if(idx >= pred){ - lb = idx - idx % pred; - } - idx = idx % pred; - } - }else if(pred<0){ - pred *= -1; - // idx has to be greater than 0 when pred is negative; - // shall we throw an error here? - if(idx > 0){ - ub = idx; - idx = idx % pred; - } - } - if(pred > 0){ - return function(elem){ - var i = getNodeIndex(elem); - return (i>=lb) && (ub<0 || i<=ub) && ((i % pred) == idx); - }; - }else{ - condition = idx; - } - } - var ncount = pi(condition); - return function(elem){ - return (getNodeIndex(elem) == ncount); - }; - } - }; - - var defaultGetter = (has("ie") < 9 || has("ie") == 9 && has("quirks")) ? function(cond){ - var clc = cond.toLowerCase(); - if(clc == "class"){ cond = "className"; } - return function(elem){ - return (caseSensitive ? elem.getAttribute(cond) : elem[cond]||elem[clc]); - }; - } : function(cond){ - return function(elem){ - return (elem && elem.getAttribute && elem.hasAttribute(cond)); - }; - }; - - var getSimpleFilterFunc = function(query, ignores){ - // generates a node tester function based on the passed query part. The - // query part is one of the structures generated by the query parser - // when it creates the query AST. The "ignores" object specifies which - // (if any) tests to skip, allowing the system to avoid duplicating - // work where it may have already been taken into account by other - // factors such as how the nodes to test were fetched in the first - // place - if(!query){ return yesman; } - ignores = ignores||{}; - - var ff = null; - - if(!("el" in ignores)){ - ff = agree(ff, _isElement); - } - - if(!("tag" in ignores)){ - if(query.tag != "*"){ - ff = agree(ff, function(elem){ - return (elem && ((caseSensitive ? elem.tagName : elem.tagName.toUpperCase()) == query.getTag())); - }); - } - } - - if(!("classes" in ignores)){ - each(query.classes, function(cname, idx, arr){ - // get the class name - /* - var isWildcard = cname.charAt(cname.length-1) == "*"; - if(isWildcard){ - cname = cname.substr(0, cname.length-1); - } - // I dislike the regex thing, even if memoized in a cache, but it's VERY short - var re = new RegExp("(?:^|\\s)" + cname + (isWildcard ? ".*" : "") + "(?:\\s|$)"); - */ - var re = new RegExp("(?:^|\\s)" + cname + "(?:\\s|$)"); - ff = agree(ff, function(elem){ - return re.test(elem.className); - }); - ff.count = idx; - }); - } - - if(!("pseudos" in ignores)){ - each(query.pseudos, function(pseudo){ - var pn = pseudo.name; - if(pseudos[pn]){ - ff = agree(ff, pseudos[pn](pn, pseudo.value)); - } - }); - } - - if(!("attrs" in ignores)){ - each(query.attrs, function(attr){ - var matcher; - var a = attr.attr; - // type, attr, matchFor - if(attr.type && attrs[attr.type]){ - matcher = attrs[attr.type](a, attr.matchFor); - }else if(a.length){ - matcher = defaultGetter(a); - } - if(matcher){ - ff = agree(ff, matcher); - } - }); - } - - if(!("id" in ignores)){ - if(query.id){ - ff = agree(ff, function(elem){ - return (!!elem && (elem.id == query.id)); - }); - } - } - - if(!ff){ - if(!("default" in ignores)){ - ff = yesman; - } - } - return ff; - }; - - var _nextSibling = function(filterFunc){ - return function(node, ret, bag){ - while(node = node[_ns]){ - if(_noNES && (!_isElement(node))){ continue; } - if( - (!bag || _isUnique(node, bag)) && - filterFunc(node) - ){ - ret.push(node); - } - break; - } - return ret; - }; - }; - - var _nextSiblings = function(filterFunc){ - return function(root, ret, bag){ - var te = root[_ns]; - while(te){ - if(_simpleNodeTest(te)){ - if(bag && !_isUnique(te, bag)){ - break; - } - if(filterFunc(te)){ - ret.push(te); - } - } - te = te[_ns]; - } - return ret; - }; - }; - - // get an array of child *elements*, skipping text and comment nodes - var _childElements = function(filterFunc){ - filterFunc = filterFunc||yesman; - return function(root, ret, bag){ - // get an array of child elements, skipping text and comment nodes - var te, x = 0, tret = root.children || root.childNodes; - while(te = tret[x++]){ - if( - _simpleNodeTest(te) && - (!bag || _isUnique(te, bag)) && - (filterFunc(te, x)) - ){ - ret.push(te); - } - } - return ret; - }; - }; - - // test to see if node is below root - var _isDescendant = function(node, root){ - var pn = node.parentNode; - while(pn){ - if(pn == root){ - break; - } - pn = pn.parentNode; - } - return !!pn; - }; - - var _getElementsFuncCache = {}; - - var getElementsFunc = function(query){ - var retFunc = _getElementsFuncCache[query.query]; - // if we've got a cached dispatcher, just use that - if(retFunc){ return retFunc; } - // else, generate a new on - - // NOTE: - // this function returns a function that searches for nodes and - // filters them. The search may be specialized by infix operators - // (">", "~", or "+") else it will default to searching all - // descendants (the " " selector). Once a group of children is - // found, a test function is applied to weed out the ones we - // don't want. Many common cases can be fast-pathed. We spend a - // lot of cycles to create a dispatcher that doesn't do more work - // than necessary at any point since, unlike this function, the - // dispatchers will be called every time. The logic of generating - // efficient dispatchers looks like this in pseudo code: - // - // # if it's a purely descendant query (no ">", "+", or "~" modifiers) - // if infixOperator == " ": - // if only(id): - // return def(root): - // return d.byId(id, root); - // - // elif id: - // return def(root): - // return filter(d.byId(id, root)); - // - // elif cssClass && getElementsByClassName: - // return def(root): - // return filter(root.getElementsByClassName(cssClass)); - // - // elif only(tag): - // return def(root): - // return root.getElementsByTagName(tagName); - // - // else: - // # search by tag name, then filter - // return def(root): - // return filter(root.getElementsByTagName(tagName||"*")); - // - // elif infixOperator == ">": - // # search direct children - // return def(root): - // return filter(root.children); - // - // elif infixOperator == "+": - // # search next sibling - // return def(root): - // return filter(root.nextElementSibling); - // - // elif infixOperator == "~": - // # search rightward siblings - // return def(root): - // return filter(nextSiblings(root)); - - var io = query.infixOper; - var oper = (io ? io.oper : ""); - // the default filter func which tests for all conditions in the query - // part. This is potentially inefficient, so some optimized paths may - // re-define it to test fewer things. - var filterFunc = getSimpleFilterFunc(query, { el: 1 }); - var qt = query.tag; - var wildcardTag = ("*" == qt); - var ecs = getDoc()["getElementsByClassName"]; - - if(!oper){ - // if there's no infix operator, then it's a descendant query. ID - // and "elements by class name" variants can be accelerated so we - // call them out explicitly: - if(query.id){ - // testing shows that the overhead of yesman() is acceptable - // and can save us some bytes vs. re-defining the function - // everywhere. - filterFunc = (!query.loops && wildcardTag) ? - yesman : - getSimpleFilterFunc(query, { el: 1, id: 1 }); - - retFunc = function(root, arr){ - var te = dom.byId(query.id, (root.ownerDocument||root)); - if(!te || !filterFunc(te)){ return; } - if(9 == root.nodeType){ // if root's a doc, we just return directly - return getArr(te, arr); - }else{ // otherwise check ancestry - if(_isDescendant(te, root)){ - return getArr(te, arr); - } - } - }; - }else if( - ecs && - // isAlien check. Workaround for Prototype.js being totally evil/dumb. - /\{\s*\[native code\]\s*\}/.test(String(ecs)) && - query.classes.length && - !cssCaseBug - ){ - // it's a class-based query and we've got a fast way to run it. - - // ignore class and ID filters since we will have handled both - filterFunc = getSimpleFilterFunc(query, { el: 1, classes: 1, id: 1 }); - var classesString = query.classes.join(" "); - retFunc = function(root, arr, bag){ - var ret = getArr(0, arr), te, x=0; - var tret = root.getElementsByClassName(classesString); - while((te = tret[x++])){ - if(filterFunc(te, root) && _isUnique(te, bag)){ - ret.push(te); - } - } - return ret; - }; - - }else if(!wildcardTag && !query.loops){ - // it's tag only. Fast-path it. - retFunc = function(root, arr, bag){ - var ret = getArr(0, arr), te, x=0; - var tag = query.getTag(), - tret = tag ? root.getElementsByTagName(tag) : []; - while((te = tret[x++])){ - if(_isUnique(te, bag)){ - ret.push(te); - } - } - return ret; - }; - }else{ - // the common case: - // a descendant selector without a fast path. By now it's got - // to have a tag selector, even if it's just "*" so we query - // by that and filter - filterFunc = getSimpleFilterFunc(query, { el: 1, tag: 1, id: 1 }); - retFunc = function(root, arr, bag){ - var ret = getArr(0, arr), te, x=0; - // we use getTag() to avoid case sensitivity issues - var tag = query.getTag(), - tret = tag ? root.getElementsByTagName(tag) : []; - while((te = tret[x++])){ - if(filterFunc(te, root) && _isUnique(te, bag)){ - ret.push(te); - } - } - return ret; - }; - } - }else{ - // the query is scoped in some way. Instead of querying by tag we - // use some other collection to find candidate nodes - var skipFilters = { el: 1 }; - if(wildcardTag){ - skipFilters.tag = 1; - } - filterFunc = getSimpleFilterFunc(query, skipFilters); - if("+" == oper){ - retFunc = _nextSibling(filterFunc); - }else if("~" == oper){ - retFunc = _nextSiblings(filterFunc); - }else if(">" == oper){ - retFunc = _childElements(filterFunc); - } - } - // cache it and return - return _getElementsFuncCache[query.query] = retFunc; - }; - - var filterDown = function(root, queryParts){ - // NOTE: - // this is the guts of the DOM query system. It takes a list of - // parsed query parts and a root and finds children which match - // the selector represented by the parts - var candidates = getArr(root), qp, x, te, qpl = queryParts.length, bag, ret; - - for(var i = 0; i < qpl; i++){ - ret = []; - qp = queryParts[i]; - x = candidates.length - 1; - if(x > 0){ - // if we have more than one root at this level, provide a new - // hash to use for checking group membership but tell the - // system not to post-filter us since we will already have been - // guaranteed to be unique - bag = {}; - ret.nozip = true; - } - var gef = getElementsFunc(qp); - for(var j = 0; (te = candidates[j]); j++){ - // for every root, get the elements that match the descendant - // selector, adding them to the "ret" array and filtering them - // via membership in this level's bag. If there are more query - // parts, then this level's return will be used as the next - // level's candidates - gef(te, ret, bag); - } - if(!ret.length){ break; } - candidates = ret; - } - return ret; - }; - - //////////////////////////////////////////////////////////////////////// - // the query runner - //////////////////////////////////////////////////////////////////////// - - // these are the primary caches for full-query results. The query - // dispatcher functions are generated then stored here for hash lookup in - // the future - var _queryFuncCacheDOM = {}, - _queryFuncCacheQSA = {}; - - // this is the second level of splitting, from full-length queries (e.g., - // "div.foo .bar") into simple query expressions (e.g., ["div.foo", - // ".bar"]) - var getStepQueryFunc = function(query){ - var qparts = getQueryParts(trim(query)); - - // if it's trivial, avoid iteration and zipping costs - if(qparts.length == 1){ - // we optimize this case here to prevent dispatch further down the - // chain, potentially slowing things down. We could more elegantly - // handle this in filterDown(), but it's slower for simple things - // that need to be fast (e.g., "#someId"). - var tef = getElementsFunc(qparts[0]); - return function(root){ - var r = tef(root, []); - if(r){ r.nozip = true; } - return r; - }; - } - - // otherwise, break it up and return a runner that iterates over the parts recursively - return function(root){ - return filterDown(root, qparts); - }; - }; - - // NOTES: - // * we can't trust QSA for anything but document-rooted queries, so - // caching is split into DOM query evaluators and QSA query evaluators - // * caching query results is dirty and leak-prone (or, at a minimum, - // prone to unbounded growth). Other toolkits may go this route, but - // they totally destroy their own ability to manage their memory - // footprint. If we implement it, it should only ever be with a fixed - // total element reference # limit and an LRU-style algorithm since JS - // has no weakref support. Caching compiled query evaluators is also - // potentially problematic, but even on large documents the size of the - // query evaluators is often < 100 function objects per evaluator (and - // LRU can be applied if it's ever shown to be an issue). - // * since IE's QSA support is currently only for HTML documents and even - // then only in IE 8's "standards mode", we have to detect our dispatch - // route at query time and keep 2 separate caches. Ugg. - - // we need to determine if we think we can run a given query via - // querySelectorAll or if we'll need to fall back on DOM queries to get - // there. We need a lot of information about the environment and the query - // to make the determination (e.g. does it support QSA, does the query in - // question work in the native QSA impl, etc.). - - // IE QSA queries may incorrectly include comment nodes, so we throw the - // zipping function into "remove" comments mode instead of the normal "skip - // it" which every other QSA-clued browser enjoys - var noZip = has("ie") ? "commentStrip" : "nozip"; - - var qsa = "querySelectorAll"; - var qsaAvail = !!getDoc()[qsa]; - - //Don't bother with n+3 type of matches, IE complains if we modify those. - var infixSpaceRe = /\\[>~+]|n\+\d|([^ \\])?([>~+])([^ =])?/g; - var infixSpaceFunc = function(match, pre, ch, post){ - return ch ? (pre ? pre + " " : "") + ch + (post ? " " + post : "") : /*n+3*/ match; - }; - - //Don't apply the infixSpaceRe to attribute value selectors - var attRe = /([^[]*)([^\]]*])?/g; - var attFunc = function(match, nonAtt, att){ - return nonAtt.replace(infixSpaceRe, infixSpaceFunc) + (att||""); - }; - var getQueryFunc = function(query, forceDOM){ - //Normalize query. The CSS3 selectors spec allows for omitting spaces around - //infix operators, >, ~ and + - //Do the work here since detection for spaces is used as a simple "not use QSA" - //test below. - query = query.replace(attRe, attFunc); - - if(qsaAvail){ - // if we've got a cached variant and we think we can do it, run it! - var qsaCached = _queryFuncCacheQSA[query]; - if(qsaCached && !forceDOM){ return qsaCached; } - } - - // else if we've got a DOM cached variant, assume that we already know - // all we need to and use it - var domCached = _queryFuncCacheDOM[query]; - if(domCached){ return domCached; } - - // TODO: - // today we're caching DOM and QSA branches separately so we - // recalc useQSA every time. If we had a way to tag root+query - // efficiently, we'd be in good shape to do a global cache. - - var qcz = query.charAt(0); - var nospace = (-1 == query.indexOf(" ")); - - // byId searches are wicked fast compared to QSA, even when filtering - // is required - if( (query.indexOf("#") >= 0) && (nospace) ){ - forceDOM = true; - } - - var useQSA = ( - qsaAvail && (!forceDOM) && - // as per CSS 3, we can't currently start w/ combinator: - // http://www.w3.org/TR/css3-selectors/#w3cselgrammar - (specials.indexOf(qcz) == -1) && - // IE's QSA impl sucks on pseudos - (!has("ie") || (query.indexOf(":") == -1)) && - - (!(cssCaseBug && (query.indexOf(".") >= 0))) && - - // FIXME: - // need to tighten up browser rules on ":contains" and "|=" to - // figure out which aren't good - // Latest webkit (around 531.21.8) does not seem to do well with :checked on option - // elements, even though according to spec, selected options should - // match :checked. So go nonQSA for it: - // http://bugs.dojotoolkit.org/ticket/5179 - (query.indexOf(":contains") == -1) && (query.indexOf(":checked") == -1) && - (query.indexOf("|=") == -1) // some browsers don't grok it - ); - - // TODO: - // if we've got a descendant query (e.g., "> .thinger" instead of - // just ".thinger") in a QSA-able doc, but are passed a child as a - // root, it should be possible to give the item a synthetic ID and - // trivially rewrite the query to the form "#synid > .thinger" to - // use the QSA branch - - - if(useQSA){ - var tq = (specials.indexOf(query.charAt(query.length-1)) >= 0) ? - (query + " *") : query; - return _queryFuncCacheQSA[query] = function(root){ - try{ - // the QSA system contains an egregious spec bug which - // limits us, effectively, to only running QSA queries over - // entire documents. See: - // http://ejohn.org/blog/thoughts-on-queryselectorall/ - // despite this, we can also handle QSA runs on simple - // selectors, but we don't want detection to be expensive - // so we're just checking for the presence of a space char - // right now. Not elegant, but it's cheaper than running - // the query parser when we might not need to - if(!((9 == root.nodeType) || nospace)){ throw ""; } - var r = root[qsa](tq); - // skip expensive duplication checks and just wrap in a NodeList - r[noZip] = true; - return r; - }catch(e){ - // else run the DOM branch on this query, ensuring that we - // default that way in the future - return getQueryFunc(query, true)(root); - } - }; - }else{ - // DOM branch - var parts = query.match(/([^\s,](?:"(?:\\.|[^"])+"|'(?:\\.|[^'])+'|[^,])*)/g); - return _queryFuncCacheDOM[query] = ((parts.length < 2) ? - // if not a compound query (e.g., ".foo, .bar"), cache and return a dispatcher - getStepQueryFunc(query) : - // if it *is* a complex query, break it up into its - // constituent parts and return a dispatcher that will - // merge the parts when run - function(root){ - var pindex = 0, // avoid array alloc for every invocation - ret = [], - tp; - while((tp = parts[pindex++])){ - ret = ret.concat(getStepQueryFunc(tp)(root)); - } - return ret; - } - ); - } - }; - - var _zipIdx = 0; - - // NOTE: - // this function is Moo inspired, but our own impl to deal correctly - // with XML in IE - var _nodeUID = has("ie") ? function(node){ - if(caseSensitive){ - // XML docs don't have uniqueID on their nodes - return (node.getAttribute("_uid") || node.setAttribute("_uid", ++_zipIdx) || _zipIdx); - - }else{ - return node.uniqueID; - } - } : - function(node){ - return (node._uid || (node._uid = ++_zipIdx)); - }; - - // determine if a node in is unique in a "bag". In this case we don't want - // to flatten a list of unique items, but rather just tell if the item in - // question is already in the bag. Normally we'd just use hash lookup to do - // this for us but IE's DOM is busted so we can't really count on that. On - // the upside, it gives us a built in unique ID function. - var _isUnique = function(node, bag){ - if(!bag){ return 1; } - var id = _nodeUID(node); - if(!bag[id]){ return bag[id] = 1; } - return 0; - }; - - // attempt to efficiently determine if an item in a list is a dupe, - // returning a list of "uniques", hopefully in document order - var _zipIdxName = "_zipIdx"; - var _zip = function(arr){ - if(arr && arr.nozip){ return arr; } - - if(!arr || !arr.length){ return []; } - if(arr.length < 2){ return [arr[0]]; } - - var ret = []; - - _zipIdx++; - - // we have to fork here for IE and XML docs because we can't set - // expandos on their nodes (apparently). *sigh* - var x, te; - if(has("ie") && caseSensitive){ - var szidx = _zipIdx+""; - for(x = 0; x < arr.length; x++){ - if((te = arr[x]) && te.getAttribute(_zipIdxName) != szidx){ - ret.push(te); - te.setAttribute(_zipIdxName, szidx); - } - } - }else if(has("ie") && arr.commentStrip){ - try{ - for(x = 0; x < arr.length; x++){ - if((te = arr[x]) && _isElement(te)){ - ret.push(te); - } - } - }catch(e){ /* squelch */ } - }else{ - for(x = 0; x < arr.length; x++){ - if((te = arr[x]) && te[_zipIdxName] != _zipIdx){ - ret.push(te); - te[_zipIdxName] = _zipIdx; - } - } - } - return ret; - }; - - // the main executor - var query = function(/*String*/ query, /*String|DOMNode?*/ root){ - // summary: - // Returns nodes which match the given CSS3 selector, searching the - // entire document by default but optionally taking a node to scope - // the search by. Returns an array. - // description: - // dojo.query() is the swiss army knife of DOM node manipulation in - // Dojo. Much like Prototype's "$$" (bling-bling) function or JQuery's - // "$" function, dojo.query provides robust, high-performance - // CSS-based node selector support with the option of scoping searches - // to a particular sub-tree of a document. - // - // Supported Selectors: - // -------------------- - // - // acme supports a rich set of CSS3 selectors, including: - // - // - class selectors (e.g., `.foo`) - // - node type selectors like `span` - // - ` ` descendant selectors - // - `>` child element selectors - // - `#foo` style ID selectors - // - `*` universal selector - // - `~`, the preceded-by sibling selector - // - `+`, the immediately preceded-by sibling selector - // - attribute queries: - // - `[foo]` attribute presence selector - // - `[foo='bar']` attribute value exact match - // - `[foo~='bar']` attribute value list item match - // - `[foo^='bar']` attribute start match - // - `[foo$='bar']` attribute end match - // - `[foo*='bar']` attribute substring match - // - `:first-child`, `:last-child`, and `:only-child` positional selectors - // - `:empty` content emtpy selector - // - `:checked` pseudo selector - // - `:nth-child(n)`, `:nth-child(2n+1)` style positional calculations - // - `:nth-child(even)`, `:nth-child(odd)` positional selectors - // - `:not(...)` negation pseudo selectors - // - // Any legal combination of these selectors will work with - // `dojo.query()`, including compound selectors ("," delimited). - // Very complex and useful searches can be constructed with this - // palette of selectors and when combined with functions for - // manipulation presented by dojo/NodeList, many types of DOM - // manipulation operations become very straightforward. - // - // Unsupported Selectors: - // ---------------------- - // - // While dojo.query handles many CSS3 selectors, some fall outside of - // what's reasonable for a programmatic node querying engine to - // handle. Currently unsupported selectors include: - // - // - namespace-differentiated selectors of any form - // - all `::` pseduo-element selectors - // - certain pseudo-selectors which don't get a lot of day-to-day use: - // - `:root`, `:lang()`, `:target`, `:focus` - // - all visual and state selectors: - // - `:root`, `:active`, `:hover`, `:visited`, `:link`, - // `:enabled`, `:disabled` - // - `:*-of-type` pseudo selectors - // - // dojo.query and XML Documents: - // ----------------------------- - // - // `dojo.query` (as of dojo 1.2) supports searching XML documents - // in a case-sensitive manner. If an HTML document is served with - // a doctype that forces case-sensitivity (e.g., XHTML 1.1 - // Strict), dojo.query() will detect this and "do the right - // thing". Case sensitivity is dependent upon the document being - // searched and not the query used. It is therefore possible to - // use case-sensitive queries on strict sub-documents (iframes, - // etc.) or XML documents while still assuming case-insensitivity - // for a host/root document. - // - // Non-selector Queries: - // --------------------- - // - // If something other than a String is passed for the query, - // `dojo.query` will return a new `dojo/NodeList` instance - // constructed from that parameter alone and all further - // processing will stop. This means that if you have a reference - // to a node or NodeList, you can quickly construct a new NodeList - // from the original by calling `dojo.query(node)` or - // `dojo.query(list)`. - // - // query: - // The CSS3 expression to match against. For details on the syntax of - // CSS3 selectors, see - // root: - // A DOMNode (or node id) to scope the search from. Optional. - // returns: Array - // example: - // search the entire document for elements with the class "foo": - // | require(["dojo/query"], function(query) { - // | query(".foo").forEach(function(q) { console.log(q); }); - // | }); - // these elements will match: - // | - // | - // |

    - // example: - // search the entire document for elements with the classes "foo" *and* "bar": - // | require(["dojo/query"], function(query) { - // | query(".foo.bar").forEach(function(q) { console.log(q); }); - // | }); - - // these elements will match: - // | - // while these will not: - // | - // |

    - // example: - // find `` elements which are descendants of paragraphs and - // which have a "highlighted" class: - // | require(["dojo/query"], function(query) { - // | query("p span.highlighted").forEach(function(q) { console.log(q); }); - // | }); - // the innermost span in this fragment matches: - // |

    - // | ... - // | ... - // | - // |

    - // example: - // set an "odd" class on all odd table rows inside of the table - // `#tabular_data`, using the `>` (direct child) selector to avoid - // affecting any nested tables: - // | require(["dojo/query"], function(query) { - // | query("#tabular_data > tbody > tr:nth-child(odd)").addClass("odd"); - // | ); - // example: - // remove all elements with the class "error" from the document: - // | require(["dojo/query"], function(query) { - // | query(".error").orphan(); - // | ); - // example: - // add an onclick handler to every submit button in the document - // which causes the form to be sent via Ajax instead: - // | require(["dojo/query", "dojo/request", "dojo/dom-construct", "dojo/dom-style" - // | ], function (query, request, domConstruct, domStyle) { - // | query("input[type='submit']").on("click", function (e) { - // | e.stopPropagation(); - // | e.preventDefault(); - // | var btn = e.target; - // | request.post("", { data: btn.form, timeout: 2000 }) - // | .then(function (data) { - // | // replace the form with the response - // | domConstruct.create("div", { innerHTML: data }, btn.form, "after"); - // | domStyle.set(btn.form, "display", "none"); - // | }); - // | }); - // | }); - - - root = root || getDoc(); - - // throw the big case sensitivity switch - var od = root.ownerDocument || root; // root is either Document or a node inside the document - caseSensitive = (od.createElement("div").tagName === "div"); - - // NOTE: - // adding "true" as the 2nd argument to getQueryFunc is useful for - // testing the DOM branch without worrying about the - // behavior/performance of the QSA branch. - var r = getQueryFunc(query)(root); - - // FIXME: - // need to investigate this branch WRT #8074 and #8075 - if(r && r.nozip){ - return r; - } - return _zip(r); // dojo/NodeList - }; - query.filter = function(/*Node[]*/ nodeList, /*String*/ filter, /*String|DOMNode?*/ root){ - // summary: - // function for filtering a NodeList based on a selector, optimized for simple selectors - var tmpNodeList = [], - parts = getQueryParts(filter), - filterFunc = - (parts.length == 1 && !/[^\w#\.]/.test(filter)) ? - getSimpleFilterFunc(parts[0]) : - function(node){ - return array.indexOf(query(filter, dom.byId(root)), node) != -1; - }; - for(var x = 0, te; te = nodeList[x]; x++){ - if(filterFunc(te)){ tmpNodeList.push(te); } - } - return tmpNodeList; - }; - return query; -}); - -}, -'dojo/errors/RequestTimeoutError':function(){ -define(['./create', './RequestError'], function(create, RequestError){ - // module: - // dojo/errors/RequestTimeoutError - - /*===== - return function(){ - // summary: - // TODOC - }; - =====*/ - - return create("RequestTimeoutError", null, RequestError, { - dojoType: "timeout" - }); -}); - -}, -'dojo/dom-style':function(){ -define(["./sniff", "./dom"], function(has, dom){ - // module: - // dojo/dom-style - - // ============================= - // Style Functions - // ============================= - - // getComputedStyle drives most of the style code. - // Wherever possible, reuse the returned object. - // - // API functions below that need to access computed styles accept an - // optional computedStyle parameter. - // If this parameter is omitted, the functions will call getComputedStyle themselves. - // This way, calling code can access computedStyle once, and then pass the reference to - // multiple API functions. - - // Although we normally eschew argument validation at this - // level, here we test argument 'node' for (duck)type, - // by testing nodeType, ecause 'document' is the 'parentNode' of 'body' - // it is frequently sent to this function even - // though it is not Element. - var getComputedStyle, style = { - // summary: - // This module defines the core dojo DOM style API. - }; - if(has("webkit")){ - getComputedStyle = function(/*DomNode*/ node){ - var s; - if(node.nodeType == 1){ - var dv = node.ownerDocument.defaultView; - s = dv.getComputedStyle(node, null); - if(!s && node.style){ - node.style.display = ""; - s = dv.getComputedStyle(node, null); - } - } - return s || {}; - }; - }else if(has("ie") && (has("ie") < 9 || has("quirks"))){ - getComputedStyle = function(node){ - // IE (as of 7) doesn't expose Element like sane browsers - // currentStyle can be null on IE8! - return node.nodeType == 1 /* ELEMENT_NODE*/ && node.currentStyle ? node.currentStyle : {}; - }; - }else{ - getComputedStyle = function(node){ - return node.nodeType == 1 /* ELEMENT_NODE*/ ? - node.ownerDocument.defaultView.getComputedStyle(node, null) : {}; - }; - } - style.getComputedStyle = getComputedStyle; - /*===== - style.getComputedStyle = function(node){ - // summary: - // Returns a "computed style" object. - // - // description: - // Gets a "computed style" object which can be used to gather - // information about the current state of the rendered node. - // - // Note that this may behave differently on different browsers. - // Values may have different formats and value encodings across - // browsers. - // - // Note also that this method is expensive. Wherever possible, - // reuse the returned object. - // - // Use the dojo/dom-style.get() method for more consistent (pixelized) - // return values. - // - // node: DOMNode - // A reference to a DOM node. Does NOT support taking an - // ID string for speed reasons. - // example: - // | require(["dojo/dom-style", "dojo/dom"], function(domStyle, dom){ - // | domStyle.getComputedStyle(dom.byId('foo')).borderWidth; - // | }); - // - // example: - // Reusing the returned object, avoiding multiple lookups: - // | require(["dojo/dom-style", "dojo/dom"], function(domStyle, dom){ - // | var cs = domStyle.getComputedStyle(dom.byId("someNode")); - // | var w = cs.width, h = cs.height; - // | }); - return; // CSS2Properties - }; - =====*/ - - var toPixel; - if(!has("ie")){ - toPixel = function(element, value){ - // style values can be floats, client code may want - // to round for integer pixels. - return parseFloat(value) || 0; - }; - }else{ - toPixel = function(element, avalue){ - if(!avalue){ return 0; } - // on IE7, medium is usually 4 pixels - if(avalue == "medium"){ return 4; } - // style values can be floats, client code may - // want to round this value for integer pixels. - if(avalue.slice && avalue.slice(-2) == 'px'){ return parseFloat(avalue); } - var s = element.style, rs = element.runtimeStyle, cs = element.currentStyle, - sLeft = s.left, rsLeft = rs.left; - rs.left = cs.left; - try{ - // 'avalue' may be incompatible with style.left, which can cause IE to throw - // this has been observed for border widths using "thin", "medium", "thick" constants - // those particular constants could be trapped by a lookup - // but perhaps there are more - s.left = avalue; - avalue = s.pixelLeft; - }catch(e){ - avalue = 0; - } - s.left = sLeft; - rs.left = rsLeft; - return avalue; - }; - } - style.toPixelValue = toPixel; - /*===== - style.toPixelValue = function(node, value){ - // summary: - // converts style value to pixels on IE or return a numeric value. - // node: DOMNode - // value: String - // returns: Number - }; - =====*/ - - // FIXME: there opacity quirks on FF that we haven't ported over. Hrm. - - var astr = "DXImageTransform.Microsoft.Alpha"; - var af = function(n, f){ - try{ - return n.filters.item(astr); - }catch(e){ - return f ? {} : null; - } - }; - - var _getOpacity = - has("ie") < 9 || (has("ie") < 10 && has("quirks")) ? function(node){ - try{ - return af(node).Opacity / 100; // Number - }catch(e){ - return 1; // Number - } - } : - function(node){ - return getComputedStyle(node).opacity; - }; - - var _setOpacity = - has("ie") < 9 || (has("ie") < 10 && has("quirks")) ? function(/*DomNode*/ node, /*Number*/ opacity){ - if(opacity === ""){ opacity = 1; } - var ov = opacity * 100, fullyOpaque = opacity === 1; - - // on IE7 Alpha(Filter opacity=100) makes text look fuzzy so disable it altogether (bug #2661), - // but still update the opacity value so we can get a correct reading if it is read later: - // af(node, 1).Enabled = !fullyOpaque; - - if(fullyOpaque){ - node.style.zoom = ""; - if(af(node)){ - node.style.filter = node.style.filter.replace( - new RegExp("\\s*progid:" + astr + "\\([^\\)]+?\\)", "i"), ""); - } - }else{ - node.style.zoom = 1; - if(af(node)){ - af(node, 1).Opacity = ov; - }else{ - node.style.filter += " progid:" + astr + "(Opacity=" + ov + ")"; - } - af(node, 1).Enabled = true; - } - - if(node.tagName.toLowerCase() == "tr"){ - for(var td = node.firstChild; td; td = td.nextSibling){ - if(td.tagName.toLowerCase() == "td"){ - _setOpacity(td, opacity); - } - } - } - return opacity; - } : - function(node, opacity){ - return node.style.opacity = opacity; - }; - - var _pixelNamesCache = { - left: true, top: true - }; - var _pixelRegExp = /margin|padding|width|height|max|min|offset/; // |border - function _toStyleValue(node, type, value){ - //TODO: should we really be doing string case conversion here? Should we cache it? Need to profile! - type = type.toLowerCase(); - if(has("ie") || has("trident")){ - if(value == "auto"){ - if(type == "height"){ return node.offsetHeight; } - if(type == "width"){ return node.offsetWidth; } - } - if(type == "fontweight"){ - switch(value){ - case 700: return "bold"; - case 400: - default: return "normal"; - } - } - } - if(!(type in _pixelNamesCache)){ - _pixelNamesCache[type] = _pixelRegExp.test(type); - } - return _pixelNamesCache[type] ? toPixel(node, value) : value; - } - - var _floatAliases = {cssFloat: 1, styleFloat: 1, "float": 1}; - - // public API - - style.get = function getStyle(/*DOMNode|String*/ node, /*String?*/ name){ - // summary: - // Accesses styles on a node. - // description: - // Getting the style value uses the computed style for the node, so the value - // will be a calculated value, not just the immediate node.style value. - // Also when getting values, use specific style names, - // like "borderBottomWidth" instead of "border" since compound values like - // "border" are not necessarily reflected as expected. - // If you want to get node dimensions, use `dojo/dom-geometry.getMarginBox()`, - // `dojo/dom-geometry.getContentBox()` or `dojo/dom-geometry.getPosition()`. - // node: DOMNode|String - // id or reference to node to get style for - // name: String? - // the style property to get - // example: - // Passing only an ID or node returns the computed style object of - // the node: - // | require(["dojo/dom-style", "dojo/dom"], function(domStyle, dom){ - // | domStyle.get("thinger"); - // | }); - // example: - // Passing a node and a style property returns the current - // normalized, computed value for that property: - // | require(["dojo/dom-style", "dojo/dom"], function(domStyle, dom){ - // | domStyle.get("thinger", "opacity"); // 1 by default - // | }); - - var n = dom.byId(node), l = arguments.length, op = (name == "opacity"); - if(l == 2 && op){ - return _getOpacity(n); - } - name = _floatAliases[name] ? "cssFloat" in n.style ? "cssFloat" : "styleFloat" : name; - var s = style.getComputedStyle(n); - return (l == 1) ? s : _toStyleValue(n, name, s[name] || n.style[name]); /* CSS2Properties||String||Number */ - }; - - style.set = function setStyle(/*DOMNode|String*/ node, /*String|Object*/ name, /*String?*/ value){ - // summary: - // Sets styles on a node. - // node: DOMNode|String - // id or reference to node to set style for - // name: String|Object - // the style property to set in DOM-accessor format - // ("borderWidth", not "border-width") or an object with key/value - // pairs suitable for setting each property. - // value: String? - // If passed, sets value on the node for style, handling - // cross-browser concerns. When setting a pixel value, - // be sure to include "px" in the value. For instance, top: "200px". - // Otherwise, in some cases, some browsers will not apply the style. - // - // example: - // Passing a node, a style property, and a value changes the - // current display of the node and returns the new computed value - // | require(["dojo/dom-style"], function(domStyle){ - // | domStyle.set("thinger", "opacity", 0.5); // == 0.5 - // | }); - // - // example: - // Passing a node, an object-style style property sets each of the values in turn and returns the computed style object of the node: - // | require(["dojo/dom-style"], function(domStyle){ - // | domStyle.set("thinger", { - // | "opacity": 0.5, - // | "border": "3px solid black", - // | "height": "300px" - // | }); - // | }); - // - // example: - // When the CSS style property is hyphenated, the JavaScript property is camelCased. - // font-size becomes fontSize, and so on. - // | require(["dojo/dom-style", "dojo/dom"], function(domStyle, dom){ - // | domStyle.set("thinger",{ - // | fontSize:"14pt", - // | letterSpacing:"1.2em" - // | }); - // | }); - // - // example: - // dojo/NodeList implements .style() using the same syntax, omitting the "node" parameter, calling - // dojo/dom-style.get() on every element of the list. See: `dojo/query` and `dojo/NodeList` - // | require(["dojo/dom-style", "dojo/query", "dojo/NodeList-dom"], - // | function(domStyle, query){ - // | query(".someClassName").style("visibility","hidden"); - // | // or - // | query("#baz > div").style({ - // | opacity:0.75, - // | fontSize:"13pt" - // | }); - // | }); - - var n = dom.byId(node), l = arguments.length, op = (name == "opacity"); - name = _floatAliases[name] ? "cssFloat" in n.style ? "cssFloat" : "styleFloat" : name; - if(l == 3){ - return op ? _setOpacity(n, value) : n.style[name] = value; // Number - } - for(var x in name){ - style.set(node, x, name[x]); - } - return style.getComputedStyle(n); - }; - - return style; -}); - -}, -'dojo/dom-geometry':function(){ -define(["./sniff", "./_base/window","./dom", "./dom-style"], - function(has, win, dom, style){ - // module: - // dojo/dom-geometry - - // the result object - var geom = { - // summary: - // This module defines the core dojo DOM geometry API. - }; - - // Box functions will assume this model. - // On IE/Opera, BORDER_BOX will be set if the primary document is in quirks mode. - // Can be set to change behavior of box setters. - - // can be either: - // "border-box" - // "content-box" (default) - geom.boxModel = "content-box"; - - // We punt per-node box mode testing completely. - // If anybody cares, we can provide an additional (optional) unit - // that overrides existing code to include per-node box sensitivity. - - // Opera documentation claims that Opera 9 uses border-box in BackCompat mode. - // but experiments (Opera 9.10.8679 on Windows Vista) indicate that it actually continues to use content-box. - // IIRC, earlier versions of Opera did in fact use border-box. - // Opera guys, this is really confusing. Opera being broken in quirks mode is not our fault. - - if(has("ie") /*|| has("opera")*/){ - // client code may have to adjust if compatMode varies across iframes - geom.boxModel = document.compatMode == "BackCompat" ? "border-box" : "content-box"; - } - - geom.getPadExtents = function getPadExtents(/*DomNode*/ node, /*Object*/ computedStyle){ - // summary: - // Returns object with special values specifically useful for node - // fitting. - // description: - // Returns an object with `w`, `h`, `l`, `t` properties: - // | l/t/r/b = left/top/right/bottom padding (respectively) - // | w = the total of the left and right padding - // | h = the total of the top and bottom padding - // If 'node' has position, l/t forms the origin for child nodes. - // The w/h are used for calculating boxes. - // Normally application code will not need to invoke this - // directly, and will use the ...box... functions instead. - // node: DOMNode - // computedStyle: Object? - // This parameter accepts computed styles object. - // If this parameter is omitted, the functions will call - // dojo/dom-style.getComputedStyle to get one. It is a better way, calling - // dojo/dom-style.getComputedStyle once, and then pass the reference to this - // computedStyle parameter. Wherever possible, reuse the returned - // object of dojo/dom-style.getComputedStyle(). - - node = dom.byId(node); - var s = computedStyle || style.getComputedStyle(node), px = style.toPixelValue, - l = px(node, s.paddingLeft), t = px(node, s.paddingTop), r = px(node, s.paddingRight), b = px(node, s.paddingBottom); - return {l: l, t: t, r: r, b: b, w: l + r, h: t + b}; - }; - - var none = "none"; - - geom.getBorderExtents = function getBorderExtents(/*DomNode*/ node, /*Object*/ computedStyle){ - // summary: - // returns an object with properties useful for noting the border - // dimensions. - // description: - // - l/t/r/b = the sum of left/top/right/bottom border (respectively) - // - w = the sum of the left and right border - // - h = the sum of the top and bottom border - // - // The w/h are used for calculating boxes. - // Normally application code will not need to invoke this - // directly, and will use the ...box... functions instead. - // node: DOMNode - // computedStyle: Object? - // This parameter accepts computed styles object. - // If this parameter is omitted, the functions will call - // dojo/dom-style.getComputedStyle to get one. It is a better way, calling - // dojo/dom-style.getComputedStyle once, and then pass the reference to this - // computedStyle parameter. Wherever possible, reuse the returned - // object of dojo/dom-style.getComputedStyle(). - - node = dom.byId(node); - var px = style.toPixelValue, s = computedStyle || style.getComputedStyle(node), - l = s.borderLeftStyle != none ? px(node, s.borderLeftWidth) : 0, - t = s.borderTopStyle != none ? px(node, s.borderTopWidth) : 0, - r = s.borderRightStyle != none ? px(node, s.borderRightWidth) : 0, - b = s.borderBottomStyle != none ? px(node, s.borderBottomWidth) : 0; - return {l: l, t: t, r: r, b: b, w: l + r, h: t + b}; - }; - - geom.getPadBorderExtents = function getPadBorderExtents(/*DomNode*/ node, /*Object*/ computedStyle){ - // summary: - // Returns object with properties useful for box fitting with - // regards to padding. - // description: - // - l/t/r/b = the sum of left/top/right/bottom padding and left/top/right/bottom border (respectively) - // - w = the sum of the left and right padding and border - // - h = the sum of the top and bottom padding and border - // - // The w/h are used for calculating boxes. - // Normally application code will not need to invoke this - // directly, and will use the ...box... functions instead. - // node: DOMNode - // computedStyle: Object? - // This parameter accepts computed styles object. - // If this parameter is omitted, the functions will call - // dojo/dom-style.getComputedStyle to get one. It is a better way, calling - // dojo/dom-style.getComputedStyle once, and then pass the reference to this - // computedStyle parameter. Wherever possible, reuse the returned - // object of dojo/dom-style.getComputedStyle(). - - node = dom.byId(node); - var s = computedStyle || style.getComputedStyle(node), - p = geom.getPadExtents(node, s), - b = geom.getBorderExtents(node, s); - return { - l: p.l + b.l, - t: p.t + b.t, - r: p.r + b.r, - b: p.b + b.b, - w: p.w + b.w, - h: p.h + b.h - }; - }; - - geom.getMarginExtents = function getMarginExtents(node, computedStyle){ - // summary: - // returns object with properties useful for box fitting with - // regards to box margins (i.e., the outer-box). - // - // - l/t = marginLeft, marginTop, respectively - // - w = total width, margin inclusive - // - h = total height, margin inclusive - // - // The w/h are used for calculating boxes. - // Normally application code will not need to invoke this - // directly, and will use the ...box... functions instead. - // node: DOMNode - // computedStyle: Object? - // This parameter accepts computed styles object. - // If this parameter is omitted, the functions will call - // dojo/dom-style.getComputedStyle to get one. It is a better way, calling - // dojo/dom-style.getComputedStyle once, and then pass the reference to this - // computedStyle parameter. Wherever possible, reuse the returned - // object of dojo/dom-style.getComputedStyle(). - - node = dom.byId(node); - var s = computedStyle || style.getComputedStyle(node), px = style.toPixelValue, - l = px(node, s.marginLeft), t = px(node, s.marginTop), r = px(node, s.marginRight), b = px(node, s.marginBottom); - return {l: l, t: t, r: r, b: b, w: l + r, h: t + b}; - }; - - // Box getters work in any box context because offsetWidth/clientWidth - // are invariant wrt box context - // - // They do *not* work for display: inline objects that have padding styles - // because the user agent ignores padding (it's bogus styling in any case) - // - // Be careful with IMGs because they are inline or block depending on - // browser and browser mode. - - // Although it would be easier to read, there are not separate versions of - // _getMarginBox for each browser because: - // 1. the branching is not expensive - // 2. factoring the shared code wastes cycles (function call overhead) - // 3. duplicating the shared code wastes bytes - - geom.getMarginBox = function getMarginBox(/*DomNode*/ node, /*Object*/ computedStyle){ - // summary: - // returns an object that encodes the width, height, left and top - // positions of the node's margin box. - // node: DOMNode - // computedStyle: Object? - // This parameter accepts computed styles object. - // If this parameter is omitted, the functions will call - // dojo/dom-style.getComputedStyle to get one. It is a better way, calling - // dojo/dom-style.getComputedStyle once, and then pass the reference to this - // computedStyle parameter. Wherever possible, reuse the returned - // object of dojo/dom-style.getComputedStyle(). - - node = dom.byId(node); - var s = computedStyle || style.getComputedStyle(node), me = geom.getMarginExtents(node, s), - l = node.offsetLeft - me.l, t = node.offsetTop - me.t, p = node.parentNode, px = style.toPixelValue, pcs; - if(has("mozilla")){ - // Mozilla: - // If offsetParent has a computed overflow != visible, the offsetLeft is decreased - // by the parent's border. - // We don't want to compute the parent's style, so instead we examine node's - // computed left/top which is more stable. - var sl = parseFloat(s.left), st = parseFloat(s.top); - if(!isNaN(sl) && !isNaN(st)){ - l = sl; - t = st; - }else{ - // If child's computed left/top are not parseable as a number (e.g. "auto"), we - // have no choice but to examine the parent's computed style. - if(p && p.style){ - pcs = style.getComputedStyle(p); - if(pcs.overflow != "visible"){ - l += pcs.borderLeftStyle != none ? px(node, pcs.borderLeftWidth) : 0; - t += pcs.borderTopStyle != none ? px(node, pcs.borderTopWidth) : 0; - } - } - } - }else if(has("opera") || (has("ie") == 8 && !has("quirks"))){ - // On Opera and IE 8, offsetLeft/Top includes the parent's border - if(p){ - pcs = style.getComputedStyle(p); - l -= pcs.borderLeftStyle != none ? px(node, pcs.borderLeftWidth) : 0; - t -= pcs.borderTopStyle != none ? px(node, pcs.borderTopWidth) : 0; - } - } - return {l: l, t: t, w: node.offsetWidth + me.w, h: node.offsetHeight + me.h}; - }; - - geom.getContentBox = function getContentBox(node, computedStyle){ - // summary: - // Returns an object that encodes the width, height, left and top - // positions of the node's content box, irrespective of the - // current box model. - // node: DOMNode - // computedStyle: Object? - // This parameter accepts computed styles object. - // If this parameter is omitted, the functions will call - // dojo/dom-style.getComputedStyle to get one. It is a better way, calling - // dojo/dom-style.getComputedStyle once, and then pass the reference to this - // computedStyle parameter. Wherever possible, reuse the returned - // object of dojo/dom-style.getComputedStyle(). - - // clientWidth/Height are important since the automatically account for scrollbars - // fallback to offsetWidth/Height for special cases (see #3378) - node = dom.byId(node); - var s = computedStyle || style.getComputedStyle(node), w = node.clientWidth, h, - pe = geom.getPadExtents(node, s), be = geom.getBorderExtents(node, s); - if(!w){ - w = node.offsetWidth; - h = node.offsetHeight; - }else{ - h = node.clientHeight; - be.w = be.h = 0; - } - // On Opera, offsetLeft includes the parent's border - if(has("opera")){ - pe.l += be.l; - pe.t += be.t; - } - return {l: pe.l, t: pe.t, w: w - pe.w - be.w, h: h - pe.h - be.h}; - }; - - // Box setters depend on box context because interpretation of width/height styles - // vary wrt box context. - // - // The value of boxModel is used to determine box context. - // boxModel can be set directly to change behavior. - // - // Beware of display: inline objects that have padding styles - // because the user agent ignores padding (it's a bogus setup anyway) - // - // Be careful with IMGs because they are inline or block depending on - // browser and browser mode. - // - // Elements other than DIV may have special quirks, like built-in - // margins or padding, or values not detectable via computedStyle. - // In particular, margins on TABLE do not seems to appear - // at all in computedStyle on Mozilla. - - function setBox(/*DomNode*/ node, /*Number?*/ l, /*Number?*/ t, /*Number?*/ w, /*Number?*/ h, /*String?*/ u){ - // summary: - // sets width/height/left/top in the current (native) box-model - // dimensions. Uses the unit passed in u. - // node: - // DOM Node reference. Id string not supported for performance - // reasons. - // l: - // left offset from parent. - // t: - // top offset from parent. - // w: - // width in current box model. - // h: - // width in current box model. - // u: - // unit measure to use for other measures. Defaults to "px". - u = u || "px"; - var s = node.style; - if(!isNaN(l)){ - s.left = l + u; - } - if(!isNaN(t)){ - s.top = t + u; - } - if(w >= 0){ - s.width = w + u; - } - if(h >= 0){ - s.height = h + u; - } - } - - function isButtonTag(/*DomNode*/ node){ - // summary: - // True if the node is BUTTON or INPUT.type="button". - return node.tagName.toLowerCase() == "button" || - node.tagName.toLowerCase() == "input" && (node.getAttribute("type") || "").toLowerCase() == "button"; // boolean - } - - function usesBorderBox(/*DomNode*/ node){ - // summary: - // True if the node uses border-box layout. - - // We could test the computed style of node to see if a particular box - // has been specified, but there are details and we choose not to bother. - - // TABLE and BUTTON (and INPUT type=button) are always border-box by default. - // If you have assigned a different box to either one via CSS then - // box functions will break. - - return geom.boxModel == "border-box" || node.tagName.toLowerCase() == "table" || isButtonTag(node); // boolean - } - - geom.setContentSize = function setContentSize(/*DomNode*/ node, /*Object*/ box, /*Object*/ computedStyle){ - // summary: - // Sets the size of the node's contents, irrespective of margins, - // padding, or borders. - // node: DOMNode - // box: Object - // hash with optional "w", and "h" properties for "width", and "height" - // respectively. All specified properties should have numeric values in whole pixels. - // computedStyle: Object? - // This parameter accepts computed styles object. - // If this parameter is omitted, the functions will call - // dojo/dom-style.getComputedStyle to get one. It is a better way, calling - // dojo/dom-style.getComputedStyle once, and then pass the reference to this - // computedStyle parameter. Wherever possible, reuse the returned - // object of dojo/dom-style.getComputedStyle(). - - node = dom.byId(node); - var w = box.w, h = box.h; - if(usesBorderBox(node)){ - var pb = geom.getPadBorderExtents(node, computedStyle); - if(w >= 0){ - w += pb.w; - } - if(h >= 0){ - h += pb.h; - } - } - setBox(node, NaN, NaN, w, h); - }; - - var nilExtents = {l: 0, t: 0, w: 0, h: 0}; - - geom.setMarginBox = function setMarginBox(/*DomNode*/ node, /*Object*/ box, /*Object*/ computedStyle){ - // summary: - // sets the size of the node's margin box and placement - // (left/top), irrespective of box model. Think of it as a - // passthrough to setBox that handles box-model vagaries for - // you. - // node: DOMNode - // box: Object - // hash with optional "l", "t", "w", and "h" properties for "left", "right", "width", and "height" - // respectively. All specified properties should have numeric values in whole pixels. - // computedStyle: Object? - // This parameter accepts computed styles object. - // If this parameter is omitted, the functions will call - // dojo/dom-style.getComputedStyle to get one. It is a better way, calling - // dojo/dom-style.getComputedStyle once, and then pass the reference to this - // computedStyle parameter. Wherever possible, reuse the returned - // object of dojo/dom-style.getComputedStyle(). - - node = dom.byId(node); - var s = computedStyle || style.getComputedStyle(node), w = box.w, h = box.h, - // Some elements have special padding, margin, and box-model settings. - // To use box functions you may need to set padding, margin explicitly. - // Controlling box-model is harder, in a pinch you might set dojo/dom-geometry.boxModel. - pb = usesBorderBox(node) ? nilExtents : geom.getPadBorderExtents(node, s), - mb = geom.getMarginExtents(node, s); - if(has("webkit")){ - // on Safari (3.1.2), button nodes with no explicit size have a default margin - // setting an explicit size eliminates the margin. - // We have to swizzle the width to get correct margin reading. - if(isButtonTag(node)){ - var ns = node.style; - if(w >= 0 && !ns.width){ - ns.width = "4px"; - } - if(h >= 0 && !ns.height){ - ns.height = "4px"; - } - } - } - if(w >= 0){ - w = Math.max(w - pb.w - mb.w, 0); - } - if(h >= 0){ - h = Math.max(h - pb.h - mb.h, 0); - } - setBox(node, box.l, box.t, w, h); - }; - - // ============================= - // Positioning - // ============================= - - geom.isBodyLtr = function isBodyLtr(/*Document?*/ doc){ - // summary: - // Returns true if the current language is left-to-right, and false otherwise. - // doc: Document? - // Optional document to query. If unspecified, use win.doc. - // returns: Boolean - - doc = doc || win.doc; - return (win.body(doc).dir || doc.documentElement.dir || "ltr").toLowerCase() == "ltr"; // Boolean - }; - - geom.docScroll = function docScroll(/*Document?*/ doc){ - // summary: - // Returns an object with {node, x, y} with corresponding offsets. - // doc: Document? - // Optional document to query. If unspecified, use win.doc. - // returns: Object - - doc = doc || win.doc; - var node = win.doc.parentWindow || win.doc.defaultView; // use UI window, not dojo.global window. TODO: use dojo/window::get() except for circular dependency problem - return "pageXOffset" in node ? {x: node.pageXOffset, y: node.pageYOffset } : - (node = has("quirks") ? win.body(doc) : doc.documentElement) && - {x: geom.fixIeBiDiScrollLeft(node.scrollLeft || 0, doc), y: node.scrollTop || 0 }; - }; - - if(has("ie")){ - geom.getIeDocumentElementOffset = function getIeDocumentElementOffset(/*Document?*/ doc){ - // summary: - // returns the offset in x and y from the document body to the - // visual edge of the page for IE - // doc: Document? - // Optional document to query. If unspecified, use win.doc. - // description: - // The following values in IE contain an offset: - // | event.clientX - // | event.clientY - // | node.getBoundingClientRect().left - // | node.getBoundingClientRect().top - // But other position related values do not contain this offset, - // such as node.offsetLeft, node.offsetTop, node.style.left and - // node.style.top. The offset is always (2, 2) in LTR direction. - // When the body is in RTL direction, the offset counts the width - // of left scroll bar's width. This function computes the actual - // offset. - - //NOTE: assumes we're being called in an IE browser - - doc = doc || win.doc; - var de = doc.documentElement; // only deal with HTML element here, position() handles body/quirks - - if(has("ie") < 8){ - var r = de.getBoundingClientRect(), // works well for IE6+ - l = r.left, t = r.top; - if(has("ie") < 7){ - l += de.clientLeft; // scrollbar size in strict/RTL, or, - t += de.clientTop; // HTML border size in strict - } - return { - x: l < 0 ? 0 : l, // FRAME element border size can lead to inaccurate negative values - y: t < 0 ? 0 : t - }; - }else{ - return { - x: 0, - y: 0 - }; - } - }; - } - - geom.fixIeBiDiScrollLeft = function fixIeBiDiScrollLeft(/*Integer*/ scrollLeft, /*Document?*/ doc){ - // summary: - // In RTL direction, scrollLeft should be a negative value, but IE - // returns a positive one. All codes using documentElement.scrollLeft - // must call this function to fix this error, otherwise the position - // will offset to right when there is a horizontal scrollbar. - // scrollLeft: Number - // doc: Document? - // Optional document to query. If unspecified, use win.doc. - // returns: Number - - // In RTL direction, scrollLeft should be a negative value, but IE - // returns a positive one. All codes using documentElement.scrollLeft - // must call this function to fix this error, otherwise the position - // will offset to right when there is a horizontal scrollbar. - - doc = doc || win.doc; - var ie = has("ie"); - if(ie && !geom.isBodyLtr(doc)){ - var qk = has("quirks"), - de = qk ? win.body(doc) : doc.documentElement, - pwin = win.global; // TODO: use winUtils.get(doc) after resolving circular dependency b/w dom-geometry.js and dojo/window.js - if(ie == 6 && !qk && pwin.frameElement && de.scrollHeight > de.clientHeight){ - scrollLeft += de.clientLeft; // workaround ie6+strict+rtl+iframe+vertical-scrollbar bug where clientWidth is too small by clientLeft pixels - } - return (ie < 8 || qk) ? (scrollLeft + de.clientWidth - de.scrollWidth) : -scrollLeft; // Integer - } - return scrollLeft; // Integer - }; - - geom.position = function(/*DomNode*/ node, /*Boolean?*/ includeScroll){ - // summary: - // Gets the position and size of the passed element relative to - // the viewport (if includeScroll==false), or relative to the - // document root (if includeScroll==true). - // - // description: - // Returns an object of the form: - // `{ x: 100, y: 300, w: 20, h: 15 }`. - // If includeScroll==true, the x and y values will include any - // document offsets that may affect the position relative to the - // viewport. - // Uses the border-box model (inclusive of border and padding but - // not margin). Does not act as a setter. - // node: DOMNode|String - // includeScroll: Boolean? - // returns: Object - - node = dom.byId(node); - var db = win.body(node.ownerDocument), - ret = node.getBoundingClientRect(); - ret = {x: ret.left, y: ret.top, w: ret.right - ret.left, h: ret.bottom - ret.top}; - - if(has("ie") < 9){ - // On IE<9 there's a 2px offset that we need to adjust for, see dojo.getIeDocumentElementOffset() - var offset = geom.getIeDocumentElementOffset(node.ownerDocument); - - // fixes the position in IE, quirks mode - ret.x -= offset.x + (has("quirks") ? db.clientLeft + db.offsetLeft : 0); - ret.y -= offset.y + (has("quirks") ? db.clientTop + db.offsetTop : 0); - } - - // account for document scrolling - // if offsetParent is used, ret value already includes scroll position - // so we may have to actually remove that value if !includeScroll - if(includeScroll){ - var scroll = geom.docScroll(node.ownerDocument); - ret.x += scroll.x; - ret.y += scroll.y; - } - - return ret; // Object - }; - - // random "private" functions wildly used throughout the toolkit - - geom.getMarginSize = function getMarginSize(/*DomNode*/ node, /*Object*/ computedStyle){ - // summary: - // returns an object that encodes the width and height of - // the node's margin box - // node: DOMNode|String - // computedStyle: Object? - // This parameter accepts computed styles object. - // If this parameter is omitted, the functions will call - // dojo/dom-style.getComputedStyle to get one. It is a better way, calling - // dojo/dom-style.getComputedStyle once, and then pass the reference to this - // computedStyle parameter. Wherever possible, reuse the returned - // object of dojo/dom-style.getComputedStyle(). - - node = dom.byId(node); - var me = geom.getMarginExtents(node, computedStyle || style.getComputedStyle(node)); - var size = node.getBoundingClientRect(); - return { - w: (size.right - size.left) + me.w, - h: (size.bottom - size.top) + me.h - }; - }; - - geom.normalizeEvent = function(event){ - // summary: - // Normalizes the geometry of a DOM event, normalizing the pageX, pageY, - // offsetX, offsetY, layerX, and layerX properties - // event: Object - if(!("layerX" in event)){ - event.layerX = event.offsetX; - event.layerY = event.offsetY; - } - if(!has("dom-addeventlistener")){ - // old IE version - // FIXME: scroll position query is duped from dojo/_base/html to - // avoid dependency on that entire module. Now that HTML is in - // Base, we should convert back to something similar there. - var se = event.target; - var doc = (se && se.ownerDocument) || document; - // DO NOT replace the following to use dojo/_base/window.body(), in IE, document.documentElement should be used - // here rather than document.body - var docBody = has("quirks") ? doc.body : doc.documentElement; - var offset = geom.getIeDocumentElementOffset(doc); - event.pageX = event.clientX + geom.fixIeBiDiScrollLeft(docBody.scrollLeft || 0, doc) - offset.x; - event.pageY = event.clientY + (docBody.scrollTop || 0) - offset.y; - } - }; - - // TODO: evaluate separate getters/setters for position and sizes? - - return geom; -}); - -}, -'dojo/dom-prop':function(){ -define(["exports", "./_base/kernel", "./sniff", "./_base/lang", "./dom", "./dom-style", "./dom-construct", "./_base/connect"], - function(exports, dojo, has, lang, dom, style, ctr, conn){ - // module: - // dojo/dom-prop - // summary: - // This module defines the core dojo DOM properties API. - - // TODOC: summary not showing up in output, see https://github.com/csnover/js-doc-parse/issues/42 - - // ============================= - // Element properties Functions - // ============================= - - // helper to connect events - var _evtHdlrMap = {}, _ctr = 0, _attrId = dojo._scopeName + "attrid"; - has.add('dom-textContent', function (global, doc, element) { return 'textContent' in element; }); - - exports.names = { - // properties renamed to avoid clashes with reserved words - "class": "className", - "for": "htmlFor", - // properties written as camelCase - tabindex: "tabIndex", - readonly: "readOnly", - colspan: "colSpan", - frameborder: "frameBorder", - rowspan: "rowSpan", - textcontent: "textContent", - valuetype: "valueType" - }; - - function getText(/*DOMNode*/node){ - // summary: - // recursion method for get('textContent') to use. Gets text value for a node. - // description: - // Juse uses nodedValue so things like
    tags do not end up in - // the text as any sort of line return. - var text = "", ch = node.childNodes; - for(var i = 0, n; n = ch[i]; i++){ - //Skip comments. - if(n.nodeType != 8){ - if(n.nodeType == 1){ - text += getText(n); - }else{ - text += n.nodeValue; - } - } - } - return text; - } - - exports.get = function getProp(/*DOMNode|String*/ node, /*String*/ name){ - // summary: - // Gets a property on an HTML element. - // description: - // Handles normalized getting of properties on DOM nodes. - // - // node: DOMNode|String - // id or reference to the element to get the property on - // name: String - // the name of the property to get. - // returns: - // the value of the requested property or its default value - // - // example: - // | // get the current value of the "foo" property on a node - // | require(["dojo/dom-prop", "dojo/dom"], function(domProp, dom){ - // | domProp.get(dom.byId("nodeId"), "foo"); - // | // or we can just pass the id: - // | domProp.get("nodeId", "foo"); - // | }); - - node = dom.byId(node); - var lc = name.toLowerCase(), propName = exports.names[lc] || name; - - if(propName == "textContent" && !has("dom-textContent")){ - return getText(node); - } - - return node[propName]; // Anything - }; - - exports.set = function setProp(/*DOMNode|String*/ node, /*String|Object*/ name, /*String?*/ value){ - // summary: - // Sets a property on an HTML element. - // description: - // Handles normalized setting of properties on DOM nodes. - // - // When passing functions as values, note that they will not be - // directly assigned to slots on the node, but rather the default - // behavior will be removed and the new behavior will be added - // using `dojo.connect()`, meaning that event handler properties - // will be normalized and that some caveats with regards to - // non-standard behaviors for onsubmit apply. Namely that you - // should cancel form submission using `dojo.stopEvent()` on the - // passed event object instead of returning a boolean value from - // the handler itself. - // node: DOMNode|String - // id or reference to the element to set the property on - // name: String|Object - // the name of the property to set, or a hash object to set - // multiple properties at once. - // value: String? - // The value to set for the property - // returns: - // the DOM node - // - // example: - // | // use prop() to set the tab index - // | require(["dojo/dom-prop"], function(domProp){ - // | domProp.set("nodeId", "tabIndex", 3); - // | }); - // - // example: - // Set multiple values at once, including event handlers: - // | require(["dojo/dom-prop"], function(domProp){ - // | domProp.set("formId", { - // | "foo": "bar", - // | "tabIndex": -1, - // | "method": "POST", - // | }); - // | }); - - node = dom.byId(node); - var l = arguments.length; - if(l == 2 && typeof name != "string"){ // inline'd type check - // the object form of setter: the 2nd argument is a dictionary - for(var x in name){ - exports.set(node, x, name[x]); - } - return node; // DomNode - } - var lc = name.toLowerCase(), propName = exports.names[lc] || name; - if(propName == "style" && typeof value != "string"){ // inline'd type check - // special case: setting a style - style.set(node, value); - return node; // DomNode - } - if(propName == "innerHTML"){ - // special case: assigning HTML - // the hash lists elements with read-only innerHTML on IE - if(has("ie") && node.tagName.toLowerCase() in {col: 1, colgroup: 1, - table: 1, tbody: 1, tfoot: 1, thead: 1, tr: 1, title: 1}){ - ctr.empty(node); - node.appendChild(ctr.toDom(value, node.ownerDocument)); - }else{ - node[propName] = value; - } - return node; // DomNode - } - if(propName == "textContent" && !has("dom-textContent")) { - ctr.empty(node); - node.appendChild(node.ownerDocument.createTextNode(value)); - return node; - } - if(lang.isFunction(value)){ - // special case: assigning an event handler - // clobber if we can - var attrId = node[_attrId]; - if(!attrId){ - attrId = _ctr++; - node[_attrId] = attrId; - } - if(!_evtHdlrMap[attrId]){ - _evtHdlrMap[attrId] = {}; - } - var h = _evtHdlrMap[attrId][propName]; - if(h){ - //h.remove(); - conn.disconnect(h); - }else{ - try{ - delete node[propName]; - }catch(e){} - } - // ensure that event objects are normalized, etc. - if(value){ - //_evtHdlrMap[attrId][propName] = on(node, propName, value); - _evtHdlrMap[attrId][propName] = conn.connect(node, propName, value); - }else{ - node[propName] = null; - } - return node; // DomNode - } - node[propName] = value; - return node; // DomNode - }; -}); - -}, -'dojo/when':function(){ -define([ - "./Deferred", - "./promise/Promise" -], function(Deferred, Promise){ - "use strict"; - - // module: - // dojo/when - - return function when(valueOrPromise, callback, errback, progback){ - // summary: - // Transparently applies callbacks to values and/or promises. - // description: - // Accepts promises but also transparently handles non-promises. If no - // callbacks are provided returns a promise, regardless of the initial - // value. Foreign promises are converted. - // - // If callbacks are provided and the initial value is not a promise, - // the callback is executed immediately with no error handling. Returns - // a promise if the initial value is a promise, or the result of the - // callback otherwise. - // valueOrPromise: - // Either a regular value or an object with a `then()` method that - // follows the Promises/A specification. - // callback: Function? - // Callback to be invoked when the promise is resolved, or a non-promise - // is received. - // errback: Function? - // Callback to be invoked when the promise is rejected. - // progback: Function? - // Callback to be invoked when the promise emits a progress update. - // returns: dojo/promise/Promise - // Promise, or if a callback is provided, the result of the callback. - - var receivedPromise = valueOrPromise && typeof valueOrPromise.then === "function"; - var nativePromise = receivedPromise && valueOrPromise instanceof Promise; - - if(!receivedPromise){ - if(arguments.length > 1){ - return callback ? callback(valueOrPromise) : valueOrPromise; - }else{ - return new Deferred().resolve(valueOrPromise); - } - }else if(!nativePromise){ - var deferred = new Deferred(valueOrPromise.cancel); - valueOrPromise.then(deferred.resolve, deferred.reject, deferred.progress); - valueOrPromise = deferred.promise; - } - - if(callback || errback || progback){ - return valueOrPromise.then(callback, errback, progback); - } - return valueOrPromise; - }; -}); - -}, -'dojo/dom-attr':function(){ -define(["exports", "./sniff", "./_base/lang", "./dom", "./dom-style", "./dom-prop"], - function(exports, has, lang, dom, style, prop){ - // module: - // dojo/dom-attr - // summary: - // This module defines the core dojo DOM attributes API. - - // TODOC: summary not showing up in output see https://github.com/csnover/js-doc-parse/issues/42 - - // ============================= - // Element attribute Functions - // ============================= - - // This module will be obsolete soon. Use dojo/prop instead. - - // dojo/dom-attr.get() should conform to http://www.w3.org/TR/DOM-Level-2-Core/ - - // attribute-related functions (to be obsolete soon) - var forcePropNames = { - innerHTML: 1, - textContent:1, - className: 1, - htmlFor: has("ie"), - value: 1 - }, - attrNames = { - // original attribute names - classname: "class", - htmlfor: "for", - // for IE - tabindex: "tabIndex", - readonly: "readOnly" - }; - - function _hasAttr(node, name){ - var attr = node.getAttributeNode && node.getAttributeNode(name); - return attr && attr.specified; // Boolean - } - - // There is a difference in the presence of certain properties and their default values - // between browsers. For example, on IE "disabled" is present on all elements, - // but it is value is "false"; "tabIndex" of
    returns 0 by default on IE, yet other browsers - // can return -1. - - exports.has = function hasAttr(/*DOMNode|String*/ node, /*String*/ name){ - // summary: - // Returns true if the requested attribute is specified on the - // given element, and false otherwise. - // node: DOMNode|String - // id or reference to the element to check - // name: String - // the name of the attribute - // returns: Boolean - // true if the requested attribute is specified on the - // given element, and false otherwise - - var lc = name.toLowerCase(); - return forcePropNames[prop.names[lc] || name] || _hasAttr(dom.byId(node), attrNames[lc] || name); // Boolean - }; - - exports.get = function getAttr(/*DOMNode|String*/ node, /*String*/ name){ - // summary: - // Gets an attribute on an HTML element. - // description: - // Handles normalized getting of attributes on DOM Nodes. - // node: DOMNode|String - // id or reference to the element to get the attribute on - // name: String - // the name of the attribute to get. - // returns: - // the value of the requested attribute or null if that attribute does not have a specified or - // default value; - // - // example: - // | // get the current value of the "foo" attribute on a node - // | require(["dojo/dom-attr", "dojo/dom"], function(domAttr, dom){ - // | domAttr.get(dom.byId("nodeId"), "foo"); - // | // or we can just pass the id: - // | domAttr.get("nodeId", "foo"); - // | }); - // | - - node = dom.byId(node); - var lc = name.toLowerCase(), - propName = prop.names[lc] || name, - forceProp = forcePropNames[propName], - value = node[propName]; // should we access this attribute via a property or via getAttribute()? - - if(forceProp && typeof value != "undefined"){ - // node's property - return value; // Anything - } - - if(propName == "textContent"){ - return prop.get(node, propName); - } - - if(propName != "href" && (typeof value == "boolean" || lang.isFunction(value))){ - // node's property - return value; // Anything - } - // node's attribute - // we need _hasAttr() here to guard against IE returning a default value - var attrName = attrNames[lc] || name; - return _hasAttr(node, attrName) ? node.getAttribute(attrName) : null; // Anything - }; - - exports.set = function setAttr(/*DOMNode|String*/ node, /*String|Object*/ name, /*String?*/ value){ - // summary: - // Sets an attribute on an HTML element. - // description: - // Handles normalized setting of attributes on DOM Nodes. - // - // When passing functions as values, note that they will not be - // directly assigned to slots on the node, but rather the default - // behavior will be removed and the new behavior will be added - // using `dojo.connect()`, meaning that event handler properties - // will be normalized and that some caveats with regards to - // non-standard behaviors for onsubmit apply. Namely that you - // should cancel form submission using `dojo.stopEvent()` on the - // passed event object instead of returning a boolean value from - // the handler itself. - // node: DOMNode|String - // id or reference to the element to set the attribute on - // name: String|Object - // the name of the attribute to set, or a hash of key-value pairs to set. - // value: String? - // the value to set for the attribute, if the name is a string. - // returns: - // the DOM node - // - // example: - // | // use attr() to set the tab index - // | require(["dojo/dom-attr"], function(domAttr){ - // | domAttr.set("nodeId", "tabIndex", 3); - // | }); - // - // example: - // Set multiple values at once, including event handlers: - // | require(["dojo/dom-attr"], - // | function(domAttr){ - // | domAttr.set("formId", { - // | "foo": "bar", - // | "tabIndex": -1, - // | "method": "POST" - // | } - // | }); - - node = dom.byId(node); - if(arguments.length == 2){ // inline'd type check - // the object form of setter: the 2nd argument is a dictionary - for(var x in name){ - exports.set(node, x, name[x]); - } - return node; // DomNode - } - var lc = name.toLowerCase(), - propName = prop.names[lc] || name, - forceProp = forcePropNames[propName]; - if(propName == "style" && typeof value != "string"){ // inline'd type check - // special case: setting a style - style.set(node, value); - return node; // DomNode - } - if(forceProp || typeof value == "boolean" || lang.isFunction(value)){ - return prop.set(node, name, value); - } - // node's attribute - node.setAttribute(attrNames[lc] || name, value); - return node; // DomNode - }; - - exports.remove = function removeAttr(/*DOMNode|String*/ node, /*String*/ name){ - // summary: - // Removes an attribute from an HTML element. - // node: DOMNode|String - // id or reference to the element to remove the attribute from - // name: String - // the name of the attribute to remove - - dom.byId(node).removeAttribute(attrNames[name.toLowerCase()] || name); - }; - - exports.getNodeProp = function getNodeProp(/*DomNode|String*/ node, /*String*/ name){ - // summary: - // Returns an effective value of a property or an attribute. - // node: DOMNode|String - // id or reference to the element to remove the attribute from - // name: String - // the name of the attribute - // returns: - // the value of the attribute - - node = dom.byId(node); - var lc = name.toLowerCase(), propName = prop.names[lc] || name; - if((propName in node) && propName != "href"){ - // node's property - return node[propName]; // Anything - } - // node's attribute - var attrName = attrNames[lc] || name; - return _hasAttr(node, attrName) ? node.getAttribute(attrName) : null; // Anything - }; -}); - -}, -'dojo/dom-construct':function(){ -define(["exports", "./_base/kernel", "./sniff", "./_base/window", "./dom", "./dom-attr"], - function(exports, dojo, has, win, dom, attr){ - // module: - // dojo/dom-construct - // summary: - // This module defines the core dojo DOM construction API. - - // TODOC: summary not showing up in output, see https://github.com/csnover/js-doc-parse/issues/42 - - // support stuff for toDom() - var tagWrap = { - option: ["select"], - tbody: ["table"], - thead: ["table"], - tfoot: ["table"], - tr: ["table", "tbody"], - td: ["table", "tbody", "tr"], - th: ["table", "thead", "tr"], - legend: ["fieldset"], - caption: ["table"], - colgroup: ["table"], - col: ["table", "colgroup"], - li: ["ul"] - }, - reTag = /<\s*([\w\:]+)/, - masterNode = {}, masterNum = 0, - masterName = "__" + dojo._scopeName + "ToDomId"; - - // generate start/end tag strings to use - // for the injection for each special tag wrap case. - for(var param in tagWrap){ - if(tagWrap.hasOwnProperty(param)){ - var tw = tagWrap[param]; - tw.pre = param == "option" ? '":"<"+tw.join("><")+">"; -tw.post=""; -} -} -var _d; -if(_3("ie")<=8){ -_d=function(_e){ -_e.__dojo_html5_tested="yes"; -var _f=_10("div",{innerHTML:"",style:{visibility:"hidden"}},_e.body); -if(_f.childNodes.length!==1){ -("abbr article aside audio canvas details figcaption figure footer header "+"hgroup mark meter nav output progress section summary time video").replace(/\b\w+\b/g,function(n){ -_e.createElement(n); -}); -} -_11(_f); -}; -} -function _12(_13,ref){ -var _14=ref.parentNode; -if(_14){ -_14.insertBefore(_13,ref); -} -}; -function _15(_16,ref){ -var _17=ref.parentNode; -if(_17){ -if(_17.lastChild==ref){ -_17.appendChild(_16); -}else{ -_17.insertBefore(_16,ref.nextSibling); -} -} -}; -_1.toDom=function toDom(_18,doc){ -doc=doc||_4.doc; -var _19=doc[_b]; -if(!_19){ -doc[_b]=_19=++_a+""; -_9[_19]=doc.createElement("div"); -} -if(_3("ie")<=8){ -if(!doc.__dojo_html5_tested&&doc.body){ -_d(doc); -} -} -_18+=""; -var _1a=_18.match(_8),tag=_1a?_1a[1].toLowerCase():"",_1b=_9[_19],_1c,i,fc,df; -if(_1a&&_7[tag]){ -_1c=_7[tag]; -_1b.innerHTML=_1c.pre+_18+_1c.post; -for(i=_1c.length;i;--i){ -_1b=_1b.firstChild; -} -}else{ -_1b.innerHTML=_18; -} -if(_1b.childNodes.length==1){ -return _1b.removeChild(_1b.firstChild); -} -df=doc.createDocumentFragment(); -while((fc=_1b.firstChild)){ -df.appendChild(fc); -} -return df; -}; -_1.place=function place(_1d,_1e,_1f){ -_1e=_5.byId(_1e); -if(typeof _1d=="string"){ -_1d=/^\s*' : "<" + tw.join("><") + ">"; - tw.post = ""; - // the last line is destructive: it reverses the array, - // but we don't care at this point - } - } - - var html5domfix; - if(has("ie") <= 8){ - html5domfix = function(doc){ - doc.__dojo_html5_tested = "yes"; - var div = create('div', {innerHTML: "", style: {visibility: "hidden"}}, doc.body); - if(div.childNodes.length !== 1){ - ('abbr article aside audio canvas details figcaption figure footer header ' + - 'hgroup mark meter nav output progress section summary time video').replace( - /\b\w+\b/g, function(n){ - doc.createElement(n); - } - ); - } - destroy(div); - } - } - - function _insertBefore(/*DomNode*/ node, /*DomNode*/ ref){ - var parent = ref.parentNode; - if(parent){ - parent.insertBefore(node, ref); - } - } - - function _insertAfter(/*DomNode*/ node, /*DomNode*/ ref){ - // summary: - // Try to insert node after ref - var parent = ref.parentNode; - if(parent){ - if(parent.lastChild == ref){ - parent.appendChild(node); - }else{ - parent.insertBefore(node, ref.nextSibling); - } - } - } - - exports.toDom = function toDom(frag, doc){ - // summary: - // instantiates an HTML fragment returning the corresponding DOM. - // frag: String - // the HTML fragment - // doc: DocumentNode? - // optional document to use when creating DOM nodes, defaults to - // dojo/_base/window.doc if not specified. - // returns: - // Document fragment, unless it's a single node in which case it returns the node itself - // example: - // Create a table row: - // | require(["dojo/dom-construct"], function(domConstruct){ - // | var tr = domConstruct.toDom("First!"); - // | }); - - doc = doc || win.doc; - var masterId = doc[masterName]; - if(!masterId){ - doc[masterName] = masterId = ++masterNum + ""; - masterNode[masterId] = doc.createElement("div"); - } - - if(has("ie") <= 8){ - if(!doc.__dojo_html5_tested && doc.body){ - html5domfix(doc); - } - } - - // make sure the frag is a string. - frag += ""; - - // find the starting tag, and get node wrapper - var match = frag.match(reTag), - tag = match ? match[1].toLowerCase() : "", - master = masterNode[masterId], - wrap, i, fc, df; - if(match && tagWrap[tag]){ - wrap = tagWrap[tag]; - master.innerHTML = wrap.pre + frag + wrap.post; - for(i = wrap.length; i; --i){ - master = master.firstChild; - } - }else{ - master.innerHTML = frag; - } - - // one node shortcut => return the node itself - if(master.childNodes.length == 1){ - return master.removeChild(master.firstChild); // DOMNode - } - - // return multiple nodes as a document fragment - df = doc.createDocumentFragment(); - while((fc = master.firstChild)){ // intentional assignment - df.appendChild(fc); - } - return df; // DocumentFragment - }; - - exports.place = function place(node, refNode, position){ - // summary: - // Attempt to insert node into the DOM, choosing from various positioning options. - // Returns the first argument resolved to a DOM node. - // node: DOMNode|DocumentFragment|String - // id or node reference, or HTML fragment starting with "<" to place relative to refNode - // refNode: DOMNode|String - // id or node reference to use as basis for placement - // position: String|Number? - // string noting the position of node relative to refNode or a - // number indicating the location in the childNodes collection of refNode. - // Accepted string values are: - // - // - before - // - after - // - replace - // - only - // - first - // - last - // - // "first" and "last" indicate positions as children of refNode, "replace" replaces refNode, - // "only" replaces all children. position defaults to "last" if not specified - // returns: DOMNode - // Returned values is the first argument resolved to a DOM node. - // - // .place() is also a method of `dojo/NodeList`, allowing `dojo/query` node lookups. - // example: - // Place a node by string id as the last child of another node by string id: - // | require(["dojo/dom-construct"], function(domConstruct){ - // | domConstruct.place("someNode", "anotherNode"); - // | }); - // example: - // Place a node by string id before another node by string id - // | require(["dojo/dom-construct"], function(domConstruct){ - // | domConstruct.place("someNode", "anotherNode", "before"); - // | }); - // example: - // Create a Node, and place it in the body element (last child): - // | require(["dojo/dom-construct", "dojo/_base/window" - // | ], function(domConstruct, win){ - // | domConstruct.place("
    ", win.body()); - // | }); - // example: - // Put a new LI as the first child of a list by id: - // | require(["dojo/dom-construct"], function(domConstruct){ - // | domConstruct.place("
  • ", "someUl", "first"); - // | }); - - refNode = dom.byId(refNode); - if(typeof node == "string"){ // inline'd type check - node = /^\s*hi

    " }); - // | }); - // - // example: - // Place a new DIV in the BODY, with no attributes set - // | require(["dojo/dom-construct"], function(domConstruct){ - // | var n = domConstruct.create("div", null, dojo.body()); - // | }); - // - // example: - // Create an UL, and populate it with LI's. Place the list as the first-child of a - // node with id="someId": - // | require(["dojo/dom-construct", "dojo/_base/array"], - // | function(domConstruct, arrayUtil){ - // | var ul = domConstruct.create("ul", null, "someId", "first"); - // | var items = ["one", "two", "three", "four"]; - // | arrayUtil.forEach(items, function(data){ - // | domConstruct.create("li", { innerHTML: data }, ul); - // | }); - // | }); - // - // example: - // Create an anchor, with an href. Place in BODY: - // | require(["dojo/dom-construct"], function(domConstruct){ - // | domConstruct.create("a", { href:"foo.html", title:"Goto FOO!" }, dojo.body()); - // | }); - - var doc = win.doc; - if(refNode){ - refNode = dom.byId(refNode); - doc = refNode.ownerDocument; - } - if(typeof tag == "string"){ // inline'd type check - tag = doc.createElement(tag); - } - if(attrs){ attr.set(tag, attrs); } - if(refNode){ exports.place(tag, refNode, pos); } - return tag; // DomNode - }; - - function _empty(/*DomNode*/ node){ - // TODO: remove this if() block in 2.0 when we no longer have to worry about IE memory leaks, - // and then uncomment the emptyGrandchildren() test case from html.html. - // Note that besides fixing #16957, using removeChild() is actually faster than setting node.innerHTML, - // see http://jsperf.com/clear-dom-node. - if("innerHTML" in node){ - try{ - // fast path - node.innerHTML = ""; - return; - }catch(e){ - // innerHTML is readOnly (e.g. TABLE (sub)elements in quirks mode) - // Fall through (saves bytes) - } - } - - // SVG/strict elements don't support innerHTML - for(var c; c = node.lastChild;){ // intentional assignment - node.removeChild(c); - } - } - - exports.empty = function empty(/*DOMNode|String*/ node){ - // summary: - // safely removes all children of the node. - // node: DOMNode|String - // a reference to a DOM node or an id. - // example: - // Destroy node's children byId: - // | require(["dojo/dom-construct"], function(domConstruct){ - // | domConstruct.empty("someId"); - // | }); - - _empty(dom.byId(node)); - }; - - - function _destroy(/*DomNode*/ node, /*DomNode*/ parent){ - // in IE quirks, node.canHaveChildren can be false but firstChild can be non-null (OBJECT/APPLET) - if(node.firstChild){ - _empty(node); - } - if(parent){ - // removeNode(false) doesn't leak in IE 6+, but removeChild() and removeNode(true) are known to leak under IE 8- while 9+ is TBD. - // In IE quirks mode, PARAM nodes as children of OBJECT/APPLET nodes have a removeNode method that does nothing and - // the parent node has canHaveChildren=false even though removeChild correctly removes the PARAM children. - // In IE, SVG/strict nodes don't have a removeNode method nor a canHaveChildren boolean. - has("ie") && parent.canHaveChildren && "removeNode" in node ? node.removeNode(false) : parent.removeChild(node); - } - } - var destroy = exports.destroy = function destroy(/*DOMNode|String*/ node){ - // summary: - // Removes a node from its parent, clobbering it and all of its - // children. - // - // description: - // Removes a node from its parent, clobbering it and all of its - // children. Function only works with DomNodes, and returns nothing. - // - // node: DOMNode|String - // A String ID or DomNode reference of the element to be destroyed - // - // example: - // Destroy a node byId: - // | require(["dojo/dom-construct"], function(domConstruct){ - // | domConstruct.destroy("someId"); - // | }); - - node = dom.byId(node); - if(!node){ return; } - _destroy(node, node.parentNode); - }; -}); diff --git a/lib/dojo/dom-form.js b/lib/dojo/dom-form.js deleted file mode 100644 index ebada3d..0000000 --- a/lib/dojo/dom-form.js +++ /dev/null @@ -1,81 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/dom-form",["./_base/lang","./dom","./io-query","./json"],function(_1,_2,_3,_4){ -function _5(_6,_7,_8){ -if(_8===null){ -return; -} -var _9=_6[_7]; -if(typeof _9=="string"){ -_6[_7]=[_9,_8]; -}else{ -if(_1.isArray(_9)){ -_9.push(_8); -}else{ -_6[_7]=_8; -} -} -}; -var _a="file|submit|image|reset|button"; -var _b={fieldToObject:function fieldToObject(_c){ -var _d=null; -_c=_2.byId(_c); -if(_c){ -var _e=_c.name,_f=(_c.type||"").toLowerCase(); -if(_e&&_f&&!_c.disabled){ -if(_f=="radio"||_f=="checkbox"){ -if(_c.checked){ -_d=_c.value; -} -}else{ -if(_c.multiple){ -_d=[]; -var _10=[_c.firstChild]; -while(_10.length){ -for(var _11=_10.pop();_11;_11=_11.nextSibling){ -if(_11.nodeType==1&&_11.tagName.toLowerCase()=="option"){ -if(_11.selected){ -_d.push(_11.value); -} -}else{ -if(_11.nextSibling){ -_10.push(_11.nextSibling); -} -if(_11.firstChild){ -_10.push(_11.firstChild); -} -break; -} -} -} -}else{ -_d=_c.value; -} -} -} -} -return _d; -},toObject:function formToObject(_12){ -var ret={},_13=_2.byId(_12).elements; -for(var i=0,l=_13.length;i - // | - // | - // | - // | - // | - // - // yields this object structure as the result of a call to - // formToObject(): - // - // | { - // | blah: "blah", - // | multi: [ - // | "thud", - // | "thonk" - // | ] - // | }; - - var ret = {}, elems = dom.byId(formNode).elements; - for(var i = 0, l = elems.length; i < l; ++i){ - var item = elems[i], _in = item.name, type = (item.type || "").toLowerCase(); - if(_in && type && exclude.indexOf(type) < 0 && !item.disabled){ - setValue(ret, _in, form.fieldToObject(item)); - if(type == "image"){ - ret[_in + ".x"] = ret[_in + ".y"] = ret[_in].x = ret[_in].y = 0; - } - } - } - return ret; // Object - }, - - toQuery: function formToQuery(/*DOMNode|String*/ formNode){ - // summary: - // Returns a URL-encoded string representing the form passed as either a - // node or string ID identifying the form to serialize - // formNode: DOMNode|String - // returns: String - - return ioq.objectToQuery(form.toObject(formNode)); // String - }, - - toJson: function formToJson(/*DOMNode|String*/ formNode, /*Boolean?*/ prettyPrint){ - // summary: - // Create a serialized JSON string from a form node or string - // ID identifying the form to serialize - // formNode: DOMNode|String - // prettyPrint: Boolean? - // returns: String - - return json.stringify(form.toObject(formNode), null, prettyPrint ? 4 : 0); // String - } - }; - - return form; -}); diff --git a/lib/dojo/dom-geometry.js b/lib/dojo/dom-geometry.js deleted file mode 100644 index 8db891f..0000000 --- a/lib/dojo/dom-geometry.js +++ /dev/null @@ -1,212 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/dom-geometry",["./sniff","./_base/window","./dom","./dom-style"],function(_1,_2,_3,_4){ -var _5={}; -_5.boxModel="content-box"; -if(_1("ie")){ -_5.boxModel=document.compatMode=="BackCompat"?"border-box":"content-box"; -} -_5.getPadExtents=function getPadExtents(_6,_7){ -_6=_3.byId(_6); -var s=_7||_4.getComputedStyle(_6),px=_4.toPixelValue,l=px(_6,s.paddingLeft),t=px(_6,s.paddingTop),r=px(_6,s.paddingRight),b=px(_6,s.paddingBottom); -return {l:l,t:t,r:r,b:b,w:l+r,h:t+b}; -}; -var _8="none"; -_5.getBorderExtents=function getBorderExtents(_9,_a){ -_9=_3.byId(_9); -var px=_4.toPixelValue,s=_a||_4.getComputedStyle(_9),l=s.borderLeftStyle!=_8?px(_9,s.borderLeftWidth):0,t=s.borderTopStyle!=_8?px(_9,s.borderTopWidth):0,r=s.borderRightStyle!=_8?px(_9,s.borderRightWidth):0,b=s.borderBottomStyle!=_8?px(_9,s.borderBottomWidth):0; -return {l:l,t:t,r:r,b:b,w:l+r,h:t+b}; -}; -_5.getPadBorderExtents=function getPadBorderExtents(_b,_c){ -_b=_3.byId(_b); -var s=_c||_4.getComputedStyle(_b),p=_5.getPadExtents(_b,s),b=_5.getBorderExtents(_b,s); -return {l:p.l+b.l,t:p.t+b.t,r:p.r+b.r,b:p.b+b.b,w:p.w+b.w,h:p.h+b.h}; -}; -_5.getMarginExtents=function getMarginExtents(_d,_e){ -_d=_3.byId(_d); -var s=_e||_4.getComputedStyle(_d),px=_4.toPixelValue,l=px(_d,s.marginLeft),t=px(_d,s.marginTop),r=px(_d,s.marginRight),b=px(_d,s.marginBottom); -return {l:l,t:t,r:r,b:b,w:l+r,h:t+b}; -}; -_5.getMarginBox=function getMarginBox(_f,_10){ -_f=_3.byId(_f); -var s=_10||_4.getComputedStyle(_f),me=_5.getMarginExtents(_f,s),l=_f.offsetLeft-me.l,t=_f.offsetTop-me.t,p=_f.parentNode,px=_4.toPixelValue,pcs; -if(_1("mozilla")){ -var sl=parseFloat(s.left),st=parseFloat(s.top); -if(!isNaN(sl)&&!isNaN(st)){ -l=sl; -t=st; -}else{ -if(p&&p.style){ -pcs=_4.getComputedStyle(p); -if(pcs.overflow!="visible"){ -l+=pcs.borderLeftStyle!=_8?px(_f,pcs.borderLeftWidth):0; -t+=pcs.borderTopStyle!=_8?px(_f,pcs.borderTopWidth):0; -} -} -} -}else{ -if(_1("opera")||(_1("ie")==8&&!_1("quirks"))){ -if(p){ -pcs=_4.getComputedStyle(p); -l-=pcs.borderLeftStyle!=_8?px(_f,pcs.borderLeftWidth):0; -t-=pcs.borderTopStyle!=_8?px(_f,pcs.borderTopWidth):0; -} -} -} -return {l:l,t:t,w:_f.offsetWidth+me.w,h:_f.offsetHeight+me.h}; -}; -_5.getContentBox=function getContentBox(_11,_12){ -_11=_3.byId(_11); -var s=_12||_4.getComputedStyle(_11),w=_11.clientWidth,h,pe=_5.getPadExtents(_11,s),be=_5.getBorderExtents(_11,s); -if(!w){ -w=_11.offsetWidth; -h=_11.offsetHeight; -}else{ -h=_11.clientHeight; -be.w=be.h=0; -} -if(_1("opera")){ -pe.l+=be.l; -pe.t+=be.t; -} -return {l:pe.l,t:pe.t,w:w-pe.w-be.w,h:h-pe.h-be.h}; -}; -function _13(_14,l,t,w,h,u){ -u=u||"px"; -var s=_14.style; -if(!isNaN(l)){ -s.left=l+u; -} -if(!isNaN(t)){ -s.top=t+u; -} -if(w>=0){ -s.width=w+u; -} -if(h>=0){ -s.height=h+u; -} -}; -function _15(_16){ -return _16.tagName.toLowerCase()=="button"||_16.tagName.toLowerCase()=="input"&&(_16.getAttribute("type")||"").toLowerCase()=="button"; -}; -function _17(_18){ -return _5.boxModel=="border-box"||_18.tagName.toLowerCase()=="table"||_15(_18); -}; -_5.setContentSize=function setContentSize(_19,box,_1a){ -_19=_3.byId(_19); -var w=box.w,h=box.h; -if(_17(_19)){ -var pb=_5.getPadBorderExtents(_19,_1a); -if(w>=0){ -w+=pb.w; -} -if(h>=0){ -h+=pb.h; -} -} -_13(_19,NaN,NaN,w,h); -}; -var _1b={l:0,t:0,w:0,h:0}; -_5.setMarginBox=function setMarginBox(_1c,box,_1d){ -_1c=_3.byId(_1c); -var s=_1d||_4.getComputedStyle(_1c),w=box.w,h=box.h,pb=_17(_1c)?_1b:_5.getPadBorderExtents(_1c,s),mb=_5.getMarginExtents(_1c,s); -if(_1("webkit")){ -if(_15(_1c)){ -var ns=_1c.style; -if(w>=0&&!ns.width){ -ns.width="4px"; -} -if(h>=0&&!ns.height){ -ns.height="4px"; -} -} -} -if(w>=0){ -w=Math.max(w-pb.w-mb.w,0); -} -if(h>=0){ -h=Math.max(h-pb.h-mb.h,0); -} -_13(_1c,box.l,box.t,w,h); -}; -_5.isBodyLtr=function isBodyLtr(doc){ -doc=doc||_2.doc; -return (_2.body(doc).dir||doc.documentElement.dir||"ltr").toLowerCase()=="ltr"; -}; -_5.docScroll=function docScroll(doc){ -doc=doc||_2.doc; -var _1e=_2.doc.parentWindow||_2.doc.defaultView; -return "pageXOffset" in _1e?{x:_1e.pageXOffset,y:_1e.pageYOffset}:(_1e=_1("quirks")?_2.body(doc):doc.documentElement)&&{x:_5.fixIeBiDiScrollLeft(_1e.scrollLeft||0,doc),y:_1e.scrollTop||0}; -}; -if(_1("ie")){ -_5.getIeDocumentElementOffset=function getIeDocumentElementOffset(doc){ -doc=doc||_2.doc; -var de=doc.documentElement; -if(_1("ie")<8){ -var r=de.getBoundingClientRect(),l=r.left,t=r.top; -if(_1("ie")<7){ -l+=de.clientLeft; -t+=de.clientTop; -} -return {x:l<0?0:l,y:t<0?0:t}; -}else{ -return {x:0,y:0}; -} -}; -} -_5.fixIeBiDiScrollLeft=function fixIeBiDiScrollLeft(_1f,doc){ -doc=doc||_2.doc; -var ie=_1("ie"); -if(ie&&!_5.isBodyLtr(doc)){ -var qk=_1("quirks"),de=qk?_2.body(doc):doc.documentElement,_20=_2.global; -if(ie==6&&!qk&&_20.frameElement&&de.scrollHeight>de.clientHeight){ -_1f+=de.clientLeft; -} -return (ie<8||qk)?(_1f+de.clientWidth-de.scrollWidth):-_1f; -} -return _1f; -}; -_5.position=function(_21,_22){ -_21=_3.byId(_21); -var db=_2.body(_21.ownerDocument),ret=_21.getBoundingClientRect(); -ret={x:ret.left,y:ret.top,w:ret.right-ret.left,h:ret.bottom-ret.top}; -if(_1("ie")<9){ -var _23=_5.getIeDocumentElementOffset(_21.ownerDocument); -ret.x-=_23.x+(_1("quirks")?db.clientLeft+db.offsetLeft:0); -ret.y-=_23.y+(_1("quirks")?db.clientTop+db.offsetTop:0); -} -if(_22){ -var _24=_5.docScroll(_21.ownerDocument); -ret.x+=_24.x; -ret.y+=_24.y; -} -return ret; -}; -_5.getMarginSize=function getMarginSize(_25,_26){ -_25=_3.byId(_25); -var me=_5.getMarginExtents(_25,_26||_4.getComputedStyle(_25)); -var _27=_25.getBoundingClientRect(); -return {w:(_27.right-_27.left)+me.w,h:(_27.bottom-_27.top)+me.h}; -}; -_5.normalizeEvent=function(_28){ -if(!("layerX" in _28)){ -_28.layerX=_28.offsetX; -_28.layerY=_28.offsetY; -} -if(!_1("dom-addeventlistener")){ -var se=_28.target; -var doc=(se&&se.ownerDocument)||document; -var _29=_1("quirks")?doc.body:doc.documentElement; -var _2a=_5.getIeDocumentElementOffset(doc); -_28.pageX=_28.clientX+_5.fixIeBiDiScrollLeft(_29.scrollLeft||0,doc)-_2a.x; -_28.pageY=_28.clientY+(_29.scrollTop||0)-_2a.y; -} -}; -return _5; -}); diff --git a/lib/dojo/dom-geometry.js.uncompressed.js b/lib/dojo/dom-geometry.js.uncompressed.js deleted file mode 100644 index a5d7518..0000000 --- a/lib/dojo/dom-geometry.js.uncompressed.js +++ /dev/null @@ -1,605 +0,0 @@ -define("dojo/dom-geometry", ["./sniff", "./_base/window","./dom", "./dom-style"], - function(has, win, dom, style){ - // module: - // dojo/dom-geometry - - // the result object - var geom = { - // summary: - // This module defines the core dojo DOM geometry API. - }; - - // Box functions will assume this model. - // On IE/Opera, BORDER_BOX will be set if the primary document is in quirks mode. - // Can be set to change behavior of box setters. - - // can be either: - // "border-box" - // "content-box" (default) - geom.boxModel = "content-box"; - - // We punt per-node box mode testing completely. - // If anybody cares, we can provide an additional (optional) unit - // that overrides existing code to include per-node box sensitivity. - - // Opera documentation claims that Opera 9 uses border-box in BackCompat mode. - // but experiments (Opera 9.10.8679 on Windows Vista) indicate that it actually continues to use content-box. - // IIRC, earlier versions of Opera did in fact use border-box. - // Opera guys, this is really confusing. Opera being broken in quirks mode is not our fault. - - if(has("ie") /*|| has("opera")*/){ - // client code may have to adjust if compatMode varies across iframes - geom.boxModel = document.compatMode == "BackCompat" ? "border-box" : "content-box"; - } - - geom.getPadExtents = function getPadExtents(/*DomNode*/ node, /*Object*/ computedStyle){ - // summary: - // Returns object with special values specifically useful for node - // fitting. - // description: - // Returns an object with `w`, `h`, `l`, `t` properties: - // | l/t/r/b = left/top/right/bottom padding (respectively) - // | w = the total of the left and right padding - // | h = the total of the top and bottom padding - // If 'node' has position, l/t forms the origin for child nodes. - // The w/h are used for calculating boxes. - // Normally application code will not need to invoke this - // directly, and will use the ...box... functions instead. - // node: DOMNode - // computedStyle: Object? - // This parameter accepts computed styles object. - // If this parameter is omitted, the functions will call - // dojo/dom-style.getComputedStyle to get one. It is a better way, calling - // dojo/dom-style.getComputedStyle once, and then pass the reference to this - // computedStyle parameter. Wherever possible, reuse the returned - // object of dojo/dom-style.getComputedStyle(). - - node = dom.byId(node); - var s = computedStyle || style.getComputedStyle(node), px = style.toPixelValue, - l = px(node, s.paddingLeft), t = px(node, s.paddingTop), r = px(node, s.paddingRight), b = px(node, s.paddingBottom); - return {l: l, t: t, r: r, b: b, w: l + r, h: t + b}; - }; - - var none = "none"; - - geom.getBorderExtents = function getBorderExtents(/*DomNode*/ node, /*Object*/ computedStyle){ - // summary: - // returns an object with properties useful for noting the border - // dimensions. - // description: - // - l/t/r/b = the sum of left/top/right/bottom border (respectively) - // - w = the sum of the left and right border - // - h = the sum of the top and bottom border - // - // The w/h are used for calculating boxes. - // Normally application code will not need to invoke this - // directly, and will use the ...box... functions instead. - // node: DOMNode - // computedStyle: Object? - // This parameter accepts computed styles object. - // If this parameter is omitted, the functions will call - // dojo/dom-style.getComputedStyle to get one. It is a better way, calling - // dojo/dom-style.getComputedStyle once, and then pass the reference to this - // computedStyle parameter. Wherever possible, reuse the returned - // object of dojo/dom-style.getComputedStyle(). - - node = dom.byId(node); - var px = style.toPixelValue, s = computedStyle || style.getComputedStyle(node), - l = s.borderLeftStyle != none ? px(node, s.borderLeftWidth) : 0, - t = s.borderTopStyle != none ? px(node, s.borderTopWidth) : 0, - r = s.borderRightStyle != none ? px(node, s.borderRightWidth) : 0, - b = s.borderBottomStyle != none ? px(node, s.borderBottomWidth) : 0; - return {l: l, t: t, r: r, b: b, w: l + r, h: t + b}; - }; - - geom.getPadBorderExtents = function getPadBorderExtents(/*DomNode*/ node, /*Object*/ computedStyle){ - // summary: - // Returns object with properties useful for box fitting with - // regards to padding. - // description: - // - l/t/r/b = the sum of left/top/right/bottom padding and left/top/right/bottom border (respectively) - // - w = the sum of the left and right padding and border - // - h = the sum of the top and bottom padding and border - // - // The w/h are used for calculating boxes. - // Normally application code will not need to invoke this - // directly, and will use the ...box... functions instead. - // node: DOMNode - // computedStyle: Object? - // This parameter accepts computed styles object. - // If this parameter is omitted, the functions will call - // dojo/dom-style.getComputedStyle to get one. It is a better way, calling - // dojo/dom-style.getComputedStyle once, and then pass the reference to this - // computedStyle parameter. Wherever possible, reuse the returned - // object of dojo/dom-style.getComputedStyle(). - - node = dom.byId(node); - var s = computedStyle || style.getComputedStyle(node), - p = geom.getPadExtents(node, s), - b = geom.getBorderExtents(node, s); - return { - l: p.l + b.l, - t: p.t + b.t, - r: p.r + b.r, - b: p.b + b.b, - w: p.w + b.w, - h: p.h + b.h - }; - }; - - geom.getMarginExtents = function getMarginExtents(node, computedStyle){ - // summary: - // returns object with properties useful for box fitting with - // regards to box margins (i.e., the outer-box). - // - // - l/t = marginLeft, marginTop, respectively - // - w = total width, margin inclusive - // - h = total height, margin inclusive - // - // The w/h are used for calculating boxes. - // Normally application code will not need to invoke this - // directly, and will use the ...box... functions instead. - // node: DOMNode - // computedStyle: Object? - // This parameter accepts computed styles object. - // If this parameter is omitted, the functions will call - // dojo/dom-style.getComputedStyle to get one. It is a better way, calling - // dojo/dom-style.getComputedStyle once, and then pass the reference to this - // computedStyle parameter. Wherever possible, reuse the returned - // object of dojo/dom-style.getComputedStyle(). - - node = dom.byId(node); - var s = computedStyle || style.getComputedStyle(node), px = style.toPixelValue, - l = px(node, s.marginLeft), t = px(node, s.marginTop), r = px(node, s.marginRight), b = px(node, s.marginBottom); - return {l: l, t: t, r: r, b: b, w: l + r, h: t + b}; - }; - - // Box getters work in any box context because offsetWidth/clientWidth - // are invariant wrt box context - // - // They do *not* work for display: inline objects that have padding styles - // because the user agent ignores padding (it's bogus styling in any case) - // - // Be careful with IMGs because they are inline or block depending on - // browser and browser mode. - - // Although it would be easier to read, there are not separate versions of - // _getMarginBox for each browser because: - // 1. the branching is not expensive - // 2. factoring the shared code wastes cycles (function call overhead) - // 3. duplicating the shared code wastes bytes - - geom.getMarginBox = function getMarginBox(/*DomNode*/ node, /*Object*/ computedStyle){ - // summary: - // returns an object that encodes the width, height, left and top - // positions of the node's margin box. - // node: DOMNode - // computedStyle: Object? - // This parameter accepts computed styles object. - // If this parameter is omitted, the functions will call - // dojo/dom-style.getComputedStyle to get one. It is a better way, calling - // dojo/dom-style.getComputedStyle once, and then pass the reference to this - // computedStyle parameter. Wherever possible, reuse the returned - // object of dojo/dom-style.getComputedStyle(). - - node = dom.byId(node); - var s = computedStyle || style.getComputedStyle(node), me = geom.getMarginExtents(node, s), - l = node.offsetLeft - me.l, t = node.offsetTop - me.t, p = node.parentNode, px = style.toPixelValue, pcs; - if(has("mozilla")){ - // Mozilla: - // If offsetParent has a computed overflow != visible, the offsetLeft is decreased - // by the parent's border. - // We don't want to compute the parent's style, so instead we examine node's - // computed left/top which is more stable. - var sl = parseFloat(s.left), st = parseFloat(s.top); - if(!isNaN(sl) && !isNaN(st)){ - l = sl; - t = st; - }else{ - // If child's computed left/top are not parseable as a number (e.g. "auto"), we - // have no choice but to examine the parent's computed style. - if(p && p.style){ - pcs = style.getComputedStyle(p); - if(pcs.overflow != "visible"){ - l += pcs.borderLeftStyle != none ? px(node, pcs.borderLeftWidth) : 0; - t += pcs.borderTopStyle != none ? px(node, pcs.borderTopWidth) : 0; - } - } - } - }else if(has("opera") || (has("ie") == 8 && !has("quirks"))){ - // On Opera and IE 8, offsetLeft/Top includes the parent's border - if(p){ - pcs = style.getComputedStyle(p); - l -= pcs.borderLeftStyle != none ? px(node, pcs.borderLeftWidth) : 0; - t -= pcs.borderTopStyle != none ? px(node, pcs.borderTopWidth) : 0; - } - } - return {l: l, t: t, w: node.offsetWidth + me.w, h: node.offsetHeight + me.h}; - }; - - geom.getContentBox = function getContentBox(node, computedStyle){ - // summary: - // Returns an object that encodes the width, height, left and top - // positions of the node's content box, irrespective of the - // current box model. - // node: DOMNode - // computedStyle: Object? - // This parameter accepts computed styles object. - // If this parameter is omitted, the functions will call - // dojo/dom-style.getComputedStyle to get one. It is a better way, calling - // dojo/dom-style.getComputedStyle once, and then pass the reference to this - // computedStyle parameter. Wherever possible, reuse the returned - // object of dojo/dom-style.getComputedStyle(). - - // clientWidth/Height are important since the automatically account for scrollbars - // fallback to offsetWidth/Height for special cases (see #3378) - node = dom.byId(node); - var s = computedStyle || style.getComputedStyle(node), w = node.clientWidth, h, - pe = geom.getPadExtents(node, s), be = geom.getBorderExtents(node, s); - if(!w){ - w = node.offsetWidth; - h = node.offsetHeight; - }else{ - h = node.clientHeight; - be.w = be.h = 0; - } - // On Opera, offsetLeft includes the parent's border - if(has("opera")){ - pe.l += be.l; - pe.t += be.t; - } - return {l: pe.l, t: pe.t, w: w - pe.w - be.w, h: h - pe.h - be.h}; - }; - - // Box setters depend on box context because interpretation of width/height styles - // vary wrt box context. - // - // The value of boxModel is used to determine box context. - // boxModel can be set directly to change behavior. - // - // Beware of display: inline objects that have padding styles - // because the user agent ignores padding (it's a bogus setup anyway) - // - // Be careful with IMGs because they are inline or block depending on - // browser and browser mode. - // - // Elements other than DIV may have special quirks, like built-in - // margins or padding, or values not detectable via computedStyle. - // In particular, margins on TABLE do not seems to appear - // at all in computedStyle on Mozilla. - - function setBox(/*DomNode*/ node, /*Number?*/ l, /*Number?*/ t, /*Number?*/ w, /*Number?*/ h, /*String?*/ u){ - // summary: - // sets width/height/left/top in the current (native) box-model - // dimensions. Uses the unit passed in u. - // node: - // DOM Node reference. Id string not supported for performance - // reasons. - // l: - // left offset from parent. - // t: - // top offset from parent. - // w: - // width in current box model. - // h: - // width in current box model. - // u: - // unit measure to use for other measures. Defaults to "px". - u = u || "px"; - var s = node.style; - if(!isNaN(l)){ - s.left = l + u; - } - if(!isNaN(t)){ - s.top = t + u; - } - if(w >= 0){ - s.width = w + u; - } - if(h >= 0){ - s.height = h + u; - } - } - - function isButtonTag(/*DomNode*/ node){ - // summary: - // True if the node is BUTTON or INPUT.type="button". - return node.tagName.toLowerCase() == "button" || - node.tagName.toLowerCase() == "input" && (node.getAttribute("type") || "").toLowerCase() == "button"; // boolean - } - - function usesBorderBox(/*DomNode*/ node){ - // summary: - // True if the node uses border-box layout. - - // We could test the computed style of node to see if a particular box - // has been specified, but there are details and we choose not to bother. - - // TABLE and BUTTON (and INPUT type=button) are always border-box by default. - // If you have assigned a different box to either one via CSS then - // box functions will break. - - return geom.boxModel == "border-box" || node.tagName.toLowerCase() == "table" || isButtonTag(node); // boolean - } - - geom.setContentSize = function setContentSize(/*DomNode*/ node, /*Object*/ box, /*Object*/ computedStyle){ - // summary: - // Sets the size of the node's contents, irrespective of margins, - // padding, or borders. - // node: DOMNode - // box: Object - // hash with optional "w", and "h" properties for "width", and "height" - // respectively. All specified properties should have numeric values in whole pixels. - // computedStyle: Object? - // This parameter accepts computed styles object. - // If this parameter is omitted, the functions will call - // dojo/dom-style.getComputedStyle to get one. It is a better way, calling - // dojo/dom-style.getComputedStyle once, and then pass the reference to this - // computedStyle parameter. Wherever possible, reuse the returned - // object of dojo/dom-style.getComputedStyle(). - - node = dom.byId(node); - var w = box.w, h = box.h; - if(usesBorderBox(node)){ - var pb = geom.getPadBorderExtents(node, computedStyle); - if(w >= 0){ - w += pb.w; - } - if(h >= 0){ - h += pb.h; - } - } - setBox(node, NaN, NaN, w, h); - }; - - var nilExtents = {l: 0, t: 0, w: 0, h: 0}; - - geom.setMarginBox = function setMarginBox(/*DomNode*/ node, /*Object*/ box, /*Object*/ computedStyle){ - // summary: - // sets the size of the node's margin box and placement - // (left/top), irrespective of box model. Think of it as a - // passthrough to setBox that handles box-model vagaries for - // you. - // node: DOMNode - // box: Object - // hash with optional "l", "t", "w", and "h" properties for "left", "right", "width", and "height" - // respectively. All specified properties should have numeric values in whole pixels. - // computedStyle: Object? - // This parameter accepts computed styles object. - // If this parameter is omitted, the functions will call - // dojo/dom-style.getComputedStyle to get one. It is a better way, calling - // dojo/dom-style.getComputedStyle once, and then pass the reference to this - // computedStyle parameter. Wherever possible, reuse the returned - // object of dojo/dom-style.getComputedStyle(). - - node = dom.byId(node); - var s = computedStyle || style.getComputedStyle(node), w = box.w, h = box.h, - // Some elements have special padding, margin, and box-model settings. - // To use box functions you may need to set padding, margin explicitly. - // Controlling box-model is harder, in a pinch you might set dojo/dom-geometry.boxModel. - pb = usesBorderBox(node) ? nilExtents : geom.getPadBorderExtents(node, s), - mb = geom.getMarginExtents(node, s); - if(has("webkit")){ - // on Safari (3.1.2), button nodes with no explicit size have a default margin - // setting an explicit size eliminates the margin. - // We have to swizzle the width to get correct margin reading. - if(isButtonTag(node)){ - var ns = node.style; - if(w >= 0 && !ns.width){ - ns.width = "4px"; - } - if(h >= 0 && !ns.height){ - ns.height = "4px"; - } - } - } - if(w >= 0){ - w = Math.max(w - pb.w - mb.w, 0); - } - if(h >= 0){ - h = Math.max(h - pb.h - mb.h, 0); - } - setBox(node, box.l, box.t, w, h); - }; - - // ============================= - // Positioning - // ============================= - - geom.isBodyLtr = function isBodyLtr(/*Document?*/ doc){ - // summary: - // Returns true if the current language is left-to-right, and false otherwise. - // doc: Document? - // Optional document to query. If unspecified, use win.doc. - // returns: Boolean - - doc = doc || win.doc; - return (win.body(doc).dir || doc.documentElement.dir || "ltr").toLowerCase() == "ltr"; // Boolean - }; - - geom.docScroll = function docScroll(/*Document?*/ doc){ - // summary: - // Returns an object with {node, x, y} with corresponding offsets. - // doc: Document? - // Optional document to query. If unspecified, use win.doc. - // returns: Object - - doc = doc || win.doc; - var node = win.doc.parentWindow || win.doc.defaultView; // use UI window, not dojo.global window. TODO: use dojo/window::get() except for circular dependency problem - return "pageXOffset" in node ? {x: node.pageXOffset, y: node.pageYOffset } : - (node = has("quirks") ? win.body(doc) : doc.documentElement) && - {x: geom.fixIeBiDiScrollLeft(node.scrollLeft || 0, doc), y: node.scrollTop || 0 }; - }; - - if(has("ie")){ - geom.getIeDocumentElementOffset = function getIeDocumentElementOffset(/*Document?*/ doc){ - // summary: - // returns the offset in x and y from the document body to the - // visual edge of the page for IE - // doc: Document? - // Optional document to query. If unspecified, use win.doc. - // description: - // The following values in IE contain an offset: - // | event.clientX - // | event.clientY - // | node.getBoundingClientRect().left - // | node.getBoundingClientRect().top - // But other position related values do not contain this offset, - // such as node.offsetLeft, node.offsetTop, node.style.left and - // node.style.top. The offset is always (2, 2) in LTR direction. - // When the body is in RTL direction, the offset counts the width - // of left scroll bar's width. This function computes the actual - // offset. - - //NOTE: assumes we're being called in an IE browser - - doc = doc || win.doc; - var de = doc.documentElement; // only deal with HTML element here, position() handles body/quirks - - if(has("ie") < 8){ - var r = de.getBoundingClientRect(), // works well for IE6+ - l = r.left, t = r.top; - if(has("ie") < 7){ - l += de.clientLeft; // scrollbar size in strict/RTL, or, - t += de.clientTop; // HTML border size in strict - } - return { - x: l < 0 ? 0 : l, // FRAME element border size can lead to inaccurate negative values - y: t < 0 ? 0 : t - }; - }else{ - return { - x: 0, - y: 0 - }; - } - }; - } - - geom.fixIeBiDiScrollLeft = function fixIeBiDiScrollLeft(/*Integer*/ scrollLeft, /*Document?*/ doc){ - // summary: - // In RTL direction, scrollLeft should be a negative value, but IE - // returns a positive one. All codes using documentElement.scrollLeft - // must call this function to fix this error, otherwise the position - // will offset to right when there is a horizontal scrollbar. - // scrollLeft: Number - // doc: Document? - // Optional document to query. If unspecified, use win.doc. - // returns: Number - - // In RTL direction, scrollLeft should be a negative value, but IE - // returns a positive one. All codes using documentElement.scrollLeft - // must call this function to fix this error, otherwise the position - // will offset to right when there is a horizontal scrollbar. - - doc = doc || win.doc; - var ie = has("ie"); - if(ie && !geom.isBodyLtr(doc)){ - var qk = has("quirks"), - de = qk ? win.body(doc) : doc.documentElement, - pwin = win.global; // TODO: use winUtils.get(doc) after resolving circular dependency b/w dom-geometry.js and dojo/window.js - if(ie == 6 && !qk && pwin.frameElement && de.scrollHeight > de.clientHeight){ - scrollLeft += de.clientLeft; // workaround ie6+strict+rtl+iframe+vertical-scrollbar bug where clientWidth is too small by clientLeft pixels - } - return (ie < 8 || qk) ? (scrollLeft + de.clientWidth - de.scrollWidth) : -scrollLeft; // Integer - } - return scrollLeft; // Integer - }; - - geom.position = function(/*DomNode*/ node, /*Boolean?*/ includeScroll){ - // summary: - // Gets the position and size of the passed element relative to - // the viewport (if includeScroll==false), or relative to the - // document root (if includeScroll==true). - // - // description: - // Returns an object of the form: - // `{ x: 100, y: 300, w: 20, h: 15 }`. - // If includeScroll==true, the x and y values will include any - // document offsets that may affect the position relative to the - // viewport. - // Uses the border-box model (inclusive of border and padding but - // not margin). Does not act as a setter. - // node: DOMNode|String - // includeScroll: Boolean? - // returns: Object - - node = dom.byId(node); - var db = win.body(node.ownerDocument), - ret = node.getBoundingClientRect(); - ret = {x: ret.left, y: ret.top, w: ret.right - ret.left, h: ret.bottom - ret.top}; - - if(has("ie") < 9){ - // On IE<9 there's a 2px offset that we need to adjust for, see dojo.getIeDocumentElementOffset() - var offset = geom.getIeDocumentElementOffset(node.ownerDocument); - - // fixes the position in IE, quirks mode - ret.x -= offset.x + (has("quirks") ? db.clientLeft + db.offsetLeft : 0); - ret.y -= offset.y + (has("quirks") ? db.clientTop + db.offsetTop : 0); - } - - // account for document scrolling - // if offsetParent is used, ret value already includes scroll position - // so we may have to actually remove that value if !includeScroll - if(includeScroll){ - var scroll = geom.docScroll(node.ownerDocument); - ret.x += scroll.x; - ret.y += scroll.y; - } - - return ret; // Object - }; - - // random "private" functions wildly used throughout the toolkit - - geom.getMarginSize = function getMarginSize(/*DomNode*/ node, /*Object*/ computedStyle){ - // summary: - // returns an object that encodes the width and height of - // the node's margin box - // node: DOMNode|String - // computedStyle: Object? - // This parameter accepts computed styles object. - // If this parameter is omitted, the functions will call - // dojo/dom-style.getComputedStyle to get one. It is a better way, calling - // dojo/dom-style.getComputedStyle once, and then pass the reference to this - // computedStyle parameter. Wherever possible, reuse the returned - // object of dojo/dom-style.getComputedStyle(). - - node = dom.byId(node); - var me = geom.getMarginExtents(node, computedStyle || style.getComputedStyle(node)); - var size = node.getBoundingClientRect(); - return { - w: (size.right - size.left) + me.w, - h: (size.bottom - size.top) + me.h - }; - }; - - geom.normalizeEvent = function(event){ - // summary: - // Normalizes the geometry of a DOM event, normalizing the pageX, pageY, - // offsetX, offsetY, layerX, and layerX properties - // event: Object - if(!("layerX" in event)){ - event.layerX = event.offsetX; - event.layerY = event.offsetY; - } - if(!has("dom-addeventlistener")){ - // old IE version - // FIXME: scroll position query is duped from dojo/_base/html to - // avoid dependency on that entire module. Now that HTML is in - // Base, we should convert back to something similar there. - var se = event.target; - var doc = (se && se.ownerDocument) || document; - // DO NOT replace the following to use dojo/_base/window.body(), in IE, document.documentElement should be used - // here rather than document.body - var docBody = has("quirks") ? doc.body : doc.documentElement; - var offset = geom.getIeDocumentElementOffset(doc); - event.pageX = event.clientX + geom.fixIeBiDiScrollLeft(docBody.scrollLeft || 0, doc) - offset.x; - event.pageY = event.clientY + (docBody.scrollTop || 0) - offset.y; - } - }; - - // TODO: evaluate separate getters/setters for position and sizes? - - return geom; -}); diff --git a/lib/dojo/dom-prop.js b/lib/dojo/dom-prop.js deleted file mode 100644 index 1f61a0f..0000000 --- a/lib/dojo/dom-prop.js +++ /dev/null @@ -1,92 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/dom-prop",["exports","./_base/kernel","./sniff","./_base/lang","./dom","./dom-style","./dom-construct","./_base/connect"],function(_1,_2,_3,_4,_5,_6,_7,_8){ -var _9={},_a=0,_b=_2._scopeName+"attrid"; -_3.add("dom-textContent",function(_c,_d,_e){ -return "textContent" in _e; -}); -_1.names={"class":"className","for":"htmlFor",tabindex:"tabIndex",readonly:"readOnly",colspan:"colSpan",frameborder:"frameBorder",rowspan:"rowSpan",textcontent:"textContent",valuetype:"valueType"}; -function _f(_10){ -var _11="",ch=_10.childNodes; -for(var i=0,n;n=ch[i];i++){ -if(n.nodeType!=8){ -if(n.nodeType==1){ -_11+=_f(n); -}else{ -_11+=n.nodeValue; -} -} -} -return _11; -}; -_1.get=function getProp(_12,_13){ -_12=_5.byId(_12); -var lc=_13.toLowerCase(),_14=_1.names[lc]||_13; -if(_14=="textContent"&&!_3("dom-textContent")){ -return _f(_12); -} -return _12[_14]; -}; -_1.set=function setProp(_15,_16,_17){ -_15=_5.byId(_15); -var l=arguments.length; -if(l==2&&typeof _16!="string"){ -for(var x in _16){ -_1.set(_15,x,_16[x]); -} -return _15; -} -var lc=_16.toLowerCase(),_18=_1.names[lc]||_16; -if(_18=="style"&&typeof _17!="string"){ -_6.set(_15,_17); -return _15; -} -if(_18=="innerHTML"){ -if(_3("ie")&&_15.tagName.toLowerCase() in {col:1,colgroup:1,table:1,tbody:1,tfoot:1,thead:1,tr:1,title:1}){ -_7.empty(_15); -_15.appendChild(_7.toDom(_17,_15.ownerDocument)); -}else{ -_15[_18]=_17; -} -return _15; -} -if(_18=="textContent"&&!_3("dom-textContent")){ -_7.empty(_15); -_15.appendChild(_15.ownerDocument.createTextNode(_17)); -return _15; -} -if(_4.isFunction(_17)){ -var _19=_15[_b]; -if(!_19){ -_19=_a++; -_15[_b]=_19; -} -if(!_9[_19]){ -_9[_19]={}; -} -var h=_9[_19][_18]; -if(h){ -_8.disconnect(h); -}else{ -try{ -delete _15[_18]; -} -catch(e){ -} -} -if(_17){ -_9[_19][_18]=_8.connect(_15,_18,_17); -}else{ -_15[_18]=null; -} -return _15; -} -_15[_18]=_17; -return _15; -}; -}); diff --git a/lib/dojo/dom-prop.js.uncompressed.js b/lib/dojo/dom-prop.js.uncompressed.js deleted file mode 100644 index 1a84b55..0000000 --- a/lib/dojo/dom-prop.js.uncompressed.js +++ /dev/null @@ -1,188 +0,0 @@ -define("dojo/dom-prop", ["exports", "./_base/kernel", "./sniff", "./_base/lang", "./dom", "./dom-style", "./dom-construct", "./_base/connect"], - function(exports, dojo, has, lang, dom, style, ctr, conn){ - // module: - // dojo/dom-prop - // summary: - // This module defines the core dojo DOM properties API. - - // TODOC: summary not showing up in output, see https://github.com/csnover/js-doc-parse/issues/42 - - // ============================= - // Element properties Functions - // ============================= - - // helper to connect events - var _evtHdlrMap = {}, _ctr = 0, _attrId = dojo._scopeName + "attrid"; - has.add('dom-textContent', function (global, doc, element) { return 'textContent' in element; }); - - exports.names = { - // properties renamed to avoid clashes with reserved words - "class": "className", - "for": "htmlFor", - // properties written as camelCase - tabindex: "tabIndex", - readonly: "readOnly", - colspan: "colSpan", - frameborder: "frameBorder", - rowspan: "rowSpan", - textcontent: "textContent", - valuetype: "valueType" - }; - - function getText(/*DOMNode*/node){ - // summary: - // recursion method for get('textContent') to use. Gets text value for a node. - // description: - // Juse uses nodedValue so things like
    tags do not end up in - // the text as any sort of line return. - var text = "", ch = node.childNodes; - for(var i = 0, n; n = ch[i]; i++){ - //Skip comments. - if(n.nodeType != 8){ - if(n.nodeType == 1){ - text += getText(n); - }else{ - text += n.nodeValue; - } - } - } - return text; - } - - exports.get = function getProp(/*DOMNode|String*/ node, /*String*/ name){ - // summary: - // Gets a property on an HTML element. - // description: - // Handles normalized getting of properties on DOM nodes. - // - // node: DOMNode|String - // id or reference to the element to get the property on - // name: String - // the name of the property to get. - // returns: - // the value of the requested property or its default value - // - // example: - // | // get the current value of the "foo" property on a node - // | require(["dojo/dom-prop", "dojo/dom"], function(domProp, dom){ - // | domProp.get(dom.byId("nodeId"), "foo"); - // | // or we can just pass the id: - // | domProp.get("nodeId", "foo"); - // | }); - - node = dom.byId(node); - var lc = name.toLowerCase(), propName = exports.names[lc] || name; - - if(propName == "textContent" && !has("dom-textContent")){ - return getText(node); - } - - return node[propName]; // Anything - }; - - exports.set = function setProp(/*DOMNode|String*/ node, /*String|Object*/ name, /*String?*/ value){ - // summary: - // Sets a property on an HTML element. - // description: - // Handles normalized setting of properties on DOM nodes. - // - // When passing functions as values, note that they will not be - // directly assigned to slots on the node, but rather the default - // behavior will be removed and the new behavior will be added - // using `dojo.connect()`, meaning that event handler properties - // will be normalized and that some caveats with regards to - // non-standard behaviors for onsubmit apply. Namely that you - // should cancel form submission using `dojo.stopEvent()` on the - // passed event object instead of returning a boolean value from - // the handler itself. - // node: DOMNode|String - // id or reference to the element to set the property on - // name: String|Object - // the name of the property to set, or a hash object to set - // multiple properties at once. - // value: String? - // The value to set for the property - // returns: - // the DOM node - // - // example: - // | // use prop() to set the tab index - // | require(["dojo/dom-prop"], function(domProp){ - // | domProp.set("nodeId", "tabIndex", 3); - // | }); - // - // example: - // Set multiple values at once, including event handlers: - // | require(["dojo/dom-prop"], function(domProp){ - // | domProp.set("formId", { - // | "foo": "bar", - // | "tabIndex": -1, - // | "method": "POST", - // | }); - // | }); - - node = dom.byId(node); - var l = arguments.length; - if(l == 2 && typeof name != "string"){ // inline'd type check - // the object form of setter: the 2nd argument is a dictionary - for(var x in name){ - exports.set(node, x, name[x]); - } - return node; // DomNode - } - var lc = name.toLowerCase(), propName = exports.names[lc] || name; - if(propName == "style" && typeof value != "string"){ // inline'd type check - // special case: setting a style - style.set(node, value); - return node; // DomNode - } - if(propName == "innerHTML"){ - // special case: assigning HTML - // the hash lists elements with read-only innerHTML on IE - if(has("ie") && node.tagName.toLowerCase() in {col: 1, colgroup: 1, - table: 1, tbody: 1, tfoot: 1, thead: 1, tr: 1, title: 1}){ - ctr.empty(node); - node.appendChild(ctr.toDom(value, node.ownerDocument)); - }else{ - node[propName] = value; - } - return node; // DomNode - } - if(propName == "textContent" && !has("dom-textContent")) { - ctr.empty(node); - node.appendChild(node.ownerDocument.createTextNode(value)); - return node; - } - if(lang.isFunction(value)){ - // special case: assigning an event handler - // clobber if we can - var attrId = node[_attrId]; - if(!attrId){ - attrId = _ctr++; - node[_attrId] = attrId; - } - if(!_evtHdlrMap[attrId]){ - _evtHdlrMap[attrId] = {}; - } - var h = _evtHdlrMap[attrId][propName]; - if(h){ - //h.remove(); - conn.disconnect(h); - }else{ - try{ - delete node[propName]; - }catch(e){} - } - // ensure that event objects are normalized, etc. - if(value){ - //_evtHdlrMap[attrId][propName] = on(node, propName, value); - _evtHdlrMap[attrId][propName] = conn.connect(node, propName, value); - }else{ - node[propName] = null; - } - return node; // DomNode - } - node[propName] = value; - return node; // DomNode - }; -}); diff --git a/lib/dojo/dom-style.js b/lib/dojo/dom-style.js deleted file mode 100644 index 86d4e30..0000000 --- a/lib/dojo/dom-style.js +++ /dev/null @@ -1,165 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/dom-style",["./sniff","./dom"],function(_1,_2){ -var _3,_4={}; -if(_1("webkit")){ -_3=function(_5){ -var s; -if(_5.nodeType==1){ -var dv=_5.ownerDocument.defaultView; -s=dv.getComputedStyle(_5,null); -if(!s&&_5.style){ -_5.style.display=""; -s=dv.getComputedStyle(_5,null); -} -} -return s||{}; -}; -}else{ -if(_1("ie")&&(_1("ie")<9||_1("quirks"))){ -_3=function(_6){ -return _6.nodeType==1&&_6.currentStyle?_6.currentStyle:{}; -}; -}else{ -_3=function(_7){ -return _7.nodeType==1?_7.ownerDocument.defaultView.getComputedStyle(_7,null):{}; -}; -} -} -_4.getComputedStyle=_3; -var _8; -if(!_1("ie")){ -_8=function(_9,_a){ -return parseFloat(_a)||0; -}; -}else{ -_8=function(_b,_c){ -if(!_c){ -return 0; -} -if(_c=="medium"){ -return 4; -} -if(_c.slice&&_c.slice(-2)=="px"){ -return parseFloat(_c); -} -var s=_b.style,rs=_b.runtimeStyle,cs=_b.currentStyle,_d=s.left,_e=rs.left; -rs.left=cs.left; -try{ -s.left=_c; -_c=s.pixelLeft; -} -catch(e){ -_c=0; -} -s.left=_d; -rs.left=_e; -return _c; -}; -} -_4.toPixelValue=_8; -var _f="DXImageTransform.Microsoft.Alpha"; -var af=function(n,f){ -try{ -return n.filters.item(_f); -} -catch(e){ -return f?{}:null; -} -}; -var _10=_1("ie")<9||(_1("ie")<10&&_1("quirks"))?function(_11){ -try{ -return af(_11).Opacity/100; -} -catch(e){ -return 1; -} -}:function(_12){ -return _3(_12).opacity; -}; -var _13=_1("ie")<9||(_1("ie")<10&&_1("quirks"))?function(_14,_15){ -if(_15===""){ -_15=1; -} -var ov=_15*100,_16=_15===1; -if(_16){ -_14.style.zoom=""; -if(af(_14)){ -_14.style.filter=_14.style.filter.replace(new RegExp("\\s*progid:"+_f+"\\([^\\)]+?\\)","i"),""); -} -}else{ -_14.style.zoom=1; -if(af(_14)){ -af(_14,1).Opacity=ov; -}else{ -_14.style.filter+=" progid:"+_f+"(Opacity="+ov+")"; -} -af(_14,1).Enabled=true; -} -if(_14.tagName.toLowerCase()=="tr"){ -for(var td=_14.firstChild;td;td=td.nextSibling){ -if(td.tagName.toLowerCase()=="td"){ -_13(td,_15); -} -} -} -return _15; -}:function(_17,_18){ -return _17.style.opacity=_18; -}; -var _19={left:true,top:true}; -var _1a=/margin|padding|width|height|max|min|offset/; -function _1b(_1c,_1d,_1e){ -_1d=_1d.toLowerCase(); -if(_1("ie")||_1("trident")){ -if(_1e=="auto"){ -if(_1d=="height"){ -return _1c.offsetHeight; -} -if(_1d=="width"){ -return _1c.offsetWidth; -} -} -if(_1d=="fontweight"){ -switch(_1e){ -case 700: -return "bold"; -case 400: -default: -return "normal"; -} -} -} -if(!(_1d in _19)){ -_19[_1d]=_1a.test(_1d); -} -return _19[_1d]?_8(_1c,_1e):_1e; -}; -var _1f={cssFloat:1,styleFloat:1,"float":1}; -_4.get=function getStyle(_20,_21){ -var n=_2.byId(_20),l=arguments.length,op=(_21=="opacity"); -if(l==2&&op){ -return _10(n); -} -_21=_1f[_21]?"cssFloat" in n.style?"cssFloat":"styleFloat":_21; -var s=_4.getComputedStyle(n); -return (l==1)?s:_1b(n,_21,s[_21]||n.style[_21]); -}; -_4.set=function setStyle(_22,_23,_24){ -var n=_2.byId(_22),l=arguments.length,op=(_23=="opacity"); -_23=_1f[_23]?"cssFloat" in n.style?"cssFloat":"styleFloat":_23; -if(l==3){ -return op?_13(n,_24):n.style[_23]=_24; -} -for(var x in _23){ -_4.set(_22,x,_23[x]); -} -return _4.getComputedStyle(n); -}; -return _4; -}); diff --git a/lib/dojo/dom-style.js.uncompressed.js b/lib/dojo/dom-style.js.uncompressed.js deleted file mode 100644 index cfcb47e..0000000 --- a/lib/dojo/dom-style.js.uncompressed.js +++ /dev/null @@ -1,329 +0,0 @@ -define("dojo/dom-style", ["./sniff", "./dom"], function(has, dom){ - // module: - // dojo/dom-style - - // ============================= - // Style Functions - // ============================= - - // getComputedStyle drives most of the style code. - // Wherever possible, reuse the returned object. - // - // API functions below that need to access computed styles accept an - // optional computedStyle parameter. - // If this parameter is omitted, the functions will call getComputedStyle themselves. - // This way, calling code can access computedStyle once, and then pass the reference to - // multiple API functions. - - // Although we normally eschew argument validation at this - // level, here we test argument 'node' for (duck)type, - // by testing nodeType, ecause 'document' is the 'parentNode' of 'body' - // it is frequently sent to this function even - // though it is not Element. - var getComputedStyle, style = { - // summary: - // This module defines the core dojo DOM style API. - }; - if(has("webkit")){ - getComputedStyle = function(/*DomNode*/ node){ - var s; - if(node.nodeType == 1){ - var dv = node.ownerDocument.defaultView; - s = dv.getComputedStyle(node, null); - if(!s && node.style){ - node.style.display = ""; - s = dv.getComputedStyle(node, null); - } - } - return s || {}; - }; - }else if(has("ie") && (has("ie") < 9 || has("quirks"))){ - getComputedStyle = function(node){ - // IE (as of 7) doesn't expose Element like sane browsers - // currentStyle can be null on IE8! - return node.nodeType == 1 /* ELEMENT_NODE*/ && node.currentStyle ? node.currentStyle : {}; - }; - }else{ - getComputedStyle = function(node){ - return node.nodeType == 1 /* ELEMENT_NODE*/ ? - node.ownerDocument.defaultView.getComputedStyle(node, null) : {}; - }; - } - style.getComputedStyle = getComputedStyle; - /*===== - style.getComputedStyle = function(node){ - // summary: - // Returns a "computed style" object. - // - // description: - // Gets a "computed style" object which can be used to gather - // information about the current state of the rendered node. - // - // Note that this may behave differently on different browsers. - // Values may have different formats and value encodings across - // browsers. - // - // Note also that this method is expensive. Wherever possible, - // reuse the returned object. - // - // Use the dojo/dom-style.get() method for more consistent (pixelized) - // return values. - // - // node: DOMNode - // A reference to a DOM node. Does NOT support taking an - // ID string for speed reasons. - // example: - // | require(["dojo/dom-style", "dojo/dom"], function(domStyle, dom){ - // | domStyle.getComputedStyle(dom.byId('foo')).borderWidth; - // | }); - // - // example: - // Reusing the returned object, avoiding multiple lookups: - // | require(["dojo/dom-style", "dojo/dom"], function(domStyle, dom){ - // | var cs = domStyle.getComputedStyle(dom.byId("someNode")); - // | var w = cs.width, h = cs.height; - // | }); - return; // CSS2Properties - }; - =====*/ - - var toPixel; - if(!has("ie")){ - toPixel = function(element, value){ - // style values can be floats, client code may want - // to round for integer pixels. - return parseFloat(value) || 0; - }; - }else{ - toPixel = function(element, avalue){ - if(!avalue){ return 0; } - // on IE7, medium is usually 4 pixels - if(avalue == "medium"){ return 4; } - // style values can be floats, client code may - // want to round this value for integer pixels. - if(avalue.slice && avalue.slice(-2) == 'px'){ return parseFloat(avalue); } - var s = element.style, rs = element.runtimeStyle, cs = element.currentStyle, - sLeft = s.left, rsLeft = rs.left; - rs.left = cs.left; - try{ - // 'avalue' may be incompatible with style.left, which can cause IE to throw - // this has been observed for border widths using "thin", "medium", "thick" constants - // those particular constants could be trapped by a lookup - // but perhaps there are more - s.left = avalue; - avalue = s.pixelLeft; - }catch(e){ - avalue = 0; - } - s.left = sLeft; - rs.left = rsLeft; - return avalue; - }; - } - style.toPixelValue = toPixel; - /*===== - style.toPixelValue = function(node, value){ - // summary: - // converts style value to pixels on IE or return a numeric value. - // node: DOMNode - // value: String - // returns: Number - }; - =====*/ - - // FIXME: there opacity quirks on FF that we haven't ported over. Hrm. - - var astr = "DXImageTransform.Microsoft.Alpha"; - var af = function(n, f){ - try{ - return n.filters.item(astr); - }catch(e){ - return f ? {} : null; - } - }; - - var _getOpacity = - has("ie") < 9 || (has("ie") < 10 && has("quirks")) ? function(node){ - try{ - return af(node).Opacity / 100; // Number - }catch(e){ - return 1; // Number - } - } : - function(node){ - return getComputedStyle(node).opacity; - }; - - var _setOpacity = - has("ie") < 9 || (has("ie") < 10 && has("quirks")) ? function(/*DomNode*/ node, /*Number*/ opacity){ - if(opacity === ""){ opacity = 1; } - var ov = opacity * 100, fullyOpaque = opacity === 1; - - // on IE7 Alpha(Filter opacity=100) makes text look fuzzy so disable it altogether (bug #2661), - // but still update the opacity value so we can get a correct reading if it is read later: - // af(node, 1).Enabled = !fullyOpaque; - - if(fullyOpaque){ - node.style.zoom = ""; - if(af(node)){ - node.style.filter = node.style.filter.replace( - new RegExp("\\s*progid:" + astr + "\\([^\\)]+?\\)", "i"), ""); - } - }else{ - node.style.zoom = 1; - if(af(node)){ - af(node, 1).Opacity = ov; - }else{ - node.style.filter += " progid:" + astr + "(Opacity=" + ov + ")"; - } - af(node, 1).Enabled = true; - } - - if(node.tagName.toLowerCase() == "tr"){ - for(var td = node.firstChild; td; td = td.nextSibling){ - if(td.tagName.toLowerCase() == "td"){ - _setOpacity(td, opacity); - } - } - } - return opacity; - } : - function(node, opacity){ - return node.style.opacity = opacity; - }; - - var _pixelNamesCache = { - left: true, top: true - }; - var _pixelRegExp = /margin|padding|width|height|max|min|offset/; // |border - function _toStyleValue(node, type, value){ - //TODO: should we really be doing string case conversion here? Should we cache it? Need to profile! - type = type.toLowerCase(); - if(has("ie") || has("trident")){ - if(value == "auto"){ - if(type == "height"){ return node.offsetHeight; } - if(type == "width"){ return node.offsetWidth; } - } - if(type == "fontweight"){ - switch(value){ - case 700: return "bold"; - case 400: - default: return "normal"; - } - } - } - if(!(type in _pixelNamesCache)){ - _pixelNamesCache[type] = _pixelRegExp.test(type); - } - return _pixelNamesCache[type] ? toPixel(node, value) : value; - } - - var _floatAliases = {cssFloat: 1, styleFloat: 1, "float": 1}; - - // public API - - style.get = function getStyle(/*DOMNode|String*/ node, /*String?*/ name){ - // summary: - // Accesses styles on a node. - // description: - // Getting the style value uses the computed style for the node, so the value - // will be a calculated value, not just the immediate node.style value. - // Also when getting values, use specific style names, - // like "borderBottomWidth" instead of "border" since compound values like - // "border" are not necessarily reflected as expected. - // If you want to get node dimensions, use `dojo/dom-geometry.getMarginBox()`, - // `dojo/dom-geometry.getContentBox()` or `dojo/dom-geometry.getPosition()`. - // node: DOMNode|String - // id or reference to node to get style for - // name: String? - // the style property to get - // example: - // Passing only an ID or node returns the computed style object of - // the node: - // | require(["dojo/dom-style", "dojo/dom"], function(domStyle, dom){ - // | domStyle.get("thinger"); - // | }); - // example: - // Passing a node and a style property returns the current - // normalized, computed value for that property: - // | require(["dojo/dom-style", "dojo/dom"], function(domStyle, dom){ - // | domStyle.get("thinger", "opacity"); // 1 by default - // | }); - - var n = dom.byId(node), l = arguments.length, op = (name == "opacity"); - if(l == 2 && op){ - return _getOpacity(n); - } - name = _floatAliases[name] ? "cssFloat" in n.style ? "cssFloat" : "styleFloat" : name; - var s = style.getComputedStyle(n); - return (l == 1) ? s : _toStyleValue(n, name, s[name] || n.style[name]); /* CSS2Properties||String||Number */ - }; - - style.set = function setStyle(/*DOMNode|String*/ node, /*String|Object*/ name, /*String?*/ value){ - // summary: - // Sets styles on a node. - // node: DOMNode|String - // id or reference to node to set style for - // name: String|Object - // the style property to set in DOM-accessor format - // ("borderWidth", not "border-width") or an object with key/value - // pairs suitable for setting each property. - // value: String? - // If passed, sets value on the node for style, handling - // cross-browser concerns. When setting a pixel value, - // be sure to include "px" in the value. For instance, top: "200px". - // Otherwise, in some cases, some browsers will not apply the style. - // - // example: - // Passing a node, a style property, and a value changes the - // current display of the node and returns the new computed value - // | require(["dojo/dom-style"], function(domStyle){ - // | domStyle.set("thinger", "opacity", 0.5); // == 0.5 - // | }); - // - // example: - // Passing a node, an object-style style property sets each of the values in turn and returns the computed style object of the node: - // | require(["dojo/dom-style"], function(domStyle){ - // | domStyle.set("thinger", { - // | "opacity": 0.5, - // | "border": "3px solid black", - // | "height": "300px" - // | }); - // | }); - // - // example: - // When the CSS style property is hyphenated, the JavaScript property is camelCased. - // font-size becomes fontSize, and so on. - // | require(["dojo/dom-style", "dojo/dom"], function(domStyle, dom){ - // | domStyle.set("thinger",{ - // | fontSize:"14pt", - // | letterSpacing:"1.2em" - // | }); - // | }); - // - // example: - // dojo/NodeList implements .style() using the same syntax, omitting the "node" parameter, calling - // dojo/dom-style.get() on every element of the list. See: `dojo/query` and `dojo/NodeList` - // | require(["dojo/dom-style", "dojo/query", "dojo/NodeList-dom"], - // | function(domStyle, query){ - // | query(".someClassName").style("visibility","hidden"); - // | // or - // | query("#baz > div").style({ - // | opacity:0.75, - // | fontSize:"13pt" - // | }); - // | }); - - var n = dom.byId(node), l = arguments.length, op = (name == "opacity"); - name = _floatAliases[name] ? "cssFloat" in n.style ? "cssFloat" : "styleFloat" : name; - if(l == 3){ - return op ? _setOpacity(n, value) : n.style[name] = value; // Number - } - for(var x in name){ - style.set(node, x, name[x]); - } - return style.getComputedStyle(n); - }; - - return style; -}); diff --git a/lib/dojo/dom.js b/lib/dojo/dom.js deleted file mode 100644 index d228d1a..0000000 --- a/lib/dojo/dom.js +++ /dev/null @@ -1,90 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/dom",["./sniff","./_base/window"],function(_1,_2){ -if(_1("ie")<=7){ -try{ -document.execCommand("BackgroundImageCache",false,true); -} -catch(e){ -} -} -var _3={}; -if(_1("ie")){ -_3.byId=function(id,_4){ -if(typeof id!="string"){ -return id; -} -var _5=_4||_2.doc,te=id&&_5.getElementById(id); -if(te&&(te.attributes.id.value==id||te.id==id)){ -return te; -}else{ -var _6=_5.all[id]; -if(!_6||_6.nodeName){ -_6=[_6]; -} -var i=0; -while((te=_6[i++])){ -if((te.attributes&&te.attributes.id&&te.attributes.id.value==id)||te.id==id){ -return te; -} -} -} -}; -}else{ -_3.byId=function(id,_7){ -return ((typeof id=="string")?(_7||_2.doc).getElementById(id):id)||null; -}; -} -_3.isDescendant=function(_8,_9){ -try{ -_8=_3.byId(_8); -_9=_3.byId(_9); -while(_8){ -if(_8==_9){ -return true; -} -_8=_8.parentNode; -} -} -catch(e){ -} -return false; -}; -_1.add("css-user-select",function(_a,_b,_c){ -if(!_c){ -return false; -} -var _d=_c.style; -var _e=["Khtml","O","Moz","Webkit"],i=_e.length,_f="userSelect",_10; -do{ -if(typeof _d[_f]!=="undefined"){ -return _f; -} -}while(i--&&(_f=_e[i]+"UserSelect")); -return false; -}); -var _11=_1("css-user-select"); -_3.setSelectable=_11?function(_12,_13){ -_3.byId(_12).style[_11]=_13?"":"none"; -}:function(_14,_15){ -_14=_3.byId(_14); -var _16=_14.getElementsByTagName("*"),i=_16.length; -if(_15){ -_14.removeAttribute("unselectable"); -while(i--){ -_16[i].removeAttribute("unselectable"); -} -}else{ -_14.setAttribute("unselectable","on"); -while(i--){ -_16[i].setAttribute("unselectable","on"); -} -} -}; -return _3; -}); diff --git a/lib/dojo/dom.js.uncompressed.js b/lib/dojo/dom.js.uncompressed.js deleted file mode 100644 index 59f583e..0000000 --- a/lib/dojo/dom.js.uncompressed.js +++ /dev/null @@ -1,202 +0,0 @@ -define("dojo/dom", ["./sniff", "./_base/window"], - function(has, win){ - // module: - // dojo/dom - - // FIXME: need to add unit tests for all the semi-public methods - - if(has("ie") <= 7){ - try{ - document.execCommand("BackgroundImageCache", false, true); - }catch(e){ - // sane browsers don't have cache "issues" - } - } - - // ============================= - // DOM Functions - // ============================= - - // the result object - var dom = { - // summary: - // This module defines the core dojo DOM API. - }; - - if(has("ie")){ - dom.byId = function(id, doc){ - if(typeof id != "string"){ - return id; - } - var _d = doc || win.doc, te = id && _d.getElementById(id); - // attributes.id.value is better than just id in case the - // user has a name=id inside a form - if(te && (te.attributes.id.value == id || te.id == id)){ - return te; - }else{ - var eles = _d.all[id]; - if(!eles || eles.nodeName){ - eles = [eles]; - } - // if more than 1, choose first with the correct id - var i = 0; - while((te = eles[i++])){ - if((te.attributes && te.attributes.id && te.attributes.id.value == id) || te.id == id){ - return te; - } - } - } - }; - }else{ - dom.byId = function(id, doc){ - // inline'd type check. - // be sure to return null per documentation, to match IE branch. - return ((typeof id == "string") ? (doc || win.doc).getElementById(id) : id) || null; // DOMNode - }; - } - /*===== - dom.byId = function(id, doc){ - // summary: - // Returns DOM node with matching `id` attribute or falsy value (ex: null or undefined) - // if not found. If `id` is a DomNode, this function is a no-op. - // - // id: String|DOMNode - // A string to match an HTML id attribute or a reference to a DOM Node - // - // doc: Document? - // Document to work in. Defaults to the current value of - // dojo/_base/window.doc. Can be used to retrieve - // node references from other documents. - // - // example: - // Look up a node by ID: - // | require(["dojo/dom"], function(dom){ - // | var n = dom.byId("foo"); - // | }); - // - // example: - // Check if a node exists, and use it. - // | require(["dojo/dom"], function(dom){ - // | var n = dom.byId("bar"); - // | if(n){ doStuff() ... } - // | }); - // - // example: - // Allow string or DomNode references to be passed to a custom function: - // | require(["dojo/dom"], function(dom){ - // | var foo = function(nodeOrId){ - // | nodeOrId = dom.byId(nodeOrId); - // | // ... more stuff - // | } - // | }); - }; - =====*/ - - dom.isDescendant = function(/*DOMNode|String*/ node, /*DOMNode|String*/ ancestor){ - // summary: - // Returns true if node is a descendant of ancestor - // node: DOMNode|String - // string id or node reference to test - // ancestor: DOMNode|String - // string id or node reference of potential parent to test against - // - // example: - // Test is node id="bar" is a descendant of node id="foo" - // | require(["dojo/dom"], function(dom){ - // | if(dom.isDescendant("bar", "foo")){ ... } - // | }); - - try{ - node = dom.byId(node); - ancestor = dom.byId(ancestor); - while(node){ - if(node == ancestor){ - return true; // Boolean - } - node = node.parentNode; - } - }catch(e){ /* squelch, return false */ } - return false; // Boolean - }; - - - // TODO: do we need setSelectable in the base? - - // Add feature test for user-select CSS property - // (currently known to work in all but IE < 10 and Opera) - // TODO: The user-select CSS property as of May 2014 is no longer part of - // any CSS specification. In IE, -ms-user-select does not do the same thing - // as the unselectable attribute on elements; namely, dijit Editor buttons - // do not properly prevent the content of the editable content frame from - // unblurring. As a result, the -ms- prefixed version is omitted here. - has.add("css-user-select", function(global, doc, element){ - // Avoid exception when dom.js is loaded in non-browser environments - if(!element){ return false; } - - var style = element.style; - var prefixes = ["Khtml", "O", "Moz", "Webkit"], - i = prefixes.length, - name = "userSelect", - prefix; - - // Iterate prefixes from most to least likely - do{ - if(typeof style[name] !== "undefined"){ - // Supported; return property name - return name; - } - }while(i-- && (name = prefixes[i] + "UserSelect")); - - // Not supported if we didn't return before now - return false; - }); - - /*===== - dom.setSelectable = function(node, selectable){ - // summary: - // Enable or disable selection on a node - // node: DOMNode|String - // id or reference to node - // selectable: Boolean - // state to put the node in. false indicates unselectable, true - // allows selection. - // example: - // Make the node id="bar" unselectable - // | require(["dojo/dom"], function(dom){ - // | dom.setSelectable("bar"); - // | }); - // example: - // Make the node id="bar" selectable - // | require(["dojo/dom"], function(dom){ - // | dom.setSelectable("bar", true); - // | }); - }; - =====*/ - - var cssUserSelect = has("css-user-select"); - dom.setSelectable = cssUserSelect ? function(node, selectable){ - // css-user-select returns a (possibly vendor-prefixed) CSS property name - dom.byId(node).style[cssUserSelect] = selectable ? "" : "none"; - } : function(node, selectable){ - node = dom.byId(node); - - // (IE < 10 / Opera) Fall back to setting/removing the - // unselectable attribute on the element and all its children - var nodes = node.getElementsByTagName("*"), - i = nodes.length; - - if(selectable){ - node.removeAttribute("unselectable"); - while(i--){ - nodes[i].removeAttribute("unselectable"); - } - }else{ - node.setAttribute("unselectable", "on"); - while(i--){ - nodes[i].setAttribute("unselectable", "on"); - } - } - }; - - return dom; -}); diff --git a/lib/dojo/domReady.js b/lib/dojo/domReady.js deleted file mode 100644 index 5de7dd6..0000000 --- a/lib/dojo/domReady.js +++ /dev/null @@ -1,110 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/domReady",["./has"],function(_1){ -var _2=this,_3=document,_4={"loaded":1,"complete":1},_5=typeof _3.readyState!="string",_6=!!_4[_3.readyState],_7=[],_8; -function _9(_a){ -_7.push(_a); -if(_6){ -_b(); -} -}; -_9.load=function(id,_c,_d){ -_9(_d); -}; -_9._Q=_7; -_9._onQEmpty=function(){ -}; -if(_5){ -_3.readyState="loading"; -} -function _b(){ -if(_8){ -return; -} -_8=true; -while(_7.length){ -try{ -(_7.shift())(_3); -} -catch(err){ -} -} -_8=false; -_9._onQEmpty(); -}; -if(!_6){ -var _e=[],_f=function(evt){ -evt=evt||_2.event; -if(_6||(evt.type=="readystatechange"&&!_4[_3.readyState])){ -return; -} -if(_5){ -_3.readyState="complete"; -} -_6=1; -_b(); -},on=function(_10,_11){ -_10.addEventListener(_11,_f,false); -_7.push(function(){ -_10.removeEventListener(_11,_f,false); -}); -}; -if(!_1("dom-addeventlistener")){ -on=function(_12,_13){ -_13="on"+_13; -_12.attachEvent(_13,_f); -_7.push(function(){ -_12.detachEvent(_13,_f); -}); -}; -var div=_3.createElement("div"); -try{ -if(div.doScroll&&_2.frameElement===null){ -_e.push(function(){ -try{ -div.doScroll("left"); -return 1; -} -catch(e){ -} -}); -} -} -catch(e){ -} -} -on(_3,"DOMContentLoaded"); -on(_2,"load"); -if("onreadystatechange" in _3){ -on(_3,"readystatechange"); -}else{ -if(!_5){ -_e.push(function(){ -return _4[_3.readyState]; -}); -} -} -if(_e.length){ -var _14=function(){ -if(_6){ -return; -} -var i=_e.length; -while(i--){ -if(_e[i]()){ -_f("poller"); -return; -} -} -setTimeout(_14,30); -}; -_14(); -} -} -return _9; -}); diff --git a/lib/dojo/domReady.js.uncompressed.js b/lib/dojo/domReady.js.uncompressed.js deleted file mode 100644 index 3d1d576..0000000 --- a/lib/dojo/domReady.js.uncompressed.js +++ /dev/null @@ -1,124 +0,0 @@ -define("dojo/domReady", ['./has'], function(has){ - var global = this, - doc = document, - readyStates = { 'loaded': 1, 'complete': 1 }, - fixReadyState = typeof doc.readyState != "string", - ready = !!readyStates[doc.readyState], - readyQ = [], - recursiveGuard; - - function domReady(callback){ - // summary: - // Plugin to delay require()/define() callback from firing until the DOM has finished loading. - readyQ.push(callback); - if(ready){ processQ(); } - } - domReady.load = function(id, req, load){ - domReady(load); - }; - - // Export queue so that ready() can check if it's empty or not. - domReady._Q = readyQ; - domReady._onQEmpty = function(){ - // summary: - // Private method overridden by dojo/ready, to notify when everything in the - // domReady queue has been processed. Do not use directly. - // Will be removed in 2.0, along with domReady._Q. - }; - - // For FF <= 3.5 - if(fixReadyState){ doc.readyState = "loading"; } - - function processQ(){ - // Calls all functions in the queue in order, unless processQ() is already running, in which case just return - - if(recursiveGuard){ return; } - recursiveGuard = true; - - while(readyQ.length){ - try{ - (readyQ.shift())(doc); - }catch(err){ - console.log("Error on domReady callback: " + err); - } - } - - recursiveGuard = false; - - // Notification for dojo/ready. Remove for 2.0. - // Note that this could add more tasks to the ready queue. - domReady._onQEmpty(); - } - - if(!ready){ - var tests = [], - detectReady = function(evt){ - evt = evt || global.event; - if(ready || (evt.type == "readystatechange" && !readyStates[doc.readyState])){ return; } - - // For FF <= 3.5 - if(fixReadyState){ doc.readyState = "complete"; } - - ready = 1; - processQ(); - }, - on = function(node, event){ - node.addEventListener(event, detectReady, false); - readyQ.push(function(){ node.removeEventListener(event, detectReady, false); }); - }; - - if(!has("dom-addeventlistener")){ - on = function(node, event){ - event = "on" + event; - node.attachEvent(event, detectReady); - readyQ.push(function(){ node.detachEvent(event, detectReady); }); - }; - - var div = doc.createElement("div"); - try{ - if(div.doScroll && global.frameElement === null){ - // the doScroll test is only useful if we're in the top-most frame - tests.push(function(){ - // Derived with permission from Diego Perini's IEContentLoaded - // http://javascript.nwbox.com/IEContentLoaded/ - try{ - div.doScroll("left"); - return 1; - }catch(e){} - }); - } - }catch(e){} - } - - on(doc, "DOMContentLoaded"); - on(global, "load"); - - if("onreadystatechange" in doc){ - on(doc, "readystatechange"); - }else if(!fixReadyState){ - // if the ready state property exists and there's - // no readystatechange event, poll for the state - // to change - tests.push(function(){ - return readyStates[doc.readyState]; - }); - } - - if(tests.length){ - var poller = function(){ - if(ready){ return; } - var i = tests.length; - while(i--){ - if(tests[i]()){ - detectReady("poller"); - return; - } - } - setTimeout(poller, 30); - }; - poller(); - } - } - - return domReady; -}); diff --git a/lib/dojo/errors/CancelError.js b/lib/dojo/errors/CancelError.js deleted file mode 100644 index 81812d1..0000000 --- a/lib/dojo/errors/CancelError.js +++ /dev/null @@ -1,10 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/errors/CancelError",["./create"],function(_1){ -return _1("CancelError",null,null,{dojoType:"cancel"}); -}); diff --git a/lib/dojo/errors/CancelError.js.uncompressed.js b/lib/dojo/errors/CancelError.js.uncompressed.js deleted file mode 100644 index 2d96b05..0000000 --- a/lib/dojo/errors/CancelError.js.uncompressed.js +++ /dev/null @@ -1,13 +0,0 @@ -define("dojo/errors/CancelError", ["./create"], function(create){ - // module: - // dojo/errors/CancelError - - /*===== - return function(){ - // summary: - // Default error if a promise is canceled without a reason. - }; - =====*/ - - return create("CancelError", null, null, { dojoType: "cancel" }); -}); diff --git a/lib/dojo/errors/RequestError.js b/lib/dojo/errors/RequestError.js deleted file mode 100644 index bedeb55..0000000 --- a/lib/dojo/errors/RequestError.js +++ /dev/null @@ -1,12 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/errors/RequestError",["./create"],function(_1){ -return _1("RequestError",function(_2,_3){ -this.response=_3; -}); -}); diff --git a/lib/dojo/errors/RequestError.js.uncompressed.js b/lib/dojo/errors/RequestError.js.uncompressed.js deleted file mode 100644 index f476cd8..0000000 --- a/lib/dojo/errors/RequestError.js.uncompressed.js +++ /dev/null @@ -1,15 +0,0 @@ -define("dojo/errors/RequestError", ['./create'], function(create){ - // module: - // dojo/errors/RequestError - - /*===== - return function(){ - // summary: - // TODOC - }; - =====*/ - - return create("RequestError", function(message, response){ - this.response = response; - }); -}); diff --git a/lib/dojo/errors/RequestTimeoutError.js b/lib/dojo/errors/RequestTimeoutError.js deleted file mode 100644 index 2d1250f..0000000 --- a/lib/dojo/errors/RequestTimeoutError.js +++ /dev/null @@ -1,10 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/errors/RequestTimeoutError",["./create","./RequestError"],function(_1,_2){ -return _1("RequestTimeoutError",null,_2,{dojoType:"timeout"}); -}); diff --git a/lib/dojo/errors/RequestTimeoutError.js.uncompressed.js b/lib/dojo/errors/RequestTimeoutError.js.uncompressed.js deleted file mode 100644 index 91e986a..0000000 --- a/lib/dojo/errors/RequestTimeoutError.js.uncompressed.js +++ /dev/null @@ -1,15 +0,0 @@ -define("dojo/errors/RequestTimeoutError", ['./create', './RequestError'], function(create, RequestError){ - // module: - // dojo/errors/RequestTimeoutError - - /*===== - return function(){ - // summary: - // TODOC - }; - =====*/ - - return create("RequestTimeoutError", null, RequestError, { - dojoType: "timeout" - }); -}); diff --git a/lib/dojo/errors/create.js b/lib/dojo/errors/create.js deleted file mode 100644 index 8690b97..0000000 --- a/lib/dojo/errors/create.js +++ /dev/null @@ -1,36 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/errors/create",["../_base/lang"],function(_1){ -return function(_2,_3,_4,_5){ -_4=_4||Error; -var _6=function(_7){ -if(_4===Error){ -if(Error.captureStackTrace){ -Error.captureStackTrace(this,_6); -} -var _8=Error.call(this,_7),_9; -for(_9 in _8){ -if(_8.hasOwnProperty(_9)){ -this[_9]=_8[_9]; -} -} -this.message=_7; -this.stack=_8.stack; -}else{ -_4.apply(this,arguments); -} -if(_3){ -_3.apply(this,arguments); -} -}; -_6.prototype=_1.delegate(_4.prototype,_5); -_6.prototype.name=_2; -_6.prototype.constructor=_6; -return _6; -}; -}); diff --git a/lib/dojo/errors/create.js.uncompressed.js b/lib/dojo/errors/create.js.uncompressed.js deleted file mode 100644 index d303a6a..0000000 --- a/lib/dojo/errors/create.js.uncompressed.js +++ /dev/null @@ -1,41 +0,0 @@ -define("dojo/errors/create", ["../_base/lang"], function(lang){ - return function(name, ctor, base, props){ - base = base || Error; - - var ErrorCtor = function(message){ - if(base === Error){ - if(Error.captureStackTrace){ - Error.captureStackTrace(this, ErrorCtor); - } - - // Error.call() operates on the returned error - // object rather than operating on |this| - var err = Error.call(this, message), - prop; - - // Copy own properties from err to |this| - for(prop in err){ - if(err.hasOwnProperty(prop)){ - this[prop] = err[prop]; - } - } - - // messsage is non-enumerable in ES5 - this.message = message; - // stack is non-enumerable in at least Firefox - this.stack = err.stack; - }else{ - base.apply(this, arguments); - } - if(ctor){ - ctor.apply(this, arguments); - } - }; - - ErrorCtor.prototype = lang.delegate(base.prototype, props); - ErrorCtor.prototype.name = name; - ErrorCtor.prototype.constructor = ErrorCtor; - - return ErrorCtor; - }; -}); diff --git a/lib/dojo/fx.js b/lib/dojo/fx.js deleted file mode 100644 index 57dc0e1..0000000 --- a/lib/dojo/fx.js +++ /dev/null @@ -1,268 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/fx",["./_base/lang","./Evented","./_base/kernel","./_base/array","./aspect","./_base/fx","./dom","./dom-style","./dom-geometry","./ready","require"],function(_1,_2,_3,_4,_5,_6,_7,_8,_9,_a,_b){ -if(!_3.isAsync){ -_a(0,function(){ -var _c=["./fx/Toggler"]; -_b(_c); -}); -} -var _d=_3.fx={}; -var _e={_fire:function(_f,_10){ -if(this[_f]){ -this[_f].apply(this,_10||[]); -} -return this; -}}; -var _11=function(_12){ -this._index=-1; -this._animations=_12||[]; -this._current=this._onAnimateCtx=this._onEndCtx=null; -this.duration=0; -_4.forEach(this._animations,function(a){ -this.duration+=a.duration; -if(a.delay){ -this.duration+=a.delay; -} -},this); -}; -_11.prototype=new _2(); -_1.extend(_11,{_onAnimate:function(){ -this._fire("onAnimate",arguments); -},_onEnd:function(){ -this._onAnimateCtx.remove(); -this._onEndCtx.remove(); -this._onAnimateCtx=this._onEndCtx=null; -if(this._index+1==this._animations.length){ -this._fire("onEnd"); -}else{ -this._current=this._animations[++this._index]; -this._onAnimateCtx=_5.after(this._current,"onAnimate",_1.hitch(this,"_onAnimate"),true); -this._onEndCtx=_5.after(this._current,"onEnd",_1.hitch(this,"_onEnd"),true); -this._current.play(0,true); -} -},play:function(_13,_14){ -if(!this._current){ -this._current=this._animations[this._index=0]; -} -if(!_14&&this._current.status()=="playing"){ -return this; -} -var _15=_5.after(this._current,"beforeBegin",_1.hitch(this,function(){ -this._fire("beforeBegin"); -}),true),_16=_5.after(this._current,"onBegin",_1.hitch(this,function(arg){ -this._fire("onBegin",arguments); -}),true),_17=_5.after(this._current,"onPlay",_1.hitch(this,function(arg){ -this._fire("onPlay",arguments); -_15.remove(); -_16.remove(); -_17.remove(); -})); -if(this._onAnimateCtx){ -this._onAnimateCtx.remove(); -} -this._onAnimateCtx=_5.after(this._current,"onAnimate",_1.hitch(this,"_onAnimate"),true); -if(this._onEndCtx){ -this._onEndCtx.remove(); -} -this._onEndCtx=_5.after(this._current,"onEnd",_1.hitch(this,"_onEnd"),true); -this._current.play.apply(this._current,arguments); -return this; -},pause:function(){ -if(this._current){ -var e=_5.after(this._current,"onPause",_1.hitch(this,function(arg){ -this._fire("onPause",arguments); -e.remove(); -}),true); -this._current.pause(); -} -return this; -},gotoPercent:function(_18,_19){ -this.pause(); -var _1a=this.duration*_18; -this._current=null; -_4.some(this._animations,function(a,_1b){ -if(_1a<=a.duration){ -this._current=a; -this._index=_1b; -return true; -} -_1a-=a.duration; -return false; -},this); -if(this._current){ -this._current.gotoPercent(_1a/this._current.duration); -} -if(_19){ -this.play(); -} -return this; -},stop:function(_1c){ -if(this._current){ -if(_1c){ -for(;this._index+1this._animations.length){ -this._fire("onEnd"); -} -},_call:function(_24,_25){ -var t=this._pseudoAnimation; -t[_24].apply(t,_25); -},play:function(_26,_27){ -this._finished=0; -this._doAction("play",arguments); -this._call("play",arguments); -return this; -},pause:function(){ -this._doAction("pause",arguments); -this._call("pause",arguments); -return this; -},gotoPercent:function(_28,_29){ -var ms=this.duration*_28; -_4.forEach(this._animations,function(a){ -a.gotoPercent(a.duration this._animations.length){ - this._fire("onEnd"); - } - }, - _call: function(action, args){ - var t = this._pseudoAnimation; - t[action].apply(t, args); - }, - play: function(/*int?*/ delay, /*Boolean?*/ gotoStart){ - this._finished = 0; - this._doAction("play", arguments); - this._call("play", arguments); - return this; - }, - pause: function(){ - this._doAction("pause", arguments); - this._call("pause", arguments); - return this; - }, - gotoPercent: function(/*Decimal*/percent, /*Boolean?*/ andPlay){ - var ms = this.duration * percent; - arrayUtil.forEach(this._animations, function(a){ - a.gotoPercent(a.duration < ms ? 1 : (ms / a.duration), andPlay); - }); - this._call("gotoPercent", arguments); - return this; - }, - stop: function(/*boolean?*/ gotoEnd){ - this._doAction("stop", arguments); - this._call("stop", arguments); - return this; - }, - status: function(){ - return this._pseudoAnimation.status(); - }, - destroy: function(){ - this.stop(); - arrayUtil.forEach(this._connects, function(handle){ - handle.remove(); - }); - } - }); - lang.extend(_combine, _baseObj); - - coreFx.combine = function(/*dojo/_base/fx.Animation[]*/ animations){ - // summary: - // Combine a list of `dojo/_base/fx.Animation`s to run in parallel - // - // description: - // Combine an array of `dojo/_base/fx.Animation`s to run in parallel, - // providing a new `dojo/_base/fx.Animation` instance encompasing each - // animation, firing standard animation events. - // - // example: - // Fade out `node` while fading in `otherNode` simultaneously - // | require(["dojo/fx"], function(fx){ - // | fx.combine([ - // | fx.fadeIn({ node:node }), - // | fx.fadeOut({ node:otherNode }) - // | ]).play(); - // | }); - // - // example: - // When the longest animation ends, execute a function: - // | require(["dojo/fx"], function(fx){ - // | var anim = fx.combine([ - // | fx.fadeIn({ node: n, duration:700 }), - // | fx.fadeOut({ node: otherNode, duration: 300 }) - // | ]); - // | aspect.after(anim, "onEnd", function(){ - // | // overall animation is done. - // | }, true); - // | anim.play(); // play the animation - // | }); - // - return new _combine(animations); // dojo/_base/fx.Animation - }; - - coreFx.wipeIn = function(/*Object*/ args){ - // summary: - // Expand a node to it's natural height. - // - // description: - // Returns an animation that will expand the - // node defined in 'args' object from it's current height to - // it's natural height (with no scrollbar). - // Node must have no margin/border/padding. - // - // args: Object - // A hash-map of standard `dojo/_base/fx.Animation` constructor properties - // (such as easing: node: duration: and so on) - // - // example: - // | require(["dojo/fx"], function(fx){ - // | fx.wipeIn({ - // | node:"someId" - // | }).play() - // | }); - - var node = args.node = dom.byId(args.node), s = node.style, o; - - var anim = baseFx.animateProperty(lang.mixin({ - properties: { - height: { - // wrapped in functions so we wait till the last second to query (in case value has changed) - start: function(){ - // start at current [computed] height, but use 1px rather than 0 - // because 0 causes IE to display the whole panel - o = s.overflow; - s.overflow = "hidden"; - if(s.visibility == "hidden" || s.display == "none"){ - s.height = "1px"; - s.display = ""; - s.visibility = ""; - return 1; - }else{ - var height = domStyle.get(node, "height"); - return Math.max(height, 1); - } - }, - end: function(){ - return node.scrollHeight; - } - } - } - }, args)); - - var fini = function(){ - s.height = "auto"; - s.overflow = o; - }; - aspect.after(anim, "onStop", fini, true); - aspect.after(anim, "onEnd", fini, true); - - return anim; // dojo/_base/fx.Animation - }; - - coreFx.wipeOut = function(/*Object*/ args){ - // summary: - // Shrink a node to nothing and hide it. - // - // description: - // Returns an animation that will shrink node defined in "args" - // from it's current height to 1px, and then hide it. - // - // args: Object - // A hash-map of standard `dojo/_base/fx.Animation` constructor properties - // (such as easing: node: duration: and so on) - // - // example: - // | require(["dojo/fx"], function(fx){ - // | fx.wipeOut({ node:"someId" }).play() - // | }); - - var node = args.node = dom.byId(args.node), s = node.style, o; - - var anim = baseFx.animateProperty(lang.mixin({ - properties: { - height: { - end: 1 // 0 causes IE to display the whole panel - } - } - }, args)); - - aspect.after(anim, "beforeBegin", function(){ - o = s.overflow; - s.overflow = "hidden"; - s.display = ""; - }, true); - var fini = function(){ - s.overflow = o; - s.height = "auto"; - s.display = "none"; - }; - aspect.after(anim, "onStop", fini, true); - aspect.after(anim, "onEnd", fini, true); - - return anim; // dojo/_base/fx.Animation - }; - - coreFx.slideTo = function(/*Object*/ args){ - // summary: - // Slide a node to a new top/left position - // - // description: - // Returns an animation that will slide "node" - // defined in args Object from its current position to - // the position defined by (args.left, args.top). - // - // args: Object - // A hash-map of standard `dojo/_base/fx.Animation` constructor properties - // (such as easing: node: duration: and so on). Special args members - // are `top` and `left`, which indicate the new position to slide to. - // - // example: - // | .slideTo({ node: node, left:"40", top:"50", units:"px" }).play() - - var node = args.node = dom.byId(args.node), - top = null, left = null; - - var init = (function(n){ - return function(){ - var cs = domStyle.getComputedStyle(n); - var pos = cs.position; - top = (pos == 'absolute' ? n.offsetTop : parseInt(cs.top) || 0); - left = (pos == 'absolute' ? n.offsetLeft : parseInt(cs.left) || 0); - if(pos != 'absolute' && pos != 'relative'){ - var ret = geom.position(n, true); - top = ret.y; - left = ret.x; - n.style.position="absolute"; - n.style.top=top+"px"; - n.style.left=left+"px"; - } - }; - })(node); - init(); - - var anim = baseFx.animateProperty(lang.mixin({ - properties: { - top: args.top || 0, - left: args.left || 0 - } - }, args)); - aspect.after(anim, "beforeBegin", init, true); - - return anim; // dojo/_base/fx.Animation - }; - - return coreFx; -}); diff --git a/lib/dojo/fx/Toggler.js b/lib/dojo/fx/Toggler.js deleted file mode 100644 index 49f91b1..0000000 --- a/lib/dojo/fx/Toggler.js +++ /dev/null @@ -1,28 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/fx/Toggler",["../_base/lang","../_base/declare","../_base/fx","../aspect"],function(_1,_2,_3,_4){ -return _2("dojo.fx.Toggler",null,{node:null,showFunc:_3.fadeIn,hideFunc:_3.fadeOut,showDuration:200,hideDuration:200,constructor:function(_5){ -var _6=this; -_1.mixin(_6,_5); -_6.node=_5.node; -_6._showArgs=_1.mixin({},_5); -_6._showArgs.node=_6.node; -_6._showArgs.duration=_6.showDuration; -_6.showAnim=_6.showFunc(_6._showArgs); -_6._hideArgs=_1.mixin({},_5); -_6._hideArgs.node=_6.node; -_6._hideArgs.duration=_6.hideDuration; -_6.hideAnim=_6.hideFunc(_6._hideArgs); -_4.after(_6.showAnim,"beforeBegin",_1.hitch(_6.hideAnim,"stop",true),true); -_4.after(_6.hideAnim,"beforeBegin",_1.hitch(_6.showAnim,"stop",true),true); -},show:function(_7){ -return this.showAnim.play(_7||0); -},hide:function(_8){ -return this.hideAnim.play(_8||0); -}}); -}); diff --git a/lib/dojo/fx/Toggler.js.uncompressed.js b/lib/dojo/fx/Toggler.js.uncompressed.js deleted file mode 100644 index 7c4b635..0000000 --- a/lib/dojo/fx/Toggler.js.uncompressed.js +++ /dev/null @@ -1,101 +0,0 @@ -define("dojo/fx/Toggler", ["../_base/lang","../_base/declare","../_base/fx", "../aspect"], - function(lang, declare, baseFx, aspect){ - // module: - // dojo/fx/Toggler - -return declare("dojo.fx.Toggler", null, { - // summary: - // A simple `dojo.Animation` toggler API. - // description: - // class constructor for an animation toggler. It accepts a packed - // set of arguments about what type of animation to use in each - // direction, duration, etc. All available members are mixed into - // these animations from the constructor (for example, `node`, - // `showDuration`, `hideDuration`). - // example: - // | var t = new dojo/fx/Toggler({ - // | node: "nodeId", - // | showDuration: 500, - // | // hideDuration will default to "200" - // | showFunc: dojo/fx/wipeIn, - // | // hideFunc will default to "fadeOut" - // | }); - // | t.show(100); // delay showing for 100ms - // | // ...time passes... - // | t.hide(); - - // node: DomNode - // the node to target for the showing and hiding animations - node: null, - - // showFunc: Function - // The function that returns the `dojo.Animation` to show the node - showFunc: baseFx.fadeIn, - - // hideFunc: Function - // The function that returns the `dojo.Animation` to hide the node - hideFunc: baseFx.fadeOut, - - // showDuration: - // Time in milliseconds to run the show Animation - showDuration: 200, - - // hideDuration: - // Time in milliseconds to run the hide Animation - hideDuration: 200, - - // FIXME: need a policy for where the toggler should "be" the next - // time show/hide are called if we're stopped somewhere in the - // middle. - // FIXME: also would be nice to specify individual showArgs/hideArgs mixed into - // each animation individually. - // FIXME: also would be nice to have events from the animations exposed/bridged - - /*===== - _showArgs: null, - _showAnim: null, - - _hideArgs: null, - _hideAnim: null, - - _isShowing: false, - _isHiding: false, - =====*/ - - constructor: function(args){ - var _t = this; - - lang.mixin(_t, args); - _t.node = args.node; - _t._showArgs = lang.mixin({}, args); - _t._showArgs.node = _t.node; - _t._showArgs.duration = _t.showDuration; - _t.showAnim = _t.showFunc(_t._showArgs); - - _t._hideArgs = lang.mixin({}, args); - _t._hideArgs.node = _t.node; - _t._hideArgs.duration = _t.hideDuration; - _t.hideAnim = _t.hideFunc(_t._hideArgs); - - aspect.after(_t.showAnim, "beforeBegin", lang.hitch(_t.hideAnim, "stop", true), true); - aspect.after(_t.hideAnim, "beforeBegin", lang.hitch(_t.showAnim, "stop", true), true); - }, - - show: function(delay){ - // summary: - // Toggle the node to showing - // delay: Integer? - // Amount of time to stall playing the show animation - return this.showAnim.play(delay || 0); - }, - - hide: function(delay){ - // summary: - // Toggle the node to hidden - // delay: Integer? - // Amount of time to stall playing the hide animation - return this.hideAnim.play(delay || 0); - } -}); - -}); diff --git a/lib/dojo/fx/easing.js b/lib/dojo/fx/easing.js deleted file mode 100644 index c1e74b6..0000000 --- a/lib/dojo/fx/easing.js +++ /dev/null @@ -1,166 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/fx/easing",["../_base/lang"],function(_1){ -var _2={linear:function(n){ -return n; -},quadIn:function(n){ -return Math.pow(n,2); -},quadOut:function(n){ -return n*(n-2)*-1; -},quadInOut:function(n){ -n=n*2; -if(n<1){ -return Math.pow(n,2)/2; -} -return -1*((--n)*(n-2)-1)/2; -},cubicIn:function(n){ -return Math.pow(n,3); -},cubicOut:function(n){ -return Math.pow(n-1,3)+1; -},cubicInOut:function(n){ -n=n*2; -if(n<1){ -return Math.pow(n,3)/2; -} -n-=2; -return (Math.pow(n,3)+2)/2; -},quartIn:function(n){ -return Math.pow(n,4); -},quartOut:function(n){ -return -1*(Math.pow(n-1,4)-1); -},quartInOut:function(n){ -n=n*2; -if(n<1){ -return Math.pow(n,4)/2; -} -n-=2; -return -1/2*(Math.pow(n,4)-2); -},quintIn:function(n){ -return Math.pow(n,5); -},quintOut:function(n){ -return Math.pow(n-1,5)+1; -},quintInOut:function(n){ -n=n*2; -if(n<1){ -return Math.pow(n,5)/2; -} -n-=2; -return (Math.pow(n,5)+2)/2; -},sineIn:function(n){ -return -1*Math.cos(n*(Math.PI/2))+1; -},sineOut:function(n){ -return Math.sin(n*(Math.PI/2)); -},sineInOut:function(n){ -return -1*(Math.cos(Math.PI*n)-1)/2; -},expoIn:function(n){ -return (n==0)?0:Math.pow(2,10*(n-1)); -},expoOut:function(n){ -return (n==1)?1:(-1*Math.pow(2,-10*n)+1); -},expoInOut:function(n){ -if(n==0){ -return 0; -} -if(n==1){ -return 1; -} -n=n*2; -if(n<1){ -return Math.pow(2,10*(n-1))/2; -} ---n; -return (-1*Math.pow(2,-10*n)+2)/2; -},circIn:function(n){ -return -1*(Math.sqrt(1-Math.pow(n,2))-1); -},circOut:function(n){ -n=n-1; -return Math.sqrt(1-Math.pow(n,2)); -},circInOut:function(n){ -n=n*2; -if(n<1){ -return -1/2*(Math.sqrt(1-Math.pow(n,2))-1); -} -n-=2; -return 1/2*(Math.sqrt(1-Math.pow(n,2))+1); -},backIn:function(n){ -var s=1.70158; -return Math.pow(n,2)*((s+1)*n-s); -},backOut:function(n){ -n=n-1; -var s=1.70158; -return Math.pow(n,2)*((s+1)*n+s)+1; -},backInOut:function(n){ -var s=1.70158*1.525; -n=n*2; -if(n<1){ -return (Math.pow(n,2)*((s+1)*n-s))/2; -} -n-=2; -return (Math.pow(n,2)*((s+1)*n+s)+2)/2; -},elasticIn:function(n){ -if(n==0||n==1){ -return n; -} -var p=0.3; -var s=p/4; -n=n-1; -return -1*Math.pow(2,10*n)*Math.sin((n-s)*(2*Math.PI)/p); -},elasticOut:function(n){ -if(n==0||n==1){ -return n; -} -var p=0.3; -var s=p/4; -return Math.pow(2,-10*n)*Math.sin((n-s)*(2*Math.PI)/p)+1; -},elasticInOut:function(n){ -if(n==0){ -return 0; -} -n=n*2; -if(n==2){ -return 1; -} -var p=0.3*1.5; -var s=p/4; -if(n<1){ -n-=1; -return -0.5*(Math.pow(2,10*n)*Math.sin((n-s)*(2*Math.PI)/p)); -} -n-=1; -return 0.5*(Math.pow(2,-10*n)*Math.sin((n-s)*(2*Math.PI)/p))+1; -},bounceIn:function(n){ -return (1-_2.bounceOut(1-n)); -},bounceOut:function(n){ -var s=7.5625; -var p=2.75; -var l; -if(n<(1/p)){ -l=s*Math.pow(n,2); -}else{ -if(n<(2/p)){ -n-=(1.5/p); -l=s*Math.pow(n,2)+0.75; -}else{ -if(n<(2.5/p)){ -n-=(2.25/p); -l=s*Math.pow(n,2)+0.9375; -}else{ -n-=(2.625/p); -l=s*Math.pow(n,2)+0.984375; -} -} -} -return l; -},bounceInOut:function(n){ -if(n<0.5){ -return _2.bounceIn(n*2)/2; -} -return (_2.bounceOut(n*2-1)/2)+0.5; -}}; -_1.setObject("dojo.fx.easing",_2); -return _2; -}); diff --git a/lib/dojo/fx/easing.js.uncompressed.js b/lib/dojo/fx/easing.js.uncompressed.js deleted file mode 100644 index d899bce..0000000 --- a/lib/dojo/fx/easing.js.uncompressed.js +++ /dev/null @@ -1,276 +0,0 @@ -define("dojo/fx/easing", ["../_base/lang"], function(lang){ - -// module: -// dojo/fx/easing - -var easingFuncs = { - // summary: - // Collection of easing functions to use beyond the default - // `dojo._defaultEasing` function. - // description: - // Easing functions are used to manipulate the iteration through - // an `dojo.Animation`s _Line. _Line being the properties of an Animation, - // and the easing function progresses through that Line determining - // how quickly (or slowly) it should go. Or more accurately: modify - // the value of the _Line based on the percentage of animation completed. - // - // All functions follow a simple naming convention of "ease type" + "when". - // If the name of the function ends in Out, the easing described appears - // towards the end of the animation. "In" means during the beginning, - // and InOut means both ranges of the Animation will applied, both - // beginning and end. - // - // One does not call the easing function directly, it must be passed to - // the `easing` property of an animation. - // example: - // | dojo.require("dojo.fx.easing"); - // | var anim = dojo.fadeOut({ - // | node: 'node', - // | duration: 2000, - // | // note there is no () - // | easing: dojo.fx.easing.quadIn - // | }).play(); - // - - linear: function(/* Decimal? */n){ - // summary: - // A linear easing function - return n; - }, - - quadIn: function(/* Decimal? */n){ - return Math.pow(n, 2); - }, - - quadOut: function(/* Decimal? */n){ - return n * (n - 2) * -1; - }, - - quadInOut: function(/* Decimal? */n){ - n = n * 2; - if(n < 1){ return Math.pow(n, 2) / 2; } - return -1 * ((--n) * (n - 2) - 1) / 2; - }, - - cubicIn: function(/* Decimal? */n){ - return Math.pow(n, 3); - }, - - cubicOut: function(/* Decimal? */n){ - return Math.pow(n - 1, 3) + 1; - }, - - cubicInOut: function(/* Decimal? */n){ - n = n * 2; - if(n < 1){ return Math.pow(n, 3) / 2; } - n -= 2; - return (Math.pow(n, 3) + 2) / 2; - }, - - quartIn: function(/* Decimal? */n){ - return Math.pow(n, 4); - }, - - quartOut: function(/* Decimal? */n){ - return -1 * (Math.pow(n - 1, 4) - 1); - }, - - quartInOut: function(/* Decimal? */n){ - n = n * 2; - if(n < 1){ return Math.pow(n, 4) / 2; } - n -= 2; - return -1 / 2 * (Math.pow(n, 4) - 2); - }, - - quintIn: function(/* Decimal? */n){ - return Math.pow(n, 5); - }, - - quintOut: function(/* Decimal? */n){ - return Math.pow(n - 1, 5) + 1; - }, - - quintInOut: function(/* Decimal? */n){ - n = n * 2; - if(n < 1){ return Math.pow(n, 5) / 2; } - n -= 2; - return (Math.pow(n, 5) + 2) / 2; - }, - - sineIn: function(/* Decimal? */n){ - return -1 * Math.cos(n * (Math.PI / 2)) + 1; - }, - - sineOut: function(/* Decimal? */n){ - return Math.sin(n * (Math.PI / 2)); - }, - - sineInOut: function(/* Decimal? */n){ - return -1 * (Math.cos(Math.PI * n) - 1) / 2; - }, - - expoIn: function(/* Decimal? */n){ - return (n == 0) ? 0 : Math.pow(2, 10 * (n - 1)); - }, - - expoOut: function(/* Decimal? */n){ - return (n == 1) ? 1 : (-1 * Math.pow(2, -10 * n) + 1); - }, - - expoInOut: function(/* Decimal? */n){ - if(n == 0){ return 0; } - if(n == 1){ return 1; } - n = n * 2; - if(n < 1){ return Math.pow(2, 10 * (n - 1)) / 2; } - --n; - return (-1 * Math.pow(2, -10 * n) + 2) / 2; - }, - - circIn: function(/* Decimal? */n){ - return -1 * (Math.sqrt(1 - Math.pow(n, 2)) - 1); - }, - - circOut: function(/* Decimal? */n){ - n = n - 1; - return Math.sqrt(1 - Math.pow(n, 2)); - }, - - circInOut: function(/* Decimal? */n){ - n = n * 2; - if(n < 1){ return -1 / 2 * (Math.sqrt(1 - Math.pow(n, 2)) - 1); } - n -= 2; - return 1 / 2 * (Math.sqrt(1 - Math.pow(n, 2)) + 1); - }, - - backIn: function(/* Decimal? */n){ - // summary: - // An easing function that starts away from the target, - // and quickly accelerates towards the end value. - // - // Use caution when the easing will cause values to become - // negative as some properties cannot be set to negative values. - var s = 1.70158; - return Math.pow(n, 2) * ((s + 1) * n - s); - }, - - backOut: function(/* Decimal? */n){ - // summary: - // An easing function that pops past the range briefly, and slowly comes back. - // description: - // An easing function that pops past the range briefly, and slowly comes back. - // - // Use caution when the easing will cause values to become negative as some - // properties cannot be set to negative values. - - n = n - 1; - var s = 1.70158; - return Math.pow(n, 2) * ((s + 1) * n + s) + 1; - }, - - backInOut: function(/* Decimal? */n){ - // summary: - // An easing function combining the effects of `backIn` and `backOut` - // description: - // An easing function combining the effects of `backIn` and `backOut`. - // Use caution when the easing will cause values to become negative - // as some properties cannot be set to negative values. - var s = 1.70158 * 1.525; - n = n * 2; - if(n < 1){ return (Math.pow(n, 2) * ((s + 1) * n - s)) / 2; } - n-=2; - return (Math.pow(n, 2) * ((s + 1) * n + s) + 2) / 2; - }, - - elasticIn: function(/* Decimal? */n){ - // summary: - // An easing function the elastically snaps from the start value - // description: - // An easing function the elastically snaps from the start value - // - // Use caution when the elasticity will cause values to become negative - // as some properties cannot be set to negative values. - if(n == 0 || n == 1){ return n; } - var p = .3; - var s = p / 4; - n = n - 1; - return -1 * Math.pow(2, 10 * n) * Math.sin((n - s) * (2 * Math.PI) / p); - }, - - elasticOut: function(/* Decimal? */n){ - // summary: - // An easing function that elasticly snaps around the target value, - // near the end of the Animation - // description: - // An easing function that elasticly snaps around the target value, - // near the end of the Animation - // - // Use caution when the elasticity will cause values to become - // negative as some properties cannot be set to negative values. - if(n==0 || n == 1){ return n; } - var p = .3; - var s = p / 4; - return Math.pow(2, -10 * n) * Math.sin((n - s) * (2 * Math.PI) / p) + 1; - }, - - elasticInOut: function(/* Decimal? */n){ - // summary: - // An easing function that elasticly snaps around the value, near - // the beginning and end of the Animation. - // description: - // An easing function that elasticly snaps around the value, near - // the beginning and end of the Animation. - // - // Use caution when the elasticity will cause values to become - // negative as some properties cannot be set to negative values. - if(n == 0) return 0; - n = n * 2; - if(n == 2) return 1; - var p = .3 * 1.5; - var s = p / 4; - if(n < 1){ - n -= 1; - return -.5 * (Math.pow(2, 10 * n) * Math.sin((n - s) * (2 * Math.PI) / p)); - } - n -= 1; - return .5 * (Math.pow(2, -10 * n) * Math.sin((n - s) * (2 * Math.PI) / p)) + 1; - }, - - bounceIn: function(/* Decimal? */n){ - // summary: - // An easing function that 'bounces' near the beginning of an Animation - return (1 - easingFuncs.bounceOut(1 - n)); // Decimal - }, - - bounceOut: function(/* Decimal? */n){ - // summary: - // An easing function that 'bounces' near the end of an Animation - var s = 7.5625; - var p = 2.75; - var l; - if(n < (1 / p)){ - l = s * Math.pow(n, 2); - }else if(n < (2 / p)){ - n -= (1.5 / p); - l = s * Math.pow(n, 2) + .75; - }else if(n < (2.5 / p)){ - n -= (2.25 / p); - l = s * Math.pow(n, 2) + .9375; - }else{ - n -= (2.625 / p); - l = s * Math.pow(n, 2) + .984375; - } - return l; - }, - - bounceInOut: function(/* Decimal? */n){ - // summary: - // An easing function that 'bounces' at the beginning and end of the Animation - if(n < 0.5){ return easingFuncs.bounceIn(n * 2) / 2; } - return (easingFuncs.bounceOut(n * 2 - 1) / 2) + 0.5; // Decimal - } -}; - -lang.setObject("dojo.fx.easing", easingFuncs); - -return easingFuncs; -}); diff --git a/lib/dojo/gears.js b/lib/dojo/gears.js deleted file mode 100644 index aa41710..0000000 --- a/lib/dojo/gears.js +++ /dev/null @@ -1,45 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/gears",["./_base/lang","./sniff"],function(_1,_2){ -var _3={}; -_1.setObject("dojo.gears",_3); -_3._gearsObject=function(){ -var _4; -var _5=_1.getObject("google.gears"); -if(_5){ -return _5; -} -if(typeof GearsFactory!="undefined"){ -_4=new GearsFactory(); -}else{ -if(_2("ie")){ -try{ -_4=new ActiveXObject("Gears.Factory"); -} -catch(e){ -} -}else{ -if(navigator.mimeTypes["application/x-googlegears"]){ -_4=document.createElement("object"); -_4.setAttribute("type","application/x-googlegears"); -_4.setAttribute("width",0); -_4.setAttribute("height",0); -_4.style.display="none"; -document.documentElement.appendChild(_4); -} -} -} -if(!_4){ -return null; -} -_1.setObject("google.gears.factory",_4); -return _1.getObject("google.gears"); -}; -_3.available=(!!_3._gearsObject())||0; -return _3; -}); diff --git a/lib/dojo/gears.js.uncompressed.js b/lib/dojo/gears.js.uncompressed.js deleted file mode 100644 index 4507f05..0000000 --- a/lib/dojo/gears.js.uncompressed.js +++ /dev/null @@ -1,65 +0,0 @@ -define("dojo/gears", ["./_base/lang", "./sniff"], function(lang, has){ - -// module: -// dojo/gears - -var gears = { - // summary: - // TODOC -}; -lang.setObject("dojo.gears", gears); - -gears._gearsObject = function(){ - // summary: - // factory method to get a Google Gears plugin instance to - // expose in the browser runtime environment, if present - var factory; - - var gearsObj = lang.getObject("google.gears"); - if(gearsObj){ return gearsObj; } // already defined elsewhere - - if(typeof GearsFactory != "undefined"){ // Firefox - factory = new GearsFactory(); - }else{ - if(has("ie")){ - // IE - try{ - factory = new ActiveXObject("Gears.Factory"); - }catch(e){ - // ok to squelch; there's no gears factory. move on. - } - }else if(navigator.mimeTypes["application/x-googlegears"]){ - // Safari? - factory = document.createElement("object"); - factory.setAttribute("type", "application/x-googlegears"); - factory.setAttribute("width", 0); - factory.setAttribute("height", 0); - factory.style.display = "none"; - document.documentElement.appendChild(factory); - } - } - - // still nothing? - if(!factory){ return null; } - - // define the global objects now; don't overwrite them though if they - // were somehow set internally by the Gears plugin, which is on their - // dev roadmap for the future - lang.setObject("google.gears.factory", factory); - return lang.getObject("google.gears"); -}; - - -// see if we have Google Gears installed, and if -// so, make it available in the runtime environment -// and in the Google standard 'google.gears' global object -gears.available = (!!gears._gearsObject())||0; -/*===== - gears.available = { - // summary: - // True if client is using Google Gears - }; - =====*/ - -return gears; -}); diff --git a/lib/dojo/has.js b/lib/dojo/has.js deleted file mode 100644 index b094759..0000000 --- a/lib/dojo/has.js +++ /dev/null @@ -1,71 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/has",["require","module"],function(_1,_2){ -var _3=_1.has||function(){ -}; -if(!1){ -var _4=typeof window!="undefined"&&typeof location!="undefined"&&typeof document!="undefined"&&window.location==location&&window.document==document,_5=this,_6=_4&&document,_7=_6&&_6.createElement("DiV"),_8=(_2.config&&_2.config())||{}; -_3=function(_9){ -return typeof _8[_9]=="function"?(_8[_9]=_8[_9](_5,_6,_7)):_8[_9]; -}; -_3.cache=_8; -_3.add=function(_a,_b,_c,_d){ -(typeof _8[_a]=="undefined"||_d)&&(_8[_a]=_b); -return _c&&_3(_a); -}; -1||_3.add("host-browser",_4); -0&&_3.add("host-node",(typeof process=="object"&&process.versions&&process.versions.node&&process.versions.v8)); -0&&_3.add("host-rhino",(typeof load=="function"&&(typeof Packages=="function"||typeof Packages=="object"))); -1||_3.add("dom",_4); -1||_3.add("dojo-dom-ready-api",1); -1||_3.add("dojo-sniff",1); -} -if(1){ -_3.add("dom-addeventlistener",!!document.addEventListener); -_3.add("touch","ontouchstart" in document||("onpointerdown" in document&&navigator.maxTouchPoints>0)||window.navigator.msMaxTouchPoints); -_3.add("touch-events","ontouchstart" in document); -_3.add("pointer-events","onpointerdown" in document); -_3.add("MSPointer","msMaxTouchPoints" in navigator); -_3.add("device-width",screen.availWidth||innerWidth); -var _e=document.createElement("form"); -_3.add("dom-attributes-explicit",_e.attributes.length==0); -_3.add("dom-attributes-specified-flag",_e.attributes.length>0&&_e.attributes.length<40); -} -_3.clearElement=function(_f){ -_f.innerHTML=""; -return _f; -}; -_3.normalize=function(id,_10){ -var _11=id.match(/[\?:]|[^:\?]*/g),i=0,get=function(_12){ -var _13=_11[i++]; -if(_13==":"){ -return 0; -}else{ -if(_11[i++]=="?"){ -if(!_12&&_3(_13)){ -return get(); -}else{ -get(true); -return get(_12); -} -} -return _13||0; -} -}; -id=get(); -return id&&_10(id); -}; -_3.load=function(id,_14,_15){ -if(id){ -_14([id],_15); -}else{ -_15(); -} -}; -return _3; -}); diff --git a/lib/dojo/has.js.uncompressed.js b/lib/dojo/has.js.uncompressed.js deleted file mode 100644 index 28a4501..0000000 --- a/lib/dojo/has.js.uncompressed.js +++ /dev/null @@ -1,187 +0,0 @@ -define("dojo/has", ["require", "module"], function(require, module){ - // module: - // dojo/has - // summary: - // Defines the has.js API and several feature tests used by dojo. - // description: - // This module defines the has API as described by the project has.js with the following additional features: - // - // - the has test cache is exposed at has.cache. - // - the method has.add includes a forth parameter that controls whether or not existing tests are replaced - // - the loader's has cache may be optionally copied into this module's has cahce. - // - // This module adopted from https://github.com/phiggins42/has.js; thanks has.js team! - - // try to pull the has implementation from the loader; both the dojo loader and bdLoad provide one - // if using a foreign loader, then the has cache may be initialized via the config object for this module - // WARNING: if a foreign loader defines require.has to be something other than the has.js API, then this implementation fail - var has = require.has || function(){}; - if(! 1 ){ - var - isBrowser = - // the most fundamental decision: are we in the browser? - typeof window != "undefined" && - typeof location != "undefined" && - typeof document != "undefined" && - window.location == location && window.document == document, - - // has API variables - global = this, - doc = isBrowser && document, - element = doc && doc.createElement("DiV"), - cache = (module.config && module.config()) || {}; - - has = function(name){ - // summary: - // Return the current value of the named feature. - // - // name: String|Integer - // The name (if a string) or identifier (if an integer) of the feature to test. - // - // description: - // Returns the value of the feature named by name. The feature must have been - // previously added to the cache by has.add. - - return typeof cache[name] == "function" ? (cache[name] = cache[name](global, doc, element)) : cache[name]; // Boolean - }; - - has.cache = cache; - - has.add = function(name, test, now, force){ - // summary: - // Register a new feature test for some named feature. - // name: String|Integer - // The name (if a string) or identifier (if an integer) of the feature to test. - // test: Function - // A test function to register. If a function, queued for testing until actually - // needed. The test function should return a boolean indicating - // the presence of a feature or bug. - // now: Boolean? - // Optional. Omit if `test` is not a function. Provides a way to immediately - // run the test and cache the result. - // force: Boolean? - // Optional. If the test already exists and force is truthy, then the existing - // test will be replaced; otherwise, add does not replace an existing test (that - // is, by default, the first test advice wins). - // example: - // A redundant test, testFn with immediate execution: - // | has.add("javascript", function(){ return true; }, true); - // - // example: - // Again with the redundantness. You can do this in your tests, but we should - // not be doing this in any internal has.js tests - // | has.add("javascript", true); - // - // example: - // Three things are passed to the testFunction. `global`, `document`, and a generic element - // from which to work your test should the need arise. - // | has.add("bug-byid", function(g, d, el){ - // | // g == global, typically window, yadda yadda - // | // d == document object - // | // el == the generic element. a `has` element. - // | return false; // fake test, byid-when-form-has-name-matching-an-id is slightly longer - // | }); - - (typeof cache[name]=="undefined" || force) && (cache[name]= test); - return now && has(name); - }; - - // since we're operating under a loader that doesn't provide a has API, we must explicitly initialize - // has as it would have otherwise been initialized by the dojo loader; use has.add to the builder - // can optimize these away iff desired - 1 || has.add("host-browser", isBrowser); - 0 && has.add("host-node", (typeof process == "object" && process.versions && process.versions.node && process.versions.v8)); - 0 && has.add("host-rhino", (typeof load == "function" && (typeof Packages == "function" || typeof Packages == "object"))); - 1 || has.add("dom", isBrowser); - 1 || has.add("dojo-dom-ready-api", 1); - 1 || has.add("dojo-sniff", 1); - } - - if( 1 ){ - // Common application level tests - has.add("dom-addeventlistener", !!document.addEventListener); - - // Do the device and browser have touch capability? - has.add("touch", "ontouchstart" in document - || ("onpointerdown" in document && navigator.maxTouchPoints > 0) - || window.navigator.msMaxTouchPoints); - - // Touch events support - has.add("touch-events", "ontouchstart" in document); - - // Pointer Events support - has.add("pointer-events", "onpointerdown" in document); - has.add("MSPointer", "msMaxTouchPoints" in navigator); //IE10 (+IE11 preview) - - // I don't know if any of these tests are really correct, just a rough guess - has.add("device-width", screen.availWidth || innerWidth); - - // Tests for DOMNode.attributes[] behavior: - // - dom-attributes-explicit - attributes[] only lists explicitly user specified attributes - // - dom-attributes-specified-flag (IE8) - need to check attr.specified flag to skip attributes user didn't specify - // - Otherwise, in IE6-7. attributes[] will list hundreds of values, so need to do outerHTML to get attrs instead. - var form = document.createElement("form"); - has.add("dom-attributes-explicit", form.attributes.length == 0); // W3C - has.add("dom-attributes-specified-flag", form.attributes.length > 0 && form.attributes.length < 40); // IE8 - } - - has.clearElement = function(element){ - // summary: - // Deletes the contents of the element passed to test functions. - element.innerHTML= ""; - return element; - }; - - has.normalize = function(id, toAbsMid){ - // summary: - // Resolves id into a module id based on possibly-nested tenary expression that branches on has feature test value(s). - // - // toAbsMid: Function - // Resolves a relative module id into an absolute module id - var - tokens = id.match(/[\?:]|[^:\?]*/g), i = 0, - get = function(skip){ - var term = tokens[i++]; - if(term == ":"){ - // empty string module name, resolves to 0 - return 0; - }else{ - // postfixed with a ? means it is a feature to branch on, the term is the name of the feature - if(tokens[i++] == "?"){ - if(!skip && has(term)){ - // matched the feature, get the first value from the options - return get(); - }else{ - // did not match, get the second value, passing over the first - get(true); - return get(skip); - } - } - // a module - return term || 0; - } - }; - id = get(); - return id && toAbsMid(id); - }; - - has.load = function(id, parentRequire, loaded){ - // summary: - // Conditional loading of AMD modules based on a has feature test value. - // id: String - // Gives the resolved module id to load. - // parentRequire: Function - // The loader require function with respect to the module that contained the plugin resource in it's - // dependency list. - // loaded: Function - // Callback to loader that consumes result of plugin demand. - - if(id){ - parentRequire([id], loaded); - }else{ - loaded(); - } - }; - - return has; -}); diff --git a/lib/dojo/hash.js b/lib/dojo/hash.js deleted file mode 100644 index 76d4c7c..0000000 --- a/lib/dojo/hash.js +++ /dev/null @@ -1,137 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/hash",["./_base/kernel","require","./_base/config","./aspect","./_base/lang","./topic","./domReady","./sniff"],function(_1,_2,_3,_4,_5,_6,_7,_8){ -_1.hash=function(_9,_a){ -if(!arguments.length){ -return _b(); -} -if(_9.charAt(0)=="#"){ -_9=_9.substring(1); -} -if(_a){ -_c(_9); -}else{ -location.href="#"+_9; -} -return _9; -}; -var _d,_e,_f,_10=_3.hashPollFrequency||100; -function _11(str,_12){ -var i=str.indexOf(_12); -return (i>=0)?str.substring(i+1):""; -}; -function _b(){ -return _11(location.href,"#"); -}; -function _13(){ -_6.publish("/dojo/hashchange",_b()); -}; -function _14(){ -if(_b()===_d){ -return; -} -_d=_b(); -_13(); -}; -function _c(_15){ -if(_e){ -if(_e.isTransitioning()){ -setTimeout(_5.hitch(null,_c,_15),_10); -return; -} -var _16=_e.iframe.location.href; -var _17=_16.indexOf("?"); -_e.iframe.location.replace(_16.substring(0,_17)+"?"+_15); -return; -} -location.replace("#"+_15); -!_f&&_14(); -}; -function _18(){ -var ifr=document.createElement("iframe"),_19="dojo-hash-iframe",_1a=_3.dojoBlankHtmlUrl||_2.toUrl("./resources/blank.html"); -if(_3.useXDomain&&!_3.dojoBlankHtmlUrl){ -console.warn("dojo/hash: When using cross-domain Dojo builds,"+" please save dojo/resources/blank.html to your domain and set djConfig.dojoBlankHtmlUrl"+" to the path on your domain to blank.html"); -} -ifr.id=_19; -ifr.src=_1a+"?"+_b(); -ifr.style.display="none"; -document.body.appendChild(ifr); -this.iframe=_1.global[_19]; -var _1b,_1c,_1d,_1e,_1f,_20=this.iframe.location; -function _21(){ -_d=_b(); -_1b=_1f?_d:_11(_20.href,"?"); -_1c=false; -_1d=null; -}; -this.isTransitioning=function(){ -return _1c; -}; -this.pollLocation=function(){ -if(!_1f){ -try{ -var _22=_11(_20.href,"?"); -if(document.title!=_1e){ -_1e=this.iframe.document.title=document.title; -} -} -catch(e){ -_1f=true; -console.error("dojo/hash: Error adding history entry. Server unreachable."); -} -} -var _23=_b(); -if(_1c&&_d===_23){ -if(_1f||_22===_1d){ -_21(); -_13(); -}else{ -setTimeout(_5.hitch(this,this.pollLocation),0); -return; -} -}else{ -if(_d===_23&&(_1f||_1b===_22)){ -}else{ -if(_d!==_23){ -_d=_23; -_1c=true; -_1d=_23; -ifr.src=_1a+"?"+_1d; -_1f=false; -setTimeout(_5.hitch(this,this.pollLocation),0); -return; -}else{ -if(!_1f){ -location.href="#"+_20.search.substring(1); -_21(); -_13(); -} -} -} -} -setTimeout(_5.hitch(this,this.pollLocation),_10); -}; -_21(); -setTimeout(_5.hitch(this,this.pollLocation),_10); -}; -_7(function(){ -if("onhashchange" in _1.global&&(!_8("ie")||(_8("ie")>=8&&document.compatMode!="BackCompat"))){ -_f=_4.after(_1.global,"onhashchange",_13,true); -}else{ -if(document.addEventListener){ -_d=_b(); -setInterval(_14,_10); -}else{ -if(document.attachEvent){ -_e=new _18(); -} -} -} -}); -return _1.hash; -}); diff --git a/lib/dojo/hash.js.uncompressed.js b/lib/dojo/hash.js.uncompressed.js deleted file mode 100644 index dacd555..0000000 --- a/lib/dojo/hash.js.uncompressed.js +++ /dev/null @@ -1,256 +0,0 @@ -define("dojo/hash", ["./_base/kernel", "require", "./_base/config", "./aspect", "./_base/lang", "./topic", "./domReady", "./sniff"], - function(dojo, require, config, aspect, lang, topic, domReady, has){ - - // module: - // dojo/hash - - dojo.hash = function(/* String? */ hash, /* Boolean? */ replace){ - // summary: - // Gets or sets the hash string in the browser URL. - // description: - // Handles getting and setting of location.hash. - // - // - If no arguments are passed, acts as a getter. - // - If a string is passed, acts as a setter. - // hash: - // the hash is set - #string. - // replace: - // If true, updates the hash value in the current history - // state instead of creating a new history state. - // returns: - // when used as a getter, returns the current hash string. - // when used as a setter, returns the new hash string. - // example: - // | topic.subscribe("/dojo/hashchange", context, callback); - // | - // | function callback (hashValue){ - // | // do something based on the hash value. - // | } - - // getter - if(!arguments.length){ - return _getHash(); - } - // setter - if(hash.charAt(0) == "#"){ - hash = hash.substring(1); - } - if(replace){ - _replace(hash); - }else{ - location.href = "#" + hash; - } - return hash; // String - }; - - // Global vars - var _recentHash, _ieUriMonitor, _connect, - _pollFrequency = config.hashPollFrequency || 100; - - //Internal functions - function _getSegment(str, delimiter){ - var i = str.indexOf(delimiter); - return (i >= 0) ? str.substring(i+1) : ""; - } - - function _getHash(){ - return _getSegment(location.href, "#"); - } - - function _dispatchEvent(){ - topic.publish("/dojo/hashchange", _getHash()); - } - - function _pollLocation(){ - if(_getHash() === _recentHash){ - return; - } - _recentHash = _getHash(); - _dispatchEvent(); - } - - function _replace(hash){ - if(_ieUriMonitor){ - if(_ieUriMonitor.isTransitioning()){ - setTimeout(lang.hitch(null,_replace,hash), _pollFrequency); - return; - } - var href = _ieUriMonitor.iframe.location.href; - var index = href.indexOf('?'); - // main frame will detect and update itself - _ieUriMonitor.iframe.location.replace(href.substring(0, index) + "?" + hash); - return; - } - location.replace("#"+hash); - !_connect && _pollLocation(); - } - - function IEUriMonitor(){ - // summary: - // Determine if the browser's URI has changed or if the user has pressed the - // back or forward button. If so, call _dispatchEvent. - // - // description: - // IE doesn't add changes to the URI's hash into the history unless the hash - // value corresponds to an actual named anchor in the document. To get around - // this IE difference, we use a background IFrame to maintain a back-forward - // history, by updating the IFrame's query string to correspond to the - // value of the main browser location's hash value. - // - // E.g. if the value of the browser window's location changes to - // - // #action=someAction - // - // ... then we'd update the IFrame's source to: - // - // ?action=someAction - // - // This design leads to a somewhat complex state machine, which is - // described below: - // - // ####s1 - // - // Stable state - neither the window's location has changed nor - // has the IFrame's location. Note that this is the 99.9% case, so - // we optimize for it. - // - // Transitions: s1, s2, s3 - // - // ####s2 - // - // Window's location changed - when a user clicks a hyperlink or - // code programmatically changes the window's URI. - // - // Transitions: s4 - // - // ####s3 - // - // Iframe's location changed as a result of user pressing back or - // forward - when the user presses back or forward, the location of - // the background's iframe changes to the previous or next value in - // its history. - // - // Transitions: s1 - // - // ####s4 - // - // IEUriMonitor has programmatically changed the location of the - // background iframe, but it's location hasn't yet changed. In this - // case we do nothing because we need to wait for the iframe's - // location to reflect its actual state. - // - // Transitions: s4, s5 - // - // ####s5 - // - // IEUriMonitor has programmatically changed the location of the - // background iframe, and the iframe's location has caught up with - // reality. In this case we need to transition to s1. - // - // Transitions: s1 - // - // The hashchange event is always dispatched on the transition back to s1. - - - // create and append iframe - var ifr = document.createElement("iframe"), - IFRAME_ID = "dojo-hash-iframe", - ifrSrc = config.dojoBlankHtmlUrl || require.toUrl("./resources/blank.html"); - - if(config.useXDomain && !config.dojoBlankHtmlUrl){ - console.warn("dojo/hash: When using cross-domain Dojo builds," - + " please save dojo/resources/blank.html to your domain and set djConfig.dojoBlankHtmlUrl" - + " to the path on your domain to blank.html"); - } - - ifr.id = IFRAME_ID; - ifr.src = ifrSrc + "?" + _getHash(); - ifr.style.display = "none"; - document.body.appendChild(ifr); - - this.iframe = dojo.global[IFRAME_ID]; - var recentIframeQuery, transitioning, expectedIFrameQuery, docTitle, ifrOffline, - iframeLoc = this.iframe.location; - - function resetState(){ - _recentHash = _getHash(); - recentIframeQuery = ifrOffline ? _recentHash : _getSegment(iframeLoc.href, "?"); - transitioning = false; - expectedIFrameQuery = null; - } - - this.isTransitioning = function(){ - return transitioning; - }; - - this.pollLocation = function(){ - if(!ifrOffline){ - try{ - //see if we can access the iframe's location without a permission denied error - var iframeSearch = _getSegment(iframeLoc.href, "?"); - //good, the iframe is same origin (no thrown exception) - if(document.title != docTitle){ //sync title of main window with title of iframe. - docTitle = this.iframe.document.title = document.title; - } - }catch(e){ - //permission denied - server cannot be reached. - ifrOffline = true; - console.error("dojo/hash: Error adding history entry. Server unreachable."); - } - } - var hash = _getHash(); - if(transitioning && _recentHash === hash){ - // we're in an iframe transition (s4 or s5) - if(ifrOffline || iframeSearch === expectedIFrameQuery){ - // s5 (iframe caught up to main window or iframe offline), transition back to s1 - resetState(); - _dispatchEvent(); - }else{ - // s4 (waiting for iframe to catch up to main window) - setTimeout(lang.hitch(this,this.pollLocation),0); - return; - } - }else if(_recentHash === hash && (ifrOffline || recentIframeQuery === iframeSearch)){ - // we're in stable state (s1, iframe query == main window hash), do nothing - }else{ - // the user has initiated a URL change somehow. - // sync iframe query <-> main window hash - if(_recentHash !== hash){ - // s2 (main window location changed), set iframe url and transition to s4 - _recentHash = hash; - transitioning = true; - expectedIFrameQuery = hash; - ifr.src = ifrSrc + "?" + expectedIFrameQuery; - ifrOffline = false; //we're updating the iframe src - set offline to false so we can check again on next poll. - setTimeout(lang.hitch(this,this.pollLocation),0); //yielded transition to s4 while iframe reloads. - return; - }else if(!ifrOffline){ - // s3 (iframe location changed via back/forward button), set main window url and transition to s1. - location.href = "#" + iframeLoc.search.substring(1); - resetState(); - _dispatchEvent(); - } - } - setTimeout(lang.hitch(this,this.pollLocation), _pollFrequency); - }; - resetState(); // initialize state (transition to s1) - setTimeout(lang.hitch(this,this.pollLocation), _pollFrequency); - } - domReady(function(){ - if("onhashchange" in dojo.global && (!has("ie") || (has("ie") >= 8 && document.compatMode != "BackCompat"))){ //need this IE browser test because "onhashchange" exists in IE8 in IE7 mode - _connect = aspect.after(dojo.global,"onhashchange",_dispatchEvent, true); - }else{ - if(document.addEventListener){ // Non-IE - _recentHash = _getHash(); - setInterval(_pollLocation, _pollFrequency); //Poll the window location for changes - }else if(document.attachEvent){ // IE7- - //Use hidden iframe in versions of IE that don't have onhashchange event - _ieUriMonitor = new IEUriMonitor(); - } - // else non-supported browser, do nothing. - } - }); - - return dojo.hash; - -}); diff --git a/lib/dojo/hccss.js b/lib/dojo/hccss.js deleted file mode 100644 index 2854f7c..0000000 --- a/lib/dojo/hccss.js +++ /dev/null @@ -1,27 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/hccss",["require","./_base/config","./dom-class","./dom-style","./has","./domReady","./_base/window"],function(_1,_2,_3,_4,_5,_6,_7){ -_5.add("highcontrast",function(){ -var _8=_7.doc.createElement("div"); -_8.style.cssText="border: 1px solid; border-color:red green; position: absolute; height: 5px; top: -999px;"+"background-image: url(\""+(_2.blankGif||_1.toUrl("./resources/blank.gif"))+"\");"; -_7.body().appendChild(_8); -var cs=_4.getComputedStyle(_8),_9=cs.backgroundImage,hc=(cs.borderTopColor==cs.borderRightColor)||(_9&&(_9=="none"||_9=="url(invalid-url:)")); -if(_5("ie")<=8){ -_8.outerHTML=""; -}else{ -_7.body().removeChild(_8); -} -return hc; -}); -_6(function(){ -if(_5("highcontrast")){ -_3.add(_7.body(),"dj_a11y"); -} -}); -return _5; -}); diff --git a/lib/dojo/hccss.js.uncompressed.js b/lib/dojo/hccss.js.uncompressed.js deleted file mode 100644 index 0109b35..0000000 --- a/lib/dojo/hccss.js.uncompressed.js +++ /dev/null @@ -1,52 +0,0 @@ -define("dojo/hccss", [ - "require", // require, require.toUrl - "./_base/config", // config.blankGif - "./dom-class", // domClass.add - "./dom-style", // domStyle.getComputedStyle - "./has", - "./domReady", - "./_base/window" // win.body -], function(require, config, domClass, domStyle, has, domReady, win){ - - // module: - // dojo/hccss - - /*===== - return function(){ - // summary: - // Test if computer is in high contrast mode (i.e. if browser is not displaying background images). - // Defines `has("highcontrast")` and sets `dj_a11y` CSS class on `` if machine is in high contrast mode. - // Returns `has()` method; - }; - =====*/ - - // Has() test for when background images aren't displayed. Don't call has("highcontrast") before dojo/domReady!. - has.add("highcontrast", function(){ - // note: if multiple documents, doesn't matter which one we use - var div = win.doc.createElement("div"); - div.style.cssText = "border: 1px solid; border-color:red green; position: absolute; height: 5px; top: -999px;" + - "background-image: url(\"" + (config.blankGif || require.toUrl("./resources/blank.gif")) + "\");"; - win.body().appendChild(div); - - var cs = domStyle.getComputedStyle(div), - bkImg = cs.backgroundImage, - hc = (cs.borderTopColor == cs.borderRightColor) || - (bkImg && (bkImg == "none" || bkImg == "url(invalid-url:)" )); - - if(has("ie") <= 8){ - div.outerHTML = ""; // prevent mixed-content warning, see http://support.microsoft.com/kb/925014 - }else{ - win.body().removeChild(div); - } - - return hc; - }); - - domReady(function(){ - if(has("highcontrast")){ - domClass.add(win.body(), "dj_a11y"); - } - }); - - return has; -}); diff --git a/lib/dojo/html.js b/lib/dojo/html.js deleted file mode 100644 index 9f14a2d..0000000 --- a/lib/dojo/html.js +++ /dev/null @@ -1,162 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/html",["./_base/kernel","./_base/lang","./_base/array","./_base/declare","./dom","./dom-construct","./parser"],function(_1,_2,_3,_4,_5,_6,_7){ -var _8=0; -var _9={_secureForInnerHtml:function(_a){ -return _a.replace(/(?:\s*]+>|]*>[\s\S]*?<\/title>)/ig,""); -},_emptyNode:_6.empty,_setNodeContent:function(_b,_c){ -_6.empty(_b); -if(_c){ -if(typeof _c=="string"){ -_c=_6.toDom(_c,_b.ownerDocument); -} -if(!_c.nodeType&&_2.isArrayLike(_c)){ -for(var _d=_c.length,i=0;i<_c.length;i=_d==_c.length?i+1:0){ -_6.place(_c[i],_b,"last"); -} -}else{ -_6.place(_c,_b,"last"); -} -} -return _b; -},_ContentSetter:_4("dojo.html._ContentSetter",null,{node:"",content:"",id:"",cleanContent:false,extractContent:false,parseContent:false,parserScope:_1._scopeName,startup:true,constructor:function(_e,_f){ -_2.mixin(this,_e||{}); -_f=this.node=_5.byId(this.node||_f); -if(!this.id){ -this.id=["Setter",(_f)?_f.id||_f.tagName:"",_8++].join("_"); -} -},set:function(_10,_11){ -if(undefined!==_10){ -this.content=_10; -} -if(_11){ -this._mixin(_11); -} -this.onBegin(); -this.setContent(); -var ret=this.onEnd(); -if(ret&&ret.then){ -return ret; -}else{ -return this.node; -} -},setContent:function(){ -var _12=this.node; -if(!_12){ -throw new Error(this.declaredClass+": setContent given no node"); -} -try{ -_12=_9._setNodeContent(_12,this.content); -} -catch(e){ -var _13=this.onContentError(e); -try{ -_12.innerHTML=_13; -} -catch(e){ -console.error("Fatal "+this.declaredClass+".setContent could not change content due to "+e.message,e); -} -} -this.node=_12; -},empty:function(){ -if(this.parseDeferred){ -if(!this.parseDeferred.isResolved()){ -this.parseDeferred.cancel(); -} -delete this.parseDeferred; -} -if(this.parseResults&&this.parseResults.length){ -_3.forEach(this.parseResults,function(w){ -if(w.destroy){ -w.destroy(); -} -}); -delete this.parseResults; -} -_6.empty(this.node); -},onBegin:function(){ -var _14=this.content; -if(_2.isString(_14)){ -if(this.cleanContent){ -_14=_9._secureForInnerHtml(_14); -} -if(this.extractContent){ -var _15=_14.match(/]*>\s*([\s\S]+)\s*<\/body>/im); -if(_15){ -_14=_15[1]; -} -} -} -this.empty(); -this.content=_14; -return this.node; -},onEnd:function(){ -if(this.parseContent){ -this._parse(); -} -return this.node; -},tearDown:function(){ -delete this.parseResults; -delete this.parseDeferred; -delete this.node; -delete this.content; -},onContentError:function(err){ -return "Error occurred setting content: "+err; -},onExecError:function(err){ -return "Error occurred executing scripts: "+err; -},_mixin:function(_16){ -var _17={},key; -for(key in _16){ -if(key in _17){ -continue; -} -this[key]=_16[key]; -} -},_parse:function(){ -var _18=this.node; -try{ -var _19={}; -_3.forEach(["dir","lang","textDir"],function(_1a){ -if(this[_1a]){ -_19[_1a]=this[_1a]; -} -},this); -var _1b=this; -this.parseDeferred=_7.parse({rootNode:_18,noStart:!this.startup,inherited:_19,scope:this.parserScope}).then(function(_1c){ -return _1b.parseResults=_1c; -},function(e){ -_1b._onError("Content",e,"Error parsing in _ContentSetter#"+this.id); -}); -} -catch(e){ -this._onError("Content",e,"Error parsing in _ContentSetter#"+this.id); -} -},_onError:function(_1d,err,_1e){ -var _1f=this["on"+_1d+"Error"].call(this,err); -if(_1e){ -console.error(_1e,err); -}else{ -if(_1f){ -_9._setNodeContent(this.node,_1f,true); -} -} -}}),set:function(_20,_21,_22){ -if(undefined==_21){ -console.warn("dojo.html.set: no cont argument provided, using empty string"); -_21=""; -} -if(!_22){ -return _9._setNodeContent(_20,_21,true); -}else{ -var op=new _9._ContentSetter(_2.mixin(_22,{content:_21,node:_20})); -return op.set(); -} -}}; -_2.setObject("dojo.html",_9); -return _9; -}); diff --git a/lib/dojo/html.js.uncompressed.js b/lib/dojo/html.js.uncompressed.js deleted file mode 100644 index 543c75c..0000000 --- a/lib/dojo/html.js.uncompressed.js +++ /dev/null @@ -1,370 +0,0 @@ -define("dojo/html", ["./_base/kernel", "./_base/lang", "./_base/array", "./_base/declare", "./dom", "./dom-construct", "./parser"], - function(kernel, lang, darray, declare, dom, domConstruct, parser){ - // module: - // dojo/html - - // the parser might be needed.. - - // idCounter is incremented with each instantiation to allow assignment of a unique id for tracking, logging purposes - var idCounter = 0; - - var html = { - // summary: - // TODOC - - _secureForInnerHtml: function(/*String*/ cont){ - // summary: - // removes !DOCTYPE and title elements from the html string. - // - // khtml is picky about dom faults, you can't attach a style or `` node as child of body - // must go into head, so we need to cut out those tags - // cont: - // An html string for insertion into the dom - // - return cont.replace(/(?:\s*<!DOCTYPE\s[^>]+>|<title[^>]*>[\s\S]*?<\/title>)/ig, ""); // String - }, - - // Deprecated, should use dojo/dom-constuct.empty() directly, remove in 2.0. - _emptyNode: domConstruct.empty, - - _setNodeContent: function(/*DomNode*/ node, /*String|DomNode|NodeList*/ cont){ - // summary: - // inserts the given content into the given node - // node: - // the parent element - // content: - // the content to be set on the parent element. - // This can be an html string, a node reference or a NodeList, dojo/NodeList, Array or other enumerable list of nodes - - // always empty - domConstruct.empty(node); - - if(cont){ - if(typeof cont == "string"){ - cont = domConstruct.toDom(cont, node.ownerDocument); - } - if(!cont.nodeType && lang.isArrayLike(cont)){ - // handle as enumerable, but it may shrink as we enumerate it - for(var startlen=cont.length, i=0; i<cont.length; i=startlen==cont.length ? i+1 : 0){ - domConstruct.place( cont[i], node, "last"); - } - }else{ - // pass nodes, documentFragments and unknowns through to dojo.place - domConstruct.place(cont, node, "last"); - } - } - - // return DomNode - return node; - }, - - // we wrap up the content-setting operation in a object - _ContentSetter: declare("dojo.html._ContentSetter", null, { - // node: DomNode|String - // An node which will be the parent element that we set content into - node: "", - - // content: String|DomNode|DomNode[] - // The content to be placed in the node. Can be an HTML string, a node reference, or a enumerable list of nodes - content: "", - - // id: String? - // Usually only used internally, and auto-generated with each instance - id: "", - - // cleanContent: Boolean - // Should the content be treated as a full html document, - // and the real content stripped of <html>, <body> wrapper before injection - cleanContent: false, - - // extractContent: Boolean - // Should the content be treated as a full html document, - // and the real content stripped of `<html> <body>` wrapper before injection - extractContent: false, - - // parseContent: Boolean - // Should the node by passed to the parser after the new content is set - parseContent: false, - - // parserScope: String - // Flag passed to parser. Root for attribute names to search for. If scopeName is dojo, - // will search for data-dojo-type (or dojoType). For backwards compatibility - // reasons defaults to dojo._scopeName (which is "dojo" except when - // multi-version support is used, when it will be something like dojo16, dojo20, etc.) - parserScope: kernel._scopeName, - - // startup: Boolean - // Start the child widgets after parsing them. Only obeyed if parseContent is true. - startup: true, - - // lifecycle methods - constructor: function(/*Object*/ params, /*String|DomNode*/ node){ - // summary: - // Provides a configurable, extensible object to wrap the setting on content on a node - // call the set() method to actually set the content.. - - // the original params are mixed directly into the instance "this" - lang.mixin(this, params || {}); - - // give precedence to params.node vs. the node argument - // and ensure its a node, not an id string - node = this.node = dom.byId( this.node || node ); - - if(!this.id){ - this.id = [ - "Setter", - (node) ? node.id || node.tagName : "", - idCounter++ - ].join("_"); - } - }, - set: function(/* String|DomNode|NodeList? */ cont, /*Object?*/ params){ - // summary: - // front-end to the set-content sequence - // cont: - // An html string, node or enumerable list of nodes for insertion into the dom - // If not provided, the object's content property will be used - if(undefined !== cont){ - this.content = cont; - } - // in the re-use scenario, set needs to be able to mixin new configuration - if(params){ - this._mixin(params); - } - - this.onBegin(); - this.setContent(); - - var ret = this.onEnd(); - - if(ret && ret.then){ - // Make dojox/html/_ContentSetter.set() return a Promise that resolves when load and parse complete. - return ret; - }else{ - // Vanilla dojo/html._ContentSetter.set() returns a DOMNode for back compat. For 2.0, switch it to - // return a Deferred like above. - return this.node; - } - }, - - setContent: function(){ - // summary: - // sets the content on the node - - var node = this.node; - if(!node){ - // can't proceed - throw new Error(this.declaredClass + ": setContent given no node"); - } - try{ - node = html._setNodeContent(node, this.content); - }catch(e){ - // check if a domfault occurs when we are appending this.errorMessage - // like for instance if domNode is a UL and we try append a DIV - - // FIXME: need to allow the user to provide a content error message string - var errMess = this.onContentError(e); - try{ - node.innerHTML = errMess; - }catch(e){ - console.error('Fatal ' + this.declaredClass + '.setContent could not change content due to '+e.message, e); - } - } - // always put back the node for the next method - this.node = node; // DomNode - }, - - empty: function(){ - // summary: - // cleanly empty out existing content - - // If there is a parse in progress, cancel it. - if(this.parseDeferred){ - if(!this.parseDeferred.isResolved()){ - this.parseDeferred.cancel(); - } - delete this.parseDeferred; - } - - // destroy any widgets from a previous run - // NOTE: if you don't want this you'll need to empty - // the parseResults array property yourself to avoid bad things happening - if(this.parseResults && this.parseResults.length){ - darray.forEach(this.parseResults, function(w){ - if(w.destroy){ - w.destroy(); - } - }); - delete this.parseResults; - } - // this is fast, but if you know its already empty or safe, you could - // override empty to skip this step - domConstruct.empty(this.node); - }, - - onBegin: function(){ - // summary: - // Called after instantiation, but before set(); - // It allows modification of any of the object properties - - // including the node and content provided - before the set operation actually takes place - // This default implementation checks for cleanContent and extractContent flags to - // optionally pre-process html string content - var cont = this.content; - - if(lang.isString(cont)){ - if(this.cleanContent){ - cont = html._secureForInnerHtml(cont); - } - - if(this.extractContent){ - var match = cont.match(/<body[^>]*>\s*([\s\S]+)\s*<\/body>/im); - if(match){ cont = match[1]; } - } - } - - // clean out the node and any cruft associated with it - like widgets - this.empty(); - - this.content = cont; - return this.node; // DomNode - }, - - onEnd: function(){ - // summary: - // Called after set(), when the new content has been pushed into the node - // It provides an opportunity for post-processing before handing back the node to the caller - // This default implementation checks a parseContent flag to optionally run the dojo parser over the new content - if(this.parseContent){ - // populates this.parseResults and this.parseDeferred if you need those.. - this._parse(); - } - return this.node; // DomNode - // TODO: for 2.0 return a Promise indicating that the parse completed. - }, - - tearDown: function(){ - // summary: - // manually reset the Setter instance if its being re-used for example for another set() - // description: - // tearDown() is not called automatically. - // In normal use, the Setter instance properties are simply allowed to fall out of scope - // but the tearDown method can be called to explicitly reset this instance. - delete this.parseResults; - delete this.parseDeferred; - delete this.node; - delete this.content; - }, - - onContentError: function(err){ - return "Error occurred setting content: " + err; - }, - - onExecError: function(err){ - return "Error occurred executing scripts: " + err; - }, - - _mixin: function(params){ - // mix properties/methods into the instance - // TODO: the intention with tearDown is to put the Setter's state - // back to that of the original constructor (vs. deleting/resetting everything regardless of ctor params) - // so we could do something here to move the original properties aside for later restoration - var empty = {}, key; - for(key in params){ - if(key in empty){ continue; } - // TODO: here's our opportunity to mask the properties we don't consider configurable/overridable - // .. but history shows we'll almost always guess wrong - this[key] = params[key]; - } - }, - _parse: function(){ - // summary: - // runs the dojo parser over the node contents, storing any results in this.parseResults - // and the parse promise in this.parseDeferred - // Any errors resulting from parsing are passed to _onError for handling - - var rootNode = this.node; - try{ - // store the results (widgets, whatever) for potential retrieval - var inherited = {}; - darray.forEach(["dir", "lang", "textDir"], function(name){ - if(this[name]){ - inherited[name] = this[name]; - } - }, this); - var self = this; - this.parseDeferred = parser.parse({ - rootNode: rootNode, - noStart: !this.startup, - inherited: inherited, - scope: this.parserScope - }).then(function(results){ - return self.parseResults = results; - }, function(e){ - self._onError('Content', e, "Error parsing in _ContentSetter#" + this.id); - }); - }catch(e){ - this._onError('Content', e, "Error parsing in _ContentSetter#" + this.id); - } - }, - - _onError: function(type, err, consoleText){ - // summary: - // shows user the string that is returned by on[type]Error - // override/implement on[type]Error and return your own string to customize - var errText = this['on' + type + 'Error'].call(this, err); - if(consoleText){ - console.error(consoleText, err); - }else if(errText){ // a empty string won't change current content - html._setNodeContent(this.node, errText, true); - } - } - }), // end declare() - - set: function(/*DomNode*/ node, /*String|DomNode|NodeList*/ cont, /*Object?*/ params){ - // summary: - // inserts (replaces) the given content into the given node. dojo/dom-construct.place(cont, node, "only") - // may be a better choice for simple HTML insertion. - // description: - // Unless you need to use the params capabilities of this method, you should use - // dojo/dom-construct.place(cont, node, "only"). dojo/dom-construct..place() has more robust support for injecting - // an HTML string into the DOM, but it only handles inserting an HTML string as DOM - // elements, or inserting a DOM node. dojo/dom-construct..place does not handle NodeList insertions - // dojo/dom-construct.place(cont, node, "only"). dojo/dom-construct.place() has more robust support for injecting - // an HTML string into the DOM, but it only handles inserting an HTML string as DOM - // elements, or inserting a DOM node. dojo/dom-construct.place does not handle NodeList insertions - // or the other capabilities as defined by the params object for this method. - // node: - // the parent element that will receive the content - // cont: - // the content to be set on the parent element. - // This can be an html string, a node reference or a NodeList, dojo/NodeList, Array or other enumerable list of nodes - // params: - // Optional flags/properties to configure the content-setting. See dojo/html/_ContentSetter - // example: - // A safe string/node/nodelist content replacement/injection with hooks for extension - // Example Usage: - // | html.set(node, "some string"); - // | html.set(node, contentNode, {options}); - // | html.set(node, myNode.childNodes, {options}); - if(undefined == cont){ - console.warn("dojo.html.set: no cont argument provided, using empty string"); - cont = ""; - } - if(!params){ - // simple and fast - return html._setNodeContent(node, cont, true); - }else{ - // more options but slower - // note the arguments are reversed in order, to match the convention for instantiation via the parser - var op = new html._ContentSetter(lang.mixin( - params, - { content: cont, node: node } - )); - return op.set(); - } - } - }; - lang.setObject("dojo.html", html); - - return html; -}); diff --git a/lib/dojo/i18n.js b/lib/dojo/i18n.js deleted file mode 100644 index 9cdc73d..0000000 --- a/lib/dojo/i18n.js +++ /dev/null @@ -1,279 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/i18n",["./_base/kernel","require","./has","./_base/array","./_base/config","./_base/lang","./_base/xhr","./json","module"],function(_1,_2,_3,_4,_5,_6,_7,_8,_9){ -_3.add("dojo-preload-i18n-Api",1); -1||_3.add("dojo-v1x-i18n-Api",1); -var _a=_1.i18n={},_b=/(^.*(^|\/)nls)(\/|$)([^\/]*)\/?([^\/]*)/,_c=function(_d,_e,_f,_10){ -for(var _11=[_f+_10],_12=_e.split("-"),_13="",i=0;i<_12.length;i++){ -_13+=(_13?"-":"")+_12[i]; -if(!_d||_d[_13]){ -_11.push(_f+_13+"/"+_10); -_11.specificity=_13; -} -} -return _11; -},_14={},_15=function(_16,_17,_18){ -_18=_18?_18.toLowerCase():_1.locale; -_16=_16.replace(/\./g,"/"); -_17=_17.replace(/\./g,"/"); -return (/root/i.test(_18))?(_16+"/nls/"+_17):(_16+"/nls/"+_18+"/"+_17); -},_19=_1.getL10nName=function(_1a,_1b,_1c){ -return _1a=_9.id+"!"+_15(_1a,_1b,_1c); -},_1d=function(_1e,_1f,_20,_21,_22,_23){ -_1e([_1f],function(_24){ -var _25=_6.clone(_24.root||_24.ROOT),_26=_c(!_24._v1x&&_24,_22,_20,_21); -_1e(_26,function(){ -for(var i=1;i<_26.length;i++){ -_25=_6.mixin(_6.clone(_25),arguments[i]); -} -var _27=_1f+"/"+_22; -_14[_27]=_25; -_25.$locale=_26.specificity; -_23(); -}); -}); -},_28=function(id,_29){ -return /^\./.test(id)?_29(id):id; -},_2a=function(_2b){ -var _2c=_5.extraLocale||[]; -_2c=_6.isArray(_2c)?_2c:[_2c]; -_2c.push(_2b); -return _2c; -},_2d=function(id,_2e,_2f){ -if(_3("dojo-preload-i18n-Api")){ -var _30=id.split("*"),_31=_30[1]=="preload"; -if(_31){ -if(!_14[id]){ -_14[id]=1; -_32(_30[2],_8.parse(_30[3]),1,_2e); -} -_2f(1); -} -if(_31||_33(id,_2e,_2f)){ -return; -} -} -var _34=_b.exec(id),_35=_34[1]+"/",_36=_34[5]||_34[4],_37=_35+_36,_38=(_34[5]&&_34[4]),_39=_38||_1.locale||"",_3a=_37+"/"+_39,_3b=_38?[_39]:_2a(_39),_3c=_3b.length,_3d=function(){ -if(!--_3c){ -_2f(_6.delegate(_14[_3a])); -} -}; -_4.forEach(_3b,function(_3e){ -var _3f=_37+"/"+_3e; -if(_3("dojo-preload-i18n-Api")){ -_40(_3f); -} -if(!_14[_3f]){ -_1d(_2e,_37,_35,_36,_3e,_3d); -}else{ -_3d(); -} -}); -}; -if(_3("dojo-unit-tests")){ -var _41=_a.unitTests=[]; -} -if(_3("dojo-preload-i18n-Api")||1){ -var _42=_a.normalizeLocale=function(_43){ -var _44=_43?_43.toLowerCase():_1.locale; -return _44=="root"?"ROOT":_44; -},_45=function(mid,_46){ -return (1&&1)?_46.isXdUrl(_2.toUrl(mid+".js")):true; -},_47=0,_48=[],_32=_a._preloadLocalizations=function(_49,_4a,_4b,_4c){ -_4c=_4c||_2; -function _4d(mid,_4e){ -if(_45(mid,_4c)||_4b){ -_4c([mid],_4e); -}else{ -_6d([mid],_4e,_4c); -} -}; -function _4f(_50,_51){ -var _52=_50.split("-"); -while(_52.length){ -if(_51(_52.join("-"))){ -return; -} -_52.pop(); -} -_51("ROOT"); -}; -function _53(){ -_47++; -}; -function _54(){ ---_47; -while(!_47&&_48.length){ -_2d.apply(null,_48.shift()); -} -}; -function _55(_56,_57,loc,_58){ -return _58.toAbsMid(_56+_57+"/"+loc); -}; -function _59(_5a){ -_5a=_42(_5a); -_4f(_5a,function(loc){ -if(_4.indexOf(_4a,loc)>=0){ -var mid=_49.replace(/\./g,"/")+"_"+loc; -_53(); -_4d(mid,function(_5b){ -for(var p in _5b){ -var _5c=_5b[p],_5d=p.match(/(.+)\/([^\/]+)$/),_5e,_5f; -if(!_5d){ -continue; -} -_5e=_5d[2]; -_5f=_5d[1]+"/"; -_5c._localized=_5c._localized||{}; -var _60; -if(loc==="ROOT"){ -var _61=_60=_5c._localized; -delete _5c._localized; -_61.root=_5c; -_14[_2.toAbsMid(p)]=_61; -}else{ -_60=_5c._localized; -_14[_55(_5f,_5e,loc,_2)]=_5c; -} -if(loc!==_5a){ -function _62(_63,_64,_65,_66){ -var _67=[],_68=[]; -_4f(_5a,function(loc){ -if(_66[loc]){ -_67.push(_2.toAbsMid(_63+loc+"/"+_64)); -_68.push(_55(_63,_64,loc,_2)); -} -}); -if(_67.length){ -_53(); -_4c(_67,function(){ -for(var i=0;i<_67.length;i++){ -_65=_6.mixin(_6.clone(_65),arguments[i]); -_14[_68[i]]=_65; -} -_14[_55(_63,_64,_5a,_2)]=_6.clone(_65); -_54(); -}); -}else{ -_14[_55(_63,_64,_5a,_2)]=_65; -} -}; -_62(_5f,_5e,_5c,_60); -} -} -_54(); -}); -return true; -} -return false; -}); -}; -_59(); -_4.forEach(_1.config.extraLocale,_59); -},_33=function(id,_69,_6a){ -if(_47){ -_48.push([id,_69,_6a]); -} -return _47; -},_40=function(){ -}; -} -if(1){ -var _6b={},_6c=new Function("__bundle","__checkForLegacyModules","__mid","__amdValue","var define = function(mid, factory){define.called = 1; __amdValue.result = factory || mid;},"+"\t require = function(){define.called = 1;};"+"try{"+"define.called = 0;"+"eval(__bundle);"+"if(define.called==1)"+"return __amdValue;"+"if((__checkForLegacyModules = __checkForLegacyModules(__mid)))"+"return __checkForLegacyModules;"+"}catch(e){}"+"try{"+"return eval('('+__bundle+')');"+"}catch(e){"+"return e;"+"}"),_6d=function(_6e,_6f,_70){ -var _71=[]; -_4.forEach(_6e,function(mid){ -var url=_70.toUrl(mid+".js"); -function _2d(_72){ -var _73=_6c(_72,_40,mid,_6b); -if(_73===_6b){ -_71.push(_14[url]=_6b.result); -}else{ -if(_73 instanceof Error){ -console.error("failed to evaluate i18n bundle; url="+url,_73); -_73={}; -} -_71.push(_14[url]=(/nls\/[^\/]+\/[^\/]+$/.test(url)?_73:{root:_73,_v1x:1})); -} -}; -if(_14[url]){ -_71.push(_14[url]); -}else{ -var _74=_70.syncLoadNls(mid); -if(_74){ -_71.push(_74); -}else{ -if(!_7){ -try{ -_70.getText(url,true,_2d); -} -catch(e){ -_71.push(_14[url]={}); -} -}else{ -_7.get({url:url,sync:true,load:_2d,error:function(){ -_71.push(_14[url]={}); -}}); -} -} -} -}); -_6f&&_6f.apply(null,_71); -}; -_40=function(_75){ -for(var _76,_77=_75.split("/"),_78=_1.global[_77[0]],i=1;_78&&i<_77.length-1;_78=_78[_77[i++]]){ -} -if(_78){ -_76=_78[_77[i]]; -if(!_76){ -_76=_78[_77[i].replace(/-/g,"_")]; -} -if(_76){ -_14[_75]=_76; -} -} -return _76; -}; -_a.getLocalization=function(_79,_7a,_7b){ -var _7c,_7d=_15(_79,_7a,_7b); -_2d(_7d,(!_45(_7d,_2)?function(_7e,_7f){ -_6d(_7e,_7f,_2); -}:_2),function(_80){ -_7c=_80; -}); -return _7c; -}; -if(_3("dojo-unit-tests")){ -_41.push(function(doh){ -doh.register("tests.i18n.unit",function(t){ -var _81; -_81=_6c("{prop:1}",_40,"nonsense",_6b); -t.is({prop:1},_81); -t.is(undefined,_81[1]); -_81=_6c("({prop:1})",_40,"nonsense",_6b); -t.is({prop:1},_81); -t.is(undefined,_81[1]); -_81=_6c("{'prop-x':1}",_40,"nonsense",_6b); -t.is({"prop-x":1},_81); -t.is(undefined,_81[1]); -_81=_6c("({'prop-x':1})",_40,"nonsense",_6b); -t.is({"prop-x":1},_81); -t.is(undefined,_81[1]); -_81=_6c("define({'prop-x':1})",_40,"nonsense",_6b); -t.is(_6b,_81); -t.is({"prop-x":1},_6b.result); -_81=_6c("define('some/module', {'prop-x':1})",_40,"nonsense",_6b); -t.is(_6b,_81); -t.is({"prop-x":1},_6b.result); -_81=_6c("this is total nonsense and should throw an error",_40,"nonsense",_6b); -t.is(_81 instanceof Error,true); -}); -}); -} -} -return _6.mixin(_a,{dynamic:true,normalize:_28,load:_2d,cache:_14,getL10nName:_19}); -}); diff --git a/lib/dojo/i18n.js.uncompressed.js b/lib/dojo/i18n.js.uncompressed.js deleted file mode 100644 index 7c874fd..0000000 --- a/lib/dojo/i18n.js.uncompressed.js +++ /dev/null @@ -1,636 +0,0 @@ -define("dojo/i18n", ["./_base/kernel", "require", "./has", "./_base/array", "./_base/config", "./_base/lang", "./_base/xhr", "./json", "module"], - function(dojo, require, has, array, config, lang, xhr, json, module){ - - // module: - // dojo/i18n - - has.add("dojo-preload-i18n-Api", - // if true, define the preload localizations machinery - 1 - ); - - 1 || has.add("dojo-v1x-i18n-Api", - // if true, define the v1.x i18n functions - 1 - ); - - var - thisModule = dojo.i18n = - { - // summary: - // This module implements the dojo/i18n! plugin and the v1.6- i18n API - // description: - // We choose to include our own plugin to leverage functionality already contained in dojo - // and thereby reduce the size of the plugin compared to various loader implementations. Also, this - // allows foreign AMD loaders to be used without their plugins. - }, - - nlsRe = - // regexp for reconstructing the master bundle name from parts of the regexp match - // nlsRe.exec("foo/bar/baz/nls/en-ca/foo") gives: - // ["foo/bar/baz/nls/en-ca/foo", "foo/bar/baz/nls/", "/", "/", "en-ca", "foo"] - // nlsRe.exec("foo/bar/baz/nls/foo") gives: - // ["foo/bar/baz/nls/foo", "foo/bar/baz/nls/", "/", "/", "foo", ""] - // so, if match[5] is blank, it means this is the top bundle definition. - // courtesy of http://requirejs.org - /(^.*(^|\/)nls)(\/|$)([^\/]*)\/?([^\/]*)/, - - getAvailableLocales = function( - root, - locale, - bundlePath, - bundleName - ){ - // summary: - // return a vector of module ids containing all available locales with respect to the target locale - // For example, assuming: - // - // - the root bundle indicates specific bundles for "fr" and "fr-ca", - // - bundlePath is "myPackage/nls" - // - bundleName is "myBundle" - // - // Then a locale argument of "fr-ca" would return - // - // ["myPackage/nls/myBundle", "myPackage/nls/fr/myBundle", "myPackage/nls/fr-ca/myBundle"] - // - // Notice that bundles are returned least-specific to most-specific, starting with the root. - // - // If root===false indicates we're working with a pre-AMD i18n bundle that doesn't tell about the available locales; - // therefore, assume everything is available and get 404 errors that indicate a particular localization is not available - - for(var result = [bundlePath + bundleName], localeParts = locale.split("-"), current = "", i = 0; i<localeParts.length; i++){ - current += (current ? "-" : "") + localeParts[i]; - if(!root || root[current]){ - result.push(bundlePath + current + "/" + bundleName); - result.specificity = current; - } - } - return result; - }, - - cache = {}, - - getBundleName = function(moduleName, bundleName, locale){ - locale = locale ? locale.toLowerCase() : dojo.locale; - moduleName = moduleName.replace(/\./g, "/"); - bundleName = bundleName.replace(/\./g, "/"); - return (/root/i.test(locale)) ? - (moduleName + "/nls/" + bundleName) : - (moduleName + "/nls/" + locale + "/" + bundleName); - }, - - getL10nName = dojo.getL10nName = function(moduleName, bundleName, locale){ - return moduleName = module.id + "!" + getBundleName(moduleName, bundleName, locale); - }, - - doLoad = function(require, bundlePathAndName, bundlePath, bundleName, locale, load){ - // summary: - // get the root bundle which instructs which other bundles are required to construct the localized bundle - require([bundlePathAndName], function(root){ - var current = lang.clone(root.root || root.ROOT),// 1.6 built bundle defined ROOT - availableLocales = getAvailableLocales(!root._v1x && root, locale, bundlePath, bundleName); - require(availableLocales, function(){ - for (var i = 1; i<availableLocales.length; i++){ - current = lang.mixin(lang.clone(current), arguments[i]); - } - // target may not have been resolve (e.g., maybe only "fr" exists when "fr-ca" was requested) - var target = bundlePathAndName + "/" + locale; - cache[target] = current; - current.$locale = availableLocales.specificity; - load(); - }); - }); - }, - - normalize = function(id, toAbsMid){ - // summary: - // id may be relative. - // preload has form `*preload*<path>/nls/<module>*<flattened locales>` and - // therefore never looks like a relative - return /^\./.test(id) ? toAbsMid(id) : id; - }, - - getLocalesToLoad = function(targetLocale){ - var list = config.extraLocale || []; - list = lang.isArray(list) ? list : [list]; - list.push(targetLocale); - return list; - }, - - load = function(id, require, load){ - // summary: - // id is in one of the following formats - // - // 1. <path>/nls/<bundle> - // => load the bundle, localized to config.locale; load all bundles localized to - // config.extraLocale (if any); return the loaded bundle localized to config.locale. - // - // 2. <path>/nls/<locale>/<bundle> - // => load then return the bundle localized to <locale> - // - // 3. *preload*<path>/nls/<module>*<JSON array of available locales> - // => for config.locale and all config.extraLocale, load all bundles found - // in the best-matching bundle rollup. A value of 1 is returned, which - // is meaningless other than to say the plugin is executing the requested - // preloads - // - // In cases 1 and 2, <path> is always normalized to an absolute module id upon entry; see - // normalize. In case 3, it <path> is assumed to be absolute; this is arranged by the builder. - // - // To load a bundle means to insert the bundle into the plugin's cache and publish the bundle - // value to the loader. Given <path>, <bundle>, and a particular <locale>, the cache key - // - // <path>/nls/<bundle>/<locale> - // - // will hold the value. Similarly, then plugin will publish this value to the loader by - // - // define("<path>/nls/<bundle>/<locale>", <bundle-value>); - // - // Given this algorithm, other machinery can provide fast load paths be preplacing - // values in the plugin's cache, which is public. When a load is demanded the - // cache is inspected before starting any loading. Explicitly placing values in the plugin - // cache is an advanced/experimental feature that should not be needed; use at your own risk. - // - // For the normal AMD algorithm, the root bundle is loaded first, which instructs the - // plugin what additional localized bundles are required for a particular locale. These - // additional locales are loaded and a mix of the root and each progressively-specific - // locale is returned. For example: - // - // 1. The client demands "dojo/i18n!some/path/nls/someBundle - // - // 2. The loader demands load(some/path/nls/someBundle) - // - // 3. This plugin require's "some/path/nls/someBundle", which is the root bundle. - // - // 4. Assuming config.locale is "ab-cd-ef" and the root bundle indicates that localizations - // are available for "ab" and "ab-cd-ef" (note the missing "ab-cd", then the plugin - // requires "some/path/nls/ab/someBundle" and "some/path/nls/ab-cd-ef/someBundle" - // - // 5. Upon receiving all required bundles, the plugin constructs the value of the bundle - // ab-cd-ef as... - // - // mixin(mixin(mixin({}, require("some/path/nls/someBundle"), - // require("some/path/nls/ab/someBundle")), - // require("some/path/nls/ab-cd-ef/someBundle")); - // - // This value is inserted into the cache and published to the loader at the - // key/module-id some/path/nls/someBundle/ab-cd-ef. - // - // The special preload signature (case 3) instructs the plugin to stop servicing all normal requests - // (further preload requests will be serviced) until all ongoing preloading has completed. - // - // The preload signature instructs the plugin that a special rollup module is available that contains - // one or more flattened, localized bundles. The JSON array of available locales indicates which locales - // are available. Here is an example: - // - // *preload*some/path/nls/someModule*["root", "ab", "ab-cd-ef"] - // - // This indicates the following rollup modules are available: - // - // some/path/nls/someModule_ROOT - // some/path/nls/someModule_ab - // some/path/nls/someModule_ab-cd-ef - // - // Each of these modules is a normal AMD module that contains one or more flattened bundles in a hash. - // For example, assume someModule contained the bundles some/bundle/path/someBundle and - // some/bundle/path/someOtherBundle, then some/path/nls/someModule_ab would be expressed as follows: - // - // define({ - // some/bundle/path/someBundle:<value of someBundle, flattened with respect to locale ab>, - // some/bundle/path/someOtherBundle:<value of someOtherBundle, flattened with respect to locale ab>, - // }); - // - // E.g., given this design, preloading for locale=="ab" can execute the following algorithm: - // - // require(["some/path/nls/someModule_ab"], function(rollup){ - // for(var p in rollup){ - // var id = p + "/ab", - // cache[id] = rollup[p]; - // define(id, rollup[p]); - // } - // }); - // - // Similarly, if "ab-cd" is requested, the algorithm can determine that "ab" is the best available and - // load accordingly. - // - // The builder will write such rollups for every layer if a non-empty localeList profile property is - // provided. Further, the builder will include the following cache entry in the cache associated with - // any layer. - // - // "*now":function(r){r(['dojo/i18n!*preload*<path>/nls/<module>*<JSON array of available locales>']);} - // - // The *now special cache module instructs the loader to apply the provided function to context-require - // with respect to the particular layer being defined. This causes the plugin to hold all normal service - // requests until all preloading is complete. - // - // Notice that this algorithm is rarely better than the standard AMD load algorithm. Consider the normal case - // where the target locale has a single segment and a layer depends on a single bundle: - // - // Without Preloads: - // - // 1. Layer loads root bundle. - // 2. bundle is demanded; plugin loads single localized bundle. - // - // With Preloads: - // - // 1. Layer causes preloading of target bundle. - // 2. bundle is demanded; service is delayed until preloading complete; bundle is returned. - // - // In each case a single transaction is required to load the target bundle. In cases where multiple bundles - // are required and/or the locale has multiple segments, preloads still requires a single transaction whereas - // the normal path requires an additional transaction for each additional bundle/locale-segment. However all - // of these additional transactions can be done concurrently. Owing to this analysis, the entire preloading - // algorithm can be discard during a build by setting the has feature dojo-preload-i18n-Api to false. - - if(has("dojo-preload-i18n-Api")){ - var split = id.split("*"), - preloadDemand = split[1] == "preload"; - if(preloadDemand){ - if(!cache[id]){ - // use cache[id] to prevent multiple preloads of the same preload; this shouldn't happen, but - // who knows what over-aggressive human optimizers may attempt - cache[id] = 1; - preloadL10n(split[2], json.parse(split[3]), 1, require); - } - // don't stall the loader! - load(1); - } - if(preloadDemand || waitForPreloads(id, require, load)){ - return; - } - } - - var match = nlsRe.exec(id), - bundlePath = match[1] + "/", - bundleName = match[5] || match[4], - bundlePathAndName = bundlePath + bundleName, - localeSpecified = (match[5] && match[4]), - targetLocale = localeSpecified || dojo.locale || "", - loadTarget = bundlePathAndName + "/" + targetLocale, - loadList = localeSpecified ? [targetLocale] : getLocalesToLoad(targetLocale), - remaining = loadList.length, - finish = function(){ - if(!--remaining){ - load(lang.delegate(cache[loadTarget])); - } - }; - array.forEach(loadList, function(locale){ - var target = bundlePathAndName + "/" + locale; - if(has("dojo-preload-i18n-Api")){ - checkForLegacyModules(target); - } - if(!cache[target]){ - doLoad(require, bundlePathAndName, bundlePath, bundleName, locale, finish); - }else{ - finish(); - } - }); - }; - - if(has("dojo-unit-tests")){ - var unitTests = thisModule.unitTests = []; - } - - if(has("dojo-preload-i18n-Api") || 1 ){ - var normalizeLocale = thisModule.normalizeLocale = function(locale){ - var result = locale ? locale.toLowerCase() : dojo.locale; - return result == "root" ? "ROOT" : result; - }, - - isXd = function(mid, contextRequire){ - return ( 1 && 1 ) ? - contextRequire.isXdUrl(require.toUrl(mid + ".js")) : - true; - }, - - preloading = 0, - - preloadWaitQueue = [], - - preloadL10n = thisModule._preloadLocalizations = function(/*String*/bundlePrefix, /*Array*/localesGenerated, /*boolean?*/ guaranteedAmdFormat, /*function?*/ contextRequire){ - // summary: - // Load available flattened resource bundles associated with a particular module for dojo/locale and all dojo/config.extraLocale (if any) - // description: - // Only called by built layer files. The entire locale hierarchy is loaded. For example, - // if locale=="ab-cd", then ROOT, "ab", and "ab-cd" are loaded. This is different than v1.6- - // in that the v1.6- would only load ab-cd...which was *always* flattened. - // - // If guaranteedAmdFormat is true, then the module can be loaded with require thereby circumventing the detection algorithm - // and the extra possible extra transaction. - - // If this function is called from legacy code, then guaranteedAmdFormat and contextRequire will be undefined. Since the function - // needs a require in order to resolve module ids, fall back to the context-require associated with this dojo/i18n module, which - // itself may have been mapped. - contextRequire = contextRequire || require; - - function doRequire(mid, callback){ - if(isXd(mid, contextRequire) || guaranteedAmdFormat){ - contextRequire([mid], callback); - }else{ - syncRequire([mid], callback, contextRequire); - } - } - - function forEachLocale(locale, func){ - // given locale= "ab-cd-ef", calls func on "ab-cd-ef", "ab-cd", "ab", "ROOT"; stops calling the first time func returns truthy - var parts = locale.split("-"); - while(parts.length){ - if(func(parts.join("-"))){ - return; - } - parts.pop(); - } - func("ROOT"); - } - - function preloadingAddLock(){ - preloading++; - } - - function preloadingRelLock(){ - --preloading; - while(!preloading && preloadWaitQueue.length){ - load.apply(null, preloadWaitQueue.shift()); - } - } - - function cacheId(path, name, loc, require){ - // path is assumed to have a trailing "/" - return require.toAbsMid(path + name + "/" + loc) - } - - function preload(locale){ - locale = normalizeLocale(locale); - forEachLocale(locale, function(loc){ - if(array.indexOf(localesGenerated, loc) >= 0){ - var mid = bundlePrefix.replace(/\./g, "/") + "_" + loc; - preloadingAddLock(); - doRequire(mid, function(rollup){ - for(var p in rollup){ - var bundle = rollup[p], - match = p.match(/(.+)\/([^\/]+)$/), - bundleName, bundlePath; - - // If there is no match, the bundle is not a regular bundle from an AMD layer. - if (!match){continue;} - - bundleName = match[2]; - bundlePath = match[1] + "/"; - - // backcompat - bundle._localized = bundle._localized || {}; - - var localized; - if(loc === "ROOT"){ - var root = localized = bundle._localized; - delete bundle._localized; - root.root = bundle; - cache[require.toAbsMid(p)] = root; - }else{ - localized = bundle._localized; - cache[cacheId(bundlePath, bundleName, loc, require)] = bundle; - } - - if(loc !== locale){ - // capture some locale variables - function improveBundle(bundlePath, bundleName, bundle, localized){ - // locale was not flattened and we've fallen back to a less-specific locale that was flattened - // for example, we had a flattened 'fr', a 'fr-ca' is available for at least this bundle, and - // locale==='fr-ca'; therefore, we must improve the bundle as retrieved from the rollup by - // manually loading the fr-ca version of the bundle and mixing this into the already-retrieved 'fr' - // version of the bundle. - // - // Remember, different bundles may have different sets of locales available. - // - // we are really falling back on the regular algorithm here, but--hopefully--starting with most - // of the required bundles already on board as given by the rollup and we need to "manually" load - // only one locale from a few bundles...or even better...we won't find anything better to load. - // This algorithm ensures there is nothing better to load even when we can only load a less-specific rollup. - // - // note: this feature is only available in async mode - - // inspect the loaded bundle that came from the rollup to see if something better is available - // for any bundle in a rollup, more-specific available locales are given at localized. - var requiredBundles = [], - cacheIds = []; - forEachLocale(locale, function(loc){ - if(localized[loc]){ - requiredBundles.push(require.toAbsMid(bundlePath + loc + "/" + bundleName)); - cacheIds.push(cacheId(bundlePath, bundleName, loc, require)); - } - }); - - if(requiredBundles.length){ - preloadingAddLock(); - contextRequire(requiredBundles, function(){ - for(var i = 0; i < requiredBundles.length; i++){ - bundle = lang.mixin(lang.clone(bundle), arguments[i]); - cache[cacheIds[i]] = bundle; - } - // this is the best possible (maybe a perfect match, maybe not), accept it - cache[cacheId(bundlePath, bundleName, locale, require)] = lang.clone(bundle); - preloadingRelLock(); - }); - }else{ - // this is the best possible (definitely not a perfect match), accept it - cache[cacheId(bundlePath, bundleName, locale, require)] = bundle; - } - } - improveBundle(bundlePath, bundleName, bundle, localized); - } - } - preloadingRelLock(); - }); - return true; - } - return false; - }); - } - - preload(); - array.forEach(dojo.config.extraLocale, preload); - }, - - waitForPreloads = function(id, require, load){ - if(preloading){ - preloadWaitQueue.push([id, require, load]); - } - return preloading; - }, - - checkForLegacyModules = function() - {}; - } - - if( 1 ){ - // this code path assumes the dojo loader and won't work with a standard AMD loader - var amdValue = {}, - evalBundle = - // use the function ctor to keep the minifiers away (also come close to global scope, but this is secondary) - new Function( - "__bundle", // the bundle to evalutate - "__checkForLegacyModules", // a function that checks if __bundle defined __mid in the global space - "__mid", // the mid that __bundle is intended to define - "__amdValue", - - // returns one of: - // 1 => the bundle was an AMD bundle - // a legacy bundle object that is the value of __mid - // instance of Error => could not figure out how to evaluate bundle - - // used to detect when __bundle calls define - "var define = function(mid, factory){define.called = 1; __amdValue.result = factory || mid;}," - + " require = function(){define.called = 1;};" - - + "try{" - + "define.called = 0;" - + "eval(__bundle);" - + "if(define.called==1)" - // bundle called define; therefore signal it's an AMD bundle - + "return __amdValue;" - - + "if((__checkForLegacyModules = __checkForLegacyModules(__mid)))" - // bundle was probably a v1.6- built NLS flattened NLS bundle that defined __mid in the global space - + "return __checkForLegacyModules;" - - + "}catch(e){}" - // evaulating the bundle was *neither* an AMD *nor* a legacy flattened bundle - // either way, re-eval *after* surrounding with parentheses - - + "try{" - + "return eval('('+__bundle+')');" - + "}catch(e){" - + "return e;" - + "}" - ), - - syncRequire = function(deps, callback, require){ - var results = []; - array.forEach(deps, function(mid){ - var url = require.toUrl(mid + ".js"); - - function load(text){ - var result = evalBundle(text, checkForLegacyModules, mid, amdValue); - if(result===amdValue){ - // the bundle was an AMD module; re-inject it through the normal AMD path - // we gotta do this since it could be an anonymous module and simply evaluating - // the text here won't provide the loader with the context to know what - // module is being defined()'d. With browser caching, this should be free; further - // this entire code path can be circumvented by using the AMD format to begin with - results.push(cache[url] = amdValue.result); - }else{ - if(result instanceof Error){ - console.error("failed to evaluate i18n bundle; url=" + url, result); - result = {}; - } - // nls/<locale>/<bundle-name> indicates not the root. - results.push(cache[url] = (/nls\/[^\/]+\/[^\/]+$/.test(url) ? result : {root:result, _v1x:1})); - } - } - - if(cache[url]){ - results.push(cache[url]); - }else{ - var bundle = require.syncLoadNls(mid); - // don't need to check for legacy since syncLoadNls returns a module if the module - // (1) was already loaded, or (2) was in the cache. In case 1, if syncRequire is called - // from getLocalization --> load, then load will have called checkForLegacyModules() before - // calling syncRequire; if syncRequire is called from preloadLocalizations, then we - // don't care about checkForLegacyModules() because that will be done when a particular - // bundle is actually demanded. In case 2, checkForLegacyModules() is never relevant - // because cached modules are always v1.7+ built modules. - if(bundle){ - results.push(bundle); - }else{ - if(!xhr){ - try{ - require.getText(url, true, load); - }catch(e){ - results.push(cache[url] = {}); - } - }else{ - xhr.get({ - url:url, - sync:true, - load:load, - error:function(){ - results.push(cache[url] = {}); - } - }); - } - } - } - }); - callback && callback.apply(null, results); - }; - - checkForLegacyModules = function(target){ - // legacy code may have already loaded [e.g] the raw bundle x/y/z at x.y.z; when true, push into the cache - for(var result, names = target.split("/"), object = dojo.global[names[0]], i = 1; object && i<names.length-1; object = object[names[i++]]){} - if(object){ - result = object[names[i]]; - if(!result){ - // fallback for incorrect bundle build of 1.6 - result = object[names[i].replace(/-/g,"_")]; - } - if(result){ - cache[target] = result; - } - } - return result; - }; - - thisModule.getLocalization = function(moduleName, bundleName, locale){ - var result, - l10nName = getBundleName(moduleName, bundleName, locale); - load( - l10nName, - - // isXd() and syncRequire() need a context-require in order to resolve the mid with respect to a reference module. - // Since this legacy function does not have the concept of a reference module, resolve with respect to this - // dojo/i18n module, which, itself may have been mapped. - (!isXd(l10nName, require) ? function(deps, callback){ syncRequire(deps, callback, require); } : require), - - function(result_){ result = result_; } - ); - return result; - }; - - if(has("dojo-unit-tests")){ - unitTests.push(function(doh){ - doh.register("tests.i18n.unit", function(t){ - var check; - - check = evalBundle("{prop:1}", checkForLegacyModules, "nonsense", amdValue); - t.is({prop:1}, check); t.is(undefined, check[1]); - - check = evalBundle("({prop:1})", checkForLegacyModules, "nonsense", amdValue); - t.is({prop:1}, check); t.is(undefined, check[1]); - - check = evalBundle("{'prop-x':1}", checkForLegacyModules, "nonsense", amdValue); - t.is({'prop-x':1}, check); t.is(undefined, check[1]); - - check = evalBundle("({'prop-x':1})", checkForLegacyModules, "nonsense", amdValue); - t.is({'prop-x':1}, check); t.is(undefined, check[1]); - - check = evalBundle("define({'prop-x':1})", checkForLegacyModules, "nonsense", amdValue); - t.is(amdValue, check); t.is({'prop-x':1}, amdValue.result); - - check = evalBundle("define('some/module', {'prop-x':1})", checkForLegacyModules, "nonsense", amdValue); - t.is(amdValue, check); t.is({'prop-x':1}, amdValue.result); - - check = evalBundle("this is total nonsense and should throw an error", checkForLegacyModules, "nonsense", amdValue); - t.is(check instanceof Error, true); - }); - }); - } - } - - return lang.mixin(thisModule, { - dynamic:true, - normalize:normalize, - load:load, - cache:cache, - getL10nName: getL10nName - }); -}); diff --git a/lib/dojo/io-query.js b/lib/dojo/io-query.js deleted file mode 100644 index 02f7482..0000000 --- a/lib/dojo/io-query.js +++ /dev/null @@ -1,51 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/io-query",["./_base/lang"],function(_1){ -var _2={}; -return {objectToQuery:function objectToQuery(_3){ -var _4=encodeURIComponent,_5=[]; -for(var _6 in _3){ -var _7=_3[_6]; -if(_7!=_2[_6]){ -var _8=_4(_6)+"="; -if(_1.isArray(_7)){ -for(var i=0,l=_7.length;i<l;++i){ -_5.push(_8+_4(_7[i])); -} -}else{ -_5.push(_8+_4(_7)); -} -} -} -return _5.join("&"); -},queryToObject:function queryToObject(_9){ -var _a=decodeURIComponent,qp=_9.split("&"),_b={},_c,_d; -for(var i=0,l=qp.length,_e;i<l;++i){ -_e=qp[i]; -if(_e.length){ -var s=_e.indexOf("="); -if(s<0){ -_c=_a(_e); -_d=""; -}else{ -_c=_a(_e.slice(0,s)); -_d=_a(_e.slice(s+1)); -} -if(typeof _b[_c]=="string"){ -_b[_c]=[_b[_c]]; -} -if(_1.isArray(_b[_c])){ -_b[_c].push(_d); -}else{ -_b[_c]=_d; -} -} -} -return _b; -}}; -}); diff --git a/lib/dojo/io-query.js.uncompressed.js b/lib/dojo/io-query.js.uncompressed.js deleted file mode 100644 index 1e9de93..0000000 --- a/lib/dojo/io-query.js.uncompressed.js +++ /dev/null @@ -1,97 +0,0 @@ -define("dojo/io-query", ["./_base/lang"], function(lang){ - -// module: -// dojo/io-query - -var backstop = {}; - -return { -// summary: -// This module defines query string processing functions. - - objectToQuery: function objectToQuery(/*Object*/ map){ - // summary: - // takes a name/value mapping object and returns a string representing - // a URL-encoded version of that object. - // example: - // this object: - // - // | { - // | blah: "blah", - // | multi: [ - // | "thud", - // | "thonk" - // | ] - // | }; - // - // yields the following query string: - // - // | "blah=blah&multi=thud&multi=thonk" - - // FIXME: need to implement encodeAscii!! - var enc = encodeURIComponent, pairs = []; - for(var name in map){ - var value = map[name]; - if(value != backstop[name]){ - var assign = enc(name) + "="; - if(lang.isArray(value)){ - for(var i = 0, l = value.length; i < l; ++i){ - pairs.push(assign + enc(value[i])); - } - }else{ - pairs.push(assign + enc(value)); - } - } - } - return pairs.join("&"); // String - }, - - queryToObject: function queryToObject(/*String*/ str){ - // summary: - // Create an object representing a de-serialized query section of a - // URL. Query keys with multiple values are returned in an array. - // - // example: - // This string: - // - // | "foo=bar&foo=baz&thinger=%20spaces%20=blah&zonk=blarg&" - // - // results in this object structure: - // - // | { - // | foo: [ "bar", "baz" ], - // | thinger: " spaces =blah", - // | zonk: "blarg" - // | } - // - // Note that spaces and other urlencoded entities are correctly - // handled. - - // FIXME: should we grab the URL string if we're not passed one? - var dec = decodeURIComponent, qp = str.split("&"), ret = {}, name, val; - for(var i = 0, l = qp.length, item; i < l; ++i){ - item = qp[i]; - if(item.length){ - var s = item.indexOf("="); - if(s < 0){ - name = dec(item); - val = ""; - }else{ - name = dec(item.slice(0, s)); - val = dec(item.slice(s + 1)); - } - if(typeof ret[name] == "string"){ // inline'd type check - ret[name] = [ret[name]]; - } - - if(lang.isArray(ret[name])){ - ret[name].push(val); - }else{ - ret[name] = val; - } - } - } - return ret; // Object - } -}; -}); \ No newline at end of file diff --git a/lib/dojo/io/iframe.js b/lib/dojo/io/iframe.js deleted file mode 100644 index 3f0aafc..0000000 --- a/lib/dojo/io/iframe.js +++ /dev/null @@ -1,72 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/io/iframe",["../_base/config","../_base/json","../_base/kernel","../_base/lang","../_base/xhr","../sniff","../_base/window","../dom","../dom-construct","../query","require","../aspect","../request/iframe"],function(_1,_2,_3,_4,_5,_6,_7,_8,_9,_a,_b,_c,_d){ -_3.deprecated("dojo/io/iframe","Use dojo/request/iframe.","2.0"); -var _e=_d._iframeName; -_e=_e.substring(0,_e.lastIndexOf("_")); -var _f=_4.delegate(_d,{create:function(){ -return _f._frame=_d.create.apply(_d,arguments); -},get:null,post:null,send:function(_10){ -var _11; -var dfd=_5._ioSetArgs(_10,function(dfd){ -_11&&_11.cancel(); -},function(dfd){ -var _12=null,_13=dfd.ioArgs; -try{ -var _14=_13.handleAs; -if(_14==="xml"||_14==="html"){ -_12=_11.response.data; -}else{ -_12=_11.response.text; -if(_14==="json"){ -_12=_2.fromJson(_12); -}else{ -if(_14==="javascript"){ -_12=_3.eval(_12); -} -} -} -} -catch(e){ -_12=e; -} -return _12; -},function(_15,dfd){ -dfd.ioArgs._hasError=true; -return _15; -}); -var _16=dfd.ioArgs; -var _17="GET",_18=_8.byId(_10.form); -if(_10.method&&_10.method.toUpperCase()==="POST"&&_18){ -_17="POST"; -} -var _19={method:_17,handleAs:_10.handleAs==="json"||_10.handleAs==="javascript"?"text":_10.handleAs,form:_10.form,query:_18?null:_10.content,data:_18?_10.content:null,timeout:_10.timeout,ioArgs:_16}; -if(_19.method){ -_19.method=_19.method.toUpperCase(); -} -if(_1.ioPublish&&_3.publish&&_16.args.ioPublish!==false){ -var _1a=_c.after(_d,"_notifyStart",function(_1b){ -if(_1b.options.ioArgs===_16){ -_1a.remove(); -_5._ioNotifyStart(dfd); -} -},true); -} -_11=_d(_16.url,_19,true); -_16._callNext=_11._callNext; -_11.then(function(){ -dfd.resolve(dfd); -}).otherwise(function(_1c){ -dfd.ioArgs.error=_1c; -dfd.reject(_1c); -}); -return dfd; -},_iframeOnload:_7.global[_e+"_onload"]}); -_4.setObject("dojo.io.iframe",_f); -return _f; -}); diff --git a/lib/dojo/io/iframe.js.uncompressed.js b/lib/dojo/io/iframe.js.uncompressed.js deleted file mode 100644 index 3ce93e0..0000000 --- a/lib/dojo/io/iframe.js.uncompressed.js +++ /dev/null @@ -1,190 +0,0 @@ -define("dojo/io/iframe", [ - "../_base/config", "../_base/json", "../_base/kernel", /*===== "../_base/declare", =====*/ "../_base/lang", - "../_base/xhr", "../sniff", "../_base/window", - "../dom", "../dom-construct", "../query", "require", "../aspect", "../request/iframe" -], function(config, json, kernel, /*===== declare, =====*/ lang, xhr, has, win, dom, domConstruct, query, require, aspect, _iframe){ - -// module: -// dojo/io/iframe - -kernel.deprecated("dojo/io/iframe", "Use dojo/request/iframe.", "2.0"); - -/*===== -var __ioArgs = declare(kernel.__IoArgs, { - // method: String? - // The HTTP method to use. "GET" or "POST" are the only supported - // values. It will try to read the value from the form node's - // method, then try this argument. If neither one exists, then it - // defaults to POST. - // handleAs: String? - // Specifies what format the result data should be given to the - // load/handle callback. Valid values are: text, html, xml, json, - // javascript. IMPORTANT: For all values EXCEPT html and xml, The - // server response should be an HTML file with a textarea element. - // The response data should be inside the textarea element. Using an - // HTML document the only reliable, cross-browser way this - // transport can know when the response has loaded. For the html - // handleAs value, just return a normal HTML document. NOTE: xml - // is now supported with this transport (as of 1.1+); a known issue - // is if the XML document in question is malformed, Internet Explorer - // will throw an uncatchable error. - // content: Object? - // If "form" is one of the other args properties, then the content - // object properties become hidden form form elements. For - // instance, a content object of {name1 : "value1"} is converted - // to a hidden form element with a name of "name1" and a value of - // "value1". If there is not a "form" property, then the content - // object is converted into a name=value&name=value string, by - // using xhr.objectToQuery(). -}); -=====*/ - -/*===== -return kernel.io.iframe = { - // summary: - // Deprecated, use dojo/request/iframe instead. - // Sends an Ajax I/O call using and Iframe (for instance, to upload files) - - create: function(fname, onloadstr, uri){ - // summary: - // Creates a hidden iframe in the page. Used mostly for IO - // transports. You do not need to call this to start a - // dojo/io/iframe request. Just call send(). - // fname: String - // The name of the iframe. Used for the name attribute on the - // iframe. - // onloadstr: String - // A string of JavaScript that will be executed when the content - // in the iframe loads. - // uri: String - // The value of the src attribute on the iframe element. If a - // value is not given, then dojo/resources/blank.html will be - // used. - }, - setSrc: function(iframe, src, replace){ - // summary: - // Sets the URL that is loaded in an IFrame. The replace parameter - // indicates whether location.replace() should be used when - // changing the location of the iframe. - }, - doc: function(iframeNode){ - // summary: - // Returns the document object associated with the iframe DOM Node argument. - } -}; -=====*/ - - -var mid = _iframe._iframeName; -mid = mid.substring(0, mid.lastIndexOf('_')); - -var iframe = lang.delegate(_iframe, { - // summary: - // Deprecated, use dojo/request/iframe instead. - // Sends an Ajax I/O call using and Iframe (for instance, to upload files) - - create: function(){ - return iframe._frame = _iframe.create.apply(_iframe, arguments); - }, - - // cover up delegated methods - get: null, - post: null, - - send: function(/*__ioArgs*/args){ - // summary: - // Function that sends the request to the server. - // This transport can only process one send() request at a time, so if send() is called - // multiple times, it will queue up the calls and only process one at a time. - var rDfd; - - //Set up the deferred. - var dfd = xhr._ioSetArgs(args, - function(/*Deferred*/dfd){ - // summary: - // canceller function for xhr._ioSetArgs call. - rDfd && rDfd.cancel(); - }, - function(/*Deferred*/dfd){ - // summary: - // okHandler function for xhr._ioSetArgs call. - var value = null, - ioArgs = dfd.ioArgs; - try{ - var handleAs = ioArgs.handleAs; - - //Assign correct value based on handleAs value. - if(handleAs === "xml" || handleAs === "html"){ - value = rDfd.response.data; - }else{ - value = rDfd.response.text; - if(handleAs === "json"){ - value = json.fromJson(value); - }else if(handleAs === "javascript"){ - value = kernel.eval(value); - } - } - }catch(e){ - value = e; - } - return value; - }, - function(/*Error*/error, /*Deferred*/dfd){ - // summary: - // errHandler function for xhr._ioSetArgs call. - dfd.ioArgs._hasError = true; - return error; - } - ); - - var ioArgs = dfd.ioArgs; - - var method = "GET", - form = dom.byId(args.form); - if(args.method && args.method.toUpperCase() === "POST" && form){ - method = "POST"; - } - - var options = { - method: method, - handleAs: args.handleAs === "json" || args.handleAs === "javascript" ? "text" : args.handleAs, - form: args.form, - query: form ? null : args.content, - data: form ? args.content : null, - timeout: args.timeout, - ioArgs: ioArgs - }; - - if(options.method){ - options.method = options.method.toUpperCase(); - } - - if(config.ioPublish && kernel.publish && ioArgs.args.ioPublish !== false){ - var start = aspect.after(_iframe, "_notifyStart", function(data){ - if(data.options.ioArgs === ioArgs){ - start.remove(); - xhr._ioNotifyStart(dfd); - } - }, true); - } - rDfd = _iframe(ioArgs.url, options, true); - - ioArgs._callNext = rDfd._callNext; - - rDfd.then(function(){ - dfd.resolve(dfd); - }).otherwise(function(error){ - dfd.ioArgs.error = error; - dfd.reject(error); - }); - - return dfd; - }, - - _iframeOnload: win.global[mid + '_onload'] -}); - -lang.setObject("dojo.io.iframe", iframe); - -return iframe; -}); diff --git a/lib/dojo/io/script.js b/lib/dojo/io/script.js deleted file mode 100644 index 7ee30c1..0000000 --- a/lib/dojo/io/script.js +++ /dev/null @@ -1,113 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/io/script",["../_base/connect","../_base/kernel","../_base/lang","../sniff","../_base/window","../_base/xhr","../dom","../dom-construct","../request/script","../aspect"],function(_1,_2,_3,_4,_5,_6,_7,_8,_9,_a){ -_2.deprecated("dojo/io/script","Use dojo/request/script.","2.0"); -var _b={get:function(_c){ -var _d; -var _e=this._makeScriptDeferred(_c,function(_f){ -_d&&_d.cancel(); -}); -var _10=_e.ioArgs; -_6._ioAddQueryToUrl(_10); -_6._ioNotifyStart(_e); -_d=_9.get(_10.url,{timeout:_c.timeout,jsonp:_10.jsonp,checkString:_c.checkString,ioArgs:_10,frameDoc:_c.frameDoc,canAttach:function(_11){ -_10.requestId=_11.id; -_10.scriptId=_11.scriptId; -_10.canDelete=_11.canDelete; -return _b._canAttach(_10); -}},true); -_a.around(_d,"isValid",function(_12){ -return function(_13){ -_b._validCheck(_e); -return _12.call(this,_13); -}; -}); -_d.then(function(){ -_e.resolve(_e); -}).otherwise(function(_14){ -_e.ioArgs.error=_14; -_e.reject(_14); -}); -return _e; -},attach:_9._attach,remove:_9._remove,_makeScriptDeferred:function(_15,_16){ -var dfd=_6._ioSetArgs(_15,_16||this._deferredCancel,this._deferredOk,this._deferredError); -var _17=dfd.ioArgs; -_17.id=_2._scopeName+"IoScript"+(this._counter++); -_17.canDelete=false; -_17.jsonp=_15.callbackParamName||_15.jsonp; -if(_17.jsonp){ -_17.query=_17.query||""; -if(_17.query.length>0){ -_17.query+="&"; -} -_17.query+=_17.jsonp+"="+(_15.frameDoc?"parent.":"")+_2._scopeName+".io.script.jsonp_"+_17.id+"._jsonpCallback"; -_17.frameDoc=_15.frameDoc; -_17.canDelete=true; -dfd._jsonpCallback=this._jsonpCallback; -this["jsonp_"+_17.id]=dfd; -} -dfd.addBoth(function(_18){ -if(_17.canDelete){ -if(_18 instanceof Error){ -_b["jsonp_"+_17.id]._jsonpCallback=function(){ -delete _b["jsonp_"+_17.id]; -if(_17.requestId){ -_2.global[_9._callbacksProperty][_17.requestId](); -} -}; -}else{ -_b._addDeadScript(_17); -} -} -}); -return dfd; -},_deferredCancel:function(dfd){ -dfd.canceled=true; -},_deferredOk:function(dfd){ -var _19=dfd.ioArgs; -return _19.json||_19.scriptLoaded||_19; -},_deferredError:function(_1a,dfd){ -return _1a; -},_deadScripts:[],_counter:1,_addDeadScript:function(_1b){ -_b._deadScripts.push({id:_1b.id,frameDoc:_1b.frameDoc}); -_1b.frameDoc=null; -},_validCheck:function(dfd){ -var _1c=_b._deadScripts; -if(_1c&&_1c.length>0){ -for(var i=0;i<_1c.length;i++){ -_b.remove(_1c[i].id,_1c[i].frameDoc); -delete _b["jsonp_"+_1c[i].id]; -_1c[i].frameDoc=null; -} -_b._deadScripts=[]; -} -return true; -},_ioCheck:function(dfd){ -var _1d=dfd.ioArgs; -if(_1d.json||(_1d.scriptLoaded&&!_1d.args.checkString)){ -return true; -} -var _1e=_1d.args.checkString; -return _1e&&eval("typeof("+_1e+") != 'undefined'"); -},_resHandle:function(dfd){ -if(_b._ioCheck(dfd)){ -dfd.callback(dfd); -}else{ -dfd.errback(new Error("inconceivable dojo.io.script._resHandle error")); -} -},_canAttach:function(){ -return true; -},_jsonpCallback:function(_1f){ -this.ioArgs.json=_1f; -if(this.ioArgs.requestId){ -_2.global[_9._callbacksProperty][this.ioArgs.requestId](_1f); -} -}}; -_3.setObject("dojo.io.script",_b); -return _b; -}); diff --git a/lib/dojo/io/script.js.uncompressed.js b/lib/dojo/io/script.js.uncompressed.js deleted file mode 100644 index bc302ca..0000000 --- a/lib/dojo/io/script.js.uncompressed.js +++ /dev/null @@ -1,280 +0,0 @@ -define("dojo/io/script", [ - "../_base/connect", /*===== "../_base/declare", =====*/ "../_base/kernel", "../_base/lang", - "../sniff", "../_base/window","../_base/xhr", - "../dom", "../dom-construct", "../request/script", "../aspect" -], function(connect, /*===== declare, =====*/ kernel, lang, has, win, xhr, dom, domConstruct, _script, aspect){ - - // module: - // dojo/io/script - - kernel.deprecated("dojo/io/script", "Use dojo/request/script.", "2.0"); - - /*===== - var __ioArgs = declare(kernel.__IoArgs, { - // summary: - // All the properties described in the dojo.__ioArgs type, apply to this - // type as well, EXCEPT "handleAs". It is not applicable to - // dojo/io/script.get() calls, since it is implied by the usage of - // "jsonp" (response will be a JSONP call returning JSON) - // or the response is pure JavaScript defined in - // the body of the script that was attached. - // callbackParamName: String - // Deprecated as of Dojo 1.4 in favor of "jsonp", but still supported for - // legacy code. See notes for jsonp property. - // jsonp: String - // The URL parameter name that indicates the JSONP callback string. - // For instance, when using Yahoo JSONP calls it is normally, - // jsonp: "callback". For AOL JSONP calls it is normally - // jsonp: "c". - // checkString: String - // A string of JavaScript that when evaluated like so: - // "typeof(" + checkString + ") != 'undefined'" - // being true means that the script fetched has been loaded. - // Do not use this if doing a JSONP type of call (use callbackParamName instead). - // frameDoc: Document - // The Document object for a child iframe. If this is passed in, the script - // will be attached to that document. This can be helpful in some comet long-polling - // scenarios with Firefox and Opera. - }); - =====*/ - - var script = { - // summary: - // TODOC - - get: function(/*__ioArgs*/ args){ - // summary: - // sends a get request using a dynamically created script tag. - var rDfd; - var dfd = this._makeScriptDeferred(args, function(dfd){ - rDfd && rDfd.cancel(); - }); - var ioArgs = dfd.ioArgs; - xhr._ioAddQueryToUrl(ioArgs); - - xhr._ioNotifyStart(dfd); - - rDfd = _script.get(ioArgs.url, { - timeout: args.timeout, - jsonp: ioArgs.jsonp, - checkString: args.checkString, - ioArgs: ioArgs, - frameDoc: args.frameDoc, - canAttach: function(rDfd){ - // sync values - ioArgs.requestId = rDfd.id; - ioArgs.scriptId = rDfd.scriptId; - ioArgs.canDelete = rDfd.canDelete; - - return script._canAttach(ioArgs); - } - }, true); - - // Run _validCheck at the same time dojo/request/watch runs the - // rDfd.isValid function - aspect.around(rDfd, "isValid", function(isValid){ - return function(response){ - script._validCheck(dfd); - return isValid.call(this, response); - }; - }); - - rDfd.then(function(){ - dfd.resolve(dfd); - }).otherwise(function(error){ - dfd.ioArgs.error = error; - dfd.reject(error); - }); - - return dfd; - }, - - attach: _script._attach, - remove: _script._remove, - - _makeScriptDeferred: function(/*Object*/ args, /*Function?*/ cancel){ - // summary: - // sets up a Deferred object for an IO request. - var dfd = xhr._ioSetArgs(args, cancel || this._deferredCancel, this._deferredOk, this._deferredError); - - var ioArgs = dfd.ioArgs; - ioArgs.id = kernel._scopeName + "IoScript" + (this._counter++); - ioArgs.canDelete = false; - - //Special setup for jsonp case - ioArgs.jsonp = args.callbackParamName || args.jsonp; - if(ioArgs.jsonp){ - //Add the jsonp parameter. - ioArgs.query = ioArgs.query || ""; - if(ioArgs.query.length > 0){ - ioArgs.query += "&"; - } - ioArgs.query += ioArgs.jsonp + - "=" + (args.frameDoc ? "parent." : "") + - kernel._scopeName + ".io.script.jsonp_" + ioArgs.id + "._jsonpCallback"; - - ioArgs.frameDoc = args.frameDoc; - - //Setup the Deferred to have the jsonp callback. - ioArgs.canDelete = true; - dfd._jsonpCallback = this._jsonpCallback; - this["jsonp_" + ioArgs.id] = dfd; - } - // Make sure this runs no matter what happens to clean things up if need be - dfd.addBoth(function(value){ - if(ioArgs.canDelete){ - if(value instanceof Error){ - // Set up a callback that will clean things up for timeouts and cancels - script["jsonp_" + ioArgs.id]._jsonpCallback = function(){ - // Delete the cached deferred - delete script["jsonp_" + ioArgs.id]; - if(ioArgs.requestId){ - // Call the dojo/request/script callback to clean itself up as well - kernel.global[_script._callbacksProperty][ioArgs.requestId](); - } - }; - }else{ - script._addDeadScript(ioArgs); - } - } - }); - return dfd; // dojo/_base/Deferred - }, - - _deferredCancel: function(/*Deferred*/ dfd){ - // summary: - // canceller function for xhr._ioSetArgs call. - - //DO NOT use "this" and expect it to be script. - dfd.canceled = true; - }, - - _deferredOk: function(/*Deferred*/ dfd){ - // summary: - // okHandler function for xhr._ioSetArgs call. - - //DO NOT use "this" and expect it to be script. - var ioArgs = dfd.ioArgs; - - //Favor JSONP responses, script load events then lastly ioArgs. - //The ioArgs are goofy, but cannot return the dfd since that stops - //the callback chain in Deferred. The return value is not that important - //in that case, probably a checkString case. - return ioArgs.json || ioArgs.scriptLoaded || ioArgs; - }, - - _deferredError: function(/*Error*/ error, /*Deferred*/ dfd){ - // summary: - // errHandler function for xhr._ioSetArgs call. - - console.log("dojo.io.script error", error); - return error; - }, - - _deadScripts: [], - _counter: 1, - - _addDeadScript: function(/*Object*/ ioArgs){ - // summary: - // sets up an entry in the deadScripts array. - script._deadScripts.push({id: ioArgs.id, frameDoc: ioArgs.frameDoc}); - //Being extra paranoid about leaks: - ioArgs.frameDoc = null; - }, - - _validCheck: function(/*Deferred*/ dfd){ - // summary: - // inflight check function to see if dfd is still valid. - - // TODO: why isn't dfd accessed? - - //Do script cleanup here. We wait for one inflight pass - //to make sure we don't get any weird things by trying to remove a script - //tag that is part of the call chain (IE 6 has been known to - //crash in that case). - var deadScripts = script._deadScripts; - if(deadScripts && deadScripts.length > 0){ - for(var i = 0; i < deadScripts.length; i++){ - //Remove the script tag - script.remove(deadScripts[i].id, deadScripts[i].frameDoc); - //Clean up the deferreds - delete script["jsonp_" + deadScripts[i].id]; - deadScripts[i].frameDoc = null; - } - script._deadScripts = []; - } - - return true; - }, - - _ioCheck: function(dfd){ - // summary: - // inflight check function to see if IO finished. - // dfd: Deferred - var ioArgs = dfd.ioArgs; - //Check for finished jsonp - if(ioArgs.json || (ioArgs.scriptLoaded && !ioArgs.args.checkString)){ - return true; - } - - //Check for finished "checkString" case. - var checkString = ioArgs.args.checkString; - return checkString && eval("typeof(" + checkString + ") != 'undefined'"); - - - }, - - _resHandle: function(/*Deferred*/ dfd){ - // summary: - // inflight function to handle a completed response. - if(script._ioCheck(dfd)){ - dfd.callback(dfd); - }else{ - //This path should never happen since the only way we can get - //to _resHandle is if _ioCheck is true. - dfd.errback(new Error("inconceivable dojo.io.script._resHandle error")); - } - }, - - _canAttach: function(/*===== ioArgs =====*/ ){ - // summary: - // A method that can be overridden by other modules - // to control when the script attachment occurs. - // ioArgs: Object - return true; - }, - - _jsonpCallback: function(/*JSON Object*/ json){ - // summary: - // generic handler for jsonp callback. A pointer to this function - // is used for all jsonp callbacks. NOTE: the "this" in this - // function will be the Deferred object that represents the script - // request. - this.ioArgs.json = json; - if(this.ioArgs.requestId){ - kernel.global[_script._callbacksProperty][this.ioArgs.requestId](json); - } - } - }; - - lang.setObject("dojo.io.script", script); - - /*===== - script.attach = function(id, url, frameDocument){ - // summary: - // creates a new `<script>` tag pointing to the specified URL and - // adds it to the document. - // description: - // Attaches the script element to the DOM. Use this method if you - // just want to attach a script to the DOM and do not care when or - // if it loads. - }; - script.remove = function(id, frameDocument){ - // summary: - // removes the script element with the given id, from the given frameDocument. - // If no frameDocument is passed, the current document is used. - }; - =====*/ - - return script; -}); diff --git a/lib/dojo/json.js b/lib/dojo/json.js deleted file mode 100644 index 3dd4d48..0000000 --- a/lib/dojo/json.js +++ /dev/null @@ -1,104 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/json",["./has"],function(_1){ -"use strict"; -var _2=typeof JSON!="undefined"; -_1.add("json-parse",_2); -_1.add("json-stringify",_2&&JSON.stringify({a:0},function(k,v){ -return v||1; -})=="{\"a\":1}"); -if(_1("json-stringify")){ -return JSON; -}else{ -var _3=function(_4){ -return ("\""+_4.replace(/(["\\])/g,"\\$1")+"\"").replace(/[\f]/g,"\\f").replace(/[\b]/g,"\\b").replace(/[\n]/g,"\\n").replace(/[\t]/g,"\\t").replace(/[\r]/g,"\\r"); -}; -return {parse:_1("json-parse")?JSON.parse:function(_5,_6){ -if(_6&&!/^([\s\[\{]*(?:"(?:\\.|[^"])*"|-?\d[\d\.]*(?:[Ee][+-]?\d+)?|null|true|false|)[\s\]\}]*(?:,|:|$))+$/.test(_5)){ -throw new SyntaxError("Invalid characters in JSON"); -} -return eval("("+_5+")"); -},stringify:function(_7,_8,_9){ -var _a; -if(typeof _8=="string"){ -_9=_8; -_8=null; -} -function _b(it,_c,_d){ -if(_8){ -it=_8(_d,it); -} -var _e,_f=typeof it; -if(_f=="number"){ -return isFinite(it)?it+"":"null"; -} -if(_f=="boolean"){ -return it+""; -} -if(it===null){ -return "null"; -} -if(typeof it=="string"){ -return _3(it); -} -if(_f=="function"||_f=="undefined"){ -return _a; -} -if(typeof it.toJSON=="function"){ -return _b(it.toJSON(_d),_c,_d); -} -if(it instanceof Date){ -return "\"{FullYear}-{Month+}-{Date}T{Hours}:{Minutes}:{Seconds}Z\"".replace(/\{(\w+)(\+)?\}/g,function(t,_10,_11){ -var num=it["getUTC"+_10]()+(_11?1:0); -return num<10?"0"+num:num; -}); -} -if(it.valueOf()!==it){ -return _b(it.valueOf(),_c,_d); -} -var _12=_9?(_c+_9):""; -var sep=_9?" ":""; -var _13=_9?"\n":""; -if(it instanceof Array){ -var itl=it.length,res=[]; -for(_d=0;_d<itl;_d++){ -var obj=it[_d]; -_e=_b(obj,_12,_d); -if(typeof _e!="string"){ -_e="null"; -} -res.push(_13+_12+_e); -} -return "["+res.join(",")+_13+_c+"]"; -} -var _14=[]; -for(_d in it){ -var _15; -if(it.hasOwnProperty(_d)){ -if(typeof _d=="number"){ -_15="\""+_d+"\""; -}else{ -if(typeof _d=="string"){ -_15=_3(_d); -}else{ -continue; -} -} -_e=_b(it[_d],_12,_d); -if(typeof _e!="string"){ -continue; -} -_14.push(_13+_12+_15+":"+sep+_e); -} -} -return "{"+_14.join(",")+_13+_c+"}"; -}; -return _b(_7,"",""); -}}; -} -}); diff --git a/lib/dojo/json.js.uncompressed.js b/lib/dojo/json.js.uncompressed.js deleted file mode 100644 index 86f6a73..0000000 --- a/lib/dojo/json.js.uncompressed.js +++ /dev/null @@ -1,162 +0,0 @@ -define("dojo/json", ["./has"], function(has){ - "use strict"; - var hasJSON = typeof JSON != "undefined"; - has.add("json-parse", hasJSON); // all the parsers work fine - // Firefox 3.5/Gecko 1.9 fails to use replacer in stringify properly https://bugzilla.mozilla.org/show_bug.cgi?id=509184 - has.add("json-stringify", hasJSON && JSON.stringify({a:0}, function(k,v){return v||1;}) == '{"a":1}'); - - /*===== - return { - // summary: - // Functions to parse and serialize JSON - - parse: function(str, strict){ - // summary: - // Parses a [JSON](http://json.org) string to return a JavaScript object. - // description: - // This function follows [native JSON API](https://developer.mozilla.org/en/JSON) - // Throws for invalid JSON strings. This delegates to eval() if native JSON - // support is not available. By default this will evaluate any valid JS expression. - // With the strict parameter set to true, the parser will ensure that only - // valid JSON strings are parsed (otherwise throwing an error). Without the strict - // parameter, the content passed to this method must come - // from a trusted source. - // str: - // a string literal of a JSON item, for instance: - // `'{ "foo": [ "bar", 1, { "baz": "thud" } ] }'` - // strict: - // When set to true, this will ensure that only valid, secure JSON is ever parsed. - // Make sure this is set to true for untrusted content. Note that on browsers/engines - // without native JSON support, setting this to true will run slower. - }, - stringify: function(value, replacer, spacer){ - // summary: - // Returns a [JSON](http://json.org) serialization of an object. - // description: - // Returns a [JSON](http://json.org) serialization of an object. - // This function follows [native JSON API](https://developer.mozilla.org/en/JSON) - // Note that this doesn't check for infinite recursion, so don't do that! - // value: - // A value to be serialized. - // replacer: - // A replacer function that is called for each value and can return a replacement - // spacer: - // A spacer string to be used for pretty printing of JSON - // example: - // simple serialization of a trivial object - // | define(["dojo/json"], function(JSON){ - // | var jsonStr = JSON.stringify({ howdy: "stranger!", isStrange: true }); - // | doh.is('{"howdy":"stranger!","isStrange":true}', jsonStr); - } - }; - =====*/ - - if(has("json-stringify")){ - return JSON; - }else{ - var escapeString = function(/*String*/str){ - // summary: - // Adds escape sequences for non-visual characters, double quote and - // backslash and surrounds with double quotes to form a valid string - // literal. - return ('"' + str.replace(/(["\\])/g, '\\$1') + '"'). - replace(/[\f]/g, "\\f").replace(/[\b]/g, "\\b").replace(/[\n]/g, "\\n"). - replace(/[\t]/g, "\\t").replace(/[\r]/g, "\\r"); // string - }; - return { - parse: has("json-parse") ? JSON.parse : function(str, strict){ - if(strict && !/^([\s\[\{]*(?:"(?:\\.|[^"])*"|-?\d[\d\.]*(?:[Ee][+-]?\d+)?|null|true|false|)[\s\]\}]*(?:,|:|$))+$/.test(str)){ - throw new SyntaxError("Invalid characters in JSON"); - } - return eval('(' + str + ')'); - }, - stringify: function(value, replacer, spacer){ - var undef; - if(typeof replacer == "string"){ - spacer = replacer; - replacer = null; - } - function stringify(it, indent, key){ - if(replacer){ - it = replacer(key, it); - } - var val, objtype = typeof it; - if(objtype == "number"){ - return isFinite(it) ? it + "" : "null"; - } - if(objtype == "boolean"){ - return it + ""; - } - if(it === null){ - return "null"; - } - if(typeof it == "string"){ - return escapeString(it); - } - if(objtype == "function" || objtype == "undefined"){ - return undef; // undefined - } - // short-circuit for objects that support "json" serialization - // if they return "self" then just pass-through... - if(typeof it.toJSON == "function"){ - return stringify(it.toJSON(key), indent, key); - } - if(it instanceof Date){ - return '"{FullYear}-{Month+}-{Date}T{Hours}:{Minutes}:{Seconds}Z"'.replace(/\{(\w+)(\+)?\}/g, function(t, prop, plus){ - var num = it["getUTC" + prop]() + (plus ? 1 : 0); - return num < 10 ? "0" + num : num; - }); - } - if(it.valueOf() !== it){ - // primitive wrapper, try again unwrapped: - return stringify(it.valueOf(), indent, key); - } - var nextIndent= spacer ? (indent + spacer) : ""; - /* we used to test for DOM nodes and throw, but FF serializes them as {}, so cross-browser consistency is probably not efficiently attainable */ - - var sep = spacer ? " " : ""; - var newLine = spacer ? "\n" : ""; - - // array - if(it instanceof Array){ - var itl = it.length, res = []; - for(key = 0; key < itl; key++){ - var obj = it[key]; - val = stringify(obj, nextIndent, key); - if(typeof val != "string"){ - val = "null"; - } - res.push(newLine + nextIndent + val); - } - return "[" + res.join(",") + newLine + indent + "]"; - } - // generic object code path - var output = []; - for(key in it){ - var keyStr; - if(it.hasOwnProperty(key)){ - if(typeof key == "number"){ - keyStr = '"' + key + '"'; - }else if(typeof key == "string"){ - keyStr = escapeString(key); - }else{ - // skip non-string or number keys - continue; - } - val = stringify(it[key], nextIndent, key); - if(typeof val != "string"){ - // skip non-serializable values - continue; - } - // At this point, the most non-IE browsers don't get in this branch - // (they have native JSON), so push is definitely the way to - output.push(newLine + nextIndent + keyStr + ":" + sep + val); - } - } - return "{" + output.join(",") + newLine + indent + "}"; // String - } - return stringify(value, "", ""); - } - }; - } -}); diff --git a/lib/dojo/keys.js b/lib/dojo/keys.js deleted file mode 100644 index 78d53f3..0000000 --- a/lib/dojo/keys.js +++ /dev/null @@ -1,10 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/keys",["./_base/kernel","./sniff"],function(_1,_2){ -return _1.keys={BACKSPACE:8,TAB:9,CLEAR:12,ENTER:13,SHIFT:16,CTRL:17,ALT:18,META:_2("webkit")?91:224,PAUSE:19,CAPS_LOCK:20,ESCAPE:27,SPACE:32,PAGE_UP:33,PAGE_DOWN:34,END:35,HOME:36,LEFT_ARROW:37,UP_ARROW:38,RIGHT_ARROW:39,DOWN_ARROW:40,INSERT:45,DELETE:46,HELP:47,LEFT_WINDOW:91,RIGHT_WINDOW:92,SELECT:93,NUMPAD_0:96,NUMPAD_1:97,NUMPAD_2:98,NUMPAD_3:99,NUMPAD_4:100,NUMPAD_5:101,NUMPAD_6:102,NUMPAD_7:103,NUMPAD_8:104,NUMPAD_9:105,NUMPAD_MULTIPLY:106,NUMPAD_PLUS:107,NUMPAD_ENTER:108,NUMPAD_MINUS:109,NUMPAD_PERIOD:110,NUMPAD_DIVIDE:111,F1:112,F2:113,F3:114,F4:115,F5:116,F6:117,F7:118,F8:119,F9:120,F10:121,F11:122,F12:123,F13:124,F14:125,F15:126,NUM_LOCK:144,SCROLL_LOCK:145,UP_DPAD:175,DOWN_DPAD:176,LEFT_DPAD:177,RIGHT_DPAD:178,copyKey:_2("mac")&&!_2("air")?(_2("safari")?91:224):17}; -}); diff --git a/lib/dojo/keys.js.uncompressed.js b/lib/dojo/keys.js.uncompressed.js deleted file mode 100644 index 65567a2..0000000 --- a/lib/dojo/keys.js.uncompressed.js +++ /dev/null @@ -1,77 +0,0 @@ -define("dojo/keys", ["./_base/kernel", "./sniff"], function(dojo, has){ - - // module: - // dojo/keys - - return dojo.keys = { - // summary: - // Definitions for common key values. Client code should test keyCode against these named constants, - // as the actual codes can vary by browser. - - BACKSPACE: 8, - TAB: 9, - CLEAR: 12, - ENTER: 13, - SHIFT: 16, - CTRL: 17, - ALT: 18, - META: has("webkit") ? 91 : 224, // the apple key on macs - PAUSE: 19, - CAPS_LOCK: 20, - ESCAPE: 27, - SPACE: 32, - PAGE_UP: 33, - PAGE_DOWN: 34, - END: 35, - HOME: 36, - LEFT_ARROW: 37, - UP_ARROW: 38, - RIGHT_ARROW: 39, - DOWN_ARROW: 40, - INSERT: 45, - DELETE: 46, - HELP: 47, - LEFT_WINDOW: 91, - RIGHT_WINDOW: 92, - SELECT: 93, - NUMPAD_0: 96, - NUMPAD_1: 97, - NUMPAD_2: 98, - NUMPAD_3: 99, - NUMPAD_4: 100, - NUMPAD_5: 101, - NUMPAD_6: 102, - NUMPAD_7: 103, - NUMPAD_8: 104, - NUMPAD_9: 105, - NUMPAD_MULTIPLY: 106, - NUMPAD_PLUS: 107, - NUMPAD_ENTER: 108, - NUMPAD_MINUS: 109, - NUMPAD_PERIOD: 110, - NUMPAD_DIVIDE: 111, - F1: 112, - F2: 113, - F3: 114, - F4: 115, - F5: 116, - F6: 117, - F7: 118, - F8: 119, - F9: 120, - F10: 121, - F11: 122, - F12: 123, - F13: 124, - F14: 125, - F15: 126, - NUM_LOCK: 144, - SCROLL_LOCK: 145, - UP_DPAD: 175, - DOWN_DPAD: 176, - LEFT_DPAD: 177, - RIGHT_DPAD: 178, - // virtual key mapping - copyKey: has("mac") && !has("air") ? (has("safari") ? 91 : 224 ) : 17 - }; -}); diff --git a/lib/dojo/loadInit.js b/lib/dojo/loadInit.js deleted file mode 100644 index 9503289..0000000 --- a/lib/dojo/loadInit.js +++ /dev/null @@ -1,12 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/loadInit",["./_base/loader"],function(_1){ -return {dynamic:0,normalize:function(id){ -return id; -},load:_1.loadInit}; -}); diff --git a/lib/dojo/loadInit.js.uncompressed.js b/lib/dojo/loadInit.js.uncompressed.js deleted file mode 100644 index 373931d..0000000 --- a/lib/dojo/loadInit.js.uncompressed.js +++ /dev/null @@ -1,7 +0,0 @@ -define("dojo/loadInit", ["./_base/loader"], function(loader){ - return { - dynamic:0, - normalize:function(id){return id;}, - load:loader.loadInit - }; -}); diff --git a/lib/dojo/main.js b/lib/dojo/main.js deleted file mode 100644 index 3cb012b..0000000 --- a/lib/dojo/main.js +++ /dev/null @@ -1,29 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/main",["./_base/kernel","./has","require","./sniff","./_base/lang","./_base/array","./_base/config","./ready","./_base/declare","./_base/connect","./_base/Deferred","./_base/json","./_base/Color","./has!dojo-firebug?./_firebug/firebug","./_base/browser","./_base/loader"],function(_1,_2,_3,_4,_5,_6,_7,_8){ -if(_7.isDebug){ -_3(["./_firebug/firebug"]); -} -1||_2.add("dojo-config-require",1); -if(1){ -var _9=_7.require; -if(_9){ -_9=_6.map(_5.isArray(_9)?_9:[_9],function(_a){ -return _a.replace(/\./g,"/"); -}); -if(_1.isAsync){ -_3(_9); -}else{ -_8(1,function(){ -_3(_9); -}); -} -} -} -return _1; -}); diff --git a/lib/dojo/main.js.uncompressed.js b/lib/dojo/main.js.uncompressed.js deleted file mode 100644 index a3dd805..0000000 --- a/lib/dojo/main.js.uncompressed.js +++ /dev/null @@ -1,52 +0,0 @@ -define("dojo/main", [ - "./_base/kernel", // kernel.isAsync - "./has", - "require", - "./sniff", - "./_base/lang", - "./_base/array", - "./_base/config", - "./ready", - "./_base/declare", - "./_base/connect", - "./_base/Deferred", - "./_base/json", - "./_base/Color", - "./has!dojo-firebug?./_firebug/firebug", - "./_base/browser", - "./_base/loader" -], function(kernel, has, require, sniff, lang, array, config, ready){ - // module: - // dojo/main - // summary: - // This is the package main module for the dojo package; it loads dojo base appropriate for the execution environment. - - // the preferred way to load the dojo firebug console is by setting has("dojo-firebug") true in dojoConfig - // the isDebug config switch is for backcompat and will work fine in sync loading mode; it works in - // async mode too, but there's no guarantee when the module is loaded; therefore, if you need a firebug - // console guaranteed at a particular spot in an app, either set config.has["dojo-firebug"] true before - // loading dojo.js or explicitly include dojo/_firebug/firebug in a dependency list. - if(config.isDebug){ - require(["./_firebug/firebug"]); - } - - // dojoConfig.require is deprecated; use the loader configuration property deps - 1 || has.add("dojo-config-require", 1); - if( 1 ){ - var deps= config.require; - if(deps){ - // config.require may be dot notation - deps= array.map(lang.isArray(deps) ? deps : [deps], function(item){ return item.replace(/\./g, "/"); }); - if(kernel.isAsync){ - require(deps); - }else{ - // this is a bit janky; in 1.6- dojo is defined before these requires are applied; but in 1.7+ - // dojo isn't defined until returning from this module; this is only a problem in sync mode - // since we're in sync mode, we know we've got our loader with its priority ready queue - ready(1, function(){require(deps);}); - } - } - } - - return kernel; -}); diff --git a/lib/dojo/mouse.js b/lib/dojo/mouse.js deleted file mode 100644 index 7dd5540..0000000 --- a/lib/dojo/mouse.js +++ /dev/null @@ -1,69 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/mouse",["./_base/kernel","./on","./has","./dom","./_base/window"],function(_1,on,_2,_3,_4){ -_2.add("dom-quirks",_4.doc&&_4.doc.compatMode=="BackCompat"); -_2.add("events-mouseenter",_4.doc&&"onmouseenter" in _4.doc.createElement("div")); -_2.add("events-mousewheel",_4.doc&&"onmousewheel" in _4.doc); -var _5; -if((_2("dom-quirks")&&_2("ie"))||!_2("dom-addeventlistener")){ -_5={LEFT:1,MIDDLE:4,RIGHT:2,isButton:function(e,_6){ -return e.button&_6; -},isLeft:function(e){ -return e.button&1; -},isMiddle:function(e){ -return e.button&4; -},isRight:function(e){ -return e.button&2; -}}; -}else{ -_5={LEFT:0,MIDDLE:1,RIGHT:2,isButton:function(e,_7){ -return e.button==_7; -},isLeft:function(e){ -return e.button==0; -},isMiddle:function(e){ -return e.button==1; -},isRight:function(e){ -return e.button==2; -}}; -} -_1.mouseButtons=_5; -function _8(_9,_a){ -var _b=function(_c,_d){ -return on(_c,_9,function(_e){ -if(_a){ -return _a(_e,_d); -} -if(!_3.isDescendant(_e.relatedTarget,_c)){ -return _d.call(this,_e); -} -}); -}; -_b.bubble=function(_f){ -return _8(_9,function(evt,_10){ -var _11=_f(evt.target); -var _12=evt.relatedTarget; -if(_11&&(_11!=(_12&&_12.nodeType==1&&_f(_12)))){ -return _10.call(_11,evt); -} -}); -}; -return _b; -}; -var _13; -if(_2("events-mousewheel")){ -_13="mousewheel"; -}else{ -_13=function(_14,_15){ -return on(_14,"DOMMouseScroll",function(evt){ -evt.wheelDelta=-evt.detail; -_15.call(this,evt); -}); -}; -} -return {_eventHandler:_8,enter:_8("mouseover"),leave:_8("mouseout"),wheel:_13,isLeft:_5.isLeft,isMiddle:_5.isMiddle,isRight:_5.isRight}; -}); diff --git a/lib/dojo/mouse.js.uncompressed.js b/lib/dojo/mouse.js.uncompressed.js deleted file mode 100644 index 473345b..0000000 --- a/lib/dojo/mouse.js.uncompressed.js +++ /dev/null @@ -1,171 +0,0 @@ -define("dojo/mouse", ["./_base/kernel", "./on", "./has", "./dom", "./_base/window"], function(dojo, on, has, dom, win){ - - // module: - // dojo/mouse - - has.add("dom-quirks", win.doc && win.doc.compatMode == "BackCompat"); - has.add("events-mouseenter", win.doc && "onmouseenter" in win.doc.createElement("div")); - has.add("events-mousewheel", win.doc && 'onmousewheel' in win.doc); - - var mouseButtons; - if((has("dom-quirks") && has("ie")) || !has("dom-addeventlistener")){ - mouseButtons = { - LEFT: 1, - MIDDLE: 4, - RIGHT: 2, - // helper functions - isButton: function(e, button){ return e.button & button; }, - isLeft: function(e){ return e.button & 1; }, - isMiddle: function(e){ return e.button & 4; }, - isRight: function(e){ return e.button & 2; } - }; - }else{ - mouseButtons = { - LEFT: 0, - MIDDLE: 1, - RIGHT: 2, - // helper functions - isButton: function(e, button){ return e.button == button; }, - isLeft: function(e){ return e.button == 0; }, - isMiddle: function(e){ return e.button == 1; }, - isRight: function(e){ return e.button == 2; } - }; - } - dojo.mouseButtons = mouseButtons; - -/*===== - dojo.mouseButtons = { - // LEFT: Number - // Numeric value of the left mouse button for the platform. - LEFT: 0, - // MIDDLE: Number - // Numeric value of the middle mouse button for the platform. - MIDDLE: 1, - // RIGHT: Number - // Numeric value of the right mouse button for the platform. - RIGHT: 2, - - isButton: function(e, button){ - // summary: - // Checks an event object for a pressed button - // e: Event - // Event object to examine - // button: Number - // The button value (example: dojo.mouseButton.LEFT) - return e.button == button; // Boolean - }, - isLeft: function(e){ - // summary: - // Checks an event object for the pressed left button - // e: Event - // Event object to examine - return e.button == 0; // Boolean - }, - isMiddle: function(e){ - // summary: - // Checks an event object for the pressed middle button - // e: Event - // Event object to examine - return e.button == 1; // Boolean - }, - isRight: function(e){ - // summary: - // Checks an event object for the pressed right button - // e: Event - // Event object to examine - return e.button == 2; // Boolean - } - }; -=====*/ - - function eventHandler(type, selectHandler){ - // emulation of mouseenter/leave with mouseover/out using descendant checking - var handler = function(node, listener){ - return on(node, type, function(evt){ - if(selectHandler){ - return selectHandler(evt, listener); - } - if(!dom.isDescendant(evt.relatedTarget, node)){ - return listener.call(this, evt); - } - }); - }; - handler.bubble = function(select){ - return eventHandler(type, function(evt, listener){ - // using a selector, use the select function to determine if the mouse moved inside the selector and was previously outside the selector - var target = select(evt.target); - var relatedTarget = evt.relatedTarget; - if(target && (target != (relatedTarget && relatedTarget.nodeType == 1 && select(relatedTarget)))){ - return listener.call(target, evt); - } - }); - }; - return handler; - } - var wheel; - if(has("events-mousewheel")){ - wheel = 'mousewheel'; - }else{ //firefox - wheel = function(node, listener){ - return on(node, 'DOMMouseScroll', function(evt){ - evt.wheelDelta = -evt.detail; - listener.call(this, evt); - }); - }; - } - return { - // summary: - // This module provide mouse event handling utility functions and exports - // mouseenter and mouseleave event emulation. - // example: - // To use these events, you register a mouseenter like this: - // | define(["dojo/on", dojo/mouse"], function(on, mouse){ - // | on(targetNode, mouse.enter, function(event){ - // | dojo.addClass(targetNode, "highlighted"); - // | }); - // | on(targetNode, mouse.leave, function(event){ - // | dojo.removeClass(targetNode, "highlighted"); - // | }); - - _eventHandler: eventHandler, // for dojo/touch - - // enter: Synthetic Event - // This is an extension event for the mouseenter that IE provides, emulating the - // behavior on other browsers. - enter: eventHandler("mouseover"), - - // leave: Synthetic Event - // This is an extension event for the mouseleave that IE provides, emulating the - // behavior on other browsers. - leave: eventHandler("mouseout"), - - // wheel: Normalized Mouse Wheel Event - // This is an extension event for the mousewheel that non-Mozilla browsers provide, - // emulating the behavior on Mozilla based browsers. - wheel: wheel, - - isLeft: mouseButtons.isLeft, - /*===== - isLeft: function(){ - // summary: - // Test an event object (from a mousedown event) to see if the left button was pressed. - }, - =====*/ - - isMiddle: mouseButtons.isMiddle, - /*===== - isMiddle: function(){ - // summary: - // Test an event object (from a mousedown event) to see if the middle button was pressed. - }, - =====*/ - - isRight: mouseButtons.isRight - /*===== - , isRight: function(){ - // summary: - // Test an event object (from a mousedown event) to see if the right button was pressed. - } - =====*/ - }; -}); diff --git a/lib/dojo/nls/ar/colors.js b/lib/dojo/nls/ar/colors.js deleted file mode 100644 index 7e8beca..0000000 --- a/lib/dojo/nls/ar/colors.js +++ /dev/null @@ -1,8 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/nls/ar/colors",({aliceblue:"أزرق فاتح",antiquewhite:"أبيض عتيق",aqua:"أزرق مائي",aquamarine:"أزرق مائل للأخضر (زبرجد)",azure:"أزرق سماوي",beige:"بيج",bisque:"أصفر برتقالي الى رمادي مصفر",black:"أسود",blanchedalmond:"أخضر مائل للبياض",blue:"أزرق",blueviolet:"أزرق-بنفسجي",brown:"بني",burlywood:"خشبي",cadetblue:"أزرق ملون بالرمادي",chartreuse:"أخضر مائل للصفرة",chocolate:"بني غامق",coral:"مرجاني",cornflowerblue:"أزرق عنبري",cornsilk:"حريري",crimson:"قرمزي",cyan:"أزرق سماوي",darkblue:"أزرق داكن",darkcyan:"أزرق سماوي داكن",darkgoldenrod:"أصفر ذهبي داكن",darkgray:"رمادي داكن",darkgreen:"أخضر داكن",darkgrey:"رمادي داكن",darkkhaki:"كاكي داكن",darkmagenta:"قرمزي داكن",darkolivegreen:"أخضر زيتوني داكن",darkorange:"برتقالي داكن",darkorchid:"أرجواني داكن",darkred:"أحمر داكن",darksalmon:"فضي داكن",darkseagreen:"أخضر مائل للأزرق داكن",darkslateblue:"أزرق اردوازي داكن",darkslategray:"رمادي اردوازي داكن",darkslategrey:"رمادي اردوازي داكن",darkturquoise:"تركواز داكن",darkviolet:"بنفسجي داكن",deeppink:"أحمر وردي غامق",deepskyblue:"أزرق سماوي غامق",dimgray:"رمادي شاحب",dimgrey:"رمادي شاحب",dodgerblue:"أزرق عنبري",firebrick:"أصفر زاهي",floralwhite:"أبيض زهري",forestgreen:"أخضر بلون أشجار الغابات",fuchsia:"فوشيا",gainsboro:"رمادي مائل للأزرق فاتح",ghostwhite:"أبيض شفاف",gold:"ذهبي",goldenrod:"أصفر ذهبي",gray:"رمادي",green:"أخضر",greenyellow:"أخضر مائل للأصفر",grey:"رمادي",honeydew:"أبيض مائل للأخضر",hotpink:"أحمر وردي زاهي",indianred:"أحمر هندي",indigo:"نيلي",ivory:"عاجي",khaki:"كاكي",lavender:"أرجواني شاحب",lavenderblush:"أحمر أرجواني",lawngreen:"أخضر بلون العشب",lemonchiffon:"أصفر شفاف",lightblue:"أزرق فاتح",lightcoral:"مرجاني فاتح",lightcyan:"سماوي فاتح",lightgoldenrodyellow:"أصفر ذهبي فاتح",lightgray:"رمادي فاتح",lightgreen:"أخضر فاتح",lightgrey:"رمادي فاتح",lightpink:"وردي فاتح",lightsalmon:"فضي فاتح",lightseagreen:"أخضر مائل للأزرق فاتح",lightskyblue:"أزرق سماوي فاتح",lightslategray:"رمادي اردوازي فاتح",lightslategrey:"رمادي اردوازي فاتح",lightsteelblue:"أزرق معدني فاتح",lightyellow:"أصفر فاتح",lime:"ليموني",limegreen:"أخضر ليموني",linen:"كتاني",magenta:"أحمر قرمزي",maroon:"أحمر داكن",mediumaquamarine:"أزرق مائل للأخضر (زبرجد) متوسط",mediumblue:"أزرق متوسط",mediumorchid:"أرجواني متوسط",mediumpurple:"قرمزي متوسط",mediumseagreen:"أخضر مائل للأزرق متوسط",mediumslateblue:"أزرق اردوازي متوسط",mediumspringgreen:"أخضر ربيعي متوسط",mediumturquoise:"تركواز متوسط",mediumvioletred:"أحمر-بنفسجي متوسط",midnightblue:"أزرق بحري",mintcream:"أصفر شاحب مائل للأخضر الزرعي",mistyrose:"وردي",moccasin:"نحاسي أحمر",navajowhite:"أبيض ملاحي",navy:"أزرق داكن",oldlace:"برتقالي مائل للأصفر شاحب",olive:"أخضر زيتوني داكن",olivedrab:"أسود فاتح",orange:"برتقالي",orangered:"أحمر مائل للبرتقالي",orchid:"أرجواني فاتح",palegoldenrod:"أصفر ذهبي شاحب",palegreen:"أخضر شاحب",paleturquoise:"تركواز شاحب",palevioletred:"أحمر-بنفسجي شاحب",papayawhip:"خوخي فاتح",peachpuff:"خوخي مائل للأصفر",peru:"بني جملي",pink:"وردي",plum:"أرجواني داكن",powderblue:"أزرق مائل للأصفر",purple:"ارجواني",red:"أحمر",rosybrown:"بني وردي",royalblue:"أزرق ملكي",saddlebrown:"بني فاتح",salmon:"برتقالي وردي شاحب",sandybrown:"بني مائل للصفرة",seagreen:"أخضر مائل للأزرق",seashell:"أبيض مائل للأصفر فاتح",sienna:"بني محروق",silver:"فضي",skyblue:"أزرق سماوي",slateblue:"أزرق اردوازي",slategray:"رمادي اردوازي",slategrey:"رمادي اردوازي",snow:"أبيض ثلجي",springgreen:"أخضر ربيعي",steelblue:"أزرق معدني",tan:"خمري",teal:"بترولي",thistle:"ارجواني شاحب",tomato:"أحمر مائل للأصفر",transparent:"شفاف",turquoise:"تركواز",violet:"بنفسجي",wheat:"أخضر قمحي",white:"أبيض",whitesmoke:"دخان أبيض",yellow:"أصفر",yellowgreen:"أخضر مائل للأصفر"})); diff --git a/lib/dojo/nls/ar/colors.js.uncompressed.js b/lib/dojo/nls/ar/colors.js.uncompressed.js deleted file mode 100644 index 0b7fa59..0000000 --- a/lib/dojo/nls/ar/colors.js.uncompressed.js +++ /dev/null @@ -1,156 +0,0 @@ -define( -"dojo/nls/ar/colors", ({ -// local representation of all CSS3 named colors, companion to dojo.colors. To be used where descriptive information -// is required for each color, such as a palette widget, and not for specifying color programatically. - //Note: due to the SVG 1.0 spec additions, some of these are alternate spellings for the same color (e.g. gray / grey). - //TODO: should we be using unique rgb values as keys instead and avoid these duplicates, or rely on the caller to do the reverse mapping? - aliceblue: "أزرق فاتح", - antiquewhite: "أبيض عتيق", - aqua: "أزرق مائي", - aquamarine: "أزرق مائل للأخضر (زبرجد)", - azure: "أزرق سماوي", - beige: "بيج", - bisque: "أصفر برتقالي الى رمادي مصفر", - black: "أسود", - blanchedalmond: "أخضر مائل للبياض", - blue: "أزرق", - blueviolet: "أزرق-بنفسجي", - brown: "بني", - burlywood: "خشبي", - cadetblue: "أزرق ملون بالرمادي", - chartreuse: "أخضر مائل للصفرة", - chocolate: "بني غامق", - coral: "مرجاني", - cornflowerblue: "أزرق عنبري", - cornsilk: "حريري", - crimson: "قرمزي", - cyan: "أزرق سماوي", - darkblue: "أزرق داكن", - darkcyan: "أزرق سماوي داكن", - darkgoldenrod: "أصفر ذهبي داكن", - darkgray: "رمادي داكن", - darkgreen: "أخضر داكن", - darkgrey: "رمادي داكن", // same as darkgray - darkkhaki: "كاكي داكن", - darkmagenta: "قرمزي داكن", - darkolivegreen: "أخضر زيتوني داكن", - darkorange: "برتقالي داكن", - darkorchid: "أرجواني داكن", - darkred: "أحمر داكن", - darksalmon: "فضي داكن", - darkseagreen: "أخضر مائل للأزرق داكن", - darkslateblue: "أزرق اردوازي داكن", - darkslategray: "رمادي اردوازي داكن", - darkslategrey: "رمادي اردوازي داكن", // same as darkslategray - darkturquoise: "تركواز داكن", - darkviolet: "بنفسجي داكن", - deeppink: "أحمر وردي غامق", - deepskyblue: "أزرق سماوي غامق", - dimgray: "رمادي شاحب", - dimgrey: "رمادي شاحب", // same as dimgray - dodgerblue: "أزرق عنبري", - firebrick: "أصفر زاهي", - floralwhite: "أبيض زهري", - forestgreen: "أخضر بلون أشجار الغابات", - fuchsia: "فوشيا", - gainsboro: "رمادي مائل للأزرق فاتح", - ghostwhite: "أبيض شفاف", - gold: "ذهبي", - goldenrod: "أصفر ذهبي", - gray: "رمادي", - green: "أخضر", - greenyellow: "أخضر مائل للأصفر", - grey: "رمادي", // same as gray - honeydew: "أبيض مائل للأخضر", - hotpink: "أحمر وردي زاهي", - indianred: "أحمر هندي", - indigo: "نيلي", - ivory: "عاجي", - khaki: "كاكي", - lavender: "أرجواني شاحب", - lavenderblush: "أحمر أرجواني", - lawngreen: "أخضر بلون العشب", - lemonchiffon: "أصفر شفاف", - lightblue: "أزرق فاتح", - lightcoral: "مرجاني فاتح", - lightcyan: "سماوي فاتح", - lightgoldenrodyellow: "أصفر ذهبي فاتح", - lightgray: "رمادي فاتح", - lightgreen: "أخضر فاتح", - lightgrey: "رمادي فاتح", // same as lightgray - lightpink: "وردي فاتح", - lightsalmon: "فضي فاتح", - lightseagreen: "أخضر مائل للأزرق فاتح", - lightskyblue: "أزرق سماوي فاتح", - lightslategray: "رمادي اردوازي فاتح", - lightslategrey: "رمادي اردوازي فاتح", // same as lightslategray - lightsteelblue: "أزرق معدني فاتح", - lightyellow: "أصفر فاتح", - lime: "ليموني", - limegreen: "أخضر ليموني", - linen: "كتاني", - magenta: "أحمر قرمزي", - maroon: "أحمر داكن", - mediumaquamarine: "أزرق مائل للأخضر (زبرجد) متوسط", - mediumblue: "أزرق متوسط", - mediumorchid: "أرجواني متوسط", - mediumpurple: "قرمزي متوسط", - mediumseagreen: "أخضر مائل للأزرق متوسط", - mediumslateblue: "أزرق اردوازي متوسط", - mediumspringgreen: "أخضر ربيعي متوسط", - mediumturquoise: "تركواز متوسط", - mediumvioletred: "أحمر-بنفسجي متوسط", - midnightblue: "أزرق بحري", - mintcream: "أصفر شاحب مائل للأخضر الزرعي", - mistyrose: "وردي", - moccasin: "نحاسي أحمر", - navajowhite: "أبيض ملاحي", - navy: "أزرق داكن", - oldlace: "برتقالي مائل للأصفر شاحب", - olive: "أخضر زيتوني داكن", - olivedrab: "أسود فاتح", - orange: "برتقالي", - orangered: "أحمر مائل للبرتقالي", - orchid: "أرجواني فاتح", - palegoldenrod: "أصفر ذهبي شاحب", - palegreen: "أخضر شاحب", - paleturquoise: "تركواز شاحب", - palevioletred: "أحمر-بنفسجي شاحب", - papayawhip: "خوخي فاتح", - peachpuff: "خوخي مائل للأصفر", - peru: "بني جملي", - pink: "وردي", - plum: "أرجواني داكن", - powderblue: "أزرق مائل للأصفر", - purple: "ارجواني", - red: "أحمر", - rosybrown: "بني وردي", - royalblue: "أزرق ملكي", - saddlebrown: "بني فاتح", - salmon: "برتقالي وردي شاحب", - sandybrown: "بني مائل للصفرة", - seagreen: "أخضر مائل للأزرق", - seashell: "أبيض مائل للأصفر فاتح", - sienna: "بني محروق", - silver: "فضي", - skyblue: "أزرق سماوي", - slateblue: "أزرق اردوازي", - slategray: "رمادي اردوازي", - slategrey: "رمادي اردوازي", // same as slategray - snow: "أبيض ثلجي", - springgreen: "أخضر ربيعي", - steelblue: "أزرق معدني", - tan: "خمري", - teal: "بترولي", - thistle: "ارجواني شاحب", - tomato: "أحمر مائل للأصفر", - transparent: "شفاف", - turquoise: "تركواز", - violet: "بنفسجي", - wheat: "أخضر قمحي", - white: "أبيض", - whitesmoke: "دخان أبيض", - yellow: "أصفر", - yellowgreen: "أخضر مائل للأصفر" -}) -); diff --git a/lib/dojo/nls/az/colors.js b/lib/dojo/nls/az/colors.js deleted file mode 100644 index f942ebb..0000000 --- a/lib/dojo/nls/az/colors.js +++ /dev/null @@ -1,8 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/nls/az/colors",({"lightsteelblue":"açıq metal mavi","orangered":"narıncı qırmızı","midnightblue":"gecə mavisi","cadetblue":"dəniz mavisi","seashell":"dəniz səthi","slategrey":"boz şifer rəngi","coral":"mərcan","darkturquoise":"tünd firuzəyi","antiquewhite":"antik ağ","mediumspringgreen":"orta bahar yaşılı","salmon":"somon","darkgrey":"tünd boz","ivory":"fil dişi","greenyellow":"yaşıl-sarı","mistyrose":"gül qurusu","lightsalmon":"açıq somon","silver":"gümüşü","dimgrey":"açıq boz","orange":"narıncı","white":"ağ","navajowhite":"navajo ağı","royalblue":"parlaq tünd mavi","deeppink":"tünd çəhrayı","lime":"lomon yaşılı","oldlace":"köhnə krujeva","chartreuse":"chartreuse","darkcyan":"tünd firuzəyi","yellow":"sarı","linen":"kətan","olive":"zeytun","gold":"qızıl","lawngreen":"çəmən yaşılı","lightyellow":"açıq sarı","tan":"günəş yanığı","darkviolet":"tünd bənövşəyi","lightslategrey":"tünd şifer bozu","grey":"boz","darkkhaki":"tünd haki","green":"yaşıl","deepskyblue":"tünd səma mavisi","aqua":"dəniz mavisi","sienna":"tünd qəhvəyi","mintcream":"nanəli krem","rosybrown":"çəhrayımsı qəhvəyi","mediumslateblue":"orta şıfer bozu","magenta":"magenta","lightseagreen":"açıq dəniz yaşılı","cyan":"firuzəyi","olivedrab":"əsgər yaşılı","darkgoldenrod":"tünd sarı","slateblue":"şifer mavisi","mediumaquamarine":"orta akvamarin","lavender":"lavanta","mediumseagreen":"orta dəniz yaşılı","maroon":"tünd qırmızı","darkslategray":"tünd şifer bozu","mediumturquoise":"orta firuzəyi","ghostwhite":"ala","darkblue":"tünd mavi","mediumvioletred":"orta bənövşəyi-qırmızı","brown":"qəhvəyi","lightgray":"açıq boz","sandybrown":"qum rəngi","pink":"çəhrayı","firebrick":"yanmış kərpic rəngi","indigo":"indigo","snow":"qar","darkorchid":"tünd orkide","turquoise":"firuzəyi","chocolate":"şokolad","springgreen":"bahar yaşılı","moccasin":"mokosen","navy":"tünd göy","lemonchiffon":"limon rəngi","teal":"teal mavi","floralwhite":"çiçək ağı","cornflowerblue":"peyğəmbər çiçək mavisi","paleturquoise":"solğun firuzəyi","purple":"tünd qırmızı","gainsboro":"gainsboro","plum":"gavalı","red":"qırmızı","blue":"göy","forestgreen":"tünd dəniz yaşılı","darkgreen":"tünd yaşıl","honeydew":"bal saqqızı","darkseagreen":"tünd dəniz yaşılı","lightcoral":"açıq mərcan","palevioletred":"solğun bənövşəyi-qırmızı","mediumpurple":"orta tünd qırmızı","saddlebrown":"açıq qəhvəyi","darkmagenta":"tünd magenta","thistle":"dəvə tikanı","whitesmoke":"ağ duman","wheat":"buğdayı","violet":"bənövşəyi","lightskyblue":"açıq səma mavisi","goldenrod":"sapsarı","mediumblue":"orta göy","skyblue":"göy mavisi","crimson":"crimson","darksalmon":"tünd somon","darkred":"tünd qırmızı","darkslategrey":"tünd şifer bozu","peru":"peru","lightgrey":"açıq boz","lightgoldenrodyellow":"açıq qızılı","blanchedalmond":"solğun badamı","aliceblue":"alice mavisi","bisque":"biskvit","slategray":"şifer bozu","palegoldenrod":"açıq qızılı","darkorange":"tünd narıncı","aquamarine":"akvamarin","lightgreen":"açıq yaşıl","burlywood":"sarımsı qəhvə rəngi","dodgerblue":"toz mavisi","darkgray":"tünd boz","lightcyan":"açıq firuzəyi","powderblue":"pudra mavisi","blueviolet":"mavi-bənövşəyi","orchid":"orkide","dimgray":"solğun boz","beige":"bej","fuchsia":"fuşya","lavenderblush":"lavanta tünd qırmızısı","hotpink":"tünd çəhrayı","steelblue":"metal mavisi","tomato":"pomidor","lightpink":"açıq çəhrayı","limegreen":"əhəng yaşılı","indianred":"qızıldərili qırmızısı","papayawhip":"papaya qamçısı","lightslategray":"açıq şifer bozu","gray":"boz","mediumorchid":"orta orkide","cornsilk":"qarğıdalı rəngi","black":"qara","seagreen":"dəniz yaşılı","darkslateblue":"tünd şifer bozu","khaki":"haki","lightblue":"açıq mavi","palegreen":"solğun yaşıl","azure":"azur mavisi","peachpuff":"açıq şaftalı","darkolivegreen":"tünd zeytun yaşılı","yellowgreen":"sarı-yaşıl"})); diff --git a/lib/dojo/nls/az/colors.js.uncompressed.js b/lib/dojo/nls/az/colors.js.uncompressed.js deleted file mode 100644 index 5092b46..0000000 --- a/lib/dojo/nls/az/colors.js.uncompressed.js +++ /dev/null @@ -1,151 +0,0 @@ -define( -"dojo/nls/az/colors", ({ - "lightsteelblue":"açıq metal mavi", - "orangered" :"narıncı qırmızı", - "midnightblue" :"gecə mavisi", - "cadetblue" :"dəniz mavisi" , - "seashell" :"dəniz səthi", - "slategrey" :"boz şifer rəngi", - "coral" :"mərcan", - "darkturquoise" :"tünd firuzəyi", - "antiquewhite" :"antik ağ", - "mediumspringgreen" :"orta bahar yaşılı", - "salmon" :"somon", - "darkgrey" :"tünd boz", - "ivory" :"fil dişi", - "greenyellow" :"yaşıl-sarı", - "mistyrose" :"gül qurusu", - "lightsalmon" :"açıq somon", - "silver" :"gümüşü", - "dimgrey" :"açıq boz", - "orange" :"narıncı", - "white" :"ağ", - "navajowhite" :"navajo ağı", - "royalblue" :"parlaq tünd mavi" , - "deeppink" :"tünd çəhrayı", - "lime" :"lomon yaşılı", - "oldlace" :"köhnə krujeva", - "chartreuse" :"chartreuse", - "darkcyan" :"tünd firuzəyi", - "yellow" :"sarı", - "linen" :"kətan", - "olive" :"zeytun", - "gold" :"qızıl", - "lawngreen" :"çəmən yaşılı", - "lightyellow" :"açıq sarı", - "tan" :"günəş yanığı", - "darkviolet" :"tünd bənövşəyi", - "lightslategrey" :"tünd şifer bozu", - "grey" :"boz", - "darkkhaki" :"tünd haki", - "green" :"yaşıl", - "deepskyblue" :"tünd səma mavisi", - "aqua" :"dəniz mavisi", - "sienna" :"tünd qəhvəyi", - "mintcream" :"nanəli krem", - "rosybrown" :"çəhrayımsı qəhvəyi", - "mediumslateblue" :"orta şıfer bozu", - "magenta" :"magenta", - "lightseagreen" :"açıq dəniz yaşılı", - "cyan" :"firuzəyi", - "olivedrab" :"əsgər yaşılı", - "darkgoldenrod" :"tünd sarı", - "slateblue" :"şifer mavisi", - "mediumaquamarine" :"orta akvamarin", - "lavender" :"lavanta", - "mediumseagreen" :"orta dəniz yaşılı", - "maroon" :"tünd qırmızı", - "darkslategray" :"tünd şifer bozu", - "mediumturquoise" :"orta firuzəyi", - "ghostwhite" :"ala", - "darkblue" :"tünd mavi", - "mediumvioletred" :"orta bənövşəyi-qırmızı", - "brown" :"qəhvəyi", - "lightgray" :"açıq boz", - "sandybrown" :"qum rəngi", - "pink" :"çəhrayı", - "firebrick" :"yanmış kərpic rəngi", - "indigo" :"indigo", - "snow" :"qar", - "darkorchid" :"tünd orkide", - "turquoise" :"firuzəyi", - "chocolate" :"şokolad", - "springgreen" :"bahar yaşılı", - "moccasin" :"mokosen", - "navy" :"tünd göy", - "lemonchiffon" :"limon rəngi", - "teal" :"teal mavi", - "floralwhite" :"çiçək ağı", - "cornflowerblue" :"peyğəmbər çiçək mavisi", - "paleturquoise" :"solğun firuzəyi", - "purple" :"tünd qırmızı", - "gainsboro" :"gainsboro", - "plum" :"gavalı", - "red" :"qırmızı", - "blue" :"göy", - "forestgreen" :"tünd dəniz yaşılı", - "darkgreen" :"tünd yaşıl", - "honeydew" :"bal saqqızı", - "darkseagreen" :"tünd dəniz yaşılı", - "lightcoral" :"açıq mərcan", - "palevioletred" :"solğun bənövşəyi-qırmızı", - "mediumpurple" :"orta tünd qırmızı", - "saddlebrown" :"açıq qəhvəyi", - "darkmagenta" :"tünd magenta", - "thistle" :"dəvə tikanı", - "whitesmoke" :"ağ duman", - "wheat" :"buğdayı", - "violet" :"bənövşəyi", - "lightskyblue" :"açıq səma mavisi" , - "goldenrod" :"sapsarı", - "mediumblue" :"orta göy", - "skyblue" :"göy mavisi", - "crimson" :"crimson", - "darksalmon" :"tünd somon", - "darkred" :"tünd qırmızı", - "darkslategrey" :"tünd şifer bozu", - "peru" :"peru", - "lightgrey" :"açıq boz", - "lightgoldenrodyellow" :"açıq qızılı", - "blanchedalmond" :"solğun badamı", - "aliceblue" :"alice mavisi", - "bisque" :"biskvit", - "slategray" :"şifer bozu", - "palegoldenrod" :"açıq qızılı", - "darkorange" :"tünd narıncı", - "aquamarine" :"akvamarin", - "lightgreen" :"açıq yaşıl", - "burlywood" :"sarımsı qəhvə rəngi", - "dodgerblue" :"toz mavisi", - "darkgray" :"tünd boz", - "lightcyan" :"açıq firuzəyi", - "powderblue" :"pudra mavisi", - "blueviolet" :"mavi-bənövşəyi", - "orchid" :"orkide", - "dimgray" :"solğun boz", - "beige" :"bej", - "fuchsia" :"fuşya", - "lavenderblush" :"lavanta tünd qırmızısı", - "hotpink" :"tünd çəhrayı", - "steelblue" :"metal mavisi", - "tomato" :"pomidor", - "lightpink" :"açıq çəhrayı", - "limegreen" :"əhəng yaşılı", - "indianred" :"qızıldərili qırmızısı", - "papayawhip" :"papaya qamçısı", - "lightslategray" :"açıq şifer bozu", - "gray" :"boz", - "mediumorchid" :"orta orkide", - "cornsilk" :"qarğıdalı rəngi", - "black" :"qara", - "seagreen" :"dəniz yaşılı", - "darkslateblue" :"tünd şifer bozu", - "khaki" :"haki", - "lightblue" :"açıq mavi", - "palegreen" :"solğun yaşıl", - "azure" :"azur mavisi", - "peachpuff" :"açıq şaftalı", - "darkolivegreen" :"tünd zeytun yaşılı", - "yellowgreen" :"sarı-yaşıl" -}) -); diff --git a/lib/dojo/nls/bg/colors.js b/lib/dojo/nls/bg/colors.js deleted file mode 100644 index dc3ebd7..0000000 --- a/lib/dojo/nls/bg/colors.js +++ /dev/null @@ -1,8 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/nls/bg/colors",({aliceblue:"alice blue",antiquewhite:"antique white",aqua:"aqua",aquamarine:"aquamarine",azure:"azure",beige:"beige",bisque:"bisque",black:"black",blanchedalmond:"blanched almond",blue:"blue",blueviolet:"blue-violet",brown:"brown",burlywood:"burlywood",cadetblue:"cadet blue",chartreuse:"chartreuse",chocolate:"chocolate",coral:"coral",cornflowerblue:"cornflower blue",cornsilk:"cornsilk",crimson:"crimson",cyan:"cyan",darkblue:"dark blue",darkcyan:"dark cyan",darkgoldenrod:"dark goldenrod",darkgray:"dark gray",darkgreen:"dark green",darkgrey:"dark gray",darkkhaki:"dark khaki",darkmagenta:"dark magenta",darkolivegreen:"dark olive green",darkorange:"dark orange",darkorchid:"dark orchid",darkred:"dark red",darksalmon:"dark salmon",darkseagreen:"dark sea green",darkslateblue:"dark slate blue",darkslategray:"dark slate gray",darkslategrey:"dark slate gray",darkturquoise:"dark turquoise",darkviolet:"dark violet",deeppink:"deep pink",deepskyblue:"deep sky blue",dimgray:"dim gray",dimgrey:"dim gray",dodgerblue:"dodger blue",firebrick:"fire brick",floralwhite:"floral white",forestgreen:"forest green",fuchsia:"fuchsia",gainsboro:"gainsboro",ghostwhite:"ghost white",gold:"gold",goldenrod:"goldenrod",gray:"gray",green:"green",greenyellow:"green-yellow",grey:"gray",honeydew:"honeydew",hotpink:"hot pink",indianred:"indian red",indigo:"indigo",ivory:"ivory",khaki:"khaki",lavender:"lavender",lavenderblush:"lavender blush",lawngreen:"lawn green",lemonchiffon:"lemon chiffon",lightblue:"light blue",lightcoral:"light coral",lightcyan:"light cyan",lightgoldenrodyellow:"light goldenrod yellow",lightgray:"light gray",lightgreen:"light green",lightgrey:"light gray",lightpink:"light pink",lightsalmon:"light salmon",lightseagreen:"light sea green",lightskyblue:"light sky blue",lightslategray:"light slate gray",lightslategrey:"light slate gray",lightsteelblue:"light steel blue",lightyellow:"light yellow",lime:"lime",limegreen:"lime green",linen:"linen",magenta:"magenta",maroon:"maroon",mediumaquamarine:"medium aquamarine",mediumblue:"medium blue",mediumorchid:"medium orchid",mediumpurple:"medium purple",mediumseagreen:"medium sea green",mediumslateblue:"medium slate blue",mediumspringgreen:"medium spring green",mediumturquoise:"medium turquoise",mediumvioletred:"medium violet-red",midnightblue:"midnight blue",mintcream:"mint cream",mistyrose:"misty rose",moccasin:"moccasin",navajowhite:"navajo white",navy:"navy",oldlace:"old lace",olive:"olive",olivedrab:"olive drab",orange:"orange",orangered:"orange red",orchid:"orchid",palegoldenrod:"pale goldenrod",palegreen:"pale green",paleturquoise:"pale turquoise",palevioletred:"pale violet-red",papayawhip:"papaya whip",peachpuff:"peach puff",peru:"peru",pink:"pink",plum:"plum",powderblue:"powder blue",purple:"purple",red:"red",rosybrown:"rosy brown",royalblue:"royal blue",saddlebrown:"saddle brown",salmon:"salmon",sandybrown:"sandy brown",seagreen:"sea green",seashell:"seashell",sienna:"sienna",silver:"silver",skyblue:"sky blue",slateblue:"slate blue",slategray:"slate gray",slategrey:"slate gray",snow:"snow",springgreen:"spring green",steelblue:"steel blue",tan:"tan",teal:"teal",thistle:"thistle",tomato:"tomato",transparent:"transparent",turquoise:"turquoise",violet:"violet",wheat:"wheat",white:"white",whitesmoke:"white smoke",yellow:"yellow",yellowgreen:"yellow green"})); diff --git a/lib/dojo/nls/bg/colors.js.uncompressed.js b/lib/dojo/nls/bg/colors.js.uncompressed.js deleted file mode 100644 index 6c84038..0000000 --- a/lib/dojo/nls/bg/colors.js.uncompressed.js +++ /dev/null @@ -1,156 +0,0 @@ -define( -"dojo/nls/bg/colors", ({ -// local representation of all CSS3 named colors, companion to dojo.colors. To be used where descriptive information -// is required for each color, such as a palette widget, and not for specifying color programatically. - //Note: due to the SVG 1.0 spec additions, some of these are alternate spellings for the same color (e.g. gray / grey). - //TODO: should we be using unique rgb values as keys instead and avoid these duplicates, or rely on the caller to do the reverse mapping? - aliceblue: "alice blue", - antiquewhite: "antique white", - aqua: "aqua", - aquamarine: "aquamarine", - azure: "azure", - beige: "beige", - bisque: "bisque", - black: "black", - blanchedalmond: "blanched almond", - blue: "blue", - blueviolet: "blue-violet", - brown: "brown", - burlywood: "burlywood", - cadetblue: "cadet blue", - chartreuse: "chartreuse", - chocolate: "chocolate", - coral: "coral", - cornflowerblue: "cornflower blue", - cornsilk: "cornsilk", - crimson: "crimson", - cyan: "cyan", - darkblue: "dark blue", - darkcyan: "dark cyan", - darkgoldenrod: "dark goldenrod", - darkgray: "dark gray", - darkgreen: "dark green", - darkgrey: "dark gray", // same as darkgray - darkkhaki: "dark khaki", - darkmagenta: "dark magenta", - darkolivegreen: "dark olive green", - darkorange: "dark orange", - darkorchid: "dark orchid", - darkred: "dark red", - darksalmon: "dark salmon", - darkseagreen: "dark sea green", - darkslateblue: "dark slate blue", - darkslategray: "dark slate gray", - darkslategrey: "dark slate gray", // same as darkslategray - darkturquoise: "dark turquoise", - darkviolet: "dark violet", - deeppink: "deep pink", - deepskyblue: "deep sky blue", - dimgray: "dim gray", - dimgrey: "dim gray", // same as dimgray - dodgerblue: "dodger blue", - firebrick: "fire brick", - floralwhite: "floral white", - forestgreen: "forest green", - fuchsia: "fuchsia", - gainsboro: "gainsboro", - ghostwhite: "ghost white", - gold: "gold", - goldenrod: "goldenrod", - gray: "gray", - green: "green", - greenyellow: "green-yellow", - grey: "gray", // same as gray - honeydew: "honeydew", - hotpink: "hot pink", - indianred: "indian red", - indigo: "indigo", - ivory: "ivory", - khaki: "khaki", - lavender: "lavender", - lavenderblush: "lavender blush", - lawngreen: "lawn green", - lemonchiffon: "lemon chiffon", - lightblue: "light blue", - lightcoral: "light coral", - lightcyan: "light cyan", - lightgoldenrodyellow: "light goldenrod yellow", - lightgray: "light gray", - lightgreen: "light green", - lightgrey: "light gray", // same as lightgray - lightpink: "light pink", - lightsalmon: "light salmon", - lightseagreen: "light sea green", - lightskyblue: "light sky blue", - lightslategray: "light slate gray", - lightslategrey: "light slate gray", // same as lightslategray - lightsteelblue: "light steel blue", - lightyellow: "light yellow", - lime: "lime", - limegreen: "lime green", - linen: "linen", - magenta: "magenta", - maroon: "maroon", - mediumaquamarine: "medium aquamarine", - mediumblue: "medium blue", - mediumorchid: "medium orchid", - mediumpurple: "medium purple", - mediumseagreen: "medium sea green", - mediumslateblue: "medium slate blue", - mediumspringgreen: "medium spring green", - mediumturquoise: "medium turquoise", - mediumvioletred: "medium violet-red", - midnightblue: "midnight blue", - mintcream: "mint cream", - mistyrose: "misty rose", - moccasin: "moccasin", - navajowhite: "navajo white", - navy: "navy", - oldlace: "old lace", - olive: "olive", - olivedrab: "olive drab", - orange: "orange", - orangered: "orange red", - orchid: "orchid", - palegoldenrod: "pale goldenrod", - palegreen: "pale green", - paleturquoise: "pale turquoise", - palevioletred: "pale violet-red", - papayawhip: "papaya whip", - peachpuff: "peach puff", - peru: "peru", - pink: "pink", - plum: "plum", - powderblue: "powder blue", - purple: "purple", - red: "red", - rosybrown: "rosy brown", - royalblue: "royal blue", - saddlebrown: "saddle brown", - salmon: "salmon", - sandybrown: "sandy brown", - seagreen: "sea green", - seashell: "seashell", - sienna: "sienna", - silver: "silver", - skyblue: "sky blue", - slateblue: "slate blue", - slategray: "slate gray", - slategrey: "slate gray", // same as slategray - snow: "snow", - springgreen: "spring green", - steelblue: "steel blue", - tan: "tan", - teal: "teal", - thistle: "thistle", - tomato: "tomato", - transparent: "transparent", - turquoise: "turquoise", - violet: "violet", - wheat: "wheat", - white: "white", - whitesmoke: "white smoke", - yellow: "yellow", - yellowgreen: "yellow green" -}) -); diff --git a/lib/dojo/nls/ca/colors.js b/lib/dojo/nls/ca/colors.js deleted file mode 100644 index 9b543ae..0000000 --- a/lib/dojo/nls/ca/colors.js +++ /dev/null @@ -1,8 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/nls/ca/colors",({aliceblue:"blau cian clar",antiquewhite:"blanc antic",aqua:"aigua",aquamarine:"aiguamarina",azure:"atzur",beige:"beix",bisque:"crema",black:"negre",blanchedalmond:"ametlla pàl·lid",blue:"blau",blueviolet:"blau violeta",brown:"marró",burlywood:"marró arenós",cadetblue:"blau marí",chartreuse:"Llimona pàl·lid",chocolate:"xocolata",coral:"corall",cornflowerblue:"blau blauet",cornsilk:"cru",crimson:"carmesí",cyan:"cian",darkblue:"blau fosc",darkcyan:"cian fosc",darkgoldenrod:"ocre fosc",darkgray:"gris fosc",darkgreen:"verd fosc",darkgrey:"gris fosc",darkkhaki:"caqui fosc",darkmagenta:"magenta fosc",darkolivegreen:"verd oliva fosc",darkorange:"taronja fosc",darkorchid:"orquídia fosc",darkred:"vermell fosc",darksalmon:"salmó fosc",darkseagreen:"verd marí fosc",darkslateblue:"blau pissarra fosc",darkslategray:"gris pissarra fosc",darkslategrey:"gris pissarra fosc",darkturquoise:"turquesa fosc",darkviolet:"violeta fosc",deeppink:"rosa profund",deepskyblue:"blau cel profund",dimgray:"gris fosc",dimgrey:"gris fosc",dodgerblue:"blau Dodger",firebrick:"maó refractari",floralwhite:"blanc floral",forestgreen:"verd bosc",fuchsia:"fúcsia",gainsboro:"gainsboro",ghostwhite:"blanc fantasma",gold:"daurat",goldenrod:"ocre",gray:"gris",green:"verd",greenyellow:"verd grogós",grey:"gris",honeydew:"rosada de mel",hotpink:"rosa fúcsia",indianred:"vermell indi",indigo:"índigo",ivory:"marbre",khaki:"caqui",lavender:"lavanda",lavenderblush:"lavanda vermellosa",lawngreen:"verd gespa",lemonchiffon:"groc brisa",lightblue:"blau clar",lightcoral:"corall clar",lightcyan:"cian clar",lightgoldenrodyellow:"groc ocre clar",lightgray:"gris clar",lightgreen:"verd clar",lightgrey:"gris clar",lightpink:"rosa clar",lightsalmon:"salmó clar",lightseagreen:"verd marí clar",lightskyblue:"blau cel clar",lightslategray:"gris pissarra clar",lightslategrey:"gris pissarra clar",lightsteelblue:"blau acer clar",lightyellow:"groc clar",lime:"verd llimona",limegreen:"verd llimona verda",linen:"lli",magenta:"magenta",maroon:"marró vermellós",mediumaquamarine:"aiguamarina mitjana",mediumblue:"blau mitjà",mediumorchid:"orquídia mitjana",mediumpurple:"porpra mitjana",mediumseagreen:"verd marí mitjà",mediumslateblue:"blau pissarra mitjà",mediumspringgreen:"verd primavera mitjà",mediumturquoise:"turquesa mitjana",mediumvioletred:"vermell violeta mitjà",midnightblue:"blau mitjanit",mintcream:"menta pàl·lid",mistyrose:"rosa dens",moccasin:"mocassí",navajowhite:"blanc Navajo",navy:"blau marí",oldlace:"rosa cremós",olive:"oliva",olivedrab:"gris oliva",orange:"taronja",orangered:"taronja vermellós",orchid:"orquídia",palegoldenrod:"ocre pàl·lid",palegreen:"verd pàl·lid",paleturquoise:"turquesa pàl·lid",palevioletred:"vermell porpra pàl·lid",papayawhip:"préssec pastel",peachpuff:"préssec",peru:"Perú",pink:"rosa",plum:"pruna",powderblue:"blau grisós",purple:"porpra",red:"vermell",rosybrown:"marró rosat",royalblue:"blau marí intens",saddlebrown:"marró mitjà",salmon:"salmó",sandybrown:"marró arenós",seagreen:"verd marí",seashell:"petxina marina",sienna:"siena",silver:"argent",skyblue:"blau cel",slateblue:"blau pissarra",slategray:"gris pissarra",slategrey:"gris pissarra",snow:"neu",springgreen:"verd de primavera",steelblue:"blau acer",tan:"tan",teal:"verd blavós",thistle:"card",tomato:"tomàquet",transparent:"transparent",turquoise:"turquesa",violet:"violeta",wheat:"blat",white:"blanc",whitesmoke:"blanc fumat",yellow:"groc",yellowgreen:"verd grogós"})); diff --git a/lib/dojo/nls/ca/colors.js.uncompressed.js b/lib/dojo/nls/ca/colors.js.uncompressed.js deleted file mode 100644 index 520654d..0000000 --- a/lib/dojo/nls/ca/colors.js.uncompressed.js +++ /dev/null @@ -1,156 +0,0 @@ -define( -"dojo/nls/ca/colors", ({ -// local representation of all CSS3 named colors, companion to dojo.colors. To be used where descriptive information -// is required for each color, such as a palette widget, and not for specifying color programatically. - //Note: due to the SVG 1.0 spec additions, some of these are alternate spellings for the same color (e.g. gray / grey). - //TODO: should we be using unique rgb values as keys instead and avoid these duplicates, or rely on the caller to do the reverse mapping? - aliceblue: "blau cian clar", - antiquewhite: "blanc antic", - aqua: "aigua", - aquamarine: "aiguamarina", - azure: "atzur", - beige: "beix", - bisque: "crema", - black: "negre", - blanchedalmond: "ametlla pàl·lid", - blue: "blau", - blueviolet: "blau violeta", - brown: "marró", - burlywood: "marró arenós", - cadetblue: "blau marí", - chartreuse: "Llimona pàl·lid", - chocolate: "xocolata", - coral: "corall", - cornflowerblue: "blau blauet", - cornsilk: "cru", - crimson: "carmesí", - cyan: "cian", - darkblue: "blau fosc", - darkcyan: "cian fosc", - darkgoldenrod: "ocre fosc", - darkgray: "gris fosc", - darkgreen: "verd fosc", - darkgrey: "gris fosc", // same as darkgray - darkkhaki: "caqui fosc", - darkmagenta: "magenta fosc", - darkolivegreen: "verd oliva fosc", - darkorange: "taronja fosc", - darkorchid: "orquídia fosc", - darkred: "vermell fosc", - darksalmon: "salmó fosc", - darkseagreen: "verd marí fosc", - darkslateblue: "blau pissarra fosc", - darkslategray: "gris pissarra fosc", - darkslategrey: "gris pissarra fosc", // same as darkslategray - darkturquoise: "turquesa fosc", - darkviolet: "violeta fosc", - deeppink: "rosa profund", - deepskyblue: "blau cel profund", - dimgray: "gris fosc", - dimgrey: "gris fosc", // same as dimgray - dodgerblue: "blau Dodger", - firebrick: "maó refractari", - floralwhite: "blanc floral", - forestgreen: "verd bosc", - fuchsia: "fúcsia", - gainsboro: "gainsboro", - ghostwhite: "blanc fantasma", - gold: "daurat", - goldenrod: "ocre", - gray: "gris", - green: "verd", - greenyellow: "verd grogós", - grey: "gris", // same as gray - honeydew: "rosada de mel", - hotpink: "rosa fúcsia", - indianred: "vermell indi", - indigo: "índigo", - ivory: "marbre", - khaki: "caqui", - lavender: "lavanda", - lavenderblush: "lavanda vermellosa", - lawngreen: "verd gespa", - lemonchiffon: "groc brisa", - lightblue: "blau clar", - lightcoral: "corall clar", - lightcyan: "cian clar", - lightgoldenrodyellow: "groc ocre clar", - lightgray: "gris clar", - lightgreen: "verd clar", - lightgrey: "gris clar", // same as lightgray - lightpink: "rosa clar", - lightsalmon: "salmó clar", - lightseagreen: "verd marí clar", - lightskyblue: "blau cel clar", - lightslategray: "gris pissarra clar", - lightslategrey: "gris pissarra clar", // same as lightslategray - lightsteelblue: "blau acer clar", - lightyellow: "groc clar", - lime: "verd llimona", - limegreen: "verd llimona verda", - linen: "lli", - magenta: "magenta", - maroon: "marró vermellós", - mediumaquamarine: "aiguamarina mitjana", - mediumblue: "blau mitjà", - mediumorchid: "orquídia mitjana", - mediumpurple: "porpra mitjana", - mediumseagreen: "verd marí mitjà", - mediumslateblue: "blau pissarra mitjà", - mediumspringgreen: "verd primavera mitjà", - mediumturquoise: "turquesa mitjana", - mediumvioletred: "vermell violeta mitjà", - midnightblue: "blau mitjanit", - mintcream: "menta pàl·lid", - mistyrose: "rosa dens", - moccasin: "mocassí", - navajowhite: "blanc Navajo", - navy: "blau marí", - oldlace: "rosa cremós", - olive: "oliva", - olivedrab: "gris oliva", - orange: "taronja", - orangered: "taronja vermellós", - orchid: "orquídia", - palegoldenrod: "ocre pàl·lid", - palegreen: "verd pàl·lid", - paleturquoise: "turquesa pàl·lid", - palevioletred: "vermell porpra pàl·lid", - papayawhip: "préssec pastel", - peachpuff: "préssec", - peru: "Perú", - pink: "rosa", - plum: "pruna", - powderblue: "blau grisós", - purple: "porpra", - red: "vermell", - rosybrown: "marró rosat", - royalblue: "blau marí intens", - saddlebrown: "marró mitjà", - salmon: "salmó", - sandybrown: "marró arenós", - seagreen: "verd marí", - seashell: "petxina marina", - sienna: "siena", - silver: "argent", - skyblue: "blau cel", - slateblue: "blau pissarra", - slategray: "gris pissarra", - slategrey: "gris pissarra", // same as slategray - snow: "neu", - springgreen: "verd de primavera", - steelblue: "blau acer", - tan: "tan", - teal: "verd blavós", - thistle: "card", - tomato: "tomàquet", - transparent: "transparent", - turquoise: "turquesa", - violet: "violeta", - wheat: "blat", - white: "blanc", - whitesmoke: "blanc fumat", - yellow: "groc", - yellowgreen: "verd grogós" -}) -); diff --git a/lib/dojo/nls/colors.js b/lib/dojo/nls/colors.js deleted file mode 100644 index cbab528..0000000 --- a/lib/dojo/nls/colors.js +++ /dev/null @@ -1,8 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/nls/colors",{root:({aliceblue:"alice blue",antiquewhite:"antique white",aqua:"aqua",aquamarine:"aquamarine",azure:"azure",beige:"beige",bisque:"bisque",black:"black",blanchedalmond:"blanched almond",blue:"blue",blueviolet:"blue-violet",brown:"brown",burlywood:"burlywood",cadetblue:"cadet blue",chartreuse:"chartreuse",chocolate:"chocolate",coral:"coral",cornflowerblue:"cornflower blue",cornsilk:"cornsilk",crimson:"crimson",cyan:"cyan",darkblue:"dark blue",darkcyan:"dark cyan",darkgoldenrod:"dark goldenrod",darkgray:"dark gray",darkgreen:"dark green",darkgrey:"dark gray",darkkhaki:"dark khaki",darkmagenta:"dark magenta",darkolivegreen:"dark olive green",darkorange:"dark orange",darkorchid:"dark orchid",darkred:"dark red",darksalmon:"dark salmon",darkseagreen:"dark sea green",darkslateblue:"dark slate blue",darkslategray:"dark slate gray",darkslategrey:"dark slate gray",darkturquoise:"dark turquoise",darkviolet:"dark violet",deeppink:"deep pink",deepskyblue:"deep sky blue",dimgray:"dim gray",dimgrey:"dim gray",dodgerblue:"dodger blue",firebrick:"fire brick",floralwhite:"floral white",forestgreen:"forest green",fuchsia:"fuchsia",gainsboro:"gainsboro",ghostwhite:"ghost white",gold:"gold",goldenrod:"goldenrod",gray:"gray",green:"green",greenyellow:"green-yellow",grey:"gray",honeydew:"honeydew",hotpink:"hot pink",indianred:"indian red",indigo:"indigo",ivory:"ivory",khaki:"khaki",lavender:"lavender",lavenderblush:"lavender blush",lawngreen:"lawn green",lemonchiffon:"lemon chiffon",lightblue:"light blue",lightcoral:"light coral",lightcyan:"light cyan",lightgoldenrodyellow:"light goldenrod yellow",lightgray:"light gray",lightgreen:"light green",lightgrey:"light gray",lightpink:"light pink",lightsalmon:"light salmon",lightseagreen:"light sea green",lightskyblue:"light sky blue",lightslategray:"light slate gray",lightslategrey:"light slate gray",lightsteelblue:"light steel blue",lightyellow:"light yellow",lime:"lime",limegreen:"lime green",linen:"linen",magenta:"magenta",maroon:"maroon",mediumaquamarine:"medium aquamarine",mediumblue:"medium blue",mediumorchid:"medium orchid",mediumpurple:"medium purple",mediumseagreen:"medium sea green",mediumslateblue:"medium slate blue",mediumspringgreen:"medium spring green",mediumturquoise:"medium turquoise",mediumvioletred:"medium violet-red",midnightblue:"midnight blue",mintcream:"mint cream",mistyrose:"misty rose",moccasin:"moccasin",navajowhite:"navajo white",navy:"navy",oldlace:"old lace",olive:"olive",olivedrab:"olive drab",orange:"orange",orangered:"orange red",orchid:"orchid",palegoldenrod:"pale goldenrod",palegreen:"pale green",paleturquoise:"pale turquoise",palevioletred:"pale violet-red",papayawhip:"papaya whip",peachpuff:"peach puff",peru:"peru",pink:"pink",plum:"plum",powderblue:"powder blue",purple:"purple",red:"red",rosybrown:"rosy brown",royalblue:"royal blue",saddlebrown:"saddle brown",salmon:"salmon",sandybrown:"sandy brown",seagreen:"sea green",seashell:"seashell",sienna:"sienna",silver:"silver",skyblue:"sky blue",slateblue:"slate blue",slategray:"slate gray",slategrey:"slate gray",snow:"snow",springgreen:"spring green",steelblue:"steel blue",tan:"tan",teal:"teal",thistle:"thistle",tomato:"tomato",transparent:"transparent",turquoise:"turquoise",violet:"violet",wheat:"wheat",white:"white",whitesmoke:"white smoke",yellow:"yellow",yellowgreen:"yellow green"}),"zh":true,"zh-tw":true,"uk":true,"tr":true,"th":true,"sv":true,"sl":true,"sk":true,"ru":true,"ro":true,"pt":true,"pt-pt":true,"pl":true,"nl":true,"nb":true,"ko":true,"kk":true,"ja":true,"it":true,"id":true,"hu":true,"hr":true,"he":true,"fr":true,"fi":true,"es":true,"el":true,"de":true,"da":true,"cs":true,"ca":true,"bg":true,"az":true,"ar":true}); diff --git a/lib/dojo/nls/colors.js.uncompressed.js b/lib/dojo/nls/colors.js.uncompressed.js deleted file mode 100644 index 038ceea..0000000 --- a/lib/dojo/nls/colors.js.uncompressed.js +++ /dev/null @@ -1,194 +0,0 @@ -define("dojo/nls/colors", { root: -//begin v1.x content -({ -// local representation of all CSS3 named colors, companion to dojo.colors. To be used where descriptive information -// is required for each color, such as a palette widget, and not for specifying color programatically. - -//Note: due to the SVG 1.0 spec additions, some of these are alternate spellings for the same color (e.g. gray / grey). -//TODO: should we be using unique rgb values as keys instead and avoid these duplicates, or rely on the caller to do the reverse mapping? -aliceblue: "alice blue", -antiquewhite: "antique white", -aqua: "aqua", -aquamarine: "aquamarine", -azure: "azure", -beige: "beige", -bisque: "bisque", -black: "black", -blanchedalmond: "blanched almond", -blue: "blue", -blueviolet: "blue-violet", -brown: "brown", -burlywood: "burlywood", -cadetblue: "cadet blue", -chartreuse: "chartreuse", -chocolate: "chocolate", -coral: "coral", -cornflowerblue: "cornflower blue", -cornsilk: "cornsilk", -crimson: "crimson", -cyan: "cyan", -darkblue: "dark blue", -darkcyan: "dark cyan", -darkgoldenrod: "dark goldenrod", -darkgray: "dark gray", -darkgreen: "dark green", -darkgrey: "dark gray", // same as darkgray -darkkhaki: "dark khaki", -darkmagenta: "dark magenta", -darkolivegreen: "dark olive green", -darkorange: "dark orange", -darkorchid: "dark orchid", -darkred: "dark red", -darksalmon: "dark salmon", -darkseagreen: "dark sea green", -darkslateblue: "dark slate blue", -darkslategray: "dark slate gray", -darkslategrey: "dark slate gray", // same as darkslategray -darkturquoise: "dark turquoise", -darkviolet: "dark violet", -deeppink: "deep pink", -deepskyblue: "deep sky blue", -dimgray: "dim gray", -dimgrey: "dim gray", // same as dimgray -dodgerblue: "dodger blue", -firebrick: "fire brick", -floralwhite: "floral white", -forestgreen: "forest green", -fuchsia: "fuchsia", -gainsboro: "gainsboro", -ghostwhite: "ghost white", -gold: "gold", -goldenrod: "goldenrod", -gray: "gray", -green: "green", -greenyellow: "green-yellow", -grey: "gray", // same as gray -honeydew: "honeydew", -hotpink: "hot pink", -indianred: "indian red", -indigo: "indigo", -ivory: "ivory", -khaki: "khaki", -lavender: "lavender", -lavenderblush: "lavender blush", -lawngreen: "lawn green", -lemonchiffon: "lemon chiffon", -lightblue: "light blue", -lightcoral: "light coral", -lightcyan: "light cyan", -lightgoldenrodyellow: "light goldenrod yellow", -lightgray: "light gray", -lightgreen: "light green", -lightgrey: "light gray", // same as lightgray -lightpink: "light pink", -lightsalmon: "light salmon", -lightseagreen: "light sea green", -lightskyblue: "light sky blue", -lightslategray: "light slate gray", -lightslategrey: "light slate gray", // same as lightslategray -lightsteelblue: "light steel blue", -lightyellow: "light yellow", -lime: "lime", -limegreen: "lime green", -linen: "linen", -magenta: "magenta", -maroon: "maroon", -mediumaquamarine: "medium aquamarine", -mediumblue: "medium blue", -mediumorchid: "medium orchid", -mediumpurple: "medium purple", -mediumseagreen: "medium sea green", -mediumslateblue: "medium slate blue", -mediumspringgreen: "medium spring green", -mediumturquoise: "medium turquoise", -mediumvioletred: "medium violet-red", -midnightblue: "midnight blue", -mintcream: "mint cream", -mistyrose: "misty rose", -moccasin: "moccasin", -navajowhite: "navajo white", -navy: "navy", -oldlace: "old lace", -olive: "olive", -olivedrab: "olive drab", -orange: "orange", -orangered: "orange red", -orchid: "orchid", -palegoldenrod: "pale goldenrod", -palegreen: "pale green", -paleturquoise: "pale turquoise", -palevioletred: "pale violet-red", -papayawhip: "papaya whip", -peachpuff: "peach puff", -peru: "peru", -pink: "pink", -plum: "plum", -powderblue: "powder blue", -purple: "purple", -red: "red", -rosybrown: "rosy brown", -royalblue: "royal blue", -saddlebrown: "saddle brown", -salmon: "salmon", -sandybrown: "sandy brown", -seagreen: "sea green", -seashell: "seashell", -sienna: "sienna", -silver: "silver", -skyblue: "sky blue", -slateblue: "slate blue", -slategray: "slate gray", -slategrey: "slate gray", // same as slategray -snow: "snow", -springgreen: "spring green", -steelblue: "steel blue", -tan: "tan", -teal: "teal", -thistle: "thistle", -tomato: "tomato", -transparent: "transparent", -turquoise: "turquoise", -violet: "violet", -wheat: "wheat", -white: "white", -whitesmoke: "white smoke", -yellow: "yellow", -yellowgreen: "yellow green" -}) -//end v1.x content -, -"zh": true, -"zh-tw": true, -"uk": true, -"tr": true, -"th": true, -"sv": true, -"sl": true, -"sk": true, -"ru": true, -"ro": true, -"pt": true, -"pt-pt": true, -"pl": true, -"nl": true, -"nb": true, -"ko": true, -"kk": true, -"ja": true, -"it": true, -"id": true, -"hu": true, -"hr": true, -"he": true, -"fr": true, -"fi": true, -"es": true, -"el": true, -"de": true, -"da": true, -"cs": true, -"ca": true, -"bg": true, -"az": true, -"ar": true -}); diff --git a/lib/dojo/nls/cs/colors.js b/lib/dojo/nls/cs/colors.js deleted file mode 100644 index d895368..0000000 --- a/lib/dojo/nls/cs/colors.js +++ /dev/null @@ -1,8 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/nls/cs/colors",({aliceblue:"modravá",antiquewhite:"krémově bílá",aqua:"azurová",aquamarine:"akvamarínová",azure:"bledě azurová",beige:"bledě béžová",bisque:"bledě oranžová",black:"černá",blanchedalmond:"mandlová",blue:"modrá",blueviolet:"modrofialová",brown:"červenohnědá",burlywood:"krémová",cadetblue:"šedomodrá",chartreuse:"chartreuska",chocolate:"hnědobéžová",coral:"korálová červená",cornflowerblue:"chrpově modrá",cornsilk:"režná",crimson:"karmínová",cyan:"azurová",darkblue:"tmavě modrá",darkcyan:"tmavě azurová",darkgoldenrod:"tmavě béžová",darkgray:"tmavě šedá",darkgreen:"tmavě zelená",darkgrey:"tmavě šedá",darkkhaki:"pískově hnědá",darkmagenta:"tmavě purpurová",darkolivegreen:"tmavě olivová",darkorange:"tmavě oranžová",darkorchid:"tmavě orchidejová",darkred:"tmavě červená",darksalmon:"tmavě lososová",darkseagreen:"tmavá mořská zelená",darkslateblue:"tmavá břidlicová modrá",darkslategray:"tmavá břidlicová šedá",darkslategrey:"tmavá břidlicová šedá",darkturquoise:"tmavě tyrkysová",darkviolet:"tmavě fialová",deeppink:"sytě růžová",deepskyblue:"sytá nebeská modrá",dimgray:"kouřově šedá",dimgrey:"kouřově šedá",dodgerblue:"jasně modrá",firebrick:"cihlová",floralwhite:"květinově bílá",forestgreen:"lesní zelená",fuchsia:"fuchsiová",gainsboro:"bledě šedá",ghostwhite:"modravě bílá",gold:"zlatá",goldenrod:"béžová",gray:"šedá",green:"zelená",greenyellow:"zelenožlutá",grey:"šedá",honeydew:"nazelenalá",hotpink:"jasně růžová",indianred:"indiánská červená",indigo:"indigově modrá",ivory:"slonovinová",khaki:"písková",lavender:"levandulová",lavenderblush:"levandulová růžová",lawngreen:"jasně zelená",lemonchiffon:"světle citrónová",lightblue:"světle modrá",lightcoral:"světle korálová",lightcyan:"světle azurová",lightgoldenrodyellow:"světle žlutá",lightgray:"světle šedá",lightgreen:"světle zelená",lightgrey:"světle šedá",lightpink:"světle růžová",lightsalmon:"světle lososová",lightseagreen:"světlá mořská zelená",lightskyblue:"světlá nebeská modrá",lightslategray:"světlá břidlicová šedá",lightslategrey:"světlá břidlicová šedá",lightsteelblue:"světlá ocelová modrá",lightyellow:"bledě žlutá",lime:"limetková",limegreen:"limetkově zelená",linen:"bledě šedobéžová",magenta:"purpurová",maroon:"kaštanová",mediumaquamarine:"střední akvamarínová",mediumblue:"středně modrá",mediumorchid:"středně orchidejová",mediumpurple:"středně nachová",mediumseagreen:"střední mořská zelená",mediumslateblue:"střední břidlicová modrá",mediumspringgreen:"střední jarní zelená",mediumturquoise:"středně tyrkysová",mediumvioletred:"středně fialovočervená",midnightblue:"temně modrá",mintcream:"mentolová",mistyrose:"růžovobílá",moccasin:"bledě krémová",navajowhite:"světle krémová",navy:"námořnická modrá",oldlace:"světle béžová",olive:"olivová",olivedrab:"khaki",orange:"oranžová",orangered:"oranžovočervená",orchid:"orchidejová",palegoldenrod:"bledě písková",palegreen:"bledě zelená",paleturquoise:"bledě tyrkysová",palevioletred:"bledě fialovočervená",papayawhip:"papájová",peachpuff:"broskvová",peru:"karamelová",pink:"růžová",plum:"švestková",powderblue:"bledě modrá",purple:"nachová",red:"červená",rosybrown:"růžovohnědá",royalblue:"královská modrá",saddlebrown:"hnědá",salmon:"lososová",sandybrown:"oranžovohnědá",seagreen:"mořská zelená",seashell:"lasturová",sienna:"siena",silver:"stříbrná",skyblue:"nebeská modrá",slateblue:"břidlicová modrá",slategray:"břidlicová šedá",slategrey:"břidlicová šedá",snow:"sněhobílá",springgreen:"jarní zelená",steelblue:"ocelová modrá",tan:"šedobéžová",teal:"šedozelená",thistle:"bodláková",tomato:"tomatová",transparent:"průhledná",turquoise:"tyrkysová",violet:"fialová",wheat:"zlatohnědá",white:"bílá",whitesmoke:"kouřově bílá",yellow:"žlutá",yellowgreen:"žlutozelená"})); diff --git a/lib/dojo/nls/cs/colors.js.uncompressed.js b/lib/dojo/nls/cs/colors.js.uncompressed.js deleted file mode 100644 index c625f21..0000000 --- a/lib/dojo/nls/cs/colors.js.uncompressed.js +++ /dev/null @@ -1,156 +0,0 @@ -define( -"dojo/nls/cs/colors", ({ -// local representation of all CSS3 named colors, companion to dojo.colors. To be used where descriptive information -// is required for each color, such as a palette widget, and not for specifying color programatically. - //Note: due to the SVG 1.0 spec additions, some of these are alternate spellings for the same color (e.g. gray / grey). - //TODO: should we be using unique rgb values as keys instead and avoid these duplicates, or rely on the caller to do the reverse mapping? - aliceblue: "modravá", - antiquewhite: "krémově bílá", - aqua: "azurová", - aquamarine: "akvamarínová", - azure: "bledě azurová", - beige: "bledě béžová", - bisque: "bledě oranžová", - black: "černá", - blanchedalmond: "mandlová", - blue: "modrá", - blueviolet: "modrofialová", - brown: "červenohnědá", - burlywood: "krémová", - cadetblue: "šedomodrá", - chartreuse: "chartreuska", - chocolate: "hnědobéžová", - coral: "korálová červená", - cornflowerblue: "chrpově modrá", - cornsilk: "režná", - crimson: "karmínová", - cyan: "azurová", - darkblue: "tmavě modrá", - darkcyan: "tmavě azurová", - darkgoldenrod: "tmavě béžová", - darkgray: "tmavě šedá", - darkgreen: "tmavě zelená", - darkgrey: "tmavě šedá", // same as darkgray - darkkhaki: "pískově hnědá", - darkmagenta: "tmavě purpurová", - darkolivegreen: "tmavě olivová", - darkorange: "tmavě oranžová", - darkorchid: "tmavě orchidejová", - darkred: "tmavě červená", - darksalmon: "tmavě lososová", - darkseagreen: "tmavá mořská zelená", - darkslateblue: "tmavá břidlicová modrá", - darkslategray: "tmavá břidlicová šedá", - darkslategrey: "tmavá břidlicová šedá", // same as darkslategray - darkturquoise: "tmavě tyrkysová", - darkviolet: "tmavě fialová", - deeppink: "sytě růžová", - deepskyblue: "sytá nebeská modrá", - dimgray: "kouřově šedá", - dimgrey: "kouřově šedá", // same as dimgray - dodgerblue: "jasně modrá", - firebrick: "cihlová", - floralwhite: "květinově bílá", - forestgreen: "lesní zelená", - fuchsia: "fuchsiová", - gainsboro: "bledě šedá", - ghostwhite: "modravě bílá", - gold: "zlatá", - goldenrod: "béžová", - gray: "šedá", - green: "zelená", - greenyellow: "zelenožlutá", - grey: "šedá", // same as gray - honeydew: "nazelenalá", - hotpink: "jasně růžová", - indianred: "indiánská červená", - indigo: "indigově modrá", - ivory: "slonovinová", - khaki: "písková", - lavender: "levandulová", - lavenderblush: "levandulová růžová", - lawngreen: "jasně zelená", - lemonchiffon: "světle citrónová", - lightblue: "světle modrá", - lightcoral: "světle korálová", - lightcyan: "světle azurová", - lightgoldenrodyellow: "světle žlutá", - lightgray: "světle šedá", - lightgreen: "světle zelená", - lightgrey: "světle šedá", // same as lightgray - lightpink: "světle růžová", - lightsalmon: "světle lososová", - lightseagreen: "světlá mořská zelená", - lightskyblue: "světlá nebeská modrá", - lightslategray: "světlá břidlicová šedá", - lightslategrey: "světlá břidlicová šedá", // same as lightslategray - lightsteelblue: "světlá ocelová modrá", - lightyellow: "bledě žlutá", - lime: "limetková", - limegreen: "limetkově zelená", - linen: "bledě šedobéžová", - magenta: "purpurová", - maroon: "kaštanová", - mediumaquamarine: "střední akvamarínová", - mediumblue: "středně modrá", - mediumorchid: "středně orchidejová", - mediumpurple: "středně nachová", - mediumseagreen: "střední mořská zelená", - mediumslateblue: "střední břidlicová modrá", - mediumspringgreen: "střední jarní zelená", - mediumturquoise: "středně tyrkysová", - mediumvioletred: "středně fialovočervená", - midnightblue: "temně modrá", - mintcream: "mentolová", - mistyrose: "růžovobílá", - moccasin: "bledě krémová", - navajowhite: "světle krémová", - navy: "námořnická modrá", - oldlace: "světle béžová", - olive: "olivová", - olivedrab: "khaki", - orange: "oranžová", - orangered: "oranžovočervená", - orchid: "orchidejová", - palegoldenrod: "bledě písková", - palegreen: "bledě zelená", - paleturquoise: "bledě tyrkysová", - palevioletred: "bledě fialovočervená", - papayawhip: "papájová", - peachpuff: "broskvová", - peru: "karamelová", - pink: "růžová", - plum: "švestková", - powderblue: "bledě modrá", - purple: "nachová", - red: "červená", - rosybrown: "růžovohnědá", - royalblue: "královská modrá", - saddlebrown: "hnědá", - salmon: "lososová", - sandybrown: "oranžovohnědá", - seagreen: "mořská zelená", - seashell: "lasturová", - sienna: "siena", - silver: "stříbrná", - skyblue: "nebeská modrá", - slateblue: "břidlicová modrá", - slategray: "břidlicová šedá", - slategrey: "břidlicová šedá", // same as slategray - snow: "sněhobílá", - springgreen: "jarní zelená", - steelblue: "ocelová modrá", - tan: "šedobéžová", - teal: "šedozelená", - thistle: "bodláková", - tomato: "tomatová", - transparent: "průhledná", - turquoise: "tyrkysová", - violet: "fialová", - wheat: "zlatohnědá", - white: "bílá", - whitesmoke: "kouřově bílá", - yellow: "žlutá", - yellowgreen: "žlutozelená" -}) -); diff --git a/lib/dojo/nls/da/colors.js b/lib/dojo/nls/da/colors.js deleted file mode 100644 index 2b4734d..0000000 --- a/lib/dojo/nls/da/colors.js +++ /dev/null @@ -1,8 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/nls/da/colors",({aliceblue:"babyblå",antiquewhite:"antikhvid",aqua:"akvablå",aquamarine:"akvamarin",azure:"azurblå",beige:"beige",bisque:"gulgrå",black:"sort",blanchedalmond:"blanceret mandel",blue:"blå",blueviolet:"blåviolet",brown:"brun",burlywood:"tobak",cadetblue:"kadetblå",chartreuse:"chartreuse",chocolate:"rust",coral:"koralrød",cornflowerblue:"kornblomstblå",cornsilk:"majs",crimson:"blodrød",cyan:"cyan",darkblue:"mørkeblå",darkcyan:"mørk cyan",darkgoldenrod:"mørk gyldenris",darkgray:"mørkegrå",darkgreen:"mørkegrøn",darkgrey:"mørkegrå",darkkhaki:"mørk khaki",darkmagenta:"mørk magenta",darkolivegreen:"mørk olivengrøn",darkorange:"mørk orange",darkorchid:"mørk orkide",darkred:"mørkerød",darksalmon:"mørk laksefarvet",darkseagreen:"mørk havgrøn",darkslateblue:"mørk skiferblå",darkslategray:"mørk skifergrå",darkslategrey:"mørk skifergrå",darkturquoise:"mørk turkis",darkviolet:"mørkelilla",deeppink:"dyb pink",deepskyblue:"dyb himmelblå",dimgray:"svag grå",dimgrey:"svag grå",dodgerblue:"dodgerblå",firebrick:"chamottesten",floralwhite:"blomsterhvid",forestgreen:"skovgrøn",fuchsia:"lyslilla",gainsboro:"gainsboro",ghostwhite:"spøgelseshvid",gold:"guld",goldenrod:"gyldenris",gray:"grå",green:"grøn",greenyellow:"grøngul",grey:"grå",honeydew:"honningdug",hotpink:"mørk rosa",indianred:"lys rødbrun",indigo:"indigo",ivory:"elfenben",khaki:"khaki",lavender:"lysviolet",lavenderblush:"lavendelrød",lawngreen:"græsgrøn",lemonchiffon:"citronfromage",lightblue:"lyseblå",lightcoral:"lys koralrød",lightcyan:"lys cyan",lightgoldenrodyellow:"lys gyldenrisgul",lightgray:"lysegrå",lightgreen:"lysegrøn",lightgrey:"lysegrå",lightpink:"lys pink",lightsalmon:"lys laksefarvet",lightseagreen:"lys havgrøn",lightskyblue:"lys himmelblå",lightslategray:"lys skifergrå",lightslategrey:"lys skifergrå",lightsteelblue:"lys stålblå",lightyellow:"lysegul",lime:"lime",limegreen:"limegrøn",linen:"lærred",magenta:"magenta",maroon:"rødbrun",mediumaquamarine:"mellem akvamarin",mediumblue:"mellemblå",mediumorchid:"mellem orkide",mediumpurple:"mellemlilla",mediumseagreen:"mellemhavgrøn",mediumslateblue:"mellemskiferblå",mediumspringgreen:"mellemforårsgrøn",mediumturquoise:"mellemturkis",mediumvioletred:"mellemviolet",midnightblue:"midnatsblå",mintcream:"pebermyntecreme",mistyrose:"blegrosa",moccasin:"fruesko",navajowhite:"navajo-hvid",navy:"marineblå",oldlace:"kniplingshvid",olive:"olivengrøn",olivedrab:"brungrøn",orange:"orange",orangered:"orangerød",orchid:"orkide",palegoldenrod:"bleg gyldenris",palegreen:"bleggrøn",paleturquoise:"bleg turkis",palevioletred:"blegviolet",papayawhip:"papaya",peachpuff:"fersken",peru:"peru",pink:"pink",plum:"blomme",powderblue:"pudderblå",purple:"lilla",red:"rød",rosybrown:"rosabrun",royalblue:"kongeblå",saddlebrown:"saddelbrun",salmon:"laksefarvet",sandybrown:"sandbrun",seagreen:"havgrøn",seashell:"muslingeskal",sienna:"sienna",silver:"sølv",skyblue:"himmelblå",slateblue:"skiferblå",slategray:"skifergrå",slategrey:"skifergrå",snow:"sne",springgreen:"forårsgrøn",steelblue:"metalblå",tan:"tan",teal:"blågrøn",thistle:"tidsel",tomato:"tomat",transparent:"transparent",turquoise:"turkis",violet:"lilla",wheat:"korngul",white:"hvid",whitesmoke:"hvid røg",yellow:"gul",yellowgreen:"gulgrøn"})); diff --git a/lib/dojo/nls/da/colors.js.uncompressed.js b/lib/dojo/nls/da/colors.js.uncompressed.js deleted file mode 100644 index 4b40f48..0000000 --- a/lib/dojo/nls/da/colors.js.uncompressed.js +++ /dev/null @@ -1,156 +0,0 @@ -define( -"dojo/nls/da/colors", ({ -// local representation of all CSS3 named colors, companion to dojo.colors. To be used where descriptive information -// is required for each color, such as a palette widget, and not for specifying color programatically. - //Note: due to the SVG 1.0 spec additions, some of these are alternate spellings for the same color (e.g. gray / grey). - //TODO: should we be using unique rgb values as keys instead and avoid these duplicates, or rely on the caller to do the reverse mapping? - aliceblue: "babyblå", - antiquewhite: "antikhvid", - aqua: "akvablå", - aquamarine: "akvamarin", - azure: "azurblå", - beige: "beige", - bisque: "gulgrå", - black: "sort", - blanchedalmond: "blanceret mandel", - blue: "blå", - blueviolet: "blåviolet", - brown: "brun", - burlywood: "tobak", - cadetblue: "kadetblå", - chartreuse: "chartreuse", - chocolate: "rust", - coral: "koralrød", - cornflowerblue: "kornblomstblå", - cornsilk: "majs", - crimson: "blodrød", - cyan: "cyan", - darkblue: "mørkeblå", - darkcyan: "mørk cyan", - darkgoldenrod: "mørk gyldenris", - darkgray: "mørkegrå", - darkgreen: "mørkegrøn", - darkgrey: "mørkegrå", // same as darkgray - darkkhaki: "mørk khaki", - darkmagenta: "mørk magenta", - darkolivegreen: "mørk olivengrøn", - darkorange: "mørk orange", - darkorchid: "mørk orkide", - darkred: "mørkerød", - darksalmon: "mørk laksefarvet", - darkseagreen: "mørk havgrøn", - darkslateblue: "mørk skiferblå", - darkslategray: "mørk skifergrå", - darkslategrey: "mørk skifergrå", // same as darkslategray - darkturquoise: "mørk turkis", - darkviolet: "mørkelilla", - deeppink: "dyb pink", - deepskyblue: "dyb himmelblå", - dimgray: "svag grå", - dimgrey: "svag grå", // same as dimgray - dodgerblue: "dodgerblå", - firebrick: "chamottesten", - floralwhite: "blomsterhvid", - forestgreen: "skovgrøn", - fuchsia: "lyslilla", - gainsboro: "gainsboro", - ghostwhite: "spøgelseshvid", - gold: "guld", - goldenrod: "gyldenris", - gray: "grå", - green: "grøn", - greenyellow: "grøngul", - grey: "grå", // same as gray - honeydew: "honningdug", - hotpink: "mørk rosa", - indianred: "lys rødbrun", - indigo: "indigo", - ivory: "elfenben", - khaki: "khaki", - lavender: "lysviolet", - lavenderblush: "lavendelrød", - lawngreen: "græsgrøn", - lemonchiffon: "citronfromage", - lightblue: "lyseblå", - lightcoral: "lys koralrød", - lightcyan: "lys cyan", - lightgoldenrodyellow: "lys gyldenrisgul", - lightgray: "lysegrå", - lightgreen: "lysegrøn", - lightgrey: "lysegrå", // same as lightgray - lightpink: "lys pink", - lightsalmon: "lys laksefarvet", - lightseagreen: "lys havgrøn", - lightskyblue: "lys himmelblå", - lightslategray: "lys skifergrå", - lightslategrey: "lys skifergrå", // same as lightslategray - lightsteelblue: "lys stålblå", - lightyellow: "lysegul", - lime: "lime", - limegreen: "limegrøn", - linen: "lærred", - magenta: "magenta", - maroon: "rødbrun", - mediumaquamarine: "mellem akvamarin", - mediumblue: "mellemblå", - mediumorchid: "mellem orkide", - mediumpurple: "mellemlilla", - mediumseagreen: "mellemhavgrøn", - mediumslateblue: "mellemskiferblå", - mediumspringgreen: "mellemforårsgrøn", - mediumturquoise: "mellemturkis", - mediumvioletred: "mellemviolet", - midnightblue: "midnatsblå", - mintcream: "pebermyntecreme", - mistyrose: "blegrosa", - moccasin: "fruesko", - navajowhite: "navajo-hvid", - navy: "marineblå", - oldlace: "kniplingshvid", - olive: "olivengrøn", - olivedrab: "brungrøn", - orange: "orange", - orangered: "orangerød", - orchid: "orkide", - palegoldenrod: "bleg gyldenris", - palegreen: "bleggrøn", - paleturquoise: "bleg turkis", - palevioletred: "blegviolet", - papayawhip: "papaya", - peachpuff: "fersken", - peru: "peru", - pink: "pink", - plum: "blomme", - powderblue: "pudderblå", - purple: "lilla", - red: "rød", - rosybrown: "rosabrun", - royalblue: "kongeblå", - saddlebrown: "saddelbrun", - salmon: "laksefarvet", - sandybrown: "sandbrun", - seagreen: "havgrøn", - seashell: "muslingeskal", - sienna: "sienna", - silver: "sølv", - skyblue: "himmelblå", - slateblue: "skiferblå", - slategray: "skifergrå", - slategrey: "skifergrå", // same as slategray - snow: "sne", - springgreen: "forårsgrøn", - steelblue: "metalblå", - tan: "tan", - teal: "blågrøn", - thistle: "tidsel", - tomato: "tomat", - transparent: "transparent", - turquoise: "turkis", - violet: "lilla", - wheat: "korngul", - white: "hvid", - whitesmoke: "hvid røg", - yellow: "gul", - yellowgreen: "gulgrøn" -}) -); diff --git a/lib/dojo/nls/de/colors.js b/lib/dojo/nls/de/colors.js deleted file mode 100644 index c89c171..0000000 --- a/lib/dojo/nls/de/colors.js +++ /dev/null @@ -1,8 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/nls/de/colors",({aliceblue:"Alice-blau",antiquewhite:"Antikweiß",aqua:"Wasserblau",aquamarine:"Aquamarin",azure:"Azur",beige:"Beige",bisque:"Bisquit",black:"Schwarz",blanchedalmond:"Mandelweiß",blue:"Blau",blueviolet:"Blauviolett",brown:"Braun",burlywood:"Burlywood",cadetblue:"Kadettenblau",chartreuse:"Helles Gelbgrün",chocolate:"Schokoladenbraun",coral:"Koralle",cornflowerblue:"Kornblumenblau",cornsilk:"Kornseide",crimson:"Karmesinrot",cyan:"Zyan",darkblue:"Dunkelblau",darkcyan:"Dunkelzyan",darkgoldenrod:"Dunkelgoldgelb",darkgray:"Dunkelgrau",darkgreen:"Dunkelgrün",darkgrey:"Dunkelgrau",darkkhaki:"Dunkelkhaki",darkmagenta:"Dunkelmagenta",darkolivegreen:"Dunkelolivgrün",darkorange:"Dunkelorange",darkorchid:"Dunkelorchidee",darkred:"Dunkelrot",darksalmon:"Dunkellachs",darkseagreen:"Dunkles Meergrün",darkslateblue:"Dunkelschieferblau",darkslategray:"Dunkelschiefergrau",darkslategrey:"Dunkelschiefergrau",darkturquoise:"Dunkeltürkis",darkviolet:"Dunkelviolett",deeppink:"Tiefrosa",deepskyblue:"Dunkles Himmelblau",dimgray:"Blassgrau",dimgrey:"Blassgrau",dodgerblue:"Dodger-blau",firebrick:"Schamottestein",floralwhite:"Blütenweiß",forestgreen:"Forstgrün",fuchsia:"Fuchsia",gainsboro:"Gainsboro",ghostwhite:"Geisterweiß",gold:"Gold",goldenrod:"Goldgelb",gray:"Grau",green:"Grün",greenyellow:"Grüngelb",grey:"Grau",honeydew:"Honigtau",hotpink:"Knallrosa",indianred:"Indischrot",indigo:"Indigoblau",ivory:"Elfenbein",khaki:"Khaki",lavender:"Lavendelblau",lavenderblush:"Lavendelhauch",lawngreen:"Grasgrün",lemonchiffon:"Zitronenchiffon",lightblue:"Hellblau",lightcoral:"Hellkoralle",lightcyan:"Hellzyan",lightgoldenrodyellow:"Hellgoldgelb",lightgray:"Hellgrau",lightgreen:"Hellgrün",lightgrey:"Hellgrau",lightpink:"Hellrosa",lightsalmon:"Helllachs",lightseagreen:"Helles Meergrün",lightskyblue:"Helles Himmelblau",lightslategray:"Helles Schiefergrau",lightslategrey:"Helles Schiefergrau",lightsteelblue:"Helles Stahlblau",lightyellow:"Hellgelb",lime:"Limone",limegreen:"Limonengrün",linen:"Leinen",magenta:"Magenta",maroon:"Kastanienbraun",mediumaquamarine:"Mittelaquamarin",mediumblue:"Mittelblau",mediumorchid:"Mittelorchidee",mediumpurple:"Mittelpurpur",mediumseagreen:"Mittelmeeresgrün",mediumslateblue:"Mittelschieferblau ",mediumspringgreen:"Mittelfrühlingsgrün",mediumturquoise:"Mitteltürkis ",mediumvioletred:"Mittelviolettrot ",midnightblue:"Mitternachtblau",mintcream:"Mintcreme",mistyrose:"Blassrose",moccasin:"Mokassin",navajowhite:"Navajo-weiß",navy:"Marineblau",oldlace:"Alte Spitze",olive:"Oliv",olivedrab:"Olivgrau",orange:"Orange",orangered:"Orangerot",orchid:"Orchidee",palegoldenrod:"Blassgoldgelb",palegreen:"Blassgrün",paleturquoise:"Blasstürkis",palevioletred:"Blassviolettrot ",papayawhip:"Papayacreme",peachpuff:"Pfirsich",peru:"Peru",pink:"Rosa",plum:"Pflaume",powderblue:"Pulverblau",purple:"Purpurrot",red:"Rot",rosybrown:"Rosigbraun",royalblue:"Königsblau",saddlebrown:"Sattelbraun",salmon:"Lachs",sandybrown:"Sandbraun",seagreen:"Meeresgrün",seashell:"Muschelweiß",sienna:"Sienna",silver:"Silbergrau",skyblue:"Himmelblau",slateblue:"Schieferblau",slategray:"Schiefergrau",slategrey:"Schiefergrau",snow:"Schneeweiß",springgreen:"Frühlingsgrün",steelblue:"Stahlblau",tan:"Hautfarben",teal:"Smaragdgrün",thistle:"Distel",tomato:"Tomatenrot",transparent:"Transparent",turquoise:"Türkis",violet:"Violett",wheat:"Weizen",white:"Weiß",whitesmoke:"Rauchweiß",yellow:"Gelb",yellowgreen:"Gelbgrün"})); diff --git a/lib/dojo/nls/de/colors.js.uncompressed.js b/lib/dojo/nls/de/colors.js.uncompressed.js deleted file mode 100644 index 8d376c4..0000000 --- a/lib/dojo/nls/de/colors.js.uncompressed.js +++ /dev/null @@ -1,156 +0,0 @@ -define( -"dojo/nls/de/colors", ({ -// local representation of all CSS3 named colors, companion to dojo.colors. To be used where descriptive information -// is required for each color, such as a palette widget, and not for specifying color programatically. - //Note: due to the SVG 1.0 spec additions, some of these are alternate spellings for the same color (e.g. gray / grey). - //TODO: should we be using unique rgb values as keys instead and avoid these duplicates, or rely on the caller to do the reverse mapping? - aliceblue: "Alice-blau", - antiquewhite: "Antikweiß", - aqua: "Wasserblau", - aquamarine: "Aquamarin", - azure: "Azur", - beige: "Beige", - bisque: "Bisquit", - black: "Schwarz", - blanchedalmond: "Mandelweiß", - blue: "Blau", - blueviolet: "Blauviolett", - brown: "Braun", - burlywood: "Burlywood", - cadetblue: "Kadettenblau", - chartreuse: "Helles Gelbgrün", - chocolate: "Schokoladenbraun", - coral: "Koralle", - cornflowerblue: "Kornblumenblau", - cornsilk: "Kornseide", - crimson: "Karmesinrot", - cyan: "Zyan", - darkblue: "Dunkelblau", - darkcyan: "Dunkelzyan", - darkgoldenrod: "Dunkelgoldgelb", - darkgray: "Dunkelgrau", - darkgreen: "Dunkelgrün", - darkgrey: "Dunkelgrau", // same as darkgray - darkkhaki: "Dunkelkhaki", - darkmagenta: "Dunkelmagenta", - darkolivegreen: "Dunkelolivgrün", - darkorange: "Dunkelorange", - darkorchid: "Dunkelorchidee", - darkred: "Dunkelrot", - darksalmon: "Dunkellachs", - darkseagreen: "Dunkles Meergrün", - darkslateblue: "Dunkelschieferblau", - darkslategray: "Dunkelschiefergrau", - darkslategrey: "Dunkelschiefergrau", // same as darkslategray - darkturquoise: "Dunkeltürkis", - darkviolet: "Dunkelviolett", - deeppink: "Tiefrosa", - deepskyblue: "Dunkles Himmelblau", - dimgray: "Blassgrau", - dimgrey: "Blassgrau", // same as dimgray - dodgerblue: "Dodger-blau", - firebrick: "Schamottestein", - floralwhite: "Blütenweiß", - forestgreen: "Forstgrün", - fuchsia: "Fuchsia", - gainsboro: "Gainsboro", - ghostwhite: "Geisterweiß", - gold: "Gold", - goldenrod: "Goldgelb", - gray: "Grau", - green: "Grün", - greenyellow: "Grüngelb", - grey: "Grau", // same as gray - honeydew: "Honigtau", - hotpink: "Knallrosa", - indianred: "Indischrot", - indigo: "Indigoblau", - ivory: "Elfenbein", - khaki: "Khaki", - lavender: "Lavendelblau", - lavenderblush: "Lavendelhauch", - lawngreen: "Grasgrün", - lemonchiffon: "Zitronenchiffon", - lightblue: "Hellblau", - lightcoral: "Hellkoralle", - lightcyan: "Hellzyan", - lightgoldenrodyellow: "Hellgoldgelb", - lightgray: "Hellgrau", - lightgreen: "Hellgrün", - lightgrey: "Hellgrau", // same as lightgray - lightpink: "Hellrosa", - lightsalmon: "Helllachs", - lightseagreen: "Helles Meergrün", - lightskyblue: "Helles Himmelblau", - lightslategray: "Helles Schiefergrau", - lightslategrey: "Helles Schiefergrau", // same as lightslategray - lightsteelblue: "Helles Stahlblau", - lightyellow: "Hellgelb", - lime: "Limone", - limegreen: "Limonengrün", - linen: "Leinen", - magenta: "Magenta", - maroon: "Kastanienbraun", - mediumaquamarine: "Mittelaquamarin", - mediumblue: "Mittelblau", - mediumorchid: "Mittelorchidee", - mediumpurple: "Mittelpurpur", - mediumseagreen: "Mittelmeeresgrün", - mediumslateblue: "Mittelschieferblau ", - mediumspringgreen: "Mittelfrühlingsgrün", - mediumturquoise: "Mitteltürkis ", - mediumvioletred: "Mittelviolettrot ", - midnightblue: "Mitternachtblau", - mintcream: "Mintcreme", - mistyrose: "Blassrose", - moccasin: "Mokassin", - navajowhite: "Navajo-weiß", - navy: "Marineblau", - oldlace: "Alte Spitze", - olive: "Oliv", - olivedrab: "Olivgrau", - orange: "Orange", - orangered: "Orangerot", - orchid: "Orchidee", - palegoldenrod: "Blassgoldgelb", - palegreen: "Blassgrün", - paleturquoise: "Blasstürkis", - palevioletred: "Blassviolettrot ", - papayawhip: "Papayacreme", - peachpuff: "Pfirsich", - peru: "Peru", - pink: "Rosa", - plum: "Pflaume", - powderblue: "Pulverblau", - purple: "Purpurrot", - red: "Rot", - rosybrown: "Rosigbraun", - royalblue: "Königsblau", - saddlebrown: "Sattelbraun", - salmon: "Lachs", - sandybrown: "Sandbraun", - seagreen: "Meeresgrün", - seashell: "Muschelweiß", - sienna: "Sienna", - silver: "Silbergrau", - skyblue: "Himmelblau", - slateblue: "Schieferblau", - slategray: "Schiefergrau", - slategrey: "Schiefergrau", // same as slategray - snow: "Schneeweiß", - springgreen: "Frühlingsgrün", - steelblue: "Stahlblau", - tan: "Hautfarben", - teal: "Smaragdgrün", - thistle: "Distel", - tomato: "Tomatenrot", - transparent: "Transparent", - turquoise: "Türkis", - violet: "Violett", - wheat: "Weizen", - white: "Weiß", - whitesmoke: "Rauchweiß", - yellow: "Gelb", - yellowgreen: "Gelbgrün" -}) -); diff --git a/lib/dojo/nls/el/colors.js b/lib/dojo/nls/el/colors.js deleted file mode 100644 index 6c6b819..0000000 --- a/lib/dojo/nls/el/colors.js +++ /dev/null @@ -1,8 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/nls/el/colors",({aliceblue:"σιέλ",antiquewhite:"ξεθωριασμένο λευκό",aqua:"γαλάζιο",aquamarine:"γαλαζοπράσινο",azure:"μπλε του ουρανού",beige:"μπεζ",bisque:"σκούρο κρεμ",black:"μαύρο",blanchedalmond:"ζαχαρί",blue:"μπλε",blueviolet:"βιολετί",brown:"καφέ",burlywood:"καφέ του ξύλου",cadetblue:"μπλε του στρατού",chartreuse:"φωτεινό κιτρινοπράσινο",chocolate:"σοκολατί",coral:"κοραλί",cornflowerblue:"μεσαίο μπλε",cornsilk:"ασημί του καλαμποκιού",crimson:"βαθύ κόκκινο",cyan:"κυανό",darkblue:"σκούρο μπλε",darkcyan:"σκούρο κυανό",darkgoldenrod:"σκούρο χρυσοκίτρινο",darkgray:"σκούρο γκρι",darkgreen:"σκούρο πράσινο",darkgrey:"σκούρο γκρι",darkkhaki:"σκούρο χακί",darkmagenta:"σκούρο ματζέντα",darkolivegreen:"σκούρο πράσινο λαδί",darkorange:"σκούρο πορτοκαλί",darkorchid:"σκούρα ορχιδέα",darkred:"σκούρο κόκκινο",darksalmon:"σκούρο σομόν",darkseagreen:"σκούρο πράσινο της θάλασσας",darkslateblue:"σκούρο μεταλλικό μπλε",darkslategray:"σκούρο μεταλλικό γκρι",darkslategrey:"σκούρο μεταλλικό γκρι",darkturquoise:"σκούρο τυρκουάζ",darkviolet:"σκούρο βιολετί",deeppink:"βαθύ ροζ",deepskyblue:"βαθύ μπλε το ουρανού",dimgray:"αχνό γκρι",dimgrey:"αχνό γκρι",dodgerblue:"σκούρο ελεκτρίκ",firebrick:"κεραμιδί",floralwhite:"λευκό των ανθών",forestgreen:"πράσινο του δάσους",fuchsia:"φούξια",gainsboro:"γκρι σιέλ",ghostwhite:"άσπρο",gold:"χρυσαφί",goldenrod:"χρυσοκίτρινο",gray:"γκρι",green:"πράσινο",greenyellow:"πρασινοκίτρινο",grey:"γκρι",honeydew:"μελί",hotpink:"έντονο ροζ",indianred:"ινδικό κόκκινο",indigo:"λουλακί",ivory:"ιβουάρ",khaki:"χακί",lavender:"λίλα",lavenderblush:"μωβ λεβάντας",lawngreen:"σκούρο πράσινο",lemonchiffon:"λεμονί",lightblue:"ανοιχτό μπλε",lightcoral:"ανοιχτό κοραλί",lightcyan:"ανοιχτό κυανό",lightgoldenrodyellow:"ανοιχτό χρυσοκίτρινο",lightgray:"ανοιχτό γκρι",lightgreen:"ανοιχτό πράσινο",lightgrey:"ανοιχτό γκρι",lightpink:"ανοιχτό ροζ",lightsalmon:"ανοιχτό σομόν",lightseagreen:"ανοιχτό πράσινο της θάλασσας",lightskyblue:"ανοιχτό μπλε το ουρανού",lightslategray:"ανοιχτό μεταλλικό γκρι",lightslategrey:"ανοιχτό μεταλλικό γκρι",lightsteelblue:"ανοιχτό μπλε ατσαλιού",lightyellow:"ανοιχτό κίτρινο",lime:"λαχανί",limegreen:"πράσινο λαχανί",linen:"σπαγγί",magenta:"ματζέντα",maroon:"βυσσινί",mediumaquamarine:"μεσαίο γαλαζοπράσινο",mediumblue:"μεσαίο μπλε",mediumorchid:"μεσαία ορχιδέα",mediumpurple:"μεσαίο μωβ",mediumseagreen:"μεσαίο πράσινο της θάλασσας",mediumslateblue:"μεσαίο μεταλλικό μπλε",mediumspringgreen:"μεσαίο πράσινο της άνοιξης",mediumturquoise:"μεσαίο τυρκουάζ",mediumvioletred:"μεσαίο κόκκινο βιολετί",midnightblue:"πολύ σκούρο μπλε",mintcream:"βεραμάν",mistyrose:"τριανταφυλλί",moccasin:"μόκα",navajowhite:"άσπρο Ναβάχο",navy:"μπλε του ναυτικού",oldlace:"εκρού",olive:"πράσινο λαδί",olivedrab:"λαδί",orange:"πορτοκαλί",orangered:"πορτοκαλοκόκκινο",orchid:"ορχιδέα",palegoldenrod:"αχνό χρυσοκίτρινο",palegreen:"αχνό πράσινο",paleturquoise:"αχνό τυρκουάζ",palevioletred:"αχνό κόκκινο βιολετί",papayawhip:"αχνό ροζ",peachpuff:"ροδακινί",peru:"περού",pink:"ροζ",plum:"δαμασκηνί",powderblue:"αχνό μπλε",purple:"μωβ",red:"κόκκινο",rosybrown:"καστανό",royalblue:"έντονο μπλε",saddlebrown:"βαθύ καφέ",salmon:"σομόν",sandybrown:"μπεζ της άμμου",seagreen:"πράσινο της θάλασσας",seashell:"κοχύλι",sienna:"καφεκίτρινο",silver:"ασημί",skyblue:"μπλε του ουρανού",slateblue:"μεταλλικό μπλε",slategray:"μεταλλικό γκρι",slategrey:"μεταλλικό γκρι",snow:"χιονί",springgreen:"πράσινο της άνοιξης",steelblue:"μπλε ατσαλιού",tan:"ώχρα",teal:"πετρόλ",thistle:"μωβ βιολετί",tomato:"κόκκινο της ντομάτας",transparent:"διαφανές",turquoise:"τυρκουάζ",violet:"βιολετί",wheat:"σταρένιο",white:"λευκό",whitesmoke:"λευκός καπνός",yellow:"κίτρινο",yellowgreen:"κιτρινοπράσινο"})); diff --git a/lib/dojo/nls/el/colors.js.uncompressed.js b/lib/dojo/nls/el/colors.js.uncompressed.js deleted file mode 100644 index 8f4bc0e..0000000 --- a/lib/dojo/nls/el/colors.js.uncompressed.js +++ /dev/null @@ -1,156 +0,0 @@ -define( -"dojo/nls/el/colors", ({ -// local representation of all CSS3 named colors, companion to dojo.colors. To be used where descriptive information -// is required for each color, such as a palette widget, and not for specifying color programatically. - //Note: due to the SVG 1.0 spec additions, some of these are alternate spellings for the same color (e.g. gray / grey). - //TODO: should we be using unique rgb values as keys instead and avoid these duplicates, or rely on the caller to do the reverse mapping? - aliceblue: "σιέλ", - antiquewhite: "ξεθωριασμένο λευκό", - aqua: "γαλάζιο", - aquamarine: "γαλαζοπράσινο", - azure: "μπλε του ουρανού", - beige: "μπεζ", - bisque: "σκούρο κρεμ", - black: "μαύρο", - blanchedalmond: "ζαχαρί", - blue: "μπλε", - blueviolet: "βιολετί", - brown: "καφέ", - burlywood: "καφέ του ξύλου", - cadetblue: "μπλε του στρατού", - chartreuse: "φωτεινό κιτρινοπράσινο", - chocolate: "σοκολατί", - coral: "κοραλί", - cornflowerblue: "μεσαίο μπλε", - cornsilk: "ασημί του καλαμποκιού", - crimson: "βαθύ κόκκινο", - cyan: "κυανό", - darkblue: "σκούρο μπλε", - darkcyan: "σκούρο κυανό", - darkgoldenrod: "σκούρο χρυσοκίτρινο", - darkgray: "σκούρο γκρι", - darkgreen: "σκούρο πράσινο", - darkgrey: "σκούρο γκρι", // same as darkgray - darkkhaki: "σκούρο χακί", - darkmagenta: "σκούρο ματζέντα", - darkolivegreen: "σκούρο πράσινο λαδί", - darkorange: "σκούρο πορτοκαλί", - darkorchid: "σκούρα ορχιδέα", - darkred: "σκούρο κόκκινο", - darksalmon: "σκούρο σομόν", - darkseagreen: "σκούρο πράσινο της θάλασσας", - darkslateblue: "σκούρο μεταλλικό μπλε", - darkslategray: "σκούρο μεταλλικό γκρι", - darkslategrey: "σκούρο μεταλλικό γκρι", // same as darkslategray - darkturquoise: "σκούρο τυρκουάζ", - darkviolet: "σκούρο βιολετί", - deeppink: "βαθύ ροζ", - deepskyblue: "βαθύ μπλε το ουρανού", - dimgray: "αχνό γκρι", - dimgrey: "αχνό γκρι", // same as dimgray - dodgerblue: "σκούρο ελεκτρίκ", - firebrick: "κεραμιδί", - floralwhite: "λευκό των ανθών", - forestgreen: "πράσινο του δάσους", - fuchsia: "φούξια", - gainsboro: "γκρι σιέλ", - ghostwhite: "άσπρο", - gold: "χρυσαφί", - goldenrod: "χρυσοκίτρινο", - gray: "γκρι", - green: "πράσινο", - greenyellow: "πρασινοκίτρινο", - grey: "γκρι", // same as gray - honeydew: "μελί", - hotpink: "έντονο ροζ", - indianred: "ινδικό κόκκινο", - indigo: "λουλακί", - ivory: "ιβουάρ", - khaki: "χακί", - lavender: "λίλα", - lavenderblush: "μωβ λεβάντας", - lawngreen: "σκούρο πράσινο", - lemonchiffon: "λεμονί", - lightblue: "ανοιχτό μπλε", - lightcoral: "ανοιχτό κοραλί", - lightcyan: "ανοιχτό κυανό", - lightgoldenrodyellow: "ανοιχτό χρυσοκίτρινο", - lightgray: "ανοιχτό γκρι", - lightgreen: "ανοιχτό πράσινο", - lightgrey: "ανοιχτό γκρι", // same as lightgray - lightpink: "ανοιχτό ροζ", - lightsalmon: "ανοιχτό σομόν", - lightseagreen: "ανοιχτό πράσινο της θάλασσας", - lightskyblue: "ανοιχτό μπλε το ουρανού", - lightslategray: "ανοιχτό μεταλλικό γκρι", - lightslategrey: "ανοιχτό μεταλλικό γκρι", // same as lightslategray - lightsteelblue: "ανοιχτό μπλε ατσαλιού", - lightyellow: "ανοιχτό κίτρινο", - lime: "λαχανί", - limegreen: "πράσινο λαχανί", - linen: "σπαγγί", - magenta: "ματζέντα", - maroon: "βυσσινί", - mediumaquamarine: "μεσαίο γαλαζοπράσινο", - mediumblue: "μεσαίο μπλε", - mediumorchid: "μεσαία ορχιδέα", - mediumpurple: "μεσαίο μωβ", - mediumseagreen: "μεσαίο πράσινο της θάλασσας", - mediumslateblue: "μεσαίο μεταλλικό μπλε", - mediumspringgreen: "μεσαίο πράσινο της άνοιξης", - mediumturquoise: "μεσαίο τυρκουάζ", - mediumvioletred: "μεσαίο κόκκινο βιολετί", - midnightblue: "πολύ σκούρο μπλε", - mintcream: "βεραμάν", - mistyrose: "τριανταφυλλί", - moccasin: "μόκα", - navajowhite: "άσπρο Ναβάχο", - navy: "μπλε του ναυτικού", - oldlace: "εκρού", - olive: "πράσινο λαδί", - olivedrab: "λαδί", - orange: "πορτοκαλί", - orangered: "πορτοκαλοκόκκινο", - orchid: "ορχιδέα", - palegoldenrod: "αχνό χρυσοκίτρινο", - palegreen: "αχνό πράσινο", - paleturquoise: "αχνό τυρκουάζ", - palevioletred: "αχνό κόκκινο βιολετί", - papayawhip: "αχνό ροζ", - peachpuff: "ροδακινί", - peru: "περού", - pink: "ροζ", - plum: "δαμασκηνί", - powderblue: "αχνό μπλε", - purple: "μωβ", - red: "κόκκινο", - rosybrown: "καστανό", - royalblue: "έντονο μπλε", - saddlebrown: "βαθύ καφέ", - salmon: "σομόν", - sandybrown: "μπεζ της άμμου", - seagreen: "πράσινο της θάλασσας", - seashell: "κοχύλι", - sienna: "καφεκίτρινο", - silver: "ασημί", - skyblue: "μπλε του ουρανού", - slateblue: "μεταλλικό μπλε", - slategray: "μεταλλικό γκρι", - slategrey: "μεταλλικό γκρι", // same as slategray - snow: "χιονί", - springgreen: "πράσινο της άνοιξης", - steelblue: "μπλε ατσαλιού", - tan: "ώχρα", - teal: "πετρόλ", - thistle: "μωβ βιολετί", - tomato: "κόκκινο της ντομάτας", - transparent: "διαφανές", - turquoise: "τυρκουάζ", - violet: "βιολετί", - wheat: "σταρένιο", - white: "λευκό", - whitesmoke: "λευκός καπνός", - yellow: "κίτρινο", - yellowgreen: "κιτρινοπράσινο" -}) -); diff --git a/lib/dojo/nls/es/colors.js b/lib/dojo/nls/es/colors.js deleted file mode 100644 index a9d17a2..0000000 --- a/lib/dojo/nls/es/colors.js +++ /dev/null @@ -1,8 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/nls/es/colors",({aliceblue:"blanco azulado",antiquewhite:"blanco antiguo",aqua:"aguamarina",aquamarine:"aguamarina 2",azure:"blanco cielo",beige:"beige",bisque:"miel",black:"negro",blanchedalmond:"almendra pálido",blue:"azul",blueviolet:"azul violáceo",brown:"marrón",burlywood:"madera",cadetblue:"azul cadete",chartreuse:"verde pálido 2",chocolate:"chocolate",coral:"coral",cornflowerblue:"azul aciano",cornsilk:"crudo",crimson:"carmesí",cyan:"cian",darkblue:"azul oscuro",darkcyan:"cian oscuro",darkgoldenrod:"ocre oscuro",darkgray:"gris oscuro",darkgreen:"verde oscuro",darkgrey:"gris oscuro",darkkhaki:"caqui oscuro",darkmagenta:"magenta oscuro",darkolivegreen:"verde oliva oscuro",darkorange:"naranja oscuro",darkorchid:"orquídea oscuro",darkred:"rojo oscuro",darksalmon:"salmón oscuro",darkseagreen:"verde mar oscuro",darkslateblue:"azul pizarra oscuro",darkslategray:"gris pizarra oscuro",darkslategrey:"gris pizarra oscuro",darkturquoise:"turquesa oscuro",darkviolet:"violeta oscuro",deeppink:"rosa fuerte",deepskyblue:"azul cielo fuerte",dimgray:"gris marengo",dimgrey:"gris marengo",dodgerblue:"azul fuerte",firebrick:"teja",floralwhite:"blanco manteca",forestgreen:"verde pino",fuchsia:"fucsia",gainsboro:"azul gainsboro",ghostwhite:"blanco ligero",gold:"oro",goldenrod:"ocre",gray:"gris",green:"verde",greenyellow:"amarillo verdoso",grey:"gris",honeydew:"flor de rocío",hotpink:"rosa oscuro",indianred:"rojo teja",indigo:"añil",ivory:"marfil",khaki:"caqui",lavender:"lavanda",lavenderblush:"lavanda rosácea",lawngreen:"verde césped",lemonchiffon:"amarillo pastel",lightblue:"azul claro",lightcoral:"coral claro",lightcyan:"cian claro",lightgoldenrodyellow:"ocre claro",lightgray:"gris claro",lightgreen:"verde claro",lightgrey:"gris claro",lightpink:"rosa claro",lightsalmon:"salmón claro",lightseagreen:"verde mar claro",lightskyblue:"azul cielo claro",lightslategray:"gris pizarra claro",lightslategrey:"gris pizarra claro",lightsteelblue:"azul acero claro",lightyellow:"amarillo claro",lime:"lima",limegreen:"lima limón",linen:"blanco arena",magenta:"magenta",maroon:"granate",mediumaquamarine:"aguamarina medio",mediumblue:"azul medio",mediumorchid:"orquídea medio",mediumpurple:"púrpura medio",mediumseagreen:"verde mar medio",mediumslateblue:"azul pizarra medio",mediumspringgreen:"verde primavera medio",mediumturquoise:"turquesa medio",mediumvioletred:"rojo violáceo medio",midnightblue:"azul medianoche",mintcream:"crema menta",mistyrose:"rosa difuminado",moccasin:"arena",navajowhite:"blanco navajo",navy:"azul marino",oldlace:"encaje antiguo",olive:"verde oliva",olivedrab:"verde oliva pardusco",orange:"naranja",orangered:"rojo anaranjado",orchid:"orquídea",palegoldenrod:"ocre pálido",palegreen:"verde pálido",paleturquoise:"turquesa pálido",palevioletred:"rojo violáceo pálido",papayawhip:"papaya claro",peachpuff:"melocotón",peru:"perú",pink:"rosa",plum:"ciruela",powderblue:"azul suave",purple:"púrpura",red:"rojo",rosybrown:"marrón rosáceo",royalblue:"azul real",saddlebrown:"cuero",salmon:"salmón",sandybrown:"marrón arcilla",seagreen:"verde mar",seashell:"blanco marfil",sienna:"siena",silver:"plateado",skyblue:"azul cielo",slateblue:"azul pizarra",slategray:"gris pizarra",slategrey:"gris pizarra",snow:"nieve",springgreen:"verde fuerte",steelblue:"azul acero",tan:"canela",teal:"verde azulado",thistle:"cardo",tomato:"tomate",transparent:"transparente",turquoise:"turquesa",violet:"violeta",wheat:"trigo",white:"blanco",whitesmoke:"blanco ahumado",yellow:"amarillo",yellowgreen:"verde amarillento"})); diff --git a/lib/dojo/nls/es/colors.js.uncompressed.js b/lib/dojo/nls/es/colors.js.uncompressed.js deleted file mode 100644 index 121f351..0000000 --- a/lib/dojo/nls/es/colors.js.uncompressed.js +++ /dev/null @@ -1,156 +0,0 @@ -define( -"dojo/nls/es/colors", ({ -// local representation of all CSS3 named colors, companion to dojo.colors. To be used where descriptive information -// is required for each color, such as a palette widget, and not for specifying color programatically. - //Note: due to the SVG 1.0 spec additions, some of these are alternate spellings for the same color (e.g. gray / grey). - //TODO: should we be using unique rgb values as keys instead and avoid these duplicates, or rely on the caller to do the reverse mapping? - aliceblue: "blanco azulado", - antiquewhite: "blanco antiguo", - aqua: "aguamarina", - aquamarine: "aguamarina 2", - azure: "blanco cielo", - beige: "beige", - bisque: "miel", - black: "negro", - blanchedalmond: "almendra pálido", - blue: "azul", - blueviolet: "azul violáceo", - brown: "marrón", - burlywood: "madera", - cadetblue: "azul cadete", - chartreuse: "verde pálido 2", - chocolate: "chocolate", - coral: "coral", - cornflowerblue: "azul aciano", - cornsilk: "crudo", - crimson: "carmesí", - cyan: "cian", - darkblue: "azul oscuro", - darkcyan: "cian oscuro", - darkgoldenrod: "ocre oscuro", - darkgray: "gris oscuro", - darkgreen: "verde oscuro", - darkgrey: "gris oscuro", // same as darkgray - darkkhaki: "caqui oscuro", - darkmagenta: "magenta oscuro", - darkolivegreen: "verde oliva oscuro", - darkorange: "naranja oscuro", - darkorchid: "orquídea oscuro", - darkred: "rojo oscuro", - darksalmon: "salmón oscuro", - darkseagreen: "verde mar oscuro", - darkslateblue: "azul pizarra oscuro", - darkslategray: "gris pizarra oscuro", - darkslategrey: "gris pizarra oscuro", // same as darkslategray - darkturquoise: "turquesa oscuro", - darkviolet: "violeta oscuro", - deeppink: "rosa fuerte", - deepskyblue: "azul cielo fuerte", - dimgray: "gris marengo", - dimgrey: "gris marengo", // same as dimgray - dodgerblue: "azul fuerte", - firebrick: "teja", - floralwhite: "blanco manteca", - forestgreen: "verde pino", - fuchsia: "fucsia", - gainsboro: "azul gainsboro", - ghostwhite: "blanco ligero", - gold: "oro", - goldenrod: "ocre", - gray: "gris", - green: "verde", - greenyellow: "amarillo verdoso", - grey: "gris", // same as gray - honeydew: "flor de rocío", - hotpink: "rosa oscuro", - indianred: "rojo teja", - indigo: "añil", - ivory: "marfil", - khaki: "caqui", - lavender: "lavanda", - lavenderblush: "lavanda rosácea", - lawngreen: "verde césped", - lemonchiffon: "amarillo pastel", - lightblue: "azul claro", - lightcoral: "coral claro", - lightcyan: "cian claro", - lightgoldenrodyellow: "ocre claro", - lightgray: "gris claro", - lightgreen: "verde claro", - lightgrey: "gris claro", // same as lightgray - lightpink: "rosa claro", - lightsalmon: "salmón claro", - lightseagreen: "verde mar claro", - lightskyblue: "azul cielo claro", - lightslategray: "gris pizarra claro", - lightslategrey: "gris pizarra claro", // same as lightslategray - lightsteelblue: "azul acero claro", - lightyellow: "amarillo claro", - lime: "lima", - limegreen: "lima limón", - linen: "blanco arena", - magenta: "magenta", - maroon: "granate", - mediumaquamarine: "aguamarina medio", - mediumblue: "azul medio", - mediumorchid: "orquídea medio", - mediumpurple: "púrpura medio", - mediumseagreen: "verde mar medio", - mediumslateblue: "azul pizarra medio", - mediumspringgreen: "verde primavera medio", - mediumturquoise: "turquesa medio", - mediumvioletred: "rojo violáceo medio", - midnightblue: "azul medianoche", - mintcream: "crema menta", - mistyrose: "rosa difuminado", - moccasin: "arena", - navajowhite: "blanco navajo", - navy: "azul marino", - oldlace: "encaje antiguo", - olive: "verde oliva", - olivedrab: "verde oliva pardusco", - orange: "naranja", - orangered: "rojo anaranjado", - orchid: "orquídea", - palegoldenrod: "ocre pálido", - palegreen: "verde pálido", - paleturquoise: "turquesa pálido", - palevioletred: "rojo violáceo pálido", - papayawhip: "papaya claro", - peachpuff: "melocotón", - peru: "perú", - pink: "rosa", - plum: "ciruela", - powderblue: "azul suave", - purple: "púrpura", - red: "rojo", - rosybrown: "marrón rosáceo", - royalblue: "azul real", - saddlebrown: "cuero", - salmon: "salmón", - sandybrown: "marrón arcilla", - seagreen: "verde mar", - seashell: "blanco marfil", - sienna: "siena", - silver: "plateado", - skyblue: "azul cielo", - slateblue: "azul pizarra", - slategray: "gris pizarra", - slategrey: "gris pizarra", // same as slategray - snow: "nieve", - springgreen: "verde fuerte", - steelblue: "azul acero", - tan: "canela", - teal: "verde azulado", - thistle: "cardo", - tomato: "tomate", - transparent: "transparente", - turquoise: "turquesa", - violet: "violeta", - wheat: "trigo", - white: "blanco", - whitesmoke: "blanco ahumado", - yellow: "amarillo", - yellowgreen: "verde amarillento" -}) -); diff --git a/lib/dojo/nls/fi/colors.js b/lib/dojo/nls/fi/colors.js deleted file mode 100644 index f2b2c12..0000000 --- a/lib/dojo/nls/fi/colors.js +++ /dev/null @@ -1,8 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/nls/fi/colors",({aliceblue:"vaaleanharmaansininen",antiquewhite:"antiikinvalkoinen",aqua:"sinivihreä",aquamarine:"vedenvihreä",azure:"taivaansininen",beige:"vaaleanruskea",bisque:"vaaleanruskea",black:"musta",blanchedalmond:"kuorittu manteli",blue:"sininen",blueviolet:"sinivioletti",brown:"ruskea",burlywood:"puunruskea",cadetblue:"meren vihreä",chartreuse:"kellanvihreä",chocolate:"suklaanruskea",coral:"koralli",cornflowerblue:"syvänsininen",cornsilk:"maissinkeltainen",crimson:"karmiininpunainen",cyan:"syaani",darkblue:"tummansininen",darkcyan:"tumma turkoosi",darkgoldenrod:"tumma kultapiisku",darkgray:"tummanharmaa",darkgreen:"tummanvihreä",darkgrey:"tummanharmaa",darkkhaki:"tumma khaki",darkmagenta:"tumma magenta",darkolivegreen:"tummanoliivinvihreä",darkorange:"tummanoranssi",darkorchid:"tumma orkidea",darkred:"tummanpunainen",darksalmon:"tumma lohenpunainen",darkseagreen:"tumma merenvihreä",darkslateblue:"tumma siniharmaa",darkslategray:"tummanharmaa",darkslategrey:"tummanharmaa",darkturquoise:"tumma turkoosi",darkviolet:"tummanvioletti",deeppink:"syvä vaaleanpunainen",deepskyblue:"tumma taivaansininen",dimgray:"himmeänharmaa",dimgrey:"himmeänharmaa",dodgerblue:"Dodger-sininen",firebrick:"poltetun tiilen punainen",floralwhite:"kukanvalkoinen",forestgreen:"metsänvihreä",fuchsia:"purppura",gainsboro:"gainsboro",ghostwhite:"lakananvalkoinen",gold:"kulta",goldenrod:"kullanruskea",gray:"harmaa",green:"vihreä",greenyellow:"vihreänkeltainen",grey:"harmaa",honeydew:"hunajameloninvihreä",hotpink:"pinkki",indianred:"kirkkaanpunainen",indigo:"indigo",ivory:"norsunluu",khaki:"khaki",lavender:"laventeli",lavenderblush:"laventelinpunainen",lawngreen:"ruohonvihreä",lemonchiffon:"sitruunankeltainen",lightblue:"vaaleansininen",lightcoral:"vaalea koralli",lightcyan:"vaalea syaani",lightgoldenrodyellow:"vaalea kultapiiskunkeltainen",lightgray:"vaaleanharmaa",lightgreen:"vaaleanvihreä",lightgrey:"vaaleanharmaa",lightpink:"vaaleanpunainen",lightsalmon:"vaalea lohenpunainen",lightseagreen:"vaalea merenvihreä",lightskyblue:"vaalea taivaansininen",lightslategray:"vaaleanharmaa",lightslategrey:"vaaleanharmaa",lightsteelblue:"vaalea teräksensininen",lightyellow:"vaaleankeltainen",lime:"vaaleanvihreä",limegreen:"limetinvihreä",linen:"pellavanvaalea",magenta:"magenta",maroon:"kastanjanruskea",mediumaquamarine:"keskivaalea vedenvihreä",mediumblue:"keskisininen",mediumorchid:"keskivaalea orkidea",mediumpurple:"keskivaalea violetti",mediumseagreen:"keskivaalea merenvihreä",mediumslateblue:"keskivaalea siniharmaa",mediumspringgreen:"keskivaalea keväänvihreä",mediumturquoise:"keskivaalea turkoosi",mediumvioletred:"keskivaalea lila",midnightblue:"yönsininen",mintcream:"minttukreemi",mistyrose:"utuinen ruusu",moccasin:"nahanruskea",navajowhite:"navajonvalkoinen",navy:"laivastonsininen",oldlace:"vanha pitsi",olive:"oliivinvihreä",olivedrab:"oliivinruskea",orange:"oranssi",orangered:"oranssinpunainen",orchid:"orkidea",palegoldenrod:"haalea kultapiisku",palegreen:"haalea vihreä",paleturquoise:"haalea turkoosi",palevioletred:"haalea lila",papayawhip:"papaijavaahto",peachpuff:"persikka",peru:"peru",pink:"vaaleanpunainen",plum:"luumunpunainen",powderblue:"harmaansininen",purple:"violetti",red:"punainen",rosybrown:"punertavanruskea",royalblue:"syvänsininen",saddlebrown:"satulanruskea",salmon:"lohenpunainen",sandybrown:"hiekanruskea",seagreen:"merenvihreä",seashell:"simpukankuori",sienna:"siena",silver:"hopea",skyblue:"taivaansininen",slateblue:"savensininen",slategray:"savenharmaa",slategrey:"savenharmaa",snow:"lumivalkoinen",springgreen:"keväänvihreä",steelblue:"teräksensininen",tan:"kellanruskea",teal:"sinivihreä",thistle:"ohdake",tomato:"tomaatinpunainen",transparent:"läpinäkyvä",turquoise:"turkoosi",violet:"violetti",wheat:"vehnänkeltainen",white:"valkoinen",whitesmoke:"savunvalkea",yellow:"keltainen",yellowgreen:"kellanvihreä"})); diff --git a/lib/dojo/nls/fi/colors.js.uncompressed.js b/lib/dojo/nls/fi/colors.js.uncompressed.js deleted file mode 100644 index 935c23b..0000000 --- a/lib/dojo/nls/fi/colors.js.uncompressed.js +++ /dev/null @@ -1,156 +0,0 @@ -define( -"dojo/nls/fi/colors", ({ -// local representation of all CSS3 named colors, companion to dojo.colors. To be used where descriptive information -// is required for each color, such as a palette widget, and not for specifying color programatically. - //Note: due to the SVG 1.0 spec additions, some of these are alternate spellings for the same color (e.g. gray / grey). - //TODO: should we be using unique rgb values as keys instead and avoid these duplicates, or rely on the caller to do the reverse mapping? - aliceblue: "vaaleanharmaansininen", - antiquewhite: "antiikinvalkoinen", - aqua: "sinivihreä", - aquamarine: "vedenvihreä", - azure: "taivaansininen", - beige: "vaaleanruskea", - bisque: "vaaleanruskea", - black: "musta", - blanchedalmond: "kuorittu manteli", - blue: "sininen", - blueviolet: "sinivioletti", - brown: "ruskea", - burlywood: "puunruskea", - cadetblue: "meren vihreä", - chartreuse: "kellanvihreä", - chocolate: "suklaanruskea", - coral: "koralli", - cornflowerblue: "syvänsininen", - cornsilk: "maissinkeltainen", - crimson: "karmiininpunainen", - cyan: "syaani", - darkblue: "tummansininen", - darkcyan: "tumma turkoosi", - darkgoldenrod: "tumma kultapiisku", - darkgray: "tummanharmaa", - darkgreen: "tummanvihreä", - darkgrey: "tummanharmaa", // same as darkgray - darkkhaki: "tumma khaki", - darkmagenta: "tumma magenta", - darkolivegreen: "tummanoliivinvihreä", - darkorange: "tummanoranssi", - darkorchid: "tumma orkidea", - darkred: "tummanpunainen", - darksalmon: "tumma lohenpunainen", - darkseagreen: "tumma merenvihreä", - darkslateblue: "tumma siniharmaa", - darkslategray: "tummanharmaa", - darkslategrey: "tummanharmaa", // same as darkslategray - darkturquoise: "tumma turkoosi", - darkviolet: "tummanvioletti", - deeppink: "syvä vaaleanpunainen", - deepskyblue: "tumma taivaansininen", - dimgray: "himmeänharmaa", - dimgrey: "himmeänharmaa", // same as dimgray - dodgerblue: "Dodger-sininen", - firebrick: "poltetun tiilen punainen", - floralwhite: "kukanvalkoinen", - forestgreen: "metsänvihreä", - fuchsia: "purppura", - gainsboro: "gainsboro", - ghostwhite: "lakananvalkoinen", - gold: "kulta", - goldenrod: "kullanruskea", - gray: "harmaa", - green: "vihreä", - greenyellow: "vihreänkeltainen", - grey: "harmaa", // same as gray - honeydew: "hunajameloninvihreä", - hotpink: "pinkki", - indianred: "kirkkaanpunainen", - indigo: "indigo", - ivory: "norsunluu", - khaki: "khaki", - lavender: "laventeli", - lavenderblush: "laventelinpunainen", - lawngreen: "ruohonvihreä", - lemonchiffon: "sitruunankeltainen", - lightblue: "vaaleansininen", - lightcoral: "vaalea koralli", - lightcyan: "vaalea syaani", - lightgoldenrodyellow: "vaalea kultapiiskunkeltainen", - lightgray: "vaaleanharmaa", - lightgreen: "vaaleanvihreä", - lightgrey: "vaaleanharmaa", // same as lightgray - lightpink: "vaaleanpunainen", - lightsalmon: "vaalea lohenpunainen", - lightseagreen: "vaalea merenvihreä", - lightskyblue: "vaalea taivaansininen", - lightslategray: "vaaleanharmaa", - lightslategrey: "vaaleanharmaa", // same as lightslategray - lightsteelblue: "vaalea teräksensininen", - lightyellow: "vaaleankeltainen", - lime: "vaaleanvihreä", - limegreen: "limetinvihreä", - linen: "pellavanvaalea", - magenta: "magenta", - maroon: "kastanjanruskea", - mediumaquamarine: "keskivaalea vedenvihreä", - mediumblue: "keskisininen", - mediumorchid: "keskivaalea orkidea", - mediumpurple: "keskivaalea violetti", - mediumseagreen: "keskivaalea merenvihreä", - mediumslateblue: "keskivaalea siniharmaa", - mediumspringgreen: "keskivaalea keväänvihreä", - mediumturquoise: "keskivaalea turkoosi", - mediumvioletred: "keskivaalea lila", - midnightblue: "yönsininen", - mintcream: "minttukreemi", - mistyrose: "utuinen ruusu", - moccasin: "nahanruskea", - navajowhite: "navajonvalkoinen", - navy: "laivastonsininen", - oldlace: "vanha pitsi", - olive: "oliivinvihreä", - olivedrab: "oliivinruskea", - orange: "oranssi", - orangered: "oranssinpunainen", - orchid: "orkidea", - palegoldenrod: "haalea kultapiisku", - palegreen: "haalea vihreä", - paleturquoise: "haalea turkoosi", - palevioletred: "haalea lila", - papayawhip: "papaijavaahto", - peachpuff: "persikka", - peru: "peru", - pink: "vaaleanpunainen", - plum: "luumunpunainen", - powderblue: "harmaansininen", - purple: "violetti", - red: "punainen", - rosybrown: "punertavanruskea", - royalblue: "syvänsininen", - saddlebrown: "satulanruskea", - salmon: "lohenpunainen", - sandybrown: "hiekanruskea", - seagreen: "merenvihreä", - seashell: "simpukankuori", - sienna: "siena", - silver: "hopea", - skyblue: "taivaansininen", - slateblue: "savensininen", - slategray: "savenharmaa", - slategrey: "savenharmaa", // same as slategray - snow: "lumivalkoinen", - springgreen: "keväänvihreä", - steelblue: "teräksensininen", - tan: "kellanruskea", - teal: "sinivihreä", - thistle: "ohdake", - tomato: "tomaatinpunainen", - transparent: "läpinäkyvä", - turquoise: "turkoosi", - violet: "violetti", - wheat: "vehnänkeltainen", - white: "valkoinen", - whitesmoke: "savunvalkea", - yellow: "keltainen", - yellowgreen: "kellanvihreä" -}) -); diff --git a/lib/dojo/nls/fr/colors.js b/lib/dojo/nls/fr/colors.js deleted file mode 100644 index 5a0c89f..0000000 --- a/lib/dojo/nls/fr/colors.js +++ /dev/null @@ -1,8 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/nls/fr/colors",({aliceblue:"bleu gris",antiquewhite:"blanc antique",aqua:"bleu-vert",aquamarine:"aigue-marine",azure:"bleu azur",beige:"beige",bisque:"beige rosé",black:"noir",blanchedalmond:"coquille d'œuf",blue:"bleu",blueviolet:"bleu-violet",brown:"brun",burlywood:"bois précieux",cadetblue:"bleu pétrole",chartreuse:"vert vif",chocolate:"chocolat",coral:"corail",cornflowerblue:"bleuet",cornsilk:"vanille",crimson:"cramoisi",cyan:"cyan",darkblue:"bleu foncé",darkcyan:"cyan foncé",darkgoldenrod:"jaune paille foncé",darkgray:"gris foncé",darkgreen:"vert foncé",darkgrey:"gris foncé",darkkhaki:"kaki foncé",darkmagenta:"magenta foncé",darkolivegreen:"olive foncé",darkorange:"orange foncé",darkorchid:"lilas foncé",darkred:"rouge foncé",darksalmon:"saumon foncé",darkseagreen:"vert d'eau foncé",darkslateblue:"bleu ardoise foncé",darkslategray:"gris ardoise foncé",darkslategrey:"gris ardoise foncé",darkturquoise:"turquoise foncé",darkviolet:"violet foncé",deeppink:"rose soutenu",deepskyblue:"bleu ciel soutenu",dimgray:"gris soutenu",dimgrey:"gris soutenu",dodgerblue:"bleu France",firebrick:"rouge brique",floralwhite:"lys",forestgreen:"vert sapin",fuchsia:"fuchsia",gainsboro:"gris souris",ghostwhite:"blanc laiteux",gold:"or",goldenrod:"jaune paille",gray:"gris",green:"vert",greenyellow:"vert-jaune",grey:"gris",honeydew:"opalin",hotpink:"rose intense",indianred:"rose indien",indigo:"indigo",ivory:"ivoire",khaki:"kaki",lavender:"lavande",lavenderblush:"lavandin",lawngreen:"vert prairie",lemonchiffon:"mousse de citron",lightblue:"bleu clair",lightcoral:"corail clair",lightcyan:"cyan clair",lightgoldenrodyellow:"jaune paille clair",lightgray:"gris clair",lightgreen:"vert clair",lightgrey:"gris clair",lightpink:"rose clair",lightsalmon:"saumon clair",lightseagreen:"vert d'eau clair",lightskyblue:"bleu ciel clair",lightslategray:"gris ardoise clair",lightslategrey:"gris ardoise clair",lightsteelblue:"bleu acier clair",lightyellow:"jaune clair",lime:"vert citron",limegreen:"citron vert",linen:"écru",magenta:"magenta",maroon:"marron",mediumaquamarine:"aigue-marine moyen",mediumblue:"bleu moyen",mediumorchid:"lilas moyen",mediumpurple:"pourpre moyen",mediumseagreen:"vert d'eau moyen",mediumslateblue:"bleu ardoise moyen",mediumspringgreen:"vert printemps moyen",mediumturquoise:"turquoise moyen",mediumvioletred:"rouge violacé moyen",midnightblue:"bleu nuit",mintcream:"crème de menthe",mistyrose:"rose pâle",moccasin:"chamois",navajowhite:"chair",navy:"bleu marine",oldlace:"blanc cassé",olive:"olive",olivedrab:"brun verdâtre",orange:"orange",orangered:"rouge orangé",orchid:"lilas",palegoldenrod:"jaune paille pâle",palegreen:"vert pâle",paleturquoise:"turquoise pâle",palevioletred:"rouge violacé pâle",papayawhip:"crème de papaye",peachpuff:"pêche",peru:"caramel",pink:"rose",plum:"prune",powderblue:"bleu de smalt",purple:"pourpre",red:"rouge",rosybrown:"vieux rose",royalblue:"bleu roi",saddlebrown:"brun cuir",salmon:"saumon",sandybrown:"sable",seagreen:"vert d'eau",seashell:"coquillage",sienna:"terre de sienne",silver:"argent",skyblue:"bleu ciel",slateblue:"bleu ardoise",slategray:"gris ardoise",slategrey:"gris ardoise",snow:"neige",springgreen:"vert printemps",steelblue:"bleu acier",tan:"grège",teal:"sarcelle",thistle:"chardon",tomato:"tomate",transparent:"transparent",turquoise:"turquoise",violet:"violet",wheat:"blé",white:"blanc",whitesmoke:"blanc cendré",yellow:"jaune",yellowgreen:"vert jaunâtre"})); diff --git a/lib/dojo/nls/fr/colors.js.uncompressed.js b/lib/dojo/nls/fr/colors.js.uncompressed.js deleted file mode 100644 index e04b512..0000000 --- a/lib/dojo/nls/fr/colors.js.uncompressed.js +++ /dev/null @@ -1,156 +0,0 @@ -define( -"dojo/nls/fr/colors", ({ -// local representation of all CSS3 named colors, companion to dojo.colors. To be used where descriptive information -// is required for each color, such as a palette widget, and not for specifying color programatically. - //Note: due to the SVG 1.0 spec additions, some of these are alternate spellings for the same color (e.g. gray / grey). - //TODO: should we be using unique rgb values as keys instead and avoid these duplicates, or rely on the caller to do the reverse mapping? - aliceblue: "bleu gris", - antiquewhite: "blanc antique", - aqua: "bleu-vert", - aquamarine: "aigue-marine", - azure: "bleu azur", - beige: "beige", - bisque: "beige rosé", - black: "noir", - blanchedalmond: "coquille d'œuf", - blue: "bleu", - blueviolet: "bleu-violet", - brown: "brun", - burlywood: "bois précieux", - cadetblue: "bleu pétrole", - chartreuse: "vert vif", - chocolate: "chocolat", - coral: "corail", - cornflowerblue: "bleuet", - cornsilk: "vanille", - crimson: "cramoisi", - cyan: "cyan", - darkblue: "bleu foncé", - darkcyan: "cyan foncé", - darkgoldenrod: "jaune paille foncé", - darkgray: "gris foncé", - darkgreen: "vert foncé", - darkgrey: "gris foncé", // same as darkgray - darkkhaki: "kaki foncé", - darkmagenta: "magenta foncé", - darkolivegreen: "olive foncé", - darkorange: "orange foncé", - darkorchid: "lilas foncé", - darkred: "rouge foncé", - darksalmon: "saumon foncé", - darkseagreen: "vert d'eau foncé", - darkslateblue: "bleu ardoise foncé", - darkslategray: "gris ardoise foncé", - darkslategrey: "gris ardoise foncé", // same as darkslategray - darkturquoise: "turquoise foncé", - darkviolet: "violet foncé", - deeppink: "rose soutenu", - deepskyblue: "bleu ciel soutenu", - dimgray: "gris soutenu", - dimgrey: "gris soutenu", // same as dimgray - dodgerblue: "bleu France", - firebrick: "rouge brique", - floralwhite: "lys", - forestgreen: "vert sapin", - fuchsia: "fuchsia", - gainsboro: "gris souris", - ghostwhite: "blanc laiteux", - gold: "or", - goldenrod: "jaune paille", - gray: "gris", - green: "vert", - greenyellow: "vert-jaune", - grey: "gris", // same as gray - honeydew: "opalin", - hotpink: "rose intense", - indianred: "rose indien", - indigo: "indigo", - ivory: "ivoire", - khaki: "kaki", - lavender: "lavande", - lavenderblush: "lavandin", - lawngreen: "vert prairie", - lemonchiffon: "mousse de citron", - lightblue: "bleu clair", - lightcoral: "corail clair", - lightcyan: "cyan clair", - lightgoldenrodyellow: "jaune paille clair", - lightgray: "gris clair", - lightgreen: "vert clair", - lightgrey: "gris clair", // same as lightgray - lightpink: "rose clair", - lightsalmon: "saumon clair", - lightseagreen: "vert d'eau clair", - lightskyblue: "bleu ciel clair", - lightslategray: "gris ardoise clair", - lightslategrey: "gris ardoise clair", // same as lightslategray - lightsteelblue: "bleu acier clair", - lightyellow: "jaune clair", - lime: "vert citron", - limegreen: "citron vert", - linen: "écru", - magenta: "magenta", - maroon: "marron", - mediumaquamarine: "aigue-marine moyen", - mediumblue: "bleu moyen", - mediumorchid: "lilas moyen", - mediumpurple: "pourpre moyen", - mediumseagreen: "vert d'eau moyen", - mediumslateblue: "bleu ardoise moyen", - mediumspringgreen: "vert printemps moyen", - mediumturquoise: "turquoise moyen", - mediumvioletred: "rouge violacé moyen", - midnightblue: "bleu nuit", - mintcream: "crème de menthe", - mistyrose: "rose pâle", - moccasin: "chamois", - navajowhite: "chair", - navy: "bleu marine", - oldlace: "blanc cassé", - olive: "olive", - olivedrab: "brun verdâtre", - orange: "orange", - orangered: "rouge orangé", - orchid: "lilas", - palegoldenrod: "jaune paille pâle", - palegreen: "vert pâle", - paleturquoise: "turquoise pâle", - palevioletred: "rouge violacé pâle", - papayawhip: "crème de papaye", - peachpuff: "pêche", - peru: "caramel", - pink: "rose", - plum: "prune", - powderblue: "bleu de smalt", - purple: "pourpre", - red: "rouge", - rosybrown: "vieux rose", - royalblue: "bleu roi", - saddlebrown: "brun cuir", - salmon: "saumon", - sandybrown: "sable", - seagreen: "vert d'eau", - seashell: "coquillage", - sienna: "terre de sienne", - silver: "argent", - skyblue: "bleu ciel", - slateblue: "bleu ardoise", - slategray: "gris ardoise", - slategrey: "gris ardoise", // same as slategray - snow: "neige", - springgreen: "vert printemps", - steelblue: "bleu acier", - tan: "grège", - teal: "sarcelle", - thistle: "chardon", - tomato: "tomate", - transparent: "transparent", - turquoise: "turquoise", - violet: "violet", - wheat: "blé", - white: "blanc", - whitesmoke: "blanc cendré", - yellow: "jaune", - yellowgreen: "vert jaunâtre" -}) -); diff --git a/lib/dojo/nls/he/colors.js b/lib/dojo/nls/he/colors.js deleted file mode 100644 index 58be754..0000000 --- a/lib/dojo/nls/he/colors.js +++ /dev/null @@ -1,8 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/nls/he/colors",({aliceblue:"כחול פלדה",antiquewhite:"לבן עתיק",aqua:"אקווה",aquamarine:"אקוומארין",azure:"תכלת עז",beige:"בז'",bisque:"לבן שקד",black:"שחור",blanchedalmond:"שקד",blue:"כחול",blueviolet:"כחול-סגול",brown:"חום",burlywood:"חום דהוי",cadetblue:"כחול ים",chartreuse:"ירוק-צהוב",chocolate:"שוקולד",coral:"אלמוג",cornflowerblue:"כחול דרדר",cornsilk:"צהבהב",crimson:"ארגמן",cyan:"טורקיז",darkblue:"כחול כהה",darkcyan:"טורקיז כהה",darkgoldenrod:"זהוב כהה",darkgray:"אפור כהה",darkgreen:"ירוק כהה",darkgrey:"אפור כהה",darkkhaki:"חאקי כהה",darkmagenta:"בורדו כהה",darkolivegreen:"ירוק זית כהה",darkorange:"כתום כהה",darkorchid:"סחלב כהה",darkred:"אדום כהה",darksalmon:"סלמון כהה",darkseagreen:"ירוק ים כהה",darkslateblue:"כחול צפחה כהה",darkslategray:"אפור צפחה כהה",darkslategrey:"אפור צפחה כהה",darkturquoise:"טורקיז כהה",darkviolet:"סגול כהה",deeppink:"ורוד עמוק",deepskyblue:"כחול שמיים עמוק",dimgray:"אפור עמום",dimgrey:"אפור עמום",dodgerblue:"כחול",firebrick:"לבנה שרופה",floralwhite:"לבן פרחוני",forestgreen:"ירוק יער",fuchsia:"ורוד בהיר",gainsboro:"גיינסבורו",ghostwhite:"לבן רפאים",gold:"זהב",goldenrod:"זהוב",gray:"אפור",green:"ירוק",greenyellow:"ירוק-צהוב",grey:"אפור",honeydew:"ירקרק",hotpink:"ורוד לוהט",indianred:"אדום דהוי",indigo:"אינדיגו",ivory:"שנהב",khaki:"חאקי",lavender:"לבנדר",lavenderblush:"סומק לבנדר",lawngreen:"ירוק דשא",lemonchiffon:"ירוק לימון",lightblue:"תכלת",lightcoral:"אלמוג בהיר",lightcyan:"טורקיז בהיר",lightgoldenrodyellow:"צהוב בהיר",lightgray:"אפור בהיר",lightgreen:"ירוק בהיר",lightgrey:"אפור בהיר",lightpink:"ורוד בהיר",lightsalmon:"סלמון בהיר",lightseagreen:"ירוק ים בהיר",lightskyblue:"כחול שמיים בהיר",lightslategray:"אפור צפחה בהיר",lightslategrey:"אפור צפחה בהיר",lightsteelblue:"כחול פלדה בהיר",lightyellow:"צהוב בהיר",lime:"לימון",limegreen:"ירוק לימוני",linen:"פשתן",magenta:"בורדו",maroon:"חום אדמדם",mediumaquamarine:"כחול בינוני",mediumblue:"תכלת בינוני",mediumorchid:"סחלב בינוני",mediumpurple:"סגול בינוני",mediumseagreen:"ירוק ים בינוני",mediumslateblue:"כחול צפחה בינוני",mediumspringgreen:"ירוק אביב בינוני",mediumturquoise:"טורקיז בינוני",mediumvioletred:"סגול-אדום בינוני",midnightblue:"כחול כהה",mintcream:"קרם מנטה",mistyrose:"ורוד מעורפל",moccasin:"מוקסין",navajowhite:"לבן נוואחו",navy:"כחול כהה",oldlace:"תחרה עתיקה",olive:"זית",olivedrab:"זית עמום",orange:"כתום",orangered:"כתום אדום",orchid:"סחלב",palegoldenrod:"זהוב בהיר",palegreen:"ירוק בהיר",paleturquoise:"טורקיז בהיר",palevioletred:"סגול-אדום בהיר",papayawhip:"פפאיה",peachpuff:"קציפת אפרסק",peru:"פרו",pink:"ורוד",plum:"שזיף",powderblue:"כחול חיוור",purple:"סגול",red:"אדום",rosybrown:"חום ורדרד",royalblue:"כחול מלכותי",saddlebrown:"חום דהוי",salmon:"סלמון",sandybrown:"חום חולי",seagreen:"ירוק ים",seashell:"צדף",sienna:"סיינה",silver:"כסף",skyblue:"כחול שמיים",slateblue:"כחול צפחה",slategray:"אפור צפחה",slategrey:"אפור צפחה",snow:"שלג",springgreen:"ירוק אביב",steelblue:"כחול פלדה",tan:"חום אדמדם",teal:"כחול-ירוק כהה",thistle:"דרדר",tomato:"עגבניה",transparent:"שקוף",turquoise:"טורקיז",violet:"סגול",wheat:"חיוט",white:"לבן",whitesmoke:"עשן לבן",yellow:"צהוב",yellowgreen:"ירוק צהוב"})); diff --git a/lib/dojo/nls/he/colors.js.uncompressed.js b/lib/dojo/nls/he/colors.js.uncompressed.js deleted file mode 100644 index 2ba5f11..0000000 --- a/lib/dojo/nls/he/colors.js.uncompressed.js +++ /dev/null @@ -1,156 +0,0 @@ -define( -"dojo/nls/he/colors", ({ -// local representation of all CSS3 named colors, companion to dojo.colors. To be used where descriptive information -// is required for each color, such as a palette widget, and not for specifying color programatically. -//Note: due to the SVG 1.0 spec additions, some of these are alternate spellings for the same color (e.g. gray / grey). -//TODO: should we be using unique rgb values as keys instead and avoid these duplicates, or rely on the caller to do the reverse mapping? -aliceblue: "כחול פלדה", -antiquewhite: "לבן עתיק", -aqua: "אקווה", -aquamarine: "אקוומארין", -azure: "תכלת עז", -beige: "בז'", -bisque: "לבן שקד", -black: "שחור", -blanchedalmond: "שקד", -blue: "כחול", -blueviolet: "כחול-סגול", -brown: "חום", -burlywood: "חום דהוי", -cadetblue: "כחול ים", -chartreuse: "ירוק-צהוב", -chocolate: "שוקולד", -coral: "אלמוג", -cornflowerblue: "כחול דרדר", -cornsilk: "צהבהב", -crimson: "ארגמן", -cyan: "טורקיז", -darkblue: "כחול כהה", -darkcyan: "טורקיז כהה", -darkgoldenrod: "זהוב כהה", -darkgray: "אפור כהה", -darkgreen: "ירוק כהה", -darkgrey: "אפור כהה", // same as darkgray -darkkhaki: "חאקי כהה", -darkmagenta: "בורדו כהה", -darkolivegreen: "ירוק זית כהה", -darkorange: "כתום כהה", -darkorchid: "סחלב כהה", -darkred: "אדום כהה", -darksalmon: "סלמון כהה", -darkseagreen: "ירוק ים כהה", -darkslateblue: "כחול צפחה כהה", -darkslategray: "אפור צפחה כהה", -darkslategrey: "אפור צפחה כהה", // same as darkslategray -darkturquoise: "טורקיז כהה", -darkviolet: "סגול כהה", -deeppink: "ורוד עמוק", -deepskyblue: "כחול שמיים עמוק", -dimgray: "אפור עמום", -dimgrey: "אפור עמום", // same as dimgray -dodgerblue: "כחול", -firebrick: "לבנה שרופה", -floralwhite: "לבן פרחוני", -forestgreen: "ירוק יער", -fuchsia: "ורוד בהיר", -gainsboro: "גיינסבורו", -ghostwhite: "לבן רפאים", -gold: "זהב", -goldenrod: "זהוב", -gray: "אפור", -green: "ירוק", -greenyellow: "ירוק-צהוב", -grey: "אפור", // same as gray -honeydew: "ירקרק", -hotpink: "ורוד לוהט", -indianred: "אדום דהוי", -indigo: "אינדיגו", -ivory: "שנהב", -khaki: "חאקי", -lavender: "לבנדר", -lavenderblush: "סומק לבנדר", -lawngreen: "ירוק דשא", -lemonchiffon: "ירוק לימון", -lightblue: "תכלת", -lightcoral: "אלמוג בהיר", -lightcyan: "טורקיז בהיר", -lightgoldenrodyellow: "צהוב בהיר", -lightgray: "אפור בהיר", -lightgreen: "ירוק בהיר", -lightgrey: "אפור בהיר", // same as lightgray -lightpink: "ורוד בהיר", -lightsalmon: "סלמון בהיר", -lightseagreen: "ירוק ים בהיר", -lightskyblue: "כחול שמיים בהיר", -lightslategray: "אפור צפחה בהיר", -lightslategrey: "אפור צפחה בהיר", // same as lightslategray -lightsteelblue: "כחול פלדה בהיר", -lightyellow: "צהוב בהיר", -lime: "לימון", -limegreen: "ירוק לימוני", -linen: "פשתן", -magenta: "בורדו", -maroon: "חום אדמדם", -mediumaquamarine: "כחול בינוני", -mediumblue: "תכלת בינוני", -mediumorchid: "סחלב בינוני", -mediumpurple: "סגול בינוני", -mediumseagreen: "ירוק ים בינוני", -mediumslateblue: "כחול צפחה בינוני", -mediumspringgreen: "ירוק אביב בינוני", -mediumturquoise: "טורקיז בינוני", -mediumvioletred: "סגול-אדום בינוני", -midnightblue: "כחול כהה", -mintcream: "קרם מנטה", -mistyrose: "ורוד מעורפל", -moccasin: "מוקסין", -navajowhite: "לבן נוואחו", -navy: "כחול כהה", -oldlace: "תחרה עתיקה", -olive: "זית", -olivedrab: "זית עמום", -orange: "כתום", -orangered: "כתום אדום", -orchid: "סחלב", -palegoldenrod: "זהוב בהיר", -palegreen: "ירוק בהיר", -paleturquoise: "טורקיז בהיר", -palevioletred: "סגול-אדום בהיר", -papayawhip: "פפאיה", -peachpuff: "קציפת אפרסק", -peru: "פרו", -pink: "ורוד", -plum: "שזיף", -powderblue: "כחול חיוור", -purple: "סגול", -red: "אדום", -rosybrown: "חום ורדרד", -royalblue: "כחול מלכותי", -saddlebrown: "חום דהוי", -salmon: "סלמון", -sandybrown: "חום חולי", -seagreen: "ירוק ים", -seashell: "צדף", -sienna: "סיינה", -silver: "כסף", -skyblue: "כחול שמיים", -slateblue: "כחול צפחה", -slategray: "אפור צפחה", -slategrey: "אפור צפחה", // same as slategray -snow: "שלג", -springgreen: "ירוק אביב", -steelblue: "כחול פלדה", -tan: "חום אדמדם", -teal: "כחול-ירוק כהה", -thistle: "דרדר", -tomato: "עגבניה", -transparent: "שקוף", -turquoise: "טורקיז", -violet: "סגול", -wheat: "חיוט", -white: "לבן", -whitesmoke: "עשן לבן", -yellow: "צהוב", -yellowgreen: "ירוק צהוב" -}) -); diff --git a/lib/dojo/nls/hr/colors.js b/lib/dojo/nls/hr/colors.js deleted file mode 100644 index 79359f3..0000000 --- a/lib/dojo/nls/hr/colors.js +++ /dev/null @@ -1,8 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/nls/hr/colors",({aliceblue:"alice plava",antiquewhite:"antique bijela",aqua:"aqua",aquamarine:"akvamarin",azure:"azurna",beige:"bež",bisque:"svjetlo smeđe ružičasta",black:"crna",blanchedalmond:"svjetlo bademasta",blue:"plava",blueviolet:"plavo ljubičasta",brown:"smeđa",burlywood:"tamno smeđa",cadetblue:"kadet plava",chartreuse:"chartreuse",chocolate:"čokoladna",coral:"koraljna",cornflowerblue:"različak plava",cornsilk:"cornsilk",crimson:"rumena",cyan:"cijan",darkblue:"tamno plava",darkcyan:"tamno cijan",darkgoldenrod:"tamno zlatno žuta",darkgray:"tamno siva",darkgreen:"tamno zelena",darkgrey:"tamno siva",darkkhaki:"tamno sivo smeđa",darkmagenta:"tamno grimizna",darkolivegreen:"tamno maslinasto zelena",darkorange:"tamno narančasta",darkorchid:"tamno ružičasta",darkred:"tamno crvena",darksalmon:"tamno žuto ružičasta",darkseagreen:"tamno plavo zelena",darkslateblue:"tamno sivo plava",darkslategray:"tamno plavo siva",darkslategrey:"tamno plavo siva",darkturquoise:"tamno tirkizna",darkviolet:"tamno ljubičasta",deeppink:"intenzivno ružičasta",deepskyblue:"intenzivno nebesko plava",dimgray:"mutno siva",dimgrey:"mutno siva",dodgerblue:"dodger plava",firebrick:"žarko crvena",floralwhite:"cvjetno bijela",forestgreen:"šumsko zelena",fuchsia:"fuksija",gainsboro:"gainsboro",ghostwhite:"sivo bijela",gold:"zlatna",goldenrod:"zlatno žuta",gray:"siva",green:"zelena",greenyellow:"zeleno žuta",grey:"siva",honeydew:"honeydew",hotpink:"žarko ružičasta",indianred:"indijski crveno",indigo:"indigo",ivory:"slonovača",khaki:"sivo smeđa",lavender:"lavanda",lavenderblush:"rumena lavanda",lawngreen:"livadno zelena",lemonchiffon:"nježno žuta",lightblue:"svjetlo plava",lightcoral:"svjetlo koraljna",lightcyan:"svjetlo cijan",lightgoldenrodyellow:"svjetlo zlatno žuta",lightgray:"svjetlo siva",lightgreen:"svjetlo zelena",lightgrey:"svjetlo siva",lightpink:"svjetlo ružičasta",lightsalmon:"svjetlo žuto ružičasta",lightseagreen:"svjetlo plavo zelena",lightskyblue:"svjetlo nebesko plava",lightslategray:"svjetlo plavo siva",lightslategrey:"svjetlo plavo siva",lightsteelblue:"svjetlo čelično plava",lightyellow:"svjetlo žuta",lime:"limeta",limegreen:"limeta zelena",linen:"platno",magenta:"grimizna",maroon:"kestenjasta",mediumaquamarine:"srednje akvamarin",mediumblue:"srednje plava",mediumorchid:"srednje ružičasta",mediumpurple:"srednje purpurna",mediumseagreen:"srednje plavo zelena",mediumslateblue:"srednje sivo plava",mediumspringgreen:"srednje proljetno zelena",mediumturquoise:"srednje tirkizna",mediumvioletred:"srednje ljubičasto crvena",midnightblue:"ponoćno plava",mintcream:"blijedo zelena",mistyrose:"mutno ružičasta",moccasin:"moccasin",navajowhite:"krem bijela",navy:"mornarsko plava",oldlace:"old lace",olive:"maslinasta",olivedrab:"maslinasto siva",orange:"narančasta",orangered:"narančasto crvena",orchid:"ružičasta",palegoldenrod:"blijedo zlatno žuta",palegreen:"blijedo zelena",paleturquoise:"blijedo tirkizna",palevioletred:"blijedo ljubičasto crvena",papayawhip:"blijedo narančasta",peachpuff:"breskva",peru:"peru",pink:"roza",plum:"šljiva",powderblue:"blijedo plava",purple:"purpurna",red:"crvena",rosybrown:"ružičasto smeđa",royalblue:"kraljevski plava",saddlebrown:"srednje smeđa",salmon:"žuto ružičasta",sandybrown:"pješčano smeđa",seagreen:"plavo zelena",seashell:"nježno ružičasta",sienna:"sjena",silver:"srebrna",skyblue:"nebesko plava",slateblue:"sivo plava",slategray:"plavo siva",slategrey:"plavo siva",snow:"snijeg",springgreen:"proljetno zeleno",steelblue:"čelično plava",tan:"ten",teal:"teal",thistle:"čičak",tomato:"rajčica",transparent:"prozirno",turquoise:"tirkizna",violet:"ljubičasta",wheat:"pšenica",white:"bijela",whitesmoke:"bijeli dim",yellow:"žuta",yellowgreen:"žuto zelena"})); diff --git a/lib/dojo/nls/hr/colors.js.uncompressed.js b/lib/dojo/nls/hr/colors.js.uncompressed.js deleted file mode 100644 index 5cd5dbc..0000000 --- a/lib/dojo/nls/hr/colors.js.uncompressed.js +++ /dev/null @@ -1,156 +0,0 @@ -define( -"dojo/nls/hr/colors", ({ -// local representation of all CSS3 named colors, companion to dojo.colors. To be used where descriptive information -// is required for each color, such as a palette widget, and not for specifying color programatically. -//Note: due to the SVG 1.0 spec additions, some of these are alternate spellings for the same color (e.g. gray / grey). -//TODO: should we be using unique rgb values as keys instead and avoid these duplicates, or rely on the caller to do the reverse mapping? - aliceblue: "alice plava", - antiquewhite: "antique bijela", - aqua: "aqua", - aquamarine: "akvamarin", - azure: "azurna", - beige: "bež", - bisque: "svjetlo smeđe ružičasta", - black: "crna", - blanchedalmond: "svjetlo bademasta", - blue: "plava", - blueviolet: "plavo ljubičasta", - brown: "smeđa", - burlywood: "tamno smeđa", - cadetblue: "kadet plava", - chartreuse: "chartreuse", - chocolate: "čokoladna", - coral: "koraljna", - cornflowerblue: "različak plava", - cornsilk: "cornsilk", - crimson: "rumena", - cyan: "cijan", - darkblue: "tamno plava", - darkcyan: "tamno cijan", - darkgoldenrod: "tamno zlatno žuta", - darkgray: "tamno siva", - darkgreen: "tamno zelena", - darkgrey: "tamno siva", // same as darkgray - darkkhaki: "tamno sivo smeđa", - darkmagenta: "tamno grimizna", - darkolivegreen: "tamno maslinasto zelena", - darkorange: "tamno narančasta", - darkorchid: "tamno ružičasta", - darkred: "tamno crvena", - darksalmon: "tamno žuto ružičasta", - darkseagreen: "tamno plavo zelena", - darkslateblue: "tamno sivo plava", - darkslategray: "tamno plavo siva", - darkslategrey: "tamno plavo siva", // same as darkslategray - darkturquoise: "tamno tirkizna", - darkviolet: "tamno ljubičasta", - deeppink: "intenzivno ružičasta", - deepskyblue: "intenzivno nebesko plava", - dimgray: "mutno siva", - dimgrey: "mutno siva", // same as dimgray - dodgerblue: "dodger plava", - firebrick: "žarko crvena", - floralwhite: "cvjetno bijela", - forestgreen: "šumsko zelena", - fuchsia: "fuksija", - gainsboro: "gainsboro", - ghostwhite: "sivo bijela", - gold: "zlatna", - goldenrod: "zlatno žuta", - gray: "siva", - green: "zelena", - greenyellow: "zeleno žuta", - grey: "siva", // same as gray - honeydew: "honeydew", - hotpink: "žarko ružičasta", - indianred: "indijski crveno", - indigo: "indigo", - ivory: "slonovača", - khaki: "sivo smeđa", - lavender: "lavanda", - lavenderblush: "rumena lavanda", - lawngreen: "livadno zelena", - lemonchiffon: "nježno žuta", - lightblue: "svjetlo plava", - lightcoral: "svjetlo koraljna", - lightcyan: "svjetlo cijan", - lightgoldenrodyellow: "svjetlo zlatno žuta", - lightgray: "svjetlo siva", - lightgreen: "svjetlo zelena", - lightgrey: "svjetlo siva", // same as lightgray - lightpink: "svjetlo ružičasta", - lightsalmon: "svjetlo žuto ružičasta", - lightseagreen: "svjetlo plavo zelena", - lightskyblue: "svjetlo nebesko plava", - lightslategray: "svjetlo plavo siva", - lightslategrey: "svjetlo plavo siva", // same as lightslategray - lightsteelblue: "svjetlo čelično plava", - lightyellow: "svjetlo žuta", - lime: "limeta", - limegreen: "limeta zelena", - linen: "platno", - magenta: "grimizna", - maroon: "kestenjasta", - mediumaquamarine: "srednje akvamarin", - mediumblue: "srednje plava", - mediumorchid: "srednje ružičasta", - mediumpurple: "srednje purpurna", - mediumseagreen: "srednje plavo zelena", - mediumslateblue: "srednje sivo plava", - mediumspringgreen: "srednje proljetno zelena", - mediumturquoise: "srednje tirkizna", - mediumvioletred: "srednje ljubičasto crvena", - midnightblue: "ponoćno plava", - mintcream: "blijedo zelena", - mistyrose: "mutno ružičasta", - moccasin: "moccasin", - navajowhite: "krem bijela", - navy: "mornarsko plava", - oldlace: "old lace", - olive: "maslinasta", - olivedrab: "maslinasto siva", - orange: "narančasta", - orangered: "narančasto crvena", - orchid: "ružičasta", - palegoldenrod: "blijedo zlatno žuta", - palegreen: "blijedo zelena", - paleturquoise: "blijedo tirkizna", - palevioletred: "blijedo ljubičasto crvena", - papayawhip: "blijedo narančasta", - peachpuff: "breskva", - peru: "peru", - pink: "roza", - plum: "šljiva", - powderblue: "blijedo plava", - purple: "purpurna", - red: "crvena", - rosybrown: "ružičasto smeđa", - royalblue: "kraljevski plava", - saddlebrown: "srednje smeđa", - salmon: "žuto ružičasta", - sandybrown: "pješčano smeđa", - seagreen: "plavo zelena", - seashell: "nježno ružičasta", - sienna: "sjena", - silver: "srebrna", - skyblue: "nebesko plava", - slateblue: "sivo plava", - slategray: "plavo siva", - slategrey: "plavo siva", // same as slategray - snow: "snijeg", - springgreen: "proljetno zeleno", - steelblue: "čelično plava", - tan: "ten", - teal: "teal", - thistle: "čičak", - tomato: "rajčica", - transparent: "prozirno", - turquoise: "tirkizna", - violet: "ljubičasta", - wheat: "pšenica", - white: "bijela", - whitesmoke: "bijeli dim", - yellow: "žuta", - yellowgreen: "žuto zelena" -}) -); diff --git a/lib/dojo/nls/hu/colors.js b/lib/dojo/nls/hu/colors.js deleted file mode 100644 index 56467d2..0000000 --- a/lib/dojo/nls/hu/colors.js +++ /dev/null @@ -1,8 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/nls/hu/colors",({aliceblue:"Alice kék",antiquewhite:"antik fehér",aqua:"vízszín",aquamarine:"akvamarin",azure:"azúrkék",beige:"bézs",bisque:"porcelán",black:"fekete",blanchedalmond:"hámozott mandula",blue:"kék",blueviolet:"ibolyakék",brown:"barna",burlywood:"nyersfa",cadetblue:"kadétkék",chartreuse:"chartreuse",chocolate:"csokoládé",coral:"korall",cornflowerblue:"búzavirágkék",cornsilk:"kukoricahaj",crimson:"karmazsinvörös",cyan:"ciánkék",darkblue:"sötétkék",darkcyan:"sötét ciánkék",darkgoldenrod:"sötét aranyvessző",darkgray:"sötétszürke",darkgreen:"sötétzöld",darkgrey:"sötétszürke",darkkhaki:"sötét khakiszín",darkmagenta:"sötétbíbor",darkolivegreen:"sötét olajzöld",darkorange:"sötét narancssárga",darkorchid:"sötét orchidea",darkred:"sötétvörös",darksalmon:"sötét lazacszín",darkseagreen:"sötét tengerzöld",darkslateblue:"sötét palakék",darkslategray:"sötét palaszürke",darkslategrey:"sötét palaszürke",darkturquoise:"sötét türkizkék",darkviolet:"sötét ibolyaszín",deeppink:"sötétrózsaszín",deepskyblue:"sötét égszínkék",dimgray:"halványszürke",dimgrey:"halványszürke",dodgerblue:"dodger kék",firebrick:"téglavörös",floralwhite:"virágfehér",forestgreen:"erdőzöld",fuchsia:"fukszia",gainsboro:"gainsboro",ghostwhite:"szellemfehér",gold:"arany",goldenrod:"aranyvessző",gray:"szürke",green:"zöld",greenyellow:"zöldessárga",grey:"szürke",honeydew:"mézharmat",hotpink:"meleg rózsaszín",indianred:"indiánvörös",indigo:"indigó",ivory:"elefántcsont",khaki:"khakiszín",lavender:"levendula",lavenderblush:"pirosas levendula",lawngreen:"fűzöld",lemonchiffon:"sárga műselyem",lightblue:"világoskék",lightcoral:"világos korall",lightcyan:"világos ciánkék",lightgoldenrodyellow:"világos aranyvessző sárga",lightgray:"világosszürke",lightgreen:"világoszöld",lightgrey:"világosszürke",lightpink:"világos rózsaszín",lightsalmon:"világos lazacszín",lightseagreen:"világos tengerzöld",lightskyblue:"világos égszínkék",lightslategray:"világos palaszürke",lightslategrey:"világos palaszürke",lightsteelblue:"világos acélkék",lightyellow:"világossárga",lime:"lime",limegreen:"limezöld",linen:"vászonfehér",magenta:"bíbor",maroon:"gesztenyebarna",mediumaquamarine:"közepes akvamarin",mediumblue:"közepes kék",mediumorchid:"közepes orchidea",mediumpurple:"közepes lila",mediumseagreen:"közepes tengerzöld",mediumslateblue:"közepes palakék",mediumspringgreen:"közepes tavaszzöld",mediumturquoise:"közepes türkizkék",mediumvioletred:"közepes ibolyavörös",midnightblue:"éjkék",mintcream:"mentaszósz",mistyrose:"halvány rózsaszín",moccasin:"mokkaszín",navajowhite:"navajo fehér",navy:"tengerészkék",oldlace:"régi csipke",olive:"olajzöld",olivedrab:"olajzöld drapp",orange:"narancssárga",orangered:"narancsvörös",orchid:"orchidea",palegoldenrod:"halvány aranyvessző",palegreen:"halványzöld",paleturquoise:"halvány türkizkék",palevioletred:"halvány ibolyavörös",papayawhip:"papayahab",peachpuff:"barackszín",peru:"peru",pink:"rózsaszín",plum:"szilvakék",powderblue:"púderkék",purple:"lila",red:"vörös",rosybrown:"barnásrózsaszín",royalblue:"királykék",saddlebrown:"nyeregbarna",salmon:"lazacszín",sandybrown:"homokbarna",seagreen:"tengerzöld",seashell:"kagyló",sienna:"vörösesbarna",silver:"ezüst",skyblue:"égszínkék",slateblue:"palakék",slategray:"palaszürke",slategrey:"palaszürke",snow:"hó",springgreen:"tavaszzöld",steelblue:"acélkék",tan:"rozsdabarna",teal:"pávakék",thistle:"bogáncs",tomato:"paradicsom",transparent:"átlátszó",turquoise:"türkizkék",violet:"ibolyaszín",wheat:"búza",white:"fehér",whitesmoke:"fehér füst",yellow:"sárga",yellowgreen:"sárgászöld"})); diff --git a/lib/dojo/nls/hu/colors.js.uncompressed.js b/lib/dojo/nls/hu/colors.js.uncompressed.js deleted file mode 100644 index 92773ae..0000000 --- a/lib/dojo/nls/hu/colors.js.uncompressed.js +++ /dev/null @@ -1,156 +0,0 @@ -define( -"dojo/nls/hu/colors", ({ -// local representation of all CSS3 named colors, companion to dojo.colors. To be used where descriptive information -// is required for each color, such as a palette widget, and not for specifying color programatically. - //Note: due to the SVG 1.0 spec additions, some of these are alternate spellings for the same color (e.g. gray / grey). - //TODO: should we be using unique rgb values as keys instead and avoid these duplicates, or rely on the caller to do the reverse mapping? - aliceblue: "Alice kék", - antiquewhite: "antik fehér", - aqua: "vízszín", - aquamarine: "akvamarin", - azure: "azúrkék", - beige: "bézs", - bisque: "porcelán", - black: "fekete", - blanchedalmond: "hámozott mandula", - blue: "kék", - blueviolet: "ibolyakék", - brown: "barna", - burlywood: "nyersfa", - cadetblue: "kadétkék", - chartreuse: "chartreuse", - chocolate: "csokoládé", - coral: "korall", - cornflowerblue: "búzavirágkék", - cornsilk: "kukoricahaj", - crimson: "karmazsinvörös", - cyan: "ciánkék", - darkblue: "sötétkék", - darkcyan: "sötét ciánkék", - darkgoldenrod: "sötét aranyvessző", - darkgray: "sötétszürke", - darkgreen: "sötétzöld", - darkgrey: "sötétszürke", // same as darkgray - darkkhaki: "sötét khakiszín", - darkmagenta: "sötétbíbor", - darkolivegreen: "sötét olajzöld", - darkorange: "sötét narancssárga", - darkorchid: "sötét orchidea", - darkred: "sötétvörös", - darksalmon: "sötét lazacszín", - darkseagreen: "sötét tengerzöld", - darkslateblue: "sötét palakék", - darkslategray: "sötét palaszürke", - darkslategrey: "sötét palaszürke", // same as darkslategray - darkturquoise: "sötét türkizkék", - darkviolet: "sötét ibolyaszín", - deeppink: "sötétrózsaszín", - deepskyblue: "sötét égszínkék", - dimgray: "halványszürke", - dimgrey: "halványszürke", // same as dimgray - dodgerblue: "dodger kék", - firebrick: "téglavörös", - floralwhite: "virágfehér", - forestgreen: "erdőzöld", - fuchsia: "fukszia", - gainsboro: "gainsboro", - ghostwhite: "szellemfehér", - gold: "arany", - goldenrod: "aranyvessző", - gray: "szürke", - green: "zöld", - greenyellow: "zöldessárga", - grey: "szürke", // same as gray - honeydew: "mézharmat", - hotpink: "meleg rózsaszín", - indianred: "indiánvörös", - indigo: "indigó", - ivory: "elefántcsont", - khaki: "khakiszín", - lavender: "levendula", - lavenderblush: "pirosas levendula", - lawngreen: "fűzöld", - lemonchiffon: "sárga műselyem", - lightblue: "világoskék", - lightcoral: "világos korall", - lightcyan: "világos ciánkék", - lightgoldenrodyellow: "világos aranyvessző sárga", - lightgray: "világosszürke", - lightgreen: "világoszöld", - lightgrey: "világosszürke", // same as lightgray - lightpink: "világos rózsaszín", - lightsalmon: "világos lazacszín", - lightseagreen: "világos tengerzöld", - lightskyblue: "világos égszínkék", - lightslategray: "világos palaszürke", - lightslategrey: "világos palaszürke", // same as lightslategray - lightsteelblue: "világos acélkék", - lightyellow: "világossárga", - lime: "lime", - limegreen: "limezöld", - linen: "vászonfehér", - magenta: "bíbor", - maroon: "gesztenyebarna", - mediumaquamarine: "közepes akvamarin", - mediumblue: "közepes kék", - mediumorchid: "közepes orchidea", - mediumpurple: "közepes lila", - mediumseagreen: "közepes tengerzöld", - mediumslateblue: "közepes palakék", - mediumspringgreen: "közepes tavaszzöld", - mediumturquoise: "közepes türkizkék", - mediumvioletred: "közepes ibolyavörös", - midnightblue: "éjkék", - mintcream: "mentaszósz", - mistyrose: "halvány rózsaszín", - moccasin: "mokkaszín", - navajowhite: "navajo fehér", - navy: "tengerészkék", - oldlace: "régi csipke", - olive: "olajzöld", - olivedrab: "olajzöld drapp", - orange: "narancssárga", - orangered: "narancsvörös", - orchid: "orchidea", - palegoldenrod: "halvány aranyvessző", - palegreen: "halványzöld", - paleturquoise: "halvány türkizkék", - palevioletred: "halvány ibolyavörös", - papayawhip: "papayahab", - peachpuff: "barackszín", - peru: "peru", - pink: "rózsaszín", - plum: "szilvakék", - powderblue: "púderkék", - purple: "lila", - red: "vörös", - rosybrown: "barnásrózsaszín", - royalblue: "királykék", - saddlebrown: "nyeregbarna", - salmon: "lazacszín", - sandybrown: "homokbarna", - seagreen: "tengerzöld", - seashell: "kagyló", - sienna: "vörösesbarna", - silver: "ezüst", - skyblue: "égszínkék", - slateblue: "palakék", - slategray: "palaszürke", - slategrey: "palaszürke", // same as slategray - snow: "hó", - springgreen: "tavaszzöld", - steelblue: "acélkék", - tan: "rozsdabarna", - teal: "pávakék", - thistle: "bogáncs", - tomato: "paradicsom", - transparent: "átlátszó", - turquoise: "türkizkék", - violet: "ibolyaszín", - wheat: "búza", - white: "fehér", - whitesmoke: "fehér füst", - yellow: "sárga", - yellowgreen: "sárgászöld" -}) -); diff --git a/lib/dojo/nls/id/colors.js b/lib/dojo/nls/id/colors.js deleted file mode 100644 index c096129..0000000 --- a/lib/dojo/nls/id/colors.js +++ /dev/null @@ -1,8 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/nls/id/colors",({aliceblue:"alice blue",antiquewhite:"antique white",aqua:"aqua",aquamarine:"biru laut",azure:"biru langit",beige:"krem",bisque:"bisque",black:"hitam",blanchedalmond:"almond pucat",blue:"biru",blueviolet:"biru-ungu",brown:"coklat",burlywood:"burlywood",cadetblue:"cadet blue",chartreuse:"chartreuse",chocolate:"chocolate",coral:"coral",cornflowerblue:"cornflower blue",cornsilk:"cornsilk",crimson:"crimson",cyan:"cyan",darkblue:"biru tua",darkcyan:"dark cyan",darkgoldenrod:"dark goldenrod",darkgray:"abu-abu tua",darkgreen:"hijau tua",darkgrey:"abu-abu tua",darkkhaki:"dark khaki",darkmagenta:"magenta tua",darkolivegreen:"olive hijau tua",darkorange:"jingga tua",darkorchid:"dark orchid",darkred:"merah tua",darksalmon:"dark salmon",darkseagreen:"hijau laut tua",darkslateblue:"biru batu tua",darkslategray:"abu-abu batu tua",darkslategrey:"abu-abu batu tua",darkturquoise:"turquoise tua",darkviolet:"lembayung tua",deeppink:"merah muda dalam",deepskyblue:"hijau langit dalam",dimgray:"abu-abu temaram",dimgrey:"abu-abu temaram",dodgerblue:"dodger blue",firebrick:"fire brick",floralwhite:"putih bunga",forestgreen:"hijau hutan",fuchsia:"fuchsia",gainsboro:"gainsboro",ghostwhite:"ghost white",gold:"emas",goldenrod:"goldenrod",gray:"abu-abu",green:"hijau",greenyellow:"hijau-kuning",grey:"abu-abu",honeydew:"hijau melon",hotpink:"hot pink",indianred:"merah indian",indigo:"nila",ivory:"ivory",khaki:"khaki",lavender:"lembayung muda",lavenderblush:"lembayung muda kemerahan",lawngreen:"rumput hijau",lemonchiffon:"lemon chiffon",lightblue:"biru muda",lightcoral:"coral muda",lightcyan:"light cyan",lightgoldenrodyellow:"kuning goldenrod muda",lightgray:"abu-abu muda",lightgreen:"hijau muda",lightgrey:"abu-abu muda",lightpink:"merah jambu muda",lightsalmon:"light salmon",lightseagreen:"hijau laut muda",lightskyblue:"hijau langit muda",lightslategray:"au-abu batu tua",lightslategrey:"abu-abu batu tua",lightsteelblue:"biru baja muda",lightyellow:"kuning muda",lime:"limau",limegreen:"hijau limau",linen:"linen",magenta:"magenta",maroon:"maroon",mediumaquamarine:"medium aquamarine",mediumblue:"biru medium",mediumorchid:"medium orchid",mediumpurple:"ungu medium",mediumseagreen:"hijau laut medium",mediumslateblue:"biru batu medium",mediumspringgreen:"medium spring green",mediumturquoise:"medium turquoise",mediumvioletred:"ungu-merah medium",midnightblue:"midnight blue",mintcream:"mint cream",mistyrose:"misty rose",moccasin:"moccasin",navajowhite:"navajo white",navy:"navy",oldlace:"old lace",olive:"olive",olivedrab:"olive drab",orange:"jingga",orangered:"merah jingga",orchid:"orchid",palegoldenrod:"goldenrod pucat",palegreen:"hijau pucat",paleturquoise:"turquoise pucat",palevioletred:"ungu-marah pucat",papayawhip:"papaya whip",peachpuff:"peach puff",peru:"peru",pink:"merah jambu",plum:"plum",powderblue:"powder blue",purple:"ungu",red:"merah",rosybrown:"rosy brown",royalblue:"royal blue",saddlebrown:"saddle brown",salmon:"salmon",sandybrown:"sandy brown",seagreen:"hijau laut",seashell:"seashell",sienna:"sienna",silver:"perak",skyblue:"biru langit",slateblue:"biru batu",slategray:"abu-abu batu",slategrey:"abu-abu batu",snow:"snow",springgreen:"spring green",steelblue:"biru baja",tan:"tan",teal:"teal",thistle:"thistle",tomato:"tomat",transparent:"transparan",turquoise:"biru hijau",violet:"lembayung",wheat:"wheat",white:"putih",whitesmoke:"white smoke",yellow:"kuning",yellowgreen:"kuning hijau"})); diff --git a/lib/dojo/nls/id/colors.js.uncompressed.js b/lib/dojo/nls/id/colors.js.uncompressed.js deleted file mode 100644 index f01b1b7..0000000 --- a/lib/dojo/nls/id/colors.js.uncompressed.js +++ /dev/null @@ -1,157 +0,0 @@ -define( -"dojo/nls/id/colors", ({ -// local representation of all CSS3 named colors, companion to dojo.colors. To be used where descriptive information -// is required for each color, such as a palette widget, and not for specifying color programatically. - //Note: due to the SVG 1.0 spec additions, some of these are alternate spellings for the same color (e.g. gray / grey). - //TODO: should we be using unique rgb values as keys instead and avoid these duplicates, or rely on the caller to do the reverse mapping? - aliceblue: "alice blue", - antiquewhite: "antique white", - aqua: "aqua", - aquamarine: "biru laut", - azure: "biru langit", - beige: "krem", - bisque: "bisque", - black: "hitam", - blanchedalmond: "almond pucat", - blue: "biru", - blueviolet: "biru-ungu", - brown: "coklat", - burlywood: "burlywood", - cadetblue: "cadet blue", - chartreuse: "chartreuse", - chocolate: "chocolate", - coral: "coral", - cornflowerblue: "cornflower blue", - cornsilk: "cornsilk", - crimson: "crimson", - cyan: "cyan", - darkblue: "biru tua", - darkcyan: "dark cyan", - darkgoldenrod: "dark goldenrod", - darkgray: "abu-abu tua", - darkgreen: "hijau tua", - darkgrey: "abu-abu tua", // same as darkgray - darkkhaki: "dark khaki", - darkmagenta: "magenta tua", - darkolivegreen: "olive hijau tua", - darkorange: "jingga tua", - darkorchid: "dark orchid", - darkred: "merah tua", - darksalmon: "dark salmon", - darkseagreen: "hijau laut tua", - darkslateblue: "biru batu tua", - darkslategray: "abu-abu batu tua", - darkslategrey: "abu-abu batu tua", // same as darkslategray - darkturquoise: "turquoise tua", - darkviolet: "lembayung tua", - deeppink: "merah muda dalam", - deepskyblue: "hijau langit dalam", - dimgray: "abu-abu temaram", - dimgrey: "abu-abu temaram", // same as dimgray - dodgerblue: "dodger blue", - firebrick: "fire brick", - floralwhite: "putih bunga", - forestgreen: "hijau hutan", - fuchsia: "fuchsia", - gainsboro: "gainsboro", - ghostwhite: "ghost white", - gold: "emas", - goldenrod: "goldenrod", - gray: "abu-abu", - green: "hijau", - greenyellow: "hijau-kuning", - grey: "abu-abu", // same as gray - honeydew: "hijau melon", - hotpink: "hot pink", - indianred: "merah indian", - indigo: "nila", - ivory: "ivory", - khaki: "khaki", - lavender: "lembayung muda", - lavenderblush: "lembayung muda kemerahan", - lawngreen: "rumput hijau", - lemonchiffon: "lemon chiffon", - lightblue: "biru muda", - lightcoral: "coral muda", - lightcyan: "light cyan", - lightgoldenrodyellow: "kuning goldenrod muda", - lightgray: "abu-abu muda", - lightgreen: "hijau muda", - lightgrey: "abu-abu muda", // same as lightgray - lightpink: "merah jambu muda", - lightsalmon: "light salmon", - lightseagreen: "hijau laut muda", - lightskyblue: "hijau langit muda", - lightslategray: "au-abu batu tua", - lightslategrey: "abu-abu batu tua", // same as lightslategray - lightsteelblue: "biru baja muda", - lightyellow: "kuning muda", - lime: "limau", - limegreen: "hijau limau", - linen: "linen", - magenta: "magenta", - maroon: "maroon", - mediumaquamarine: "medium aquamarine", - mediumblue: "biru medium", - mediumorchid: "medium orchid", - mediumpurple: "ungu medium", - mediumseagreen: "hijau laut medium", - mediumslateblue: "biru batu medium", - mediumspringgreen: "medium spring green", - mediumturquoise: "medium turquoise", - mediumvioletred: "ungu-merah medium", - midnightblue: "midnight blue", - mintcream: "mint cream", - mistyrose: "misty rose", - moccasin: "moccasin", - navajowhite: "navajo white", - navy: "navy", - oldlace: "old lace", - olive: "olive", - olivedrab: "olive drab", - orange: "jingga", - orangered: "merah jingga", - orchid: "orchid", - palegoldenrod: "goldenrod pucat", - palegreen: "hijau pucat", - paleturquoise: "turquoise pucat", - palevioletred: "ungu-marah pucat", - papayawhip: "papaya whip", - peachpuff: "peach puff", - peru: "peru", - pink: "merah jambu", - plum: "plum", - powderblue: "powder blue", - purple: "ungu", - red: "merah", - rosybrown: "rosy brown", - royalblue: "royal blue", - saddlebrown: "saddle brown", - salmon: "salmon", - sandybrown: "sandy brown", - seagreen: "hijau laut", - seashell: "seashell", - sienna: "sienna", - silver: "perak", - skyblue: "biru langit", - slateblue: "biru batu", - slategray: "abu-abu batu", - slategrey: "abu-abu batu", // same as slategray - snow: "snow", - springgreen: "spring green", - steelblue: "biru baja", - tan: "tan", - teal: "teal", - thistle: "thistle", - tomato: "tomat", - transparent: "transparan", - turquoise: "biru hijau", - violet: "lembayung", - wheat: "wheat", - white: "putih", - whitesmoke: "white smoke", - yellow: "kuning", - yellowgreen: "kuning hijau" -}) -); - diff --git a/lib/dojo/nls/it/colors.js b/lib/dojo/nls/it/colors.js deleted file mode 100644 index a968100..0000000 --- a/lib/dojo/nls/it/colors.js +++ /dev/null @@ -1,8 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/nls/it/colors",({aliceblue:"bianco ghiaccio",antiquewhite:"rosa antico",aqua:"verde acqua",aquamarine:"acquamarina",azure:"azure",beige:"beige",bisque:"terracotta",black:"nero",blanchedalmond:"beige 2",blue:"blu",blueviolet:"violetto bluastro",brown:"marrone",burlywood:"legno massiccio",cadetblue:"verde petrolio",chartreuse:"verde brillante",chocolate:"cioccolato",coral:"corallo",cornflowerblue:"blu fiordaliso",cornsilk:"crema",crimson:"rosso scarlatto",cyan:"ciano",darkblue:"blu scuro",darkcyan:"celeste scuro",darkgoldenrod:"ocra scuro",darkgray:"grigio scuro",darkgreen:"verde scuro",darkgrey:"grigio scuro",darkkhaki:"cachi scuro",darkmagenta:"magenta scuro",darkolivegreen:"verde oliva scuro",darkorange:"arancione scuro",darkorchid:"orchidea scuro",darkred:"rosso scuro",darksalmon:"salmone scuro",darkseagreen:"verde acqua scuro",darkslateblue:"blu ardesia scuro",darkslategray:"grigio ardesia scuro",darkslategrey:"grigio ardesia scuro",darkturquoise:"turchese scuro",darkviolet:"viola scuro",deeppink:"ciclamino",deepskyblue:"azzurro intenso",dimgray:"grigio tenue",dimgrey:"grigio tenue",dodgerblue:"dodger blue",firebrick:"mattone",floralwhite:"bianco grigio",forestgreen:"verde pino scuro",fuchsia:"fucsia",gainsboro:"gainsboro",ghostwhite:"bianco gesso",gold:"oro",goldenrod:"dorato",gray:"grigio",green:"verde",greenyellow:"verde-giallo",grey:"grigio",honeydew:"miele",hotpink:"rosa acceso",indianred:"terra indiana",indigo:"indaco",ivory:"avorio",khaki:"cachi",lavender:"lavanda",lavenderblush:"lavanda rosa",lawngreen:"verde brillante chiaro",lemonchiffon:"lemon chiffon",lightblue:"blu chiaro",lightcoral:"corallo chiaro",lightcyan:"ciano chiaro",lightgoldenrodyellow:"giallo dorato chiaro",lightgray:"grigio chiaro",lightgreen:"verde chiaro",lightgrey:"grigio chiaro",lightpink:"rosa chiaro",lightsalmon:"salmone chiaro",lightseagreen:"verde acqua chiaro",lightskyblue:"azzurro chiaro",lightslategray:"grigio ardesia chiaro",lightslategrey:"grigio ardesia chiaro",lightsteelblue:"blu acciaio chiaro",lightyellow:"giallo chiaro",lime:"lime",limegreen:"verde lime",linen:"lino",magenta:"magenta",maroon:"Bordeaux",mediumaquamarine:"acquamarina medio",mediumblue:"blu medio",mediumorchid:"orchidea medio",mediumpurple:"viola medio",mediumseagreen:"verde acqua medio",mediumslateblue:"blu ardesia medio",mediumspringgreen:"verde brillante medio",mediumturquoise:"turchese medio",mediumvioletred:"violetto rosso medio",midnightblue:"blu notte",mintcream:"bianco nuvola",mistyrose:"rosa pallido",moccasin:"mocassino",navajowhite:"sabbia",navy:"blu scuro",oldlace:"mandorla",olive:"verde oliva",olivedrab:"verde bottiglia",orange:"arancione",orangered:"vermiglio",orchid:"orchidea",palegoldenrod:"dorato pallido",palegreen:"verde pallido",paleturquoise:"turchese pallido",palevioletred:"violetto rosso pallido",papayawhip:"papaya",peachpuff:"pesche",peru:"perù",pink:"rosa",plum:"prugna",powderblue:"azzurro polvere",purple:"viola",red:"rosso",rosybrown:"caffè latte",royalblue:"royal blue",saddlebrown:"cacao",salmon:"salmone",sandybrown:"argilla",seagreen:"verde acqua",seashell:"sabbia rosa",sienna:"terra di siena",silver:"argento",skyblue:"azzurro",slateblue:"blu ardesia",slategray:"grigio ardesia",slategrey:"grigio ardesia",snow:"neve",springgreen:"verde brillante",steelblue:"blu brillante",tan:"tan",teal:"verde acqua",thistle:"rosa cenere",tomato:"pomodoro",transparent:"trasparente",turquoise:"turchese",violet:"violetto",wheat:"tabacco",white:"bianco",whitesmoke:"bianco fumo",yellow:"giallo",yellowgreen:"giallo verde"})); diff --git a/lib/dojo/nls/it/colors.js.uncompressed.js b/lib/dojo/nls/it/colors.js.uncompressed.js deleted file mode 100644 index aafbb2d..0000000 --- a/lib/dojo/nls/it/colors.js.uncompressed.js +++ /dev/null @@ -1,156 +0,0 @@ -define( -"dojo/nls/it/colors", ({ -// local representation of all CSS3 named colors, companion to dojo.colors. To be used where descriptive information -// is required for each color, such as a palette widget, and not for specifying color programatically. - //Note: due to the SVG 1.0 spec additions, some of these are alternate spellings for the same color (e.g. gray / grey). - //TODO: should we be using unique rgb values as keys instead and avoid these duplicates, or rely on the caller to do the reverse mapping? - aliceblue: "bianco ghiaccio", - antiquewhite: "rosa antico", - aqua: "verde acqua", - aquamarine: "acquamarina", - azure: "azure", - beige: "beige", - bisque: "terracotta", - black: "nero", - blanchedalmond: "beige 2", - blue: "blu", - blueviolet: "violetto bluastro", - brown: "marrone", - burlywood: "legno massiccio", - cadetblue: "verde petrolio", - chartreuse: "verde brillante", - chocolate: "cioccolato", - coral: "corallo", - cornflowerblue: "blu fiordaliso", - cornsilk: "crema", - crimson: "rosso scarlatto", - cyan: "ciano", - darkblue: "blu scuro", - darkcyan: "celeste scuro", - darkgoldenrod: "ocra scuro", - darkgray: "grigio scuro", - darkgreen: "verde scuro", - darkgrey: "grigio scuro", // same as darkgray - darkkhaki: "cachi scuro", - darkmagenta: "magenta scuro", - darkolivegreen: "verde oliva scuro", - darkorange: "arancione scuro", - darkorchid: "orchidea scuro", - darkred: "rosso scuro", - darksalmon: "salmone scuro", - darkseagreen: "verde acqua scuro", - darkslateblue: "blu ardesia scuro", - darkslategray: "grigio ardesia scuro", - darkslategrey: "grigio ardesia scuro", // same as darkslategray - darkturquoise: "turchese scuro", - darkviolet: "viola scuro", - deeppink: "ciclamino", - deepskyblue: "azzurro intenso", - dimgray: "grigio tenue", - dimgrey: "grigio tenue", // same as dimgray - dodgerblue: "dodger blue", - firebrick: "mattone", - floralwhite: "bianco grigio", - forestgreen: "verde pino scuro", - fuchsia: "fucsia", - gainsboro: "gainsboro", - ghostwhite: "bianco gesso", - gold: "oro", - goldenrod: "dorato", - gray: "grigio", - green: "verde", - greenyellow: "verde-giallo", - grey: "grigio", // same as gray - honeydew: "miele", - hotpink: "rosa acceso", - indianred: "terra indiana", - indigo: "indaco", - ivory: "avorio", - khaki: "cachi", - lavender: "lavanda", - lavenderblush: "lavanda rosa", - lawngreen: "verde brillante chiaro", - lemonchiffon: "lemon chiffon", - lightblue: "blu chiaro", - lightcoral: "corallo chiaro", - lightcyan: "ciano chiaro", - lightgoldenrodyellow: "giallo dorato chiaro", - lightgray: "grigio chiaro", - lightgreen: "verde chiaro", - lightgrey: "grigio chiaro", // same as lightgray - lightpink: "rosa chiaro", - lightsalmon: "salmone chiaro", - lightseagreen: "verde acqua chiaro", - lightskyblue: "azzurro chiaro", - lightslategray: "grigio ardesia chiaro", - lightslategrey: "grigio ardesia chiaro", // same as lightslategray - lightsteelblue: "blu acciaio chiaro", - lightyellow: "giallo chiaro", - lime: "lime", - limegreen: "verde lime", - linen: "lino", - magenta: "magenta", - maroon: "Bordeaux", - mediumaquamarine: "acquamarina medio", - mediumblue: "blu medio", - mediumorchid: "orchidea medio", - mediumpurple: "viola medio", - mediumseagreen: "verde acqua medio", - mediumslateblue: "blu ardesia medio", - mediumspringgreen: "verde brillante medio", - mediumturquoise: "turchese medio", - mediumvioletred: "violetto rosso medio", - midnightblue: "blu notte", - mintcream: "bianco nuvola", - mistyrose: "rosa pallido", - moccasin: "mocassino", - navajowhite: "sabbia", - navy: "blu scuro", - oldlace: "mandorla", - olive: "verde oliva", - olivedrab: "verde bottiglia", - orange: "arancione", - orangered: "vermiglio", - orchid: "orchidea", - palegoldenrod: "dorato pallido", - palegreen: "verde pallido", - paleturquoise: "turchese pallido", - palevioletred: "violetto rosso pallido", - papayawhip: "papaya", - peachpuff: "pesche", - peru: "perù", - pink: "rosa", - plum: "prugna", - powderblue: "azzurro polvere", - purple: "viola", - red: "rosso", - rosybrown: "caffè latte", - royalblue: "royal blue", - saddlebrown: "cacao", - salmon: "salmone", - sandybrown: "argilla", - seagreen: "verde acqua", - seashell: "sabbia rosa", - sienna: "terra di siena", - silver: "argento", - skyblue: "azzurro", - slateblue: "blu ardesia", - slategray: "grigio ardesia", - slategrey: "grigio ardesia", // same as slategray - snow: "neve", - springgreen: "verde brillante", - steelblue: "blu brillante", - tan: "tan", - teal: "verde acqua", - thistle: "rosa cenere", - tomato: "pomodoro", - transparent: "trasparente", - turquoise: "turchese", - violet: "violetto", - wheat: "tabacco", - white: "bianco", - whitesmoke: "bianco fumo", - yellow: "giallo", - yellowgreen: "giallo verde" -}) -); diff --git a/lib/dojo/nls/ja/colors.js b/lib/dojo/nls/ja/colors.js deleted file mode 100644 index 820c1b2..0000000 --- a/lib/dojo/nls/ja/colors.js +++ /dev/null @@ -1,8 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/nls/ja/colors",({aliceblue:"アリスブルー",antiquewhite:"アンティークホワイト",aqua:"アクア",aquamarine:"碧緑",azure:"薄い空色",beige:"ベージュ",bisque:"ビスク",black:"黒",blanchedalmond:"皮なしアーモンド",blue:"青",blueviolet:"青紫",brown:"茶",burlywood:"バーリーウッド",cadetblue:"くすんだ青",chartreuse:"淡黄緑",chocolate:"チョコレート",coral:"珊瑚",cornflowerblue:"コーンフラワーブルー",cornsilk:"コーンシルク",crimson:"深紅",cyan:"シアンブルー",darkblue:"ダークブルー",darkcyan:"ダークシアンブルー",darkgoldenrod:"ダークゴールデンロッド",darkgray:"ダークグレイ",darkgreen:"ダークグリーン",darkgrey:"ダークグレイ",darkkhaki:"ダークカーキ",darkmagenta:"ダークマジェンタ",darkolivegreen:"ダークオリーブグリーン",darkorange:"ダークオレンジ",darkorchid:"ダークオーキッド",darkred:"ダークレッド",darksalmon:"ダークサーモン",darkseagreen:"ダークシーグリーン",darkslateblue:"ダークスレートブルー",darkslategray:"ダークスレートグレイ",darkslategrey:"ダークスレートグレイ",darkturquoise:"ダークターコイズ",darkviolet:"ダークバイオレット",deeppink:"濃いピンク",deepskyblue:"濃い空色",dimgray:"くすんだグレイ",dimgrey:"くすんだグレイ",dodgerblue:"ドッジャーブルー",firebrick:"赤煉瓦色",floralwhite:"フローラルホワイト",forestgreen:"フォレストグリーン",fuchsia:"紫紅色",gainsboro:"ゲインズボーロ",ghostwhite:"ゴーストホワイト",gold:"金",goldenrod:"ゴールデンロッド",gray:"グレイ",green:"緑",greenyellow:"緑黄色",grey:"グレイ",honeydew:"ハニーデュー",hotpink:"ホットピンク",indianred:"インディアンレッド",indigo:"藍色",ivory:"アイボリー",khaki:"カーキ",lavender:"ラベンダー",lavenderblush:"ラベンダーブラッシ",lawngreen:"ローングリーン",lemonchiffon:"レモンシフォン",lightblue:"ライトブルー",lightcoral:"ライトコーラル",lightcyan:"ライトシアン",lightgoldenrodyellow:"ライトゴールデンロッドイエロー",lightgray:"ライトグレイ",lightgreen:"ライトグリーン",lightgrey:"ライトグレイ",lightpink:"ライトピンク",lightsalmon:"ライトサーモン",lightseagreen:"ライトシーグリーン",lightskyblue:"ライトスカイブルー",lightslategray:"ライトスレートグレイ",lightslategrey:"ライトスレートグレイ",lightsteelblue:"ライトスチールブルー",lightyellow:"ライトイエロー",lime:"ライム",limegreen:"ライムグリーン",linen:"亜麻色",magenta:"赤紫",maroon:"えび茶",mediumaquamarine:"ミディアムアクアマリーン",mediumblue:"ミディアムブルー",mediumorchid:"ミディアムオーキッド",mediumpurple:"ミディアムパープル",mediumseagreen:"ミディアムシーグリーン",mediumslateblue:"ミディアムスレートブルー",mediumspringgreen:"ミディアムスプリンググリーン",mediumturquoise:"ミディアムターコイズ",mediumvioletred:"ミディアムバイオレットレッド",midnightblue:"ミッドナイトブルー",mintcream:"ミントクリーム",mistyrose:"ミスティローズ",moccasin:"モカシン",navajowhite:"ナバホホワイト",navy:"濃紺",oldlace:"オールドレイス",olive:"オリーブ",olivedrab:"濃黄緑",orange:"オレンジ",orangered:"オレンジレッド",orchid:"薄紫",palegoldenrod:"ペイルゴールデンロッド",palegreen:"ペイルグリーン",paleturquoise:"ペイルターコイズ",palevioletred:"ペイルバイオレットレッド",papayawhip:"パパイアホイップ",peachpuff:"ピーチパフ",peru:"ペルー",pink:"ピンク",plum:"深紫",powderblue:"淡青",purple:"紫",red:"赤",rosybrown:"ロージーブラウン",royalblue:"藤色",saddlebrown:"サドルブラウン",salmon:"サーモン",sandybrown:"砂褐色",seagreen:"シーグリーン",seashell:"シーシェル",sienna:"黄褐色",silver:"銀",skyblue:"スカイブルー",slateblue:"スレートブルー",slategray:"スレートグレイ",slategrey:"スレートグレイ",snow:"雪色",springgreen:"スプリンググリーン",steelblue:"鋼色",tan:"茶褐色",teal:"ティール",thistle:"シスル",tomato:"トマト色",transparent:"透明",turquoise:"ターコイズ",violet:"すみれ色",wheat:"小麦色",white:"白",whitesmoke:"ホワイトスモーク",yellow:"黄",yellowgreen:"黄緑"})); diff --git a/lib/dojo/nls/ja/colors.js.uncompressed.js b/lib/dojo/nls/ja/colors.js.uncompressed.js deleted file mode 100644 index 7051d78..0000000 --- a/lib/dojo/nls/ja/colors.js.uncompressed.js +++ /dev/null @@ -1,156 +0,0 @@ -define( -"dojo/nls/ja/colors", ({ -// local representation of all CSS3 named colors, companion to dojo.colors. To be used where descriptive information -// is required for each color, such as a palette widget, and not for specifying color programatically. - //Note: due to the SVG 1.0 spec additions, some of these are alternate spellings for the same color (e.g. gray / grey). - //TODO: should we be using unique rgb values as keys instead and avoid these duplicates, or rely on the caller to do the reverse mapping? - aliceblue: "アリスブルー", - antiquewhite: "アンティークホワイト", - aqua: "アクア", - aquamarine: "碧緑", - azure: "薄い空色", - beige: "ベージュ", - bisque: "ビスク", - black: "黒", - blanchedalmond: "皮なしアーモンド", - blue: "青", - blueviolet: "青紫", - brown: "茶", - burlywood: "バーリーウッド", - cadetblue: "くすんだ青", - chartreuse: "淡黄緑", - chocolate: "チョコレート", - coral: "珊瑚", - cornflowerblue: "コーンフラワーブルー", - cornsilk: "コーンシルク", - crimson: "深紅", - cyan: "シアンブルー", - darkblue: "ダークブルー", - darkcyan: "ダークシアンブルー", - darkgoldenrod: "ダークゴールデンロッド", - darkgray: "ダークグレイ", - darkgreen: "ダークグリーン", - darkgrey: "ダークグレイ", // same as darkgray - darkkhaki: "ダークカーキ", - darkmagenta: "ダークマジェンタ", - darkolivegreen: "ダークオリーブグリーン", - darkorange: "ダークオレンジ", - darkorchid: "ダークオーキッド", - darkred: "ダークレッド", - darksalmon: "ダークサーモン", - darkseagreen: "ダークシーグリーン", - darkslateblue: "ダークスレートブルー", - darkslategray: "ダークスレートグレイ", - darkslategrey: "ダークスレートグレイ", // same as darkslategray - darkturquoise: "ダークターコイズ", - darkviolet: "ダークバイオレット", - deeppink: "濃いピンク", - deepskyblue: "濃い空色", - dimgray: "くすんだグレイ", - dimgrey: "くすんだグレイ", // same as dimgray - dodgerblue: "ドッジャーブルー", - firebrick: "赤煉瓦色", - floralwhite: "フローラルホワイト", - forestgreen: "フォレストグリーン", - fuchsia: "紫紅色", - gainsboro: "ゲインズボーロ", - ghostwhite: "ゴーストホワイト", - gold: "金", - goldenrod: "ゴールデンロッド", - gray: "グレイ", - green: "緑", - greenyellow: "緑黄色", - grey: "グレイ", // same as gray - honeydew: "ハニーデュー", - hotpink: "ホットピンク", - indianred: "インディアンレッド", - indigo: "藍色", - ivory: "アイボリー", - khaki: "カーキ", - lavender: "ラベンダー", - lavenderblush: "ラベンダーブラッシ", - lawngreen: "ローングリーン", - lemonchiffon: "レモンシフォン", - lightblue: "ライトブルー", - lightcoral: "ライトコーラル", - lightcyan: "ライトシアン", - lightgoldenrodyellow: "ライトゴールデンロッドイエロー", - lightgray: "ライトグレイ", - lightgreen: "ライトグリーン", - lightgrey: "ライトグレイ", // same as lightgray - lightpink: "ライトピンク", - lightsalmon: "ライトサーモン", - lightseagreen: "ライトシーグリーン", - lightskyblue: "ライトスカイブルー", - lightslategray: "ライトスレートグレイ", - lightslategrey: "ライトスレートグレイ", // same as lightslategray - lightsteelblue: "ライトスチールブルー", - lightyellow: "ライトイエロー", - lime: "ライム", - limegreen: "ライムグリーン", - linen: "亜麻色", - magenta: "赤紫", - maroon: "えび茶", - mediumaquamarine: "ミディアムアクアマリーン", - mediumblue: "ミディアムブルー", - mediumorchid: "ミディアムオーキッド", - mediumpurple: "ミディアムパープル", - mediumseagreen: "ミディアムシーグリーン", - mediumslateblue: "ミディアムスレートブルー", - mediumspringgreen: "ミディアムスプリンググリーン", - mediumturquoise: "ミディアムターコイズ", - mediumvioletred: "ミディアムバイオレットレッド", - midnightblue: "ミッドナイトブルー", - mintcream: "ミントクリーム", - mistyrose: "ミスティローズ", - moccasin: "モカシン", - navajowhite: "ナバホホワイト", - navy: "濃紺", - oldlace: "オールドレイス", - olive: "オリーブ", - olivedrab: "濃黄緑", - orange: "オレンジ", - orangered: "オレンジレッド", - orchid: "薄紫", - palegoldenrod: "ペイルゴールデンロッド", - palegreen: "ペイルグリーン", - paleturquoise: "ペイルターコイズ", - palevioletred: "ペイルバイオレットレッド", - papayawhip: "パパイアホイップ", - peachpuff: "ピーチパフ", - peru: "ペルー", - pink: "ピンク", - plum: "深紫", - powderblue: "淡青", - purple: "紫", - red: "赤", - rosybrown: "ロージーブラウン", - royalblue: "藤色", - saddlebrown: "サドルブラウン", - salmon: "サーモン", - sandybrown: "砂褐色", - seagreen: "シーグリーン", - seashell: "シーシェル", - sienna: "黄褐色", - silver: "銀", - skyblue: "スカイブルー", - slateblue: "スレートブルー", - slategray: "スレートグレイ", - slategrey: "スレートグレイ", // same as slategray - snow: "雪色", - springgreen: "スプリンググリーン", - steelblue: "鋼色", - tan: "茶褐色", - teal: "ティール", - thistle: "シスル", - tomato: "トマト色", - transparent: "透明", - turquoise: "ターコイズ", - violet: "すみれ色", - wheat: "小麦色", - white: "白", - whitesmoke: "ホワイトスモーク", - yellow: "黄", - yellowgreen: "黄緑" -}) -); diff --git a/lib/dojo/nls/kk/colors.js b/lib/dojo/nls/kk/colors.js deleted file mode 100644 index 8a796f2..0000000 --- a/lib/dojo/nls/kk/colors.js +++ /dev/null @@ -1,8 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/nls/kk/colors",({aliceblue:"бозғылт көк",antiquewhite:"ақ антик",aqua:"су түсі",aquamarine:"жасылдау-көк",azure:"көкшіл",beige:"сарғыш",bisque:"бисквит",black:"қара",blanchedalmond:"ағартылған бадам",blue:"көк",blueviolet:"көк-ақшыл көк",brown:"қоңыр",burlywood:"ағаш тамыры",cadetblue:"кадет көк",chartreuse:"жасылдау-сары",chocolate:"шоколад",coral:"коралл",cornflowerblue:"көктікен көк",cornsilk:"жібек",crimson:"таңқұрай",cyan:"циан",darkblue:"күңгірт көк",darkcyan:"күңгірт циан",darkgoldenrod:"қара алтын",darkgray:"қою сұры",darkgreen:"қою жасыл",darkgrey:"қою сұры",darkkhaki:"қою хаки",darkmagenta:"қою қызыл күрең",darkolivegreen:"қою қоңырлау жасыл",darkorange:"қою қызғылт сары",darkorchid:"күңгірт орсель",darkred:"күңгірт қызыл",darksalmon:"қою сарылау қызғылт",darkseagreen:"қою теңіз толқыны",darkslateblue:"күңгірт грифель көк",darkslategray:"күңгірт көкшіл сұры",darkslategrey:"күңгірт көкшіл сұры",darkturquoise:"күңгірт көгілдір",darkviolet:"күңгірт қызыл күрең",deeppink:"қою қызғылт",deepskyblue:"қою аспан көк",dimgray:"күңгірт сұры",dimgrey:"күңгірт сұры",dodgerblue:"көк доджер",firebrick:"қызыл кірпіш",floralwhite:"гүлді ақ",forestgreen:"шөпті жасыл",fuchsia:"фуксия",gainsboro:"gainsboro",ghostwhite:"елесті ақ",gold:"алтындай",goldenrod:"алтын",gray:"сұры",green:"жасыл",greenyellow:"жасыл-сары",grey:"сұры",honeydew:"балдай",hotpink:"ашық қызғылт",indianred:"үнділік қызыл",indigo:"индиго",ivory:"піл сүйег",khaki:"хаки",lavender:"бозғылт ақшыл көк",lavenderblush:"күңгірт ақшыл қызыл",lawngreen:"көгал жасыл",lemonchiffon:"лимон шиффон",lightblue:"ақшыл көк",lightcoral:"ашық коралл",lightcyan:"ашық көгілдір",lightgoldenrodyellow:"ашық алтындай сары",lightgray:"ашық сұры",lightgreen:"ақшыл жасыл",lightgrey:"ашық сұры",lightpink:"ақшыл қызғылт",lightsalmon:"ашық сарғыш қызғылт",lightseagreen:"ашық теңіз толқыны",lightskyblue:"ашық аспан көк",lightslategray:"ашық көкшіл сұры",lightslategrey:"ашық көкшіл сұры",lightsteelblue:"ашық сұрғылт көк",lightyellow:"ашық сары",lime:"әк",limegreen:"әк жасыл",linen:"зығыр",magenta:"фуксин",maroon:"сарғылт",mediumaquamarine:"орташа жасылдау көк",mediumblue:"орташа көк",mediumorchid:"орташа ақшыл",mediumpurple:"орташа қызыл күрең",mediumseagreen:"орташа теңіз толқыны",mediumslateblue:"орташа көкшіл сұры",mediumspringgreen:"орташа ашық жасыл",mediumturquoise:"орташа көгілдір",mediumvioletred:"орташа ақшыл көк-қызыл",midnightblue:"түн ортасы көк",mintcream:"жалбыз майы",mistyrose:"көмескі қызғылт",moccasin:"мокасин",navajowhite:"навахо ақ",navy:"теңіз көк",oldlace:"ескі бау",olive:"зәйтүнді",olivedrab:"жасылдау сары",orange:"қызғылт сары",orangered:"қызғылт сары қызыл",orchid:"орхидея",palegoldenrod:"бозғылт алтын",palegreen:"бозғылт жасыл",paleturquoise:"бозғылт көгілдір",palevioletred:"бозғылт ақшыл көк-қызыл",papayawhip:"папайя қамшысы",peachpuff:"шабдалы",peru:"перу",pink:"қызғылт",plum:"алхоры",powderblue:"жасылдау көк",purple:"қызыл күрең",red:"қызыл",rosybrown:"қызғылт қоңыр",royalblue:"патша көк",saddlebrown:"тоқым қоңыр",salmon:"сомон",sandybrown:"құмды қоңыр",seagreen:"теңіз толқыны",seashell:"теңіз қабыршағы",sienna:"сиенна",silver:"күмістей",skyblue:"аспан көк",slateblue:"грифель көк",slategray:"көкшіл сұры",slategrey:"көкшіл сұры",snow:"қар",springgreen:"көктем жасыл",steelblue:"көкшіл сұрғылт",tan:"сарғыш қоңыр",teal:"шүрегей",thistle:"артишок",tomato:"қызанақ",transparent:"мөлдір",turquoise:"көгілдір",violet:"күлгін",wheat:"бидай",white:"ақ",whitesmoke:"ақ түтін",yellow:"сары",yellowgreen:"сарғыш жасыл"})); diff --git a/lib/dojo/nls/kk/colors.js.uncompressed.js b/lib/dojo/nls/kk/colors.js.uncompressed.js deleted file mode 100644 index d7aa08c..0000000 --- a/lib/dojo/nls/kk/colors.js.uncompressed.js +++ /dev/null @@ -1,156 +0,0 @@ -define( -"dojo/nls/kk/colors", ({ -// local representation of all CSS3 named colors, companion to dojo.colors. To be used where descriptive information -// is required for each color, such as a palette widget, and not for specifying color programatically. - //Note: due to the SVG 1.0 spec additions, some of these are alternate spellings for the same color (e.g. gray / grey). - //TODO: should we be using unique rgb values as keys instead and avoid these duplicates, or rely on the caller to do the reverse mapping? - aliceblue: "бозғылт көк", - antiquewhite: "ақ антик", - aqua: "су түсі", - aquamarine: "жасылдау-көк", - azure: "көкшіл", - beige: "сарғыш", - bisque: "бисквит", - black: "қара", - blanchedalmond: "ағартылған бадам", - blue: "көк", - blueviolet: "көк-ақшыл көк", - brown: "қоңыр", - burlywood: "ағаш тамыры", - cadetblue: "кадет көк", - chartreuse: "жасылдау-сары", - chocolate: "шоколад", - coral: "коралл", - cornflowerblue: "көктікен көк", - cornsilk: "жібек", - crimson: "таңқұрай", - cyan: "циан", - darkblue: "күңгірт көк", - darkcyan: "күңгірт циан", - darkgoldenrod: "қара алтын", - darkgray: "қою сұры", - darkgreen: "қою жасыл", - darkgrey: "қою сұры", // same as darkgray - darkkhaki: "қою хаки", - darkmagenta: "қою қызыл күрең", - darkolivegreen: "қою қоңырлау жасыл", - darkorange: "қою қызғылт сары", - darkorchid: "күңгірт орсель", - darkred: "күңгірт қызыл", - darksalmon: "қою сарылау қызғылт", - darkseagreen: "қою теңіз толқыны", - darkslateblue: "күңгірт грифель көк", - darkslategray: "күңгірт көкшіл сұры", - darkslategrey: "күңгірт көкшіл сұры", // same as darkslategray - darkturquoise: "күңгірт көгілдір", - darkviolet: "күңгірт қызыл күрең", - deeppink: "қою қызғылт", - deepskyblue: "қою аспан көк", - dimgray: "күңгірт сұры", - dimgrey: "күңгірт сұры", // same as dimgray - dodgerblue: "көк доджер", - firebrick: "қызыл кірпіш", - floralwhite: "гүлді ақ", - forestgreen: "шөпті жасыл", - fuchsia: "фуксия", - gainsboro: "gainsboro", - ghostwhite: "елесті ақ", - gold: "алтындай", - goldenrod: "алтын", - gray: "сұры", - green: "жасыл", - greenyellow: "жасыл-сары", - grey: "сұры", // same as gray - honeydew: "балдай", - hotpink: "ашық қызғылт", - indianred: "үнділік қызыл", - indigo: "индиго", - ivory: "піл сүйег", - khaki: "хаки", - lavender: "бозғылт ақшыл көк", - lavenderblush: "күңгірт ақшыл қызыл", - lawngreen: "көгал жасыл", - lemonchiffon: "лимон шиффон", - lightblue: "ақшыл көк", - lightcoral: "ашық коралл", - lightcyan: "ашық көгілдір", - lightgoldenrodyellow: "ашық алтындай сары", - lightgray: "ашық сұры", - lightgreen: "ақшыл жасыл", - lightgrey: "ашық сұры", // same as lightgray - lightpink: "ақшыл қызғылт", - lightsalmon: "ашық сарғыш қызғылт", - lightseagreen: "ашық теңіз толқыны", - lightskyblue: "ашық аспан көк", - lightslategray: "ашық көкшіл сұры", - lightslategrey: "ашық көкшіл сұры", // same as lightslategray - lightsteelblue: "ашық сұрғылт көк", - lightyellow: "ашық сары", - lime: "әк", - limegreen: "әк жасыл", - linen: "зығыр", - magenta: "фуксин", - maroon: "сарғылт", - mediumaquamarine: "орташа жасылдау көк", - mediumblue: "орташа көк", - mediumorchid: "орташа ақшыл", - mediumpurple: "орташа қызыл күрең", - mediumseagreen: "орташа теңіз толқыны", - mediumslateblue: "орташа көкшіл сұры", - mediumspringgreen: "орташа ашық жасыл", - mediumturquoise: "орташа көгілдір", - mediumvioletred: "орташа ақшыл көк-қызыл", - midnightblue: "түн ортасы көк", - mintcream: "жалбыз майы", - mistyrose: "көмескі қызғылт", - moccasin: "мокасин", - navajowhite: "навахо ақ", - navy: "теңіз көк", - oldlace: "ескі бау", - olive: "зәйтүнді", - olivedrab: "жасылдау сары", - orange: "қызғылт сары", - orangered: "қызғылт сары қызыл", - orchid: "орхидея", - palegoldenrod: "бозғылт алтын", - palegreen: "бозғылт жасыл", - paleturquoise: "бозғылт көгілдір", - palevioletred: "бозғылт ақшыл көк-қызыл", - papayawhip: "папайя қамшысы", - peachpuff: "шабдалы", - peru: "перу", - pink: "қызғылт", - plum: "алхоры", - powderblue: "жасылдау көк", - purple: "қызыл күрең", - red: "қызыл", - rosybrown: "қызғылт қоңыр", - royalblue: "патша көк", - saddlebrown: "тоқым қоңыр", - salmon: "сомон", - sandybrown: "құмды қоңыр", - seagreen: "теңіз толқыны", - seashell: "теңіз қабыршағы", - sienna: "сиенна", - silver: "күмістей", - skyblue: "аспан көк", - slateblue: "грифель көк", - slategray: "көкшіл сұры", - slategrey: "көкшіл сұры", // same as slategray - snow: "қар", - springgreen: "көктем жасыл", - steelblue: "көкшіл сұрғылт", - tan: "сарғыш қоңыр", - teal: "шүрегей", - thistle: "артишок", - tomato: "қызанақ", - transparent: "мөлдір", - turquoise: "көгілдір", - violet: "күлгін", - wheat: "бидай", - white: "ақ", - whitesmoke: "ақ түтін", - yellow: "сары", - yellowgreen: "сарғыш жасыл" -}) -); diff --git a/lib/dojo/nls/ko/colors.js b/lib/dojo/nls/ko/colors.js deleted file mode 100644 index e440857..0000000 --- a/lib/dojo/nls/ko/colors.js +++ /dev/null @@ -1,8 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/nls/ko/colors",({aliceblue:"앨리스 블루(alice blue)",antiquewhite:"앤틱 화이트(antique white)",aqua:"아쿠아(aqua)",aquamarine:"아쿠아마린(aquamarine)",azure:"애쥬어(azure)",beige:"베이지(beige)",bisque:"비스크(bisque)",black:"블랙(black)",blanchedalmond:"블랜치 아몬드(blanched almond)",blue:"블루(blue)",blueviolet:"블루 바이올렛(blue-violet)",brown:"브라운(brown)",burlywood:"벌리우드(burlywood)",cadetblue:"카뎃 블루(cadet blue)",chartreuse:"샤르트뢰즈(chartreuse)",chocolate:"초콜렛(chocolate)",coral:"코랄(coral)",cornflowerblue:"콘플라워 블루(cornflower blue)",cornsilk:"콘실크(cornsilk)",crimson:"크림슨(crimson)",cyan:"시안(cyan)",darkblue:"다크 블루(dark blue)",darkcyan:"다크 시안(dark cyan)",darkgoldenrod:"다크 골든로드(dark goldenrod)",darkgray:"다크 그레이(dark gray)",darkgreen:"다크 그린(dark green)",darkgrey:"다크 그레이(dark gray)",darkkhaki:"다크 카키(dark khaki)",darkmagenta:"다크 마젠타(dark magenta)",darkolivegreen:"다크 올리브 그린(dark olive green)",darkorange:"다크 오렌지(dark orange)",darkorchid:"다크 오키드(dark orchid)",darkred:"다크 레드(dark red)",darksalmon:"다크 샐몬(dark salmon)",darkseagreen:"다크 씨 그린(dark sea green)",darkslateblue:"다크 슬레이트 블루(dark slate blue)",darkslategray:"다크 슬레이트 그레이(dark slate gray)",darkslategrey:"다크 슬레이트 그레이(dark slate gray)",darkturquoise:"다크 터콰즈(dark turquoise)",darkviolet:"다크 바이올렛(dark violet)",deeppink:"딥 핑크(deep pink)",deepskyblue:"딥 스카이 블루(deep sky blue)",dimgray:"딤 그레이(dim gray)",dimgrey:"딤 그레이(dim gray)",dodgerblue:"다저 블루(dodger blue)",firebrick:"파이어 브릭(fire brick)",floralwhite:"플로랄 화이트(floral white)",forestgreen:"포레스트 그린(forest green)",fuchsia:"후크샤(fuchsia)",gainsboro:"게인스브로(gainsboro)",ghostwhite:"고스트 화이트(ghost white)",gold:"골드(gold)",goldenrod:"골든로드(goldenrod)",gray:"그레이(gray)",green:"그린(green)",greenyellow:"그린 옐로우(green-yellow)",grey:"그레이(gray)",honeydew:"허니듀(honeydew)",hotpink:"핫 핑크(hot pink)",indianred:"인디안 레드(indian red)",indigo:"인디고(indigo)",ivory:"아이보리(ivory)",khaki:"카키(khaki)",lavender:"라벤더(lavender)",lavenderblush:"라벤더 블러쉬(lavender blush)",lawngreen:"론 그린(lawn green)",lemonchiffon:"레몬 쉬폰(lemon chiffon)",lightblue:"라이트 블루(light blue)",lightcoral:"라이트 코랄(light coral)",lightcyan:"라이트 시안(light cyan)",lightgoldenrodyellow:"라이트 골든로드 옐로우(light goldenrod yellow)",lightgray:"라이트 그레이(light gray)",lightgreen:"라이트 그린(light green)",lightgrey:"라이트 그레이(light gray)",lightpink:"라이트 핑크(light pink)",lightsalmon:"라이트 샐몬(light salmon)",lightseagreen:"라이트 씨 그린(light sea green)",lightskyblue:"라이트 스카이 블루(light sky blue)",lightslategray:"라이트 슬레이트 그레이(light slate gray)",lightslategrey:"라이트 슬레이트 그레이(light slate gray)",lightsteelblue:"라이트 스틸 블루(light steel blue)",lightyellow:"라이트 옐로우(light yellow)",lime:"라임(lime)",limegreen:"라임 그린(lime green)",linen:"리넨(linen)",magenta:"마젠타(magenta)",maroon:"마룬(maroon)",mediumaquamarine:"미디엄 아쿠아마린(medium aquamarine)",mediumblue:"미디엄 블루(medium blue)",mediumorchid:"미디엄 오키드(medium orchid)",mediumpurple:"미디엄 퍼플(medium purple)",mediumseagreen:"미디엄 씨 그린(medium sea green)",mediumslateblue:"미디엄 슬레이트 블루(medium slate blue)",mediumspringgreen:"미디엄 스프링 그린(medium spring green)",mediumturquoise:"미디엄 터콰즈(medium turquoise)",mediumvioletred:"미디엄 바이올렛 레드(medium violet-red)",midnightblue:"미드나잇 블루(midnight blue)",mintcream:"민트 크림(mint cream)",mistyrose:"미스티 로즈(misty rose)",moccasin:"모카신(moccasin)",navajowhite:"나바호 화이트(navajo white)",navy:"네이비(navy)",oldlace:"올드 레이스(old lace)",olive:"올리브(olive)",olivedrab:"올리브 드랩(olive drab)",orange:"오렌지(orange)",orangered:"오렌지 레드(orange red)",orchid:"오키드(orchid)",palegoldenrod:"페일 골든로드(pale goldenrod)",palegreen:"페일 그린(pale green)",paleturquoise:"페일 터콰즈(pale turquoise)",palevioletred:"페일 바이올렛 레드(pale violet-red)",papayawhip:"파파야 휩(papaya whip)",peachpuff:"피치 퍼프(peach puff)",peru:"페루(peru)",pink:"핑크(pink)",plum:"플럼(plum)",powderblue:"파우더 블루(powder blue)",purple:"퍼플(purple)",red:"레드(red)",rosybrown:"로지 브라운(rosy brown)",royalblue:"로얄 블루(royal blue)",saddlebrown:"새들 브라운(saddle brown)",salmon:"샐몬(salmon)",sandybrown:"샌디 브라운(sandy brown)",seagreen:"씨 그린(sea green)",seashell:"씨쉘(seashell)",sienna:"시에나(sienna)",silver:"실버(silver)",skyblue:"스카이 블루(sky blue)",slateblue:"슬레이트 블루(slate blue)",slategray:"슬레이트 그레이(slate gray)",slategrey:"슬레이트 그레이(slate gray)",snow:"스노우(snow)",springgreen:"스프링 그린(spring green)",steelblue:"스틸 블루(steel blue)",tan:"탠(tan)",teal:"틸(teal)",thistle:"시슬(thistle)",tomato:"토마토(tomato)",transparent:"투명(transparent)",turquoise:"터콰즈(turquoise)",violet:"바이올렛(violet)",wheat:"휘트(wheat)",white:"화이트(white)",whitesmoke:"화이트 스모크(white smoke)",yellow:"옐로우(yellow)",yellowgreen:"옐로우 그린(yellow green)"})); diff --git a/lib/dojo/nls/ko/colors.js.uncompressed.js b/lib/dojo/nls/ko/colors.js.uncompressed.js deleted file mode 100644 index 901b3c9..0000000 --- a/lib/dojo/nls/ko/colors.js.uncompressed.js +++ /dev/null @@ -1,156 +0,0 @@ -define( -"dojo/nls/ko/colors", ({ -// local representation of all CSS3 named colors, companion to dojo.colors. To be used where descriptive information -// is required for each color, such as a palette widget, and not for specifying color programatically. - //Note: due to the SVG 1.0 spec additions, some of these are alternate spellings for the same color (e.g. gray / grey). - //TODO: should we be using unique rgb values as keys instead and avoid these duplicates, or rely on the caller to do the reverse mapping? - aliceblue: "앨리스 블루(alice blue)", - antiquewhite: "앤틱 화이트(antique white)", - aqua: "아쿠아(aqua)", - aquamarine: "아쿠아마린(aquamarine)", - azure: "애쥬어(azure)", - beige: "베이지(beige)", - bisque: "비스크(bisque)", - black: "블랙(black)", - blanchedalmond: "블랜치 아몬드(blanched almond)", - blue: "블루(blue)", - blueviolet: "블루 바이올렛(blue-violet)", - brown: "브라운(brown)", - burlywood: "벌리우드(burlywood)", - cadetblue: "카뎃 블루(cadet blue)", - chartreuse: "샤르트뢰즈(chartreuse)", - chocolate: "초콜렛(chocolate)", - coral: "코랄(coral)", - cornflowerblue: "콘플라워 블루(cornflower blue)", - cornsilk: "콘실크(cornsilk)", - crimson: "크림슨(crimson)", - cyan: "시안(cyan)", - darkblue: "다크 블루(dark blue)", - darkcyan: "다크 시안(dark cyan)", - darkgoldenrod: "다크 골든로드(dark goldenrod)", - darkgray: "다크 그레이(dark gray)", - darkgreen: "다크 그린(dark green)", - darkgrey: "다크 그레이(dark gray)", // same as darkgray - darkkhaki: "다크 카키(dark khaki)", - darkmagenta: "다크 마젠타(dark magenta)", - darkolivegreen: "다크 올리브 그린(dark olive green)", - darkorange: "다크 오렌지(dark orange)", - darkorchid: "다크 오키드(dark orchid)", - darkred: "다크 레드(dark red)", - darksalmon: "다크 샐몬(dark salmon)", - darkseagreen: "다크 씨 그린(dark sea green)", - darkslateblue: "다크 슬레이트 블루(dark slate blue)", - darkslategray: "다크 슬레이트 그레이(dark slate gray)", - darkslategrey: "다크 슬레이트 그레이(dark slate gray)", // same as darkslategray - darkturquoise: "다크 터콰즈(dark turquoise)", - darkviolet: "다크 바이올렛(dark violet)", - deeppink: "딥 핑크(deep pink)", - deepskyblue: "딥 스카이 블루(deep sky blue)", - dimgray: "딤 그레이(dim gray)", - dimgrey: "딤 그레이(dim gray)", // same as dimgray - dodgerblue: "다저 블루(dodger blue)", - firebrick: "파이어 브릭(fire brick)", - floralwhite: "플로랄 화이트(floral white)", - forestgreen: "포레스트 그린(forest green)", - fuchsia: "후크샤(fuchsia)", - gainsboro: "게인스브로(gainsboro)", - ghostwhite: "고스트 화이트(ghost white)", - gold: "골드(gold)", - goldenrod: "골든로드(goldenrod)", - gray: "그레이(gray)", - green: "그린(green)", - greenyellow: "그린 옐로우(green-yellow)", - grey: "그레이(gray)", // same as gray - honeydew: "허니듀(honeydew)", - hotpink: "핫 핑크(hot pink)", - indianred: "인디안 레드(indian red)", - indigo: "인디고(indigo)", - ivory: "아이보리(ivory)", - khaki: "카키(khaki)", - lavender: "라벤더(lavender)", - lavenderblush: "라벤더 블러쉬(lavender blush)", - lawngreen: "론 그린(lawn green)", - lemonchiffon: "레몬 쉬폰(lemon chiffon)", - lightblue: "라이트 블루(light blue)", - lightcoral: "라이트 코랄(light coral)", - lightcyan: "라이트 시안(light cyan)", - lightgoldenrodyellow: "라이트 골든로드 옐로우(light goldenrod yellow)", - lightgray: "라이트 그레이(light gray)", - lightgreen: "라이트 그린(light green)", - lightgrey: "라이트 그레이(light gray)", // same as lightgray - lightpink: "라이트 핑크(light pink)", - lightsalmon: "라이트 샐몬(light salmon)", - lightseagreen: "라이트 씨 그린(light sea green)", - lightskyblue: "라이트 스카이 블루(light sky blue)", - lightslategray: "라이트 슬레이트 그레이(light slate gray)", - lightslategrey: "라이트 슬레이트 그레이(light slate gray)", // same as lightslategray - lightsteelblue: "라이트 스틸 블루(light steel blue)", - lightyellow: "라이트 옐로우(light yellow)", - lime: "라임(lime)", - limegreen: "라임 그린(lime green)", - linen: "리넨(linen)", - magenta: "마젠타(magenta)", - maroon: "마룬(maroon)", - mediumaquamarine: "미디엄 아쿠아마린(medium aquamarine)", - mediumblue: "미디엄 블루(medium blue)", - mediumorchid: "미디엄 오키드(medium orchid)", - mediumpurple: "미디엄 퍼플(medium purple)", - mediumseagreen: "미디엄 씨 그린(medium sea green)", - mediumslateblue: "미디엄 슬레이트 블루(medium slate blue)", - mediumspringgreen: "미디엄 스프링 그린(medium spring green)", - mediumturquoise: "미디엄 터콰즈(medium turquoise)", - mediumvioletred: "미디엄 바이올렛 레드(medium violet-red)", - midnightblue: "미드나잇 블루(midnight blue)", - mintcream: "민트 크림(mint cream)", - mistyrose: "미스티 로즈(misty rose)", - moccasin: "모카신(moccasin)", - navajowhite: "나바호 화이트(navajo white)", - navy: "네이비(navy)", - oldlace: "올드 레이스(old lace)", - olive: "올리브(olive)", - olivedrab: "올리브 드랩(olive drab)", - orange: "오렌지(orange)", - orangered: "오렌지 레드(orange red)", - orchid: "오키드(orchid)", - palegoldenrod: "페일 골든로드(pale goldenrod)", - palegreen: "페일 그린(pale green)", - paleturquoise: "페일 터콰즈(pale turquoise)", - palevioletred: "페일 바이올렛 레드(pale violet-red)", - papayawhip: "파파야 휩(papaya whip)", - peachpuff: "피치 퍼프(peach puff)", - peru: "페루(peru)", - pink: "핑크(pink)", - plum: "플럼(plum)", - powderblue: "파우더 블루(powder blue)", - purple: "퍼플(purple)", - red: "레드(red)", - rosybrown: "로지 브라운(rosy brown)", - royalblue: "로얄 블루(royal blue)", - saddlebrown: "새들 브라운(saddle brown)", - salmon: "샐몬(salmon)", - sandybrown: "샌디 브라운(sandy brown)", - seagreen: "씨 그린(sea green)", - seashell: "씨쉘(seashell)", - sienna: "시에나(sienna)", - silver: "실버(silver)", - skyblue: "스카이 블루(sky blue)", - slateblue: "슬레이트 블루(slate blue)", - slategray: "슬레이트 그레이(slate gray)", - slategrey: "슬레이트 그레이(slate gray)", // same as slategray - snow: "스노우(snow)", - springgreen: "스프링 그린(spring green)", - steelblue: "스틸 블루(steel blue)", - tan: "탠(tan)", - teal: "틸(teal)", - thistle: "시슬(thistle)", - tomato: "토마토(tomato)", - transparent: "투명(transparent)", - turquoise: "터콰즈(turquoise)", - violet: "바이올렛(violet)", - wheat: "휘트(wheat)", - white: "화이트(white)", - whitesmoke: "화이트 스모크(white smoke)", - yellow: "옐로우(yellow)", - yellowgreen: "옐로우 그린(yellow green)" -}) -); diff --git a/lib/dojo/nls/nb/colors.js b/lib/dojo/nls/nb/colors.js deleted file mode 100644 index 1350f78..0000000 --- a/lib/dojo/nls/nb/colors.js +++ /dev/null @@ -1,8 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/nls/nb/colors",({aliceblue:"blåhvit",antiquewhite:"antikk hvit",aqua:"akva",aquamarine:"akvamarin",azure:"asur",beige:"beige",bisque:"gulrosa",black:"svart",blanchedalmond:"lys mandel",blue:"blå",blueviolet:"blåfiolett",brown:"brun",burlywood:"matt mellombrun",cadetblue:"mørk grønnblå",chartreuse:"løvgrønn",chocolate:"sjokolade",coral:"korall",cornflowerblue:"kornblå",cornsilk:"cornsilk",crimson:"karmosinrødt",cyan:"cyan",darkblue:"mørk blå",darkcyan:"mørk cyan",darkgoldenrod:"mørk gyldenris",darkgray:"mørk grå",darkgreen:"mørk grønn",darkgrey:"mørk grå",darkkhaki:"mørk khaki",darkmagenta:"mørk magenta",darkolivegreen:"mørk olivengrønn",darkorange:"mørk oransje",darkorchid:"mørk orkide",darkred:"mørk rød",darksalmon:"mørk lakserosa",darkseagreen:"mørk sjøgrønn",darkslateblue:"mørk skiferblå",darkslategray:"mørk skifergrå",darkslategrey:"mørk skifergrå",darkturquoise:"mørk turkis",darkviolet:"mørk fiolett",deeppink:"dyp rosa",deepskyblue:"dyp himmelblå",dimgray:"mørk mørkegrå",dimgrey:"mørk mørkegrå",dodgerblue:"lys havblå",firebrick:"mursteinsrød",floralwhite:"blomsterhvit",forestgreen:"skoggrønn",fuchsia:"fuksia",gainsboro:"lys lys grå",ghostwhite:"egghvit",gold:"gull",goldenrod:"gyldenris",gray:"grå",green:"grønn",greenyellow:"gulgrønn",grey:"grå",honeydew:"grønnhvit",hotpink:"halvmørk rosa",indianred:"rustrød",indigo:"indigo",ivory:"elfenbenshvit",khaki:"khaki",lavender:"lavendel",lavenderblush:"lillahvit",lawngreen:"plengrønn",lemonchiffon:"ferskenfarget",lightblue:"lys blå",lightcoral:"lys korall",lightcyan:"lys cyan",lightgoldenrodyellow:"lys gyldenrisgul",lightgray:"lys grå",lightgreen:"lys grønn",lightgrey:"lys grå",lightpink:"lys rosa",lightsalmon:"lys lakserosa",lightseagreen:"lys sjøgrønn",lightskyblue:"lys himmelblå",lightslategray:"lys skifergrå",lightslategrey:"lys skifergrå",lightsteelblue:"lys stålblå",lightyellow:"lys gul",lime:"lime",limegreen:"limegrønn",linen:"lin",magenta:"magenta",maroon:"rødbrun",mediumaquamarine:"middels akvamarin",mediumblue:"mellomblå",mediumorchid:"middels orkide",mediumpurple:"middels purpur",mediumseagreen:"middels sjøgrønn",mediumslateblue:"middels skiferblå",mediumspringgreen:"middels vårgrønn",mediumturquoise:"middels turkis",mediumvioletred:"middels fiolettrød",midnightblue:"midnattsblå",mintcream:"mintkrem",mistyrose:"lys rosenrød",moccasin:"lys gulbrun",navajowhite:"gulbrun",navy:"marineblå",oldlace:"kniplingshvit",olive:"oliven",olivedrab:"middels olivengrønn",orange:"oransje",orangered:"rødoransje",orchid:"orkide",palegoldenrod:"svak gyldenris",palegreen:"svak grønn",paleturquoise:"svak turkis",palevioletred:"svak fiolettrød",papayawhip:"lys papaya",peachpuff:"brunrosa",peru:"lys nøttebrun",pink:"rosa",plum:"plommefarget",powderblue:"lys grønnblå",purple:"purpur",red:"rød",rosybrown:"brunlilla",royalblue:"kongeblå",saddlebrown:"mørk nøttebrun",salmon:"lakserosa",sandybrown:"sandbrun",seagreen:"sjøgrønn",seashell:"skjellhvit",sienna:"nøttebrun",silver:"sølvfarget",skyblue:"himmelblå",slateblue:"skiferblå",slategray:"skifergrå",slategrey:"skifergrå",snow:"snøhvit",springgreen:"vårgrønn",steelblue:"stålblå",tan:"matt mellombrun",teal:"mørk grønnblå",thistle:"lys grålilla",tomato:"tomatrød",transparent:"gjennomsiktig",turquoise:"turkis",violet:"fiolett",wheat:"varm sienna",white:"hvit",whitesmoke:"røykhvit",yellow:"gul",yellowgreen:"gulgrønn"})); diff --git a/lib/dojo/nls/nb/colors.js.uncompressed.js b/lib/dojo/nls/nb/colors.js.uncompressed.js deleted file mode 100644 index 8345bbb..0000000 --- a/lib/dojo/nls/nb/colors.js.uncompressed.js +++ /dev/null @@ -1,156 +0,0 @@ -define( -"dojo/nls/nb/colors", ({ -// local representation of all CSS3 named colors, companion to dojo.colors. To be used where descriptive information -// is required for each color, such as a palette widget, and not for specifying color programatically. - //Note: due to the SVG 1.0 spec additions, some of these are alternate spellings for the same color (e.g. gray / grey). - //TODO: should we be using unique rgb values as keys instead and avoid these duplicates, or rely on the caller to do the reverse mapping? - aliceblue: "blåhvit", - antiquewhite: "antikk hvit", - aqua: "akva", - aquamarine: "akvamarin", - azure: "asur", - beige: "beige", - bisque: "gulrosa", - black: "svart", - blanchedalmond: "lys mandel", - blue: "blå", - blueviolet: "blåfiolett", - brown: "brun", - burlywood: "matt mellombrun", - cadetblue: "mørk grønnblå", - chartreuse: "løvgrønn", - chocolate: "sjokolade", - coral: "korall", - cornflowerblue: "kornblå", - cornsilk: "cornsilk", - crimson: "karmosinrødt", - cyan: "cyan", - darkblue: "mørk blå", - darkcyan: "mørk cyan", - darkgoldenrod: "mørk gyldenris", - darkgray: "mørk grå", - darkgreen: "mørk grønn", - darkgrey: "mørk grå", // same as darkgray - darkkhaki: "mørk khaki", - darkmagenta: "mørk magenta", - darkolivegreen: "mørk olivengrønn", - darkorange: "mørk oransje", - darkorchid: "mørk orkide", - darkred: "mørk rød", - darksalmon: "mørk lakserosa", - darkseagreen: "mørk sjøgrønn", - darkslateblue: "mørk skiferblå", - darkslategray: "mørk skifergrå", - darkslategrey: "mørk skifergrå", // same as darkslategray - darkturquoise: "mørk turkis", - darkviolet: "mørk fiolett", - deeppink: "dyp rosa", - deepskyblue: "dyp himmelblå", - dimgray: "mørk mørkegrå", - dimgrey: "mørk mørkegrå", // same as dimgray - dodgerblue: "lys havblå", - firebrick: "mursteinsrød", - floralwhite: "blomsterhvit", - forestgreen: "skoggrønn", - fuchsia: "fuksia", - gainsboro: "lys lys grå", - ghostwhite: "egghvit", - gold: "gull", - goldenrod: "gyldenris", - gray: "grå", - green: "grønn", - greenyellow: "gulgrønn", - grey: "grå", // same as gray - honeydew: "grønnhvit", - hotpink: "halvmørk rosa", - indianred: "rustrød", - indigo: "indigo", - ivory: "elfenbenshvit", - khaki: "khaki", - lavender: "lavendel", - lavenderblush: "lillahvit", - lawngreen: "plengrønn", - lemonchiffon: "ferskenfarget", - lightblue: "lys blå", - lightcoral: "lys korall", - lightcyan: "lys cyan", - lightgoldenrodyellow: "lys gyldenrisgul", - lightgray: "lys grå", - lightgreen: "lys grønn", - lightgrey: "lys grå", // same as lightgray - lightpink: "lys rosa", - lightsalmon: "lys lakserosa", - lightseagreen: "lys sjøgrønn", - lightskyblue: "lys himmelblå", - lightslategray: "lys skifergrå", - lightslategrey: "lys skifergrå", // same as lightslategray - lightsteelblue: "lys stålblå", - lightyellow: "lys gul", - lime: "lime", - limegreen: "limegrønn", - linen: "lin", - magenta: "magenta", - maroon: "rødbrun", - mediumaquamarine: "middels akvamarin", - mediumblue: "mellomblå", - mediumorchid: "middels orkide", - mediumpurple: "middels purpur", - mediumseagreen: "middels sjøgrønn", - mediumslateblue: "middels skiferblå", - mediumspringgreen: "middels vårgrønn", - mediumturquoise: "middels turkis", - mediumvioletred: "middels fiolettrød", - midnightblue: "midnattsblå", - mintcream: "mintkrem", - mistyrose: "lys rosenrød", - moccasin: "lys gulbrun", - navajowhite: "gulbrun", - navy: "marineblå", - oldlace: "kniplingshvit", - olive: "oliven", - olivedrab: "middels olivengrønn", - orange: "oransje", - orangered: "rødoransje", - orchid: "orkide", - palegoldenrod: "svak gyldenris", - palegreen: "svak grønn", - paleturquoise: "svak turkis", - palevioletred: "svak fiolettrød", - papayawhip: "lys papaya", - peachpuff: "brunrosa", - peru: "lys nøttebrun", - pink: "rosa", - plum: "plommefarget", - powderblue: "lys grønnblå", - purple: "purpur", - red: "rød", - rosybrown: "brunlilla", - royalblue: "kongeblå", - saddlebrown: "mørk nøttebrun", - salmon: "lakserosa", - sandybrown: "sandbrun", - seagreen: "sjøgrønn", - seashell: "skjellhvit", - sienna: "nøttebrun", - silver: "sølvfarget", - skyblue: "himmelblå", - slateblue: "skiferblå", - slategray: "skifergrå", - slategrey: "skifergrå", // same as slategray - snow: "snøhvit", - springgreen: "vårgrønn", - steelblue: "stålblå", - tan: "matt mellombrun", - teal: "mørk grønnblå", - thistle: "lys grålilla", - tomato: "tomatrød", - transparent: "gjennomsiktig", - turquoise: "turkis", - violet: "fiolett", - wheat: "varm sienna", - white: "hvit", - whitesmoke: "røykhvit", - yellow: "gul", - yellowgreen: "gulgrønn" -}) -); diff --git a/lib/dojo/nls/nl/colors.js b/lib/dojo/nls/nl/colors.js deleted file mode 100644 index cb1a79f..0000000 --- a/lib/dojo/nls/nl/colors.js +++ /dev/null @@ -1,8 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/nls/nl/colors",({aliceblue:"lichtblauw",antiquewhite:"antiekwit",aqua:"aqua",aquamarine:"aquamarijn",azure:"azuur",beige:"beige",bisque:"oranjegeel",black:"zwart",blanchedalmond:"amandel",blue:"blauw",blueviolet:"violet",brown:"bruin",burlywood:"lichtbruin",cadetblue:"donkerstaalblauw",chartreuse:"groengeel",chocolate:"chocoladebruin",coral:"koraalrood",cornflowerblue:"korenbloemblauw",cornsilk:"maïsgeel",crimson:"karmozijnrood",cyan:"cyaan",darkblue:"donkerblauw",darkcyan:"donkercyaan",darkgoldenrod:"donkergoud",darkgray:"donkergrijs",darkgreen:"donkergroen",darkgrey:"donkergrijs",darkkhaki:"donkerkaki",darkmagenta:"donkermagenta",darkolivegreen:"donkerolijfgroen",darkorange:"donkeroranje",darkorchid:"donkerorchidee",darkred:"donkerrood",darksalmon:"donkerzalm",darkseagreen:"donkerzeegroen",darkslateblue:"donkergrijsblauw",darkslategray:"donkerblauwgrijs",darkslategrey:"donkerblauwgrijs",darkturquoise:"donkerturquoise",darkviolet:"donkerviolet",deeppink:"donkerroze",deepskyblue:"diephemelblauw",dimgray:"dofgrijs",dimgrey:"dofgrijs",dodgerblue:"helderblauw",firebrick:"vuursteenrood",floralwhite:"rozewit",forestgreen:"bosgroen",fuchsia:"fuchsia",gainsboro:"lichtblauwgrijs",ghostwhite:"spierwit",gold:"goud",goldenrod:"goudbruin",gray:"grijs",green:"groen",greenyellow:"groengeel",grey:"grijs",honeydew:"meloen",hotpink:"acaciaroze",indianred:"indisch rood",indigo:"indigo",ivory:"ivoorwit",khaki:"kaki",lavender:"lavendelblauw",lavenderblush:"lavendelblos",lawngreen:"grasgroen",lemonchiffon:"citroengeel",lightblue:"lichtblauw",lightcoral:"lichtkoraal",lightcyan:"lichtcyaan",lightgoldenrodyellow:"lichtgoudgeel",lightgray:"lichtgrijs",lightgreen:"lichtgroen",lightgrey:"lichtgrijs",lightpink:"lichtroze",lightsalmon:"lichtzalm",lightseagreen:"lichtzeegroen",lightskyblue:"lichthemelsblauw",lightslategray:"lichtblauwgrijs",lightslategrey:"lichtblauwgrijs",lightsteelblue:"lichtstaalblauw",lightyellow:"lichtgeel",lime:"limoen",limegreen:"limoengroen",linen:"linnen",magenta:"magenta",maroon:"kastanjebruin",mediumaquamarine:"midaquamarijn",mediumblue:"midblauw",mediumorchid:"midorchidee",mediumpurple:"midpurper",mediumseagreen:"midzeegroen",mediumslateblue:"midgrijsblauw",mediumspringgreen:"midlentegroen",mediumturquoise:"midturquoise",mediumvioletred:"midvioletrood",midnightblue:"nachtblauw",mintcream:"mintroomgeel",mistyrose:"matroze",moccasin:"moccasin",navajowhite:"navajowit",navy:"marineblauw",oldlace:"kant",olive:"olijfgroen",olivedrab:"grijsbruin",orange:"oranje",orangered:"oranjerood",orchid:"orchidee",palegoldenrod:"bleekgeel",palegreen:"bleekgroen",paleturquoise:"bleekturquoise",palevioletred:"bleekvioletrood",papayawhip:"papajaroze",peachpuff:"perzikroze",peru:"bruin",pink:"roze",plum:"pruim",powderblue:"lichtblauw-wit",purple:"purper",red:"rood",rosybrown:"roodbruin",royalblue:"koningsblauw",saddlebrown:"leerbruin",salmon:"zalm",sandybrown:"zandbruin",seagreen:"zeegroen",seashell:"schelp",sienna:"sienna",silver:"zilvergrijs",skyblue:"hemelsblauw",slateblue:"leiblauw",slategray:"leigrijs",slategrey:"leigrijs",snow:"sneeuwwit",springgreen:"lentegroen",steelblue:"staalblauw",tan:"geelbruin",teal:"grijsblauw",thistle:"distel",tomato:"tomaat",transparent:"transparant",turquoise:"turquoise",violet:"violet",wheat:"tarwebruin",white:"wit",whitesmoke:"rookwit",yellow:"geel",yellowgreen:"geelgroen"})); diff --git a/lib/dojo/nls/nl/colors.js.uncompressed.js b/lib/dojo/nls/nl/colors.js.uncompressed.js deleted file mode 100644 index d4fa3d9..0000000 --- a/lib/dojo/nls/nl/colors.js.uncompressed.js +++ /dev/null @@ -1,156 +0,0 @@ -define( -"dojo/nls/nl/colors", ({ -// local representation of all CSS3 named colors, companion to dojo.colors. To be used where descriptive information -// is required for each color, such as a palette widget, and not for specifying color programatically. - //Note: due to the SVG 1.0 spec additions, some of these are alternate spellings for the same color (e.g. gray / grey). - //TODO: should we be using unique rgb values as keys instead and avoid these duplicates, or rely on the caller to do the reverse mapping? - aliceblue: "lichtblauw", - antiquewhite: "antiekwit", - aqua: "aqua", - aquamarine: "aquamarijn", - azure: "azuur", - beige: "beige", - bisque: "oranjegeel", - black: "zwart", - blanchedalmond: "amandel", - blue: "blauw", - blueviolet: "violet", - brown: "bruin", - burlywood: "lichtbruin", - cadetblue: "donkerstaalblauw", - chartreuse: "groengeel", - chocolate: "chocoladebruin", - coral: "koraalrood", - cornflowerblue: "korenbloemblauw", - cornsilk: "maïsgeel", - crimson: "karmozijnrood", - cyan: "cyaan", - darkblue: "donkerblauw", - darkcyan: "donkercyaan", - darkgoldenrod: "donkergoud", - darkgray: "donkergrijs", - darkgreen: "donkergroen", - darkgrey: "donkergrijs", // same as darkgray - darkkhaki: "donkerkaki", - darkmagenta: "donkermagenta", - darkolivegreen: "donkerolijfgroen", - darkorange: "donkeroranje", - darkorchid: "donkerorchidee", - darkred: "donkerrood", - darksalmon: "donkerzalm", - darkseagreen: "donkerzeegroen", - darkslateblue: "donkergrijsblauw", - darkslategray: "donkerblauwgrijs", - darkslategrey: "donkerblauwgrijs", // same as darkslategray - darkturquoise: "donkerturquoise", - darkviolet: "donkerviolet", - deeppink: "donkerroze", - deepskyblue: "diephemelblauw", - dimgray: "dofgrijs", - dimgrey: "dofgrijs", // same as dimgray - dodgerblue: "helderblauw", - firebrick: "vuursteenrood", - floralwhite: "rozewit", - forestgreen: "bosgroen", - fuchsia: "fuchsia", - gainsboro: "lichtblauwgrijs", - ghostwhite: "spierwit", - gold: "goud", - goldenrod: "goudbruin", - gray: "grijs", - green: "groen", - greenyellow: "groengeel", - grey: "grijs", // same as gray - honeydew: "meloen", - hotpink: "acaciaroze", - indianred: "indisch rood", - indigo: "indigo", - ivory: "ivoorwit", - khaki: "kaki", - lavender: "lavendelblauw", - lavenderblush: "lavendelblos", - lawngreen: "grasgroen", - lemonchiffon: "citroengeel", - lightblue: "lichtblauw", - lightcoral: "lichtkoraal", - lightcyan: "lichtcyaan", - lightgoldenrodyellow: "lichtgoudgeel", - lightgray: "lichtgrijs", - lightgreen: "lichtgroen", - lightgrey: "lichtgrijs", // same as lightgray - lightpink: "lichtroze", - lightsalmon: "lichtzalm", - lightseagreen: "lichtzeegroen", - lightskyblue: "lichthemelsblauw", - lightslategray: "lichtblauwgrijs", - lightslategrey: "lichtblauwgrijs", // same as lightslategray - lightsteelblue: "lichtstaalblauw", - lightyellow: "lichtgeel", - lime: "limoen", - limegreen: "limoengroen", - linen: "linnen", - magenta: "magenta", - maroon: "kastanjebruin", - mediumaquamarine: "midaquamarijn", - mediumblue: "midblauw", - mediumorchid: "midorchidee", - mediumpurple: "midpurper", - mediumseagreen: "midzeegroen", - mediumslateblue: "midgrijsblauw", - mediumspringgreen: "midlentegroen", - mediumturquoise: "midturquoise", - mediumvioletred: "midvioletrood", - midnightblue: "nachtblauw", - mintcream: "mintroomgeel", - mistyrose: "matroze", - moccasin: "moccasin", - navajowhite: "navajowit", - navy: "marineblauw", - oldlace: "kant", - olive: "olijfgroen", - olivedrab: "grijsbruin", - orange: "oranje", - orangered: "oranjerood", - orchid: "orchidee", - palegoldenrod: "bleekgeel", - palegreen: "bleekgroen", - paleturquoise: "bleekturquoise", - palevioletred: "bleekvioletrood", - papayawhip: "papajaroze", - peachpuff: "perzikroze", - peru: "bruin", - pink: "roze", - plum: "pruim", - powderblue: "lichtblauw-wit", - purple: "purper", - red: "rood", - rosybrown: "roodbruin", - royalblue: "koningsblauw", - saddlebrown: "leerbruin", - salmon: "zalm", - sandybrown: "zandbruin", - seagreen: "zeegroen", - seashell: "schelp", - sienna: "sienna", - silver: "zilvergrijs", - skyblue: "hemelsblauw", - slateblue: "leiblauw", - slategray: "leigrijs", - slategrey: "leigrijs", // same as slategray - snow: "sneeuwwit", - springgreen: "lentegroen", - steelblue: "staalblauw", - tan: "geelbruin", - teal: "grijsblauw", - thistle: "distel", - tomato: "tomaat", - transparent: "transparant", - turquoise: "turquoise", - violet: "violet", - wheat: "tarwebruin", - white: "wit", - whitesmoke: "rookwit", - yellow: "geel", - yellowgreen: "geelgroen" -}) -); diff --git a/lib/dojo/nls/pl/colors.js b/lib/dojo/nls/pl/colors.js deleted file mode 100644 index 5249234..0000000 --- a/lib/dojo/nls/pl/colors.js +++ /dev/null @@ -1,8 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/nls/pl/colors",({aliceblue:"bladoniebieski",antiquewhite:"biel antyczna",aqua:"morski",aquamarine:"akwamaryna",azure:"lazurowy",beige:"beżowy",bisque:"cielistobeżowy",black:"czarny",blanchedalmond:"obrany migdał",blue:"niebieski",blueviolet:"błękitnofiołkowy",brown:"brązowy",burlywood:"piaskowobeżowy",cadetblue:"szaroniebieski",chartreuse:"żółtooliwkowy",chocolate:"czekoladowy",coral:"koralowy",cornflowerblue:"niebieskochabrowy",cornsilk:"białożółty",crimson:"karmazynowy",cyan:"niebieskozielony",darkblue:"ciemnoniebieski",darkcyan:"ciemnoniebieskozielony",darkgoldenrod:"ciemne stare złoto",darkgray:"ciemnoszary",darkgreen:"ciemnozielony",darkgrey:"ciemnoszary",darkkhaki:"ciemny khaki",darkmagenta:"ciemnoamarantowy",darkolivegreen:"ciemnooliwkowozielony",darkorange:"ciemnopomarańczowy",darkorchid:"ciemna orchidea",darkred:"ciemnoczerwony",darksalmon:"ciemnołososiowy",darkseagreen:"ciemna zieleń morska",darkslateblue:"ciemny gołębi",darkslategray:"ciemny mysi",darkslategrey:"ciemny mysi",darkturquoise:"ciemnoturkusowy",darkviolet:"ciemnofiołkowy",deeppink:"głęboki róż",deepskyblue:"intensywny błękit nieba",dimgray:"przyciemniony szary",dimgrey:"przyciemniony szary",dodgerblue:"niebieski Dodgersów",firebrick:"podpalana cegła",floralwhite:"złamana biel",forestgreen:"leśna zieleń",fuchsia:"fuksjowy",gainsboro:"jasnoniebieskawoszary",ghostwhite:"sina biel",gold:"złoty",goldenrod:"stare złoto",gray:"szary",green:"zielony",greenyellow:"zielonożółty",grey:"szary",honeydew:"miodowy",hotpink:"odblaskoworóżowy",indianred:"kasztanowy",indigo:"indygo",ivory:"kość słoniowa",khaki:"khaki",lavender:"lawendowy",lavenderblush:"lawendoworóżowy",lawngreen:"trawiasty",lemonchiffon:"babka cytrynowa",lightblue:"jasnoniebieski",lightcoral:"jasnokoralowy",lightcyan:"jasnoniebieskozielony",lightgoldenrodyellow:"jasne stare złoto",lightgray:"jasnoszary",lightgreen:"jasnozielony",lightgrey:"jasnoszary",lightpink:"jasnoróżowy",lightsalmon:"jasnołososiowy",lightseagreen:"jasna zieleń morska",lightskyblue:"jasny błękit nieba",lightslategray:"jasny mysi",lightslategrey:"jasny mysi",lightsteelblue:"jasnostalowoniebieski",lightyellow:"jasnożółty",lime:"limonkowy",limegreen:"limonkowozielony",linen:"lniany",magenta:"amarantowy",maroon:"rdzawoczerwony",mediumaquamarine:"średnia akwamaryna",mediumblue:"średni niebieski",mediumorchid:"średnia orchidea",mediumpurple:"średni fioletowy",mediumseagreen:"średnia zieleń morska",mediumslateblue:"średni gołębi",mediumspringgreen:"średnia wiosenna zieleń",mediumturquoise:"średni turkusowy",mediumvioletred:"średni fiołkowowoczerwony",midnightblue:"atramentowoniebieski",mintcream:"miętowokremowy",mistyrose:"mglistoróżany",moccasin:"mokasynowy",navajowhite:"biel Nawaho",navy:"granatowy",oldlace:"ecru",olive:"oliwkowy",olivedrab:"oliwkowozielony",orange:"pomarańczowy",orangered:"czerwona pomarańcza",orchid:"orchidea",palegoldenrod:"blade stare złoto",palegreen:"bladozielony",paleturquoise:"bladoturkusowy",palevioletred:"bladofiołkowoczerwony",papayawhip:"kremowa papaja",peachpuff:"cielisty brzoskwiniowy",peru:"palona glina",pink:"różowy",plum:"śliwkowy",powderblue:"jasnobladobłękitny",purple:"fioletowy",red:"czerwony",rosybrown:"różanobrązowy",royalblue:"królewska purpura",saddlebrown:"brąz skórzany",salmon:"łososiowy",sandybrown:"piaskowobrązowy",seagreen:"zieleń morska",seashell:"matowoliliowy",sienna:"sjena",silver:"srebrny",skyblue:"błękit nieba",slateblue:"gołębi",slategray:"mysi",slategrey:"mysi",snow:"śnieżny",springgreen:"wiosenna zieleń",steelblue:"stalowoniebieski",tan:"śniady",teal:"zielonomodry",thistle:"kwiat ostu",tomato:"pomidorowy",transparent:"przezroczysty",turquoise:"turkusowy",violet:"fiołkowy",wheat:"pszeniczny",white:"biały",whitesmoke:"siwy",yellow:"żółty",yellowgreen:"żółtozielony"})); diff --git a/lib/dojo/nls/pl/colors.js.uncompressed.js b/lib/dojo/nls/pl/colors.js.uncompressed.js deleted file mode 100644 index ad95f62..0000000 --- a/lib/dojo/nls/pl/colors.js.uncompressed.js +++ /dev/null @@ -1,156 +0,0 @@ -define( -"dojo/nls/pl/colors", ({ -// local representation of all CSS3 named colors, companion to dojo.colors. To be used where descriptive information -// is required for each color, such as a palette widget, and not for specifying color programatically. - //Note: due to the SVG 1.0 spec additions, some of these are alternate spellings for the same color (e.g. gray / grey). - //TODO: should we be using unique rgb values as keys instead and avoid these duplicates, or rely on the caller to do the reverse mapping? - aliceblue: "bladoniebieski", - antiquewhite: "biel antyczna", - aqua: "morski", - aquamarine: "akwamaryna", - azure: "lazurowy", - beige: "beżowy", - bisque: "cielistobeżowy", - black: "czarny", - blanchedalmond: "obrany migdał", - blue: "niebieski", - blueviolet: "błękitnofiołkowy", - brown: "brązowy", - burlywood: "piaskowobeżowy", - cadetblue: "szaroniebieski", - chartreuse: "żółtooliwkowy", - chocolate: "czekoladowy", - coral: "koralowy", - cornflowerblue: "niebieskochabrowy", - cornsilk: "białożółty", - crimson: "karmazynowy", - cyan: "niebieskozielony", - darkblue: "ciemnoniebieski", - darkcyan: "ciemnoniebieskozielony", - darkgoldenrod: "ciemne stare złoto", - darkgray: "ciemnoszary", - darkgreen: "ciemnozielony", - darkgrey: "ciemnoszary", // same as darkgray - darkkhaki: "ciemny khaki", - darkmagenta: "ciemnoamarantowy", - darkolivegreen: "ciemnooliwkowozielony", - darkorange: "ciemnopomarańczowy", - darkorchid: "ciemna orchidea", - darkred: "ciemnoczerwony", - darksalmon: "ciemnołososiowy", - darkseagreen: "ciemna zieleń morska", - darkslateblue: "ciemny gołębi", - darkslategray: "ciemny mysi", - darkslategrey: "ciemny mysi", // same as darkslategray - darkturquoise: "ciemnoturkusowy", - darkviolet: "ciemnofiołkowy", - deeppink: "głęboki róż", - deepskyblue: "intensywny błękit nieba", - dimgray: "przyciemniony szary", - dimgrey: "przyciemniony szary", // same as dimgray - dodgerblue: "niebieski Dodgersów", - firebrick: "podpalana cegła", - floralwhite: "złamana biel", - forestgreen: "leśna zieleń", - fuchsia: "fuksjowy", - gainsboro: "jasnoniebieskawoszary", - ghostwhite: "sina biel", - gold: "złoty", - goldenrod: "stare złoto", - gray: "szary", - green: "zielony", - greenyellow: "zielonożółty", - grey: "szary", // same as gray - honeydew: "miodowy", - hotpink: "odblaskoworóżowy", - indianred: "kasztanowy", - indigo: "indygo", - ivory: "kość słoniowa", - khaki: "khaki", - lavender: "lawendowy", - lavenderblush: "lawendoworóżowy", - lawngreen: "trawiasty", - lemonchiffon: "babka cytrynowa", - lightblue: "jasnoniebieski", - lightcoral: "jasnokoralowy", - lightcyan: "jasnoniebieskozielony", - lightgoldenrodyellow: "jasne stare złoto", - lightgray: "jasnoszary", - lightgreen: "jasnozielony", - lightgrey: "jasnoszary", // same as lightgray - lightpink: "jasnoróżowy", - lightsalmon: "jasnołososiowy", - lightseagreen: "jasna zieleń morska", - lightskyblue: "jasny błękit nieba", - lightslategray: "jasny mysi", - lightslategrey: "jasny mysi", // same as lightslategray - lightsteelblue: "jasnostalowoniebieski", - lightyellow: "jasnożółty", - lime: "limonkowy", - limegreen: "limonkowozielony", - linen: "lniany", - magenta: "amarantowy", - maroon: "rdzawoczerwony", - mediumaquamarine: "średnia akwamaryna", - mediumblue: "średni niebieski", - mediumorchid: "średnia orchidea", - mediumpurple: "średni fioletowy", - mediumseagreen: "średnia zieleń morska", - mediumslateblue: "średni gołębi", - mediumspringgreen: "średnia wiosenna zieleń", - mediumturquoise: "średni turkusowy", - mediumvioletred: "średni fiołkowowoczerwony", - midnightblue: "atramentowoniebieski", - mintcream: "miętowokremowy", - mistyrose: "mglistoróżany", - moccasin: "mokasynowy", - navajowhite: "biel Nawaho", - navy: "granatowy", - oldlace: "ecru", - olive: "oliwkowy", - olivedrab: "oliwkowozielony", - orange: "pomarańczowy", - orangered: "czerwona pomarańcza", - orchid: "orchidea", - palegoldenrod: "blade stare złoto", - palegreen: "bladozielony", - paleturquoise: "bladoturkusowy", - palevioletred: "bladofiołkowoczerwony", - papayawhip: "kremowa papaja", - peachpuff: "cielisty brzoskwiniowy", - peru: "palona glina", - pink: "różowy", - plum: "śliwkowy", - powderblue: "jasnobladobłękitny", - purple: "fioletowy", - red: "czerwony", - rosybrown: "różanobrązowy", - royalblue: "królewska purpura", - saddlebrown: "brąz skórzany", - salmon: "łososiowy", - sandybrown: "piaskowobrązowy", - seagreen: "zieleń morska", - seashell: "matowoliliowy", - sienna: "sjena", - silver: "srebrny", - skyblue: "błękit nieba", - slateblue: "gołębi", - slategray: "mysi", - slategrey: "mysi", // same as slategray - snow: "śnieżny", - springgreen: "wiosenna zieleń", - steelblue: "stalowoniebieski", - tan: "śniady", - teal: "zielonomodry", - thistle: "kwiat ostu", - tomato: "pomidorowy", - transparent: "przezroczysty", - turquoise: "turkusowy", - violet: "fiołkowy", - wheat: "pszeniczny", - white: "biały", - whitesmoke: "siwy", - yellow: "żółty", - yellowgreen: "żółtozielony" -}) -); diff --git a/lib/dojo/nls/pt-pt/colors.js b/lib/dojo/nls/pt-pt/colors.js deleted file mode 100644 index aa0fa57..0000000 --- a/lib/dojo/nls/pt-pt/colors.js +++ /dev/null @@ -1,8 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/nls/pt-pt/colors",({aliceblue:"azul alice",antiquewhite:"branco antigo",aqua:"verde-água",aquamarine:"verde-azulado",azure:"azul-celeste",beige:"bege",bisque:"rosa-velho",black:"preto",blanchedalmond:"amêndoa claro",blue:"azul",blueviolet:"azul violeta",brown:"castanho",burlywood:"castanho pinho",cadetblue:"azul cadete",chartreuse:"amarelo esverdeado",chocolate:"chocolate",coral:"coral",cornflowerblue:"azul-violáceo",cornsilk:"branco seda",crimson:"carmesim",cyan:"ciano",darkblue:"azul escuro",darkcyan:"ciano escuro",darkgoldenrod:"ouro velho escuro",darkgray:"cinzento escuro",darkgreen:"verde escuro",darkgrey:"cinzento escuro",darkkhaki:"caqui escuro",darkmagenta:"magenta escuro",darkolivegreen:"verde-azeitona escuro",darkorange:"laranja escuro",darkorchid:"orquídea escuro",darkred:"vermelho escuro",darksalmon:"salmão escuro",darkseagreen:"verde marinho escuro",darkslateblue:"azul ardósia escuro",darkslategray:"cinzento ardósia escuro",darkslategrey:"cinzento ardósia escuro",darkturquoise:"turquesa escuro",darkviolet:"violeta escuro",deeppink:"rosa profundo",deepskyblue:"azul céu profundo",dimgray:"cinzento esbatido",dimgrey:"cinzento esbatido",dodgerblue:"azul furtivo",firebrick:"tijolo fogo",floralwhite:"branco floral",forestgreen:"verde floresta",fuchsia:"fúcsia",gainsboro:"cinzento azulado claro",ghostwhite:"branco sombreado",gold:"dourado",goldenrod:"ouro velho",gray:"cinzento",green:"verde",greenyellow:"amarelo esverdeado",grey:"cinzento",honeydew:"mel",hotpink:"rosa forte",indianred:"almagre",indigo:"índigo",ivory:"marfim",khaki:"caqui",lavender:"alfazema",lavenderblush:"alfazema rosado",lawngreen:"verde relva",lemonchiffon:"limão chiffon",lightblue:"azul claro",lightcoral:"coral claro",lightcyan:"ciano claro",lightgoldenrodyellow:"ouro velho amarelado claro",lightgray:"cinzento claro",lightgreen:"verde claro",lightgrey:"cinzento claro",lightpink:"rosa claro",lightsalmon:"salmão claro",lightseagreen:"verde marinho claro",lightskyblue:"azul céu claro",lightslategray:"cinzento ardósia claro",lightslategrey:"cinzento ardósia claro",lightsteelblue:"azul-aço claro",lightyellow:"amarelo claro",lime:"lima",limegreen:"verde-lima",linen:"linho",magenta:"magenta",maroon:"bordeaux",mediumaquamarine:"verde-azulado médio",mediumblue:"azul médio",mediumorchid:"orquídea médio",mediumpurple:"roxo médio",mediumseagreen:"verde marinho médio",mediumslateblue:"azul ardósia médio",mediumspringgreen:"verde primavera médio",mediumturquoise:"turquesa médio",mediumvioletred:"violeta avermelhado médio",midnightblue:"azul meia-noite",mintcream:"creme de menta",mistyrose:"rosa pálido",moccasin:"mocassim",navajowhite:"branco navajo",navy:"azul marinho",oldlace:"renda antiga",olive:"azeitona",olivedrab:"azeitona claro",orange:"laranja",orangered:"vermelho alaranjado",orchid:"orquídea",palegoldenrod:"ouro velho pálido",palegreen:"verde pálido",paleturquoise:"turquesa pálido",palevioletred:"violeta avermelhado pálido",papayawhip:"creme de papaia",peachpuff:"pêssego",peru:"peru",pink:"rosa",plum:"cor-de-ameixa",powderblue:"azul de esmalte",purple:"roxo",red:"vermelho",rosybrown:"castanho rosado",royalblue:"azul real",saddlebrown:"castanho sela",salmon:"salmão",sandybrown:"castanho areia",seagreen:"verde marinho",seashell:"concha",sienna:"castanho-avermelhado",silver:"prateado",skyblue:"azul céu",slateblue:"azul ardósia",slategray:"cinzento ardósia",slategrey:"cinzento ardósia",snow:"branco-neve",springgreen:"verde primavera",steelblue:"azul-aço",tan:"castanho claro",teal:"verde-azulado",thistle:"cardo",tomato:"vermelho tomate",transparent:"transparente",turquoise:"turquesa",violet:"violeta",wheat:"trigo",white:"branco",whitesmoke:"fumo branco",yellow:"amarelo",yellowgreen:"verde amarelado"})); diff --git a/lib/dojo/nls/pt-pt/colors.js.uncompressed.js b/lib/dojo/nls/pt-pt/colors.js.uncompressed.js deleted file mode 100644 index 542b7a1..0000000 --- a/lib/dojo/nls/pt-pt/colors.js.uncompressed.js +++ /dev/null @@ -1,156 +0,0 @@ -define( -"dojo/nls/pt-pt/colors", ({ -// local representation of all CSS3 named colors, companion to dojo.colors. To be used where descriptive information -// is required for each color, such as a palette widget, and not for specifying color programatically. - //Note: due to the SVG 1.0 spec additions, some of these are alternate spellings for the same color (e.g. gray / grey). - //TODO: should we be using unique rgb values as keys instead and avoid these duplicates, or rely on the caller to do the reverse mapping? - aliceblue: "azul alice", - antiquewhite: "branco antigo", - aqua: "verde-água", - aquamarine: "verde-azulado", - azure: "azul-celeste", - beige: "bege", - bisque: "rosa-velho", - black: "preto", - blanchedalmond: "amêndoa claro", - blue: "azul", - blueviolet: "azul violeta", - brown: "castanho", - burlywood: "castanho pinho", - cadetblue: "azul cadete", - chartreuse: "amarelo esverdeado", - chocolate: "chocolate", - coral: "coral", - cornflowerblue: "azul-violáceo", - cornsilk: "branco seda", - crimson: "carmesim", - cyan: "ciano", - darkblue: "azul escuro", - darkcyan: "ciano escuro", - darkgoldenrod: "ouro velho escuro", - darkgray: "cinzento escuro", - darkgreen: "verde escuro", - darkgrey: "cinzento escuro", // same as darkgray - darkkhaki: "caqui escuro", - darkmagenta: "magenta escuro", - darkolivegreen: "verde-azeitona escuro", - darkorange: "laranja escuro", - darkorchid: "orquídea escuro", - darkred: "vermelho escuro", - darksalmon: "salmão escuro", - darkseagreen: "verde marinho escuro", - darkslateblue: "azul ardósia escuro", - darkslategray: "cinzento ardósia escuro", - darkslategrey: "cinzento ardósia escuro", // same as darkslategray - darkturquoise: "turquesa escuro", - darkviolet: "violeta escuro", - deeppink: "rosa profundo", - deepskyblue: "azul céu profundo", - dimgray: "cinzento esbatido", - dimgrey: "cinzento esbatido", // same as dimgray - dodgerblue: "azul furtivo", - firebrick: "tijolo fogo", - floralwhite: "branco floral", - forestgreen: "verde floresta", - fuchsia: "fúcsia", - gainsboro: "cinzento azulado claro", - ghostwhite: "branco sombreado", - gold: "dourado", - goldenrod: "ouro velho", - gray: "cinzento", - green: "verde", - greenyellow: "amarelo esverdeado", - grey: "cinzento", // same as gray - honeydew: "mel", - hotpink: "rosa forte", - indianred: "almagre", - indigo: "índigo", - ivory: "marfim", - khaki: "caqui", - lavender: "alfazema", - lavenderblush: "alfazema rosado", - lawngreen: "verde relva", - lemonchiffon: "limão chiffon", - lightblue: "azul claro", - lightcoral: "coral claro", - lightcyan: "ciano claro", - lightgoldenrodyellow: "ouro velho amarelado claro", - lightgray: "cinzento claro", - lightgreen: "verde claro", - lightgrey: "cinzento claro", // same as lightgray - lightpink: "rosa claro", - lightsalmon: "salmão claro", - lightseagreen: "verde marinho claro", - lightskyblue: "azul céu claro", - lightslategray: "cinzento ardósia claro", - lightslategrey: "cinzento ardósia claro", // same as lightslategray - lightsteelblue: "azul-aço claro", - lightyellow: "amarelo claro", - lime: "lima", - limegreen: "verde-lima", - linen: "linho", - magenta: "magenta", - maroon: "bordeaux", - mediumaquamarine: "verde-azulado médio", - mediumblue: "azul médio", - mediumorchid: "orquídea médio", - mediumpurple: "roxo médio", - mediumseagreen: "verde marinho médio", - mediumslateblue: "azul ardósia médio", - mediumspringgreen: "verde primavera médio", - mediumturquoise: "turquesa médio", - mediumvioletred: "violeta avermelhado médio", - midnightblue: "azul meia-noite", - mintcream: "creme de menta", - mistyrose: "rosa pálido", - moccasin: "mocassim", - navajowhite: "branco navajo", - navy: "azul marinho", - oldlace: "renda antiga", - olive: "azeitona", - olivedrab: "azeitona claro", - orange: "laranja", - orangered: "vermelho alaranjado", - orchid: "orquídea", - palegoldenrod: "ouro velho pálido", - palegreen: "verde pálido", - paleturquoise: "turquesa pálido", - palevioletred: "violeta avermelhado pálido", - papayawhip: "creme de papaia", - peachpuff: "pêssego", - peru: "peru", - pink: "rosa", - plum: "cor-de-ameixa", - powderblue: "azul de esmalte", - purple: "roxo", - red: "vermelho", - rosybrown: "castanho rosado", - royalblue: "azul real", - saddlebrown: "castanho sela", - salmon: "salmão", - sandybrown: "castanho areia", - seagreen: "verde marinho", - seashell: "concha", - sienna: "castanho-avermelhado", - silver: "prateado", - skyblue: "azul céu", - slateblue: "azul ardósia", - slategray: "cinzento ardósia", - slategrey: "cinzento ardósia", // same as slategray - snow: "branco-neve", - springgreen: "verde primavera", - steelblue: "azul-aço", - tan: "castanho claro", - teal: "verde-azulado", - thistle: "cardo", - tomato: "vermelho tomate", - transparent: "transparente", - turquoise: "turquesa", - violet: "violeta", - wheat: "trigo", - white: "branco", - whitesmoke: "fumo branco", - yellow: "amarelo", - yellowgreen: "verde amarelado" -}) -); diff --git a/lib/dojo/nls/pt/colors.js b/lib/dojo/nls/pt/colors.js deleted file mode 100644 index aae933f..0000000 --- a/lib/dojo/nls/pt/colors.js +++ /dev/null @@ -1,8 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/nls/pt/colors",({aliceblue:"azul alice",antiquewhite:"branco antigo",aqua:"aqua",aquamarine:"água marinha",azure:"azul celeste",beige:"bege",bisque:"bisque",black:"preto",blanchedalmond:"amêndoa pelada",blue:"azul",blueviolet:"azul violeta",brown:"marrom",burlywood:"burlywood",cadetblue:"azul cadet",chartreuse:"chartreuse",chocolate:"chocolate",coral:"coral",cornflowerblue:"azul centaurea",cornsilk:"cornsilk",crimson:"carmesim",cyan:"ciano",darkblue:"azul escuro",darkcyan:"ciano escuro",darkgoldenrod:"goldenrod escuro",darkgray:"cinza escuro",darkgreen:"verde escuro",darkgrey:"cinza escuro",darkkhaki:"cáqui escuro",darkmagenta:"magenta escuro",darkolivegreen:"verde oliva escuro",darkorange:"laranja escuro",darkorchid:"orquídea escuro",darkred:"vermelho escuro",darksalmon:"salmão escuro",darkseagreen:"verde marinho escuro",darkslateblue:"azul ardósia escuro",darkslategray:"cinza ardósia escuro",darkslategrey:"cinza ardósia escuro",darkturquoise:"turquesa escuro",darkviolet:"violeta escuro",deeppink:"rosa profundo",deepskyblue:"azul céu intenso",dimgray:"cinza turvo",dimgrey:"cinza turvo",dodgerblue:"azul dodger",firebrick:"firebrick",floralwhite:"branco floral",forestgreen:"verde floresta",fuchsia:"fúcsia",gainsboro:"gainsboro",ghostwhite:"branco ghost",gold:"dourado",goldenrod:"goldenrod",gray:"cinza",green:"verde",greenyellow:"amarelo esverdeado",grey:"cinza",honeydew:"honeydew",hotpink:"rosa quente",indianred:"vermelho indiano",indigo:"índigo",ivory:"marfim",khaki:"cáqui",lavender:"lavanda",lavenderblush:"lavanda avermelhada",lawngreen:"verde grama",lemonchiffon:"limão chiffon",lightblue:"azul claro",lightcoral:"coral claro",lightcyan:"ciano claro",lightgoldenrodyellow:"amarelo goldenrod claro",lightgray:"cinza claro",lightgreen:"verde claro",lightgrey:"cinza claro",lightpink:"rosa claro",lightsalmon:"salmão claro",lightseagreen:"verde marinho claro",lightskyblue:"azul céu claro",lightslategray:"cinza ardósia claro",lightslategrey:"cinza ardósia claro",lightsteelblue:"azul aço claro",lightyellow:"amarelo claro",lime:"lima",limegreen:"verde lima",linen:"linho",magenta:"magenta",maroon:"castanho",mediumaquamarine:"água marinha médio",mediumblue:"azul médio",mediumorchid:"orquídea médio",mediumpurple:"roxo médio",mediumseagreen:"verde marinho médio",mediumslateblue:"azul ardósia médio",mediumspringgreen:"verde primavera médio",mediumturquoise:"turquesa médio",mediumvioletred:"vermelho violeta médio",midnightblue:"azul meia-noite",mintcream:"creme de menta",mistyrose:"rosa enevoado",moccasin:"moccasin",navajowhite:"branco navajo",navy:"marinho",oldlace:"cadarço velho",olive:"oliva",olivedrab:"verde oliva",orange:"laranja",orangered:"vermelho alaranjado",orchid:"orquídea",palegoldenrod:"goldenrod esbranquiçado",palegreen:"verde esbranquiçado",paleturquoise:"turquesa esbranquiçado",palevioletred:"vermelho violeta esbranquiçado",papayawhip:"creme de papaya",peachpuff:"peach puff",peru:"peru",pink:"rosa",plum:"ameixa",powderblue:"azul talco",purple:"roxo",red:"vermelho",rosybrown:"marrom rosado",royalblue:"azul royal",saddlebrown:"marrom saddle",salmon:"salmão",sandybrown:"marrom cor de areia",seagreen:"verde marinho",seashell:"seashell",sienna:"sienna",silver:"prateado",skyblue:"azul céu",slateblue:"azul ardósia",slategray:"cinza ardósia",slategrey:"cinza ardósia",snow:"branco neve",springgreen:"verde primavera",steelblue:"azul aço",tan:"tan",teal:"azul esverdeado",thistle:"thistle",tomato:"tomate",transparent:"transparente",turquoise:"turquesa",violet:"violeta",wheat:"trigo",white:"branco",whitesmoke:"fumaça branca",yellow:"amarelo",yellowgreen:"verde amarelado"})); diff --git a/lib/dojo/nls/pt/colors.js.uncompressed.js b/lib/dojo/nls/pt/colors.js.uncompressed.js deleted file mode 100644 index 02893b5..0000000 --- a/lib/dojo/nls/pt/colors.js.uncompressed.js +++ /dev/null @@ -1,156 +0,0 @@ -define( -"dojo/nls/pt/colors", ({ -// local representation of all CSS3 named colors, companion to dojo.colors. To be used where descriptive information -// is required for each color, such as a palette widget, and not for specifying color programatically. - //Note: due to the SVG 1.0 spec additions, some of these are alternate spellings for the same color (e.g. gray / grey). - //TODO: should we be using unique rgb values as keys instead and avoid these duplicates, or rely on the caller to do the reverse mapping? - aliceblue: "azul alice", - antiquewhite: "branco antigo", - aqua: "aqua", - aquamarine: "água marinha", - azure: "azul celeste", - beige: "bege", - bisque: "bisque", - black: "preto", - blanchedalmond: "amêndoa pelada", - blue: "azul", - blueviolet: "azul violeta", - brown: "marrom", - burlywood: "burlywood", - cadetblue: "azul cadet", - chartreuse: "chartreuse", - chocolate: "chocolate", - coral: "coral", - cornflowerblue: "azul centaurea", - cornsilk: "cornsilk", - crimson: "carmesim", - cyan: "ciano", - darkblue: "azul escuro", - darkcyan: "ciano escuro", - darkgoldenrod: "goldenrod escuro", - darkgray: "cinza escuro", - darkgreen: "verde escuro", - darkgrey: "cinza escuro", // same as darkgray - darkkhaki: "cáqui escuro", - darkmagenta: "magenta escuro", - darkolivegreen: "verde oliva escuro", - darkorange: "laranja escuro", - darkorchid: "orquídea escuro", - darkred: "vermelho escuro", - darksalmon: "salmão escuro", - darkseagreen: "verde marinho escuro", - darkslateblue: "azul ardósia escuro", - darkslategray: "cinza ardósia escuro", - darkslategrey: "cinza ardósia escuro", // same as darkslategray - darkturquoise: "turquesa escuro", - darkviolet: "violeta escuro", - deeppink: "rosa profundo", - deepskyblue: "azul céu intenso", - dimgray: "cinza turvo", - dimgrey: "cinza turvo", // same as dimgray - dodgerblue: "azul dodger", - firebrick: "firebrick", - floralwhite: "branco floral", - forestgreen: "verde floresta", - fuchsia: "fúcsia", - gainsboro: "gainsboro", - ghostwhite: "branco ghost", - gold: "dourado", - goldenrod: "goldenrod", - gray: "cinza", - green: "verde", - greenyellow: "amarelo esverdeado", - grey: "cinza", // same as gray - honeydew: "honeydew", - hotpink: "rosa quente", - indianred: "vermelho indiano", - indigo: "índigo", - ivory: "marfim", - khaki: "cáqui", - lavender: "lavanda", - lavenderblush: "lavanda avermelhada", - lawngreen: "verde grama", - lemonchiffon: "limão chiffon", - lightblue: "azul claro", - lightcoral: "coral claro", - lightcyan: "ciano claro", - lightgoldenrodyellow: "amarelo goldenrod claro", - lightgray: "cinza claro", - lightgreen: "verde claro", - lightgrey: "cinza claro", // same as lightgray - lightpink: "rosa claro", - lightsalmon: "salmão claro", - lightseagreen: "verde marinho claro", - lightskyblue: "azul céu claro", - lightslategray: "cinza ardósia claro", - lightslategrey: "cinza ardósia claro", // same as lightslategray - lightsteelblue: "azul aço claro", - lightyellow: "amarelo claro", - lime: "lima", - limegreen: "verde lima", - linen: "linho", - magenta: "magenta", - maroon: "castanho", - mediumaquamarine: "água marinha médio", - mediumblue: "azul médio", - mediumorchid: "orquídea médio", - mediumpurple: "roxo médio", - mediumseagreen: "verde marinho médio", - mediumslateblue: "azul ardósia médio", - mediumspringgreen: "verde primavera médio", - mediumturquoise: "turquesa médio", - mediumvioletred: "vermelho violeta médio", - midnightblue: "azul meia-noite", - mintcream: "creme de menta", - mistyrose: "rosa enevoado", - moccasin: "moccasin", - navajowhite: "branco navajo", - navy: "marinho", - oldlace: "cadarço velho", - olive: "oliva", - olivedrab: "verde oliva", - orange: "laranja", - orangered: "vermelho alaranjado", - orchid: "orquídea", - palegoldenrod: "goldenrod esbranquiçado", - palegreen: "verde esbranquiçado", - paleturquoise: "turquesa esbranquiçado", - palevioletred: "vermelho violeta esbranquiçado", - papayawhip: "creme de papaya", - peachpuff: "peach puff", - peru: "peru", - pink: "rosa", - plum: "ameixa", - powderblue: "azul talco", - purple: "roxo", - red: "vermelho", - rosybrown: "marrom rosado", - royalblue: "azul royal", - saddlebrown: "marrom saddle", - salmon: "salmão", - sandybrown: "marrom cor de areia", - seagreen: "verde marinho", - seashell: "seashell", - sienna: "sienna", - silver: "prateado", - skyblue: "azul céu", - slateblue: "azul ardósia", - slategray: "cinza ardósia", - slategrey: "cinza ardósia", // same as slategray - snow: "branco neve", - springgreen: "verde primavera", - steelblue: "azul aço", - tan: "tan", - teal: "azul esverdeado", - thistle: "thistle", - tomato: "tomate", - transparent: "transparente", - turquoise: "turquesa", - violet: "violeta", - wheat: "trigo", - white: "branco", - whitesmoke: "fumaça branca", - yellow: "amarelo", - yellowgreen: "verde amarelado" -}) -); diff --git a/lib/dojo/nls/ro/colors.js b/lib/dojo/nls/ro/colors.js deleted file mode 100644 index 45328bd..0000000 --- a/lib/dojo/nls/ro/colors.js +++ /dev/null @@ -1,8 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/nls/ro/colors",({aliceblue:"alice blue",antiquewhite:"antique white",aqua:"aqua",aquamarine:"aquamarine",azure:"azuriu",beige:"bej",bisque:"bisque",black:"negru",blanchedalmond:"blanched almond",blue:"albastru",blueviolet:"albastru-violet",brown:"brun",burlywood:"burlywood",cadetblue:"albastru cadet",chartreuse:"chartreuse",chocolate:"ciocolată",coral:"coral",cornflowerblue:"cornflower blue",cornsilk:"cornsilk",crimson:"stacojiu",cyan:"cyan",darkblue:"albastru închis",darkcyan:"cyan închis",darkgoldenrod:"goldenrod închis",darkgray:"gri închis",darkgreen:"verde închis",darkgrey:"gri închis",darkkhaki:"kaki închis",darkmagenta:"magenta închis",darkolivegreen:"verde măslină închis",darkorange:"portocaliu închis",darkorchid:"orchid închis",darkred:"roşu închis",darksalmon:"somon închis",darkseagreen:"verde marin închis",darkslateblue:"albastru ardezie închis",darkslategray:"gri ardezie închis",darkslategrey:"gri ardezie închis",darkturquoise:"turcoaz închis",darkviolet:"violet închis",deeppink:"roz profund",deepskyblue:"albastru cer profund",dimgray:"dim gray",dimgrey:"dim gray",dodgerblue:"dodger blue",firebrick:"cărămiziu aprins",floralwhite:"floral white",forestgreen:"forest green",fuchsia:"fuchsia",gainsboro:"gainsboro",ghostwhite:"ghost white",gold:"auriu",goldenrod:"goldenrod",gray:"gri",green:"verde",greenyellow:"verde-gălbui",grey:"gri",honeydew:"honeydew",hotpink:"roz aprins",indianred:"roşu indian",indigo:"indigo",ivory:"ivoriu",khaki:"kaki",lavender:"lavandă",lavenderblush:"lavender blush",lawngreen:"lawn green",lemonchiffon:"lemon chiffon",lightblue:"albastru deschis",lightcoral:"coral deschis",lightcyan:"cyan deschis",lightgoldenrodyellow:"goldenrod gălbui deschis",lightgray:"gri deschis",lightgreen:"verde dschis",lightgrey:"gri deschis",lightpink:"roz deschis",lightsalmon:"somon deschis",lightseagreen:"verde marin deschis",lightskyblue:"albastru cer deschis",lightslategray:"gri ardezie deschis",lightslategrey:"gri ardezie deschis",lightsteelblue:"albastru metalic deschis",lightyellow:"galben deschis",lime:"lime",limegreen:"verde lime",linen:"linen",magenta:"magenta",maroon:"maro",mediumaquamarine:"aquamarin mediu",mediumblue:"albastru mediu",mediumorchid:"orchid mediu",mediumpurple:"purpuriu mediu",mediumseagreen:"verde marin mediu",mediumslateblue:"albastru ardezie mediu",mediumspringgreen:"verde primăvară mediu",mediumturquoise:"turcoaz mediu",mediumvioletred:"roşu-violet mediu",midnightblue:"midnight blue",mintcream:"mint cream",mistyrose:"misty rose",moccasin:"moccasin",navajowhite:"navajo white",navy:"navy",oldlace:"old lace",olive:"oliv",olivedrab:"oliv şters",orange:"portocaliu",orangered:"roşu portocaliu",orchid:"orchid",palegoldenrod:"goldenrod pal",palegreen:"verde pal",paleturquoise:"turcoaz pal",palevioletred:"roşu-violet pal",papayawhip:"papaya whip",peachpuff:"peach puff",peru:"peru",pink:"roz",plum:"plum",powderblue:"powder blue",purple:"purpuriu",red:"roşu",rosybrown:"rosy brown",royalblue:"albastru regal",saddlebrown:"saddle brown",salmon:"somon",sandybrown:"sandy brown",seagreen:"verde marin",seashell:"seashell",sienna:"sienna",silver:"argintiu",skyblue:"albastru cer",slateblue:"albastru ardezie",slategray:"gri ardezie",slategrey:"gri ardezie",snow:"zăpadă",springgreen:"verde primăvară",steelblue:"albastru metalic",tan:"tan",teal:"teal",thistle:"thistle",tomato:"tomato",transparent:"transparent",turquoise:"turcoaz",violet:"violet",wheat:"wheat",white:"alb",whitesmoke:"white smoke",yellow:"galben",yellowgreen:"verde gălbui"})); diff --git a/lib/dojo/nls/ro/colors.js.uncompressed.js b/lib/dojo/nls/ro/colors.js.uncompressed.js deleted file mode 100644 index 5b0d11b..0000000 --- a/lib/dojo/nls/ro/colors.js.uncompressed.js +++ /dev/null @@ -1,156 +0,0 @@ -define( -"dojo/nls/ro/colors", ({ -// local representation of all CSS3 named colors, companion to dojo.colors. To be used where descriptive information -// is required for each color, such as a palette widget, and not for specifying color programatically. - //Note: due to the SVG 1.0 spec additions, some of these are alternate spellings for the same color (e.g. gray / grey). - //TODO: should we be using unique rgb values as keys instead and avoid these duplicates, or rely on the caller to do the reverse mapping? - aliceblue: "alice blue", - antiquewhite: "antique white", - aqua: "aqua", - aquamarine: "aquamarine", - azure: "azuriu", - beige: "bej", - bisque: "bisque", - black: "negru", - blanchedalmond: "blanched almond", - blue: "albastru", - blueviolet: "albastru-violet", - brown: "brun", - burlywood: "burlywood", - cadetblue: "albastru cadet", - chartreuse: "chartreuse", - chocolate: "ciocolată", - coral: "coral", - cornflowerblue: "cornflower blue", - cornsilk: "cornsilk", - crimson: "stacojiu", - cyan: "cyan", - darkblue: "albastru închis", - darkcyan: "cyan închis", - darkgoldenrod: "goldenrod închis", - darkgray: "gri închis", - darkgreen: "verde închis", - darkgrey: "gri închis", // same as darkgray - darkkhaki: "kaki închis", - darkmagenta: "magenta închis", - darkolivegreen: "verde măslină închis", - darkorange: "portocaliu închis", - darkorchid: "orchid închis", - darkred: "roşu închis", - darksalmon: "somon închis", - darkseagreen: "verde marin închis", - darkslateblue: "albastru ardezie închis", - darkslategray: "gri ardezie închis", - darkslategrey: "gri ardezie închis", // same as darkslategray - darkturquoise: "turcoaz închis", - darkviolet: "violet închis", - deeppink: "roz profund", - deepskyblue: "albastru cer profund", - dimgray: "dim gray", - dimgrey: "dim gray", // same as dimgray - dodgerblue: "dodger blue", - firebrick: "cărămiziu aprins", - floralwhite: "floral white", - forestgreen: "forest green", - fuchsia: "fuchsia", - gainsboro: "gainsboro", - ghostwhite: "ghost white", - gold: "auriu", - goldenrod: "goldenrod", - gray: "gri", - green: "verde", - greenyellow: "verde-gălbui", - grey: "gri", // same as gray - honeydew: "honeydew", - hotpink: "roz aprins", - indianred: "roşu indian", - indigo: "indigo", - ivory: "ivoriu", - khaki: "kaki", - lavender: "lavandă", - lavenderblush: "lavender blush", - lawngreen: "lawn green", - lemonchiffon: "lemon chiffon", - lightblue: "albastru deschis", - lightcoral: "coral deschis", - lightcyan: "cyan deschis", - lightgoldenrodyellow: "goldenrod gălbui deschis", - lightgray: "gri deschis", - lightgreen: "verde dschis", - lightgrey: "gri deschis", // same as lightgray - lightpink: "roz deschis", - lightsalmon: "somon deschis", - lightseagreen: "verde marin deschis", - lightskyblue: "albastru cer deschis", - lightslategray: "gri ardezie deschis", - lightslategrey: "gri ardezie deschis", // same as lightslategray - lightsteelblue: "albastru metalic deschis", - lightyellow: "galben deschis", - lime: "lime", - limegreen: "verde lime", - linen: "linen", - magenta: "magenta", - maroon: "maro", - mediumaquamarine: "aquamarin mediu", - mediumblue: "albastru mediu", - mediumorchid: "orchid mediu", - mediumpurple: "purpuriu mediu", - mediumseagreen: "verde marin mediu", - mediumslateblue: "albastru ardezie mediu", - mediumspringgreen: "verde primăvară mediu", - mediumturquoise: "turcoaz mediu", - mediumvioletred: "roşu-violet mediu", - midnightblue: "midnight blue", - mintcream: "mint cream", - mistyrose: "misty rose", - moccasin: "moccasin", - navajowhite: "navajo white", - navy: "navy", - oldlace: "old lace", - olive: "oliv", - olivedrab: "oliv şters", - orange: "portocaliu", - orangered: "roşu portocaliu", - orchid: "orchid", - palegoldenrod: "goldenrod pal", - palegreen: "verde pal", - paleturquoise: "turcoaz pal", - palevioletred: "roşu-violet pal", - papayawhip: "papaya whip", - peachpuff: "peach puff", - peru: "peru", - pink: "roz", - plum: "plum", - powderblue: "powder blue", - purple: "purpuriu", - red: "roşu", - rosybrown: "rosy brown", - royalblue: "albastru regal", - saddlebrown: "saddle brown", - salmon: "somon", - sandybrown: "sandy brown", - seagreen: "verde marin", - seashell: "seashell", - sienna: "sienna", - silver: "argintiu", - skyblue: "albastru cer", - slateblue: "albastru ardezie", - slategray: "gri ardezie", - slategrey: "gri ardezie", // same as slategray - snow: "zăpadă", - springgreen: "verde primăvară", - steelblue: "albastru metalic", - tan: "tan", - teal: "teal", - thistle: "thistle", - tomato: "tomato", - transparent: "transparent", - turquoise: "turcoaz", - violet: "violet", - wheat: "wheat", - white: "alb", - whitesmoke: "white smoke", - yellow: "galben", - yellowgreen: "verde gălbui" -}) -); diff --git a/lib/dojo/nls/ru/colors.js b/lib/dojo/nls/ru/colors.js deleted file mode 100644 index 74575c8..0000000 --- a/lib/dojo/nls/ru/colors.js +++ /dev/null @@ -1,8 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/nls/ru/colors",({aliceblue:"серо-голубой",antiquewhite:"белый антик",aqua:"зеленовато-голубой",aquamarine:"аквамарин",azure:"лазурный",beige:"бежевый",bisque:"бисквитный",black:"черный",blanchedalmond:"светло-миндальный",blue:"синий",blueviolet:"сине-фиолетовый",brown:"коричневый",burlywood:"светло-коричневый",cadetblue:"серо-синий",chartreuse:"желто-салатный",chocolate:"шоколадный",coral:"коралловый",cornflowerblue:"фиолетово-синий",cornsilk:"шелковый оттенок",crimson:"малиновый",cyan:"циан",darkblue:"темно-синий",darkcyan:"темный циан",darkgoldenrod:"темно-золотистый",darkgray:"темно-серый",darkgreen:"темно-зеленый",darkgrey:"темно-серый",darkkhaki:"темный хаки",darkmagenta:"темно-пурпурный",darkolivegreen:"темно-оливковый",darkorange:"темно-оранжевый",darkorchid:"темный орсель",darkred:"темно-красный",darksalmon:"темно-лососевый",darkseagreen:"темный морской волны",darkslateblue:"темный грифельно-синий",darkslategray:"темный грифельно-серый",darkslategrey:"темный грифельно-серый",darkturquoise:"темный бирюзовый",darkviolet:"темно-фиолетовый",deeppink:"темно-розовый",deepskyblue:"темный небесно-голубой",dimgray:"тускло-серый",dimgrey:"тускло-серый",dodgerblue:"бледно-синий",firebrick:"кирпичный",floralwhite:"цветочно-белый",forestgreen:"зеленый лесной",fuchsia:"фуксин",gainsboro:"бледно-серый",ghostwhite:"призрачно-белый",gold:"золотой",goldenrod:"золотистый",gray:"серый",green:"зеленый",greenyellow:"зелено-желтый",grey:"серый",honeydew:"медовый",hotpink:"красно-розовый",indianred:"индийский красный",indigo:"индиго",ivory:"слоновой кости",khaki:"хаки",lavender:"бледно-лиловый",lavenderblush:"розовато-лиловый",lawngreen:"зеленая лужайка",lemonchiffon:"бледно-лимонный",lightblue:"светло-синий",lightcoral:"светло-коралловый",lightcyan:"светлый циан",lightgoldenrodyellow:"светло-золотистый",lightgray:"светло-серый",lightgreen:"светло-зеленый",lightgrey:"светло-серый",lightpink:"светло-розовый",lightsalmon:"светло-лососевый",lightseagreen:"светлый морской волны",lightskyblue:"светлый небесно-голубой",lightslategray:"светлый грифельно-серый",lightslategrey:"светлый грифельно-серый",lightsteelblue:"светлый стальной",lightyellow:"светло-желтый",lime:"лайм",limegreen:"зеленый лайм",linen:"хлопковый",magenta:"пурпурный",maroon:"темно-бордовый",mediumaquamarine:"нейтральный аквамарин",mediumblue:"нейтральный синий",mediumorchid:"нейтральный орсель",mediumpurple:"нейтральный фиолетовый",mediumseagreen:"нейтральный морской волны",mediumslateblue:"нейтральный грифельно-синий",mediumspringgreen:"нейтральный весенне-зеленый",mediumturquoise:"нейтральный бирюзовый",mediumvioletred:"нейтральный фиолетово-красный",midnightblue:"полуночно-синий",mintcream:"мятно-кремовый",mistyrose:"блекло-розовый",moccasin:"мокасин",navajowhite:"белый навахо",navy:"темно-синий",oldlace:"матово-белый",olive:"оливковый",olivedrab:"желтовато-серый",orange:"оранжевый",orangered:"оранжево-красный",orchid:"орсель",palegoldenrod:"бледно-золотистый",palegreen:"бледно-зеленый",paleturquoise:"бледно-бирюзовый",palevioletred:"бледный фиолетово-красный",papayawhip:"черенок папайи",peachpuff:"персиковый",peru:"перу",pink:"розовый",plum:"сливовый",powderblue:"пороховой",purple:"фиолетовый",red:"красный",rosybrown:"розово-коричневый",royalblue:"королевский голубой",saddlebrown:"кожано-коричневый",salmon:"лососевый",sandybrown:"коричнево-песчаный",seagreen:"морской волны",seashell:"морская раковина",sienna:"охра",silver:"серебристый",skyblue:"небесно-голубой",slateblue:"грифельно-синий",slategray:"грифельно-серый",slategrey:"грифельно-серый",snow:"белоснежный",springgreen:"весенний зеленый",steelblue:"стальной",tan:"рыжевато-коричневый",teal:"чирок",thistle:"чертополох",tomato:"помидор",transparent:"прозрачный",turquoise:"бирюзовый",violet:"фиолетовый",wheat:"пшеница",white:"белый",whitesmoke:"дымчато-белый",yellow:"желтый",yellowgreen:"желто-зеленый"})); diff --git a/lib/dojo/nls/ru/colors.js.uncompressed.js b/lib/dojo/nls/ru/colors.js.uncompressed.js deleted file mode 100644 index 902d07b..0000000 --- a/lib/dojo/nls/ru/colors.js.uncompressed.js +++ /dev/null @@ -1,156 +0,0 @@ -define( -"dojo/nls/ru/colors", ({ -// local representation of all CSS3 named colors, companion to dojo.colors. To be used where descriptive information -// is required for each color, such as a palette widget, and not for specifying color programatically. - //Note: due to the SVG 1.0 spec additions, some of these are alternate spellings for the same color (e.g. gray / grey). - //TODO: should we be using unique rgb values as keys instead and avoid these duplicates, or rely on the caller to do the reverse mapping? - aliceblue: "серо-голубой", - antiquewhite: "белый антик", - aqua: "зеленовато-голубой", - aquamarine: "аквамарин", - azure: "лазурный", - beige: "бежевый", - bisque: "бисквитный", - black: "черный", - blanchedalmond: "светло-миндальный", - blue: "синий", - blueviolet: "сине-фиолетовый", - brown: "коричневый", - burlywood: "светло-коричневый", - cadetblue: "серо-синий", - chartreuse: "желто-салатный", - chocolate: "шоколадный", - coral: "коралловый", - cornflowerblue: "фиолетово-синий", - cornsilk: "шелковый оттенок", - crimson: "малиновый", - cyan: "циан", - darkblue: "темно-синий", - darkcyan: "темный циан", - darkgoldenrod: "темно-золотистый", - darkgray: "темно-серый", - darkgreen: "темно-зеленый", - darkgrey: "темно-серый", // same as darkgray - darkkhaki: "темный хаки", - darkmagenta: "темно-пурпурный", - darkolivegreen: "темно-оливковый", - darkorange: "темно-оранжевый", - darkorchid: "темный орсель", - darkred: "темно-красный", - darksalmon: "темно-лососевый", - darkseagreen: "темный морской волны", - darkslateblue: "темный грифельно-синий", - darkslategray: "темный грифельно-серый", - darkslategrey: "темный грифельно-серый", // same as darkslategray - darkturquoise: "темный бирюзовый", - darkviolet: "темно-фиолетовый", - deeppink: "темно-розовый", - deepskyblue: "темный небесно-голубой", - dimgray: "тускло-серый", - dimgrey: "тускло-серый", // same as dimgray - dodgerblue: "бледно-синий", - firebrick: "кирпичный", - floralwhite: "цветочно-белый", - forestgreen: "зеленый лесной", - fuchsia: "фуксин", - gainsboro: "бледно-серый", - ghostwhite: "призрачно-белый", - gold: "золотой", - goldenrod: "золотистый", - gray: "серый", - green: "зеленый", - greenyellow: "зелено-желтый", - grey: "серый", // same as gray - honeydew: "медовый", - hotpink: "красно-розовый", - indianred: "индийский красный", - indigo: "индиго", - ivory: "слоновой кости", - khaki: "хаки", - lavender: "бледно-лиловый", - lavenderblush: "розовато-лиловый", - lawngreen: "зеленая лужайка", - lemonchiffon: "бледно-лимонный", - lightblue: "светло-синий", - lightcoral: "светло-коралловый", - lightcyan: "светлый циан", - lightgoldenrodyellow: "светло-золотистый", - lightgray: "светло-серый", - lightgreen: "светло-зеленый", - lightgrey: "светло-серый", // same as lightgray - lightpink: "светло-розовый", - lightsalmon: "светло-лососевый", - lightseagreen: "светлый морской волны", - lightskyblue: "светлый небесно-голубой", - lightslategray: "светлый грифельно-серый", - lightslategrey: "светлый грифельно-серый", // same as lightslategray - lightsteelblue: "светлый стальной", - lightyellow: "светло-желтый", - lime: "лайм", - limegreen: "зеленый лайм", - linen: "хлопковый", - magenta: "пурпурный", - maroon: "темно-бордовый", - mediumaquamarine: "нейтральный аквамарин", - mediumblue: "нейтральный синий", - mediumorchid: "нейтральный орсель", - mediumpurple: "нейтральный фиолетовый", - mediumseagreen: "нейтральный морской волны", - mediumslateblue: "нейтральный грифельно-синий", - mediumspringgreen: "нейтральный весенне-зеленый", - mediumturquoise: "нейтральный бирюзовый", - mediumvioletred: "нейтральный фиолетово-красный", - midnightblue: "полуночно-синий", - mintcream: "мятно-кремовый", - mistyrose: "блекло-розовый", - moccasin: "мокасин", - navajowhite: "белый навахо", - navy: "темно-синий", - oldlace: "матово-белый", - olive: "оливковый", - olivedrab: "желтовато-серый", - orange: "оранжевый", - orangered: "оранжево-красный", - orchid: "орсель", - palegoldenrod: "бледно-золотистый", - palegreen: "бледно-зеленый", - paleturquoise: "бледно-бирюзовый", - palevioletred: "бледный фиолетово-красный", - papayawhip: "черенок папайи", - peachpuff: "персиковый", - peru: "перу", - pink: "розовый", - plum: "сливовый", - powderblue: "пороховой", - purple: "фиолетовый", - red: "красный", - rosybrown: "розово-коричневый", - royalblue: "королевский голубой", - saddlebrown: "кожано-коричневый", - salmon: "лососевый", - sandybrown: "коричнево-песчаный", - seagreen: "морской волны", - seashell: "морская раковина", - sienna: "охра", - silver: "серебристый", - skyblue: "небесно-голубой", - slateblue: "грифельно-синий", - slategray: "грифельно-серый", - slategrey: "грифельно-серый", // same as slategray - snow: "белоснежный", - springgreen: "весенний зеленый", - steelblue: "стальной", - tan: "рыжевато-коричневый", - teal: "чирок", - thistle: "чертополох", - tomato: "помидор", - transparent: "прозрачный", - turquoise: "бирюзовый", - violet: "фиолетовый", - wheat: "пшеница", - white: "белый", - whitesmoke: "дымчато-белый", - yellow: "желтый", - yellowgreen: "желто-зеленый" -}) -); diff --git a/lib/dojo/nls/sk/colors.js b/lib/dojo/nls/sk/colors.js deleted file mode 100644 index 675a5f3..0000000 --- a/lib/dojo/nls/sk/colors.js +++ /dev/null @@ -1,8 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/nls/sk/colors",({aliceblue:"modrá (alice)",antiquewhite:"antická biela",aqua:"vodová",aquamarine:"akvamarínová",azure:"azúrová",beige:"béžová",bisque:"porcelánová",black:"čierna",blanchedalmond:"bledá mandľová",blue:"modrá",blueviolet:"modro-fialová",brown:"hnedá",burlywood:"drevená hnedá",cadetblue:"červeno modrá",chartreuse:"kartúzska",chocolate:"čokoládová",coral:"koralová",cornflowerblue:"nevädzová modrá",cornsilk:"ôstie kukurice",crimson:"karmínová",cyan:"zelenomodrá",darkblue:"tmavomodrá",darkcyan:"tmavá zelenomodrá",darkgoldenrod:"tmavá zlatobyľ",darkgray:"tmavosivá",darkgreen:"tmavozelená",darkgrey:"tmavosivá",darkkhaki:"tmavá žltohnedá",darkmagenta:"tmavá purpurová",darkolivegreen:"tmavá olivovo zelená",darkorange:"tmavá oranžová",darkorchid:"tmavá orchidea",darkred:"tmavočervená",darksalmon:"tmavá lososová",darkseagreen:"tmavá morská zelená",darkslateblue:"tmavá bridlicová modrá",darkslategray:"tmavá bridlicová sivá",darkslategrey:"tmavá bridlicová sivá",darkturquoise:"tmavá tyrkysová",darkviolet:"tmavofialová",deeppink:"hlboká ružová",deepskyblue:"hlboká modrá obloha",dimgray:"matná sivá",dimgrey:"matná sivá",dodgerblue:"modrá (dodger)",firebrick:"pálená tehla",floralwhite:"biely kvet",forestgreen:"lesná zelená",fuchsia:"fuchsia",gainsboro:"sivá - gainsboro",ghostwhite:"biela (ghost white)",gold:"zlatá",goldenrod:"zlatobyľ",gray:"sivá",green:"zelená",greenyellow:"zelenožltá",grey:"sivá",honeydew:"ambrózia",hotpink:"horúca ružová",indianred:"indiánska červená",indigo:"indigo",ivory:"slonovina",khaki:"kaki",lavender:"levanduľa",lavenderblush:"rumencová levanduľa",lawngreen:"trávová zelená",lemonchiffon:"citrónový šifón",lightblue:"svetlomodrá",lightcoral:"svetlá koralová",lightcyan:"svetlá zelenomodrá",lightgoldenrodyellow:"svetlá zlatobyľová žltá",lightgray:"svetlosivá",lightgreen:"svetlozelená",lightgrey:"svetlosivá",lightpink:"svetloružová",lightsalmon:"svetlá lososová",lightseagreen:"svetlá morská zelená",lightskyblue:"svetlá modrá obloha",lightslategray:"svetlá bridlicová sivá",lightslategrey:"svetlá bridlicová sivá",lightsteelblue:"svetlá oceľovomodrá",lightyellow:"svetložltá",lime:"limetková",limegreen:"limetková zelená",linen:"ľan",magenta:"purpurová",maroon:"gaštanová hnedá",mediumaquamarine:"stredná akvamarínová",mediumblue:"stredná modrá",mediumorchid:"stredná orchideová",mediumpurple:"stredná purpurová",mediumseagreen:"stredná morská zelená",mediumslateblue:"stredná bridlicová modrá",mediumspringgreen:"stredná jarná zelená",mediumturquoise:"stredná tyrkysová",mediumvioletred:"stredná fialovočervená",midnightblue:"polnočná modrá",mintcream:"mätová krémová",mistyrose:"zahmlená ruža",moccasin:"mokasínová",navajowhite:"navajská biela",navy:"námornícka",oldlace:"stará čipka",olive:"olivová",olivedrab:"fádna olivová",orange:"oranžová",orangered:"oranžovo červená",orchid:"orchideová",palegoldenrod:"bledá zlatobyľová",palegreen:"bledá zelená",paleturquoise:"bledá tyrkysová",palevioletred:"bledá fialovo červená",papayawhip:"papájový krém",peachpuff:"broskyňový nádych",peru:"peru",pink:"ružová",plum:"slivková",powderblue:"prášková modrá",purple:"purpurová",red:"červená",rosybrown:"ružovo hnedá",royalblue:"kráľovská modrá",saddlebrown:"sedlová hnedá",salmon:"lososová",sandybrown:"piesková hnedá",seagreen:"morská zelená",seashell:"lastúrová",sienna:"sienská",silver:"strieborná",skyblue:"modré nebo",slateblue:"bridlicová modrá",slategray:"bridlicová sivá",slategrey:"bridlicová sivá",snow:"snehová",springgreen:"jarná zelená",steelblue:"oceľovomodrá",tan:"žltohnedá",teal:"zelenomodrá",thistle:"bodliaková",tomato:"paradajková",transparent:"priesvitná",turquoise:"tyrkysová",violet:"fialová",wheat:"pšeničná",white:"biela",whitesmoke:"biely dym",yellow:"žltá",yellowgreen:"žltozelená"})); diff --git a/lib/dojo/nls/sk/colors.js.uncompressed.js b/lib/dojo/nls/sk/colors.js.uncompressed.js deleted file mode 100644 index 700f727..0000000 --- a/lib/dojo/nls/sk/colors.js.uncompressed.js +++ /dev/null @@ -1,156 +0,0 @@ -define( -"dojo/nls/sk/colors", ({ -// local representation of all CSS3 named colors, companion to dojo.colors. To be used where descriptive information -// is required for each color, such as a palette widget, and not for specifying color programatically. - //Note: due to the SVG 1.0 spec additions, some of these are alternate spellings for the same color (e.g. gray / grey). - //TODO: should we be using unique rgb values as keys instead and avoid these duplicates, or rely on the caller to do the reverse mapping? - aliceblue: "modrá (alice)", - antiquewhite: "antická biela", - aqua: "vodová", - aquamarine: "akvamarínová", - azure: "azúrová", - beige: "béžová", - bisque: "porcelánová", - black: "čierna", - blanchedalmond: "bledá mandľová", - blue: "modrá", - blueviolet: "modro-fialová", - brown: "hnedá", - burlywood: "drevená hnedá", - cadetblue: "červeno modrá", - chartreuse: "kartúzska", - chocolate: "čokoládová", - coral: "koralová", - cornflowerblue: "nevädzová modrá", - cornsilk: "ôstie kukurice", - crimson: "karmínová", - cyan: "zelenomodrá", - darkblue: "tmavomodrá", - darkcyan: "tmavá zelenomodrá", - darkgoldenrod: "tmavá zlatobyľ", - darkgray: "tmavosivá", - darkgreen: "tmavozelená", - darkgrey: "tmavosivá", // same as darkgray - darkkhaki: "tmavá žltohnedá", - darkmagenta: "tmavá purpurová", - darkolivegreen: "tmavá olivovo zelená", - darkorange: "tmavá oranžová", - darkorchid: "tmavá orchidea", - darkred: "tmavočervená", - darksalmon: "tmavá lososová", - darkseagreen: "tmavá morská zelená", - darkslateblue: "tmavá bridlicová modrá", - darkslategray: "tmavá bridlicová sivá", - darkslategrey: "tmavá bridlicová sivá", // same as darkslategray - darkturquoise: "tmavá tyrkysová", - darkviolet: "tmavofialová", - deeppink: "hlboká ružová", - deepskyblue: "hlboká modrá obloha", - dimgray: "matná sivá", - dimgrey: "matná sivá", // same as dimgray - dodgerblue: "modrá (dodger)", - firebrick: "pálená tehla", - floralwhite: "biely kvet", - forestgreen: "lesná zelená", - fuchsia: "fuchsia", - gainsboro: "sivá - gainsboro", - ghostwhite: "biela (ghost white)", - gold: "zlatá", - goldenrod: "zlatobyľ", - gray: "sivá", - green: "zelená", - greenyellow: "zelenožltá", - grey: "sivá", // same as gray - honeydew: "ambrózia", - hotpink: "horúca ružová", - indianred: "indiánska červená", - indigo: "indigo", - ivory: "slonovina", - khaki: "kaki", - lavender: "levanduľa", - lavenderblush: "rumencová levanduľa", - lawngreen: "trávová zelená", - lemonchiffon: "citrónový šifón", - lightblue: "svetlomodrá", - lightcoral: "svetlá koralová", - lightcyan: "svetlá zelenomodrá", - lightgoldenrodyellow: "svetlá zlatobyľová žltá", - lightgray: "svetlosivá", - lightgreen: "svetlozelená", - lightgrey: "svetlosivá", // same as lightgray - lightpink: "svetloružová", - lightsalmon: "svetlá lososová", - lightseagreen: "svetlá morská zelená", - lightskyblue: "svetlá modrá obloha", - lightslategray: "svetlá bridlicová sivá", - lightslategrey: "svetlá bridlicová sivá", // same as lightslategray - lightsteelblue: "svetlá oceľovomodrá", - lightyellow: "svetložltá", - lime: "limetková", - limegreen: "limetková zelená", - linen: "ľan", - magenta: "purpurová", - maroon: "gaštanová hnedá", - mediumaquamarine: "stredná akvamarínová", - mediumblue: "stredná modrá", - mediumorchid: "stredná orchideová", - mediumpurple: "stredná purpurová", - mediumseagreen: "stredná morská zelená", - mediumslateblue: "stredná bridlicová modrá", - mediumspringgreen: "stredná jarná zelená", - mediumturquoise: "stredná tyrkysová", - mediumvioletred: "stredná fialovočervená", - midnightblue: "polnočná modrá", - mintcream: "mätová krémová", - mistyrose: "zahmlená ruža", - moccasin: "mokasínová", - navajowhite: "navajská biela", - navy: "námornícka", - oldlace: "stará čipka", - olive: "olivová", - olivedrab: "fádna olivová", - orange: "oranžová", - orangered: "oranžovo červená", - orchid: "orchideová", - palegoldenrod: "bledá zlatobyľová", - palegreen: "bledá zelená", - paleturquoise: "bledá tyrkysová", - palevioletred: "bledá fialovo červená", - papayawhip: "papájový krém", - peachpuff: "broskyňový nádych", - peru: "peru", - pink: "ružová", - plum: "slivková", - powderblue: "prášková modrá", - purple: "purpurová", - red: "červená", - rosybrown: "ružovo hnedá", - royalblue: "kráľovská modrá", - saddlebrown: "sedlová hnedá", - salmon: "lososová", - sandybrown: "piesková hnedá", - seagreen: "morská zelená", - seashell: "lastúrová", - sienna: "sienská", - silver: "strieborná", - skyblue: "modré nebo", - slateblue: "bridlicová modrá", - slategray: "bridlicová sivá", - slategrey: "bridlicová sivá", // same as slategray - snow: "snehová", - springgreen: "jarná zelená", - steelblue: "oceľovomodrá", - tan: "žltohnedá", - teal: "zelenomodrá", - thistle: "bodliaková", - tomato: "paradajková", - transparent: "priesvitná", - turquoise: "tyrkysová", - violet: "fialová", - wheat: "pšeničná", - white: "biela", - whitesmoke: "biely dym", - yellow: "žltá", - yellowgreen: "žltozelená" -}) -); diff --git a/lib/dojo/nls/sl/colors.js b/lib/dojo/nls/sl/colors.js deleted file mode 100644 index b9ab054..0000000 --- a/lib/dojo/nls/sl/colors.js +++ /dev/null @@ -1,8 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/nls/sl/colors",({aliceblue:"alice blue modra",antiquewhite:"antično bela",aqua:"svetlo modra",aquamarine:"akvamarin",azure:"azurno modra",beige:"bež",bisque:"porcelanasta",black:"črna",blanchedalmond:"obledelo mandljeva",blue:"modra",blueviolet:"modro vijolična",brown:"rjava",burlywood:"peščeno sivo-rjava",cadetblue:"kadetsko modra",chartreuse:"chartreuse",chocolate:"čokoladna",coral:"koralna",cornflowerblue:"plavičasto modra",cornsilk:"koruzna",crimson:"karminasta",cyan:"cijan",darkblue:"temno modra",darkcyan:"temno cijan",darkgoldenrod:"temna zlata rozga",darkgray:"temno siva",darkgreen:"temno zelena",darkgrey:"temno siva",darkkhaki:"temno kaki",darkmagenta:"temna magenta",darkolivegreen:"temna olivno zelena",darkorange:"temno oranžna",darkorchid:"temno orhidejasta",darkred:"temno rdeča",darksalmon:"temno lososova",darkseagreen:"temno morsko zelena",darkslateblue:"temno skrilasto modra",darkslategray:"temno skrilasto siva",darkslategrey:"temno skrilasto siva",darkturquoise:"temno turkizna",darkviolet:"temno vijolična",deeppink:"temno rožnata",deepskyblue:"temno nebeško modra",dimgray:"pepelnato siva",dimgrey:"pepelnato siva",dodgerblue:"dodgersko modra",firebrick:"opečnata",floralwhite:"cvetno bela",forestgreen:"gozdno zelena",fuchsia:"roza",gainsboro:"gainsboro",ghostwhite:"senčnato bela",gold:"zlata",goldenrod:"zlata rozga",gray:"siva",green:"zelena",greenyellow:"zeleno-rumena",grey:"siva",honeydew:"medena rosa",hotpink:"kričeče rožnata",indianred:"indijansko rdeča",indigo:"indigo",ivory:"slonokoščena",khaki:"kaki",lavender:"sivka",lavenderblush:"rožnato sivka",lawngreen:"travniško zelena",lemonchiffon:"limonast šifon",lightblue:"svetlo modra",lightcoral:"svetlo koralna",lightcyan:"svetlo cijan",lightgoldenrodyellow:"svetlo rumena zlata rozga",lightgray:"svetlo siva",lightgreen:"svetlo zelena",lightgrey:"svetlo siva",lightpink:"svetlo rožnata",lightsalmon:"svetlo lososova",lightseagreen:"svetlo morsko zelena",lightskyblue:"svetlo nebeško modra",lightslategray:"svetlo skrilasto siva",lightslategrey:"svetlo skrilasto siva",lightsteelblue:"svetlo kovinsko modra",lightyellow:"svetlo rumena",lime:"svetlo zelena",limegreen:"apneno zelena",linen:"lanena",magenta:"magenta",maroon:"kostanjeva",mediumaquamarine:"srednji akvamarin",mediumblue:"srednje modra",mediumorchid:"srednje orhidejasta",mediumpurple:"srednje škrlatna",mediumseagreen:"srednje morsko zelena",mediumslateblue:"srednje skrilasto modra",mediumspringgreen:"srednje pomladno zelena",mediumturquoise:"srednje turkizna",mediumvioletred:"srednje vijolično rdeča",midnightblue:"polnočno modra",mintcream:"metina krema",mistyrose:"megleno rožnata",moccasin:"mokasinasta",navajowhite:"navajo bela",navy:"mornarsko modra",oldlace:"stara čipka",olive:"olivno zelena",olivedrab:"umazano olivna",orange:"oranžna",orangered:"oranžno-rdeča",orchid:"orhidejasta",palegoldenrod:"bleda zlata rozga",palegreen:"bledo zelena",paleturquoise:"bledo turkizna",palevioletred:"bledo vijolično-rdeča",papayawhip:"papaja",peachpuff:"breskova",peru:"perujska",pink:"rožnata",plum:"slivova",powderblue:"kobaltovo modra",purple:"škrlatna",red:"rdeča",rosybrown:"rožnato rjava",royalblue:"kraljevsko modra",saddlebrown:"sedlasto rjava",salmon:"lososova",sandybrown:"peščeno rjava",seagreen:"morsko zelena",seashell:"morska lupina",sienna:"sienna",silver:"srebrna",skyblue:"nebeško modra",slateblue:"skrilasto modra",slategray:"skrilasto siva",slategrey:"skrilasto siva",snow:"snežena",springgreen:"pomladno zelena",steelblue:"kovinsko modra",tan:"rumeno-rjava",teal:"modrozelena",thistle:"osatna",tomato:"paradižnikova",transparent:"prosojno",turquoise:"turkizna",violet:"vijolična",wheat:"pšenična",white:"bela",whitesmoke:"megleno bela",yellow:"rumena",yellowgreen:"rumeno-zelena"})); diff --git a/lib/dojo/nls/sl/colors.js.uncompressed.js b/lib/dojo/nls/sl/colors.js.uncompressed.js deleted file mode 100644 index 9a73f47..0000000 --- a/lib/dojo/nls/sl/colors.js.uncompressed.js +++ /dev/null @@ -1,156 +0,0 @@ -define( -"dojo/nls/sl/colors", ({ -// local representation of all CSS3 named colors, companion to dojo.colors. To be used where descriptive information -// is required for each color, such as a palette widget, and not for specifying color programatically. -//Note: due to the SVG 1.0 spec additions, some of these are alternate spellings for the same color (e.g. gray / grey). -//TODO: should we be using unique rgb values as keys instead and avoid these duplicates, or rely on the caller to do the reverse mapping? - aliceblue: "alice blue modra", - antiquewhite: "antično bela", - aqua: "svetlo modra", - aquamarine: "akvamarin", - azure: "azurno modra", - beige: "bež", - bisque: "porcelanasta", - black: "črna", - blanchedalmond: "obledelo mandljeva", - blue: "modra", - blueviolet: "modro vijolična", - brown: "rjava", - burlywood: "peščeno sivo-rjava", - cadetblue: "kadetsko modra", - chartreuse: "chartreuse", - chocolate: "čokoladna", - coral: "koralna", - cornflowerblue: "plavičasto modra", - cornsilk: "koruzna", - crimson: "karminasta", - cyan: "cijan", - darkblue: "temno modra", - darkcyan: "temno cijan", - darkgoldenrod: "temna zlata rozga", - darkgray: "temno siva", - darkgreen: "temno zelena", - darkgrey: "temno siva", // same as darkgray - darkkhaki: "temno kaki", - darkmagenta: "temna magenta", - darkolivegreen: "temna olivno zelena", - darkorange: "temno oranžna", - darkorchid: "temno orhidejasta", - darkred: "temno rdeča", - darksalmon: "temno lososova", - darkseagreen: "temno morsko zelena", - darkslateblue: "temno skrilasto modra", - darkslategray: "temno skrilasto siva", - darkslategrey: "temno skrilasto siva", // same as darkslategray - darkturquoise: "temno turkizna", - darkviolet: "temno vijolična", - deeppink: "temno rožnata", - deepskyblue: "temno nebeško modra", - dimgray: "pepelnato siva", - dimgrey: "pepelnato siva", // same as dimgray - dodgerblue: "dodgersko modra", - firebrick: "opečnata", - floralwhite: "cvetno bela", - forestgreen: "gozdno zelena", - fuchsia: "roza", - gainsboro: "gainsboro", - ghostwhite: "senčnato bela", - gold: "zlata", - goldenrod: "zlata rozga", - gray: "siva", - green: "zelena", - greenyellow: "zeleno-rumena", - grey: "siva", // same as gray - honeydew: "medena rosa", - hotpink: "kričeče rožnata", - indianred: "indijansko rdeča", - indigo: "indigo", - ivory: "slonokoščena", - khaki: "kaki", - lavender: "sivka", - lavenderblush: "rožnato sivka", - lawngreen: "travniško zelena", - lemonchiffon: "limonast šifon", - lightblue: "svetlo modra", - lightcoral: "svetlo koralna", - lightcyan: "svetlo cijan", - lightgoldenrodyellow: "svetlo rumena zlata rozga", - lightgray: "svetlo siva", - lightgreen: "svetlo zelena", - lightgrey: "svetlo siva", // same as lightgray - lightpink: "svetlo rožnata", - lightsalmon: "svetlo lososova", - lightseagreen: "svetlo morsko zelena", - lightskyblue: "svetlo nebeško modra", - lightslategray: "svetlo skrilasto siva", - lightslategrey: "svetlo skrilasto siva", // same as lightslategray - lightsteelblue: "svetlo kovinsko modra", - lightyellow: "svetlo rumena", - lime: "svetlo zelena", - limegreen: "apneno zelena", - linen: "lanena", - magenta: "magenta", - maroon: "kostanjeva", - mediumaquamarine: "srednji akvamarin", - mediumblue: "srednje modra", - mediumorchid: "srednje orhidejasta", - mediumpurple: "srednje škrlatna", - mediumseagreen: "srednje morsko zelena", - mediumslateblue: "srednje skrilasto modra", - mediumspringgreen: "srednje pomladno zelena", - mediumturquoise: "srednje turkizna", - mediumvioletred: "srednje vijolično rdeča", - midnightblue: "polnočno modra", - mintcream: "metina krema", - mistyrose: "megleno rožnata", - moccasin: "mokasinasta", - navajowhite: "navajo bela", - navy: "mornarsko modra", - oldlace: "stara čipka", - olive: "olivno zelena", - olivedrab: "umazano olivna", - orange: "oranžna", - orangered: "oranžno-rdeča", - orchid: "orhidejasta", - palegoldenrod: "bleda zlata rozga", - palegreen: "bledo zelena", - paleturquoise: "bledo turkizna", - palevioletred: "bledo vijolično-rdeča", - papayawhip: "papaja", - peachpuff: "breskova", - peru: "perujska", - pink: "rožnata", - plum: "slivova", - powderblue: "kobaltovo modra", - purple: "škrlatna", - red: "rdeča", - rosybrown: "rožnato rjava", - royalblue: "kraljevsko modra", - saddlebrown: "sedlasto rjava", - salmon: "lososova", - sandybrown: "peščeno rjava", - seagreen: "morsko zelena", - seashell: "morska lupina", - sienna: "sienna", - silver: "srebrna", - skyblue: "nebeško modra", - slateblue: "skrilasto modra", - slategray: "skrilasto siva", - slategrey: "skrilasto siva", // same as slategray - snow: "snežena", - springgreen: "pomladno zelena", - steelblue: "kovinsko modra", - tan: "rumeno-rjava", - teal: "modrozelena", - thistle: "osatna", - tomato: "paradižnikova", - transparent: "prosojno", - turquoise: "turkizna", - violet: "vijolična", - wheat: "pšenična", - white: "bela", - whitesmoke: "megleno bela", - yellow: "rumena", - yellowgreen: "rumeno-zelena" -}) -); diff --git a/lib/dojo/nls/sv/colors.js b/lib/dojo/nls/sv/colors.js deleted file mode 100644 index 06702f3..0000000 --- a/lib/dojo/nls/sv/colors.js +++ /dev/null @@ -1,8 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/nls/sv/colors",({aliceblue:"aliceblå",antiquewhite:"antikvitt",aqua:"akvamarin",aquamarine:"akvamarin",azure:"azurblått",beige:"beige",bisque:"biskvi",black:"svart",blanchedalmond:"skållad mandel",blue:"blått",blueviolet:"blåviolett",brown:"brunt",burlywood:"träfärgat",cadetblue:"kadettblått",chartreuse:"chartreuse",chocolate:"choklad",coral:"korall",cornflowerblue:"kornblått",cornsilk:"gulvitt",crimson:"karmosinrött",cyan:"cyan",darkblue:"mörkblått",darkcyan:"mörkt cyan",darkgoldenrod:"mörkt gullris",darkgray:"mörkgrått",darkgreen:"mörkgrönt",darkgrey:"mörkgrått",darkkhaki:"mörkt kaki",darkmagenta:"mörk magenta",darkolivegreen:"mörkt olivgrönt",darkorange:"mörkorange",darkorchid:"mörkt orkidé",darkred:"mörkrött",darksalmon:"mörkt laxfärgat",darkseagreen:"mörkt havsgrönt",darkslateblue:"mörkt skifferblått",darkslategray:"mörkt skiffergrått",darkslategrey:"mörkt skiffergrått",darkturquoise:"mörkturkost",darkviolet:"mörkviolett",deeppink:"djuprosa",deepskyblue:"mörkt himmelsblått",dimgray:"smutsgrått",dimgrey:"smutsgrått",dodgerblue:"dodgerblått",firebrick:"tegelstensrött",floralwhite:"blomvitt",forestgreen:"skogsgrönt",fuchsia:"fuchsia",gainsboro:"gainsboro",ghostwhite:"spökvitt",gold:"guld",goldenrod:"gullris",gray:"grått",green:"grönt",greenyellow:"gröngult",grey:"grått",honeydew:"honungsdagg",hotpink:"varmrosa",indianred:"indianrött",indigo:"indigo",ivory:"elfenbensvitt",khaki:"kaki",lavender:"lavendel",lavenderblush:"lavendelskimrande",lawngreen:"gräsmattegrönt",lemonchiffon:"citronchiffong",lightblue:"ljusblått",lightcoral:"ljuskorall",lightcyan:"ljust cyan",lightgoldenrodyellow:"ljust gullrisgult",lightgray:"ljusgrått",lightgreen:"ljusgrönt",lightgrey:"ljusgrått",lightpink:"ljusrosa",lightsalmon:"ljust laxfärgat",lightseagreen:"ljust havsgrönt",lightskyblue:"ljust himmelsblått",lightslategray:"ljust skiffergrått",lightslategrey:"ljust skiffergrått",lightsteelblue:"ljust stålblått",lightyellow:"ljusgult",lime:"lime",limegreen:"limegrönt",linen:"linne",magenta:"magenta",maroon:"rödbrunt",mediumaquamarine:"mellanakvamarin",mediumblue:"mellanblått",mediumorchid:"mellanorkidé",mediumpurple:"mellanlila",mediumseagreen:"mellanhavsgrönt",mediumslateblue:"mellanskifferblått",mediumspringgreen:"mellanvårgrönt",mediumturquoise:"mellanturkost",mediumvioletred:"mellanviolettrött",midnightblue:"midnattsblått",mintcream:"mintgrädde",mistyrose:"dunkelrosa",moccasin:"mockasin",navajowhite:"navajovitt",navy:"marinblått",oldlace:"spetsvitt",olive:"olivfärgat",olivedrab:"olivsmutsgult",orange:"orange",orangered:"orangerött",orchid:"orkidé",palegoldenrod:"blekt gullris",palegreen:"blekgrönt",paleturquoise:"blekturkost",palevioletred:"blekviolettrött",papayawhip:"papayaröra",peachpuff:"persika",peru:"peru",pink:"rosa",plum:"plommon",powderblue:"pulverblått",purple:"lila",red:"rött",rosybrown:"rosenbrunt",royalblue:"kungligt blått",saddlebrown:"sadelbrunt",salmon:"laxfärgat",sandybrown:"sandbrunt",seagreen:"havsgrönt",seashell:"snäckskal",sienna:"sienna",silver:"silver",skyblue:"himmelsblått",slateblue:"skifferblått",slategray:"skiffergrått",slategrey:"skiffergrått",snow:"snö",springgreen:"vårgrönt",steelblue:"stålblått",tan:"mellanbrunt",teal:"blågrönt",thistle:"tistel",tomato:"tomatrött",transparent:"transparent",turquoise:"turkost",violet:"violett",wheat:"vete",white:"vitt",whitesmoke:"vit rök",yellow:"gult",yellowgreen:"gulgrönt"})); diff --git a/lib/dojo/nls/sv/colors.js.uncompressed.js b/lib/dojo/nls/sv/colors.js.uncompressed.js deleted file mode 100644 index 2aba2e3..0000000 --- a/lib/dojo/nls/sv/colors.js.uncompressed.js +++ /dev/null @@ -1,156 +0,0 @@ -define( -"dojo/nls/sv/colors", ({ -// local representation of all CSS3 named colors, companion to dojo.colors. To be used where descriptive information -// is required for each color, such as a palette widget, and not for specifying color programatically. - //Note: due to the SVG 1.0 spec additions, some of these are alternate spellings for the same color (e.g. gray / grey). - //TODO: should we be using unique rgb values as keys instead and avoid these duplicates, or rely on the caller to do the reverse mapping? - aliceblue: "aliceblå", - antiquewhite: "antikvitt", - aqua: "akvamarin", - aquamarine: "akvamarin", - azure: "azurblått", - beige: "beige", - bisque: "biskvi", - black: "svart", - blanchedalmond: "skållad mandel", - blue: "blått", - blueviolet: "blåviolett", - brown: "brunt", - burlywood: "träfärgat", - cadetblue: "kadettblått", - chartreuse: "chartreuse", - chocolate: "choklad", - coral: "korall", - cornflowerblue: "kornblått", - cornsilk: "gulvitt", - crimson: "karmosinrött", - cyan: "cyan", - darkblue: "mörkblått", - darkcyan: "mörkt cyan", - darkgoldenrod: "mörkt gullris", - darkgray: "mörkgrått", - darkgreen: "mörkgrönt", - darkgrey: "mörkgrått", // same as darkgray - darkkhaki: "mörkt kaki", - darkmagenta: "mörk magenta", - darkolivegreen: "mörkt olivgrönt", - darkorange: "mörkorange", - darkorchid: "mörkt orkidé", - darkred: "mörkrött", - darksalmon: "mörkt laxfärgat", - darkseagreen: "mörkt havsgrönt", - darkslateblue: "mörkt skifferblått", - darkslategray: "mörkt skiffergrått", - darkslategrey: "mörkt skiffergrått", // same as darkslategray - darkturquoise: "mörkturkost", - darkviolet: "mörkviolett", - deeppink: "djuprosa", - deepskyblue: "mörkt himmelsblått", - dimgray: "smutsgrått", - dimgrey: "smutsgrått", // same as dimgray - dodgerblue: "dodgerblått", - firebrick: "tegelstensrött", - floralwhite: "blomvitt", - forestgreen: "skogsgrönt", - fuchsia: "fuchsia", - gainsboro: "gainsboro", - ghostwhite: "spökvitt", - gold: "guld", - goldenrod: "gullris", - gray: "grått", - green: "grönt", - greenyellow: "gröngult", - grey: "grått", // same as gray - honeydew: "honungsdagg", - hotpink: "varmrosa", - indianred: "indianrött", - indigo: "indigo", - ivory: "elfenbensvitt", - khaki: "kaki", - lavender: "lavendel", - lavenderblush: "lavendelskimrande", - lawngreen: "gräsmattegrönt", - lemonchiffon: "citronchiffong", - lightblue: "ljusblått", - lightcoral: "ljuskorall", - lightcyan: "ljust cyan", - lightgoldenrodyellow: "ljust gullrisgult", - lightgray: "ljusgrått", - lightgreen: "ljusgrönt", - lightgrey: "ljusgrått", // same as lightgray - lightpink: "ljusrosa", - lightsalmon: "ljust laxfärgat", - lightseagreen: "ljust havsgrönt", - lightskyblue: "ljust himmelsblått", - lightslategray: "ljust skiffergrått", - lightslategrey: "ljust skiffergrått", // same as lightslategray - lightsteelblue: "ljust stålblått", - lightyellow: "ljusgult", - lime: "lime", - limegreen: "limegrönt", - linen: "linne", - magenta: "magenta", - maroon: "rödbrunt", - mediumaquamarine: "mellanakvamarin", - mediumblue: "mellanblått", - mediumorchid: "mellanorkidé", - mediumpurple: "mellanlila", - mediumseagreen: "mellanhavsgrönt", - mediumslateblue: "mellanskifferblått", - mediumspringgreen: "mellanvårgrönt", - mediumturquoise: "mellanturkost", - mediumvioletred: "mellanviolettrött", - midnightblue: "midnattsblått", - mintcream: "mintgrädde", - mistyrose: "dunkelrosa", - moccasin: "mockasin", - navajowhite: "navajovitt", - navy: "marinblått", - oldlace: "spetsvitt", - olive: "olivfärgat", - olivedrab: "olivsmutsgult", - orange: "orange", - orangered: "orangerött", - orchid: "orkidé", - palegoldenrod: "blekt gullris", - palegreen: "blekgrönt", - paleturquoise: "blekturkost", - palevioletred: "blekviolettrött", - papayawhip: "papayaröra", - peachpuff: "persika", - peru: "peru", - pink: "rosa", - plum: "plommon", - powderblue: "pulverblått", - purple: "lila", - red: "rött", - rosybrown: "rosenbrunt", - royalblue: "kungligt blått", - saddlebrown: "sadelbrunt", - salmon: "laxfärgat", - sandybrown: "sandbrunt", - seagreen: "havsgrönt", - seashell: "snäckskal", - sienna: "sienna", - silver: "silver", - skyblue: "himmelsblått", - slateblue: "skifferblått", - slategray: "skiffergrått", - slategrey: "skiffergrått", // same as slategray - snow: "snö", - springgreen: "vårgrönt", - steelblue: "stålblått", - tan: "mellanbrunt", - teal: "blågrönt", - thistle: "tistel", - tomato: "tomatrött", - transparent: "transparent", - turquoise: "turkost", - violet: "violett", - wheat: "vete", - white: "vitt", - whitesmoke: "vit rök", - yellow: "gult", - yellowgreen: "gulgrönt" -}) -); diff --git a/lib/dojo/nls/th/colors.js b/lib/dojo/nls/th/colors.js deleted file mode 100644 index aa45e4d..0000000 --- a/lib/dojo/nls/th/colors.js +++ /dev/null @@ -1,8 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/nls/th/colors",({aliceblue:"ฟ้าจาง",antiquewhite:"สีเนื้อ",aqua:"ฟ้าน้ำทะเล",aquamarine:"อะความารีน",azure:"น้ำเงินฟ้า",beige:"น้ำตาลเบจ",bisque:"ขาวข้าวสาร",black:"ดำ",blanchedalmond:"เนื้ออ่อน",blue:"น้ำเงิน",blueviolet:"น้ำเงินม่วง",brown:"น้ำตาล",burlywood:"น้ำตาลอ่อน",cadetblue:"เขียวน้ำเงินหม่น",chartreuse:"เขียวสะท้อนแสง",chocolate:"ช็อกโกแลต",coral:"แสดเข้มนวล",cornflowerblue:"สีคอร์นฟลาวเวอร์บลู",cornsilk:"cornsilk",crimson:"แดงเลือดหมู",cyan:"เขียวแกมน้ำเงิน",darkblue:"น้ำเงินเข้ม",darkcyan:"เขียวแกมน้ำเงินเข้ม",darkgoldenrod:"ทองเหลืองเข้ม",darkgray:"เทาเข้ม",darkgreen:"เขียวเข้ม",darkgrey:"เทาเข้ม",darkkhaki:"กากีเข้ม",darkmagenta:"แดงแกมม่วงเข้ม",darkolivegreen:"เขียวโอลีฟเข้ม",darkorange:"ส้มเข้ม",darkorchid:"สีม่วงกล้วยไม้เข้ม",darkred:"แดงเข้ม",darksalmon:"ส้มเข้ม",darkseagreen:"เขียวทะเลเข้ม",darkslateblue:"น้ำเงินนวลเข้ม",darkslategray:"เทานวลเข้ม",darkslategrey:"เทานวลเข้ม",darkturquoise:"ฟ้าขี้นกการเวกเข้ม",darkviolet:"ม่วงเข้ม",deeppink:"ชมพูเข้ม",deepskyblue:"ฟ้าสด",dimgray:"เทาทึม",dimgrey:"เทาทึม",dodgerblue:"ฟ้าสะท้อนแสง",firebrick:"สีอิฐ",floralwhite:"ขาวแกมชมพู",forestgreen:"หยก",fuchsia:"บานเย็น",gainsboro:"เทานวล",ghostwhite:"น้ำข้าว",gold:"ทอง",goldenrod:"ทองเหลือง",gray:"เทา",green:"เขียว",greenyellow:"เขียวแกมเหลือง",grey:"เทา",honeydew:"ขาวแกมเขียว",hotpink:"ชมพูจัด",indianred:"แดงอมเหลือง",indigo:"คราม",ivory:"งาช้าง",khaki:"กากี",lavender:"ม่วงลาเวนเดอร์",lavenderblush:"นมเย็น",lawngreen:"เขียวหญ้าอ่อน",lemonchiffon:"lemon chiffon",lightblue:"น้ำเงินอ่อน",lightcoral:"ชมพูอมแดง",lightcyan:"เขียวแกมน้ำเงินอ่อน",lightgoldenrodyellow:"ทองเหลืองอ่อน",lightgray:"เทาอ่อน",lightgreen:"เขียวอ่อน",lightgrey:"เทาอ่อน",lightpink:"ชมพูอ่อน",lightsalmon:"ส้มจาง",lightseagreen:"เขียวทะเลอ่อน",lightskyblue:"ฟ้าอ่อน",lightslategray:"เทานวลอ่อน",lightslategrey:"เทานวลอ่อน",lightsteelblue:"น้ำเงินนวลอ่อน",lightyellow:"เหลืองอ่อน",lime:"เหลืองมะนาว",limegreen:"เขียวมะนาว",linen:"ลินนิน",magenta:"แดงแกมม่วง",maroon:"น้ำตาลแดง",mediumaquamarine:"อะความารีนกลางๆ",mediumblue:"น้ำเงินกลางๆ",mediumorchid:"ม่วงกล้วยไม้กลางๆ",mediumpurple:"ม่วงอัญชัญ",mediumseagreen:" เขียวทะเลกลางๆ",mediumslateblue:"น้ำเงินนวลกลางๆ",mediumspringgreen:"สีเขียวนวลกลางๆ",mediumturquoise:"ฟ้าขี้นกการเวกกลางๆ",mediumvioletred:"แดงอมม่วงกลางๆ",midnightblue:"น้ำเงินทึบ",mintcream:"ขาวกะทิ",mistyrose:"ชมพูหม่น",moccasin:"ม็อคค่า",navajowhite:"ส้มหนังกลับ",navy:"น้ำเงินเข้ม",oldlace:"ขาวนวล",olive:"โอลีฟ",olivedrab:"เขียวมะกอกแก่",orange:"ส้ม",orangered:"ส้มแกมแดง",orchid:"สีกล้วยไม้",palegoldenrod:"ทองเหลืองจาง",palegreen:"เขียวจาง",paleturquoise:"ฟ้าขี้นกการเวกจาง",palevioletred:"แดงอมม่วงจาง",papayawhip:"ชมพูจาง",peachpuff:" สีพีช",peru:"ส้มดินเผา",pink:"ชมพู",plum:"ม่วงอ่อน",powderblue:"ฟ้าหม่น",purple:"ม่วง",red:"แดง",rosybrown:"กะปิ",royalblue:"น้ำเงินเข้ม",saddlebrown:"น้ำตาล",salmon:"ส้มอ่อน",sandybrown:"น้ำตาลลูกรัง",seagreen:"เขียวทะเล",seashell:"สีขาวหอยทะเล",sienna:"น้ำตาลอมแดง",silver:"เงิน",skyblue:"ฟ้า",slateblue:"น้ำเงินนวล",slategray:"เทาอมน้ำเงินนวล",slategrey:"เทาอมน้ำเงินนวล",snow:"ขาวหิมะ",springgreen:"เขียว",steelblue:"น้ำเงินด้าน",tan:"แทน",teal:"เขียวหัวเป็ด",thistle:"ม่วงจาง",tomato:"แสด",transparent:"สีใส",turquoise:"ฟ้าขี้นกการเวก",violet:"ม่วง",wheat:"เหลืองรำข้าว",white:"ขาว",whitesmoke:"ขาวควัน",yellow:"เหลือง",yellowgreen:"เหลืองแกมเขียว"})); diff --git a/lib/dojo/nls/th/colors.js.uncompressed.js b/lib/dojo/nls/th/colors.js.uncompressed.js deleted file mode 100644 index 520bdac..0000000 --- a/lib/dojo/nls/th/colors.js.uncompressed.js +++ /dev/null @@ -1,157 +0,0 @@ -define( -"dojo/nls/th/colors", ({ -// local representation of all CSS3 named colors, companion to dojo.colors. To be used where descriptive information -// is required for each color, such as a palette widget, and not for specifying color programatically. - -//Note: due to the SVG 1.0 spec additions, some of these are alternate spellings for the same color (e.g. gray / grey). -//TODO: should we be using unique rgb values as keys instead and avoid these duplicates, or rely on the caller to do the reverse mapping? -aliceblue: "ฟ้าจาง", -antiquewhite: "สีเนื้อ", -aqua: "ฟ้าน้ำทะเล", -aquamarine: "อะความารีน", -azure: "น้ำเงินฟ้า", -beige: "น้ำตาลเบจ", -bisque: "ขาวข้าวสาร", -black: "ดำ", -blanchedalmond: "เนื้ออ่อน", -blue: "น้ำเงิน", -blueviolet: "น้ำเงินม่วง", -brown: "น้ำตาล", -burlywood: "น้ำตาลอ่อน", -cadetblue: "เขียวน้ำเงินหม่น", -chartreuse: "เขียวสะท้อนแสง", -chocolate: "ช็อกโกแลต", -coral: "แสดเข้มนวล", -cornflowerblue: "สีคอร์นฟลาวเวอร์บลู", -cornsilk: "cornsilk", -crimson: "แดงเลือดหมู", -cyan: "เขียวแกมน้ำเงิน", -darkblue: "น้ำเงินเข้ม", -darkcyan: "เขียวแกมน้ำเงินเข้ม", -darkgoldenrod: "ทองเหลืองเข้ม", -darkgray: "เทาเข้ม", -darkgreen: "เขียวเข้ม", -darkgrey: "เทาเข้ม", // same as darkgray -darkkhaki: "กากีเข้ม", -darkmagenta: "แดงแกมม่วงเข้ม", -darkolivegreen: "เขียวโอลีฟเข้ม", -darkorange: "ส้มเข้ม", -darkorchid: "สีม่วงกล้วยไม้เข้ม", -darkred: "แดงเข้ม", -darksalmon: "ส้มเข้ม", -darkseagreen: "เขียวทะเลเข้ม", -darkslateblue: "น้ำเงินนวลเข้ม", -darkslategray: "เทานวลเข้ม", -darkslategrey: "เทานวลเข้ม", // same as darkslategray -darkturquoise: "ฟ้าขี้นกการเวกเข้ม", -darkviolet: "ม่วงเข้ม", -deeppink: "ชมพูเข้ม", -deepskyblue: "ฟ้าสด", -dimgray: "เทาทึม", -dimgrey: "เทาทึม", // same as dimgray -dodgerblue: "ฟ้าสะท้อนแสง", -firebrick: "สีอิฐ", -floralwhite: "ขาวแกมชมพู", -forestgreen: "หยก", -fuchsia: "บานเย็น", -gainsboro: "เทานวล", -ghostwhite: "น้ำข้าว", -gold: "ทอง", -goldenrod: "ทองเหลือง", -gray: "เทา", -green: "เขียว", -greenyellow: "เขียวแกมเหลือง", -grey: "เทา", // same as gray -honeydew: "ขาวแกมเขียว", -hotpink: "ชมพูจัด", -indianred: "แดงอมเหลือง", -indigo: "คราม", -ivory: "งาช้าง", -khaki: "กากี", -lavender: "ม่วงลาเวนเดอร์", -lavenderblush: "นมเย็น", -lawngreen: "เขียวหญ้าอ่อน", -lemonchiffon: "lemon chiffon", -lightblue: "น้ำเงินอ่อน", -lightcoral: "ชมพูอมแดง", -lightcyan: "เขียวแกมน้ำเงินอ่อน", -lightgoldenrodyellow: "ทองเหลืองอ่อน", -lightgray: "เทาอ่อน", -lightgreen: "เขียวอ่อน", -lightgrey: "เทาอ่อน", // same as lightgray -lightpink: "ชมพูอ่อน", -lightsalmon: "ส้มจาง", -lightseagreen: "เขียวทะเลอ่อน", -lightskyblue: "ฟ้าอ่อน", -lightslategray: "เทานวลอ่อน", -lightslategrey: "เทานวลอ่อน", // same as lightslategray -lightsteelblue: "น้ำเงินนวลอ่อน", -lightyellow: "เหลืองอ่อน", -lime: "เหลืองมะนาว", -limegreen: "เขียวมะนาว", -linen: "ลินนิน", -magenta: "แดงแกมม่วง", -maroon: "น้ำตาลแดง", -mediumaquamarine: "อะความารีนกลางๆ", -mediumblue: "น้ำเงินกลางๆ", -mediumorchid: "ม่วงกล้วยไม้กลางๆ", -mediumpurple: "ม่วงอัญชัญ", -mediumseagreen: " เขียวทะเลกลางๆ", -mediumslateblue: "น้ำเงินนวลกลางๆ", -mediumspringgreen: "สีเขียวนวลกลางๆ", -mediumturquoise: "ฟ้าขี้นกการเวกกลางๆ", -mediumvioletred: "แดงอมม่วงกลางๆ", -midnightblue: "น้ำเงินทึบ", -mintcream: "ขาวกะทิ", -mistyrose: "ชมพูหม่น", -moccasin: "ม็อคค่า", -navajowhite: "ส้มหนังกลับ", -navy: "น้ำเงินเข้ม", -oldlace: "ขาวนวล", -olive: "โอลีฟ", -olivedrab: "เขียวมะกอกแก่", -orange: "ส้ม", -orangered: "ส้มแกมแดง", -orchid: "สีกล้วยไม้", -palegoldenrod: "ทองเหลืองจาง", -palegreen: "เขียวจาง", -paleturquoise: "ฟ้าขี้นกการเวกจาง", -palevioletred: "แดงอมม่วงจาง", -papayawhip: "ชมพูจาง", -peachpuff: " สีพีช", -peru: "ส้มดินเผา", -pink: "ชมพู", -plum: "ม่วงอ่อน", -powderblue: "ฟ้าหม่น", -purple: "ม่วง", -red: "แดง", -rosybrown: "กะปิ", -royalblue: "น้ำเงินเข้ม", -saddlebrown: "น้ำตาล", -salmon: "ส้มอ่อน", -sandybrown: "น้ำตาลลูกรัง", -seagreen: "เขียวทะเล", -seashell: "สีขาวหอยทะเล", -sienna: "น้ำตาลอมแดง", -silver: "เงิน", -skyblue: "ฟ้า", -slateblue: "น้ำเงินนวล", -slategray: "เทาอมน้ำเงินนวล", -slategrey: "เทาอมน้ำเงินนวล", // same as slategray -snow: "ขาวหิมะ", -springgreen: "เขียว", -steelblue: "น้ำเงินด้าน", -tan: "แทน", -teal: "เขียวหัวเป็ด", -thistle: "ม่วงจาง", -tomato: "แสด", -transparent: "สีใส", -turquoise: "ฟ้าขี้นกการเวก", -violet: "ม่วง", -wheat: "เหลืองรำข้าว", -white: "ขาว", -whitesmoke: "ขาวควัน", -yellow: "เหลือง", -yellowgreen: "เหลืองแกมเขียว" -}) -); diff --git a/lib/dojo/nls/tr/colors.js b/lib/dojo/nls/tr/colors.js deleted file mode 100644 index b9e0d64..0000000 --- a/lib/dojo/nls/tr/colors.js +++ /dev/null @@ -1,8 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/nls/tr/colors",({aliceblue:"alice mavisi",antiquewhite:"antik beyaz",aqua:"deniz mavisi",aquamarine:"akuamarin",azure:"azur mavisi",beige:"bej",bisque:"bisküvi",black:"siyah",blanchedalmond:"soluk badem",blue:"mavi",blueviolet:"mavi-mor",brown:"kahverengi",burlywood:"sarımsı kahverengi",cadetblue:"denizci mavisi",chartreuse:"chartreuse",chocolate:"çikolata",coral:"mercan",cornflowerblue:"peygamber çiçeği mavisi",cornsilk:"mısır rengi",crimson:"crimson",cyan:"camgöbeği",darkblue:"koyu mavi",darkcyan:"koyu camgöbeği",darkgoldenrod:"koyu sarı",darkgray:"koyu gri",darkgreen:"koyu yeşil",darkgrey:"koyu gri",darkkhaki:"koyu haki",darkmagenta:"koyu mor",darkolivegreen:"koyu zeytin yeşili",darkorange:"koyu turuncu",darkorchid:"koyu orkide",darkred:"koyu kırmızı",darksalmon:"koyu somon",darkseagreen:"koyu deniz yeşili",darkslateblue:"koyu arduvaz mavisi",darkslategray:"koyu arduvaz grisi",darkslategrey:"koyu arduvaz grisi",darkturquoise:"koyu turkuaz",darkviolet:"koyu eflatun",deeppink:"koyu pembe",deepskyblue:"koyu gök mavisi",dimgray:"soluk gri",dimgrey:"soluk gri",dodgerblue:"toz mavisi",firebrick:"canlı kiremit",floralwhite:"çiçek beyazı",forestgreen:"koyu deniz yeşili",fuchsia:"fuşya",gainsboro:"gainsboro",ghostwhite:"silik beyaz",gold:"altın",goldenrod:"sarısabır",gray:"gri",green:"yeşil",greenyellow:"yeşil-sarı",grey:"gri",honeydew:"çam sakızı",hotpink:"sıcak pembe",indianred:"kızılderili kırmızısı",indigo:"çivit mavisi",ivory:"fildişi",khaki:"haki",lavender:"lavanta",lavenderblush:"lavanta pembesi",lawngreen:"çimen yeşili",lemonchiffon:"limoni",lightblue:"açık mavi",lightcoral:"açık mercan",lightcyan:"açık camgöbeği",lightgoldenrodyellow:"açık sarısabır",lightgray:"açık gri",lightgreen:"açık yeşil",lightgrey:"açık gri",lightpink:"açık pembe",lightsalmon:"açık somon",lightseagreen:"açık deniz yeşili",lightskyblue:"açık gök mavisi",lightslategray:"açık arduvaz grisi",lightslategrey:"açık arduvaz grisi",lightsteelblue:"açık metalik mavi",lightyellow:"açık sarı",lime:"limon yeşili",limegreen:"küf yeşili",linen:"keten",magenta:"macenta",maroon:"kestane",mediumaquamarine:"orta akuamarin",mediumblue:"orta mavi",mediumorchid:"orta orkide",mediumpurple:"orta mor",mediumseagreen:"orta deniz yeşili",mediumslateblue:"orta arduvaz mavisi",mediumspringgreen:"orta bahar yeşili",mediumturquoise:"orta turkuaz",mediumvioletred:"orta menekşe kırmızısı",midnightblue:"gece mavisi",mintcream:"naneli krem",mistyrose:"gülkurusu",moccasin:"mokosen",navajowhite:"navajo beyazı",navy:"lacivert",oldlace:"eski dantel",olive:"zeytin",olivedrab:"asker yeşili",orange:"turuncu",orangered:"turuncu kırmızı",orchid:"orkide",palegoldenrod:"soluk sarısabır",palegreen:"soluk yeşil",paleturquoise:"soluk turkuaz",palevioletred:"soluk menekşe kırmızısı",papayawhip:"papaya sapı",peachpuff:"açık şeftali",peru:"peru",pink:"pembe",plum:"erik",powderblue:"pudra mavisi",purple:"mor",red:"kırmızı",rosybrown:"pembemsi kahverengi",royalblue:"parlak koyu mavi",saddlebrown:"açık kahve",salmon:"somon",sandybrown:"kum rengi",seagreen:"deniz yeşili",seashell:"deniz kabuğu",sienna:"koyu kahve",silver:"gümüş",skyblue:"gök mavisi",slateblue:"arduvaz mavisi",slategray:"arduvaz grisi",slategrey:"arduvaz grisi",snow:"kar",springgreen:"bahar yeşili",steelblue:"metalik mavi",tan:"güneş yanığı",teal:"Teal mavi",thistle:"devedikeni",tomato:"domates",transparent:"saydam",turquoise:"turkuaz",violet:"eflatun",wheat:"buğday",white:"beyaz",whitesmoke:"beyaz duman",yellow:"sarı",yellowgreen:"sarı yeşil"})); diff --git a/lib/dojo/nls/tr/colors.js.uncompressed.js b/lib/dojo/nls/tr/colors.js.uncompressed.js deleted file mode 100644 index 8b9020f..0000000 --- a/lib/dojo/nls/tr/colors.js.uncompressed.js +++ /dev/null @@ -1,156 +0,0 @@ -define( -"dojo/nls/tr/colors", ({ -// local representation of all CSS3 named colors, companion to dojo.colors. To be used where descriptive information -// is required for each color, such as a palette widget, and not for specifying color programatically. - //Note: due to the SVG 1.0 spec additions, some of these are alternate spellings for the same color (e.g. gray / grey). - //TODO: should we be using unique rgb values as keys instead and avoid these duplicates, or rely on the caller to do the reverse mapping? - aliceblue: "alice mavisi", - antiquewhite: "antik beyaz", - aqua: "deniz mavisi", - aquamarine: "akuamarin", - azure: "azur mavisi", - beige: "bej", - bisque: "bisküvi", - black: "siyah", - blanchedalmond: "soluk badem", - blue: "mavi", - blueviolet: "mavi-mor", - brown: "kahverengi", - burlywood: "sarımsı kahverengi", - cadetblue: "denizci mavisi", - chartreuse: "chartreuse", - chocolate: "çikolata", - coral: "mercan", - cornflowerblue: "peygamber çiçeği mavisi", - cornsilk: "mısır rengi", - crimson: "crimson", - cyan: "camgöbeği", - darkblue: "koyu mavi", - darkcyan: "koyu camgöbeği", - darkgoldenrod: "koyu sarı", - darkgray: "koyu gri", - darkgreen: "koyu yeşil", - darkgrey: "koyu gri", // same as darkgray - darkkhaki: "koyu haki", - darkmagenta: "koyu mor", - darkolivegreen: "koyu zeytin yeşili", - darkorange: "koyu turuncu", - darkorchid: "koyu orkide", - darkred: "koyu kırmızı", - darksalmon: "koyu somon", - darkseagreen: "koyu deniz yeşili", - darkslateblue: "koyu arduvaz mavisi", - darkslategray: "koyu arduvaz grisi", - darkslategrey: "koyu arduvaz grisi", // same as darkslategray - darkturquoise: "koyu turkuaz", - darkviolet: "koyu eflatun", - deeppink: "koyu pembe", - deepskyblue: "koyu gök mavisi", - dimgray: "soluk gri", - dimgrey: "soluk gri", // same as dimgray - dodgerblue: "toz mavisi", - firebrick: "canlı kiremit", - floralwhite: "çiçek beyazı", - forestgreen: "koyu deniz yeşili", - fuchsia: "fuşya", - gainsboro: "gainsboro", - ghostwhite: "silik beyaz", - gold: "altın", - goldenrod: "sarısabır", - gray: "gri", - green: "yeşil", - greenyellow: "yeşil-sarı", - grey: "gri", // same as gray - honeydew: "çam sakızı", - hotpink: "sıcak pembe", - indianred: "kızılderili kırmızısı", - indigo: "çivit mavisi", - ivory: "fildişi", - khaki: "haki", - lavender: "lavanta", - lavenderblush: "lavanta pembesi", - lawngreen: "çimen yeşili", - lemonchiffon: "limoni", - lightblue: "açık mavi", - lightcoral: "açık mercan", - lightcyan: "açık camgöbeği", - lightgoldenrodyellow: "açık sarısabır", - lightgray: "açık gri", - lightgreen: "açık yeşil", - lightgrey: "açık gri", // same as lightgray - lightpink: "açık pembe", - lightsalmon: "açık somon", - lightseagreen: "açık deniz yeşili", - lightskyblue: "açık gök mavisi", - lightslategray: "açık arduvaz grisi", - lightslategrey: "açık arduvaz grisi", // same as lightslategray - lightsteelblue: "açık metalik mavi", - lightyellow: "açık sarı", - lime: "limon yeşili", - limegreen: "küf yeşili", - linen: "keten", - magenta: "macenta", - maroon: "kestane", - mediumaquamarine: "orta akuamarin", - mediumblue: "orta mavi", - mediumorchid: "orta orkide", - mediumpurple: "orta mor", - mediumseagreen: "orta deniz yeşili", - mediumslateblue: "orta arduvaz mavisi", - mediumspringgreen: "orta bahar yeşili", - mediumturquoise: "orta turkuaz", - mediumvioletred: "orta menekşe kırmızısı", - midnightblue: "gece mavisi", - mintcream: "naneli krem", - mistyrose: "gülkurusu", - moccasin: "mokosen", - navajowhite: "navajo beyazı", - navy: "lacivert", - oldlace: "eski dantel", - olive: "zeytin", - olivedrab: "asker yeşili", - orange: "turuncu", - orangered: "turuncu kırmızı", - orchid: "orkide", - palegoldenrod: "soluk sarısabır", - palegreen: "soluk yeşil", - paleturquoise: "soluk turkuaz", - palevioletred: "soluk menekşe kırmızısı", - papayawhip: "papaya sapı", - peachpuff: "açık şeftali", - peru: "peru", - pink: "pembe", - plum: "erik", - powderblue: "pudra mavisi", - purple: "mor", - red: "kırmızı", - rosybrown: "pembemsi kahverengi", - royalblue: "parlak koyu mavi", - saddlebrown: "açık kahve", - salmon: "somon", - sandybrown: "kum rengi", - seagreen: "deniz yeşili", - seashell: "deniz kabuğu", - sienna: "koyu kahve", - silver: "gümüş", - skyblue: "gök mavisi", - slateblue: "arduvaz mavisi", - slategray: "arduvaz grisi", - slategrey: "arduvaz grisi", // same as slategray - snow: "kar", - springgreen: "bahar yeşili", - steelblue: "metalik mavi", - tan: "güneş yanığı", - teal: "Teal mavi", - thistle: "devedikeni", - tomato: "domates", - transparent: "saydam", - turquoise: "turkuaz", - violet: "eflatun", - wheat: "buğday", - white: "beyaz", - whitesmoke: "beyaz duman", - yellow: "sarı", - yellowgreen: "sarı yeşil" -}) -); diff --git a/lib/dojo/nls/uk/colors.js b/lib/dojo/nls/uk/colors.js deleted file mode 100644 index c852d22..0000000 --- a/lib/dojo/nls/uk/colors.js +++ /dev/null @@ -1,8 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/nls/uk/colors",({aliceblue:"сіро-блакитний",antiquewhite:"білий антик",aqua:"зеленувато-блакитний",aquamarine:"аквамарин",azure:"лазурний",beige:"бежевий",bisque:"кремовий",black:"чорний",blanchedalmond:"світло-мигдалевий",blue:"блакитний",blueviolet:"блакитно-фіолетовий",brown:"брунатний",burlywood:"світло-брунатний",cadetblue:"сіро-синій",chartreuse:"жовто-салатовий",chocolate:"шоколадний",coral:"коралевий",cornflowerblue:"фіолетово-синій",cornsilk:"шовковий відтінок",crimson:"малиновий",cyan:"синій",darkblue:"темно-блакитний",darkcyan:"темно-синій",darkgoldenrod:"темно-золотавий",darkgray:"темно-сірий",darkgreen:"темно-зелений",darkgrey:"темно-сірий",darkkhaki:"темний хакі",darkmagenta:"темно-пурпуровий",darkolivegreen:"темно-оливковий",darkorange:"темно-жовтогарячий",darkorchid:"темний орсель",darkred:"темно-червоний",darksalmon:"темно-лососевий",darkseagreen:"темний колір морської хвилі",darkslateblue:"темний грифельно-синій",darkslategray:"темний грифельно-сірий",darkslategrey:"темний грифельно-сірий",darkturquoise:"темно-бірюзовий",darkviolet:"темно-фіолетовий",deeppink:"темно-рожевий",deepskyblue:"насичений світло-блакитний",dimgray:"тьмяно-сірий",dimgrey:"тьмяно-сірий",dodgerblue:"блідо-блакитний",firebrick:"цеглястий",floralwhite:"квітково-білий",forestgreen:"зелений лісний",fuchsia:"фуксин",gainsboro:"блідо-сірий",ghostwhite:"молочно-білий",gold:"золотий",goldenrod:"золотавий",gray:"сірий",green:"зелений",greenyellow:"зелено-жовтий",grey:"сірий",honeydew:"медовий",hotpink:"червоно-рожевий",indianred:"індійський червоний",indigo:"індиго",ivory:"слонової кістки",khaki:"хакі",lavender:"лавандовий",lavenderblush:"рожево-лавандовий",lawngreen:"трав'янистий",lemonchiffon:"блідо-лимонний",lightblue:"світло-блакитний",lightcoral:"світло-коралевий",lightcyan:"світло-синій",lightgoldenrodyellow:"світло-золотаво-жовтий",lightgray:"світло-сірий",lightgreen:"світло-зелений",lightgrey:"світло-сірий",lightpink:"світло-рожевий",lightsalmon:"світло-лососевий",lightseagreen:"світлий морської хвилі",lightskyblue:"світлий небесно-блакитний",lightslategray:"світлий грифельно-сірий",lightslategrey:"світлий грифельно-сірий",lightsteelblue:"світлий сталевий",lightyellow:"світло-жовтий",lime:"лайм",limegreen:"зелений лайм",linen:"лляний",magenta:"пурпурний",maroon:"темно-брунатний",mediumaquamarine:"нейтральний аквамарин",mediumblue:"нейтральний блакитний",mediumorchid:"нейтральний орсель",mediumpurple:"нейтральний фіолетовий",mediumseagreen:"нейтральний морської хвилі",mediumslateblue:"нейтральний грифельно-синій",mediumspringgreen:"нейтральний весняний зелений",mediumturquoise:"нейтральний бірюзовий",mediumvioletred:"нейтральний фіолетово-червоний",midnightblue:"північно-синій",mintcream:"м'ятно-кремовий",mistyrose:"тьмяно-рожевий",moccasin:"болотний",navajowhite:"білий навахо",navy:"темно-синій",oldlace:"матово-білий",olive:"оливковий",olivedrab:"оливково-сірий",orange:"жовтогарячий",orangered:"жовтогаряче-червоний",orchid:"світло-бузковий",palegoldenrod:"блідо-золотавий",palegreen:"блідо-зелений",paleturquoise:"блідо-бірюзовий",palevioletred:"блідо-фіолетово-червоний",papayawhip:"динне дерево",peachpuff:"персиковий",peru:"перу",pink:"рожевий",plum:"сливовий",powderblue:"зеленувато-блакитний",purple:"фіолетовий",red:"червоний",rosybrown:"рожево-брунатний",royalblue:"королевський блакитний",saddlebrown:"шкіряно-брунатний",salmon:"лососевий",sandybrown:"брунатно-пісочний",seagreen:"морської хвилі",seashell:"морська скойка",sienna:"охра",silver:"сріблястий",skyblue:"небесно-блакитний",slateblue:"грифельно-синій",slategray:"грифельно-сірий",slategrey:"грифельно-сірий",snow:"білосніжний",springgreen:"весняний зелений",steelblue:"сталевий",tan:"бронзовий",teal:"темно-бірюзовий",thistle:"будяк",tomato:"томатний",transparent:"прозорий",turquoise:"бірюзовий",violet:"фіолетовий",wheat:"пшениця",white:"білий",whitesmoke:"попелясто-білий",yellow:"жовтий",yellowgreen:"жовто-зелений"})); diff --git a/lib/dojo/nls/uk/colors.js.uncompressed.js b/lib/dojo/nls/uk/colors.js.uncompressed.js deleted file mode 100644 index b0bcf8a..0000000 --- a/lib/dojo/nls/uk/colors.js.uncompressed.js +++ /dev/null @@ -1,156 +0,0 @@ -define( -"dojo/nls/uk/colors", ({ -// local representation of all CSS3 named colors, companion to dojo.colors. To be used where descriptive information -// is required for each color, such as a palette widget, and not for specifying color programatically. - //Note: due to the SVG 1.0 spec additions, some of these are alternate spellings for the same color (e.g. gray / grey). - //TODO: should we be using unique rgb values as keys instead and avoid these duplicates, or rely on the caller to do the reverse mapping? - aliceblue: "сіро-блакитний", - antiquewhite: "білий антик", - aqua: "зеленувато-блакитний", - aquamarine: "аквамарин", - azure: "лазурний", - beige: "бежевий", - bisque: "кремовий", - black: "чорний", - blanchedalmond: "світло-мигдалевий", - blue: "блакитний", - blueviolet: "блакитно-фіолетовий", - brown: "брунатний", - burlywood: "світло-брунатний", - cadetblue: "сіро-синій", - chartreuse: "жовто-салатовий", - chocolate: "шоколадний", - coral: "коралевий", - cornflowerblue: "фіолетово-синій", - cornsilk: "шовковий відтінок", - crimson: "малиновий", - cyan: "синій", - darkblue: "темно-блакитний", - darkcyan: "темно-синій", - darkgoldenrod: "темно-золотавий", - darkgray: "темно-сірий", - darkgreen: "темно-зелений", - darkgrey: "темно-сірий", // same as darkgray - darkkhaki: "темний хакі", - darkmagenta: "темно-пурпуровий", - darkolivegreen: "темно-оливковий", - darkorange: "темно-жовтогарячий", - darkorchid: "темний орсель", - darkred: "темно-червоний", - darksalmon: "темно-лососевий", - darkseagreen: "темний колір морської хвилі", - darkslateblue: "темний грифельно-синій", - darkslategray: "темний грифельно-сірий", - darkslategrey: "темний грифельно-сірий", // same as darkslategray - darkturquoise: "темно-бірюзовий", - darkviolet: "темно-фіолетовий", - deeppink: "темно-рожевий", - deepskyblue: "насичений світло-блакитний", - dimgray: "тьмяно-сірий", - dimgrey: "тьмяно-сірий", // same as dimgray - dodgerblue: "блідо-блакитний", - firebrick: "цеглястий", - floralwhite: "квітково-білий", - forestgreen: "зелений лісний", - fuchsia: "фуксин", - gainsboro: "блідо-сірий", - ghostwhite: "молочно-білий", - gold: "золотий", - goldenrod: "золотавий", - gray: "сірий", - green: "зелений", - greenyellow: "зелено-жовтий", - grey: "сірий", // same as gray - honeydew: "медовий", - hotpink: "червоно-рожевий", - indianred: "індійський червоний", - indigo: "індиго", - ivory: "слонової кістки", - khaki: "хакі", - lavender: "лавандовий", - lavenderblush: "рожево-лавандовий", - lawngreen: "трав'янистий", - lemonchiffon: "блідо-лимонний", - lightblue: "світло-блакитний", - lightcoral: "світло-коралевий", - lightcyan: "світло-синій", - lightgoldenrodyellow: "світло-золотаво-жовтий", - lightgray: "світло-сірий", - lightgreen: "світло-зелений", - lightgrey: "світло-сірий", // same as lightgray - lightpink: "світло-рожевий", - lightsalmon: "світло-лососевий", - lightseagreen: "світлий морської хвилі", - lightskyblue: "світлий небесно-блакитний", - lightslategray: "світлий грифельно-сірий", - lightslategrey: "світлий грифельно-сірий", // same as lightslategray - lightsteelblue: "світлий сталевий", - lightyellow: "світло-жовтий", - lime: "лайм", - limegreen: "зелений лайм", - linen: "лляний", - magenta: "пурпурний", - maroon: "темно-брунатний", - mediumaquamarine: "нейтральний аквамарин", - mediumblue: "нейтральний блакитний", - mediumorchid: "нейтральний орсель", - mediumpurple: "нейтральний фіолетовий", - mediumseagreen: "нейтральний морської хвилі", - mediumslateblue: "нейтральний грифельно-синій", - mediumspringgreen: "нейтральний весняний зелений", - mediumturquoise: "нейтральний бірюзовий", - mediumvioletred: "нейтральний фіолетово-червоний", - midnightblue: "північно-синій", - mintcream: "м'ятно-кремовий", - mistyrose: "тьмяно-рожевий", - moccasin: "болотний", - navajowhite: "білий навахо", - navy: "темно-синій", - oldlace: "матово-білий", - olive: "оливковий", - olivedrab: "оливково-сірий", - orange: "жовтогарячий", - orangered: "жовтогаряче-червоний", - orchid: "світло-бузковий", - palegoldenrod: "блідо-золотавий", - palegreen: "блідо-зелений", - paleturquoise: "блідо-бірюзовий", - palevioletred: "блідо-фіолетово-червоний", - papayawhip: "динне дерево", - peachpuff: "персиковий", - peru: "перу", - pink: "рожевий", - plum: "сливовий", - powderblue: "зеленувато-блакитний", - purple: "фіолетовий", - red: "червоний", - rosybrown: "рожево-брунатний", - royalblue: "королевський блакитний", - saddlebrown: "шкіряно-брунатний", - salmon: "лососевий", - sandybrown: "брунатно-пісочний", - seagreen: "морської хвилі", - seashell: "морська скойка", - sienna: "охра", - silver: "сріблястий", - skyblue: "небесно-блакитний", - slateblue: "грифельно-синій", - slategray: "грифельно-сірий", - slategrey: "грифельно-сірий", // same as slategray - snow: "білосніжний", - springgreen: "весняний зелений", - steelblue: "сталевий", - tan: "бронзовий", - teal: "темно-бірюзовий", - thistle: "будяк", - tomato: "томатний", - transparent: "прозорий", - turquoise: "бірюзовий", - violet: "фіолетовий", - wheat: "пшениця", - white: "білий", - whitesmoke: "попелясто-білий", - yellow: "жовтий", - yellowgreen: "жовто-зелений" -}) -); diff --git a/lib/dojo/nls/zh-tw/colors.js b/lib/dojo/nls/zh-tw/colors.js deleted file mode 100644 index c9bd12a..0000000 --- a/lib/dojo/nls/zh-tw/colors.js +++ /dev/null @@ -1,8 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/nls/zh-tw/colors",({aliceblue:"愛麗絲藍",antiquewhite:"米白色",aqua:"水色",aquamarine:"碧綠色",azure:"天藍色",beige:"灰棕色",bisque:"橘黃色",black:"黑色",blanchedalmond:"杏仁白",blue:"藍色",blueviolet:"藍紫色",brown:"褐色",burlywood:"實木色",cadetblue:"軍服藍",chartreuse:"淡黃綠色",chocolate:"巧克力色",coral:"珊瑚紅",cornflowerblue:"矢車菊藍",cornsilk:"玉米黃",crimson:"暗深紅色",cyan:"青色",darkblue:"暗藍色",darkcyan:"暗青色",darkgoldenrod:"暗金菊色",darkgray:"暗灰色",darkgreen:"暗綠色",darkgrey:"暗灰色",darkkhaki:"暗卡其色",darkmagenta:"暗紫紅色",darkolivegreen:"暗橄欖綠",darkorange:"暗橙色",darkorchid:"暗蘭花色",darkred:"暗紅色",darksalmon:"暗鮭紅",darkseagreen:"暗海綠色",darkslateblue:"暗岩藍色",darkslategray:"暗岩灰色",darkslategrey:"暗岩灰色",darkturquoise:"暗松石綠",darkviolet:"暗紫羅蘭色",deeppink:"深粉紅色",deepskyblue:"深天藍色",dimgray:"昏灰色",dimgrey:"昏灰色",dodgerblue:"道奇藍",firebrick:"紅磚色",floralwhite:"花卉白",forestgreen:"森綠色",fuchsia:"海棠紅",gainsboro:"石板灰",ghostwhite:"幽靈色",gold:"金色",goldenrod:"金菊色",gray:"灰色",green:"綠色",greenyellow:"綠黃色",grey:"灰色",honeydew:"密瓜色",hotpink:"暖粉紅色",indianred:"印度紅",indigo:"靛藍色",ivory:"象牙色",khaki:"卡其色",lavender:"薰衣草紫",lavenderblush:"薰衣草紫紅",lawngreen:"草綠色",lemonchiffon:"奶油黃",lightblue:"淡藍色",lightcoral:"淡珊瑚紅",lightcyan:"淡青色",lightgoldenrodyellow:"淡金菊黃",lightgray:"淡灰色",lightgreen:"淡綠色",lightgrey:"淡灰色",lightpink:"淡粉紅色",lightsalmon:"淡鮭紅",lightseagreen:"淡海綠色",lightskyblue:"淡天藍色",lightslategray:"淡岩灰色",lightslategrey:"淡岩灰色",lightsteelblue:"淡鐵藍色",lightyellow:"淡黃色",lime:"檸檬色",limegreen:"檸檬綠",linen:"亞麻色",magenta:"紫紅色",maroon:"栗色",mediumaquamarine:"中碧綠色",mediumblue:"中藍色",mediumorchid:"中蘭紫色",mediumpurple:"中紫色",mediumseagreen:"中海綠色",mediumslateblue:"中岩藍色",mediumspringgreen:"中春綠色",mediumturquoise:"中松石綠",mediumvioletred:"中紫羅蘭紅",midnightblue:"午夜藍",mintcream:"薄荷乳白色",mistyrose:"霧玫瑰色",moccasin:"鹿皮黃色",navajowhite:"印地安黃色",navy:"海軍藍",oldlace:"舊蕾絲色",olive:"橄欖色",olivedrab:"橄欖綠",orange:"橙色",orangered:"橙紅色",orchid:"蘭花色",palegoldenrod:"灰金菊色",palegreen:"灰綠色",paleturquoise:"灰松石綠",palevioletred:"灰紫羅蘭紅",papayawhip:"番木瓜色",peachpuff:"粉撲桃色",peru:"祕魯色",pink:"粉紅色",plum:"李紫色",powderblue:"粉藍色",purple:"紫色",red:"紅色",rosybrown:"玫瑰褐",royalblue:"品藍色",saddlebrown:"鞍褐色",salmon:"鮭紅色",sandybrown:"沙褐色",seagreen:"海綠色",seashell:"海貝色",sienna:"黃土赭色",silver:"銀色",skyblue:"天藍色",slateblue:"岩藍色",slategray:"岩灰色",slategrey:"岩灰色",snow:"雪白色",springgreen:"春綠色",steelblue:"鐵藍色",tan:"皮革色",teal:"深藍綠色",thistle:"薊色",tomato:"蕃茄紅",transparent:"透明",turquoise:"松石綠",violet:"紫羅蘭色",wheat:"小麥色",white:"白色",whitesmoke:"白煙色",yellow:"黃色",yellowgreen:"黃綠色"})); diff --git a/lib/dojo/nls/zh-tw/colors.js.uncompressed.js b/lib/dojo/nls/zh-tw/colors.js.uncompressed.js deleted file mode 100644 index 5d8ce27..0000000 --- a/lib/dojo/nls/zh-tw/colors.js.uncompressed.js +++ /dev/null @@ -1,156 +0,0 @@ -define( -"dojo/nls/zh-tw/colors", ({ -// local representation of all CSS3 named colors, companion to dojo.colors. To be used where descriptive information -// is required for each color, such as a palette widget, and not for specifying color programatically. - //Note: due to the SVG 1.0 spec additions, some of these are alternate spellings for the same color (e.g. gray / grey). - //TODO: should we be using unique rgb values as keys instead and avoid these duplicates, or rely on the caller to do the reverse mapping? - aliceblue: "愛麗絲藍", - antiquewhite: "米白色", - aqua: "水色", - aquamarine: "碧綠色", - azure: "天藍色", - beige: "灰棕色", - bisque: "橘黃色", - black: "黑色", - blanchedalmond: "杏仁白", - blue: "藍色", - blueviolet: "藍紫色", - brown: "褐色", - burlywood: "實木色", - cadetblue: "軍服藍", - chartreuse: "淡黃綠色", - chocolate: "巧克力色", - coral: "珊瑚紅", - cornflowerblue: "矢車菊藍", - cornsilk: "玉米黃", - crimson: "暗深紅色", - cyan: "青色", - darkblue: "暗藍色", - darkcyan: "暗青色", - darkgoldenrod: "暗金菊色", - darkgray: "暗灰色", - darkgreen: "暗綠色", - darkgrey: "暗灰色", // same as darkgray - darkkhaki: "暗卡其色", - darkmagenta: "暗紫紅色", - darkolivegreen: "暗橄欖綠", - darkorange: "暗橙色", - darkorchid: "暗蘭花色", - darkred: "暗紅色", - darksalmon: "暗鮭紅", - darkseagreen: "暗海綠色", - darkslateblue: "暗岩藍色", - darkslategray: "暗岩灰色", - darkslategrey: "暗岩灰色", // same as darkslategray - darkturquoise: "暗松石綠", - darkviolet: "暗紫羅蘭色", - deeppink: "深粉紅色", - deepskyblue: "深天藍色", - dimgray: "昏灰色", - dimgrey: "昏灰色", // same as dimgray - dodgerblue: "道奇藍", - firebrick: "紅磚色", - floralwhite: "花卉白", - forestgreen: "森綠色", - fuchsia: "海棠紅", - gainsboro: "石板灰", - ghostwhite: "幽靈色", - gold: "金色", - goldenrod: "金菊色", - gray: "灰色", - green: "綠色", - greenyellow: "綠黃色", - grey: "灰色", // same as gray - honeydew: "密瓜色", - hotpink: "暖粉紅色", - indianred: "印度紅", - indigo: "靛藍色", - ivory: "象牙色", - khaki: "卡其色", - lavender: "薰衣草紫", - lavenderblush: "薰衣草紫紅", - lawngreen: "草綠色", - lemonchiffon: "奶油黃", - lightblue: "淡藍色", - lightcoral: "淡珊瑚紅", - lightcyan: "淡青色", - lightgoldenrodyellow: "淡金菊黃", - lightgray: "淡灰色", - lightgreen: "淡綠色", - lightgrey: "淡灰色", // same as lightgray - lightpink: "淡粉紅色", - lightsalmon: "淡鮭紅", - lightseagreen: "淡海綠色", - lightskyblue: "淡天藍色", - lightslategray: "淡岩灰色", - lightslategrey: "淡岩灰色", // same as lightslategray - lightsteelblue: "淡鐵藍色", - lightyellow: "淡黃色", - lime: "檸檬色", - limegreen: "檸檬綠", - linen: "亞麻色", - magenta: "紫紅色", - maroon: "栗色", - mediumaquamarine: "中碧綠色", - mediumblue: "中藍色", - mediumorchid: "中蘭紫色", - mediumpurple: "中紫色", - mediumseagreen: "中海綠色", - mediumslateblue: "中岩藍色", - mediumspringgreen: "中春綠色", - mediumturquoise: "中松石綠", - mediumvioletred: "中紫羅蘭紅", - midnightblue: "午夜藍", - mintcream: "薄荷乳白色", - mistyrose: "霧玫瑰色", - moccasin: "鹿皮黃色", - navajowhite: "印地安黃色", - navy: "海軍藍", - oldlace: "舊蕾絲色", - olive: "橄欖色", - olivedrab: "橄欖綠", - orange: "橙色", - orangered: "橙紅色", - orchid: "蘭花色", - palegoldenrod: "灰金菊色", - palegreen: "灰綠色", - paleturquoise: "灰松石綠", - palevioletred: "灰紫羅蘭紅", - papayawhip: "番木瓜色", - peachpuff: "粉撲桃色", - peru: "祕魯色", - pink: "粉紅色", - plum: "李紫色", - powderblue: "粉藍色", - purple: "紫色", - red: "紅色", - rosybrown: "玫瑰褐", - royalblue: "品藍色", - saddlebrown: "鞍褐色", - salmon: "鮭紅色", - sandybrown: "沙褐色", - seagreen: "海綠色", - seashell: "海貝色", - sienna: "黃土赭色", - silver: "銀色", - skyblue: "天藍色", - slateblue: "岩藍色", - slategray: "岩灰色", - slategrey: "岩灰色", // same as slategray - snow: "雪白色", - springgreen: "春綠色", - steelblue: "鐵藍色", - tan: "皮革色", - teal: "深藍綠色", - thistle: "薊色", - tomato: "蕃茄紅", - transparent: "透明", - turquoise: "松石綠", - violet: "紫羅蘭色", - wheat: "小麥色", - white: "白色", - whitesmoke: "白煙色", - yellow: "黃色", - yellowgreen: "黃綠色" -}) -); diff --git a/lib/dojo/nls/zh/colors.js b/lib/dojo/nls/zh/colors.js deleted file mode 100644 index 8345e5d..0000000 --- a/lib/dojo/nls/zh/colors.js +++ /dev/null @@ -1,8 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/nls/zh/colors",({aliceblue:"爱丽丝蓝",antiquewhite:"古董白",aqua:"浅绿色",aquamarine:"碧绿色",azure:"天蓝色",beige:"米色",bisque:"桔黄色",black:"黑色",blanchedalmond:"白杏色",blue:"蓝色",blueviolet:"蓝紫色",brown:"棕色",burlywood:"实木色",cadetblue:"灰蓝色",chartreuse:"黄绿色",chocolate:"巧克力色",coral:"珊瑚色",cornflowerblue:"浅蓝色",cornsilk:"米绸色",crimson:"绯红色",cyan:"青蓝色",darkblue:"深蓝",darkcyan:"深青绿",darkgoldenrod:"深金黄",darkgray:"深灰色",darkgreen:"深绿色",darkgrey:"深灰色",darkkhaki:"深卡其色",darkmagenta:"深洋红色",darkolivegreen:"深橄榄绿",darkorange:"深橙色",darkorchid:"深紫色",darkred:"深红色",darksalmon:"深橙红",darkseagreen:"深海藻绿",darkslateblue:"深青蓝",darkslategray:"深青灰",darkslategrey:"深青灰",darkturquoise:"深粉蓝",darkviolet:"深紫色",deeppink:"深粉红色",deepskyblue:"深天蓝色",dimgray:"暗灰色",dimgrey:"暗灰色",dodgerblue:"闪蓝色",firebrick:"砖红",floralwhite:"花白色",forestgreen:"森林绿",fuchsia:"紫红色",gainsboro:"淡灰色",ghostwhite:"苍白",gold:"金黄色",goldenrod:"金麒麟色",gray:"灰色",green:"绿色",greenyellow:"绿黄色",grey:"灰色",honeydew:"蜜汁色",hotpink:"深粉红",indianred:"印度红",indigo:"靛青",ivory:"象牙色",khaki:"卡其色",lavender:"淡紫色",lavenderblush:"淡紫红",lawngreen:"草绿色",lemonchiffon:"柠檬绸色",lightblue:"淡蓝色",lightcoral:"浅珊瑚色",lightcyan:"浅青色",lightgoldenrodyellow:"浅金黄色",lightgray:"浅灰色",lightgreen:"浅绿色",lightgrey:"浅灰色",lightpink:"浅粉红色",lightsalmon:"淡橙色",lightseagreen:"浅海藻绿",lightskyblue:"浅天蓝色",lightslategray:"浅青灰",lightslategrey:"浅青灰",lightsteelblue:"浅钢蓝色",lightyellow:"浅黄色",lime:"淡黄绿色",limegreen:"橙绿色",linen:"亚麻色",magenta:"洋红色",maroon:"栗色",mediumaquamarine:"间绿色",mediumblue:"间蓝色",mediumorchid:"间紫色",mediumpurple:"间紫色",mediumseagreen:"间海蓝色",mediumslateblue:"间暗蓝色",mediumspringgreen:"间春绿色",mediumturquoise:"间绿宝石色",mediumvioletred:"间紫罗兰色",midnightblue:"深蓝色",mintcream:"薄荷色",mistyrose:"浅玫瑰色",moccasin:"鹿皮色",navajowhite:"纳瓦白",navy:"藏青色",oldlace:"老白色",olive:"橄榄绿",olivedrab:"草绿色",orange:"橙色",orangered:"橙红色",orchid:"紫色",palegoldenrod:"淡金黄色",palegreen:"淡绿色",paleturquoise:"苍绿色",palevioletred:"苍紫罗兰色",papayawhip:"木瓜色",peachpuff:"桃色",peru:"秘鲁色",pink:"粉红色",plum:"杨李色",powderblue:"铁蓝",purple:"紫色",red:"红色",rosybrown:"褐玫瑰红",royalblue:"品蓝",saddlebrown:"重褐色",salmon:"橙红",sandybrown:"沙褐色",seagreen:"海绿色",seashell:"海贝色",sienna:"赭色",silver:"银白色",skyblue:"天蓝色",slateblue:"石蓝色",slategray:"灰石色",slategrey:"灰石色",snow:"雪白色",springgreen:"春绿色",steelblue:"钢蓝色",tan:"棕褐色",teal:"水鸭色",thistle:"蓟色",tomato:"西红柿色",transparent:"透明的",turquoise:"绿宝石色",violet:"紫色",wheat:"浅黄色",white:"白色",whitesmoke:"烟白色",yellow:"黄色",yellowgreen:"黄绿色"})); diff --git a/lib/dojo/nls/zh/colors.js.uncompressed.js b/lib/dojo/nls/zh/colors.js.uncompressed.js deleted file mode 100644 index 4449d41..0000000 --- a/lib/dojo/nls/zh/colors.js.uncompressed.js +++ /dev/null @@ -1,156 +0,0 @@ -define( -"dojo/nls/zh/colors", ({ -// local representation of all CSS3 named colors, companion to dojo.colors. To be used where descriptive information -// is required for each color, such as a palette widget, and not for specifying color programatically. - //Note: due to the SVG 1.0 spec additions, some of these are alternate spellings for the same color (e.g. gray / grey). - //TODO: should we be using unique rgb values as keys instead and avoid these duplicates, or rely on the caller to do the reverse mapping? - aliceblue: "爱丽丝蓝", - antiquewhite: "古董白", - aqua: "浅绿色", - aquamarine: "碧绿色", - azure: "天蓝色", - beige: "米色", - bisque: "桔黄色", - black: "黑色", - blanchedalmond: "白杏色", - blue: "蓝色", - blueviolet: "蓝紫色", - brown: "棕色", - burlywood: "实木色", - cadetblue: "灰蓝色", - chartreuse: "黄绿色", - chocolate: "巧克力色", - coral: "珊瑚色", - cornflowerblue: "浅蓝色", - cornsilk: "米绸色", - crimson: "绯红色", - cyan: "青蓝色", - darkblue: "深蓝", - darkcyan: "深青绿", - darkgoldenrod: "深金黄", - darkgray: "深灰色", - darkgreen: "深绿色", - darkgrey: "深灰色", // same as darkgray - darkkhaki: "深卡其色", - darkmagenta: "深洋红色", - darkolivegreen: "深橄榄绿", - darkorange: "深橙色", - darkorchid: "深紫色", - darkred: "深红色", - darksalmon: "深橙红", - darkseagreen: "深海藻绿", - darkslateblue: "深青蓝", - darkslategray: "深青灰", - darkslategrey: "深青灰", // same as darkslategray - darkturquoise: "深粉蓝", - darkviolet: "深紫色", - deeppink: "深粉红色", - deepskyblue: "深天蓝色", - dimgray: "暗灰色", - dimgrey: "暗灰色", // same as dimgray - dodgerblue: "闪蓝色", - firebrick: "砖红", - floralwhite: "花白色", - forestgreen: "森林绿", - fuchsia: "紫红色", - gainsboro: "淡灰色", - ghostwhite: "苍白", - gold: "金黄色", - goldenrod: "金麒麟色", - gray: "灰色", - green: "绿色", - greenyellow: "绿黄色", - grey: "灰色", // same as gray - honeydew: "蜜汁色", - hotpink: "深粉红", - indianred: "印度红", - indigo: "靛青", - ivory: "象牙色", - khaki: "卡其色", - lavender: "淡紫色", - lavenderblush: "淡紫红", - lawngreen: "草绿色", - lemonchiffon: "柠檬绸色", - lightblue: "淡蓝色", - lightcoral: "浅珊瑚色", - lightcyan: "浅青色", - lightgoldenrodyellow: "浅金黄色", - lightgray: "浅灰色", - lightgreen: "浅绿色", - lightgrey: "浅灰色", // same as lightgray - lightpink: "浅粉红色", - lightsalmon: "淡橙色", - lightseagreen: "浅海藻绿", - lightskyblue: "浅天蓝色", - lightslategray: "浅青灰", - lightslategrey: "浅青灰", // same as lightslategray - lightsteelblue: "浅钢蓝色", - lightyellow: "浅黄色", - lime: "淡黄绿色", - limegreen: "橙绿色", - linen: "亚麻色", - magenta: "洋红色", - maroon: "栗色", - mediumaquamarine: "间绿色", - mediumblue: "间蓝色", - mediumorchid: "间紫色", - mediumpurple: "间紫色", - mediumseagreen: "间海蓝色", - mediumslateblue: "间暗蓝色", - mediumspringgreen: "间春绿色", - mediumturquoise: "间绿宝石色", - mediumvioletred: "间紫罗兰色", - midnightblue: "深蓝色", - mintcream: "薄荷色", - mistyrose: "浅玫瑰色", - moccasin: "鹿皮色", - navajowhite: "纳瓦白", - navy: "藏青色", - oldlace: "老白色", - olive: "橄榄绿", - olivedrab: "草绿色", - orange: "橙色", - orangered: "橙红色", - orchid: "紫色", - palegoldenrod: "淡金黄色", - palegreen: "淡绿色", - paleturquoise: "苍绿色", - palevioletred: "苍紫罗兰色", - papayawhip: "木瓜色", - peachpuff: "桃色", - peru: "秘鲁色", - pink: "粉红色", - plum: "杨李色", - powderblue: "铁蓝", - purple: "紫色", - red: "红色", - rosybrown: "褐玫瑰红", - royalblue: "品蓝", - saddlebrown: "重褐色", - salmon: "橙红", - sandybrown: "沙褐色", - seagreen: "海绿色", - seashell: "海贝色", - sienna: "赭色", - silver: "银白色", - skyblue: "天蓝色", - slateblue: "石蓝色", - slategray: "灰石色", - slategrey: "灰石色", // same as slategray - snow: "雪白色", - springgreen: "春绿色", - steelblue: "钢蓝色", - tan: "棕褐色", - teal: "水鸭色", - thistle: "蓟色", - tomato: "西红柿色", - transparent: "透明的", - turquoise: "绿宝石色", - violet: "紫色", - wheat: "浅黄色", - white: "白色", - whitesmoke: "烟白色", - yellow: "黄色", - yellowgreen: "黄绿色" -}) -); diff --git a/lib/dojo/node.js b/lib/dojo/node.js deleted file mode 100644 index 12ecf0c..0000000 --- a/lib/dojo/node.js +++ /dev/null @@ -1,41 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/node",["./has"],function(_1){ -if(!0){ -throw new Error("node plugin failed to load because environment is not Node.js"); -} -var _2; -if(require.nodeRequire){ -_2=require.nodeRequire("path"); -}else{ -throw new Error("node plugin failed to load because it cannot find the original Node.js require"); -} -return {load:function(id,_3,_4){ -if(!_3.nodeRequire){ -throw new Error("Cannot find native require function"); -} -_4((function(id,_5){ -var _6=define,_7; -define=undefined; -try{ -_7=_5(id); -} -finally{ -define=_6; -} -return _7; -})(id,_3.nodeRequire)); -},normalize:function(id,_8){ -if(id.charAt(0)==="."){ -var _9=require.toUrl(_8(".")).replace("/",_2.sep),_a=id.split("/"); -_a.unshift(_9); -id=_2.join.apply(_2,_a); -} -return id; -}}; -}); diff --git a/lib/dojo/node.js.uncompressed.js b/lib/dojo/node.js.uncompressed.js deleted file mode 100644 index 74f925e..0000000 --- a/lib/dojo/node.js.uncompressed.js +++ /dev/null @@ -1,67 +0,0 @@ -define("dojo/node", ["./has"], function(has){ - if(! 0 ){ - throw new Error("node plugin failed to load because environment is not Node.js"); - } - - var pathUtil; - if(require.nodeRequire){ - pathUtil = require.nodeRequire("path"); - }else{ - throw new Error("node plugin failed to load because it cannot find the original Node.js require"); - } - - return { - // summary: - // This AMD plugin module allows native Node.js modules to be loaded by AMD modules using the Dojo - // loader. Note that this plugin will not work with AMD loaders other than the Dojo loader. - // example: - // | require(["dojo/node!fs"], function(fs){ - // | var fileData = fs.readFileSync("foo.txt", "utf-8"); - // | }); - - load: function(/*string*/ id, /*Function*/ require, /*Function*/ load){ - // summary: - // Standard AMD plugin interface. See https://github.com/amdjs/amdjs-api/wiki/Loader-Plugins - // for information. - - if(!require.nodeRequire){ - throw new Error("Cannot find native require function"); - } - - load((function(id, require){ - var oldDefine = define, - result; - - // Some modules may attempt to detect an AMD loader via define and define.amd. This can cause issues - // when other CommonJS modules attempt to load them via the standard node require(). If define is - // temporarily moved into another variable, it will prevent modules from detecting AMD in this fashion. - define = undefined; - - try{ - result = require(id); - }finally{ - define = oldDefine; - } - return result; - })(id, require.nodeRequire)); - }, - - normalize: function (/**string*/ id, /*Function*/ normalize){ - // summary: - // Produces a normalized id to be used by node. Relative ids are resolved relative to the requesting - // module's location in the file system and will return an id with path separators appropriate for the - // local file system. - - if(id.charAt(0) === "."){ - // dirname of the reference module - normalized to match the local file system - var referenceModuleDirname = require.toUrl(normalize(".")).replace("/", pathUtil.sep), - segments = id.split("/"); - segments.unshift(referenceModuleDirname); - // this will produce an absolute path normalized to the semantics of the underlying file system. - id = pathUtil.join.apply(pathUtil, segments); - } - - return id; - } - }; -}); diff --git a/lib/dojo/number.js b/lib/dojo/number.js deleted file mode 100644 index 788f35d..0000000 --- a/lib/dojo/number.js +++ /dev/null @@ -1,311 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/number",["./_base/lang","./i18n","./i18n!./cldr/nls/number","./string","./regexp"],function(_1,_2,_3,_4,_5){ -var _6={}; -_1.setObject("dojo.number",_6); -_6.format=function(_7,_8){ -_8=_1.mixin({},_8||{}); -var _9=_2.normalizeLocale(_8.locale),_a=_2.getLocalization("dojo.cldr","number",_9); -_8.customs=_a; -var _b=_8.pattern||_a[(_8.type||"decimal")+"Format"]; -if(isNaN(_7)||Math.abs(_7)==Infinity){ -return null; -} -return _6._applyPattern(_7,_b,_8); -}; -_6._numberPatternRE=/[#0,]*[#0](?:\.0*#*)?/; -_6._applyPattern=function(_c,_d,_e){ -_e=_e||{}; -var _f=_e.customs.group,_10=_e.customs.decimal,_11=_d.split(";"),_12=_11[0]; -_d=_11[(_c<0)?1:0]||("-"+_12); -if(_d.indexOf("%")!=-1){ -_c*=100; -}else{ -if(_d.indexOf("‰")!=-1){ -_c*=1000; -}else{ -if(_d.indexOf("¤")!=-1){ -_f=_e.customs.currencyGroup||_f; -_10=_e.customs.currencyDecimal||_10; -_d=_d.replace(/\u00a4{1,3}/,function(_13){ -var _14=["symbol","currency","displayName"][_13.length-1]; -return _e[_14]||_e.currency||""; -}); -}else{ -if(_d.indexOf("E")!=-1){ -throw new Error("exponential notation not supported"); -} -} -} -} -var _15=_6._numberPatternRE; -var _16=_12.match(_15); -if(!_16){ -throw new Error("unable to find a number expression in pattern: "+_d); -} -if(_e.fractional===false){ -_e.places=0; -} -return _d.replace(_15,_6._formatAbsolute(_c,_16[0],{decimal:_10,group:_f,places:_e.places,round:_e.round})); -}; -_6.round=function(_17,_18,_19){ -var _1a=10/(_19||10); -return (_1a*+_17).toFixed(_18)/_1a; -}; -if((0.9).toFixed()==0){ -var _1b=_6.round; -_6.round=function(v,p,m){ -var d=Math.pow(10,-p||0),a=Math.abs(v); -if(!v||a>=d){ -d=0; -}else{ -a/=d; -if(a<0.5||a>=0.95){ -d=0; -} -} -return _1b(v,p,m)+(v>0?d:-d); -}; -} -_6._formatAbsolute=function(_1c,_1d,_1e){ -_1e=_1e||{}; -if(_1e.places===true){ -_1e.places=0; -} -if(_1e.places===Infinity){ -_1e.places=6; -} -var _1f=_1d.split("."),_20=typeof _1e.places=="string"&&_1e.places.indexOf(","),_21=_1e.places; -if(_20){ -_21=_1e.places.substring(_20+1); -}else{ -if(!(_21>=0)){ -_21=(_1f[1]||[]).length; -} -} -if(!(_1e.round<0)){ -_1c=_6.round(_1c,_21,_1e.round); -} -var _22=String(Math.abs(_1c)).split("."),_23=_22[1]||""; -if(_1f[1]||_1e.places){ -if(_20){ -_1e.places=_1e.places.substring(0,_20); -} -var pad=_1e.places!==undefined?_1e.places:(_1f[1]&&_1f[1].lastIndexOf("0")+1); -if(pad>_23.length){ -_22[1]=_4.pad(_23,pad,"0",true); -} -if(_21<_23.length){ -_22[1]=_23.substr(0,_21); -} -}else{ -if(_22[1]){ -_22.pop(); -} -} -var _24=_1f[0].replace(",",""); -pad=_24.indexOf("0"); -if(pad!=-1){ -pad=_24.length-pad; -if(pad>_22[0].length){ -_22[0]=_4.pad(_22[0],pad); -} -if(_24.indexOf("#")==-1){ -_22[0]=_22[0].substr(_22[0].length-pad); -} -} -var _25=_1f[0].lastIndexOf(","),_26,_27; -if(_25!=-1){ -_26=_1f[0].length-_25-1; -var _28=_1f[0].substr(0,_25); -_25=_28.lastIndexOf(","); -if(_25!=-1){ -_27=_28.length-_25-1; -} -} -var _29=[]; -for(var _2a=_22[0];_2a;){ -var off=_2a.length-_26; -_29.push((off>0)?_2a.substr(off):_2a); -_2a=(off>0)?_2a.slice(0,off):""; -if(_27){ -_26=_27; -delete _27; -} -} -_22[0]=_29.reverse().join(_1e.group||","); -return _22.join(_1e.decimal||"."); -}; -_6.regexp=function(_2b){ -return _6._parseInfo(_2b).regexp; -}; -_6._parseInfo=function(_2c){ -_2c=_2c||{}; -var _2d=_2.normalizeLocale(_2c.locale),_2e=_2.getLocalization("dojo.cldr","number",_2d),_2f=_2c.pattern||_2e[(_2c.type||"decimal")+"Format"],_30=_2e.group,_31=_2e.decimal,_32=1; -if(_2f.indexOf("%")!=-1){ -_32/=100; -}else{ -if(_2f.indexOf("‰")!=-1){ -_32/=1000; -}else{ -var _33=_2f.indexOf("¤")!=-1; -if(_33){ -_30=_2e.currencyGroup||_30; -_31=_2e.currencyDecimal||_31; -} -} -} -var _34=_2f.split(";"); -if(_34.length==1){ -_34.push("-"+_34[0]); -} -var re=_5.buildGroupRE(_34,function(_35){ -_35="(?:"+_5.escapeString(_35,".")+")"; -return _35.replace(_6._numberPatternRE,function(_36){ -var _37={signed:false,separator:_2c.strict?_30:[_30,""],fractional:_2c.fractional,decimal:_31,exponent:false},_38=_36.split("."),_39=_2c.places; -if(_38.length==1&&_32!=1){ -_38[1]="###"; -} -if(_38.length==1||_39===0){ -_37.fractional=false; -}else{ -if(_39===undefined){ -_39=_2c.pattern?_38[1].lastIndexOf("0")+1:Infinity; -} -if(_39&&_2c.fractional==undefined){ -_37.fractional=true; -} -if(!_2c.places&&(_39<_38[1].length)){ -_39+=","+_38[1].length; -} -_37.places=_39; -} -var _3a=_38[0].split(","); -if(_3a.length>1){ -_37.groupSize=_3a.pop().length; -if(_3a.length>1){ -_37.groupSize2=_3a.pop().length; -} -} -return "("+_6._realNumberRegexp(_37)+")"; -}); -},true); -if(_33){ -re=re.replace(/([\s\xa0]*)(\u00a4{1,3})([\s\xa0]*)/g,function(_3b,_3c,_3d,_3e){ -var _3f=["symbol","currency","displayName"][_3d.length-1],_40=_5.escapeString(_2c[_3f]||_2c.currency||""); -_3c=_3c?"[\\s\\xa0]":""; -_3e=_3e?"[\\s\\xa0]":""; -if(!_2c.strict){ -if(_3c){ -_3c+="*"; -} -if(_3e){ -_3e+="*"; -} -return "(?:"+_3c+_40+_3e+")?"; -} -return _3c+_40+_3e; -}); -} -return {regexp:re.replace(/[\xa0 ]/g,"[\\s\\xa0]"),group:_30,decimal:_31,factor:_32}; -}; -_6.parse=function(_41,_42){ -var _43=_6._parseInfo(_42),_44=(new RegExp("^"+_43.regexp+"$")).exec(_41); -if(!_44){ -return NaN; -} -var _45=_44[1]; -if(!_44[1]){ -if(!_44[2]){ -return NaN; -} -_45=_44[2]; -_43.factor*=-1; -} -_45=_45.replace(new RegExp("["+_43.group+"\\s\\xa0"+"]","g"),"").replace(_43.decimal,"."); -return _45*_43.factor; -}; -_6._realNumberRegexp=function(_46){ -_46=_46||{}; -if(!("places" in _46)){ -_46.places=Infinity; -} -if(typeof _46.decimal!="string"){ -_46.decimal="."; -} -if(!("fractional" in _46)||/^0/.test(_46.places)){ -_46.fractional=[true,false]; -} -if(!("exponent" in _46)){ -_46.exponent=[true,false]; -} -if(!("eSigned" in _46)){ -_46.eSigned=[true,false]; -} -var _47=_6._integerRegexp(_46),_48=_5.buildGroupRE(_46.fractional,function(q){ -var re=""; -if(q&&(_46.places!==0)){ -re="\\"+_46.decimal; -if(_46.places==Infinity){ -re="(?:"+re+"\\d+)?"; -}else{ -re+="\\d{"+_46.places+"}"; -} -} -return re; -},true); -var _49=_5.buildGroupRE(_46.exponent,function(q){ -if(q){ -return "([eE]"+_6._integerRegexp({signed:_46.eSigned})+")"; -} -return ""; -}); -var _4a=_47+_48; -if(_48){ -_4a="(?:(?:"+_4a+")|(?:"+_48+"))"; -} -return _4a+_49; -}; -_6._integerRegexp=function(_4b){ -_4b=_4b||{}; -if(!("signed" in _4b)){ -_4b.signed=[true,false]; -} -if(!("separator" in _4b)){ -_4b.separator=""; -}else{ -if(!("groupSize" in _4b)){ -_4b.groupSize=3; -} -} -var _4c=_5.buildGroupRE(_4b.signed,function(q){ -return q?"[-+]":""; -},true); -var _4d=_5.buildGroupRE(_4b.separator,function(sep){ -if(!sep){ -return "(?:\\d+)"; -} -sep=_5.escapeString(sep); -if(sep==" "){ -sep="\\s"; -}else{ -if(sep==" "){ -sep="\\s\\xa0"; -} -} -var grp=_4b.groupSize,_4e=_4b.groupSize2; -if(_4e){ -var _4f="(?:0|[1-9]\\d{0,"+(_4e-1)+"}(?:["+sep+"]\\d{"+_4e+"})*["+sep+"]\\d{"+grp+"})"; -return ((grp-_4e)>0)?"(?:"+_4f+"|(?:0|[1-9]\\d{0,"+(grp-1)+"}))":_4f; -} -return "(?:0|[1-9]\\d{0,"+(grp-1)+"}(?:["+sep+"]\\d{"+grp+"})*)"; -},true); -return _4c+_4d; -}; -return _6; -}); diff --git a/lib/dojo/number.js.uncompressed.js b/lib/dojo/number.js.uncompressed.js deleted file mode 100644 index 0f52cc1..0000000 --- a/lib/dojo/number.js.uncompressed.js +++ /dev/null @@ -1,553 +0,0 @@ -define("dojo/number", [/*===== "./_base/declare", =====*/ "./_base/lang", "./i18n", "./i18n!./cldr/nls/number", "./string", "./regexp"], - function(/*===== declare, =====*/ lang, i18n, nlsNumber, dstring, dregexp){ - -// module: -// dojo/number - -var number = { - // summary: - // localized formatting and parsing routines for Number -}; -lang.setObject("dojo.number", number); - -/*===== -number.__FormatOptions = declare(null, { - // pattern: String? - // override [formatting pattern](http://www.unicode.org/reports/tr35/#Number_Format_Patterns) - // with this string. Default value is based on locale. Overriding this property will defeat - // localization. Literal characters in patterns are not supported. - // type: String? - // choose a format type based on the locale from the following: - // decimal, scientific (not yet supported), percent, currency. decimal by default. - // places: Number? - // fixed number of decimal places to show. This overrides any - // information in the provided pattern. - // round: Number? - // 5 rounds to nearest .5; 0 rounds to nearest whole (default). -1 - // means do not round. - // locale: String? - // override the locale used to determine formatting rules - // fractional: Boolean? - // If false, show no decimal places, overriding places and pattern settings. -}); -=====*/ - -number.format = function(/*Number*/ value, /*number.__FormatOptions?*/ options){ - // summary: - // Format a Number as a String, using locale-specific settings - // description: - // Create a string from a Number using a known localized pattern. - // Formatting patterns appropriate to the locale are chosen from the - // [Common Locale Data Repository](http://unicode.org/cldr) as well as the appropriate symbols and - // delimiters. - // If value is Infinity, -Infinity, or is not a valid JavaScript number, return null. - // value: - // the number to be formatted - - options = lang.mixin({}, options || {}); - var locale = i18n.normalizeLocale(options.locale), - bundle = i18n.getLocalization("dojo.cldr", "number", locale); - options.customs = bundle; - var pattern = options.pattern || bundle[(options.type || "decimal") + "Format"]; - if(isNaN(value) || Math.abs(value) == Infinity){ return null; } // null - return number._applyPattern(value, pattern, options); // String -}; - -//number._numberPatternRE = /(?:[#0]*,?)*[#0](?:\.0*#*)?/; // not precise, but good enough -number._numberPatternRE = /[#0,]*[#0](?:\.0*#*)?/; // not precise, but good enough - -number._applyPattern = function(/*Number*/ value, /*String*/ pattern, /*number.__FormatOptions?*/ options){ - // summary: - // Apply pattern to format value as a string using options. Gives no - // consideration to local customs. - // value: - // the number to be formatted. - // pattern: - // a pattern string as described by - // [unicode.org TR35](http://www.unicode.org/reports/tr35/#Number_Format_Patterns) - // options: number.__FormatOptions? - // _applyPattern is usually called via `dojo/number.format()` which - // populates an extra property in the options parameter, "customs". - // The customs object specifies group and decimal parameters if set. - - //TODO: support escapes - options = options || {}; - var group = options.customs.group, - decimal = options.customs.decimal, - patternList = pattern.split(';'), - positivePattern = patternList[0]; - pattern = patternList[(value < 0) ? 1 : 0] || ("-" + positivePattern); - - //TODO: only test against unescaped - if(pattern.indexOf('%') != -1){ - value *= 100; - }else if(pattern.indexOf('\u2030') != -1){ - value *= 1000; // per mille - }else if(pattern.indexOf('\u00a4') != -1){ - group = options.customs.currencyGroup || group;//mixins instead? - decimal = options.customs.currencyDecimal || decimal;// Should these be mixins instead? - pattern = pattern.replace(/\u00a4{1,3}/, function(match){ - var prop = ["symbol", "currency", "displayName"][match.length-1]; - return options[prop] || options.currency || ""; - }); - }else if(pattern.indexOf('E') != -1){ - throw new Error("exponential notation not supported"); - } - - //TODO: support @ sig figs? - var numberPatternRE = number._numberPatternRE; - var numberPattern = positivePattern.match(numberPatternRE); - if(!numberPattern){ - throw new Error("unable to find a number expression in pattern: "+pattern); - } - if(options.fractional === false){ options.places = 0; } - return pattern.replace(numberPatternRE, - number._formatAbsolute(value, numberPattern[0], {decimal: decimal, group: group, places: options.places, round: options.round})); -}; - -number.round = function(/*Number*/ value, /*Number?*/ places, /*Number?*/ increment){ - // summary: - // Rounds to the nearest value with the given number of decimal places, away from zero - // description: - // Rounds to the nearest value with the given number of decimal places, away from zero if equal. - // Similar to Number.toFixed(), but compensates for browser quirks. Rounding can be done by - // fractional increments also, such as the nearest quarter. - // NOTE: Subject to floating point errors. See dojox/math/round for experimental workaround. - // value: - // The number to round - // places: - // The number of decimal places where rounding takes place. Defaults to 0 for whole rounding. - // Must be non-negative. - // increment: - // Rounds next place to nearest value of increment/10. 10 by default. - // example: - // | >>> number.round(-0.5) - // | -1 - // | >>> number.round(162.295, 2) - // | 162.29 // note floating point error. Should be 162.3 - // | >>> number.round(10.71, 0, 2.5) - // | 10.75 - var factor = 10 / (increment || 10); - return (factor * +value).toFixed(places) / factor; // Number -}; - -if((0.9).toFixed() == 0){ - // (isIE) toFixed() bug workaround: Rounding fails on IE when most significant digit - // is just after the rounding place and is >=5 - var round = number.round; - number.round = function(v, p, m){ - var d = Math.pow(10, -p || 0), a = Math.abs(v); - if(!v || a >= d){ - d = 0; - }else{ - a /= d; - if(a < 0.5 || a >= 0.95){ - d = 0; - } - } - return round(v, p, m) + (v > 0 ? d : -d); - }; - - // Use "doc hint" so the doc parser ignores this new definition of round(), and uses the one above. - /*===== number.round = round; =====*/ -} - -/*===== -number.__FormatAbsoluteOptions = declare(null, { - // decimal: String? - // the decimal separator - // group: String? - // the group separator - // places: Number|String? - // number of decimal places. the range "n,m" will format to m places. - // round: Number? - // 5 rounds to nearest .5; 0 rounds to nearest whole (default). -1 - // means don't round. -}); -=====*/ - -number._formatAbsolute = function(/*Number*/ value, /*String*/ pattern, /*number.__FormatAbsoluteOptions?*/ options){ - // summary: - // Apply numeric pattern to absolute value using options. Gives no - // consideration to local customs. - // value: - // the number to be formatted, ignores sign - // pattern: - // the number portion of a pattern (e.g. `#,##0.00`) - options = options || {}; - if(options.places === true){options.places=0;} - if(options.places === Infinity){options.places=6;} // avoid a loop; pick a limit - - var patternParts = pattern.split("."), - comma = typeof options.places == "string" && options.places.indexOf(","), - maxPlaces = options.places; - if(comma){ - maxPlaces = options.places.substring(comma + 1); - }else if(!(maxPlaces >= 0)){ - maxPlaces = (patternParts[1] || []).length; - } - if(!(options.round < 0)){ - value = number.round(value, maxPlaces, options.round); - } - - var valueParts = String(Math.abs(value)).split("."), - fractional = valueParts[1] || ""; - if(patternParts[1] || options.places){ - if(comma){ - options.places = options.places.substring(0, comma); - } - // Pad fractional with trailing zeros - var pad = options.places !== undefined ? options.places : (patternParts[1] && patternParts[1].lastIndexOf("0") + 1); - if(pad > fractional.length){ - valueParts[1] = dstring.pad(fractional, pad, '0', true); - } - - // Truncate fractional - if(maxPlaces < fractional.length){ - valueParts[1] = fractional.substr(0, maxPlaces); - } - }else{ - if(valueParts[1]){ valueParts.pop(); } - } - - // Pad whole with leading zeros - var patternDigits = patternParts[0].replace(',', ''); - pad = patternDigits.indexOf("0"); - if(pad != -1){ - pad = patternDigits.length - pad; - if(pad > valueParts[0].length){ - valueParts[0] = dstring.pad(valueParts[0], pad); - } - - // Truncate whole - if(patternDigits.indexOf("#") == -1){ - valueParts[0] = valueParts[0].substr(valueParts[0].length - pad); - } - } - - // Add group separators - var index = patternParts[0].lastIndexOf(','), - groupSize, groupSize2; - if(index != -1){ - groupSize = patternParts[0].length - index - 1; - var remainder = patternParts[0].substr(0, index); - index = remainder.lastIndexOf(','); - if(index != -1){ - groupSize2 = remainder.length - index - 1; - } - } - var pieces = []; - for(var whole = valueParts[0]; whole;){ - var off = whole.length - groupSize; - pieces.push((off > 0) ? whole.substr(off) : whole); - whole = (off > 0) ? whole.slice(0, off) : ""; - if(groupSize2){ - groupSize = groupSize2; - delete groupSize2; - } - } - valueParts[0] = pieces.reverse().join(options.group || ","); - - return valueParts.join(options.decimal || "."); -}; - -/*===== -number.__RegexpOptions = declare(null, { - // pattern: String? - // override [formatting pattern](http://www.unicode.org/reports/tr35/#Number_Format_Patterns) - // with this string. Default value is based on locale. Overriding this property will defeat - // localization. - // type: String? - // choose a format type based on the locale from the following: - // decimal, scientific (not yet supported), percent, currency. decimal by default. - // locale: String? - // override the locale used to determine formatting rules - // strict: Boolean? - // strict parsing, false by default. Strict parsing requires input as produced by the format() method. - // Non-strict is more permissive, e.g. flexible on white space, omitting thousands separators - // places: Number|String? - // number of decimal places to accept: Infinity, a positive number, or - // a range "n,m". Defined by pattern or Infinity if pattern not provided. -}); -=====*/ -number.regexp = function(/*number.__RegexpOptions?*/ options){ - // summary: - // Builds the regular needed to parse a number - // description: - // Returns regular expression with positive and negative match, group - // and decimal separators - return number._parseInfo(options).regexp; // String -}; - -number._parseInfo = function(/*Object?*/ options){ - options = options || {}; - var locale = i18n.normalizeLocale(options.locale), - bundle = i18n.getLocalization("dojo.cldr", "number", locale), - pattern = options.pattern || bundle[(options.type || "decimal") + "Format"], -//TODO: memoize? - group = bundle.group, - decimal = bundle.decimal, - factor = 1; - - if(pattern.indexOf('%') != -1){ - factor /= 100; - }else if(pattern.indexOf('\u2030') != -1){ - factor /= 1000; // per mille - }else{ - var isCurrency = pattern.indexOf('\u00a4') != -1; - if(isCurrency){ - group = bundle.currencyGroup || group; - decimal = bundle.currencyDecimal || decimal; - } - } - - //TODO: handle quoted escapes - var patternList = pattern.split(';'); - if(patternList.length == 1){ - patternList.push("-" + patternList[0]); - } - - var re = dregexp.buildGroupRE(patternList, function(pattern){ - pattern = "(?:"+dregexp.escapeString(pattern, '.')+")"; - return pattern.replace(number._numberPatternRE, function(format){ - var flags = { - signed: false, - separator: options.strict ? group : [group,""], - fractional: options.fractional, - decimal: decimal, - exponent: false - }, - - parts = format.split('.'), - places = options.places; - - // special condition for percent (factor != 1) - // allow decimal places even if not specified in pattern - if(parts.length == 1 && factor != 1){ - parts[1] = "###"; - } - if(parts.length == 1 || places === 0){ - flags.fractional = false; - }else{ - if(places === undefined){ places = options.pattern ? parts[1].lastIndexOf('0') + 1 : Infinity; } - if(places && options.fractional == undefined){flags.fractional = true;} // required fractional, unless otherwise specified - if(!options.places && (places < parts[1].length)){ places += "," + parts[1].length; } - flags.places = places; - } - var groups = parts[0].split(','); - if(groups.length > 1){ - flags.groupSize = groups.pop().length; - if(groups.length > 1){ - flags.groupSize2 = groups.pop().length; - } - } - return "("+number._realNumberRegexp(flags)+")"; - }); - }, true); - - if(isCurrency){ - // substitute the currency symbol for the placeholder in the pattern - re = re.replace(/([\s\xa0]*)(\u00a4{1,3})([\s\xa0]*)/g, function(match, before, target, after){ - var prop = ["symbol", "currency", "displayName"][target.length-1], - symbol = dregexp.escapeString(options[prop] || options.currency || ""); - before = before ? "[\\s\\xa0]" : ""; - after = after ? "[\\s\\xa0]" : ""; - if(!options.strict){ - if(before){before += "*";} - if(after){after += "*";} - return "(?:"+before+symbol+after+")?"; - } - return before+symbol+after; - }); - } - -//TODO: substitute localized sign/percent/permille/etc.? - - // normalize whitespace and return - return {regexp: re.replace(/[\xa0 ]/g, "[\\s\\xa0]"), group: group, decimal: decimal, factor: factor}; // Object -}; - -/*===== -number.__ParseOptions = declare(null, { - // pattern: String? - // override [formatting pattern](http://www.unicode.org/reports/tr35/#Number_Format_Patterns) - // with this string. Default value is based on locale. Overriding this property will defeat - // localization. Literal characters in patterns are not supported. - // type: String? - // choose a format type based on the locale from the following: - // decimal, scientific (not yet supported), percent, currency. decimal by default. - // locale: String? - // override the locale used to determine formatting rules - // strict: Boolean? - // strict parsing, false by default. Strict parsing requires input as produced by the format() method. - // Non-strict is more permissive, e.g. flexible on white space, omitting thousands separators - // fractional: Boolean|Array? - // Whether to include the fractional portion, where the number of decimal places are implied by pattern - // or explicit 'places' parameter. The value [true,false] makes the fractional portion optional. -}); -=====*/ -number.parse = function(/*String*/ expression, /*number.__ParseOptions?*/ options){ - // summary: - // Convert a properly formatted string to a primitive Number, using - // locale-specific settings. - // description: - // Create a Number from a string using a known localized pattern. - // Formatting patterns are chosen appropriate to the locale - // and follow the syntax described by - // [unicode.org TR35](http://www.unicode.org/reports/tr35/#Number_Format_Patterns) - // Note that literal characters in patterns are not supported. - // expression: - // A string representation of a Number - var info = number._parseInfo(options), - results = (new RegExp("^"+info.regexp+"$")).exec(expression); - if(!results){ - return NaN; //NaN - } - var absoluteMatch = results[1]; // match for the positive expression - if(!results[1]){ - if(!results[2]){ - return NaN; //NaN - } - // matched the negative pattern - absoluteMatch =results[2]; - info.factor *= -1; - } - - // Transform it to something Javascript can parse as a number. Normalize - // decimal point and strip out group separators or alternate forms of whitespace - absoluteMatch = absoluteMatch. - replace(new RegExp("["+info.group + "\\s\\xa0"+"]", "g"), ""). - replace(info.decimal, "."); - // Adjust for negative sign, percent, etc. as necessary - return absoluteMatch * info.factor; //Number -}; - -/*===== -number.__RealNumberRegexpFlags = declare(null, { - // places: Number? - // The integer number of decimal places or a range given as "n,m". If - // not given, the decimal part is optional and the number of places is - // unlimited. - // decimal: String? - // A string for the character used as the decimal point. Default - // is ".". - // fractional: Boolean|Array? - // Whether decimal places are used. Can be true, false, or [true, - // false]. Default is [true, false] which means optional. - // exponent: Boolean|Array? - // Express in exponential notation. Can be true, false, or [true, - // false]. Default is [true, false], (i.e. will match if the - // exponential part is present are not). - // eSigned: Boolean|Array? - // The leading plus-or-minus sign on the exponent. Can be true, - // false, or [true, false]. Default is [true, false], (i.e. will - // match if it is signed or unsigned). flags in regexp.integer can be - // applied. -}); -=====*/ - -number._realNumberRegexp = function(/*__RealNumberRegexpFlags?*/ flags){ - // summary: - // Builds a regular expression to match a real number in exponential - // notation - - // assign default values to missing parameters - flags = flags || {}; - //TODO: use mixin instead? - if(!("places" in flags)){ flags.places = Infinity; } - if(typeof flags.decimal != "string"){ flags.decimal = "."; } - if(!("fractional" in flags) || /^0/.test(flags.places)){ flags.fractional = [true, false]; } - if(!("exponent" in flags)){ flags.exponent = [true, false]; } - if(!("eSigned" in flags)){ flags.eSigned = [true, false]; } - - var integerRE = number._integerRegexp(flags), - decimalRE = dregexp.buildGroupRE(flags.fractional, - function(q){ - var re = ""; - if(q && (flags.places!==0)){ - re = "\\" + flags.decimal; - if(flags.places == Infinity){ - re = "(?:" + re + "\\d+)?"; - }else{ - re += "\\d{" + flags.places + "}"; - } - } - return re; - }, - true - ); - - var exponentRE = dregexp.buildGroupRE(flags.exponent, - function(q){ - if(q){ return "([eE]" + number._integerRegexp({ signed: flags.eSigned}) + ")"; } - return ""; - } - ); - - var realRE = integerRE + decimalRE; - // allow for decimals without integers, e.g. .25 - if(decimalRE){realRE = "(?:(?:"+ realRE + ")|(?:" + decimalRE + "))";} - return realRE + exponentRE; // String -}; - -/*===== -number.__IntegerRegexpFlags = declare(null, { - // signed: Boolean? - // The leading plus-or-minus sign. Can be true, false, or `[true,false]`. - // Default is `[true, false]`, (i.e. will match if it is signed - // or unsigned). - // separator: String? - // The character used as the thousands separator. Default is no - // separator. For more than one symbol use an array, e.g. `[",", ""]`, - // makes ',' optional. - // groupSize: Number? - // group size between separators - // groupSize2: Number? - // second grouping, where separators 2..n have a different interval than the first separator (for India) -}); -=====*/ - -number._integerRegexp = function(/*number.__IntegerRegexpFlags?*/ flags){ - // summary: - // Builds a regular expression that matches an integer - - // assign default values to missing parameters - flags = flags || {}; - if(!("signed" in flags)){ flags.signed = [true, false]; } - if(!("separator" in flags)){ - flags.separator = ""; - }else if(!("groupSize" in flags)){ - flags.groupSize = 3; - } - - var signRE = dregexp.buildGroupRE(flags.signed, - function(q){ return q ? "[-+]" : ""; }, - true - ); - - var numberRE = dregexp.buildGroupRE(flags.separator, - function(sep){ - if(!sep){ - return "(?:\\d+)"; - } - - sep = dregexp.escapeString(sep); - if(sep == " "){ sep = "\\s"; } - else if(sep == "\xa0"){ sep = "\\s\\xa0"; } - - var grp = flags.groupSize, grp2 = flags.groupSize2; - //TODO: should we continue to enforce that numbers with separators begin with 1-9? See #6933 - if(grp2){ - var grp2RE = "(?:0|[1-9]\\d{0," + (grp2-1) + "}(?:[" + sep + "]\\d{" + grp2 + "})*[" + sep + "]\\d{" + grp + "})"; - return ((grp-grp2) > 0) ? "(?:" + grp2RE + "|(?:0|[1-9]\\d{0," + (grp-1) + "}))" : grp2RE; - } - return "(?:0|[1-9]\\d{0," + (grp-1) + "}(?:[" + sep + "]\\d{" + grp + "})*)"; - }, - true - ); - - return signRE + numberRE; // String -}; - -return number; -}); diff --git a/lib/dojo/on.js b/lib/dojo/on.js deleted file mode 100644 index 61bc7e3..0000000 --- a/lib/dojo/on.js +++ /dev/null @@ -1,366 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/on",["./has!dom-addeventlistener?:./aspect","./_base/kernel","./sniff"],function(_1,_2,_3){ -"use strict"; -if(1){ -var _4=window.ScriptEngineMajorVersion; -_3.add("jscript",_4&&(_4()+ScriptEngineMinorVersion()/10)); -_3.add("event-orientationchange",_3("touch")&&!_3("android")); -_3.add("event-stopimmediatepropagation",window.Event&&!!window.Event.prototype&&!!window.Event.prototype.stopImmediatePropagation); -_3.add("event-focusin",function(_5,_6,_7){ -return "onfocusin" in _7; -}); -} -var on=function(_8,_9,_a,_b){ -if(typeof _8.on=="function"&&typeof _9!="function"&&!_8.nodeType){ -return _8.on(_9,_a); -} -return on.parse(_8,_9,_a,_c,_b,this); -}; -on.pausable=function(_d,_e,_f,_10){ -var _11; -var _12=on(_d,_e,function(){ -if(!_11){ -return _f.apply(this,arguments); -} -},_10); -_12.pause=function(){ -_11=true; -}; -_12.resume=function(){ -_11=false; -}; -return _12; -}; -on.once=function(_13,_14,_15,_16){ -var _17=on(_13,_14,function(){ -_17.remove(); -return _15.apply(this,arguments); -}); -return _17; -}; -on.parse=function(_18,_19,_1a,_1b,_1c,_1d){ -if(_19.call){ -return _19.call(_1d,_18,_1a); -} -if(_19 instanceof Array){ -_1e=_19; -}else{ -if(_19.indexOf(",")>-1){ -var _1e=_19.split(/\s*,\s*/); -} -} -if(_1e){ -var _1f=[]; -var i=0; -var _20; -while(_20=_1e[i++]){ -_1f.push(on.parse(_18,_20,_1a,_1b,_1c,_1d)); -} -_1f.remove=function(){ -for(var i=0;i<_1f.length;i++){ -_1f[i].remove(); -} -}; -return _1f; -} -return _1b(_18,_19,_1a,_1c,_1d); -}; -var _21=/^touch/; -function _c(_22,_23,_24,_25,_26){ -var _27=_23.match(/(.*):(.*)/); -if(_27){ -_23=_27[2]; -_27=_27[1]; -return on.selector(_27,_23).call(_26,_22,_24); -} -if(_3("touch")){ -if(_21.test(_23)){ -_24=_28(_24); -} -if(!_3("event-orientationchange")&&(_23=="orientationchange")){ -_23="resize"; -_22=window; -_24=_28(_24); -} -} -if(_29){ -_24=_29(_24); -} -if(_22.addEventListener){ -var _2a=_23 in _2b,_2c=_2a?_2b[_23]:_23; -_22.addEventListener(_2c,_24,_2a); -return {remove:function(){ -_22.removeEventListener(_2c,_24,_2a); -}}; -} -_23="on"+_23; -if(_2d&&_22.attachEvent){ -return _2d(_22,_23,_24); -} -throw new Error("Target must be an event emitter"); -}; -on.matches=function(_2e,_2f,_30,_31,_32){ -_32=_32&&_32.matches?_32:_2.query; -_31=_31!==false; -if(_2e.nodeType!=1){ -_2e=_2e.parentNode; -} -while(!_32.matches(_2e,_2f,_30)){ -if(_2e==_30||_31===false||!(_2e=_2e.parentNode)||_2e.nodeType!=1){ -return false; -} -} -return _2e; -}; -on.selector=function(_33,_34,_35){ -return function(_36,_37){ -var _38=typeof _33=="function"?{matches:_33}:this,_39=_34.bubble; -function _3a(_3b){ -return on.matches(_3b,_33,_36,_35,_38); -}; -if(_39){ -return on(_36,_39(_3a),_37); -} -return on(_36,_34,function(_3c){ -var _3d=_3a(_3c.target); -return _3d&&_37.call(_3d,_3c); -}); -}; -}; -function _3e(){ -this.cancelable=false; -this.defaultPrevented=true; -}; -function _3f(){ -this.bubbles=false; -}; -var _40=[].slice,_41=on.emit=function(_42,_43,_44){ -var _45=_40.call(arguments,2); -var _46="on"+_43; -if("parentNode" in _42){ -var _47=_45[0]={}; -for(var i in _44){ -_47[i]=_44[i]; -} -_47.preventDefault=_3e; -_47.stopPropagation=_3f; -_47.target=_42; -_47.type=_43; -_44=_47; -} -do{ -_42[_46]&&_42[_46].apply(_42,_45); -}while(_44&&_44.bubbles&&(_42=_42.parentNode)); -return _44&&_44.cancelable&&_44; -}; -var _2b=_3("event-focusin")?{}:{focusin:"focus",focusout:"blur"}; -if(!_3("event-stopimmediatepropagation")){ -var _48=function(){ -this.immediatelyStopped=true; -this.modified=true; -}; -var _29=function(_49){ -return function(_4a){ -if(!_4a.immediatelyStopped){ -_4a.stopImmediatePropagation=_48; -return _49.apply(this,arguments); -} -}; -}; -} -if(_3("dom-addeventlistener")){ -on.emit=function(_4b,_4c,_4d){ -if(_4b.dispatchEvent&&document.createEvent){ -var _4e=_4b.ownerDocument||document; -var _4f=_4e.createEvent("HTMLEvents"); -_4f.initEvent(_4c,!!_4d.bubbles,!!_4d.cancelable); -for(var i in _4d){ -if(!(i in _4f)){ -_4f[i]=_4d[i]; -} -} -return _4b.dispatchEvent(_4f)&&_4f; -} -return _41.apply(on,arguments); -}; -}else{ -on._fixEvent=function(evt,_50){ -if(!evt){ -var w=_50&&(_50.ownerDocument||_50.document||_50).parentWindow||window; -evt=w.event; -} -if(!evt){ -return evt; -} -try{ -if(_51&&evt.type==_51.type&&evt.srcElement==_51.target){ -evt=_51; -} -} -catch(e){ -} -if(!evt.target){ -evt.target=evt.srcElement; -evt.currentTarget=(_50||evt.srcElement); -if(evt.type=="mouseover"){ -evt.relatedTarget=evt.fromElement; -} -if(evt.type=="mouseout"){ -evt.relatedTarget=evt.toElement; -} -if(!evt.stopPropagation){ -evt.stopPropagation=_52; -evt.preventDefault=_53; -} -switch(evt.type){ -case "keypress": -var c=("charCode" in evt?evt.charCode:evt.keyCode); -if(c==10){ -c=0; -evt.keyCode=13; -}else{ -if(c==13||c==27){ -c=0; -}else{ -if(c==3){ -c=99; -} -} -} -evt.charCode=c; -_54(evt); -break; -} -} -return evt; -}; -var _51,_55=function(_56){ -this.handle=_56; -}; -_55.prototype.remove=function(){ -delete _dojoIEListeners_[this.handle]; -}; -var _57=function(_58){ -return function(evt){ -evt=on._fixEvent(evt,this); -var _59=_58.call(this,evt); -if(evt.modified){ -if(!_51){ -setTimeout(function(){ -_51=null; -}); -} -_51=evt; -} -return _59; -}; -}; -var _2d=function(_5a,_5b,_5c){ -_5c=_57(_5c); -if(((_5a.ownerDocument?_5a.ownerDocument.parentWindow:_5a.parentWindow||_5a.window||window)!=top||_3("jscript")<5.8)&&!_3("config-_allow_leaks")){ -if(typeof _dojoIEListeners_=="undefined"){ -_dojoIEListeners_=[]; -} -var _5d=_5a[_5b]; -if(!_5d||!_5d.listeners){ -var _5e=_5d; -_5d=Function("event","var callee = arguments.callee; for(var i = 0; i<callee.listeners.length; i++){var listener = _dojoIEListeners_[callee.listeners[i]]; if(listener){listener.call(this,event);}}"); -_5d.listeners=[]; -_5a[_5b]=_5d; -_5d.global=this; -if(_5e){ -_5d.listeners.push(_dojoIEListeners_.push(_5e)-1); -} -} -var _5f; -_5d.listeners.push(_5f=(_5d.global._dojoIEListeners_.push(_5c)-1)); -return new _55(_5f); -} -return _1.after(_5a,_5b,_5c,true); -}; -var _54=function(evt){ -evt.keyChar=evt.charCode?String.fromCharCode(evt.charCode):""; -evt.charOrCode=evt.keyChar||evt.keyCode; -}; -var _52=function(){ -this.cancelBubble=true; -}; -var _53=on._preventDefault=function(){ -this.bubbledKeyCode=this.keyCode; -if(this.ctrlKey){ -try{ -this.keyCode=0; -} -catch(e){ -} -} -this.defaultPrevented=true; -this.returnValue=false; -this.modified=true; -}; -} -if(_3("touch")){ -var _60=function(){ -}; -var _61=window.orientation; -var _28=function(_62){ -return function(_63){ -var _64=_63.corrected; -if(!_64){ -var _65=_63.type; -try{ -delete _63.type; -} -catch(e){ -} -if(_63.type){ -if(_3("mozilla")){ -var _64={}; -for(var _66 in _63){ -_64[_66]=_63[_66]; -} -}else{ -_60.prototype=_63; -var _64=new _60; -} -_64.preventDefault=function(){ -_63.preventDefault(); -}; -_64.stopPropagation=function(){ -_63.stopPropagation(); -}; -}else{ -_64=_63; -_64.type=_65; -} -_63.corrected=_64; -if(_65=="resize"){ -if(_61==window.orientation){ -return null; -} -_61=window.orientation; -_64.type="orientationchange"; -return _62.call(this,_64); -} -if(!("rotation" in _64)){ -_64.rotation=0; -_64.scale=1; -} -var _67=_64.changedTouches[0]; -for(var i in _67){ -delete _64[i]; -_64[i]=_67[i]; -} -} -return _62.call(this,_64); -}; -}; -} -return on; -}); diff --git a/lib/dojo/on.js.uncompressed.js b/lib/dojo/on.js.uncompressed.js deleted file mode 100644 index c3381a7..0000000 --- a/lib/dojo/on.js.uncompressed.js +++ /dev/null @@ -1,565 +0,0 @@ -define("dojo/on", ["./has!dom-addeventlistener?:./aspect", "./_base/kernel", "./sniff"], function(aspect, dojo, has){ - - "use strict"; - if( 1 ){ // check to make sure we are in a browser, this module should work anywhere - var major = window.ScriptEngineMajorVersion; - has.add("jscript", major && (major() + ScriptEngineMinorVersion() / 10)); - has.add("event-orientationchange", has("touch") && !has("android")); // TODO: how do we detect this? - has.add("event-stopimmediatepropagation", window.Event && !!window.Event.prototype && !!window.Event.prototype.stopImmediatePropagation); - has.add("event-focusin", function(global, doc, element){ - return 'onfocusin' in element; - }); - } - var on = function(target, type, listener, dontFix){ - // summary: - // A function that provides core event listening functionality. With this function - // you can provide a target, event type, and listener to be notified of - // future matching events that are fired. - // target: Element|Object - // This is the target object or DOM element that to receive events from - // type: String|Function - // This is the name of the event to listen for or an extension event type. - // listener: Function - // This is the function that should be called when the event fires. - // returns: Object - // An object with a remove() method that can be used to stop listening for this - // event. - // description: - // To listen for "click" events on a button node, we can do: - // | define(["dojo/on"], function(listen){ - // | on(button, "click", clickHandler); - // | ... - // Evented JavaScript objects can also have their own events. - // | var obj = new Evented; - // | on(obj, "foo", fooHandler); - // And then we could publish a "foo" event: - // | on.emit(obj, "foo", {key: "value"}); - // We can use extension events as well. For example, you could listen for a tap gesture: - // | define(["dojo/on", "dojo/gesture/tap", function(listen, tap){ - // | on(button, tap, tapHandler); - // | ... - // which would trigger fooHandler. Note that for a simple object this is equivalent to calling: - // | obj.onfoo({key:"value"}); - // If you use on.emit on a DOM node, it will use native event dispatching when possible. - - if(typeof target.on == "function" && typeof type != "function" && !target.nodeType){ - // delegate to the target's on() method, so it can handle it's own listening if it wants (unless it - // is DOM node and we may be dealing with jQuery or Prototype's incompatible addition to the - // Element prototype - return target.on(type, listener); - } - // delegate to main listener code - return on.parse(target, type, listener, addListener, dontFix, this); - }; - on.pausable = function(target, type, listener, dontFix){ - // summary: - // This function acts the same as on(), but with pausable functionality. The - // returned signal object has pause() and resume() functions. Calling the - // pause() method will cause the listener to not be called for future events. Calling the - // resume() method will cause the listener to again be called for future events. - var paused; - var signal = on(target, type, function(){ - if(!paused){ - return listener.apply(this, arguments); - } - }, dontFix); - signal.pause = function(){ - paused = true; - }; - signal.resume = function(){ - paused = false; - }; - return signal; - }; - on.once = function(target, type, listener, dontFix){ - // summary: - // This function acts the same as on(), but will only call the listener once. The - // listener will be called for the first - // event that takes place and then listener will automatically be removed. - var signal = on(target, type, function(){ - // remove this listener - signal.remove(); - // proceed to call the listener - return listener.apply(this, arguments); - }); - return signal; - }; - on.parse = function(target, type, listener, addListener, dontFix, matchesTarget){ - if(type.call){ - // event handler function - // on(node, touch.press, touchListener); - return type.call(matchesTarget, target, listener); - } - - if(type instanceof Array){ - // allow an array of event names (or event handler functions) - events = type; - }else if(type.indexOf(",") > -1){ - // we allow comma delimited event names, so you can register for multiple events at once - var events = type.split(/\s*,\s*/); - } - if(events){ - var handles = []; - var i = 0; - var eventName; - while(eventName = events[i++]){ - handles.push(on.parse(target, eventName, listener, addListener, dontFix, matchesTarget)); - } - handles.remove = function(){ - for(var i = 0; i < handles.length; i++){ - handles[i].remove(); - } - }; - return handles; - } - return addListener(target, type, listener, dontFix, matchesTarget); - }; - var touchEvents = /^touch/; - function addListener(target, type, listener, dontFix, matchesTarget){ - // event delegation: - var selector = type.match(/(.*):(.*)/); - // if we have a selector:event, the last one is interpreted as an event, and we use event delegation - if(selector){ - type = selector[2]; - selector = selector[1]; - // create the extension event for selectors and directly call it - return on.selector(selector, type).call(matchesTarget, target, listener); - } - // test to see if it a touch event right now, so we don't have to do it every time it fires - if(has("touch")){ - if(touchEvents.test(type)){ - // touch event, fix it - listener = fixTouchListener(listener); - } - if(!has("event-orientationchange") && (type == "orientationchange")){ - //"orientationchange" not supported <= Android 2.1, - //but works through "resize" on window - type = "resize"; - target = window; - listener = fixTouchListener(listener); - } - } - if(addStopImmediate){ - // add stopImmediatePropagation if it doesn't exist - listener = addStopImmediate(listener); - } - // normal path, the target is |this| - if(target.addEventListener){ - // the target has addEventListener, which should be used if available (might or might not be a node, non-nodes can implement this method as well) - // check for capture conversions - var capture = type in captures, - adjustedType = capture ? captures[type] : type; - target.addEventListener(adjustedType, listener, capture); - // create and return the signal - return { - remove: function(){ - target.removeEventListener(adjustedType, listener, capture); - } - }; - } - type = "on" + type; - if(fixAttach && target.attachEvent){ - return fixAttach(target, type, listener); - } - throw new Error("Target must be an event emitter"); - } - on.matches = function(node, selector, context, children, matchesTarget) { - // summary: - // Check if a node match the current selector within the constraint of a context - // node: DOMNode - // The node that originate the event - // selector: String - // The selector to check against - // context: DOMNode - // The context to search in. - // children: Boolean - // Indicates if children elements of the selector should be allowed. This defaults to - // true - // matchesTarget: Object|dojo/query? - // An object with a property "matches" as a function. Default is dojo/query. - // Matching DOMNodes will be done against this function - // The function must return a Boolean. - // It will have 3 arguments: "node", "selector" and "context" - // True is expected if "node" is matching the current "selector" in the passed "context" - // returns: DOMNode? - // The matching node, if any. Else you get false - - // see if we have a valid matchesTarget or default to dojo/query - matchesTarget = matchesTarget && matchesTarget.matches ? matchesTarget : dojo.query; - children = children !== false; - // there is a selector, so make sure it matches - if(node.nodeType != 1){ - // text node will fail in native match selector - node = node.parentNode; - } - while(!matchesTarget.matches(node, selector, context)){ - if(node == context || children === false || !(node = node.parentNode) || node.nodeType != 1){ // intentional assignment - return false; - } - } - return node; - } - on.selector = function(selector, eventType, children){ - // summary: - // Creates a new extension event with event delegation. This is based on - // the provided event type (can be extension event) that - // only calls the listener when the CSS selector matches the target of the event. - // - // The application must require() an appropriate level of dojo/query to handle the selector. - // selector: - // The CSS selector to use for filter events and determine the |this| of the event listener. - // eventType: - // The event to listen for - // children: - // Indicates if children elements of the selector should be allowed. This defaults to - // true - // example: - // | require(["dojo/on", "dojo/mouse", "dojo/query!css2"], function(listen, mouse){ - // | on(node, on.selector(".my-class", mouse.enter), handlerForMyHover); - return function(target, listener){ - // if the selector is function, use it to select the node, otherwise use the matches method - var matchesTarget = typeof selector == "function" ? {matches: selector} : this, - bubble = eventType.bubble; - function select(eventTarget){ - return on.matches(eventTarget, selector, target, children, matchesTarget); - } - if(bubble){ - // the event type doesn't naturally bubble, but has a bubbling form, use that, and give it the selector so it can perform the select itself - return on(target, bubble(select), listener); - } - // standard event delegation - return on(target, eventType, function(event){ - // call select to see if we match - var eventTarget = select(event.target); - // if it matches we call the listener - return eventTarget && listener.call(eventTarget, event); - }); - }; - }; - - function syntheticPreventDefault(){ - this.cancelable = false; - this.defaultPrevented = true; - } - function syntheticStopPropagation(){ - this.bubbles = false; - } - var slice = [].slice, - syntheticDispatch = on.emit = function(target, type, event){ - // summary: - // Fires an event on the target object. - // target: - // The target object to fire the event on. This can be a DOM element or a plain - // JS object. If the target is a DOM element, native event emitting mechanisms - // are used when possible. - // type: - // The event type name. You can emulate standard native events like "click" and - // "mouseover" or create custom events like "open" or "finish". - // event: - // An object that provides the properties for the event. See https://developer.mozilla.org/en/DOM/event.initEvent - // for some of the properties. These properties are copied to the event object. - // Of particular importance are the cancelable and bubbles properties. The - // cancelable property indicates whether or not the event has a default action - // that can be cancelled. The event is cancelled by calling preventDefault() on - // the event object. The bubbles property indicates whether or not the - // event will bubble up the DOM tree. If bubbles is true, the event will be called - // on the target and then each parent successively until the top of the tree - // is reached or stopPropagation() is called. Both bubbles and cancelable - // default to false. - // returns: - // If the event is cancelable and the event is not cancelled, - // emit will return true. If the event is cancelable and the event is cancelled, - // emit will return false. - // details: - // Note that this is designed to emit events for listeners registered through - // dojo/on. It should actually work with any event listener except those - // added through IE's attachEvent (IE8 and below's non-W3C event emitting - // doesn't support custom event types). It should work with all events registered - // through dojo/on. Also note that the emit method does do any default - // action, it only returns a value to indicate if the default action should take - // place. For example, emitting a keypress event would not cause a character - // to appear in a textbox. - // example: - // To fire our own click event - // | require(["dojo/on", "dojo/dom" - // | ], function(on, dom){ - // | on.emit(dom.byId("button"), "click", { - // | cancelable: true, - // | bubbles: true, - // | screenX: 33, - // | screenY: 44 - // | }); - // We can also fire our own custom events: - // | on.emit(dom.byId("slider"), "slide", { - // | cancelable: true, - // | bubbles: true, - // | direction: "left-to-right" - // | }); - // | }); - var args = slice.call(arguments, 2); - var method = "on" + type; - if("parentNode" in target){ - // node (or node-like), create event controller methods - var newEvent = args[0] = {}; - for(var i in event){ - newEvent[i] = event[i]; - } - newEvent.preventDefault = syntheticPreventDefault; - newEvent.stopPropagation = syntheticStopPropagation; - newEvent.target = target; - newEvent.type = type; - event = newEvent; - } - do{ - // call any node which has a handler (note that ideally we would try/catch to simulate normal event propagation but that causes too much pain for debugging) - target[method] && target[method].apply(target, args); - // and then continue up the parent node chain if it is still bubbling (if started as bubbles and stopPropagation hasn't been called) - }while(event && event.bubbles && (target = target.parentNode)); - return event && event.cancelable && event; // if it is still true (was cancelable and was cancelled), return the event to indicate default action should happen - }; - var captures = has("event-focusin") ? {} : {focusin: "focus", focusout: "blur"}; - if(!has("event-stopimmediatepropagation")){ - var stopImmediatePropagation =function(){ - this.immediatelyStopped = true; - this.modified = true; // mark it as modified so the event will be cached in IE - }; - var addStopImmediate = function(listener){ - return function(event){ - if(!event.immediatelyStopped){// check to make sure it hasn't been stopped immediately - event.stopImmediatePropagation = stopImmediatePropagation; - return listener.apply(this, arguments); - } - }; - } - } - if(has("dom-addeventlistener")){ - // emitter that works with native event handling - on.emit = function(target, type, event){ - if(target.dispatchEvent && document.createEvent){ - // use the native event emitting mechanism if it is available on the target object - // create a generic event - // we could create branch into the different types of event constructors, but - // that would be a lot of extra code, with little benefit that I can see, seems - // best to use the generic constructor and copy properties over, making it - // easy to have events look like the ones created with specific initializers - var ownerDocument = target.ownerDocument || document; - var nativeEvent = ownerDocument.createEvent("HTMLEvents"); - nativeEvent.initEvent(type, !!event.bubbles, !!event.cancelable); - // and copy all our properties over - for(var i in event){ - if(!(i in nativeEvent)){ - nativeEvent[i] = event[i]; - } - } - return target.dispatchEvent(nativeEvent) && nativeEvent; - } - return syntheticDispatch.apply(on, arguments); // emit for a non-node - }; - }else{ - // no addEventListener, basically old IE event normalization - on._fixEvent = function(evt, sender){ - // summary: - // normalizes properties on the event object including event - // bubbling methods, keystroke normalization, and x/y positions - // evt: - // native event object - // sender: - // node to treat as "currentTarget" - if(!evt){ - var w = sender && (sender.ownerDocument || sender.document || sender).parentWindow || window; - evt = w.event; - } - if(!evt){return evt;} - try{ - if(lastEvent && evt.type == lastEvent.type && evt.srcElement == lastEvent.target){ - // should be same event, reuse event object (so it can be augmented); - // accessing evt.srcElement rather than evt.target since evt.target not set on IE until fixup below - evt = lastEvent; - } - }catch(e){ - // will occur on IE on lastEvent.type reference if lastEvent points to a previous event that already - // finished bubbling, but the setTimeout() to clear lastEvent hasn't fired yet - } - if(!evt.target){ // check to see if it has been fixed yet - evt.target = evt.srcElement; - evt.currentTarget = (sender || evt.srcElement); - if(evt.type == "mouseover"){ - evt.relatedTarget = evt.fromElement; - } - if(evt.type == "mouseout"){ - evt.relatedTarget = evt.toElement; - } - if(!evt.stopPropagation){ - evt.stopPropagation = stopPropagation; - evt.preventDefault = preventDefault; - } - switch(evt.type){ - case "keypress": - var c = ("charCode" in evt ? evt.charCode : evt.keyCode); - if (c==10){ - // CTRL-ENTER is CTRL-ASCII(10) on IE, but CTRL-ENTER on Mozilla - c=0; - evt.keyCode = 13; - }else if(c==13||c==27){ - c=0; // Mozilla considers ENTER and ESC non-printable - }else if(c==3){ - c=99; // Mozilla maps CTRL-BREAK to CTRL-c - } - // Mozilla sets keyCode to 0 when there is a charCode - // but that stops the event on IE. - evt.charCode = c; - _setKeyChar(evt); - break; - } - } - return evt; - }; - var lastEvent, IESignal = function(handle){ - this.handle = handle; - }; - IESignal.prototype.remove = function(){ - delete _dojoIEListeners_[this.handle]; - }; - var fixListener = function(listener){ - // this is a minimal function for closing on the previous listener with as few as variables as possible - return function(evt){ - evt = on._fixEvent(evt, this); - var result = listener.call(this, evt); - if(evt.modified){ - // cache the last event and reuse it if we can - if(!lastEvent){ - setTimeout(function(){ - lastEvent = null; - }); - } - lastEvent = evt; - } - return result; - }; - }; - var fixAttach = function(target, type, listener){ - listener = fixListener(listener); - if(((target.ownerDocument ? target.ownerDocument.parentWindow : target.parentWindow || target.window || window) != top || - has("jscript") < 5.8) && - !has("config-_allow_leaks")){ - // IE will leak memory on certain handlers in frames (IE8 and earlier) and in unattached DOM nodes for JScript 5.7 and below. - // Here we use global redirection to solve the memory leaks - if(typeof _dojoIEListeners_ == "undefined"){ - _dojoIEListeners_ = []; - } - var emitter = target[type]; - if(!emitter || !emitter.listeners){ - var oldListener = emitter; - emitter = Function('event', 'var callee = arguments.callee; for(var i = 0; i<callee.listeners.length; i++){var listener = _dojoIEListeners_[callee.listeners[i]]; if(listener){listener.call(this,event);}}'); - emitter.listeners = []; - target[type] = emitter; - emitter.global = this; - if(oldListener){ - emitter.listeners.push(_dojoIEListeners_.push(oldListener) - 1); - } - } - var handle; - emitter.listeners.push(handle = (emitter.global._dojoIEListeners_.push(listener) - 1)); - return new IESignal(handle); - } - return aspect.after(target, type, listener, true); - }; - - var _setKeyChar = function(evt){ - evt.keyChar = evt.charCode ? String.fromCharCode(evt.charCode) : ''; - evt.charOrCode = evt.keyChar || evt.keyCode; // TODO: remove for 2.0 - }; - // Called in Event scope - var stopPropagation = function(){ - this.cancelBubble = true; - }; - var preventDefault = on._preventDefault = function(){ - // Setting keyCode to 0 is the only way to prevent certain keypresses (namely - // ctrl-combinations that correspond to menu accelerator keys). - // Otoh, it prevents upstream listeners from getting this information - // Try to split the difference here by clobbering keyCode only for ctrl - // combinations. If you still need to access the key upstream, bubbledKeyCode is - // provided as a workaround. - this.bubbledKeyCode = this.keyCode; - if(this.ctrlKey){ - try{ - // squelch errors when keyCode is read-only - // (e.g. if keyCode is ctrl or shift) - this.keyCode = 0; - }catch(e){ - } - } - this.defaultPrevented = true; - this.returnValue = false; - this.modified = true; // mark it as modified (for defaultPrevented flag) so the event will be cached in IE - }; - } - if(has("touch")){ - var Event = function(){}; - var windowOrientation = window.orientation; - var fixTouchListener = function(listener){ - return function(originalEvent){ - //Event normalization(for ontouchxxx and resize): - //1.incorrect e.pageX|pageY in iOS - //2.there are no "e.rotation", "e.scale" and "onorientationchange" in Android - //3.More TBD e.g. force | screenX | screenX | clientX | clientY | radiusX | radiusY - - // see if it has already been corrected - var event = originalEvent.corrected; - if(!event){ - var type = originalEvent.type; - try{ - delete originalEvent.type; // on some JS engines (android), deleting properties make them mutable - }catch(e){} - if(originalEvent.type){ - // deleting properties doesn't work (older iOS), have to use delegation - if(has('mozilla')){ - // Firefox doesn't like delegated properties, so we have to copy - var event = {}; - for(var name in originalEvent){ - event[name] = originalEvent[name]; - } - }else{ - // old iOS branch - Event.prototype = originalEvent; - var event = new Event; - } - // have to delegate methods to make them work - event.preventDefault = function(){ - originalEvent.preventDefault(); - }; - event.stopPropagation = function(){ - originalEvent.stopPropagation(); - }; - }else{ - // deletion worked, use property as is - event = originalEvent; - event.type = type; - } - originalEvent.corrected = event; - if(type == 'resize'){ - if(windowOrientation == window.orientation){ - return null;//double tap causes an unexpected 'resize' in Android - } - windowOrientation = window.orientation; - event.type = "orientationchange"; - return listener.call(this, event); - } - // We use the original event and augment, rather than doing an expensive mixin operation - if(!("rotation" in event)){ // test to see if it has rotation - event.rotation = 0; - event.scale = 1; - } - //use event.changedTouches[0].pageX|pageY|screenX|screenY|clientX|clientY|target - var firstChangeTouch = event.changedTouches[0]; - for(var i in firstChangeTouch){ // use for-in, we don't need to have dependency on dojo/_base/lang here - delete event[i]; // delete it first to make it mutable - event[i] = firstChangeTouch[i]; - } - } - return listener.call(this, event); - }; - }; - } - return on; -}); diff --git a/lib/dojo/on/asyncEventListener.js b/lib/dojo/on/asyncEventListener.js deleted file mode 100644 index e6e3bc0..0000000 --- a/lib/dojo/on/asyncEventListener.js +++ /dev/null @@ -1,38 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/on/asyncEventListener",["dojo/on","dojo/_base/window","dojo/dom-construct","dojo/domReady!"],function(on,_1,_2){ -var _3=_2.create("div",null,_1.body()),_4,_5; -on.once(_3,"click",function(e){ -_4=e; -}); -_3.click(); -try{ -_5=_4.clientX===undefined; -} -catch(e){ -_5=true; -} -finally{ -_2.destroy(_3); -} -function _6(_7){ -var _8={},i; -for(i in _7){ -_8[i]=_7[i]; -} -return _8; -}; -return function(_9){ -if(_5){ -return function(e){ -_9.call(this,_6(e)); -}; -} -return _9; -}; -}); diff --git a/lib/dojo/on/asyncEventListener.js.uncompressed.js b/lib/dojo/on/asyncEventListener.js.uncompressed.js deleted file mode 100644 index 8872f81..0000000 --- a/lib/dojo/on/asyncEventListener.js.uncompressed.js +++ /dev/null @@ -1,48 +0,0 @@ -define("dojo/on/asyncEventListener", ['dojo/on', 'dojo/_base/window', 'dojo/dom-construct', 'dojo/domReady!'], function(on, baseWin, domConstruct){ - // summary: - // This sub module provide an event factory for delayed events (like debounce or throttle) - // module: - // dojo/on/asyncEventListener - - - //Testing is the browser support async event access - //If not we need to clone the event, otherwise accessing the event properties - //will trigger a JS error (invalid member) - var testNode = domConstruct.create('div', null, baseWin.body()), - testEvent, - requiresClone; - on.once(testNode, 'click', function(e){ - testEvent = e; - }); - testNode.click(); - try{ - requiresClone = testEvent.clientX === undefined; - }catch(e){ - requiresClone = true; - }finally{ - domConstruct.destroy(testNode); - } - - function clone(arg){ - // summary: - // clone the event - // description: - // Used if the browser provides a corrupted event (comming from a node) when passed to an async function - var argCopy = {}, - i; - for(i in arg){ - argCopy[i] = arg[i]; - } - return argCopy; - } - - return function(listener){ - if(requiresClone){ - return function(e){ - //lang.clone fail to clone events, so we use a custom function - listener.call(this, clone(e)); - }; - } - return listener; - }; -}); diff --git a/lib/dojo/on/debounce.js b/lib/dojo/on/debounce.js deleted file mode 100644 index 933d2a1..0000000 --- a/lib/dojo/on/debounce.js +++ /dev/null @@ -1,14 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/on/debounce",["dojo/debounce","dojo/on","dojo/on/asyncEventListener"],function(_1,on,_2){ -return function(_3,_4){ -return function(_5,_6){ -return on(_5,_3,_2(_1(_6,_4))); -}; -}; -}); diff --git a/lib/dojo/on/debounce.js.uncompressed.js b/lib/dojo/on/debounce.js.uncompressed.js deleted file mode 100644 index 0f24683..0000000 --- a/lib/dojo/on/debounce.js.uncompressed.js +++ /dev/null @@ -1,19 +0,0 @@ -define("dojo/on/debounce", ['dojo/debounce', 'dojo/on', 'dojo/on/asyncEventListener'], function(debounce, on, asyncEventListener){ - // summary: - // This module provides an event debouncer for dojo/on - // module: - // dojo/on/debounce - - return function(selector, delay){ - // summary: - // event parser for custom events - // selector: String - // The selector to check against - // delay: Interger - // The amount of ms before testing the selector - - return function(node, listenerFnc){ - return on(node, selector, asyncEventListener(debounce(listenerFnc, delay))); - }; - }; -}); diff --git a/lib/dojo/on/throttle.js b/lib/dojo/on/throttle.js deleted file mode 100644 index e012b6f..0000000 --- a/lib/dojo/on/throttle.js +++ /dev/null @@ -1,14 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/on/throttle",["dojo/throttle","dojo/on"],function(_1,on){ -return function(_2,_3){ -return function(_4,_5){ -return on(_4,_2,_1(_5,_3)); -}; -}; -}); diff --git a/lib/dojo/on/throttle.js.uncompressed.js b/lib/dojo/on/throttle.js.uncompressed.js deleted file mode 100644 index f8e3691..0000000 --- a/lib/dojo/on/throttle.js.uncompressed.js +++ /dev/null @@ -1,19 +0,0 @@ -define("dojo/on/throttle", ['dojo/throttle', 'dojo/on'], function(throttle, on){ - // summary: - // This module provides an event throttler for dojo/on - // module: - // dojo/on/throttle - - return function(selector, delay){ - // summary: - // event parser for custom events - // selector: String - // The selector to check against - // delay: Interger - // The amount of ms before testing the selector - - return function(node, listenerFnc){ - return on(node, selector, throttle(listenerFnc, delay)); - }; - }; -}); diff --git a/lib/dojo/package.json b/lib/dojo/package.json deleted file mode 100644 index 5e728aa..0000000 --- a/lib/dojo/package.json +++ /dev/null @@ -1,23 +0,0 @@ -{ - "name": "dojo", - "version":"1.10.0", - "directories": { - "lib": "." - }, - "main": "main", - "description": "Dojo core is a powerful, lightweight library that makes common tasks quicker and easier. Animate elements, manipulate the DOM, and query with easy CSS syntax, all without sacrificing performance.", - "licenses": [ - { - "type": "AFLv2.1", - "url": "http://trac.dojotoolkit.org/browser/dojo/trunk/LICENSE#L43" - }, - { - "type": "BSD", - "url": "http://trac.dojotoolkit.org/browser/dojo/trunk/LICENSE#L13" - } - ], - "bugs": "http://bugs.dojotoolkit.org/", - "keywords": ["JavaScript", "Dojo", "Toolkit"], - "homepage": "http://dojotoolkit.org/", - "dojoBuild": "dojo.profile.js" -} diff --git a/lib/dojo/parser.js b/lib/dojo/parser.js deleted file mode 100644 index c497ba6..0000000 --- a/lib/dojo/parser.js +++ /dev/null @@ -1,445 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/parser",["require","./_base/kernel","./_base/lang","./_base/array","./_base/config","./dom","./_base/window","./_base/url","./aspect","./promise/all","./date/stamp","./Deferred","./has","./query","./on","./ready"],function(_1,_2,_3,_4,_5,_6,_7,_8,_9,_a,_b,_c,_d,_e,_f,_10){ -new Date("X"); -function _11(_12){ -return eval("("+_12+")"); -}; -var _13=0; -_9.after(_3,"extend",function(){ -_13++; -},true); -function _14(_15){ -var map=_15._nameCaseMap,_16=_15.prototype; -if(!map||map._extendCnt<_13){ -map=_15._nameCaseMap={}; -for(var _17 in _16){ -if(_17.charAt(0)==="_"){ -continue; -} -map[_17.toLowerCase()]=_17; -} -map._extendCnt=_13; -} -return map; -}; -var _18={}; -function _19(_1a,_1b){ -var ts=_1a.join(); -if(!_18[ts]){ -var _1c=[]; -for(var i=0,l=_1a.length;i<l;i++){ -var t=_1a[i]; -_1c[_1c.length]=(_18[t]=_18[t]||(_3.getObject(t)||(~t.indexOf("/")&&(_1b?_1b(t):_1(t))))); -} -var _1d=_1c.shift(); -_18[ts]=_1c.length?(_1d.createSubclass?_1d.createSubclass(_1c):_1d.extend.apply(_1d,_1c)):_1d; -} -return _18[ts]; -}; -var _1e={_clearCache:function(){ -_13++; -_18={}; -},_functionFromScript:function(_1f,_20){ -var _21="",_22="",_23=(_1f.getAttribute(_20+"args")||_1f.getAttribute("args")),_24=_1f.getAttribute("with"); -var _25=(_23||"").split(/\s*,\s*/); -if(_24&&_24.length){ -_4.forEach(_24.split(/\s*,\s*/),function(_26){ -_21+="with("+_26+"){"; -_22+="}"; -}); -} -return new Function(_25,_21+_1f.innerHTML+_22); -},instantiate:function(_27,_28,_29){ -_28=_28||{}; -_29=_29||{}; -var _2a=(_29.scope||_2._scopeName)+"Type",_2b="data-"+(_29.scope||_2._scopeName)+"-",_2c=_2b+"type",_2d=_2b+"mixins"; -var _2e=[]; -_4.forEach(_27,function(_2f){ -var _30=_2a in _28?_28[_2a]:_2f.getAttribute(_2c)||_2f.getAttribute(_2a); -if(_30){ -var _31=_2f.getAttribute(_2d),_32=_31?[_30].concat(_31.split(/\s*,\s*/)):[_30]; -_2e.push({node:_2f,types:_32}); -} -}); -return this._instantiate(_2e,_28,_29); -},_instantiate:function(_33,_34,_35,_36){ -var _37=_4.map(_33,function(obj){ -var _38=obj.ctor||_19(obj.types,_35.contextRequire); -if(!_38){ -throw new Error("Unable to resolve constructor for: '"+obj.types.join()+"'"); -} -return this.construct(_38,obj.node,_34,_35,obj.scripts,obj.inherited); -},this); -function _39(_3a){ -if(!_34._started&&!_35.noStart){ -_4.forEach(_3a,function(_3b){ -if(typeof _3b.startup==="function"&&!_3b._started){ -_3b.startup(); -} -}); -} -return _3a; -}; -if(_36){ -return _a(_37).then(_39); -}else{ -return _39(_37); -} -},construct:function(_3c,_3d,_3e,_3f,_40,_41){ -var _42=_3c&&_3c.prototype; -_3f=_3f||{}; -var _43={}; -if(_3f.defaults){ -_3.mixin(_43,_3f.defaults); -} -if(_41){ -_3.mixin(_43,_41); -} -var _44; -if(_d("dom-attributes-explicit")){ -_44=_3d.attributes; -}else{ -if(_d("dom-attributes-specified-flag")){ -_44=_4.filter(_3d.attributes,function(a){ -return a.specified; -}); -}else{ -var _45=/^input$|^img$/i.test(_3d.nodeName)?_3d:_3d.cloneNode(false),_46=_45.outerHTML.replace(/=[^\s"']+|="[^"]*"|='[^']*'/g,"").replace(/^\s*<[a-zA-Z0-9]*\s*/,"").replace(/\s*>.*$/,""); -_44=_4.map(_46.split(/\s+/),function(_47){ -var _48=_47.toLowerCase(); -return {name:_47,value:(_3d.nodeName=="LI"&&_47=="value")||_48=="enctype"?_3d.getAttribute(_48):_3d.getAttributeNode(_48).value}; -}); -} -} -var _49=_3f.scope||_2._scopeName,_4a="data-"+_49+"-",_4b={}; -if(_49!=="dojo"){ -_4b[_4a+"props"]="data-dojo-props"; -_4b[_4a+"type"]="data-dojo-type"; -_4b[_4a+"mixins"]="data-dojo-mixins"; -_4b[_49+"type"]="dojoType"; -_4b[_4a+"id"]="data-dojo-id"; -} -var i=0,_4c,_4d=[],_4e,_4f; -while(_4c=_44[i++]){ -var _50=_4c.name,_51=_50.toLowerCase(),_52=_4c.value; -switch(_4b[_51]||_51){ -case "data-dojo-type": -case "dojotype": -case "data-dojo-mixins": -break; -case "data-dojo-props": -_4f=_52; -break; -case "data-dojo-id": -case "jsid": -_4e=_52; -break; -case "data-dojo-attach-point": -case "dojoattachpoint": -_43.dojoAttachPoint=_52; -break; -case "data-dojo-attach-event": -case "dojoattachevent": -_43.dojoAttachEvent=_52; -break; -case "class": -_43["class"]=_3d.className; -break; -case "style": -_43["style"]=_3d.style&&_3d.style.cssText; -break; -default: -if(!(_50 in _42)){ -var map=_14(_3c); -_50=map[_51]||_50; -} -if(_50 in _42){ -switch(typeof _42[_50]){ -case "string": -_43[_50]=_52; -break; -case "number": -_43[_50]=_52.length?Number(_52):NaN; -break; -case "boolean": -_43[_50]=_52.toLowerCase()!="false"; -break; -case "function": -if(_52===""||_52.search(/[^\w\.]+/i)!=-1){ -_43[_50]=new Function(_52); -}else{ -_43[_50]=_3.getObject(_52,false)||new Function(_52); -} -_4d.push(_50); -break; -default: -var _53=_42[_50]; -_43[_50]=(_53&&"length" in _53)?(_52?_52.split(/\s*,\s*/):[]):(_53 instanceof Date)?(_52==""?new Date(""):_52=="now"?new Date():_b.fromISOString(_52)):(_53 instanceof _8)?(_2.baseUrl+_52):_11(_52); -} -}else{ -_43[_50]=_52; -} -} -} -for(var j=0;j<_4d.length;j++){ -var _54=_4d[j].toLowerCase(); -_3d.removeAttribute(_54); -_3d[_54]=null; -} -if(_4f){ -try{ -_4f=_11.call(_3f.propsThis,"{"+_4f+"}"); -_3.mixin(_43,_4f); -} -catch(e){ -throw new Error(e.toString()+" in data-dojo-props='"+_4f+"'"); -} -} -_3.mixin(_43,_3e); -if(!_40){ -_40=(_3c&&(_3c._noScript||_42._noScript)?[]:_e("> script[type^='dojo/']",_3d)); -} -var _55=[],_56=[],_57=[],ons=[]; -if(_40){ -for(i=0;i<_40.length;i++){ -var _58=_40[i]; -_3d.removeChild(_58); -var _59=(_58.getAttribute(_4a+"event")||_58.getAttribute("event")),_5a=_58.getAttribute(_4a+"prop"),_5b=_58.getAttribute(_4a+"method"),_5c=_58.getAttribute(_4a+"advice"),_5d=_58.getAttribute("type"),nf=this._functionFromScript(_58,_4a); -if(_59){ -if(_5d=="dojo/connect"){ -_55.push({method:_59,func:nf}); -}else{ -if(_5d=="dojo/on"){ -ons.push({event:_59,func:nf}); -}else{ -_43[_59]=nf; -} -} -}else{ -if(_5d=="dojo/aspect"){ -_55.push({method:_5b,advice:_5c,func:nf}); -}else{ -if(_5d=="dojo/watch"){ -_57.push({prop:_5a,func:nf}); -}else{ -_56.push(nf); -} -} -} -} -} -var _5e=_3c.markupFactory||_42.markupFactory; -var _5f=_5e?_5e(_43,_3d,_3c):new _3c(_43,_3d); -function _60(_61){ -if(_4e){ -_3.setObject(_4e,_61); -} -for(i=0;i<_55.length;i++){ -_9[_55[i].advice||"after"](_61,_55[i].method,_3.hitch(_61,_55[i].func),true); -} -for(i=0;i<_56.length;i++){ -_56[i].call(_61); -} -for(i=0;i<_57.length;i++){ -_61.watch(_57[i].prop,_57[i].func); -} -for(i=0;i<ons.length;i++){ -_f(_61,ons[i].event,ons[i].func); -} -return _61; -}; -if(_5f.then){ -return _5f.then(_60); -}else{ -return _60(_5f); -} -},scan:function(_62,_63){ -var _64=[],_65=[],_66={}; -var _67=(_63.scope||_2._scopeName)+"Type",_68="data-"+(_63.scope||_2._scopeName)+"-",_69=_68+"type",_6a=_68+"textdir",_6b=_68+"mixins"; -var _6c=_62.firstChild; -var _6d=_63.inherited; -if(!_6d){ -function _6e(_6f,_70){ -return (_6f.getAttribute&&_6f.getAttribute(_70))||(_6f.parentNode&&_6e(_6f.parentNode,_70)); -}; -_6d={dir:_6e(_62,"dir"),lang:_6e(_62,"lang"),textDir:_6e(_62,_6a)}; -for(var key in _6d){ -if(!_6d[key]){ -delete _6d[key]; -} -} -} -var _71={inherited:_6d}; -var _72; -var _73; -function _74(_75){ -if(!_75.inherited){ -_75.inherited={}; -var _76=_75.node,_77=_74(_75.parent); -var _78={dir:_76.getAttribute("dir")||_77.dir,lang:_76.getAttribute("lang")||_77.lang,textDir:_76.getAttribute(_6a)||_77.textDir}; -for(var key in _78){ -if(_78[key]){ -_75.inherited[key]=_78[key]; -} -} -} -return _75.inherited; -}; -while(true){ -if(!_6c){ -if(!_71||!_71.node){ -break; -} -_6c=_71.node.nextSibling; -_73=false; -_71=_71.parent; -_72=_71.scripts; -continue; -} -if(_6c.nodeType!=1){ -_6c=_6c.nextSibling; -continue; -} -if(_72&&_6c.nodeName.toLowerCase()=="script"){ -_79=_6c.getAttribute("type"); -if(_79&&/^dojo\/\w/i.test(_79)){ -_72.push(_6c); -} -_6c=_6c.nextSibling; -continue; -} -if(_73){ -_6c=_6c.nextSibling; -continue; -} -var _79=_6c.getAttribute(_69)||_6c.getAttribute(_67); -var _7a=_6c.firstChild; -if(!_79&&(!_7a||(_7a.nodeType==3&&!_7a.nextSibling))){ -_6c=_6c.nextSibling; -continue; -} -var _7b; -var _7c=null; -if(_79){ -var _7d=_6c.getAttribute(_6b),_7e=_7d?[_79].concat(_7d.split(/\s*,\s*/)):[_79]; -try{ -_7c=_19(_7e,_63.contextRequire); -} -catch(e){ -} -if(!_7c){ -_4.forEach(_7e,function(t){ -if(~t.indexOf("/")&&!_66[t]){ -_66[t]=true; -_65[_65.length]=t; -} -}); -} -var _7f=_7c&&!_7c.prototype._noScript?[]:null; -_7b={types:_7e,ctor:_7c,parent:_71,node:_6c,scripts:_7f}; -_7b.inherited=_74(_7b); -_64.push(_7b); -}else{ -_7b={node:_6c,scripts:_72,parent:_71}; -} -_72=_7f; -_73=_6c.stopParser||(_7c&&_7c.prototype.stopParser&&!(_63.template)); -_71=_7b; -_6c=_7a; -} -var d=new _c(); -if(_65.length){ -if(_d("dojo-debug-messages")){ -console.warn("WARNING: Modules being Auto-Required: "+_65.join(", ")); -} -var r=_63.contextRequire||_1; -r(_65,function(){ -d.resolve(_4.filter(_64,function(_80){ -if(!_80.ctor){ -try{ -_80.ctor=_19(_80.types,_63.contextRequire); -} -catch(e){ -} -} -var _81=_80.parent; -while(_81&&!_81.types){ -_81=_81.parent; -} -var _82=_80.ctor&&_80.ctor.prototype; -_80.instantiateChildren=!(_82&&_82.stopParser&&!(_63.template)); -_80.instantiate=!_81||(_81.instantiate&&_81.instantiateChildren); -return _80.instantiate; -})); -}); -}else{ -d.resolve(_64); -} -return d.promise; -},_require:function(_83,_84){ -var _85=_11("{"+_83.innerHTML+"}"),_86=[],_87=[],d=new _c(); -var _88=(_84&&_84.contextRequire)||_1; -for(var _89 in _85){ -_86.push(_89); -_87.push(_85[_89]); -} -_88(_87,function(){ -for(var i=0;i<_86.length;i++){ -_3.setObject(_86[i],arguments[i]); -} -d.resolve(arguments); -}); -return d.promise; -},_scanAmd:function(_8a,_8b){ -var _8c=new _c(),_8d=_8c.promise; -_8c.resolve(true); -var _8e=this; -_e("script[type='dojo/require']",_8a).forEach(function(_8f){ -_8d=_8d.then(function(){ -return _8e._require(_8f,_8b); -}); -_8f.parentNode.removeChild(_8f); -}); -return _8d; -},parse:function(_90,_91){ -var _92; -if(!_91&&_90&&_90.rootNode){ -_91=_90; -_92=_91.rootNode; -}else{ -if(_90&&_3.isObject(_90)&&!("nodeType" in _90)){ -_91=_90; -}else{ -_92=_90; -} -} -_92=_92?_6.byId(_92):_7.body(); -_91=_91||{}; -var _93=_91.template?{template:true}:{},_94=[],_95=this; -var p=this._scanAmd(_92,_91).then(function(){ -return _95.scan(_92,_91); -}).then(function(_96){ -return _95._instantiate(_96,_93,_91,true); -}).then(function(_97){ -return _94=_94.concat(_97); -}).otherwise(function(e){ -console.error("dojo/parser::parse() error",e); -throw e; -}); -_3.mixin(_94,p); -return _94; -}}; -if(1){ -_2.parser=_1e; -} -if(_5.parseOnLoad){ -_10(100,_1e,"parse"); -} -return _1e; -}); diff --git a/lib/dojo/parser.js.uncompressed.js b/lib/dojo/parser.js.uncompressed.js deleted file mode 100644 index 13d01cb..0000000 --- a/lib/dojo/parser.js.uncompressed.js +++ /dev/null @@ -1,920 +0,0 @@ -define("dojo/parser", [ - "require", "./_base/kernel", "./_base/lang", "./_base/array", "./_base/config", "./dom", "./_base/window", - "./_base/url", "./aspect", "./promise/all", "./date/stamp", "./Deferred", "./has", "./query", "./on", "./ready" -], function(require, dojo, dlang, darray, config, dom, dwindow, _Url, aspect, all, dates, Deferred, has, query, don, ready){ - - // module: - // dojo/parser - - new Date("X"); // workaround for #11279, new Date("") == NaN - - // data-dojo-props etc. is not restricted to JSON, it can be any javascript - function myEval(text){ - return eval("(" + text + ")"); - } - - // Widgets like BorderContainer add properties to _Widget via dojo.extend(). - // If BorderContainer is loaded after _Widget's parameter list has been cached, - // we need to refresh that parameter list (for _Widget and all widgets that extend _Widget). - var extendCnt = 0; - aspect.after(dlang, "extend", function(){ - extendCnt++; - }, true); - - function getNameMap(ctor){ - // summary: - // Returns map from lowercase name to attribute name in class, ex: {onclick: "onClick"} - var map = ctor._nameCaseMap, proto = ctor.prototype; - - // Create the map if it's undefined. - // Refresh the map if a superclass was possibly extended with new methods since the map was created. - if(!map || map._extendCnt < extendCnt){ - map = ctor._nameCaseMap = {}; - for(var name in proto){ - if(name.charAt(0) === "_"){ - continue; - } // skip internal properties - map[name.toLowerCase()] = name; - } - map._extendCnt = extendCnt; - } - return map; - } - - // Map from widget name or list of widget names(ex: "dijit/form/Button,acme/MyMixin") to a constructor. - var _ctorMap = {}; - - function getCtor(/*String[]*/ types, /*Function?*/ contextRequire){ - // summary: - // Retrieves a constructor. If the types array contains more than one class/MID then the - // subsequent classes will be mixed into the first class and a unique constructor will be - // returned for that array. - - var ts = types.join(); - if(!_ctorMap[ts]){ - var mixins = []; - for(var i = 0, l = types.length; i < l; i++){ - var t = types[i]; - // TODO: Consider swapping getObject and require in the future - mixins[mixins.length] = (_ctorMap[t] = _ctorMap[t] || (dlang.getObject(t) || (~t.indexOf('/') && - (contextRequire ? contextRequire(t) : require(t))))); - } - var ctor = mixins.shift(); - _ctorMap[ts] = mixins.length ? (ctor.createSubclass ? ctor.createSubclass(mixins) : ctor.extend.apply(ctor, mixins)) : ctor; - } - - return _ctorMap[ts]; - } - - var parser = { - // summary: - // The Dom/Widget parsing package - - _clearCache: function(){ - // summary: - // Clear cached data. Used mainly for benchmarking. - extendCnt++; - _ctorMap = {}; - }, - - _functionFromScript: function(script, attrData){ - // summary: - // Convert a `<script type="dojo/method" args="a, b, c"> ... </script>` - // into a function - // script: DOMNode - // The `<script>` DOMNode - // attrData: String - // For HTML5 compliance, searches for attrData + "args" (typically - // "data-dojo-args") instead of "args" - var preamble = "", - suffix = "", - argsStr = (script.getAttribute(attrData + "args") || script.getAttribute("args")), - withStr = script.getAttribute("with"); - - // Convert any arguments supplied in script tag into an array to be passed to the - var fnArgs = (argsStr || "").split(/\s*,\s*/); - - if(withStr && withStr.length){ - darray.forEach(withStr.split(/\s*,\s*/), function(part){ - preamble += "with(" + part + "){"; - suffix += "}"; - }); - } - - return new Function(fnArgs, preamble + script.innerHTML + suffix); - }, - - instantiate: function(nodes, mixin, options){ - // summary: - // Takes array of nodes, and turns them into class instances and - // potentially calls a startup method to allow them to connect with - // any children. - // nodes: Array - // Array of DOM nodes - // mixin: Object? - // An object that will be mixed in with each node in the array. - // Values in the mixin will override values in the node, if they - // exist. - // options: Object? - // An object used to hold kwArgs for instantiation. - // See parse.options argument for details. - // returns: - // Array of instances. - - mixin = mixin || {}; - options = options || {}; - - var dojoType = (options.scope || dojo._scopeName) + "Type", // typically "dojoType" - attrData = "data-" + (options.scope || dojo._scopeName) + "-", // typically "data-dojo-" - dataDojoType = attrData + "type", // typically "data-dojo-type" - dataDojoMixins = attrData + "mixins"; // typically "data-dojo-mixins" - - var list = []; - darray.forEach(nodes, function(node){ - var type = dojoType in mixin ? mixin[dojoType] : node.getAttribute(dataDojoType) || node.getAttribute(dojoType); - if(type){ - var mixinsValue = node.getAttribute(dataDojoMixins), - types = mixinsValue ? [type].concat(mixinsValue.split(/\s*,\s*/)) : [type]; - - list.push({ - node: node, - types: types - }); - } - }); - - // Instantiate the nodes and return the list of instances. - return this._instantiate(list, mixin, options); - }, - - _instantiate: function(nodes, mixin, options, returnPromise){ - // summary: - // Takes array of objects representing nodes, and turns them into class instances and - // potentially calls a startup method to allow them to connect with - // any children. - // nodes: Array - // Array of objects like - // | { - // | ctor: Function (may be null) - // | types: ["dijit/form/Button", "acme/MyMixin"] (used if ctor not specified) - // | node: DOMNode, - // | scripts: [ ... ], // array of <script type="dojo/..."> children of node - // | inherited: { ... } // settings inherited from ancestors like dir, theme, etc. - // | } - // mixin: Object - // An object that will be mixed in with each node in the array. - // Values in the mixin will override values in the node, if they - // exist. - // options: Object - // An options object used to hold kwArgs for instantiation. - // See parse.options argument for details. - // returnPromise: Boolean - // Return a Promise rather than the instance; supports asynchronous widget creation. - // returns: - // Array of instances, or if returnPromise is true, a promise for array of instances - // that resolves when instances have finished initializing. - - // Call widget constructors. Some may be asynchronous and return promises. - var thelist = darray.map(nodes, function(obj){ - var ctor = obj.ctor || getCtor(obj.types, options.contextRequire); - // If we still haven't resolved a ctor, it is fatal now - if(!ctor){ - throw new Error("Unable to resolve constructor for: '" + obj.types.join() + "'"); - } - return this.construct(ctor, obj.node, mixin, options, obj.scripts, obj.inherited); - }, this); - - // After all widget construction finishes, call startup on each top level instance if it makes sense (as for - // widgets). Parent widgets will recursively call startup on their (non-top level) children - function onConstruct(thelist){ - if(!mixin._started && !options.noStart){ - darray.forEach(thelist, function(instance){ - if(typeof instance.startup === "function" && !instance._started){ - instance.startup(); - } - }); - } - - return thelist; - } - - if(returnPromise){ - return all(thelist).then(onConstruct); - }else{ - // Back-compat path, remove for 2.0 - return onConstruct(thelist); - } - }, - - construct: function(ctor, node, mixin, options, scripts, inherited){ - // summary: - // Calls new ctor(params, node), where params is the hash of parameters specified on the node, - // excluding data-dojo-type and data-dojo-mixins. Does not call startup(). - // ctor: Function - // Widget constructor. - // node: DOMNode - // This node will be replaced/attached to by the widget. It also specifies the arguments to pass to ctor. - // mixin: Object? - // Attributes in this object will be passed as parameters to ctor, - // overriding attributes specified on the node. - // options: Object? - // An options object used to hold kwArgs for instantiation. See parse.options argument for details. - // scripts: DomNode[]? - // Array of `<script type="dojo/*">` DOMNodes. If not specified, will search for `<script>` tags inside node. - // inherited: Object? - // Settings from dir=rtl or lang=... on a node above this node. Overrides options.inherited. - // returns: - // Instance or Promise for the instance, if markupFactory() itself returned a promise - - var proto = ctor && ctor.prototype; - options = options || {}; - - // Setup hash to hold parameter settings for this widget. Start with the parameter - // settings inherited from ancestors ("dir" and "lang"). - // Inherited setting may later be overridden by explicit settings on node itself. - var params = {}; - - if(options.defaults){ - // settings for the document itself (or whatever subtree is being parsed) - dlang.mixin(params, options.defaults); - } - if(inherited){ - // settings from dir=rtl or lang=... on a node above this node - dlang.mixin(params, inherited); - } - - // Get list of attributes explicitly listed in the markup - var attributes; - if(has("dom-attributes-explicit")){ - // Standard path to get list of user specified attributes - attributes = node.attributes; - }else if(has("dom-attributes-specified-flag")){ - // Special processing needed for IE8, to skip a few faux values in attributes[] - attributes = darray.filter(node.attributes, function(a){ - return a.specified; - }); - }else{ - // Special path for IE6-7, avoid (sometimes >100) bogus entries in node.attributes - var clone = /^input$|^img$/i.test(node.nodeName) ? node : node.cloneNode(false), - attrs = clone.outerHTML.replace(/=[^\s"']+|="[^"]*"|='[^']*'/g, "").replace(/^\s*<[a-zA-Z0-9]*\s*/, "").replace(/\s*>.*$/, ""); - - attributes = darray.map(attrs.split(/\s+/), function(name){ - var lcName = name.toLowerCase(); - return { - name: name, - // getAttribute() doesn't work for button.value, returns innerHTML of button. - // but getAttributeNode().value doesn't work for the form.encType or li.value - value: (node.nodeName == "LI" && name == "value") || lcName == "enctype" ? - node.getAttribute(lcName) : node.getAttributeNode(lcName).value - }; - }); - } - - // Hash to convert scoped attribute name (ex: data-dojo17-params) to something friendly (ex: data-dojo-params) - // TODO: remove scope for 2.0 - var scope = options.scope || dojo._scopeName, - attrData = "data-" + scope + "-", // typically "data-dojo-" - hash = {}; - if(scope !== "dojo"){ - hash[attrData + "props"] = "data-dojo-props"; - hash[attrData + "type"] = "data-dojo-type"; - hash[attrData + "mixins"] = "data-dojo-mixins"; - hash[scope + "type"] = "dojoType"; - hash[attrData + "id"] = "data-dojo-id"; - } - - // Read in attributes and process them, including data-dojo-props, data-dojo-type, - // dojoAttachPoint, etc., as well as normal foo=bar attributes. - var i = 0, item, funcAttrs = [], jsname, extra; - while(item = attributes[i++]){ - var name = item.name, - lcName = name.toLowerCase(), - value = item.value; - - switch(hash[lcName] || lcName){ - // Already processed, just ignore - case "data-dojo-type": - case "dojotype": - case "data-dojo-mixins": - break; - - // Data-dojo-props. Save for later to make sure it overrides direct foo=bar settings - case "data-dojo-props": - extra = value; - break; - - // data-dojo-id or jsId. TODO: drop jsId in 2.0 - case "data-dojo-id": - case "jsid": - jsname = value; - break; - - // For the benefit of _Templated - case "data-dojo-attach-point": - case "dojoattachpoint": - params.dojoAttachPoint = value; - break; - case "data-dojo-attach-event": - case "dojoattachevent": - params.dojoAttachEvent = value; - break; - - // Special parameter handling needed for IE - case "class": - params["class"] = node.className; - break; - case "style": - params["style"] = node.style && node.style.cssText; - break; - default: - // Normal attribute, ex: value="123" - - // Find attribute in widget corresponding to specified name. - // May involve case conversion, ex: onclick --> onClick - if(!(name in proto)){ - var map = getNameMap(ctor); - name = map[lcName] || name; - } - - // Set params[name] to value, doing type conversion - if(name in proto){ - switch(typeof proto[name]){ - case "string": - params[name] = value; - break; - case "number": - params[name] = value.length ? Number(value) : NaN; - break; - case "boolean": - // for checked/disabled value might be "" or "checked". interpret as true. - params[name] = value.toLowerCase() != "false"; - break; - case "function": - if(value === "" || value.search(/[^\w\.]+/i) != -1){ - // The user has specified some text for a function like "return x+5" - params[name] = new Function(value); - }else{ - // The user has specified the name of a global function like "myOnClick" - // or a single word function "return" - params[name] = dlang.getObject(value, false) || new Function(value); - } - funcAttrs.push(name); // prevent "double connect", see #15026 - break; - default: - var pVal = proto[name]; - params[name] = - (pVal && "length" in pVal) ? (value ? value.split(/\s*,\s*/) : []) : // array - (pVal instanceof Date) ? - (value == "" ? new Date("") : // the NaN of dates - value == "now" ? new Date() : // current date - dates.fromISOString(value)) : - (pVal instanceof _Url) ? (dojo.baseUrl + value) : - myEval(value); - } - }else{ - params[name] = value; - } - } - } - - // Remove function attributes from DOMNode to prevent "double connect" problem, see #15026. - // Do this as a separate loop since attributes[] is often a live collection (depends on the browser though). - for(var j = 0; j < funcAttrs.length; j++){ - var lcfname = funcAttrs[j].toLowerCase(); - node.removeAttribute(lcfname); - node[lcfname] = null; - } - - // Mix things found in data-dojo-props into the params, overriding any direct settings - if(extra){ - try{ - extra = myEval.call(options.propsThis, "{" + extra + "}"); - dlang.mixin(params, extra); - }catch(e){ - // give the user a pointer to their invalid parameters. FIXME: can we kill this in production? - throw new Error(e.toString() + " in data-dojo-props='" + extra + "'"); - } - } - - // Any parameters specified in "mixin" override everything else. - dlang.mixin(params, mixin); - - // Get <script> nodes associated with this widget, if they weren't specified explicitly - if(!scripts){ - scripts = (ctor && (ctor._noScript || proto._noScript) ? [] : query("> script[type^='dojo/']", node)); - } - - // Process <script type="dojo/*"> script tags - // <script type="dojo/method" data-dojo-event="foo"> tags are added to params, and passed to - // the widget on instantiation. - // <script type="dojo/method"> tags (with no event) are executed after instantiation - // <script type="dojo/connect" data-dojo-event="foo"> tags are dojo.connected after instantiation, - // and likewise with <script type="dojo/aspect" data-dojo-method="foo"> - // <script type="dojo/watch" data-dojo-prop="foo"> tags are dojo.watch after instantiation - // <script type="dojo/on" data-dojo-event="foo"> tags are dojo.on after instantiation - // note: dojo/* script tags cannot exist in self closing widgets, like <input /> - var aspects = [], // aspects to connect after instantiation - calls = [], // functions to call after instantiation - watches = [], // functions to watch after instantiation - ons = []; // functions to on after instantiation - - if(scripts){ - for(i = 0; i < scripts.length; i++){ - var script = scripts[i]; - node.removeChild(script); - // FIXME: drop event="" support in 2.0. use data-dojo-event="" instead - var event = (script.getAttribute(attrData + "event") || script.getAttribute("event")), - prop = script.getAttribute(attrData + "prop"), - method = script.getAttribute(attrData + "method"), - advice = script.getAttribute(attrData + "advice"), - scriptType = script.getAttribute("type"), - nf = this._functionFromScript(script, attrData); - if(event){ - if(scriptType == "dojo/connect"){ - aspects.push({ method: event, func: nf }); - }else if(scriptType == "dojo/on"){ - ons.push({ event: event, func: nf }); - }else{ - // <script type="dojo/method" data-dojo-event="foo"> - // TODO for 2.0: use data-dojo-method="foo" instead (also affects dijit/Declaration) - params[event] = nf; - } - }else if(scriptType == "dojo/aspect"){ - aspects.push({ method: method, advice: advice, func: nf }); - }else if(scriptType == "dojo/watch"){ - watches.push({ prop: prop, func: nf }); - }else{ - calls.push(nf); - } - } - } - - // create the instance - var markupFactory = ctor.markupFactory || proto.markupFactory; - var instance = markupFactory ? markupFactory(params, node, ctor) : new ctor(params, node); - - function onInstantiate(instance){ - // map it to the JS namespace if that makes sense - if(jsname){ - dlang.setObject(jsname, instance); - } - - // process connections and startup functions - for(i = 0; i < aspects.length; i++){ - aspect[aspects[i].advice || "after"](instance, aspects[i].method, dlang.hitch(instance, aspects[i].func), true); - } - for(i = 0; i < calls.length; i++){ - calls[i].call(instance); - } - for(i = 0; i < watches.length; i++){ - instance.watch(watches[i].prop, watches[i].func); - } - for(i = 0; i < ons.length; i++){ - don(instance, ons[i].event, ons[i].func); - } - - return instance; - } - - if(instance.then){ - return instance.then(onInstantiate); - }else{ - return onInstantiate(instance); - } - }, - - scan: function(root, options){ - // summary: - // Scan a DOM tree and return an array of objects representing the DOMNodes - // that need to be turned into widgets. - // description: - // Search specified node (or document root node) recursively for class instances - // and return an array of objects that represent potential widgets to be - // instantiated. Searches for either data-dojo-type="MID" or dojoType="MID" where - // "MID" is a module ID like "dijit/form/Button" or a fully qualified Class name - // like "dijit/form/Button". If the MID is not currently available, scan will - // attempt to require() in the module. - // - // See parser.parse() for details of markup. - // root: DomNode? - // A default starting root node from which to start the parsing. Can be - // omitted, defaulting to the entire document. If omitted, the `options` - // object can be passed in this place. If the `options` object has a - // `rootNode` member, that is used. - // options: Object - // a kwArgs options object, see parse() for details - // - // returns: Promise - // A promise that is resolved with the nodes that have been parsed. - - var list = [], // Output List - mids = [], // An array of modules that are not yet loaded - midsHash = {}; // Used to keep the mids array unique - - var dojoType = (options.scope || dojo._scopeName) + "Type", // typically "dojoType" - attrData = "data-" + (options.scope || dojo._scopeName) + "-", // typically "data-dojo-" - dataDojoType = attrData + "type", // typically "data-dojo-type" - dataDojoTextDir = attrData + "textdir", // typically "data-dojo-textdir" - dataDojoMixins = attrData + "mixins"; // typically "data-dojo-mixins" - - // Info on DOMNode currently being processed - var node = root.firstChild; - - // Info on parent of DOMNode currently being processed - // - inherited: dir, lang, and textDir setting of parent, or inherited by parent - // - parent: pointer to identical structure for my parent (or null if no parent) - // - scripts: if specified, collects <script type="dojo/..."> type nodes from children - var inherited = options.inherited; - if(!inherited){ - function findAncestorAttr(node, attr){ - return (node.getAttribute && node.getAttribute(attr)) || - (node.parentNode && findAncestorAttr(node.parentNode, attr)); - } - - inherited = { - dir: findAncestorAttr(root, "dir"), - lang: findAncestorAttr(root, "lang"), - textDir: findAncestorAttr(root, dataDojoTextDir) - }; - for(var key in inherited){ - if(!inherited[key]){ - delete inherited[key]; - } - } - } - - // Metadata about parent node - var parent = { - inherited: inherited - }; - - // For collecting <script type="dojo/..."> type nodes (when null, we don't need to collect) - var scripts; - - // when true, only look for <script type="dojo/..."> tags, and don't recurse to children - var scriptsOnly; - - function getEffective(parent){ - // summary: - // Get effective dir, lang, textDir settings for specified obj - // (matching "parent" object structure above), and do caching. - // Take care not to return null entries. - if(!parent.inherited){ - parent.inherited = {}; - var node = parent.node, - grandparent = getEffective(parent.parent); - var inherited = { - dir: node.getAttribute("dir") || grandparent.dir, - lang: node.getAttribute("lang") || grandparent.lang, - textDir: node.getAttribute(dataDojoTextDir) || grandparent.textDir - }; - for(var key in inherited){ - if(inherited[key]){ - parent.inherited[key] = inherited[key]; - } - } - } - return parent.inherited; - } - - // DFS on DOM tree, collecting nodes with data-dojo-type specified. - while(true){ - if(!node){ - // Finished this level, continue to parent's next sibling - if(!parent || !parent.node){ - break; - } - node = parent.node.nextSibling; - scriptsOnly = false; - parent = parent.parent; - scripts = parent.scripts; - continue; - } - - if(node.nodeType != 1){ - // Text or comment node, skip to next sibling - node = node.nextSibling; - continue; - } - - if(scripts && node.nodeName.toLowerCase() == "script"){ - // Save <script type="dojo/..."> for parent, then continue to next sibling - type = node.getAttribute("type"); - if(type && /^dojo\/\w/i.test(type)){ - scripts.push(node); - } - node = node.nextSibling; - continue; - } - if(scriptsOnly){ - // scriptsOnly flag is set, we have already collected scripts if the parent wants them, so now we shouldn't - // continue further analysis of the node and will continue to the next sibling - node = node.nextSibling; - continue; - } - - // Check for data-dojo-type attribute, fallback to backward compatible dojoType - // TODO: Remove dojoType in 2.0 - var type = node.getAttribute(dataDojoType) || node.getAttribute(dojoType); - - // Short circuit for leaf nodes containing nothing [but text] - var firstChild = node.firstChild; - if(!type && (!firstChild || (firstChild.nodeType == 3 && !firstChild.nextSibling))){ - node = node.nextSibling; - continue; - } - - // Meta data about current node - var current; - - var ctor = null; - if(type){ - // If dojoType/data-dojo-type specified, add to output array of nodes to instantiate. - var mixinsValue = node.getAttribute(dataDojoMixins), - types = mixinsValue ? [type].concat(mixinsValue.split(/\s*,\s*/)) : [type]; - - // Note: won't find classes declared via dojo/Declaration or any modules that haven't been - // loaded yet so use try/catch to avoid throw from require() - try{ - ctor = getCtor(types, options.contextRequire); - }catch(e){} - - // If the constructor was not found, check to see if it has modules that can be loaded - if(!ctor){ - darray.forEach(types, function(t){ - if(~t.indexOf('/') && !midsHash[t]){ - // If the type looks like a MID and it currently isn't in the array of MIDs to load, add it. - midsHash[t] = true; - mids[mids.length] = t; - } - }); - } - - var childScripts = ctor && !ctor.prototype._noScript ? [] : null; // <script> nodes that are parent's children - - // Setup meta data about this widget node, and save it to list of nodes to instantiate - current = { - types: types, - ctor: ctor, - parent: parent, - node: node, - scripts: childScripts - }; - current.inherited = getEffective(current); // dir & lang settings for current node, explicit or inherited - list.push(current); - }else{ - // Meta data about this non-widget node - current = { - node: node, - scripts: scripts, - parent: parent - }; - } - - // Recurse, collecting <script type="dojo/..."> children, and also looking for - // descendant nodes with dojoType specified (unless the widget has the stopParser flag). - // When finished with children, go to my next sibling. - scripts = childScripts; - scriptsOnly = node.stopParser || (ctor && ctor.prototype.stopParser && !(options.template)); - parent = current; - node = firstChild; - } - - var d = new Deferred(); - - // If there are modules to load then require them in - if(mids.length){ - // Warn that there are modules being auto-required - if(has("dojo-debug-messages")){ - console.warn("WARNING: Modules being Auto-Required: " + mids.join(", ")); - } - var r = options.contextRequire || require; - r(mids, function(){ - // Go through list of widget nodes, filling in missing constructors, and filtering out nodes that shouldn't - // be instantiated due to a stopParser flag on an ancestor that we belatedly learned about due to - // auto-require of a module like ContentPane. Assumes list is in DFS order. - d.resolve(darray.filter(list, function(widget){ - if(!widget.ctor){ - // Attempt to find the constructor again. Still won't find classes defined via - // dijit/Declaration so need to try/catch. - try{ - widget.ctor = getCtor(widget.types, options.contextRequire); - }catch(e){} - } - - // Get the parent widget - var parent = widget.parent; - while(parent && !parent.types){ - parent = parent.parent; - } - - // Return false if this node should be skipped due to stopParser on an ancestor. - // Since list[] is in DFS order, this loop will always set parent.instantiateChildren before - // trying to compute widget.instantiate. - var proto = widget.ctor && widget.ctor.prototype; - widget.instantiateChildren = !(proto && proto.stopParser && !(options.template)); - widget.instantiate = !parent || (parent.instantiate && parent.instantiateChildren); - return widget.instantiate; - })); - }); - }else{ - // There were no modules to load, so just resolve with the parsed nodes. This separate code path is for - // efficiency, to avoid running the require() and the callback code above. - d.resolve(list); - } - - // Return the promise - return d.promise; - }, - - _require: function(/*DOMNode*/ script, /*Object?*/ options){ - // summary: - // Helper for _scanAMD(). Takes a `<script type=dojo/require>bar: "acme/bar", ...</script>` node, - // calls require() to load the specified modules and (asynchronously) assign them to the specified global - // variables, and returns a Promise for when that operation completes. - // - // In the example above, it is effectively doing a require(["acme/bar", ...], function(a){ bar = a; }). - - var hash = myEval("{" + script.innerHTML + "}"), // can't use dojo/json::parse() because maybe no quotes - vars = [], - mids = [], - d = new Deferred(); - - var contextRequire = (options && options.contextRequire) || require; - - for(var name in hash){ - vars.push(name); - mids.push(hash[name]); - } - - contextRequire(mids, function(){ - for(var i = 0; i < vars.length; i++){ - dlang.setObject(vars[i], arguments[i]); - } - d.resolve(arguments); - }); - - return d.promise; - }, - - _scanAmd: function(root, options){ - // summary: - // Scans the DOM for any declarative requires and returns their values. - // description: - // Looks for `<script type=dojo/require>bar: "acme/bar", ...</script>` node, calls require() to load the - // specified modules and (asynchronously) assign them to the specified global variables, - // and returns a Promise for when those operations complete. - // root: DomNode - // The node to base the scan from. - // options: Object? - // a kwArgs options object, see parse() for details - - // Promise that resolves when all the <script type=dojo/require> nodes have finished loading. - var deferred = new Deferred(), - promise = deferred.promise; - deferred.resolve(true); - - var self = this; - query("script[type='dojo/require']", root).forEach(function(node){ - // Fire off require() call for specified modules. Chain this require to fire after - // any previous requires complete, so that layers can be loaded before individual module require()'s fire. - promise = promise.then(function(){ - return self._require(node, options); - }); - - // Remove from DOM so it isn't seen again - node.parentNode.removeChild(node); - }); - - return promise; - }, - - parse: function(rootNode, options){ - // summary: - // Scan the DOM for class instances, and instantiate them. - // description: - // Search specified node (or root node) recursively for class instances, - // and instantiate them. Searches for either data-dojo-type="Class" or - // dojoType="Class" where "Class" is a a fully qualified class name, - // like `dijit/form/Button` - // - // Using `data-dojo-type`: - // Attributes using can be mixed into the parameters used to instantiate the - // Class by using a `data-dojo-props` attribute on the node being converted. - // `data-dojo-props` should be a string attribute to be converted from JSON. - // - // Using `dojoType`: - // Attributes are read from the original domNode and converted to appropriate - // types by looking up the Class prototype values. This is the default behavior - // from Dojo 1.0 to Dojo 1.5. `dojoType` support is deprecated, and will - // go away in Dojo 2.0. - // rootNode: DomNode? - // A default starting root node from which to start the parsing. Can be - // omitted, defaulting to the entire document. If omitted, the `options` - // object can be passed in this place. If the `options` object has a - // `rootNode` member, that is used. - // options: Object? - // A hash of options. - // - // - noStart: Boolean?: - // when set will prevent the parser from calling .startup() - // when locating the nodes. - // - rootNode: DomNode?: - // identical to the function's `rootNode` argument, though - // allowed to be passed in via this `options object. - // - template: Boolean: - // If true, ignores ContentPane's stopParser flag and parses contents inside of - // a ContentPane inside of a template. This allows dojoAttachPoint on widgets/nodes - // nested inside the ContentPane to work. - // - inherited: Object: - // Hash possibly containing dir and lang settings to be applied to - // parsed widgets, unless there's another setting on a sub-node that overrides - // - scope: String: - // Root for attribute names to search for. If scopeName is dojo, - // will search for data-dojo-type (or dojoType). For backwards compatibility - // reasons defaults to dojo._scopeName (which is "dojo" except when - // multi-version support is used, when it will be something like dojo16, dojo20, etc.) - // - propsThis: Object: - // If specified, "this" referenced from data-dojo-props will refer to propsThis. - // Intended for use from the widgets-in-template feature of `dijit._WidgetsInTemplateMixin` - // - contextRequire: Function: - // If specified, this require is utilised for looking resolving modules instead of the - // `dojo/parser` context `require()`. Intended for use from the widgets-in-template feature of - // `dijit._WidgetsInTemplateMixin`. - // returns: Mixed - // Returns a blended object that is an array of the instantiated objects, but also can include - // a promise that is resolved with the instantiated objects. This is done for backwards - // compatibility. If the parser auto-requires modules, it will always behave in a promise - // fashion and `parser.parse().then(function(instances){...})` should be used. - // example: - // Parse all widgets on a page: - // | parser.parse(); - // example: - // Parse all classes within the node with id="foo" - // | parser.parse(dojo.byId('foo')); - // example: - // Parse all classes in a page, but do not call .startup() on any - // child - // | parser.parse({ noStart: true }) - // example: - // Parse all classes in a node, but do not call .startup() - // | parser.parse(someNode, { noStart:true }); - // | // or - // | parser.parse({ noStart:true, rootNode: someNode }); - - // determine the root node and options based on the passed arguments. - var root; - if(!options && rootNode && rootNode.rootNode){ - options = rootNode; - root = options.rootNode; - }else if(rootNode && dlang.isObject(rootNode) && !("nodeType" in rootNode)){ - options = rootNode; - }else{ - root = rootNode; - } - root = root ? dom.byId(root) : dwindow.body(); - - options = options || {}; - - var mixin = options.template ? { template: true } : {}, - instances = [], - self = this; - - // First scan for any <script type=dojo/require> nodes, and execute. - // Then scan for all nodes with data-dojo-type, and load any unloaded modules. - // Then build the object instances. Add instances to already existing (but empty) instances[] array, - // which may already have been returned to caller. Also, use otherwise to collect and throw any errors - // that occur during the parse(). - var p = - this._scanAmd(root, options).then(function(){ - return self.scan(root, options); - }).then(function(parsedNodes){ - return self._instantiate(parsedNodes, mixin, options, true); - }).then(function(_instances){ - // Copy the instances into the instances[] array we declared above, and are accessing as - // our return value. - return instances = instances.concat(_instances); - }).otherwise(function(e){ - // TODO Modify to follow better pattern for promise error management when available - console.error("dojo/parser::parse() error", e); - throw e; - }); - - // Blend the array with the promise - dlang.mixin(instances, p); - return instances; - } - }; - - if( 1 ){ - dojo.parser = parser; - } - - // Register the parser callback. It should be the first callback - // after the a11y test. - if(config.parseOnLoad){ - ready(100, parser, "parse"); - } - - return parser; -}); diff --git a/lib/dojo/promise/Promise.js b/lib/dojo/promise/Promise.js deleted file mode 100644 index 0d61ca3..0000000 --- a/lib/dojo/promise/Promise.js +++ /dev/null @@ -1,37 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/promise/Promise",["../_base/lang"],function(_1){ -"use strict"; -function _2(){ -throw new TypeError("abstract"); -}; -return _1.extend(function Promise(){ -},{then:function(_3,_4,_5){ -_2(); -},cancel:function(_6,_7){ -_2(); -},isResolved:function(){ -_2(); -},isRejected:function(){ -_2(); -},isFulfilled:function(){ -_2(); -},isCanceled:function(){ -_2(); -},always:function(_8){ -return this.then(_8,_8); -},otherwise:function(_9){ -return this.then(null,_9); -},trace:function(){ -return this; -},traceRejected:function(){ -return this; -},toString:function(){ -return "[object Promise]"; -}}); -}); diff --git a/lib/dojo/promise/Promise.js.uncompressed.js b/lib/dojo/promise/Promise.js.uncompressed.js deleted file mode 100644 index eba0080..0000000 --- a/lib/dojo/promise/Promise.js.uncompressed.js +++ /dev/null @@ -1,133 +0,0 @@ -define("dojo/promise/Promise", [ - "../_base/lang" -], function(lang){ - "use strict"; - - // module: - // dojo/promise/Promise - - function throwAbstract(){ - throw new TypeError("abstract"); - } - - return lang.extend(function Promise(){ - // summary: - // The public interface to a deferred. - // description: - // The public interface to a deferred. All promises in Dojo are - // instances of this class. - }, { - then: function(callback, errback, progback){ - // summary: - // Add new callbacks to the promise. - // description: - // Add new callbacks to the deferred. Callbacks can be added - // before or after the deferred is fulfilled. - // callback: Function? - // Callback to be invoked when the promise is resolved. - // Receives the resolution value. - // errback: Function? - // Callback to be invoked when the promise is rejected. - // Receives the rejection error. - // progback: Function? - // Callback to be invoked when the promise emits a progress - // update. Receives the progress update. - // returns: dojo/promise/Promise - // Returns a new promise for the result of the callback(s). - // This can be used for chaining many asynchronous operations. - - throwAbstract(); - }, - - cancel: function(reason, strict){ - // summary: - // Inform the deferred it may cancel its asynchronous operation. - // description: - // Inform the deferred it may cancel its asynchronous operation. - // The deferred's (optional) canceler is invoked and the - // deferred will be left in a rejected state. Can affect other - // promises that originate with the same deferred. - // reason: any - // A message that may be sent to the deferred's canceler, - // explaining why it's being canceled. - // strict: Boolean? - // If strict, will throw an error if the deferred has already - // been fulfilled and consequently cannot be canceled. - // returns: any - // Returns the rejection reason if the deferred was canceled - // normally. - - throwAbstract(); - }, - - isResolved: function(){ - // summary: - // Checks whether the promise has been resolved. - // returns: Boolean - - throwAbstract(); - }, - - isRejected: function(){ - // summary: - // Checks whether the promise has been rejected. - // returns: Boolean - - throwAbstract(); - }, - - isFulfilled: function(){ - // summary: - // Checks whether the promise has been resolved or rejected. - // returns: Boolean - - throwAbstract(); - }, - - isCanceled: function(){ - // summary: - // Checks whether the promise has been canceled. - // returns: Boolean - - throwAbstract(); - }, - - always: function(callbackOrErrback){ - // summary: - // Add a callback to be invoked when the promise is resolved - // or rejected. - // callbackOrErrback: Function? - // A function that is used both as a callback and errback. - // returns: dojo/promise/Promise - // Returns a new promise for the result of the callback/errback. - - return this.then(callbackOrErrback, callbackOrErrback); - }, - - otherwise: function(errback){ - // summary: - // Add new errbacks to the promise. - // errback: Function? - // Callback to be invoked when the promise is rejected. - // returns: dojo/promise/Promise - // Returns a new promise for the result of the errback. - - return this.then(null, errback); - }, - - trace: function(){ - return this; - }, - - traceRejected: function(){ - return this; - }, - - toString: function(){ - // returns: string - // Returns `[object Promise]`. - - return "[object Promise]"; - } - }); -}); diff --git a/lib/dojo/promise/all.js b/lib/dojo/promise/all.js deleted file mode 100644 index fcf4fe6..0000000 --- a/lib/dojo/promise/all.js +++ /dev/null @@ -1,60 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/promise/all",["../_base/array","../Deferred","../when"],function(_1,_2,_3){ -"use strict"; -var _4=_1.some; -return function all(_5){ -var _6,_1; -if(_5 instanceof Array){ -_1=_5; -}else{ -if(_5&&typeof _5==="object"){ -_6=_5; -} -} -var _7; -var _8=[]; -if(_6){ -_1=[]; -for(var _9 in _6){ -if(Object.hasOwnProperty.call(_6,_9)){ -_8.push(_9); -_1.push(_6[_9]); -} -} -_7={}; -}else{ -if(_1){ -_7=[]; -} -} -if(!_1||!_1.length){ -return new _2().resolve(_7); -} -var _a=new _2(); -_a.promise.always(function(){ -_7=_8=null; -}); -var _b=_1.length; -_4(_1,function(_c,_d){ -if(!_6){ -_8.push(_d); -} -_3(_c,function(_e){ -if(!_a.isFulfilled()){ -_7[_8[_d]]=_e; -if(--_b===0){ -_a.resolve(_7); -} -} -},_a.reject); -return _a.isFulfilled(); -}); -return _a.promise; -}; -}); diff --git a/lib/dojo/promise/all.js.uncompressed.js b/lib/dojo/promise/all.js.uncompressed.js deleted file mode 100644 index 8c75ea8..0000000 --- a/lib/dojo/promise/all.js.uncompressed.js +++ /dev/null @@ -1,76 +0,0 @@ -define("dojo/promise/all", [ - "../_base/array", - "../Deferred", - "../when" -], function(array, Deferred, when){ - "use strict"; - - // module: - // dojo/promise/all - - var some = array.some; - - return function all(objectOrArray){ - // summary: - // Takes multiple promises and returns a new promise that is fulfilled - // when all promises have been resolved or one has been rejected. - // description: - // Takes multiple promises and returns a new promise that is fulfilled - // when all promises have been resolved or one has been rejected. If one of - // the promises is rejected, the returned promise is also rejected. Canceling - // the returned promise will *not* cancel any passed promises. - // objectOrArray: Object|Array? - // The promise will be fulfilled with a list of results if invoked with an - // array, or an object of results when passed an object (using the same - // keys). If passed neither an object or array it is resolved with an - // undefined value. - // returns: dojo/promise/Promise - - var object, array; - if(objectOrArray instanceof Array){ - array = objectOrArray; - }else if(objectOrArray && typeof objectOrArray === "object"){ - object = objectOrArray; - } - - var results; - var keyLookup = []; - if(object){ - array = []; - for(var key in object){ - if(Object.hasOwnProperty.call(object, key)){ - keyLookup.push(key); - array.push(object[key]); - } - } - results = {}; - }else if(array){ - results = []; - } - - if(!array || !array.length){ - return new Deferred().resolve(results); - } - - var deferred = new Deferred(); - deferred.promise.always(function(){ - results = keyLookup = null; - }); - var waiting = array.length; - some(array, function(valueOrPromise, index){ - if(!object){ - keyLookup.push(index); - } - when(valueOrPromise, function(value){ - if(!deferred.isFulfilled()){ - results[keyLookup[index]] = value; - if(--waiting === 0){ - deferred.resolve(results); - } - } - }, deferred.reject); - return deferred.isFulfilled(); - }); - return deferred.promise; // dojo/promise/Promise - }; -}); diff --git a/lib/dojo/promise/first.js b/lib/dojo/promise/first.js deleted file mode 100644 index 1cc85d8..0000000 --- a/lib/dojo/promise/first.js +++ /dev/null @@ -1,34 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/promise/first",["../_base/array","../Deferred","../when"],function(_1,_2,_3){ -"use strict"; -var _4=_1.forEach; -return function first(_5){ -var _6; -if(_5 instanceof Array){ -_6=_5; -}else{ -if(_5&&typeof _5==="object"){ -_6=[]; -for(var _7 in _5){ -if(Object.hasOwnProperty.call(_5,_7)){ -_6.push(_5[_7]); -} -} -} -} -if(!_6||!_6.length){ -return new _2().resolve(); -} -var _8=new _2(); -_4(_6,function(_9){ -_3(_9,_8.resolve,_8.reject); -}); -return _8.promise; -}; -}); diff --git a/lib/dojo/promise/first.js.uncompressed.js b/lib/dojo/promise/first.js.uncompressed.js deleted file mode 100644 index 863573f..0000000 --- a/lib/dojo/promise/first.js.uncompressed.js +++ /dev/null @@ -1,49 +0,0 @@ -define("dojo/promise/first", [ - "../_base/array", - "../Deferred", - "../when" -], function(array, Deferred, when){ - "use strict"; - - // module: - // dojo/promise/first - - var forEach = array.forEach; - - return function first(objectOrArray){ - // summary: - // Takes multiple promises and returns a new promise that is fulfilled - // when the first of these promises is fulfilled. - // description: - // Takes multiple promises and returns a new promise that is fulfilled - // when the first of these promises is fulfilled. Canceling the returned - // promise will *not* cancel any passed promises. The promise will be - // fulfilled with the value of the first fulfilled promise. - // objectOrArray: Object|Array? - // The promises are taken from the array or object values. If no value - // is passed, the returned promise is resolved with an undefined value. - // returns: dojo/promise/Promise - - var array; - if(objectOrArray instanceof Array){ - array = objectOrArray; - }else if(objectOrArray && typeof objectOrArray === "object"){ - array = []; - for(var key in objectOrArray){ - if(Object.hasOwnProperty.call(objectOrArray, key)){ - array.push(objectOrArray[key]); - } - } - } - - if(!array || !array.length){ - return new Deferred().resolve(); - } - - var deferred = new Deferred(); - forEach(array, function(valueOrPromise){ - when(valueOrPromise, deferred.resolve, deferred.reject); - }); - return deferred.promise; // dojo/promise/Promise - }; -}); diff --git a/lib/dojo/promise/instrumentation.js b/lib/dojo/promise/instrumentation.js deleted file mode 100644 index e9008ef..0000000 --- a/lib/dojo/promise/instrumentation.js +++ /dev/null @@ -1,89 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/promise/instrumentation",["./tracer","../has","../_base/lang","../_base/array"],function(_1,_2,_3,_4){ -_2.add("config-useDeferredInstrumentation","report-unhandled-rejections"); -function _5(_6,_7,_8){ -var _9=""; -if(_6&&_6.stack){ -_9+=_6.stack; -} -if(_7&&_7.stack){ -_9+="\n ----------------------------------------\n rejected"+_7.stack.split("\n").slice(1).join("\n").replace(/^\s+/," "); -} -if(_8&&_8.stack){ -_9+="\n ----------------------------------------\n"+_8.stack; -} -console.error(_6,_9); -}; -function _a(_b,_c,_d,_e){ -if(!_c){ -_5(_b,_d,_e); -} -}; -var _f=[]; -var _10=false; -var _11=1000; -function _12(_13,_14,_15,_16){ -if(_14){ -_4.some(_f,function(obj,ix){ -if(obj.error===_13){ -_f.splice(ix,1); -return true; -} -}); -}else{ -if(!_4.some(_f,function(obj){ -return obj.error===_13; -})){ -_f.push({error:_13,rejection:_15,deferred:_16,timestamp:new Date().getTime()}); -} -} -if(!_10){ -_10=setTimeout(_17,_11); -} -}; -function _17(){ -var now=new Date().getTime(); -var _18=now-_11; -_f=_4.filter(_f,function(obj){ -if(obj.timestamp<_18){ -_5(obj.error,obj.rejection,obj.deferred); -return false; -} -return true; -}); -if(_f.length){ -_10=setTimeout(_17,_f[0].timestamp+_11-now); -}else{ -_10=false; -} -}; -return function(_19){ -var _1a=_2("config-useDeferredInstrumentation"); -if(_1a){ -_1.on("resolved",_3.hitch(console,"log","resolved")); -_1.on("rejected",_3.hitch(console,"log","rejected")); -_1.on("progress",_3.hitch(console,"log","progress")); -var _1b=[]; -if(typeof _1a==="string"){ -_1b=_1a.split(","); -_1a=_1b.shift(); -} -if(_1a==="report-rejections"){ -_19.instrumentRejected=_a; -}else{ -if(_1a==="report-unhandled-rejections"||_1a===true||_1a===1){ -_19.instrumentRejected=_12; -_11=parseInt(_1b[0],10)||_11; -}else{ -throw new Error("Unsupported instrumentation usage <"+_1a+">"); -} -} -} -}; -}); diff --git a/lib/dojo/promise/instrumentation.js.uncompressed.js b/lib/dojo/promise/instrumentation.js.uncompressed.js deleted file mode 100644 index bb12b84..0000000 --- a/lib/dojo/promise/instrumentation.js.uncompressed.js +++ /dev/null @@ -1,107 +0,0 @@ -define("dojo/promise/instrumentation", [ - "./tracer", - "../has", - "../_base/lang", - "../_base/array" -], function(tracer, has, lang, arrayUtil){ - has.add("config-useDeferredInstrumentation", "report-unhandled-rejections"); - - function logError(error, rejection, deferred){ - var stack = ""; - if(error && error.stack){ - stack += error.stack; - } - if(rejection && rejection.stack){ - stack += "\n ----------------------------------------\n rejected" + rejection.stack.split("\n").slice(1).join("\n").replace(/^\s+/, " "); - } - if(deferred && deferred.stack){ - stack += "\n ----------------------------------------\n" + deferred.stack; - } - console.error(error, stack); - } - - function reportRejections(error, handled, rejection, deferred){ - if(!handled){ - logError(error, rejection, deferred); - } - } - - var errors = []; - var activeTimeout = false; - var unhandledWait = 1000; - function trackUnhandledRejections(error, handled, rejection, deferred){ - if(handled){ - arrayUtil.some(errors, function(obj, ix){ - if(obj.error === error){ - errors.splice(ix, 1); - return true; - } - }); - }else if(!arrayUtil.some(errors, function(obj){ return obj.error === error; })){ - errors.push({ - error: error, - rejection: rejection, - deferred: deferred, - timestamp: new Date().getTime() - }); - } - - if(!activeTimeout){ - activeTimeout = setTimeout(logRejected, unhandledWait); - } - } - - function logRejected(){ - var now = new Date().getTime(); - var reportBefore = now - unhandledWait; - errors = arrayUtil.filter(errors, function(obj){ - if(obj.timestamp < reportBefore){ - logError(obj.error, obj.rejection, obj.deferred); - return false; - } - return true; - }); - - if(errors.length){ - activeTimeout = setTimeout(logRejected, errors[0].timestamp + unhandledWait - now); - }else{ - activeTimeout = false; - } - } - - return function(Deferred){ - // summary: - // Initialize instrumentation for the Deferred class. - // description: - // Initialize instrumentation for the Deferred class. - // Done automatically by `dojo/Deferred` if the - // `deferredInstrumentation` and `useDeferredInstrumentation` - // config options are set. - // - // Sets up `dojo/promise/tracer` to log to the console. - // - // Sets up instrumentation of rejected deferreds so unhandled - // errors are logged to the console. - - var usage = has("config-useDeferredInstrumentation"); - if(usage){ - tracer.on("resolved", lang.hitch(console, "log", "resolved")); - tracer.on("rejected", lang.hitch(console, "log", "rejected")); - tracer.on("progress", lang.hitch(console, "log", "progress")); - - var args = []; - if(typeof usage === "string"){ - args = usage.split(","); - usage = args.shift(); - } - if(usage === "report-rejections"){ - Deferred.instrumentRejected = reportRejections; - }else if(usage === "report-unhandled-rejections" || usage === true || usage === 1){ - Deferred.instrumentRejected = trackUnhandledRejections; - unhandledWait = parseInt(args[0], 10) || unhandledWait; - }else{ - throw new Error("Unsupported instrumentation usage <" + usage + ">"); - } - } - }; -}); diff --git a/lib/dojo/promise/tracer.js b/lib/dojo/promise/tracer.js deleted file mode 100644 index 9cbce2d..0000000 --- a/lib/dojo/promise/tracer.js +++ /dev/null @@ -1,37 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/promise/tracer",["../_base/lang","./Promise","../Evented"],function(_1,_2,_3){ -"use strict"; -var _4=new _3; -var _5=_4.emit; -_4.emit=null; -function _6(_7){ -setTimeout(function(){ -_5.apply(_4,_7); -},0); -}; -_2.prototype.trace=function(){ -var _8=_1._toArray(arguments); -this.then(function(_9){ -_6(["resolved",_9].concat(_8)); -},function(_a){ -_6(["rejected",_a].concat(_8)); -},function(_b){ -_6(["progress",_b].concat(_8)); -}); -return this; -}; -_2.prototype.traceRejected=function(){ -var _c=_1._toArray(arguments); -this.otherwise(function(_d){ -_6(["rejected",_d].concat(_c)); -}); -return this; -}; -return _4; -}); diff --git a/lib/dojo/promise/tracer.js.uncompressed.js b/lib/dojo/promise/tracer.js.uncompressed.js deleted file mode 100644 index b5380cc..0000000 --- a/lib/dojo/promise/tracer.js.uncompressed.js +++ /dev/null @@ -1,85 +0,0 @@ -define("dojo/promise/tracer", [ - "../_base/lang", - "./Promise", - "../Evented" -], function(lang, Promise, Evented){ - "use strict"; - - // module: - // dojo/promise/tracer - - /*===== - return { - // summary: - // Trace promise fulfillment. - // description: - // Trace promise fulfillment. Calling `.trace()` or `.traceError()` on a - // promise enables tracing. Will emit `resolved`, `rejected` or `progress` - // events. - - on: function(type, listener){ - // summary: - // Subscribe to traces. - // description: - // See `dojo/Evented#on()`. - // type: String - // `resolved`, `rejected`, or `progress` - // listener: Function - // The listener is passed the traced value and any arguments - // that were used with the `.trace()` call. - } - }; - =====*/ - - var evented = new Evented; - var emit = evented.emit; - evented.emit = null; - // Emit events asynchronously since they should not change the promise state. - function emitAsync(args){ - setTimeout(function(){ - emit.apply(evented, args); - }, 0); - } - - Promise.prototype.trace = function(){ - // summary: - // Trace the promise. - // description: - // Tracing allows you to transparently log progress, - // resolution and rejection of promises, without affecting the - // promise itself. Any arguments passed to `trace()` are - // emitted in trace events. See `dojo/promise/tracer` on how - // to handle traces. - // returns: dojo/promise/Promise - // The promise instance `trace()` is called on. - - var args = lang._toArray(arguments); - this.then( - function(value){ emitAsync(["resolved", value].concat(args)); }, - function(error){ emitAsync(["rejected", error].concat(args)); }, - function(update){ emitAsync(["progress", update].concat(args)); } - ); - return this; - }; - - Promise.prototype.traceRejected = function(){ - // summary: - // Trace rejection of the promise. - // description: - // Tracing allows you to transparently log progress, - // resolution and rejection of promises, without affecting the - // promise itself. Any arguments passed to `trace()` are - // emitted in trace events. See `dojo/promise/tracer` on how - // to handle traces. - // returns: dojo/promise/Promise - // The promise instance `traceRejected()` is called on. - - var args = lang._toArray(arguments); - this.otherwise(function(error){ - emitAsync(["rejected", error].concat(args)); - }); - return this; - }; - - return evented; -}); diff --git a/lib/dojo/query.js b/lib/dojo/query.js deleted file mode 100644 index 71987ba..0000000 --- a/lib/dojo/query.js +++ /dev/null @@ -1,195 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/query",["./_base/kernel","./has","./dom","./on","./_base/array","./_base/lang","./selector/_loader","./selector/_loader!default"],function(_1,_2,_3,on,_4,_5,_6,_7){ -"use strict"; -_2.add("array-extensible",function(){ -return _5.delegate([],{length:1}).length==1&&!_2("bug-for-in-skips-shadowed"); -}); -var ap=Array.prototype,_8=ap.slice,_9=ap.concat,_a=_4.forEach; -var _b=function(a,_c,_d){ -var _e=new (_d||this._NodeListCtor||nl)(a); -return _c?_e._stash(_c):_e; -}; -var _f=function(f,a,o){ -a=[0].concat(_8.call(a,0)); -o=o||_1.global; -return function(_10){ -a[0]=_10; -return f.apply(o,a); -}; -}; -var _11=function(f,o){ -return function(){ -this.forEach(_f(f,arguments,o)); -return this; -}; -}; -var _12=function(f,o){ -return function(){ -return this.map(_f(f,arguments,o)); -}; -}; -var _13=function(f,o){ -return function(){ -return this.filter(_f(f,arguments,o)); -}; -}; -var _14=function(f,g,o){ -return function(){ -var a=arguments,_15=_f(f,a,o); -if(g.call(o||_1.global,a)){ -return this.map(_15); -} -this.forEach(_15); -return this; -}; -}; -var _16=function(_17){ -var _18=this instanceof nl&&_2("array-extensible"); -if(typeof _17=="number"){ -_17=Array(_17); -} -var _19=(_17&&"length" in _17)?_17:arguments; -if(_18||!_19.sort){ -var _1a=_18?this:[],l=_1a.length=_19.length; -for(var i=0;i<l;i++){ -_1a[i]=_19[i]; -} -if(_18){ -return _1a; -} -_19=_1a; -} -_5._mixin(_19,nlp); -_19._NodeListCtor=function(_1b){ -return nl(_1b); -}; -return _19; -}; -var nl=_16,nlp=nl.prototype=_2("array-extensible")?[]:{}; -nl._wrap=nlp._wrap=_b; -nl._adaptAsMap=_12; -nl._adaptAsForEach=_11; -nl._adaptAsFilter=_13; -nl._adaptWithCondition=_14; -_a(["slice","splice"],function(_1c){ -var f=ap[_1c]; -nlp[_1c]=function(){ -return this._wrap(f.apply(this,arguments),_1c=="slice"?this:null); -}; -}); -_a(["indexOf","lastIndexOf","every","some"],function(_1d){ -var f=_4[_1d]; -nlp[_1d]=function(){ -return f.apply(_1,[this].concat(_8.call(arguments,0))); -}; -}); -_5.extend(_16,{constructor:nl,_NodeListCtor:nl,toString:function(){ -return this.join(","); -},_stash:function(_1e){ -this._parent=_1e; -return this; -},on:function(_1f,_20){ -var _21=this.map(function(_22){ -return on(_22,_1f,_20); -}); -_21.remove=function(){ -for(var i=0;i<_21.length;i++){ -_21[i].remove(); -} -}; -return _21; -},end:function(){ -if(this._parent){ -return this._parent; -}else{ -return new this._NodeListCtor(0); -} -},concat:function(_23){ -var t=_8.call(this,0),m=_4.map(arguments,function(a){ -return _8.call(a,0); -}); -return this._wrap(_9.apply(t,m),this); -},map:function(_24,obj){ -return this._wrap(_4.map(this,_24,obj),this); -},forEach:function(_25,_26){ -_a(this,_25,_26); -return this; -},filter:function(_27){ -var a=arguments,_28=this,_29=0; -if(typeof _27=="string"){ -_28=_2a._filterResult(this,a[0]); -if(a.length==1){ -return _28._stash(this); -} -_29=1; -} -return this._wrap(_4.filter(_28,a[_29],a[_29+1]),this); -},instantiate:function(_2b,_2c){ -var c=_5.isFunction(_2b)?_2b:_5.getObject(_2b); -_2c=_2c||{}; -return this.forEach(function(_2d){ -new c(_2c,_2d); -}); -},at:function(){ -var t=new this._NodeListCtor(0); -_a(arguments,function(i){ -if(i<0){ -i=this.length+i; -} -if(this[i]){ -t.push(this[i]); -} -},this); -return t._stash(this); -}}); -function _2e(_2f,_30){ -var _31=function(_32,_33){ -if(typeof _33=="string"){ -_33=_3.byId(_33); -if(!_33){ -return new _30([]); -} -} -var _34=typeof _32=="string"?_2f(_32,_33):_32?(_32.end&&_32.on)?_32:[_32]:[]; -if(_34.end&&_34.on){ -return _34; -} -return new _30(_34); -}; -_31.matches=_2f.match||function(_35,_36,_37){ -return _31.filter([_35],_36,_37).length>0; -}; -_31.filter=_2f.filter||function(_38,_39,_3a){ -return _31(_39,_3a).filter(function(_3b){ -return _4.indexOf(_38,_3b)>-1; -}); -}; -if(typeof _2f!="function"){ -var _3c=_2f.search; -_2f=function(_3d,_3e){ -return _3c(_3e||document,_3d); -}; -} -return _31; -}; -var _2a=_2e(_7,_16); -_1.query=_2e(_7,function(_3f){ -return _16(_3f); -}); -_2a.load=function(id,_40,_41){ -_6.load(id,_40,function(_42){ -_41(_2e(_42,_16)); -}); -}; -_1._filterQueryResult=_2a._filterResult=function(_43,_44,_45){ -return new _16(_2a.filter(_43,_44,_45)); -}; -_1.NodeList=_2a.NodeList=_16; -return _2a; -}); diff --git a/lib/dojo/query.js.uncompressed.js b/lib/dojo/query.js.uncompressed.js deleted file mode 100644 index 88cc725..0000000 --- a/lib/dojo/query.js.uncompressed.js +++ /dev/null @@ -1,712 +0,0 @@ -define("dojo/query", ["./_base/kernel", "./has", "./dom", "./on", "./_base/array", "./_base/lang", "./selector/_loader", "./selector/_loader!default"], - function(dojo, has, dom, on, array, lang, loader, defaultEngine){ - - "use strict"; - - has.add("array-extensible", function(){ - // test to see if we can extend an array (not supported in old IE) - return lang.delegate([], {length: 1}).length == 1 && !has("bug-for-in-skips-shadowed"); - }); - - var ap = Array.prototype, aps = ap.slice, apc = ap.concat, forEach = array.forEach; - - var tnl = function(/*Array*/ a, /*dojo/NodeList?*/ parent, /*Function?*/ NodeListCtor){ - // summary: - // decorate an array to make it look like a `dojo/NodeList`. - // a: - // Array of nodes to decorate. - // parent: - // An optional parent NodeList that generated the current - // list of nodes. Used to call _stash() so the parent NodeList - // can be accessed via end() later. - // NodeListCtor: - // An optional constructor function to use for any - // new NodeList calls. This allows a certain chain of - // NodeList calls to use a different object than dojo/NodeList. - var nodeList = new (NodeListCtor || this._NodeListCtor || nl)(a); - return parent ? nodeList._stash(parent) : nodeList; - }; - - var loopBody = function(f, a, o){ - a = [0].concat(aps.call(a, 0)); - o = o || dojo.global; - return function(node){ - a[0] = node; - return f.apply(o, a); - }; - }; - - // adapters - - var adaptAsForEach = function(f, o){ - // summary: - // adapts a single node function to be used in the forEach-type - // actions. The initial object is returned from the specialized - // function. - // f: Function - // a function to adapt - // o: Object? - // an optional context for f - return function(){ - this.forEach(loopBody(f, arguments, o)); - return this; // Object - }; - }; - - var adaptAsMap = function(f, o){ - // summary: - // adapts a single node function to be used in the map-type - // actions. The return is a new array of values, as via `dojo/_base/array.map` - // f: Function - // a function to adapt - // o: Object? - // an optional context for f - return function(){ - return this.map(loopBody(f, arguments, o)); - }; - }; - - var adaptAsFilter = function(f, o){ - // summary: - // adapts a single node function to be used in the filter-type actions - // f: Function - // a function to adapt - // o: Object? - // an optional context for f - return function(){ - return this.filter(loopBody(f, arguments, o)); - }; - }; - - var adaptWithCondition = function(f, g, o){ - // summary: - // adapts a single node function to be used in the map-type - // actions, behaves like forEach() or map() depending on arguments - // f: Function - // a function to adapt - // g: Function - // a condition function, if true runs as map(), otherwise runs as forEach() - // o: Object? - // an optional context for f and g - return function(){ - var a = arguments, body = loopBody(f, a, o); - if(g.call(o || dojo.global, a)){ - return this.map(body); // self - } - this.forEach(body); - return this; // self - }; - }; - - var NodeList = function(array){ - // summary: - // Array-like object which adds syntactic - // sugar for chaining, common iteration operations, animation, and - // node manipulation. NodeLists are most often returned as the - // result of dojo/query() calls. - // description: - // NodeList instances provide many utilities that reflect - // core Dojo APIs for Array iteration and manipulation, DOM - // manipulation, and event handling. Instead of needing to dig up - // functions in the dojo package, NodeLists generally make the - // full power of Dojo available for DOM manipulation tasks in a - // simple, chainable way. - // example: - // create a node list from a node - // | require(["dojo/query", "dojo/dom" - // | ], function(query, dom){ - // | query.NodeList(dom.byId("foo")); - // | }); - // example: - // get a NodeList from a CSS query and iterate on it - // | require(["dojo/on", "dojo/dom" - // | ], function(on, dom){ - // | var l = query(".thinger"); - // | l.forEach(function(node, index, nodeList){ - // | console.log(index, node.innerHTML); - // | }); - // | }); - // example: - // use native and Dojo-provided array methods to manipulate a - // NodeList without needing to use dojo.* functions explicitly: - // | require(["dojo/query", "dojo/dom-construct", "dojo/dom" - // | ], function(query, domConstruct, dom){ - // | var l = query(".thinger"); - // | // since NodeLists are real arrays, they have a length - // | // property that is both readable and writable and - // | // push/pop/shift/unshift methods - // | console.log(l.length); - // | l.push(domConstruct.create("span")); - // | - // | // dojo's normalized array methods work too: - // | console.log( l.indexOf(dom.byId("foo")) ); - // | // ...including the special "function as string" shorthand - // | console.log( l.every("item.nodeType == 1") ); - // | - // | // NodeLists can be [..] indexed, or you can use the at() - // | // function to get specific items wrapped in a new NodeList: - // | var node = l[3]; // the 4th element - // | var newList = l.at(1, 3); // the 2nd and 4th elements - // | }); - // example: - // chainability is a key advantage of NodeLists: - // | require(["dojo/query", "dojo/NodeList-dom" - // | ], function(query){ - // | query(".thinger") - // | .onclick(function(e){ /* ... */ }) - // | .at(1, 3, 8) // get a subset - // | .style("padding", "5px") - // | .forEach(console.log); - // | }); - - var isNew = this instanceof nl && has("array-extensible"); - if(typeof array == "number"){ - array = Array(array); - } - var nodeArray = (array && "length" in array) ? array : arguments; - if(isNew || !nodeArray.sort){ - // make sure it's a real array before we pass it on to be wrapped - var target = isNew ? this : [], - l = target.length = nodeArray.length; - for(var i = 0; i < l; i++){ - target[i] = nodeArray[i]; - } - if(isNew){ - // called with new operator, this means we are going to use this instance and push - // the nodes on to it. This is usually much faster since the NodeList properties - // don't need to be copied (unless the list of nodes is extremely large). - return target; - } - nodeArray = target; - } - // called without new operator, use a real array and copy prototype properties, - // this is slower and exists for back-compat. Should be removed in 2.0. - lang._mixin(nodeArray, nlp); - nodeArray._NodeListCtor = function(array){ - // call without new operator to preserve back-compat behavior - return nl(array); - }; - return nodeArray; - }; - - var nl = NodeList, nlp = nl.prototype = - has("array-extensible") ? [] : {};// extend an array if it is extensible - - // expose adapters and the wrapper as private functions - - nl._wrap = nlp._wrap = tnl; - nl._adaptAsMap = adaptAsMap; - nl._adaptAsForEach = adaptAsForEach; - nl._adaptAsFilter = adaptAsFilter; - nl._adaptWithCondition = adaptWithCondition; - - // mass assignment - - // add array redirectors - forEach(["slice", "splice"], function(name){ - var f = ap[name]; - //Use a copy of the this array via this.slice() to allow .end() to work right in the splice case. - // CANNOT apply ._stash()/end() to splice since it currently modifies - // the existing this array -- it would break backward compatibility if we copy the array before - // the splice so that we can use .end(). So only doing the stash option to this._wrap for slice. - nlp[name] = function(){ return this._wrap(f.apply(this, arguments), name == "slice" ? this : null); }; - }); - // concat should be here but some browsers with native NodeList have problems with it - - // add array.js redirectors - forEach(["indexOf", "lastIndexOf", "every", "some"], function(name){ - var f = array[name]; - nlp[name] = function(){ return f.apply(dojo, [this].concat(aps.call(arguments, 0))); }; - }); - - lang.extend(NodeList, { - // copy the constructors - constructor: nl, - _NodeListCtor: nl, - toString: function(){ - // Array.prototype.toString can't be applied to objects, so we use join - return this.join(","); - }, - _stash: function(parent){ - // summary: - // private function to hold to a parent NodeList. end() to return the parent NodeList. - // - // example: - // How to make a `dojo/NodeList` method that only returns the third node in - // the dojo/NodeList but allows access to the original NodeList by using this._stash: - // | require(["dojo/query", "dojo/_base/lang", "dojo/NodeList", "dojo/NodeList-dom" - // | ], function(query, lang){ - // | lang.extend(NodeList, { - // | third: function(){ - // | var newNodeList = NodeList(this[2]); - // | return newNodeList._stash(this); - // | } - // | }); - // | // then see how _stash applies a sub-list, to be .end()'ed out of - // | query(".foo") - // | .third() - // | .addClass("thirdFoo") - // | .end() - // | // access to the orig .foo list - // | .removeClass("foo") - // | }); - // - this._parent = parent; - return this; // dojo/NodeList - }, - - on: function(eventName, listener){ - // summary: - // Listen for events on the nodes in the NodeList. Basic usage is: - // - // example: - // | require(["dojo/query" - // | ], function(query){ - // | query(".my-class").on("click", listener); - // This supports event delegation by using selectors as the first argument with the event names as - // pseudo selectors. For example: - // | query("#my-list").on("li:click", listener); - // This will listen for click events within `<li>` elements that are inside the `#my-list` element. - // Because on supports CSS selector syntax, we can use comma-delimited events as well: - // | query("#my-list").on("li button:mouseover, li:click", listener); - // | }); - var handles = this.map(function(node){ - return on(node, eventName, listener); // TODO: apply to the NodeList so the same selector engine is used for matches - }); - handles.remove = function(){ - for(var i = 0; i < handles.length; i++){ - handles[i].remove(); - } - }; - return handles; - }, - - end: function(){ - // summary: - // Ends use of the current `NodeList` by returning the previous NodeList - // that generated the current NodeList. - // description: - // Returns the `NodeList` that generated the current `NodeList`. If there - // is no parent NodeList, an empty NodeList is returned. - // example: - // | require(["dojo/query", "dojo/NodeList-dom" - // | ], function(query){ - // | query("a") - // | .filter(".disabled") - // | // operate on the anchors that only have a disabled class - // | .style("color", "grey") - // | .end() - // | // jump back to the list of anchors - // | .style(...) - // | }); - // - if(this._parent){ - return this._parent; - }else{ - //Just return empty list. - return new this._NodeListCtor(0); - } - }, - - // http://developer.mozilla.org/en/docs/Core_JavaScript_1.5_Reference:Global_Objects:Array#Methods - - // FIXME: handle return values for #3244 - // http://trac.dojotoolkit.org/ticket/3244 - - // FIXME: - // need to wrap or implement: - // join (perhaps w/ innerHTML/outerHTML overload for toString() of items?) - // reduce - // reduceRight - - /*===== - slice: function(begin, end){ - // summary: - // Returns a new NodeList, maintaining this one in place - // description: - // This method behaves exactly like the Array.slice method - // with the caveat that it returns a `dojo/NodeList` and not a - // raw Array. For more details, see Mozilla's [slice - // documentation](https://developer.mozilla.org/en/JavaScript/Reference/Global_Objects/Array/slice) - // begin: Integer - // Can be a positive or negative integer, with positive - // integers noting the offset to begin at, and negative - // integers denoting an offset from the end (i.e., to the left - // of the end) - // end: Integer? - // Optional parameter to describe what position relative to - // the NodeList's zero index to end the slice at. Like begin, - // can be positive or negative. - return this._wrap(a.slice.apply(this, arguments)); - }, - - splice: function(index, howmany, item){ - // summary: - // Returns a new NodeList, manipulating this NodeList based on - // the arguments passed, potentially splicing in new elements - // at an offset, optionally deleting elements - // description: - // This method behaves exactly like the Array.splice method - // with the caveat that it returns a `dojo/NodeList` and not a - // raw Array. For more details, see Mozilla's [splice - // documentation](https://developer.mozilla.org/en/JavaScript/Reference/Global_Objects/Array/splice) - // For backwards compatibility, calling .end() on the spliced NodeList - // does not return the original NodeList -- splice alters the NodeList in place. - // index: Integer - // begin can be a positive or negative integer, with positive - // integers noting the offset to begin at, and negative - // integers denoting an offset from the end (i.e., to the left - // of the end) - // howmany: Integer? - // Optional parameter to describe what position relative to - // the NodeList's zero index to end the slice at. Like begin, - // can be positive or negative. - // item: Object...? - // Any number of optional parameters may be passed in to be - // spliced into the NodeList - return this._wrap(a.splice.apply(this, arguments)); // dojo/NodeList - }, - - indexOf: function(value, fromIndex){ - // summary: - // see `dojo/_base/array.indexOf()`. The primary difference is that the acted-on - // array is implicitly this NodeList - // value: Object - // The value to search for. - // fromIndex: Integer? - // The location to start searching from. Optional. Defaults to 0. - // description: - // For more details on the behavior of indexOf, see Mozilla's - // [indexOf - // docs](https://developer.mozilla.org/en/JavaScript/Reference/Global_Objects/Array/indexOf) - // returns: - // Positive Integer or 0 for a match, -1 of not found. - return d.indexOf(this, value, fromIndex); // Integer - }, - - lastIndexOf: function(value, fromIndex){ - // summary: - // see `dojo/_base/array.lastIndexOf()`. The primary difference is that the - // acted-on array is implicitly this NodeList - // description: - // For more details on the behavior of lastIndexOf, see - // Mozilla's [lastIndexOf - // docs](https://developer.mozilla.org/en/JavaScript/Reference/Global_Objects/Array/lastIndexOf) - // value: Object - // The value to search for. - // fromIndex: Integer? - // The location to start searching from. Optional. Defaults to 0. - // returns: - // Positive Integer or 0 for a match, -1 of not found. - return d.lastIndexOf(this, value, fromIndex); // Integer - }, - - every: function(callback, thisObject){ - // summary: - // see `dojo/_base/array.every()` and the [Array.every - // docs](https://developer.mozilla.org/en/JavaScript/Reference/Global_Objects/Array/every). - // Takes the same structure of arguments and returns as - // dojo/_base/array.every() with the caveat that the passed array is - // implicitly this NodeList - // callback: Function - // the callback - // thisObject: Object? - // the context - return d.every(this, callback, thisObject); // Boolean - }, - - some: function(callback, thisObject){ - // summary: - // Takes the same structure of arguments and returns as - // `dojo/_base/array.some()` with the caveat that the passed array is - // implicitly this NodeList. See `dojo/_base/array.some()` and Mozilla's - // [Array.some - // documentation](https://developer.mozilla.org/en/JavaScript/Reference/Global_Objects/Array/some). - // callback: Function - // the callback - // thisObject: Object? - // the context - return d.some(this, callback, thisObject); // Boolean - }, - =====*/ - - concat: function(item){ - // summary: - // Returns a new NodeList comprised of items in this NodeList - // as well as items passed in as parameters - // description: - // This method behaves exactly like the Array.concat method - // with the caveat that it returns a `NodeList` and not a - // raw Array. For more details, see the [Array.concat - // docs](https://developer.mozilla.org/en/JavaScript/Reference/Global_Objects/Array/concat) - // item: Object? - // Any number of optional parameters may be passed in to be - // spliced into the NodeList - - //return this._wrap(apc.apply(this, arguments)); - // the line above won't work for the native NodeList, or for Dojo NodeLists either :-( - - // implementation notes: - // Array.concat() doesn't recognize native NodeLists or Dojo NodeLists - // as arrays, and so does not inline them into a unioned array, but - // appends them as single entities. Both the original NodeList and the - // items passed in as parameters must be converted to raw Arrays - // and then the concatenation result may be re-_wrap()ed as a Dojo NodeList. - - var t = aps.call(this, 0), - m = array.map(arguments, function(a){ - return aps.call(a, 0); - }); - return this._wrap(apc.apply(t, m), this); // dojo/NodeList - }, - - map: function(/*Function*/ func, /*Function?*/ obj){ - // summary: - // see `dojo/_base/array.map()`. The primary difference is that the acted-on - // array is implicitly this NodeList and the return is a - // NodeList (a subclass of Array) - return this._wrap(array.map(this, func, obj), this); // dojo/NodeList - }, - - forEach: function(callback, thisObj){ - // summary: - // see `dojo/_base/array.forEach()`. The primary difference is that the acted-on - // array is implicitly this NodeList. If you want the option to break out - // of the forEach loop, use every() or some() instead. - forEach(this, callback, thisObj); - // non-standard return to allow easier chaining - return this; // dojo/NodeList - }, - filter: function(/*String|Function*/ filter){ - // summary: - // "masks" the built-in javascript filter() method (supported - // in Dojo via `dojo/_base/array.filter`) to support passing a simple - // string filter in addition to supporting filtering function - // objects. - // filter: - // If a string, a CSS rule like ".thinger" or "div > span". - // example: - // "regular" JS filter syntax as exposed in `dojo/_base/array.filter`: - // | require(["dojo/query", "dojo/NodeList-dom" - // | ], function(query){ - // | query("*").filter(function(item){ - // | // highlight every paragraph - // | return (item.nodeName == "p"); - // | }).style("backgroundColor", "yellow"); - // | }); - // example: - // the same filtering using a CSS selector - // | require(["dojo/query", "dojo/NodeList-dom" - // | ], function(query){ - // | query("*").filter("p").styles("backgroundColor", "yellow"); - // | }); - - var a = arguments, items = this, start = 0; - if(typeof filter == "string"){ // inline'd type check - items = query._filterResult(this, a[0]); - if(a.length == 1){ - // if we only got a string query, pass back the filtered results - return items._stash(this); // dojo/NodeList - } - // if we got a callback, run it over the filtered items - start = 1; - } - return this._wrap(array.filter(items, a[start], a[start + 1]), this); // dojo/NodeList - }, - instantiate: function(/*String|Object*/ declaredClass, /*Object?*/ properties){ - // summary: - // Create a new instance of a specified class, using the - // specified properties and each node in the NodeList as a - // srcNodeRef. - // example: - // Grabs all buttons in the page and converts them to dijit/form/Button's. - // | var buttons = query("button").instantiate(Button, {showLabel: true}); - var c = lang.isFunction(declaredClass) ? declaredClass : lang.getObject(declaredClass); - properties = properties || {}; - return this.forEach(function(node){ - new c(properties, node); - }); // dojo/NodeList - }, - at: function(/*===== index =====*/){ - // summary: - // Returns a new NodeList comprised of items in this NodeList - // at the given index or indices. - // - // index: Integer... - // One or more 0-based indices of items in the current - // NodeList. A negative index will start at the end of the - // list and go backwards. - // - // example: - // Shorten the list to the first, second, and third elements - // | require(["dojo/query" - // | ], function(query){ - // | query("a").at(0, 1, 2).forEach(fn); - // | }); - // - // example: - // Retrieve the first and last elements of a unordered list: - // | require(["dojo/query" - // | ], function(query){ - // | query("ul > li").at(0, -1).forEach(cb); - // | }); - // - // example: - // Do something for the first element only, but end() out back to - // the original list and continue chaining: - // | require(["dojo/query" - // | ], function(query){ - // | query("a").at(0).onclick(fn).end().forEach(function(n){ - // | console.log(n); // all anchors on the page. - // | }) - // | }); - - var t = new this._NodeListCtor(0); - forEach(arguments, function(i){ - if(i < 0){ i = this.length + i; } - if(this[i]){ t.push(this[i]); } - }, this); - return t._stash(this); // dojo/NodeList - } - }); - - function queryForEngine(engine, NodeList){ - var query = function(/*String*/ query, /*String|DOMNode?*/ root){ - // summary: - // Returns nodes which match the given CSS selector, searching the - // entire document by default but optionally taking a node to scope - // the search by. Returns an instance of NodeList. - if(typeof root == "string"){ - root = dom.byId(root); - if(!root){ - return new NodeList([]); - } - } - var results = typeof query == "string" ? engine(query, root) : query ? (query.end && query.on) ? query : [query] : []; - if(results.end && results.on){ - // already wrapped - return results; - } - return new NodeList(results); - }; - query.matches = engine.match || function(node, selector, root){ - // summary: - // Test to see if a node matches a selector - return query.filter([node], selector, root).length > 0; - }; - // the engine provides a filtering function, use it to for matching - query.filter = engine.filter || function(nodes, selector, root){ - // summary: - // Filters an array of nodes. Note that this does not guarantee to return a NodeList, just an array. - return query(selector, root).filter(function(node){ - return array.indexOf(nodes, node) > -1; - }); - }; - if(typeof engine != "function"){ - var search = engine.search; - engine = function(selector, root){ - // Slick does it backwards (or everyone else does it backwards, probably the latter) - return search(root || document, selector); - }; - } - return query; - } - var query = queryForEngine(defaultEngine, NodeList); - /*===== - query = function(selector, context){ - // summary: - // This modules provides DOM querying functionality. The module export is a function - // that can be used to query for DOM nodes by CSS selector and returns a NodeList - // representing the matching nodes. - // selector: String - // A CSS selector to search for. - // context: String|DomNode? - // An optional context to limit the searching scope. Only nodes under `context` will be - // scanned. - // example: - // add an onclick handler to every submit button in the document - // which causes the form to be sent via Ajax instead: - // | require(["dojo/query", "dojo/request", "dojo/dom-form", "dojo/dom-construct", "dojo/dom-style" - // | ], function(query, request, domForm, domConstruct, domStyle){ - // | query("input[type='submit']").on("click", function(e){ - // | e.preventDefault(); // prevent sending the form - // | var btn = e.target; - // | request.post("http://example.com/", { - // | data: domForm.toObject(btn.form) - // | }).then(function(response){ - // | // replace the form with the response - // | domConstruct.create(div, {innerHTML: response}, btn.form, "after"); - // | domStyle.set(btn.form, "display", "none"); - // | }); - // | }); - // | }); - // - // description: - // dojo/query is responsible for loading the appropriate query engine and wrapping - // its results with a `NodeList`. You can use dojo/query with a specific selector engine - // by using it as a plugin. For example, if you installed the sizzle package, you could - // use it as the selector engine with: - // | require(["dojo/query!sizzle"], function(query){ - // | query("div")... - // - // The id after the ! can be a module id of the selector engine or one of the following values: - // - // - acme: This is the default engine used by Dojo base, and will ensure that the full - // Acme engine is always loaded. - // - // - css2: If the browser has a native selector engine, this will be used, otherwise a - // very minimal lightweight selector engine will be loaded that can do simple CSS2 selectors - // (by #id, .class, tag, and [name=value] attributes, with standard child or descendant (>) - // operators) and nothing more. - // - // - css2.1: If the browser has a native selector engine, this will be used, otherwise the - // full Acme engine will be loaded. - // - // - css3: If the browser has a native selector engine with support for CSS3 pseudo - // selectors (most modern browsers except IE8), this will be used, otherwise the - // full Acme engine will be loaded. - // - // - Or the module id of a selector engine can be used to explicitly choose the selector engine - // - // For example, if you are using CSS3 pseudo selectors in module, you can specify that - // you will need support them with: - // | require(["dojo/query!css3"], function(query){ - // | query('#t > h3:nth-child(odd)')... - // - // You can also choose the selector engine/load configuration by setting the query-selector: - // For example: - // | <script data-dojo-config="query-selector:'css3'" src="dojo.js"></script> - // - return new NodeList(); // dojo/NodeList - }; - =====*/ - - // the query that is returned from this module is slightly different than dojo.query, - // because dojo.query has to maintain backwards compatibility with returning a - // true array which has performance problems. The query returned from the module - // does not use true arrays, but rather inherits from Array, making it much faster to - // instantiate. - dojo.query = queryForEngine(defaultEngine, function(array){ - // call it without the new operator to invoke the back-compat behavior that returns a true array - return NodeList(array); // dojo/NodeList - }); - - query.load = function(id, parentRequire, loaded){ - // summary: - // can be used as AMD plugin to conditionally load new query engine - // example: - // | require(["dojo/query!custom"], function(qsa){ - // | // loaded selector/custom.js as engine - // | qsa("#foobar").forEach(...); - // | }); - loader.load(id, parentRequire, function(engine){ - loaded(queryForEngine(engine, NodeList)); - }); - }; - - dojo._filterQueryResult = query._filterResult = function(nodes, selector, root){ - return new NodeList(query.filter(nodes, selector, root)); - }; - dojo.NodeList = query.NodeList = NodeList; - return query; -}); diff --git a/lib/dojo/ready.js b/lib/dojo/ready.js deleted file mode 100644 index ffe9a42..0000000 --- a/lib/dojo/ready.js +++ /dev/null @@ -1,77 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/ready",["./_base/kernel","./has","require","./domReady","./_base/lang"],function(_1,_2,_3,_4,_5){ -var _6=0,_7=[],_8=0,_9=function(){ -_6=1; -_1._postLoad=_1.config.afterOnLoad=true; -_a(); -},_a=function(){ -if(_8){ -return; -} -_8=1; -while(_6&&(!_4||_4._Q.length==0)&&(_3.idle?_3.idle():true)&&_7.length){ -var f=_7.shift(); -try{ -f(); -} -catch(e){ -e.info=e.message; -if(_3.signal){ -_3.signal("error",e); -}else{ -throw e; -} -} -} -_8=0; -}; -_3.on&&_3.on("idle",_a); -if(_4){ -_4._onQEmpty=_a; -} -var _b=_1.ready=_1.addOnLoad=function(_c,_d,_e){ -var _f=_5._toArray(arguments); -if(typeof _c!="number"){ -_e=_d; -_d=_c; -_c=1000; -}else{ -_f.shift(); -} -_e=_e?_5.hitch.apply(_1,_f):function(){ -_d(); -}; -_e.priority=_c; -for(var i=0;i<_7.length&&_c>=_7[i].priority;i++){ -} -_7.splice(i,0,_e); -_a(); -}; -1||_2.add("dojo-config-addOnLoad",1); -if(1){ -var dca=_1.config.addOnLoad; -if(dca){ -_b[(_5.isArray(dca)?"apply":"call")](_1,dca); -} -} -if(1&&_1.config.parseOnLoad&&!_1.isAsync){ -_b(99,function(){ -if(!_1.parser){ -_1.deprecated("Add explicit require(['dojo/parser']);","","2.0"); -_3(["dojo/parser"]); -} -}); -} -if(_4){ -_4(_9); -}else{ -_9(); -} -return _b; -}); diff --git a/lib/dojo/ready.js.uncompressed.js b/lib/dojo/ready.js.uncompressed.js deleted file mode 100644 index 05052b3..0000000 --- a/lib/dojo/ready.js.uncompressed.js +++ /dev/null @@ -1,153 +0,0 @@ -define("dojo/ready", ["./_base/kernel", "./has", "require", "./domReady", "./_base/lang"], function(dojo, has, require, domReady, lang){ - // module: - // dojo/ready - // note: - // This module should be unnecessary in dojo 2.0 - - var - // truthy if DOMContentLoaded or better (e.g., window.onload fired) has been achieved - isDomReady = 0, - - // The queue of functions waiting to execute as soon as dojo.ready conditions satisfied - loadQ = [], - - // prevent recursion in onLoad - onLoadRecursiveGuard = 0, - - handleDomReady = function(){ - isDomReady = 1; - dojo._postLoad = dojo.config.afterOnLoad = true; - onEvent(); - }, - - onEvent = function(){ - // Called when some state changes: - // - dom ready - // - dojo/domReady has finished processing everything in its queue - // - task added to loadQ - // - require() has finished loading all currently requested modules - // - // Run the functions queued with dojo.ready if appropriate. - - - //guard against recursions into this function - if(onLoadRecursiveGuard){ - return; - } - onLoadRecursiveGuard = 1; - - // Run tasks in queue if require() is finished loading modules, the dom is ready, and there are no - // pending tasks registered via domReady(). - // The last step is necessary so that a user defined dojo.ready() callback is delayed until after the - // domReady() calls inside of dojo. Failure can be seen on dijit/tests/robot/Dialog_ally.html on IE8 - // because the dijit/focus.js domReady() callback doesn't execute until after the test starts running. - while(isDomReady && (!domReady || domReady._Q.length == 0) && (require.idle ? require.idle() : true) && loadQ.length){ - var f = loadQ.shift(); - try{ - f(); - }catch(e){ - // force the dojo.js on("error") handler do display the message - e.info = e.message; - if(require.signal){ - require.signal("error", e); - }else{ - throw e; - } - } - } - - onLoadRecursiveGuard = 0; - }; - - // Check if we should run the next queue operation whenever require() finishes loading modules or domReady - // finishes processing it's queue. - require.on && require.on("idle", onEvent); - if(domReady){ - domReady._onQEmpty = onEvent; - } - - var ready = dojo.ready = dojo.addOnLoad = function(priority, context, callback){ - // summary: - // Add a function to execute on DOM content loaded and all requested modules have arrived and been evaluated. - // In most cases, the `domReady` plug-in should suffice and this method should not be needed. - // - // When called in a non-browser environment, just checks that all requested modules have arrived and been - // evaluated. - // priority: Integer? - // The order in which to exec this callback relative to other callbacks, defaults to 1000 - // context: Object?|Function - // The context in which to run execute callback, or a callback if not using context - // callback: Function? - // The function to execute. - // - // example: - // Simple DOM and Modules ready syntax - // | require(["dojo/ready"], function(ready){ - // | ready(function(){ alert("Dom ready!"); }); - // | }); - // - // example: - // Using a priority - // | require(["dojo/ready"], function(ready){ - // | ready(2, function(){ alert("low priority ready!"); }) - // | }); - // - // example: - // Using context - // | require(["dojo/ready"], function(ready){ - // | ready(foo, function(){ - // | // in here, this == foo - // | }); - // | }); - // - // example: - // Using dojo/hitch style args: - // | require(["dojo/ready"], function(ready){ - // | var foo = { dojoReady: function(){ console.warn(this, "dojo dom and modules ready."); } }; - // | ready(foo, "dojoReady"); - // | }); - - var hitchArgs = lang._toArray(arguments); - if(typeof priority != "number"){ - callback = context; - context = priority; - priority = 1000; - }else{ - hitchArgs.shift(); - } - callback = callback ? - lang.hitch.apply(dojo, hitchArgs) : - function(){ - context(); - }; - callback.priority = priority; - for(var i = 0; i < loadQ.length && priority >= loadQ[i].priority; i++){} - loadQ.splice(i, 0, callback); - onEvent(); - }; - - 1 || has.add("dojo-config-addOnLoad", 1); - if( 1 ){ - var dca = dojo.config.addOnLoad; - if(dca){ - ready[(lang.isArray(dca) ? "apply" : "call")](dojo, dca); - } - } - - if( 1 && dojo.config.parseOnLoad && !dojo.isAsync){ - ready(99, function(){ - if(!dojo.parser){ - dojo.deprecated("Add explicit require(['dojo/parser']);", "", "2.0"); - require(["dojo/parser"]); - } - }); - } - - if(domReady){ - domReady(handleDomReady); - }else{ - handleDomReady(); - } - - return ready; -}); diff --git a/lib/dojo/regexp.js b/lib/dojo/regexp.js deleted file mode 100644 index 38fd0dd..0000000 --- a/lib/dojo/regexp.js +++ /dev/null @@ -1,33 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/regexp",["./_base/kernel","./_base/lang"],function(_1,_2){ -var _3={}; -_2.setObject("dojo.regexp",_3); -_3.escapeString=function(_4,_5){ -return _4.replace(/([\.$?*|{}\(\)\[\]\\\/\+\-^])/g,function(ch){ -if(_5&&_5.indexOf(ch)!=-1){ -return ch; -} -return "\\"+ch; -}); -}; -_3.buildGroupRE=function(_6,re,_7){ -if(!(_6 instanceof Array)){ -return re(_6); -} -var b=[]; -for(var i=0;i<_6.length;i++){ -b.push(re(_6[i])); -} -return _3.group(b.join("|"),_7); -}; -_3.group=function(_8,_9){ -return "("+(_9?"?:":"")+_8+")"; -}; -return _3; -}); diff --git a/lib/dojo/regexp.js.uncompressed.js b/lib/dojo/regexp.js.uncompressed.js deleted file mode 100644 index f36647c..0000000 --- a/lib/dojo/regexp.js.uncompressed.js +++ /dev/null @@ -1,70 +0,0 @@ -define("dojo/regexp", ["./_base/kernel", "./_base/lang"], function(dojo, lang){ - -// module: -// dojo/regexp - -var regexp = { - // summary: - // Regular expressions and Builder resources -}; -lang.setObject("dojo.regexp", regexp); - -regexp.escapeString = function(/*String*/str, /*String?*/except){ - // summary: - // Adds escape sequences for special characters in regular expressions - // except: - // a String with special characters to be left unescaped - - return str.replace(/([\.$?*|{}\(\)\[\]\\\/\+\-^])/g, function(ch){ - if(except && except.indexOf(ch) != -1){ - return ch; - } - return "\\" + ch; - }); // String -}; - -regexp.buildGroupRE = function(/*Object|Array*/arr, /*Function*/re, /*Boolean?*/nonCapture){ - // summary: - // Builds a regular expression that groups subexpressions - // description: - // A utility function used by some of the RE generators. The - // subexpressions are constructed by the function, re, in the second - // parameter. re builds one subexpression for each elem in the array - // a, in the first parameter. Returns a string for a regular - // expression that groups all the subexpressions. - // arr: - // A single value or an array of values. - // re: - // A function. Takes one parameter and converts it to a regular - // expression. - // nonCapture: - // If true, uses non-capturing match, otherwise matches are retained - // by regular expression. Defaults to false - - // case 1: a is a single value. - if(!(arr instanceof Array)){ - return re(arr); // String - } - - // case 2: a is an array - var b = []; - for(var i = 0; i < arr.length; i++){ - // convert each elem to a RE - b.push(re(arr[i])); - } - - // join the REs as alternatives in a RE group. - return regexp.group(b.join("|"), nonCapture); // String -}; - -regexp.group = function(/*String*/expression, /*Boolean?*/nonCapture){ - // summary: - // adds group match to expression - // nonCapture: - // If true, uses non-capturing match, otherwise matches are retained - // by regular expression. - return "(" + (nonCapture ? "?:":"") + expression + ")"; // String -}; - -return regexp; -}); diff --git a/lib/dojo/request.js b/lib/dojo/request.js deleted file mode 100644 index 5479886..0000000 --- a/lib/dojo/request.js +++ /dev/null @@ -1,10 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/request",["./request/default!"],function(_1){ -return _1; -}); diff --git a/lib/dojo/request.js.uncompressed.js b/lib/dojo/request.js.uncompressed.js deleted file mode 100644 index 75e42bd..0000000 --- a/lib/dojo/request.js.uncompressed.js +++ /dev/null @@ -1,81 +0,0 @@ -define("dojo/request", [ - './request/default!'/*=====, - './_base/declare', - './promise/Promise' =====*/ -], function(request/*=====, declare, Promise =====*/){ - /*===== - request = function(url, options){ - // summary: - // Send a request using the default transport for the current platform. - // url: String - // The URL to request. - // options: dojo/request.__Options? - // Options for the request. - // returns: dojo/request.__Promise - }; - request.__Promise = declare(Promise, { - // response: dojo/promise/Promise - // A promise resolving to an object representing - // the response from the server. - }); - request.__BaseOptions = declare(null, { - // query: String|Object? - // Query parameters to append to the URL. - // data: String|Object? - // Data to transfer. This is ignored for GET and DELETE - // requests. - // preventCache: Boolean? - // Whether to append a cache-busting parameter to the URL. - // timeout: Integer? - // Milliseconds to wait for the response. If this time - // passes, the then the promise is rejected. - // handleAs: String? - // How to handle the response from the server. Default is - // 'text'. Other values are 'json', 'javascript', and 'xml'. - }); - request.__MethodOptions = declare(null, { - // method: String? - // The HTTP method to use to make the request. Must be - // uppercase. - }); - request.__Options = declare([request.__BaseOptions, request.__MethodOptions]); - - request.get = function(url, options){ - // summary: - // Send an HTTP GET request using the default transport for the current platform. - // url: String - // URL to request - // options: dojo/request.__BaseOptions? - // Options for the request. - // returns: dojo/request.__Promise - }; - request.post = function(url, options){ - // summary: - // Send an HTTP POST request using the default transport for the current platform. - // url: String - // URL to request - // options: dojo/request.__BaseOptions? - // Options for the request. - // returns: dojo/request.__Promise - }; - request.put = function(url, options){ - // summary: - // Send an HTTP POST request using the default transport for the current platform. - // url: String - // URL to request - // options: dojo/request.__BaseOptions? - // Options for the request. - // returns: dojo/request.__Promise - }; - request.del = function(url, options){ - // summary: - // Send an HTTP DELETE request using the default transport for the current platform. - // url: String - // URL to request - // options: dojo/request.__BaseOptions? - // Options for the request. - // returns: dojo/request.__Promise - }; - =====*/ - return request; -}); diff --git a/lib/dojo/request/default.js b/lib/dojo/request/default.js deleted file mode 100644 index ac55efd..0000000 --- a/lib/dojo/request/default.js +++ /dev/null @@ -1,28 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/request/default",["exports","require","../has"],function(_1,_2,_3){ -var _4=_3("config-requestProvider"),_5; -if(1||_3("host-webworker")){ -_5="./xhr"; -}else{ -if(0){ -_5="./node"; -} -} -if(!_4){ -_4=_5; -} -_1.getPlatformDefaultId=function(){ -return _5; -}; -_1.load=function(id,_6,_7,_8){ -_2([id=="platform"?_5:_4],function(_9){ -_7(_9); -}); -}; -}); diff --git a/lib/dojo/request/default.js.uncompressed.js b/lib/dojo/request/default.js.uncompressed.js deleted file mode 100644 index 39d6043..0000000 --- a/lib/dojo/request/default.js.uncompressed.js +++ /dev/null @@ -1,32 +0,0 @@ -define("dojo/request/default", [ - 'exports', - 'require', - '../has' -], function(exports, require, has){ - var defId = has('config-requestProvider'), - platformId; - - if( 1 || has('host-webworker')){ - platformId = './xhr'; - }else if( 0 ){ - platformId = './node'; - /* TODO: - }else if( 0 ){ - platformId = './rhino'; - */ - } - - if(!defId){ - defId = platformId; - } - - exports.getPlatformDefaultId = function(){ - return platformId; - }; - - exports.load = function(id, parentRequire, loaded, config){ - require([id == 'platform' ? platformId : defId], function(provider){ - loaded(provider); - }); - }; -}); diff --git a/lib/dojo/request/handlers.js b/lib/dojo/request/handlers.js deleted file mode 100644 index 5673296..0000000 --- a/lib/dojo/request/handlers.js +++ /dev/null @@ -1,61 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/request/handlers",["../json","../_base/kernel","../_base/array","../has","../selector/_loader"],function(_1,_2,_3,_4){ -_4.add("activex",typeof ActiveXObject!=="undefined"); -_4.add("dom-parser",function(_5){ -return "DOMParser" in _5; -}); -var _6; -if(_4("activex")){ -var dp=["Msxml2.DOMDocument.6.0","Msxml2.DOMDocument.4.0","MSXML2.DOMDocument.3.0","MSXML.DOMDocument"]; -var _7; -_6=function(_8){ -var _9=_8.data; -var _a=_8.text; -if(_9&&_4("dom-qsa2.1")&&!_9.querySelectorAll&&_4("dom-parser")){ -_9=new DOMParser().parseFromString(_a,"application/xml"); -} -function _b(p){ -try{ -var _c=new ActiveXObject(p); -_c.async=false; -_c.loadXML(_a); -_9=_c; -_7=p; -} -catch(e){ -return false; -} -return true; -}; -if(!_9||!_9.documentElement){ -if(!_7||!_b(_7)){ -_3.some(dp,_b); -} -} -return _9; -}; -} -var _d=function(_e){ -return _e.xhr.response; -}; -var _f={"javascript":function(_10){ -return _2.eval(_10.text||""); -},"json":function(_11){ -return _1.parse(_11.text||null); -},"xml":_6,"blob":_d,"arraybuffer":_d,"document":_d}; -function _12(_13){ -var _14=_f[_13.options.handleAs]; -_13.data=_14?_14(_13):(_13.data||_13.text); -return _13; -}; -_12.register=function(_15,_16){ -_f[_15]=_16; -}; -return _12; -}); diff --git a/lib/dojo/request/handlers.js.uncompressed.js b/lib/dojo/request/handlers.js.uncompressed.js deleted file mode 100644 index e30656f..0000000 --- a/lib/dojo/request/handlers.js.uncompressed.js +++ /dev/null @@ -1,94 +0,0 @@ -define("dojo/request/handlers", [ - '../json', - '../_base/kernel', - '../_base/array', - '../has', - '../selector/_loader' // only included for has() qsa tests -], function(JSON, kernel, array, has){ - has.add('activex', typeof ActiveXObject !== 'undefined'); - has.add('dom-parser', function(global){ - return 'DOMParser' in global; - }); - - var handleXML; - if(has('activex')){ - // GUIDs obtained from http://msdn.microsoft.com/en-us/library/ms757837(VS.85).aspx - var dp = [ - 'Msxml2.DOMDocument.6.0', - 'Msxml2.DOMDocument.4.0', - 'MSXML2.DOMDocument.3.0', - 'MSXML.DOMDocument' // 2.0 - ]; - var lastParser; - - handleXML = function(response){ - var result = response.data; - var text = response.text; - - if(result && has('dom-qsa2.1') && !result.querySelectorAll && has('dom-parser')){ - // http://bugs.dojotoolkit.org/ticket/15631 - // IE9 supports a CSS3 querySelectorAll implementation, but the DOM implementation - // returned by IE9 xhr.responseXML does not. Manually create the XML DOM to gain - // the fuller-featured implementation and avoid bugs caused by the inconsistency - result = new DOMParser().parseFromString(text, 'application/xml'); - } - - function createDocument(p) { - try{ - var dom = new ActiveXObject(p); - dom.async = false; - dom.loadXML(text); - result = dom; - lastParser = p; - }catch(e){ return false; } - return true; - } - - if(!result || !result.documentElement){ - // The creation of an ActiveX object is expensive, so we cache the - // parser type to avoid trying all parser types each time we handle a - // document. There is some concern that some parser types might fail - // depending on the document being parsed. If parsing using the cached - // parser type fails, we do the more expensive operation of finding one - // that works for the given document. - // https://bugs.dojotoolkit.org/ticket/15246 - if(!lastParser || !createDocument(lastParser)) { - array.some(dp, createDocument); - } - } - - return result; - }; - } - - var handleNativeResponse = function(response) { - return response.xhr.response; - } - - var handlers = { - 'javascript': function(response){ - return kernel.eval(response.text || ''); - }, - 'json': function(response){ - return JSON.parse(response.text || null); - }, - 'xml': handleXML, - 'blob': handleNativeResponse, - 'arraybuffer': handleNativeResponse, - 'document': handleNativeResponse - }; - - function handle(response){ - var handler = handlers[response.options.handleAs]; - - response.data = handler ? handler(response) : (response.data || response.text); - - return response; - } - - handle.register = function(name, handler){ - handlers[name] = handler; - }; - - return handle; -}); diff --git a/lib/dojo/request/iframe.js b/lib/dojo/request/iframe.js deleted file mode 100644 index 46a43d6..0000000 --- a/lib/dojo/request/iframe.js +++ /dev/null @@ -1,291 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/request/iframe",["module","require","./watch","./util","./handlers","../_base/lang","../io-query","../query","../has","../dom","../dom-construct","../_base/window","../NodeList-dom"],function(_1,_2,_3,_4,_5,_6,_7,_8,_9,_a,_b,_c){ -var _d=_1.id.replace(/[\/\.\-]/g,"_"),_e=_d+"_onload"; -if(!_c.global[_e]){ -_c.global[_e]=function(){ -var _f=_10._currentDfd; -if(!_f){ -_10._fireNextRequest(); -return; -} -var _11=_f.response,_12=_11.options,_13=_a.byId(_12.form)||_f._tmpForm; -if(_13){ -var _14=_f._contentToClean; -for(var i=0;i<_14.length;i++){ -var key=_14[i]; -for(var j=0;j<_13.childNodes.length;j++){ -var _15=_13.childNodes[j]; -if(_15.name===key){ -_b.destroy(_15); -break; -} -} -} -_f._originalAction&&_13.setAttribute("action",_f._originalAction); -if(_f._originalMethod){ -_13.setAttribute("method",_f._originalMethod); -_13.method=_f._originalMethod; -} -if(_f._originalTarget){ -_13.setAttribute("target",_f._originalTarget); -_13.target=_f._originalTarget; -} -} -if(_f._tmpForm){ -_b.destroy(_f._tmpForm); -delete _f._tmpForm; -} -_f._finished=true; -}; -} -function _16(_17,_18,uri){ -if(_c.global[_17]){ -return _c.global[_17]; -} -if(_c.global.frames[_17]){ -return _c.global.frames[_17]; -} -if(!uri){ -if(_9("config-useXDomain")&&!_9("config-dojoBlankHtmlUrl")){ -console.warn("dojo/request/iframe: When using cross-domain Dojo builds,"+" please save dojo/resources/blank.html to your domain and set dojoConfig.dojoBlankHtmlUrl"+" to the path on your domain to blank.html"); -} -uri=(_9("config-dojoBlankHtmlUrl")||_2.toUrl("dojo/resources/blank.html")); -} -var _19=_b.place("<iframe id=\""+_17+"\" name=\""+_17+"\" src=\""+uri+"\" onload=\""+_18+"\" style=\"position: absolute; left: 1px; top: 1px; height: 1px; width: 1px; visibility: hidden\">",_c.body()); -_c.global[_17]=_19; -return _19; -}; -function _1a(_1b,src,_1c){ -var _1d=_c.global.frames[_1b.name]; -if(_1d.contentWindow){ -_1d=_1d.contentWindow; -} -try{ -if(!_1c){ -_1d.location=src; -}else{ -_1d.location.replace(src); -} -} -catch(e){ -} -}; -function doc(_1e){ -if(_1e.contentDocument){ -return _1e.contentDocument; -} -var _1f=_1e.name; -if(_1f){ -var _20=_c.doc.getElementsByTagName("iframe"); -if(_1e.document&&_20[_1f].contentWindow&&_20[_1f].contentWindow.document){ -return _20[_1f].contentWindow.document; -}else{ -if(_c.doc.frames[_1f]&&_c.doc.frames[_1f].document){ -return _c.doc.frames[_1f].document; -} -} -} -return null; -}; -function _21(){ -return _b.create("form",{name:_d+"_form",style:{position:"absolute",top:"-1000px",left:"-1000px"}},_c.body()); -}; -function _22(){ -var dfd; -try{ -if(_10._currentDfd||!_10._dfdQueue.length){ -return; -} -do{ -dfd=_10._currentDfd=_10._dfdQueue.shift(); -}while(dfd&&(dfd.canceled||(dfd.isCanceled&&dfd.isCanceled()))&&_10._dfdQueue.length); -if(!dfd||dfd.canceled||(dfd.isCanceled&&dfd.isCanceled())){ -_10._currentDfd=null; -return; -} -var _23=dfd.response,_24=_23.options,c2c=dfd._contentToClean=[],_25=_a.byId(_24.form),_26=_4.notify,_27=_24.data||null,_28; -if(!dfd._legacy&&_24.method==="POST"&&!_25){ -_25=dfd._tmpForm=_21(); -}else{ -if(_24.method==="GET"&&_25&&_23.url.indexOf("?")>-1){ -_28=_23.url.slice(_23.url.indexOf("?")+1); -_27=_6.mixin(_7.queryToObject(_28),_27); -} -} -if(_25){ -if(!dfd._legacy){ -var _29=_25; -do{ -_29=_29.parentNode; -}while(_29!==_c.doc.documentElement); -if(!_29){ -_25.style.position="absolute"; -_25.style.left="-1000px"; -_25.style.top="-1000px"; -_c.body().appendChild(_25); -} -if(!_25.name){ -_25.name=_d+"_form"; -} -} -if(_27){ -var _2a=function(_2b,_2c){ -_b.create("input",{type:"hidden",name:_2b,value:_2c},_25); -c2c.push(_2b); -}; -for(var x in _27){ -var val=_27[x]; -if(_6.isArray(val)&&val.length>1){ -for(var i=0;i<val.length;i++){ -_2a(x,val[i]); -} -}else{ -if(!_25[x]){ -_2a(x,val); -}else{ -_25[x].value=val; -} -} -} -} -var _2d=_25.getAttributeNode("action"),_2e=_25.getAttributeNode("method"),_2f=_25.getAttributeNode("target"); -if(_23.url){ -dfd._originalAction=_2d?_2d.value:null; -if(_2d){ -_2d.value=_23.url; -}else{ -_25.setAttribute("action",_23.url); -} -} -if(!dfd._legacy){ -dfd._originalMethod=_2e?_2e.value:null; -if(_2e){ -_2e.value=_24.method; -}else{ -_25.setAttribute("method",_24.method); -} -}else{ -if(!_2e||!_2e.value){ -if(_2e){ -_2e.value=_24.method; -}else{ -_25.setAttribute("method",_24.method); -} -} -} -dfd._originalTarget=_2f?_2f.value:null; -if(_2f){ -_2f.value=_10._iframeName; -}else{ -_25.setAttribute("target",_10._iframeName); -} -_25.target=_10._iframeName; -_26&&_26.emit("send",_23,dfd.promise.cancel); -_10._notifyStart(_23); -_25.submit(); -}else{ -var _30=""; -if(_23.options.data){ -_30=_23.options.data; -if(typeof _30!=="string"){ -_30=_7.objectToQuery(_30); -} -} -var _31=_23.url+(_23.url.indexOf("?")>-1?"&":"?")+_30; -_26&&_26.emit("send",_23,dfd.promise.cancel); -_10._notifyStart(_23); -_10.setSrc(_10._frame,_31,true); -} -} -catch(e){ -dfd.reject(e); -} -}; -function _32(_33){ -return !this.isFulfilled(); -}; -function _34(_35){ -return !!this._finished; -}; -function _36(_37,_38){ -if(!_38){ -try{ -var _39=_37.options,doc=_10.doc(_10._frame),_3a=_39.handleAs; -if(_3a!=="html"){ -if(_3a==="xml"){ -if(doc.documentElement.tagName.toLowerCase()==="html"){ -_8("a",doc.documentElement).orphan(); -var _3b=doc.documentElement.innerText; -_3b=_3b.replace(/>\s+</g,"><"); -_37.text=_6.trim(_3b); -}else{ -_37.data=doc; -} -}else{ -_37.text=doc.getElementsByTagName("textarea")[0].value; -} -_5(_37); -}else{ -_37.data=doc; -} -} -catch(e){ -_38=e; -} -} -if(_38){ -this.reject(_38); -}else{ -if(this._finished){ -this.resolve(_37); -}else{ -this.reject(new Error("Invalid dojo/request/iframe request state")); -} -} -}; -function _3c(_3d){ -this._callNext(); -}; -var _3e={method:"POST"}; -function _10(url,_3f,_40){ -var _41=_4.parseArgs(url,_4.deepCreate(_3e,_3f),true); -url=_41.url; -_3f=_41.options; -if(_3f.method!=="GET"&&_3f.method!=="POST"){ -throw new Error(_3f.method+" not supported by dojo/request/iframe"); -} -if(!_10._frame){ -_10._frame=_10.create(_10._iframeName,_e+"();"); -} -var dfd=_4.deferred(_41,null,_32,_34,_36,_3c); -dfd._callNext=function(){ -if(!this._calledNext){ -this._calledNext=true; -_10._currentDfd=null; -_10._fireNextRequest(); -} -}; -dfd._legacy=_40; -_10._dfdQueue.push(dfd); -_10._fireNextRequest(); -_3(dfd); -return _40?dfd:dfd.promise; -}; -_10.create=_16; -_10.doc=doc; -_10.setSrc=_1a; -_10._iframeName=_d+"_IoIframe"; -_10._notifyStart=function(){ -}; -_10._dfdQueue=[]; -_10._currentDfd=null; -_10._fireNextRequest=_22; -_4.addCommonMethods(_10,["GET","POST"]); -return _10; -}); diff --git a/lib/dojo/request/iframe.js.uncompressed.js b/lib/dojo/request/iframe.js.uncompressed.js deleted file mode 100644 index 86fbc2b..0000000 --- a/lib/dojo/request/iframe.js.uncompressed.js +++ /dev/null @@ -1,431 +0,0 @@ -define("dojo/request/iframe", [ - 'module', - 'require', - './watch', - './util', - './handlers', - '../_base/lang', - '../io-query', - '../query', - '../has', - '../dom', - '../dom-construct', - '../_base/window', - '../NodeList-dom'/*=====, - '../request', - '../_base/declare' =====*/ -], function(module, require, watch, util, handlers, lang, ioQuery, query, has, dom, domConstruct, win/*=====, NodeList, request, declare =====*/){ - var mid = module.id.replace(/[\/\.\-]/g, '_'), - onload = mid + '_onload'; - - if(!win.global[onload]){ - win.global[onload] = function(){ - var dfd = iframe._currentDfd; - if(!dfd){ - iframe._fireNextRequest(); - return; - } - - var response = dfd.response, - options = response.options, - formNode = dom.byId(options.form) || dfd._tmpForm; - - if(formNode){ - // remove all the hidden content inputs - var toClean = dfd._contentToClean; - for(var i=0; i<toClean.length; i++){ - var key = toClean[i]; - //Need to cycle over all nodes since we may have added - //an array value which means that more than one node could - //have the same .name value. - for(var j=0; j<formNode.childNodes.length; j++){ - var childNode = formNode.childNodes[j]; - if(childNode.name === key){ - domConstruct.destroy(childNode); - break; - } - } - } - - // restore original action + target - dfd._originalAction && formNode.setAttribute('action', dfd._originalAction); - if(dfd._originalMethod){ - formNode.setAttribute('method', dfd._originalMethod); - formNode.method = dfd._originalMethod; - } - if(dfd._originalTarget){ - formNode.setAttribute('target', dfd._originalTarget); - formNode.target = dfd._originalTarget; - } - } - - if(dfd._tmpForm){ - domConstruct.destroy(dfd._tmpForm); - delete dfd._tmpForm; - } - - dfd._finished = true; - }; - } - - function create(name, onloadstr, uri){ - if(win.global[name]){ - return win.global[name]; - } - - if(win.global.frames[name]){ - return win.global.frames[name]; - } - - if(!uri){ - if(has('config-useXDomain') && !has('config-dojoBlankHtmlUrl')){ - console.warn('dojo/request/iframe: When using cross-domain Dojo builds,' + - ' please save dojo/resources/blank.html to your domain and set dojoConfig.dojoBlankHtmlUrl' + - ' to the path on your domain to blank.html'); - } - uri = (has('config-dojoBlankHtmlUrl')||require.toUrl('dojo/resources/blank.html')); - } - - var frame = domConstruct.place( - '<iframe id="'+name+'" name="'+name+'" src="'+uri+'" onload="'+onloadstr+ - '" style="position: absolute; left: 1px; top: 1px; height: 1px; width: 1px; visibility: hidden">', - win.body()); - - win.global[name] = frame; - - return frame; - } - - function setSrc(_iframe, src, replace){ - var frame = win.global.frames[_iframe.name]; - - if(frame.contentWindow){ - // We have an iframe node instead of the window - frame = frame.contentWindow; - } - - try{ - if(!replace){ - frame.location = src; - }else{ - frame.location.replace(src); - } - }catch(e){ - console.log('dojo/request/iframe.setSrc: ', e); - } - } - - function doc(iframeNode){ - if(iframeNode.contentDocument){ - return iframeNode.contentDocument; - } - var name = iframeNode.name; - if(name){ - var iframes = win.doc.getElementsByTagName('iframe'); - if(iframeNode.document && iframes[name].contentWindow && iframes[name].contentWindow.document){ - return iframes[name].contentWindow.document; - }else if(win.doc.frames[name] && win.doc.frames[name].document){ - return win.doc.frames[name].document; - } - } - return null; - } - - function createForm(){ - return domConstruct.create('form', { - name: mid + '_form', - style: { - position: 'absolute', - top: '-1000px', - left: '-1000px' - } - }, win.body()); - } - - function fireNextRequest(){ - // summary: - // Internal method used to fire the next request in the queue. - var dfd; - try{ - if(iframe._currentDfd || !iframe._dfdQueue.length){ - return; - } - do{ - dfd = iframe._currentDfd = iframe._dfdQueue.shift(); - }while(dfd && (dfd.canceled || (dfd.isCanceled && dfd.isCanceled())) && iframe._dfdQueue.length); - - if(!dfd || dfd.canceled || (dfd.isCanceled && dfd.isCanceled())){ - iframe._currentDfd = null; - return; - } - - var response = dfd.response, - options = response.options, - c2c = dfd._contentToClean = [], - formNode = dom.byId(options.form), - notify = util.notify, - data = options.data || null, - queryStr; - - if(!dfd._legacy && options.method === 'POST' && !formNode){ - formNode = dfd._tmpForm = createForm(); - }else if(options.method === 'GET' && formNode && response.url.indexOf('?') > -1){ - queryStr = response.url.slice(response.url.indexOf('?') + 1); - data = lang.mixin(ioQuery.queryToObject(queryStr), data); - } - - if(formNode){ - if(!dfd._legacy){ - var parentNode = formNode; - do{ - parentNode = parentNode.parentNode; - }while(parentNode !== win.doc.documentElement); - - // Append the form node or some browsers won't work - if(!parentNode){ - formNode.style.position = 'absolute'; - formNode.style.left = '-1000px'; - formNode.style.top = '-1000px'; - win.body().appendChild(formNode); - } - - if(!formNode.name){ - formNode.name = mid + '_form'; - } - } - - // if we have things in data, we need to add them to the form - // before submission - if(data){ - var createInput = function(name, value){ - domConstruct.create('input', { - type: 'hidden', - name: name, - value: value - }, formNode); - c2c.push(name); - }; - for(var x in data){ - var val = data[x]; - if(lang.isArray(val) && val.length > 1){ - for(var i=0; i<val.length; i++){ - createInput(x, val[i]); - } - }else{ - if(!formNode[x]){ - createInput(x, val); - }else{ - formNode[x].value = val; - } - } - } - } - - //IE requires going through getAttributeNode instead of just getAttribute in some form cases, - //so use it for all. See #2844 - var actionNode = formNode.getAttributeNode('action'), - methodNode = formNode.getAttributeNode('method'), - targetNode = formNode.getAttributeNode('target'); - - if(response.url){ - dfd._originalAction = actionNode ? actionNode.value : null; - if(actionNode){ - actionNode.value = response.url; - }else{ - formNode.setAttribute('action', response.url); - } - } - - if(!dfd._legacy){ - dfd._originalMethod = methodNode ? methodNode.value : null; - if(methodNode){ - methodNode.value = options.method; - }else{ - formNode.setAttribute('method', options.method); - } - }else{ - if(!methodNode || !methodNode.value){ - if(methodNode){ - methodNode.value = options.method; - }else{ - formNode.setAttribute('method', options.method); - } - } - } - - dfd._originalTarget = targetNode ? targetNode.value : null; - if(targetNode){ - targetNode.value = iframe._iframeName; - }else{ - formNode.setAttribute('target', iframe._iframeName); - } - formNode.target = iframe._iframeName; - - notify && notify.emit('send', response, dfd.promise.cancel); - iframe._notifyStart(response); - formNode.submit(); - }else{ - // otherwise we post a GET string by changing URL location for the - // iframe - - var extra = ''; - if(response.options.data){ - extra = response.options.data; - if(typeof extra !== 'string'){ - extra = ioQuery.objectToQuery(extra); - } - } - var tmpUrl = response.url + (response.url.indexOf('?') > -1 ? '&' : '?') + extra; - notify && notify.emit('send', response, dfd.promise.cancel); - iframe._notifyStart(response); - iframe.setSrc(iframe._frame, tmpUrl, true); - } - }catch(e){ - dfd.reject(e); - } - } - - // dojo/request/watch handlers - function isValid(response){ - return !this.isFulfilled(); - } - function isReady(response){ - return !!this._finished; - } - function handleResponse(response, error){ - if(!error){ - try{ - var options = response.options, - doc = iframe.doc(iframe._frame), - handleAs = options.handleAs; - - if(handleAs !== 'html'){ - if(handleAs === 'xml'){ - // IE6-8 have to parse the XML manually. See http://bugs.dojotoolkit.org/ticket/6334 - if(doc.documentElement.tagName.toLowerCase() === 'html'){ - query('a', doc.documentElement).orphan(); - var xmlText = doc.documentElement.innerText; - xmlText = xmlText.replace(/>\s+</g, '><'); - response.text = lang.trim(xmlText); - }else{ - response.data = doc; - } - }else{ - // 'json' and 'javascript' and 'text' - response.text = doc.getElementsByTagName('textarea')[0].value; // text - } - handlers(response); - }else{ - response.data = doc; - } - }catch(e){ - error = e; - } - } - - if(error){ - this.reject(error); - }else if(this._finished){ - this.resolve(response); - }else{ - this.reject(new Error('Invalid dojo/request/iframe request state')); - } - } - function last(response){ - this._callNext(); - } - - var defaultOptions = { - method: 'POST' - }; - function iframe(url, options, returnDeferred){ - var response = util.parseArgs(url, util.deepCreate(defaultOptions, options), true); - url = response.url; - options = response.options; - - if(options.method !== 'GET' && options.method !== 'POST'){ - throw new Error(options.method + ' not supported by dojo/request/iframe'); - } - - if(!iframe._frame){ - iframe._frame = iframe.create(iframe._iframeName, onload + '();'); - } - - var dfd = util.deferred(response, null, isValid, isReady, handleResponse, last); - dfd._callNext = function(){ - if(!this._calledNext){ - this._calledNext = true; - iframe._currentDfd = null; - iframe._fireNextRequest(); - } - }; - dfd._legacy = returnDeferred; - - iframe._dfdQueue.push(dfd); - iframe._fireNextRequest(); - - watch(dfd); - - return returnDeferred ? dfd : dfd.promise; - } - - /*===== - iframe = function(url, options){ - // summary: - // Sends a request using an iframe element with the given URL and options. - // url: String - // URL to request - // options: dojo/request/iframe.__Options? - // Options for the request. - // returns: dojo/request.__Promise - }; - iframe.__BaseOptions = declare(request.__BaseOptions, { - // form: DOMNode? - // A form node to use to submit data to the server. - // data: String|Object? - // Data to transfer. When making a GET request, this will - // be converted to key=value parameters and appended to the - // URL. - }); - iframe.__MethodOptions = declare(null, { - // method: String? - // The HTTP method to use to make the request. Must be - // uppercase. Only `"GET"` and `"POST"` are accepted. - // Default is `"POST"`. - }); - iframe.__Options = declare([iframe.__BaseOptions, iframe.__MethodOptions]); - - iframe.get = function(url, options){ - // summary: - // Send an HTTP GET request using an iframe element with the given URL and options. - // url: String - // URL to request - // options: dojo/request/iframe.__BaseOptions? - // Options for the request. - // returns: dojo/request.__Promise - }; - iframe.post = function(url, options){ - // summary: - // Send an HTTP POST request using an iframe element with the given URL and options. - // url: String - // URL to request - // options: dojo/request/iframe.__BaseOptions? - // Options for the request. - // returns: dojo/request.__Promise - }; - =====*/ - iframe.create = create; - iframe.doc = doc; - iframe.setSrc = setSrc; - - // TODO: Make these truly private in 2.0 - iframe._iframeName = mid + '_IoIframe'; - iframe._notifyStart = function(){}; - iframe._dfdQueue = []; - iframe._currentDfd = null; - iframe._fireNextRequest = fireNextRequest; - - util.addCommonMethods(iframe, ['GET', 'POST']); - - return iframe; -}); diff --git a/lib/dojo/request/node.js b/lib/dojo/request/node.js deleted file mode 100644 index 94f787f..0000000 --- a/lib/dojo/request/node.js +++ /dev/null @@ -1,86 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/request/node",["require","./util","./handlers","../errors/RequestTimeoutError","../node!http","../node!https","../node!url","../node!stream"],function(_1,_2,_3,_4,_5,_6,_7,_8){ -var _9=_8.Stream,_a; -var _b={method:"GET",query:null,data:_a,headers:{}}; -function _c(_d,_e){ -var _f=_2.parseArgs(_d,_2.deepCreate(_b,_e),_e&&_e.data instanceof _9); -_d=_f.url; -_e=_f.options; -var def=_2.deferred(_f,function(dfd,_10){ -_10.clientRequest.abort(); -}); -_d=_7.parse(_d); -var _11=_f.requestOptions={hostname:_d.hostname,port:_d.port,socketPath:_e.socketPath,method:_e.method,headers:_e.headers,agent:_e.agent,pfx:_e.pfx,key:_e.key,passphrase:_e.passphrase,cert:_e.cert,ca:_e.ca,ciphers:_e.ciphers,rejectUnauthorized:_e.rejectUnauthorized===false?false:true}; -if(_d.path){ -_11.path=_d.path; -} -if(_e.user||_e.password){ -_11.auth=(_e.user||"")+":"+(_e.password||""); -} -var req=_f.clientRequest=(_d.protocol==="https:"?_6:_5).request(_11); -if(_e.socketOptions){ -if("timeout" in _e.socketOptions){ -req.setTimeout(_e.socketOptions.timeout); -} -if("noDelay" in _e.socketOptions){ -req.setNoDelay(_e.socketOptions.noDelay); -} -if("keepAlive" in _e.socketOptions){ -var _12=_e.socketOptions.keepAlive; -req.setKeepAlive(_12>=0,_12||0); -} -} -req.on("socket",function(){ -_f.hasSocket=true; -def.progress(_f); -}); -req.on("response",function(_13){ -_f.clientResponse=_13; -_f.status=_13.statusCode; -_f.getHeader=function(_14){ -return _13.headers[_14.toLowerCase()]||null; -}; -var _15=[]; -_13.on("data",function(_16){ -_15.push(_16); -}); -_13.on("end",function(){ -if(_17){ -clearTimeout(_17); -} -_f.text=_15.join(""); -try{ -_3(_f); -def.resolve(_f); -} -catch(error){ -def.reject(error); -} -}); -}); -req.on("error",def.reject); -if(_e.data){ -if(typeof _e.data==="string"){ -req.end(_e.data); -}else{ -_e.data.pipe(req); -} -}else{ -req.end(); -} -if(_e.timeout){ -var _17=setTimeout(function(){ -def.cancel(new _4(_f)); -},_e.timeout); -} -return def.promise; -}; -_2.addCommonMethods(_c); -return _c; -}); diff --git a/lib/dojo/request/node.js.uncompressed.js b/lib/dojo/request/node.js.uncompressed.js deleted file mode 100644 index ce56398..0000000 --- a/lib/dojo/request/node.js.uncompressed.js +++ /dev/null @@ -1,195 +0,0 @@ -define("dojo/request/node", [ - 'require', - './util', - './handlers', - '../errors/RequestTimeoutError', - '../node!http', - '../node!https', - '../node!url', - '../node!stream'/*=====, - '../request', - '../_base/declare' =====*/ -], function(require, util, handlers, RequestTimeoutError, http, https, URL, stream/*=====, request, declare =====*/){ - var Stream = stream.Stream, - undefined; - - var defaultOptions = { - method: 'GET', - query: null, - data: undefined, - headers: {} - }; - function node(url, options){ - var response = util.parseArgs(url, util.deepCreate(defaultOptions, options), options && options.data instanceof Stream); - url = response.url; - options = response.options; - - var def = util.deferred( - response, - function(dfd, response){ - response.clientRequest.abort(); - } - ); - - url = URL.parse(url); - - var reqOptions = response.requestOptions = { - hostname: url.hostname, - port: url.port, - socketPath: options.socketPath, - method: options.method, - headers: options.headers, - agent: options.agent, - pfx: options.pfx, - key: options.key, - passphrase: options.passphrase, - cert: options.cert, - ca: options.ca, - ciphers: options.ciphers, - rejectUnauthorized: options.rejectUnauthorized === false ? false : true - }; - if(url.path){ - reqOptions.path = url.path; - } - if(options.user || options.password){ - reqOptions.auth = (options.user||'') + ':' + (options.password||''); - } - var req = response.clientRequest = (url.protocol === 'https:' ? https : http).request(reqOptions); - - if(options.socketOptions){ - if('timeout' in options.socketOptions){ - req.setTimeout(options.socketOptions.timeout); - } - if('noDelay' in options.socketOptions){ - req.setNoDelay(options.socketOptions.noDelay); - } - if('keepAlive' in options.socketOptions){ - var initialDelay = options.socketOptions.keepAlive; - req.setKeepAlive(initialDelay >= 0, initialDelay || 0); - } - } - - req.on('socket', function(){ - response.hasSocket = true; - def.progress(response); - }); - - req.on('response', function(clientResponse){ - response.clientResponse = clientResponse; - response.status = clientResponse.statusCode; - response.getHeader = function(headerName){ - return clientResponse.headers[headerName.toLowerCase()] || null; - }; - - var body = []; - clientResponse.on('data', function(chunk){ - body.push(chunk); - - // TODO: progress updates via the deferred - }); - clientResponse.on('end', function(){ - if(timeout){ - clearTimeout(timeout); - } - response.text = body.join(''); - try{ - handlers(response); - def.resolve(response); - }catch(error){ - def.reject(error); - } - }); - }); - - req.on('error', def.reject); - - if(options.data){ - if(typeof options.data === 'string'){ - req.end(options.data); - }else{ - options.data.pipe(req); - } - }else{ - req.end(); - } - - if(options.timeout){ - var timeout = setTimeout(function(){ - def.cancel(new RequestTimeoutError(response)); - }, options.timeout); - } - - return def.promise; - } - - /*===== - node = function(url, options){ - // summary: - // Sends a request using the included http or https interface from node.js - // with the given URL and options. - // url: String - // URL to request - // options: dojo/request/node.__Options? - // Options for the request. - // returns: dojo/request.__Promise - }; - node.__BaseOptions = declare(request.__BaseOptions, { - // data: String|Object|Stream? - // Data to transfer. This is ignored for GET and DELETE - // requests. - // headers: Object? - // Headers to use for the request. - // user: String? - // Username to use during the request. - // password: String? - // Password to use during the request. - }); - node.__MethodOptions = declare(null, { - // method: String? - // The HTTP method to use to make the request. Must be - // uppercase. Default is `"GET"`. - }); - node.__Options = declare([node.__BaseOptions, node.__MethodOptions]); - - node.get = function(url, options){ - // summary: - // Send an HTTP GET request using XMLHttpRequest with the given URL and options. - // url: String - // URL to request - // options: dojo/request/node.__BaseOptions? - // Options for the request. - // returns: dojo/request.__Promise - }; - node.post = function(url, options){ - // summary: - // Send an HTTP POST request using XMLHttpRequest with the given URL and options. - // url: String - // URL to request - // options: dojo/request/node.__BaseOptions? - // Options for the request. - // returns: dojo/request.__Promise - }; - node.put = function(url, options){ - // summary: - // Send an HTTP PUT request using XMLHttpRequest with the given URL and options. - // url: String - // URL to request - // options: dojo/request/node.__BaseOptions? - // Options for the request. - // returns: dojo/request.__Promise - }; - node.del = function(url, options){ - // summary: - // Send an HTTP DELETE request using XMLHttpRequest with the given URL and options. - // url: String - // URL to request - // options: dojo/request/node.__BaseOptions? - // Options for the request. - // returns: dojo/request.__Promise - }; - =====*/ - - util.addCommonMethods(node); - - return node; -}); diff --git a/lib/dojo/request/notify.js b/lib/dojo/request/notify.js deleted file mode 100644 index 9c7d1fd..0000000 --- a/lib/dojo/request/notify.js +++ /dev/null @@ -1,38 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/request/notify",["../Evented","../_base/lang","./util"],function(_1,_2,_3){ -var _4=0,_5=[].slice; -var _6=_2.mixin(new _1,{onsend:function(_7){ -if(!_4){ -this.emit("start"); -} -_4++; -},_onload:function(_8){ -this.emit("done",_8); -},_onerror:function(_9){ -this.emit("done",_9); -},_ondone:function(_a){ -if(--_4<=0){ -_4=0; -this.emit("stop"); -} -},emit:function(_b,_c){ -var _d=_1.prototype.emit.apply(this,arguments); -if(this["_on"+_b]){ -this["_on"+_b].apply(this,_5.call(arguments,1)); -} -return _d; -}}); -function _e(_f,_10){ -return _6.on(_f,_10); -}; -_e.emit=function(_11,_12,_13){ -return _6.emit(_11,_12,_13); -}; -return _3.notify=_e; -}); diff --git a/lib/dojo/request/notify.js.uncompressed.js b/lib/dojo/request/notify.js.uncompressed.js deleted file mode 100644 index 2b8a2b6..0000000 --- a/lib/dojo/request/notify.js.uncompressed.js +++ /dev/null @@ -1,74 +0,0 @@ -define("dojo/request/notify", ['../Evented', '../_base/lang', './util'], function(Evented, lang, util){ - // module: - // dojo/request/notify - // summary: - // Global notification API for dojo/request. Notifications will - // only be emitted if this module is required. - // - // | require('dojo/request', 'dojo/request/notify', - // | function(request, notify){ - // | notify('load', function(response){ - // | if(response.url === 'someUrl.html'){ - // | console.log('Loaded!'); - // | } - // | }); - // | request.get('someUrl.html'); - // | } - // | ); - - var pubCount = 0, - slice = [].slice; - - var hub = lang.mixin(new Evented, { - onsend: function(data){ - if(!pubCount){ - this.emit('start'); - } - pubCount++; - }, - _onload: function(data){ - this.emit('done', data); - }, - _onerror: function(data){ - this.emit('done', data); - }, - _ondone: function(data){ - if(--pubCount <= 0){ - pubCount = 0; - this.emit('stop'); - } - }, - emit: function(type, event){ - var result = Evented.prototype.emit.apply(this, arguments); - - // After all event handlers have run, run _on* handler - if(this['_on' + type]){ - this['_on' + type].apply(this, slice.call(arguments, 1)); - } - return result; - } - }); - - function notify(type, listener){ - // summary: - // Register a listener to be notified when an event - // in dojo/request happens. - // type: String? - // The event to listen for. Events emitted: "start", "send", - // "load", "error", "done", "stop". - // listener: Function? - // A callback to be run when an event happens. - // returns: - // A signal object that can be used to cancel the listener. - // If remove() is called on this signal object, it will - // stop the listener from being executed. - return hub.on(type, listener); - } - notify.emit = function(type, event, cancel){ - return hub.emit(type, event, cancel); - }; - - // Attach notify to dojo/request/util to avoid - // try{ require('./notify'); }catch(e){} - return util.notify = notify; -}); diff --git a/lib/dojo/request/registry.js b/lib/dojo/request/registry.js deleted file mode 100644 index 1094d35..0000000 --- a/lib/dojo/request/registry.js +++ /dev/null @@ -1,68 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/request/registry",["require","../_base/array","./default!platform","./util"],function(_1,_2,_3,_4){ -var _5=[]; -function _6(_7,_8){ -var _9=_5.slice(0),i=0,_a; -while(_a=_9[i++]){ -if(_a(_7,_8)){ -return _a.request.call(null,_7,_8); -} -} -return _3.apply(null,arguments); -}; -function _b(_c,_d){ -var _e; -if(_d){ -if(_c.test){ -_e=function(_f){ -return _c.test(_f); -}; -}else{ -if(_c.apply&&_c.call){ -_e=function(){ -return _c.apply(null,arguments); -}; -}else{ -_e=function(url){ -return url===_c; -}; -} -} -_e.request=_d; -}else{ -_e=function(){ -return true; -}; -_e.request=_c; -} -return _e; -}; -_6.register=function(url,_10,_11){ -var _12=_b(url,_10); -_5[(_11?"unshift":"push")](_12); -return {remove:function(){ -var idx; -if(~(idx=_2.indexOf(_5,_12))){ -_5.splice(idx,1); -} -}}; -}; -_6.load=function(id,_13,_14,_15){ -if(id){ -_1([id],function(_16){ -_3=_16; -_14(_6); -}); -}else{ -_14(_6); -} -}; -_4.addCommonMethods(_6); -return _6; -}); diff --git a/lib/dojo/request/registry.js.uncompressed.js b/lib/dojo/request/registry.js.uncompressed.js deleted file mode 100644 index b5d28f3..0000000 --- a/lib/dojo/request/registry.js.uncompressed.js +++ /dev/null @@ -1,85 +0,0 @@ -define("dojo/request/registry", [ - 'require', - '../_base/array', - './default!platform', - './util' -], function(require, array, fallbackProvider, util){ - var providers = []; - - function request(url, options){ - var matchers = providers.slice(0), - i = 0, - matcher; - - while(matcher=matchers[i++]){ - if(matcher(url, options)){ - return matcher.request.call(null, url, options); - } - } - - return fallbackProvider.apply(null, arguments); - } - - function createMatcher(match, provider){ - var matcher; - - if(provider){ - if(match.test){ - // RegExp - matcher = function(url){ - return match.test(url); - }; - }else if(match.apply && match.call){ - matcher = function(){ - return match.apply(null, arguments); - }; - }else{ - matcher = function(url){ - return url === match; - }; - } - - matcher.request = provider; - }else{ - // If only one argument was passed, assume it is a provider function - // to apply unconditionally to all URLs - matcher = function(){ - return true; - }; - - matcher.request = match; - } - - return matcher; - } - - request.register = function(url, provider, first){ - var matcher = createMatcher(url, provider); - providers[(first ? 'unshift' : 'push')](matcher); - - return { - remove: function(){ - var idx; - if(~(idx = array.indexOf(providers, matcher))){ - providers.splice(idx, 1); - } - } - }; - }; - - request.load = function(id, parentRequire, loaded, config){ - if(id){ - // if there's an id, load and set the fallback provider - require([id], function(fallback){ - fallbackProvider = fallback; - loaded(request); - }); - }else{ - loaded(request); - } - }; - - util.addCommonMethods(request); - - return request; -}); diff --git a/lib/dojo/request/script.js b/lib/dojo/request/script.js deleted file mode 100644 index 7627610..0000000 --- a/lib/dojo/request/script.js +++ /dev/null @@ -1,114 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/request/script",["module","./watch","./util","../_base/array","../_base/lang","../on","../dom","../dom-construct","../has","../_base/window"],function(_1,_2,_3,_4,_5,on,_6,_7,_8,_9){ -_8.add("script-readystatechange",function(_a,_b){ -var _c=_b.createElement("script"); -return typeof _c["onreadystatechange"]!=="undefined"&&(typeof _a["opera"]==="undefined"||_a["opera"].toString()!=="[object Opera]"); -}); -var _d=_1.id.replace(/[\/\.\-]/g,"_"),_e=0,_f=_8("script-readystatechange")?"readystatechange":"load",_10=/complete|loaded/,_11=this[_d+"_callbacks"]={},_12=[]; -function _13(id,url,_14){ -var doc=(_14||_9.doc),_15=doc.createElement("script"); -_15.type="text/javascript"; -_15.src=url; -_15.id=id; -_15.async=true; -_15.charset="utf-8"; -return doc.getElementsByTagName("head")[0].appendChild(_15); -}; -function _16(id,_17,_18){ -_7.destroy(_6.byId(id,_17)); -if(_11[id]){ -if(_18){ -_11[id]=function(){ -delete _11[id]; -}; -}else{ -delete _11[id]; -} -} -}; -function _19(dfd){ -var _1a=dfd.response.options,_1b=_1a.ioArgs?_1a.ioArgs.frameDoc:_1a.frameDoc; -_12.push({id:dfd.id,frameDoc:_1b}); -if(_1a.ioArgs){ -_1a.ioArgs.frameDoc=null; -} -_1a.frameDoc=null; -}; -function _1c(dfd,_1d){ -if(dfd.canDelete){ -_1e._remove(dfd.id,_1d.options.frameDoc,true); -} -}; -function _1f(_20){ -if(_12&&_12.length){ -_4.forEach(_12,function(_21){ -_1e._remove(_21.id,_21.frameDoc); -_21.frameDoc=null; -}); -_12=[]; -} -return _20.options.jsonp?!_20.data:true; -}; -function _22(_23){ -return !!this.scriptLoaded; -}; -function _24(_25){ -var _26=_25.options.checkString; -return _26&&eval("typeof("+_26+") !== \"undefined\""); -}; -function _27(_28,_29){ -if(this.canDelete){ -_19(this); -} -if(_29){ -this.reject(_29); -}else{ -this.resolve(_28); -} -}; -function _1e(url,_2a,_2b){ -var _2c=_3.parseArgs(url,_3.deepCopy({},_2a)); -url=_2c.url; -_2a=_2c.options; -var dfd=_3.deferred(_2c,_1c,_1f,_2a.jsonp?null:(_2a.checkString?_24:_22),_27); -_5.mixin(dfd,{id:_d+(_e++),canDelete:false}); -if(_2a.jsonp){ -var _2d=new RegExp("[?&]"+_2a.jsonp+"="); -if(!_2d.test(url)){ -url+=(~url.indexOf("?")?"&":"?")+_2a.jsonp+"="+(_2a.frameDoc?"parent.":"")+_d+"_callbacks."+dfd.id; -} -dfd.canDelete=true; -_11[dfd.id]=function(_2e){ -_2c.data=_2e; -dfd.handleResponse(_2c); -}; -} -if(_3.notify){ -_3.notify.emit("send",_2c,dfd.promise.cancel); -} -if(!_2a.canAttach||_2a.canAttach(dfd)){ -var _2f=_1e._attach(dfd.id,url,_2a.frameDoc); -if(!_2a.jsonp&&!_2a.checkString){ -var _30=on(_2f,_f,function(evt){ -if(evt.type==="load"||_10.test(_2f.readyState)){ -_30.remove(); -dfd.scriptLoaded=evt; -} -}); -} -} -_2(dfd); -return _2b?dfd:dfd.promise; -}; -_1e.get=_1e; -_1e._attach=_13; -_1e._remove=_16; -_1e._callbacksProperty=_d+"_callbacks"; -return _1e; -}); diff --git a/lib/dojo/request/script.js.uncompressed.js b/lib/dojo/request/script.js.uncompressed.js deleted file mode 100644 index 3ca6b09..0000000 --- a/lib/dojo/request/script.js.uncompressed.js +++ /dev/null @@ -1,219 +0,0 @@ -define("dojo/request/script", [ - 'module', - './watch', - './util', - '../_base/array', - '../_base/lang', - '../on', - '../dom', - '../dom-construct', - '../has', - '../_base/window'/*=====, - '../request', - '../_base/declare' =====*/ -], function(module, watch, util, array, lang, on, dom, domConstruct, has, win/*=====, request, declare =====*/){ - has.add('script-readystatechange', function(global, document){ - var script = document.createElement('script'); - return typeof script['onreadystatechange'] !== 'undefined' && - (typeof global['opera'] === 'undefined' || global['opera'].toString() !== '[object Opera]'); - }); - - var mid = module.id.replace(/[\/\.\-]/g, '_'), - counter = 0, - loadEvent = has('script-readystatechange') ? 'readystatechange' : 'load', - readyRegExp = /complete|loaded/, - callbacks = this[mid + '_callbacks'] = {}, - deadScripts = []; - - function attach(id, url, frameDoc){ - var doc = (frameDoc || win.doc), - element = doc.createElement('script'); - - element.type = 'text/javascript'; - element.src = url; - element.id = id; - element.async = true; - element.charset = 'utf-8'; - - return doc.getElementsByTagName('head')[0].appendChild(element); - } - - function remove(id, frameDoc, cleanup){ - domConstruct.destroy(dom.byId(id, frameDoc)); - - if(callbacks[id]){ - if(cleanup){ - // set callback to a function that deletes itself so requests that - // are in-flight don't error out when returning and also - // clean up after themselves - callbacks[id] = function(){ - delete callbacks[id]; - }; - }else{ - delete callbacks[id]; - } - } - } - - function _addDeadScript(dfd){ - // Be sure to check ioArgs because it can dynamically change in the dojox/io plugins. - // See http://bugs.dojotoolkit.org/ticket/15890. - var options = dfd.response.options, - frameDoc = options.ioArgs ? options.ioArgs.frameDoc : options.frameDoc; - - deadScripts.push({ id: dfd.id, frameDoc: frameDoc }); - - if(options.ioArgs){ - options.ioArgs.frameDoc = null; - } - options.frameDoc = null; - } - - function canceler(dfd, response){ - if(dfd.canDelete){ - //For timeouts and cancels, remove the script element immediately to - //avoid a response from it coming back later and causing trouble. - script._remove(dfd.id, response.options.frameDoc, true); - } - } - function isValid(response){ - //Do script cleanup here. We wait for one inflight pass - //to make sure we don't get any weird things by trying to remove a script - //tag that is part of the call chain (IE 6 has been known to - //crash in that case). - if(deadScripts && deadScripts.length){ - array.forEach(deadScripts, function(_script){ - script._remove(_script.id, _script.frameDoc); - _script.frameDoc = null; - }); - deadScripts = []; - } - - return response.options.jsonp ? !response.data : true; - } - function isReadyScript(response){ - return !!this.scriptLoaded; - } - function isReadyCheckString(response){ - var checkString = response.options.checkString; - - return checkString && eval('typeof(' + checkString + ') !== "undefined"'); - } - function handleResponse(response, error){ - if(this.canDelete){ - _addDeadScript(this); - } - if(error){ - this.reject(error); - }else{ - this.resolve(response); - } - } - - function script(url, options, returnDeferred){ - var response = util.parseArgs(url, util.deepCopy({}, options)); - url = response.url; - options = response.options; - - var dfd = util.deferred( - response, - canceler, - isValid, - options.jsonp ? null : (options.checkString ? isReadyCheckString : isReadyScript), - handleResponse - ); - - lang.mixin(dfd, { - id: mid + (counter++), - canDelete: false - }); - - if(options.jsonp){ - var queryParameter = new RegExp('[?&]' + options.jsonp + '='); - if(!queryParameter.test(url)){ - url += (~url.indexOf('?') ? '&' : '?') + - options.jsonp + '=' + - (options.frameDoc ? 'parent.' : '') + - mid + '_callbacks.' + dfd.id; - } - - dfd.canDelete = true; - callbacks[dfd.id] = function(json){ - response.data = json; - dfd.handleResponse(response); - }; - } - - if(util.notify){ - util.notify.emit('send', response, dfd.promise.cancel); - } - - if(!options.canAttach || options.canAttach(dfd)){ - var node = script._attach(dfd.id, url, options.frameDoc); - - if(!options.jsonp && !options.checkString){ - var handle = on(node, loadEvent, function(evt){ - if(evt.type === 'load' || readyRegExp.test(node.readyState)){ - handle.remove(); - dfd.scriptLoaded = evt; - } - }); - } - } - - watch(dfd); - - return returnDeferred ? dfd : dfd.promise; - } - script.get = script; - /*===== - script = function(url, options){ - // summary: - // Sends a request using a script element with the given URL and options. - // url: String - // URL to request - // options: dojo/request/script.__Options? - // Options for the request. - // returns: dojo/request.__Promise - }; - script.__BaseOptions = declare(request.__BaseOptions, { - // jsonp: String? - // The URL parameter name that indicates the JSONP callback string. - // For instance, when using Yahoo JSONP calls it is normally, - // jsonp: "callback". For AOL JSONP calls it is normally - // jsonp: "c". - // checkString: String? - // A string of JavaScript that when evaluated like so: - // "typeof(" + checkString + ") != 'undefined'" - // being true means that the script fetched has been loaded. - // Do not use this if doing a JSONP type of call (use `jsonp` instead). - // frameDoc: Document? - // The Document object of a child iframe. If this is passed in, the script - // will be attached to that document. This can be helpful in some comet long-polling - // scenarios with Firefox and Opera. - }); - script.__MethodOptions = declare(null, { - // method: String? - // This option is ignored. All requests using this transport are - // GET requests. - }); - script.__Options = declare([script.__BaseOptions, script.__MethodOptions]); - - script.get = function(url, options){ - // summary: - // Send an HTTP GET request using a script element with the given URL and options. - // url: String - // URL to request - // options: dojo/request/script.__BaseOptions? - // Options for the request. - // returns: dojo/request.__Promise - }; - =====*/ - - // TODO: Remove in 2.0 - script._attach = attach; - script._remove = remove; - script._callbacksProperty = mid + '_callbacks'; - - return script; -}); diff --git a/lib/dojo/request/util.js b/lib/dojo/request/util.js deleted file mode 100644 index a17627e..0000000 --- a/lib/dojo/request/util.js +++ /dev/null @@ -1,121 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/request/util",["exports","../errors/RequestError","../errors/CancelError","../Deferred","../io-query","../_base/array","../_base/lang","../promise/Promise"],function(_1,_2,_3,_4,_5,_6,_7,_8){ -_1.deepCopy=function deepCopy(_9,_a){ -for(var _b in _a){ -var _c=_9[_b],_d=_a[_b]; -if(_c!==_d){ -if(_c&&typeof _c==="object"&&_d&&typeof _d==="object"){ -_1.deepCopy(_c,_d); -}else{ -_9[_b]=_d; -} -} -} -return _9; -}; -_1.deepCreate=function deepCreate(_e,_f){ -_f=_f||{}; -var _10=_7.delegate(_e),_11,_12; -for(_11 in _e){ -_12=_e[_11]; -if(_12&&typeof _12==="object"){ -_10[_11]=_1.deepCreate(_12,_f[_11]); -} -} -return _1.deepCopy(_10,_f); -}; -var _13=Object.freeze||function(obj){ -return obj; -}; -function _14(_15){ -return _13(_15); -}; -function _16(_17){ -return _17.data||_17.text; -}; -_1.deferred=function deferred(_18,_19,_1a,_1b,_1c,_1d){ -var def=new _4(function(_1e){ -_19&&_19(def,_18); -if(!_1e||!(_1e instanceof _2)&&!(_1e instanceof _3)){ -return new _3("Request canceled",_18); -} -return _1e; -}); -def.response=_18; -def.isValid=_1a; -def.isReady=_1b; -def.handleResponse=_1c; -function _1f(_20){ -_20.response=_18; -throw _20; -}; -var _21=def.then(_14).otherwise(_1f); -if(_1.notify){ -_21.then(_7.hitch(_1.notify,"emit","load"),_7.hitch(_1.notify,"emit","error")); -} -var _22=_21.then(_16); -var _23=new _8(); -for(var _24 in _22){ -if(_22.hasOwnProperty(_24)){ -_23[_24]=_22[_24]; -} -} -_23.response=_21; -_13(_23); -if(_1d){ -def.then(function(_25){ -_1d.call(def,_25); -},function(_26){ -_1d.call(def,_18,_26); -}); -} -def.promise=_23; -def.then=_23.then; -return def; -}; -_1.addCommonMethods=function addCommonMethods(_27,_28){ -_6.forEach(_28||["GET","POST","PUT","DELETE"],function(_29){ -_27[(_29==="DELETE"?"DEL":_29).toLowerCase()]=function(url,_2a){ -_2a=_7.delegate(_2a||{}); -_2a.method=_29; -return _27(url,_2a); -}; -}); -}; -_1.parseArgs=function parseArgs(url,_2b,_2c){ -var _2d=_2b.data,_2e=_2b.query; -if(_2d&&!_2c){ -if(typeof _2d==="object"){ -_2b.data=_5.objectToQuery(_2d); -} -} -if(_2e){ -if(typeof _2e==="object"){ -_2e=_5.objectToQuery(_2e); -} -if(_2b.preventCache){ -_2e+=(_2e?"&":"")+"request.preventCache="+(+(new Date)); -} -}else{ -if(_2b.preventCache){ -_2e="request.preventCache="+(+(new Date)); -} -} -if(url&&_2e){ -url+=(~url.indexOf("?")?"&":"?")+_2e; -} -return {url:url,options:_2b,getHeader:function(_2f){ -return null; -}}; -}; -_1.checkStatus=function(_30){ -_30=_30||0; -return (_30>=200&&_30<300)||_30===304||_30===1223||!_30; -}; -}); diff --git a/lib/dojo/request/util.js.uncompressed.js b/lib/dojo/request/util.js.uncompressed.js deleted file mode 100644 index f99b629..0000000 --- a/lib/dojo/request/util.js.uncompressed.js +++ /dev/null @@ -1,158 +0,0 @@ -define("dojo/request/util", [ - 'exports', - '../errors/RequestError', - '../errors/CancelError', - '../Deferred', - '../io-query', - '../_base/array', - '../_base/lang', - '../promise/Promise' -], function(exports, RequestError, CancelError, Deferred, ioQuery, array, lang, Promise){ - exports.deepCopy = function deepCopy(target, source){ - for(var name in source){ - var tval = target[name], - sval = source[name]; - if(tval !== sval){ - if(tval && typeof tval === 'object' && sval && typeof sval === 'object'){ - exports.deepCopy(tval, sval); - }else{ - target[name] = sval; - } - } - } - return target; - }; - - exports.deepCreate = function deepCreate(source, properties){ - properties = properties || {}; - var target = lang.delegate(source), - name, value; - - for(name in source){ - value = source[name]; - - if(value && typeof value === 'object'){ - target[name] = exports.deepCreate(value, properties[name]); - } - } - return exports.deepCopy(target, properties); - }; - - var freeze = Object.freeze || function(obj){ return obj; }; - function okHandler(response){ - return freeze(response); - } - function dataHandler (response) { - return response.data || response.text; - } - - exports.deferred = function deferred(response, cancel, isValid, isReady, handleResponse, last){ - var def = new Deferred(function(reason){ - cancel && cancel(def, response); - - if(!reason || !(reason instanceof RequestError) && !(reason instanceof CancelError)){ - return new CancelError('Request canceled', response); - } - return reason; - }); - - def.response = response; - def.isValid = isValid; - def.isReady = isReady; - def.handleResponse = handleResponse; - - function errHandler(error){ - error.response = response; - throw error; - } - var responsePromise = def.then(okHandler).otherwise(errHandler); - - if(exports.notify){ - responsePromise.then( - lang.hitch(exports.notify, 'emit', 'load'), - lang.hitch(exports.notify, 'emit', 'error') - ); - } - - var dataPromise = responsePromise.then(dataHandler); - - // http://bugs.dojotoolkit.org/ticket/16794 - // The following works around a leak in IE9 through the - // prototype using lang.delegate on dataPromise and - // assigning the result a property with a reference to - // responsePromise. - var promise = new Promise(); - for (var prop in dataPromise) { - if (dataPromise.hasOwnProperty(prop)) { - promise[prop] = dataPromise[prop]; - } - } - promise.response = responsePromise; - freeze(promise); - // End leak fix - - - if(last){ - def.then(function(response){ - last.call(def, response); - }, function(error){ - last.call(def, response, error); - }); - } - - def.promise = promise; - def.then = promise.then; - - return def; - }; - - exports.addCommonMethods = function addCommonMethods(provider, methods){ - array.forEach(methods||['GET', 'POST', 'PUT', 'DELETE'], function(method){ - provider[(method === 'DELETE' ? 'DEL' : method).toLowerCase()] = function(url, options){ - options = lang.delegate(options||{}); - options.method = method; - return provider(url, options); - }; - }); - }; - - exports.parseArgs = function parseArgs(url, options, skipData){ - var data = options.data, - query = options.query; - - if(data && !skipData){ - if(typeof data === 'object'){ - options.data = ioQuery.objectToQuery(data); - } - } - - if(query){ - if(typeof query === 'object'){ - query = ioQuery.objectToQuery(query); - } - if(options.preventCache){ - query += (query ? '&' : '') + 'request.preventCache=' + (+(new Date)); - } - }else if(options.preventCache){ - query = 'request.preventCache=' + (+(new Date)); - } - - if(url && query){ - url += (~url.indexOf('?') ? '&' : '?') + query; - } - - return { - url: url, - options: options, - getHeader: function(headerName){ return null; } - }; - }; - - exports.checkStatus = function(stat){ - stat = stat || 0; - return (stat >= 200 && stat < 300) || // allow any 2XX response code - stat === 304 || // or, get it out of the cache - stat === 1223 || // or, Internet Explorer mangled the status code - !stat; // or, we're Titanium/browser chrome/chrome extension requesting a local file - }; -}); diff --git a/lib/dojo/request/watch.js b/lib/dojo/request/watch.js deleted file mode 100644 index 195ce09..0000000 --- a/lib/dojo/request/watch.js +++ /dev/null @@ -1,73 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/request/watch",["./util","../errors/RequestTimeoutError","../errors/CancelError","../_base/array","../_base/window","../has!host-browser?dom-addeventlistener?:../on:"],function(_1,_2,_3,_4,_5,on){ -var _6=null,_7=[]; -function _8(){ -var _9=+(new Date); -for(var i=0,_a;i<_7.length&&(_a=_7[i]);i++){ -var _b=_a.response,_c=_b.options; -if((_a.isCanceled&&_a.isCanceled())||(_a.isValid&&!_a.isValid(_b))){ -_7.splice(i--,1); -_d._onAction&&_d._onAction(); -}else{ -if(_a.isReady&&_a.isReady(_b)){ -_7.splice(i--,1); -_a.handleResponse(_b); -_d._onAction&&_d._onAction(); -}else{ -if(_a.startTime){ -if(_a.startTime+(_c.timeout||0)<_9){ -_7.splice(i--,1); -_a.cancel(new _2("Timeout exceeded",_b)); -_d._onAction&&_d._onAction(); -} -} -} -} -} -_d._onInFlight&&_d._onInFlight(_a); -if(!_7.length){ -clearInterval(_6); -_6=null; -} -}; -function _d(_e){ -if(_e.response.options.timeout){ -_e.startTime=+(new Date); -} -if(_e.isFulfilled()){ -return; -} -_7.push(_e); -if(!_6){ -_6=setInterval(_8,50); -} -if(_e.response.options.sync){ -_8(); -} -}; -_d.cancelAll=function cancelAll(){ -try{ -_4.forEach(_7,function(_f){ -try{ -_f.cancel(new _3("All requests canceled.")); -} -catch(e){ -} -}); -} -catch(e){ -} -}; -if(_5&&on&&_5.doc.attachEvent){ -on(_5.global,"unload",function(){ -_d.cancelAll(); -}); -} -return _d; -}); diff --git a/lib/dojo/request/watch.js.uncompressed.js b/lib/dojo/request/watch.js.uncompressed.js deleted file mode 100644 index 2b77228..0000000 --- a/lib/dojo/request/watch.js.uncompressed.js +++ /dev/null @@ -1,109 +0,0 @@ -define("dojo/request/watch", [ - './util', - '../errors/RequestTimeoutError', - '../errors/CancelError', - '../_base/array', - '../_base/window', - '../has!host-browser?dom-addeventlistener?:../on:' -], function(util, RequestTimeoutError, CancelError, array, win, on){ - // avoid setting a timer per request. It degrades performance on IE - // something fierece if we don't use unified loops. - var _inFlightIntvl = null, - _inFlight = []; - - function watchInFlight(){ - // summary: - // internal method that checks each inflight XMLHttpRequest to see - // if it has completed or if the timeout situation applies. - - var now = +(new Date); - - // we need manual loop because we often modify _inFlight (and therefore 'i') while iterating - for(var i = 0, dfd; i < _inFlight.length && (dfd = _inFlight[i]); i++){ - var response = dfd.response, - options = response.options; - if((dfd.isCanceled && dfd.isCanceled()) || (dfd.isValid && !dfd.isValid(response))){ - _inFlight.splice(i--, 1); - watch._onAction && watch._onAction(); - }else if(dfd.isReady && dfd.isReady(response)){ - _inFlight.splice(i--, 1); - dfd.handleResponse(response); - watch._onAction && watch._onAction(); - }else if(dfd.startTime){ - // did we timeout? - if(dfd.startTime + (options.timeout || 0) < now){ - _inFlight.splice(i--, 1); - // Cancel the request so the io module can do appropriate cleanup. - dfd.cancel(new RequestTimeoutError('Timeout exceeded', response)); - watch._onAction && watch._onAction(); - } - } - } - - watch._onInFlight && watch._onInFlight(dfd); - - if(!_inFlight.length){ - clearInterval(_inFlightIntvl); - _inFlightIntvl = null; - } - } - - function watch(dfd){ - // summary: - // Watches the io request represented by dfd to see if it completes. - // dfd: Deferred - // The Deferred object to watch. - // response: Object - // The object used as the value of the request promise. - // validCheck: Function - // Function used to check if the IO request is still valid. Gets the dfd - // object as its only argument. - // ioCheck: Function - // Function used to check if basic IO call worked. Gets the dfd - // object as its only argument. - // resHandle: Function - // Function used to process response. Gets the dfd - // object as its only argument. - if(dfd.response.options.timeout){ - dfd.startTime = +(new Date); - } - - if(dfd.isFulfilled()){ - // bail out if the deferred is already fulfilled - return; - } - - _inFlight.push(dfd); - if(!_inFlightIntvl){ - _inFlightIntvl = setInterval(watchInFlight, 50); - } - - // handle sync requests separately from async: - // http://bugs.dojotoolkit.org/ticket/8467 - if(dfd.response.options.sync){ - watchInFlight(); - } - } - - watch.cancelAll = function cancelAll(){ - // summary: - // Cancels all pending IO requests, regardless of IO type - try{ - array.forEach(_inFlight, function(dfd){ - try{ - dfd.cancel(new CancelError('All requests canceled.')); - }catch(e){} - }); - }catch(e){} - }; - - if(win && on && win.doc.attachEvent){ - // Automatically call cancel all io calls on unload in IE - // http://bugs.dojotoolkit.org/ticket/2357 - on(win.global, 'unload', function(){ - watch.cancelAll(); - }); - } - - return watch; -}); diff --git a/lib/dojo/request/xhr.js b/lib/dojo/request/xhr.js deleted file mode 100644 index 9d31b69..0000000 --- a/lib/dojo/request/xhr.js +++ /dev/null @@ -1,203 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/request/xhr",["../errors/RequestError","./watch","./handlers","./util","../has"],function(_1,_2,_3,_4,_5){ -_5.add("native-xhr",function(){ -return typeof XMLHttpRequest!=="undefined"; -}); -_5.add("dojo-force-activex-xhr",function(){ -return _5("activex")&&!document.addEventListener&&window.location.protocol==="file:"; -}); -_5.add("native-xhr2",function(){ -if(!_5("native-xhr")){ -return; -} -var x=new XMLHttpRequest(); -return typeof x["addEventListener"]!=="undefined"&&(typeof opera==="undefined"||typeof x["upload"]!=="undefined"); -}); -_5.add("native-formdata",function(){ -return typeof FormData!=="undefined"; -}); -_5.add("native-response-type",function(){ -return _5("native-xhr")&&typeof new XMLHttpRequest().responseType!=="undefined"; -}); -var _6={"blob":1,"document":1,"arraybuffer":1}; -function _7(_8,_9){ -var _a=_8.xhr; -_8.status=_8.xhr.status; -try{ -_8.text=_a.responseText; -} -catch(e){ -} -if(_8.options.handleAs==="xml"){ -_8.data=_a.responseXML; -} -if(!_9){ -try{ -_3(_8); -} -catch(e){ -_9=e; -} -} -if(_9){ -this.reject(_9); -}else{ -if(_4.checkStatus(_a.status)){ -this.resolve(_8); -}else{ -_9=new _1("Unable to load "+_8.url+" status: "+_a.status,_8); -this.reject(_9); -} -} -}; -var _b,_c,_d,_e; -if(_5("native-xhr2")){ -_b=function(_f){ -return !this.isFulfilled(); -}; -_e=function(dfd,_10){ -_10.xhr.abort(); -}; -_d=function(_11,dfd,_12){ -function _13(evt){ -dfd.handleResponse(_12); -}; -function _14(evt){ -var _15=evt.target; -var _16=new _1("Unable to load "+_12.url+" status: "+_15.status,_12); -dfd.handleResponse(_12,_16); -}; -function _17(evt){ -if(evt.lengthComputable){ -_12.loaded=evt.loaded; -_12.total=evt.total; -dfd.progress(_12); -}else{ -if(_12.xhr.readyState===3){ -_12.loaded=evt.position; -dfd.progress(_12); -} -} -}; -_11.addEventListener("load",_13,false); -_11.addEventListener("error",_14,false); -_11.addEventListener("progress",_17,false); -return function(){ -_11.removeEventListener("load",_13,false); -_11.removeEventListener("error",_14,false); -_11.removeEventListener("progress",_17,false); -_11=null; -}; -}; -}else{ -_b=function(_18){ -return _18.xhr.readyState; -}; -_c=function(_19){ -return 4===_19.xhr.readyState; -}; -_e=function(dfd,_1a){ -var xhr=_1a.xhr; -var _1b=typeof xhr.abort; -if(_1b==="function"||_1b==="object"||_1b==="unknown"){ -xhr.abort(); -} -}; -} -function _1c(_1d){ -return this.xhr.getResponseHeader(_1d); -}; -var _1e,_1f={data:null,query:null,sync:false,method:"GET"}; -function xhr(url,_20,_21){ -var _22=_5("native-formdata")&&_20&&_20.data&&_20.data instanceof FormData; -var _23=_4.parseArgs(url,_4.deepCreate(_1f,_20),_22); -url=_23.url; -_20=_23.options; -var _24,_25=function(){ -_24&&_24(); -}; -var dfd=_4.deferred(_23,_e,_b,_c,_7,_25); -var _26=_23.xhr=xhr._create(); -if(!_26){ -dfd.cancel(new _1("XHR was not created")); -return _21?dfd:dfd.promise; -} -_23.getHeader=_1c; -if(_d){ -_24=_d(_26,dfd,_23); -} -var _27=_20.data,_28=!_20.sync,_29=_20.method; -try{ -_26.open(_29,url,_28,_20.user||_1e,_20.password||_1e); -if(_20.withCredentials){ -_26.withCredentials=_20.withCredentials; -} -if(_5("native-response-type")&&_20.handleAs in _6){ -_26.responseType=_20.handleAs; -} -var _2a=_20.headers,_2b=_22?false:"application/x-www-form-urlencoded"; -if(_2a){ -for(var hdr in _2a){ -if(hdr.toLowerCase()==="content-type"){ -_2b=_2a[hdr]; -}else{ -if(_2a[hdr]){ -_26.setRequestHeader(hdr,_2a[hdr]); -} -} -} -} -if(_2b&&_2b!==false){ -_26.setRequestHeader("Content-Type",_2b); -} -if(!_2a||!("X-Requested-With" in _2a)){ -_26.setRequestHeader("X-Requested-With","XMLHttpRequest"); -} -if(_4.notify){ -_4.notify.emit("send",_23,dfd.promise.cancel); -} -_26.send(_27); -} -catch(e){ -dfd.reject(e); -} -_2(dfd); -_26=null; -return _21?dfd:dfd.promise; -}; -xhr._create=function(){ -throw new Error("XMLHTTP not available"); -}; -if(_5("native-xhr")&&!_5("dojo-force-activex-xhr")){ -xhr._create=function(){ -return new XMLHttpRequest(); -}; -}else{ -if(_5("activex")){ -try{ -new ActiveXObject("Msxml2.XMLHTTP"); -xhr._create=function(){ -return new ActiveXObject("Msxml2.XMLHTTP"); -}; -} -catch(e){ -try{ -new ActiveXObject("Microsoft.XMLHTTP"); -xhr._create=function(){ -return new ActiveXObject("Microsoft.XMLHTTP"); -}; -} -catch(e){ -} -} -} -} -_4.addCommonMethods(xhr); -return xhr; -}); diff --git a/lib/dojo/request/xhr.js.uncompressed.js b/lib/dojo/request/xhr.js.uncompressed.js deleted file mode 100644 index 7a1d2e2..0000000 --- a/lib/dojo/request/xhr.js.uncompressed.js +++ /dev/null @@ -1,337 +0,0 @@ -define("dojo/request/xhr", [ - '../errors/RequestError', - './watch', - './handlers', - './util', - '../has'/*=====, - '../request', - '../_base/declare' =====*/ -], function(RequestError, watch, handlers, util, has/*=====, request, declare =====*/){ - has.add('native-xhr', function(){ - // if true, the environment has a native XHR implementation - return typeof XMLHttpRequest !== 'undefined'; - }); - has.add('dojo-force-activex-xhr', function(){ - return has('activex') && !document.addEventListener && window.location.protocol === 'file:'; - }); - - has.add('native-xhr2', function(){ - if(!has('native-xhr')){ return; } - var x = new XMLHttpRequest(); - return typeof x['addEventListener'] !== 'undefined' && - (typeof opera === 'undefined' || typeof x['upload'] !== 'undefined'); - }); - - has.add('native-formdata', function(){ - // if true, the environment has a native FormData implementation - return typeof FormData !== 'undefined'; - }); - - has.add('native-response-type', function(){ - return has('native-xhr') && typeof new XMLHttpRequest().responseType !== 'undefined'; - }); - - // Google Chrome doesn't support "json" response type - // up to version 30, so it's intentionally not included here - var nativeResponseTypes = {'blob': 1, 'document': 1, 'arraybuffer': 1}; - - function handleResponse(response, error){ - var _xhr = response.xhr; - response.status = response.xhr.status; - - try { - // Firefox throws an error when trying to access - // xhr.responseText if response isn't text - response.text = _xhr.responseText; - } catch (e) {} - - if(response.options.handleAs === 'xml'){ - response.data = _xhr.responseXML; - } - - if(!error){ - try{ - handlers(response); - }catch(e){ - error = e; - } - } - - if(error){ - this.reject(error); - }else if(util.checkStatus(_xhr.status)){ - this.resolve(response); - }else{ - error = new RequestError('Unable to load ' + response.url + ' status: ' + _xhr.status, response); - - this.reject(error); - } - } - - var isValid, isReady, addListeners, cancel; - if(has('native-xhr2')){ - // Any platform with XHR2 will only use the watch mechanism for timeout. - - isValid = function(response){ - // summary: - // Check to see if the request should be taken out of the watch queue - return !this.isFulfilled(); - }; - cancel = function(dfd, response){ - // summary: - // Canceler for deferred - response.xhr.abort(); - }; - addListeners = function(_xhr, dfd, response){ - // summary: - // Adds event listeners to the XMLHttpRequest object - function onLoad(evt){ - dfd.handleResponse(response); - } - function onError(evt){ - var _xhr = evt.target; - var error = new RequestError('Unable to load ' + response.url + ' status: ' + _xhr.status, response); - dfd.handleResponse(response, error); - } - - function onProgress(evt){ - if(evt.lengthComputable){ - response.loaded = evt.loaded; - response.total = evt.total; - dfd.progress(response); - } else if(response.xhr.readyState === 3){ - response.loaded = evt.position; - dfd.progress(response); - } - } - - _xhr.addEventListener('load', onLoad, false); - _xhr.addEventListener('error', onError, false); - _xhr.addEventListener('progress', onProgress, false); - - return function(){ - _xhr.removeEventListener('load', onLoad, false); - _xhr.removeEventListener('error', onError, false); - _xhr.removeEventListener('progress', onProgress, false); - _xhr = null; - }; - }; - }else{ - isValid = function(response){ - return response.xhr.readyState; //boolean - }; - isReady = function(response){ - return 4 === response.xhr.readyState; //boolean - }; - cancel = function(dfd, response){ - // summary: - // canceller function for util.deferred call. - var xhr = response.xhr; - var _at = typeof xhr.abort; - if(_at === 'function' || _at === 'object' || _at === 'unknown'){ - xhr.abort(); - } - }; - } - - function getHeader(headerName){ - return this.xhr.getResponseHeader(headerName); - } - - var undefined, - defaultOptions = { - data: null, - query: null, - sync: false, - method: 'GET' - }; - function xhr(url, options, returnDeferred){ - var isFormData = has('native-formdata') && options && options.data && options.data instanceof FormData; - var response = util.parseArgs( - url, - util.deepCreate(defaultOptions, options), - isFormData - ); - url = response.url; - options = response.options; - - var remover, - last = function(){ - remover && remover(); - }; - - //Make the Deferred object for this xhr request. - var dfd = util.deferred( - response, - cancel, - isValid, - isReady, - handleResponse, - last - ); - var _xhr = response.xhr = xhr._create(); - - if(!_xhr){ - // If XHR factory somehow returns nothings, - // cancel the deferred. - dfd.cancel(new RequestError('XHR was not created')); - return returnDeferred ? dfd : dfd.promise; - } - - response.getHeader = getHeader; - - if(addListeners){ - remover = addListeners(_xhr, dfd, response); - } - - var data = options.data, - async = !options.sync, - method = options.method; - - try{ - // IE6 won't let you call apply() on the native function. - _xhr.open(method, url, async, options.user || undefined, options.password || undefined); - - if(options.withCredentials){ - _xhr.withCredentials = options.withCredentials; - } - - if(has('native-response-type') && options.handleAs in nativeResponseTypes) { - _xhr.responseType = options.handleAs; - } - - var headers = options.headers, - contentType = isFormData ? false : 'application/x-www-form-urlencoded'; - if(headers){ - for(var hdr in headers){ - if(hdr.toLowerCase() === 'content-type'){ - contentType = headers[hdr]; - }else if(headers[hdr]){ - //Only add header if it has a value. This allows for instance, skipping - //insertion of X-Requested-With by specifying empty value. - _xhr.setRequestHeader(hdr, headers[hdr]); - } - } - } - - if(contentType && contentType !== false){ - _xhr.setRequestHeader('Content-Type', contentType); - } - if(!headers || !('X-Requested-With' in headers)){ - _xhr.setRequestHeader('X-Requested-With', 'XMLHttpRequest'); - } - - if(util.notify){ - util.notify.emit('send', response, dfd.promise.cancel); - } - _xhr.send(data); - }catch(e){ - dfd.reject(e); - } - - watch(dfd); - _xhr = null; - - return returnDeferred ? dfd : dfd.promise; - } - - /*===== - xhr = function(url, options){ - // summary: - // Sends a request using XMLHttpRequest with the given URL and options. - // url: String - // URL to request - // options: dojo/request/xhr.__Options? - // Options for the request. - // returns: dojo/request.__Promise - }; - xhr.__BaseOptions = declare(request.__BaseOptions, { - // sync: Boolean? - // Whether to make a synchronous request or not. Default - // is `false` (asynchronous). - // data: String|Object|FormData? - // Data to transfer. This is ignored for GET and DELETE - // requests. - // headers: Object? - // Headers to use for the request. - // user: String? - // Username to use during the request. - // password: String? - // Password to use during the request. - // withCredentials: Boolean? - // For cross-site requests, whether to send credentials - // or not. - }); - xhr.__MethodOptions = declare(null, { - // method: String? - // The HTTP method to use to make the request. Must be - // uppercase. Default is `"GET"`. - }); - xhr.__Options = declare([xhr.__BaseOptions, xhr.__MethodOptions]); - - xhr.get = function(url, options){ - // summary: - // Send an HTTP GET request using XMLHttpRequest with the given URL and options. - // url: String - // URL to request - // options: dojo/request/xhr.__BaseOptions? - // Options for the request. - // returns: dojo/request.__Promise - }; - xhr.post = function(url, options){ - // summary: - // Send an HTTP POST request using XMLHttpRequest with the given URL and options. - // url: String - // URL to request - // options: dojo/request/xhr.__BaseOptions? - // Options for the request. - // returns: dojo/request.__Promise - }; - xhr.put = function(url, options){ - // summary: - // Send an HTTP PUT request using XMLHttpRequest with the given URL and options. - // url: String - // URL to request - // options: dojo/request/xhr.__BaseOptions? - // Options for the request. - // returns: dojo/request.__Promise - }; - xhr.del = function(url, options){ - // summary: - // Send an HTTP DELETE request using XMLHttpRequest with the given URL and options. - // url: String - // URL to request - // options: dojo/request/xhr.__BaseOptions? - // Options for the request. - // returns: dojo/request.__Promise - }; - =====*/ - xhr._create = function(){ - // summary: - // does the work of portably generating a new XMLHTTPRequest object. - throw new Error('XMLHTTP not available'); - }; - if(has('native-xhr') && !has('dojo-force-activex-xhr')){ - xhr._create = function(){ - return new XMLHttpRequest(); - }; - }else if(has('activex')){ - try{ - new ActiveXObject('Msxml2.XMLHTTP'); - xhr._create = function(){ - return new ActiveXObject('Msxml2.XMLHTTP'); - }; - }catch(e){ - try{ - new ActiveXObject('Microsoft.XMLHTTP'); - xhr._create = function(){ - return new ActiveXObject('Microsoft.XMLHTTP'); - }; - }catch(e){} - } - } - - util.addCommonMethods(xhr); - - return xhr; -}); diff --git a/lib/dojo/require.js b/lib/dojo/require.js deleted file mode 100644 index aab0d3c..0000000 --- a/lib/dojo/require.js +++ /dev/null @@ -1,12 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/require",["./_base/loader"],function(_1){ -return {dynamic:0,normalize:function(id){ -return id; -},load:_1.require}; -}); diff --git a/lib/dojo/require.js.uncompressed.js b/lib/dojo/require.js.uncompressed.js deleted file mode 100644 index e3d12dd..0000000 --- a/lib/dojo/require.js.uncompressed.js +++ /dev/null @@ -1,7 +0,0 @@ -define("dojo/require", ["./_base/loader"], function(loader){ - return { - dynamic:0, - normalize:function(id){return id;}, - load:loader.require - }; -}); diff --git a/lib/dojo/resources/LICENSE b/lib/dojo/resources/LICENSE deleted file mode 100644 index eb28b7e..0000000 --- a/lib/dojo/resources/LICENSE +++ /dev/null @@ -1,30 +0,0 @@ -License Disclaimer: - -All contents of this directory are Copyright (c) the Dojo Foundation, with the -following exceptions: -------------------------------------------------------------------------------- - -dojo.css: - * parts Copyright (c) 2007, Yahoo! Inc. All rights reserved. - Distributed under the terms of the BSD License - -The Program includes all or portions of the following software which was obtained under the terms and conditions of the BSD License. - -http://developer.yahoo.com/yui/license.html - -Copyright (c) 2007, Yahoo! Inc. - All rights reserved. - Redistribution and use of this software in source and binary forms, with or without modification, are permitted provided that the following conditions are met: - * Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. - * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the -documentation and/or other materials provided with the distribution. - * Neither the name of Yahoo! Inc. nor the names of its contributors may be used to endorse or promote products derived from this software without -specific prior written permission of Yahoo! Inc. -THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY - EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE - COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, -OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; -LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, -WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY -OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/lib/dojo/resources/blank.gif b/lib/dojo/resources/blank.gif deleted file mode 100644 index e565824..0000000 Binary files a/lib/dojo/resources/blank.gif and /dev/null differ diff --git a/lib/dojo/resources/blank.html b/lib/dojo/resources/blank.html deleted file mode 100644 index 40fe770..0000000 --- a/lib/dojo/resources/blank.html +++ /dev/null @@ -1 +0,0 @@ -<html><head><script>isLoaded = true;</script></head><body></body></html> diff --git a/lib/dojo/resources/dnd.css b/lib/dojo/resources/dnd.css deleted file mode 100644 index a5a7556..0000000 --- a/lib/dojo/resources/dnd.css +++ /dev/null @@ -1,14 +0,0 @@ - -.dojoDndAvatar {font-size: 75%; color: black;} -.dojoDndAvatarHeader td {padding-left: 20px; padding-right: 4px; height: 16px;} -.dojoDndAvatarHeader {background: #ccc;} -.dojoDndAvatarItem {background: #eee;} -.dojoDndMove .dojoDndAvatarHeader {background-image: url(images/dndNoMove.png); background-repeat: no-repeat;} -.dojoDndCopy .dojoDndAvatarHeader {background-image: url(images/dndNoCopy.png); background-repeat: no-repeat;} -.dojoDndMove .dojoDndAvatarCanDrop .dojoDndAvatarHeader {background-image: url(images/dndMove.png); background-repeat: no-repeat;} -.dojoDndCopy .dojoDndAvatarCanDrop .dojoDndAvatarHeader {background-image: url(images/dndCopy.png); background-repeat: no-repeat;} -.dojoDndHandle {cursor: move;} -.dojoDndIgnore {cursor: default;} -.dj_a11y .dojoDndAvatar { font-size: 1em; font-weight:bold;} -.dj_a11y .dojoDndAvatarHeader td {padding-left:2px !important;} -.dj_a11y .dojoDndAvatarHeader td span {padding-right: 5px;} diff --git a/lib/dojo/resources/dojo.css b/lib/dojo/resources/dojo.css deleted file mode 100644 index baf06cb..0000000 --- a/lib/dojo/resources/dojo.css +++ /dev/null @@ -1,98 +0,0 @@ - -body, div, dl, dt, dd, li, h1, h2, h3, h4, h5, h6, pre, form, fieldset, input, textarea, p, blockquote, th, td { - margin: 0; - padding: 0; -} -fieldset, img { - border: 0 none; -} -address, caption, cite, code, dfn, th, var { - font-style: normal; - font-weight: normal; -} -caption, th { - text-align: left; -} -q:before, q:after { - content:""; -} -abbr, acronym { - border:0; -} -body { - font: 12px Myriad,Helvetica,Tahoma,Arial,clean,sans-serif; - *font-size: 75%; -} -h1 { - font-size: 1.5em; - font-weight: normal; - line-height: 1em; - margin-top: 1em; - margin-bottom:0; -} -h2 { - font-size: 1.1667em; - font-weight: bold; - line-height: 1.286em; - margin-top: 1.929em; - margin-bottom:0.643em; -} -h3, h4, h5, h6 { - font-size: 1em; - font-weight: bold; - line-height: 1.5em; - margin-top: 1.5em; - margin-bottom: 0; -} -p { - font-size: 1em; - margin-top: 1.5em; - margin-bottom: 1.5em; - line-height: 1.5em; -} -blockquote { - font-size: 0.916em; - margin-top: 3.272em; - margin-bottom: 3.272em; - line-height: 1.636em; - padding: 1.636em; - border-top: 1px solid #ccc; - border-bottom: 1px solid #ccc; -} -ol li, ul li { - font-size: 1em; - line-height: 1.5em; - margin: 0; -} -pre, code { - font-size:115%; - *font-size:100%; - font-family: Courier, "Courier New"; - background-color: #efefef; - border: 1px solid #ccc; -} -pre { - border-width: 1px 0; - padding: 1.5em; -} -table { font-size:100%; } -.dojoTabular { - border-collapse: collapse; - border-spacing: 0; - border: 1px solid #ccc; - margin: 0 1.5em; -} -.dojoTabular th { - text-align: center; - font-weight: bold; -} -.dojoTabular thead, -.dojoTabular tfoot { - background-color: #efefef; - border: 1px solid #ccc; - border-width: 1px 0; -} -.dojoTabular th, -.dojoTabular td { - padding: 0.25em 0.5em; -} diff --git a/lib/dojo/resources/iframe_history.html b/lib/dojo/resources/iframe_history.html deleted file mode 100644 index 2c5acce..0000000 --- a/lib/dojo/resources/iframe_history.html +++ /dev/null @@ -1,44 +0,0 @@ -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" - "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> - -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> -<head> - <title> - - - - -

    The Dojo Toolkit -- iframe_history.html

    - -

    This file is used in Dojo's back/fwd button management.

    - - diff --git a/lib/dojo/resources/images/dndCopy.png b/lib/dojo/resources/images/dndCopy.png deleted file mode 100644 index 660ca4f..0000000 Binary files a/lib/dojo/resources/images/dndCopy.png and /dev/null differ diff --git a/lib/dojo/resources/images/dndMove.png b/lib/dojo/resources/images/dndMove.png deleted file mode 100644 index 74af29c..0000000 Binary files a/lib/dojo/resources/images/dndMove.png and /dev/null differ diff --git a/lib/dojo/resources/images/dndNoCopy.png b/lib/dojo/resources/images/dndNoCopy.png deleted file mode 100644 index 998c2f2..0000000 Binary files a/lib/dojo/resources/images/dndNoCopy.png and /dev/null differ diff --git a/lib/dojo/resources/images/dndNoMove.png b/lib/dojo/resources/images/dndNoMove.png deleted file mode 100644 index e909173..0000000 Binary files a/lib/dojo/resources/images/dndNoMove.png and /dev/null differ diff --git a/lib/dojo/router.js b/lib/dojo/router.js deleted file mode 100644 index c8f7f72..0000000 --- a/lib/dojo/router.js +++ /dev/null @@ -1,10 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/router",["./router/RouterBase"],function(_1){ -return new _1({}); -}); diff --git a/lib/dojo/router.js.uncompressed.js b/lib/dojo/router.js.uncompressed.js deleted file mode 100644 index 5003963..0000000 --- a/lib/dojo/router.js.uncompressed.js +++ /dev/null @@ -1,28 +0,0 @@ -define("dojo/router", [ - "./router/RouterBase" -], function(RouterBase){ - - // module: - // dojo/router - -/*===== -return { - // summary: - // A singleton-style instance of dojo/router/RouterBase. See that - // module for specifics. - // example: - // | router.register("/widgets/:id", function(evt){ - // | // If "/widgets/3" was matched, - // | // evt.params.id === "3" - // | xhr.get({ - // | url: "/some/path/" + evt.params.id, - // | load: function(data){ - // | // ... - // | } - // | }); - // | }); -}; -=====*/ - - return new RouterBase({}); -}); diff --git a/lib/dojo/router/RouterBase.js b/lib/dojo/router/RouterBase.js deleted file mode 100644 index 63ec2b7..0000000 --- a/lib/dojo/router/RouterBase.js +++ /dev/null @@ -1,181 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/router/RouterBase",["dojo/_base/declare","dojo/hash","dojo/topic"],function(_1,_2,_3){ -var _4; -if(String.prototype.trim){ -_4=function(_5){ -return _5.trim(); -}; -}else{ -_4=function(_6){ -return _6.replace(/^\s\s*/,"").replace(/\s\s*$/,""); -}; -} -function _7(_8,_9,_a){ -var _b,_c,_d,_e,_f,i,l; -_b=this.callbackQueue; -_c=false; -_d=false; -_e={stopImmediatePropagation:function(){ -_c=true; -},preventDefault:function(){ -_d=true; -},oldPath:_9,newPath:_a,params:_8}; -_f=[_e]; -if(_8 instanceof Array){ -_f=_f.concat(_8); -}else{ -for(var key in _8){ -_f.push(_8[key]); -} -} -for(i=0,l=_b.length;i0?_28:null; -},_indexRoutes:function(){ -var i,l,_2a,_2b,_2c=this._routes; -_2b=this._routeIndex={}; -for(i=0,l=_2c.length;i 0 ? parameterNames : null; - }, - - _indexRoutes: function(){ - var i, l, route, routeIndex, routes = this._routes; - - // Start a new route index - routeIndex = this._routeIndex = {}; - - // Set it up again - for(i=0, l=routes.length; i= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/rpc/JsonService",["../_base/declare","../_base/Deferred","../_base/json","../_base/lang","../_base/xhr","./RpcService"],function(_1,_2,_3,_4,_5,_6){ -return _1("dojo.rpc.JsonService",_6,{bustCache:false,contentType:"application/json-rpc",lastSubmissionId:0,callRemote:function(_7,_8){ -var _9=new _2(); -this.bind(_7,_8,_9); -return _9; -},bind:function(_a,_b,_c,_d){ -var _e=_5.post({url:_d||this.serviceUrl,postData:this.createRequest(_a,_b),contentType:this.contentType,timeout:this.timeout,handleAs:"json-comment-optional"}); -_e.addCallbacks(this.resultCallback(_c),this.errorCallback(_c)); -},createRequest:function(_f,_10){ -var req={"params":_10,"method":_f,"id":++this.lastSubmissionId}; -return _3.toJson(req); -},parseResults:function(obj){ -if(_4.isObject(obj)){ -if("result" in obj){ -return obj.result; -} -if("Result" in obj){ -return obj.Result; -} -if("ResultSet" in obj){ -return obj.ResultSet; -} -} -return obj; -}}); -}); diff --git a/lib/dojo/rpc/JsonService.js.uncompressed.js b/lib/dojo/rpc/JsonService.js.uncompressed.js deleted file mode 100644 index 07c16d5..0000000 --- a/lib/dojo/rpc/JsonService.js.uncompressed.js +++ /dev/null @@ -1,87 +0,0 @@ -define("dojo/rpc/JsonService", [ - "../_base/declare", "../_base/Deferred", "../_base/json", "../_base/lang", "../_base/xhr", - "./RpcService" -], function(declare, Deferred, json, lang, xhr, RpcService){ - - // module: - // dojo/rpc/JsonService - - return declare("dojo.rpc.JsonService", RpcService, { - // summary: - // TODOC - - bustCache: false, - contentType: "application/json-rpc", - lastSubmissionId: 0, - - callRemote: function(method, params){ - // summary: - // call an arbitrary remote method without requiring it to be - // predefined with SMD - // method: string - // the name of the remote method you want to call. - // params: array - // array of parameters to pass to method - - var deferred = new Deferred(); - this.bind(method, params, deferred); - return deferred; - }, - - bind: function(method, parameters, deferredRequestHandler, url){ - // summary: - // JSON-RPC bind method. Takes remote method, parameters, - // deferred, and a url, calls createRequest to make a JSON-RPC - // envelope and passes that off with bind. - // method: string - // The name of the method we are calling - // parameters: array - // The parameters we are passing off to the method - // deferredRequestHandler: deferred - // The Deferred object for this particular request - - var def = xhr.post({ - url: url||this.serviceUrl, - postData: this.createRequest(method, parameters), - contentType: this.contentType, - timeout: this.timeout, - handleAs: "json-comment-optional" - }); - def.addCallbacks(this.resultCallback(deferredRequestHandler), this.errorCallback(deferredRequestHandler)); - }, - - createRequest: function(method, params){ - // summary: - // create a JSON-RPC envelope for the request - // method: string - // The name of the method we are creating the request for - // params: array - // The array of parameters for this request - - var req = { "params": params, "method": method, "id": ++this.lastSubmissionId }; - return json.toJson(req); - }, - - parseResults: function(/*anything*/obj){ - // summary: - // parse the result envelope and pass the results back to - // the callback function - // obj: Object - // Object containing envelope of data we receive from the server - - if(lang.isObject(obj)){ - if("result" in obj){ - return obj.result; - } - if("Result" in obj){ - return obj.Result; - } - if("ResultSet" in obj){ - return obj.ResultSet; - } - } - return obj; - } - }); - -}); diff --git a/lib/dojo/rpc/JsonpService.js b/lib/dojo/rpc/JsonpService.js deleted file mode 100644 index 67eb1ba..0000000 --- a/lib/dojo/rpc/JsonpService.js +++ /dev/null @@ -1,28 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/rpc/JsonpService",["../_base/array","../_base/declare","../_base/lang","./RpcService","../io/script"],function(_1,_2,_3,_4,_5){ -return _2("dojo.rpc.JsonpService",_4,{constructor:function(_6,_7){ -if(this.required){ -if(_7){ -_3.mixin(this.required,_7); -} -_1.forEach(this.required,function(_8){ -if(_8==""||_8==undefined){ -throw new Error("Required Service Argument not found: "+_8); -} -}); -} -},strictArgChecks:false,bind:function(_9,_a,_b,_c){ -var _d=_5.get({url:_c||this.serviceUrl,callbackParamName:this.callbackParamName||"callback",content:this.createRequest(_a),timeout:this.timeout,handleAs:"json",preventCache:true}); -_d.addCallbacks(this.resultCallback(_b),this.errorCallback(_b)); -},createRequest:function(_e){ -var _f=(_3.isArrayLike(_e)&&_e.length==1)?_e[0]:{}; -_3.mixin(_f,this.required); -return _f; -}}); -}); diff --git a/lib/dojo/rpc/JsonpService.js.uncompressed.js b/lib/dojo/rpc/JsonpService.js.uncompressed.js deleted file mode 100644 index 673a68c..0000000 --- a/lib/dojo/rpc/JsonpService.js.uncompressed.js +++ /dev/null @@ -1,66 +0,0 @@ -define("dojo/rpc/JsonpService", [ - "../_base/array", "../_base/declare", "../_base/lang", "./RpcService", "../io/script"], - function(array, declare, lang, RpcService, script){ - -// module: -// dojo/rpc/JsonpService - -return declare("dojo.rpc.JsonpService", RpcService, { - // summary: - // Generic JSONP service. Minimally extends RpcService to allow - // easy definition of nearly any JSONP style service. Example - // SMD files exist in dojox.data - - constructor: function(args, requiredArgs){ - if(this.required){ - if(requiredArgs){ - lang.mixin(this.required, requiredArgs); - } - - array.forEach(this.required, function(req){ - if(req=="" || req==undefined){ - throw new Error("Required Service Argument not found: "+req); - } - }); - } - }, - - strictArgChecks: false, - - bind: function(method, parameters, deferredRequestHandler, url){ - // summary: - // JSONP bind method. Takes remote method, parameters, - // deferred, and a url, calls createRequest to make a JSON-RPC - // envelope and passes that off with bind. - // method: string - // The name of the method we are calling - // parameters: array - // The parameters we are passing off to the method - // deferredRequestHandler: deferred - // The Deferred object for this particular request - - var def = script.get({ - url: url||this.serviceUrl, - callbackParamName: this.callbackParamName||"callback", - content: this.createRequest(parameters), - timeout: this.timeout, - handleAs: "json", - preventCache: true - }); - def.addCallbacks(this.resultCallback(deferredRequestHandler), this.errorCallback(deferredRequestHandler)); - }, - - createRequest: function(parameters){ - // summary: - // create a JSONP req - // params: array - // The array of parameters for this request; - - var params = (lang.isArrayLike(parameters) && parameters.length==1) ? - parameters[0] : {}; - lang.mixin(params,this.required); - return params; - } -}); - -}); diff --git a/lib/dojo/rpc/RpcService.js b/lib/dojo/rpc/RpcService.js deleted file mode 100644 index a3f216d..0000000 --- a/lib/dojo/rpc/RpcService.js +++ /dev/null @@ -1,86 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/rpc/RpcService",["../_base/array","../_base/declare","../_base/Deferred","../_base/kernel","../_base/lang","../_base/url","../_base/xhr"],function(_1,_2,_3,_4,_5,_6,_7){ -return _2("dojo.rpc.RpcService",null,{constructor:function(_8){ -if(_8){ -if((_5.isString(_8))||(_8 instanceof _6)){ -if(_8 instanceof _6){ -var _9=_8+""; -}else{ -_9=_8; -} -var _a=_7.get({url:_9,handleAs:"json-comment-optional",sync:true}); -_a.addCallback(this,"processSmd"); -_a.addErrback(function(){ -throw new Error("Unable to load SMD from "+_8); -}); -}else{ -if(_8.smdStr){ -this.processSmd(_4.eval("("+_8.smdStr+")")); -}else{ -if(_8.serviceUrl){ -this.serviceUrl=_8.serviceUrl; -} -this.timeout=_8.timeout||0; -if("strictArgChecks" in _8){ -this.strictArgChecks=_8.strictArgChecks; -} -this.processSmd(_8); -} -} -} -},strictArgChecks:true,serviceUrl:"",parseResults:function(_b){ -return _b; -},errorCallback:function(_c){ -return function(_d){ -_c.errback(_d.message); -}; -},resultCallback:function(_e){ -return _5.hitch(this,function(_f){ -if(_f.error!=null){ -var err; -if(typeof _f.error=="object"){ -err=new Error(_f.error.message); -err.code=_f.error.code; -err.error=_f.error.error; -}else{ -err=new Error(_f.error); -} -err.id=_f.id; -err.errorObject=_f; -_e.errback(err); -}else{ -_e.callback(this.parseResults(_f)); -} -}); -},generateMethod:function(_10,_11,url){ -return _5.hitch(this,function(){ -var _12=new _3(); -if((this.strictArgChecks)&&(_11!=null)&&(arguments.length!=_11.length)){ -throw new Error("Invalid number of parameters for remote method."); -}else{ -this.bind(_10,_5._toArray(arguments),_12,url); -} -return _12; -}); -},processSmd:function(_13){ -if(_13.methods){ -_1.forEach(_13.methods,function(m){ -if(m&&m.name){ -this[m.name]=this.generateMethod(m.name,m.parameters,m.url||m.serviceUrl||m.serviceURL); -if(!_5.isFunction(this[m.name])){ -throw new Error("RpcService: Failed to create"+m.name+"()"); -} -} -},this); -} -this.serviceUrl=_13.serviceUrl||_13.serviceURL; -this.required=_13.required; -this.smd=_13; -}}); -}); diff --git a/lib/dojo/rpc/RpcService.js.uncompressed.js b/lib/dojo/rpc/RpcService.js.uncompressed.js deleted file mode 100644 index 3365204..0000000 --- a/lib/dojo/rpc/RpcService.js.uncompressed.js +++ /dev/null @@ -1,178 +0,0 @@ -define("dojo/rpc/RpcService", [ - "../_base/array", "../_base/declare", "../_base/Deferred", "../_base/kernel","../_base/lang", - "../_base/url", "../_base/xhr" -], function(array, declare, Deferred, kernel, lang, _Url, xhr){ - -// module: -// dojo/rpc/RpcService - -return declare("dojo.rpc.RpcService", null, { - // summary: - // TODOC - - constructor: function(args){ - // summary: - // Take a string as a url to retrieve an smd or an object that is an smd or partial smd to use - // as a definition for the service - // - // args: object - // Takes a number of properties as kwArgs for defining the service. It also - // accepts a string. When passed a string, it is treated as a url from - // which it should synchronously retrieve an smd file. Otherwise it is a kwArgs - // object. It accepts serviceUrl, to manually define a url for the rpc service - // allowing the rpc system to be used without an smd definition. strictArgChecks - // forces the system to verify that the # of arguments provided in a call - // matches those defined in the smd. smdString allows a developer to pass - // a jsonString directly, which will be converted into an object or alternatively - // smdObject is accepts an smdObject directly. - // - if(args){ - //if the arg is a string, we assume it is a url to retrieve an smd definition from - if( (lang.isString(args)) || (args instanceof _Url)){ - if (args instanceof _Url){ - var url = args + ""; - }else{ - url = args; - } - var def = xhr.get({ - url: url, - handleAs: "json-comment-optional", - sync: true - }); - - def.addCallback(this, "processSmd"); - def.addErrback(function(){ - throw new Error("Unable to load SMD from " + args); - }); - - }else if(args.smdStr){ - this.processSmd(kernel.eval("("+args.smdStr+")")); - }else{ - // otherwise we assume it's an arguments object with the following - // (optional) properties: - // - serviceUrl - // - strictArgChecks - // - smdStr - // - smdObj - - if(args.serviceUrl){ - this.serviceUrl = args.serviceUrl; - } - - this.timeout = args.timeout || 0; - - if("strictArgChecks" in args){ - this.strictArgChecks = args.strictArgChecks; - } - - this.processSmd(args); - } - } - }, - - strictArgChecks: true, - serviceUrl: "", - - parseResults: function(obj){ - // summary: - // parse the results coming back from an rpc request. this - // base implementation, just returns the full object - // subclasses should parse and only return the actual results - // obj: Object - // Object that is the return results from an rpc request - return obj; - }, - - errorCallback: function(/* dojo/_base/Deferred */ deferredRequestHandler){ - // summary: - // create callback that calls the Deferred errback method - // deferredRequestHandler: Deferred - // The deferred object handling a request. - return function(data){ - deferredRequestHandler.errback(data.message); - }; - }, - - resultCallback: function(/* dojo/_base/Deferred */ deferredRequestHandler){ - // summary: - // create callback that calls the Deferred's callback method - // deferredRequestHandler: Deferred - // The deferred object handling a request. - - return lang.hitch(this, - function(obj){ - if(obj.error!=null){ - var err; - if(typeof obj.error == 'object'){ - err = new Error(obj.error.message); - err.code = obj.error.code; - err.error = obj.error.error; - }else{ - err = new Error(obj.error); - } - err.id = obj.id; - err.errorObject = obj; - deferredRequestHandler.errback(err); - }else{ - deferredRequestHandler.callback(this.parseResults(obj)); - } - } - ); - }, - - generateMethod: function(/*string*/ method, /*array*/ parameters, /*string*/ url){ - // summary: - // generate the local bind methods for the remote object - // method: string - // The name of the method we are generating - // parameters: array - // the array of parameters for this call. - // url: string - // the service url for this call - - return lang.hitch(this, function(){ - var deferredRequestHandler = new Deferred(); - - // if params weren't specified, then we can assume it's varargs - if( (this.strictArgChecks) && - (parameters != null) && - (arguments.length != parameters.length) - ){ - // put error stuff here, no enough params - throw new Error("Invalid number of parameters for remote method."); - }else{ - this.bind(method, lang._toArray(arguments), deferredRequestHandler, url); - } - - return deferredRequestHandler; - }); - }, - - processSmd: function(object){ - // summary: - // callback method for receipt of a smd object. Parse the smd - // and generate functions based on the description - // object: - // smd object defining this service. - - if(object.methods){ - array.forEach(object.methods, function(m){ - if(m && m.name){ - this[m.name] = this.generateMethod( m.name, - m.parameters, - m.url||m.serviceUrl||m.serviceURL); - if(!lang.isFunction(this[m.name])){ - throw new Error("RpcService: Failed to create" + m.name + "()"); - /*console.log("RpcService: Failed to create", m.name, "()");*/ - } - } - }, this); - } - - this.serviceUrl = object.serviceUrl||object.serviceURL; - this.required = object.required; - this.smd = object; - } -}); - -}); diff --git a/lib/dojo/selector/_loader.js b/lib/dojo/selector/_loader.js deleted file mode 100644 index bb7b09d..0000000 --- a/lib/dojo/selector/_loader.js +++ /dev/null @@ -1,40 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/selector/_loader",["../has","require"],function(_1,_2){ -"use strict"; -var _3=document.createElement("div"); -_1.add("dom-qsa2.1",!!_3.querySelectorAll); -_1.add("dom-qsa3",function(){ -try{ -_3.innerHTML="

    "; -return _3.querySelectorAll(".TEST:empty").length==1; -} -catch(e){ -} -}); -var _4; -var _5="./acme",_6="./lite"; -return {load:function(id,_7,_8,_9){ -var _a=_2; -id=id=="default"?_1("config-selectorEngine")||"css3":id; -id=id=="css2"||id=="lite"?_6:id=="css2.1"?_1("dom-qsa2.1")?_6:_5:id=="css3"?_1("dom-qsa3")?_6:_5:id=="acme"?_5:(_a=_7)&&id; -if(id.charAt(id.length-1)=="?"){ -id=id.substring(0,id.length-1); -var _b=true; -} -if(_b&&(_1("dom-compliant-qsa")||_4)){ -return _8(_4); -} -_a([id],function(_c){ -if(id!="./lite"){ -_4=_c; -} -_8(_c); -}); -}}; -}); diff --git a/lib/dojo/selector/_loader.js.uncompressed.js b/lib/dojo/selector/_loader.js.uncompressed.js deleted file mode 100644 index 8c165c3..0000000 --- a/lib/dojo/selector/_loader.js.uncompressed.js +++ /dev/null @@ -1,47 +0,0 @@ -define("dojo/selector/_loader", ["../has", "require"], - function(has, require){ - -"use strict"; -var testDiv = document.createElement("div"); -has.add("dom-qsa2.1", !!testDiv.querySelectorAll); -has.add("dom-qsa3", function(){ - // test to see if we have a reasonable native selector engine available - try{ - testDiv.innerHTML = "

    "; // test kind of from sizzle - // Safari can't handle uppercase or unicode characters when - // in quirks mode, IE8 can't handle pseudos like :empty - return testDiv.querySelectorAll(".TEST:empty").length == 1; - }catch(e){} - }); -var fullEngine; -var acme = "./acme", lite = "./lite"; -return { - // summary: - // This module handles loading the appropriate selector engine for the given browser - - load: function(id, parentRequire, loaded, config){ - var req = require; - // here we implement the default logic for choosing a selector engine - id = id == "default" ? has("config-selectorEngine") || "css3" : id; - id = id == "css2" || id == "lite" ? lite : - id == "css2.1" ? has("dom-qsa2.1") ? lite : acme : - id == "css3" ? has("dom-qsa3") ? lite : acme : - id == "acme" ? acme : (req = parentRequire) && id; - if(id.charAt(id.length-1) == '?'){ - id = id.substring(0,id.length - 1); - var optionalLoad = true; - } - // the query engine is optional, only load it if a native one is not available or existing one has not been loaded - if(optionalLoad && (has("dom-compliant-qsa") || fullEngine)){ - return loaded(fullEngine); - } - // load the referenced selector engine - req([id], function(engine){ - if(id != "./lite"){ - fullEngine = engine; - } - loaded(engine); - }); - } -}; -}); diff --git a/lib/dojo/selector/acme.js b/lib/dojo/selector/acme.js deleted file mode 100644 index e331b27..0000000 --- a/lib/dojo/selector/acme.js +++ /dev/null @@ -1,792 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/selector/acme",["../dom","../sniff","../_base/array","../_base/lang","../_base/window"],function(_1,_2,_3,_4,_5){ -var _6=_4.trim; -var _7=_3.forEach; -var _8=function(){ -return _5.doc; -}; -var _9=(_8().compatMode)=="BackCompat"; -var _a=">~+"; -var _b=false; -var _c=function(){ -return true; -}; -var _d=function(_e){ -if(_a.indexOf(_e.slice(-1))>=0){ -_e+=" * "; -}else{ -_e+=" "; -} -var ts=function(s,e){ -return _6(_e.slice(s,e)); -}; -var _f=[]; -var _10=-1,_11=-1,_12=-1,_13=-1,_14=-1,_15=-1,_16=-1,_17,lc="",cc="",_18; -var x=0,ql=_e.length,_19=null,_1a=null; -var _1b=function(){ -if(_16>=0){ -var tv=(_16==x)?null:ts(_16,x); -_19[(_a.indexOf(tv)<0)?"tag":"oper"]=tv; -_16=-1; -} -}; -var _1c=function(){ -if(_15>=0){ -_19.id=ts(_15,x).replace(/\\/g,""); -_15=-1; -} -}; -var _1d=function(){ -if(_14>=0){ -_19.classes.push(ts(_14+1,x).replace(/\\/g,"")); -_14=-1; -} -}; -var _1e=function(){ -_1c(); -_1b(); -_1d(); -}; -var _1f=function(){ -_1e(); -if(_13>=0){ -_19.pseudos.push({name:ts(_13+1,x)}); -} -_19.loops=(_19.pseudos.length||_19.attrs.length||_19.classes.length); -_19.oquery=_19.query=ts(_18,x); -_19.otag=_19.tag=(_19["oper"])?null:(_19.tag||"*"); -if(_19.tag){ -_19.tag=_19.tag.toUpperCase(); -} -if(_f.length&&(_f[_f.length-1].oper)){ -_19.infixOper=_f.pop(); -_19.query=_19.infixOper.query+" "+_19.query; -} -_f.push(_19); -_19=null; -}; -for(;lc=cc,cc=_e.charAt(x),x=0){ -if(cc=="]"){ -if(!_1a.attr){ -_1a.attr=ts(_10+1,x); -}else{ -_1a.matchFor=ts((_12||_10+1),x); -} -var cmf=_1a.matchFor; -if(cmf){ -if((cmf.charAt(0)=="\"")||(cmf.charAt(0)=="'")){ -_1a.matchFor=cmf.slice(1,-1); -} -} -if(_1a.matchFor){ -_1a.matchFor=_1a.matchFor.replace(/\\/g,""); -} -_19.attrs.push(_1a); -_1a=null; -_10=_12=-1; -}else{ -if(cc=="="){ -var _20=("|~^$*".indexOf(lc)>=0)?lc:""; -_1a.type=_20+cc; -_1a.attr=ts(_10+1,x-_20.length); -_12=x+1; -} -} -}else{ -if(_11>=0){ -if(cc==")"){ -if(_13>=0){ -_1a.value=ts(_11+1,x); -} -_13=_11=-1; -} -}else{ -if(cc=="#"){ -_1e(); -_15=x+1; -}else{ -if(cc=="."){ -_1e(); -_14=x; -}else{ -if(cc==":"){ -_1e(); -_13=x; -}else{ -if(cc=="["){ -_1e(); -_10=x; -_1a={}; -}else{ -if(cc=="("){ -if(_13>=0){ -_1a={name:ts(_13+1,x),value:null}; -_19.pseudos.push(_1a); -} -_11=x; -}else{ -if((cc==" ")&&(lc!=cc)){ -_1f(); -} -} -} -} -} -} -} -} -} -return _f; -}; -var _21=function(_22,_23){ -if(!_22){ -return _23; -} -if(!_23){ -return _22; -} -return function(){ -return _22.apply(window,arguments)&&_23.apply(window,arguments); -}; -}; -var _24=function(i,arr){ -var r=arr||[]; -if(i){ -r.push(i); -} -return r; -}; -var _25=function(n){ -return (1==n.nodeType); -}; -var _26=""; -var _27=function(_28,_29){ -if(!_28){ -return _26; -} -if(_29=="class"){ -return _28.className||_26; -} -if(_29=="for"){ -return _28.htmlFor||_26; -} -if(_29=="style"){ -return _28.style.cssText||_26; -} -return (_b?_28.getAttribute(_29):_28.getAttribute(_29,2))||_26; -}; -var _2a={"*=":function(_2b,_2c){ -return function(_2d){ -return (_27(_2d,_2b).indexOf(_2c)>=0); -}; -},"^=":function(_2e,_2f){ -return function(_30){ -return (_27(_30,_2e).indexOf(_2f)==0); -}; -},"$=":function(_31,_32){ -return function(_33){ -var ea=" "+_27(_33,_31); -var _34=ea.lastIndexOf(_32); -return _34>-1&&(_34==(ea.length-_32.length)); -}; -},"~=":function(_35,_36){ -var _37=" "+_36+" "; -return function(_38){ -var ea=" "+_27(_38,_35)+" "; -return (ea.indexOf(_37)>=0); -}; -},"|=":function(_39,_3a){ -var _3b=_3a+"-"; -return function(_3c){ -var ea=_27(_3c,_39); -return ((ea==_3a)||(ea.indexOf(_3b)==0)); -}; -},"=":function(_3d,_3e){ -return function(_3f){ -return (_27(_3f,_3d)==_3e); -}; -}}; -var _40=(typeof _8().firstChild.nextElementSibling=="undefined"); -var _41=!_40?"nextElementSibling":"nextSibling"; -var _42=!_40?"previousElementSibling":"previousSibling"; -var _43=(_40?_25:_c); -var _44=function(_45){ -while(_45=_45[_42]){ -if(_43(_45)){ -return false; -} -} -return true; -}; -var _46=function(_47){ -while(_47=_47[_41]){ -if(_43(_47)){ -return false; -} -} -return true; -}; -var _48=function(_49){ -var _4a=_49.parentNode; -_4a=_4a.nodeType!=7?_4a:_4a.nextSibling; -var i=0,_4b=_4a.children||_4a.childNodes,ci=(_49["_i"]||_49.getAttribute("_i")||-1),cl=(_4a["_l"]||(typeof _4a.getAttribute!=="undefined"?_4a.getAttribute("_l"):-1)); -if(!_4b){ -return -1; -} -var l=_4b.length; -if(cl==l&&ci>=0&&cl>=0){ -return ci; -} -if(_2("ie")&&typeof _4a.setAttribute!=="undefined"){ -_4a.setAttribute("_l",l); -}else{ -_4a["_l"]=l; -} -ci=-1; -for(var te=_4a["firstElementChild"]||_4a["firstChild"];te;te=te[_41]){ -if(_43(te)){ -if(_2("ie")){ -te.setAttribute("_i",++i); -}else{ -te["_i"]=++i; -} -if(_49===te){ -ci=i; -} -} -} -return ci; -}; -var _4c=function(_4d){ -return !((_48(_4d))%2); -}; -var _4e=function(_4f){ -return ((_48(_4f))%2); -}; -var _50={"checked":function(_51,_52){ -return function(_53){ -return !!("checked" in _53?_53.checked:_53.selected); -}; -},"disabled":function(_54,_55){ -return function(_56){ -return _56.disabled; -}; -},"enabled":function(_57,_58){ -return function(_59){ -return !_59.disabled; -}; -},"first-child":function(){ -return _44; -},"last-child":function(){ -return _46; -},"only-child":function(_5a,_5b){ -return function(_5c){ -return _44(_5c)&&_46(_5c); -}; -},"empty":function(_5d,_5e){ -return function(_5f){ -var cn=_5f.childNodes; -var cnl=_5f.childNodes.length; -for(var x=cnl-1;x>=0;x--){ -var nt=cn[x].nodeType; -if((nt===1)||(nt==3)){ -return false; -} -} -return true; -}; -},"contains":function(_60,_61){ -var cz=_61.charAt(0); -if(cz=="\""||cz=="'"){ -_61=_61.slice(1,-1); -} -return function(_62){ -return (_62.innerHTML.indexOf(_61)>=0); -}; -},"not":function(_63,_64){ -var p=_d(_64)[0]; -var _65={el:1}; -if(p.tag!="*"){ -_65.tag=1; -} -if(!p.classes.length){ -_65.classes=1; -} -var ntf=_66(p,_65); -return function(_67){ -return (!ntf(_67)); -}; -},"nth-child":function(_68,_69){ -var pi=parseInt; -if(_69=="odd"){ -return _4e; -}else{ -if(_69=="even"){ -return _4c; -} -} -if(_69.indexOf("n")!=-1){ -var _6a=_69.split("n",2); -var _6b=_6a[0]?((_6a[0]=="-")?-1:pi(_6a[0])):1; -var idx=_6a[1]?pi(_6a[1]):0; -var lb=0,ub=-1; -if(_6b>0){ -if(idx<0){ -idx=(idx%_6b)&&(_6b+(idx%_6b)); -}else{ -if(idx>0){ -if(idx>=_6b){ -lb=idx-idx%_6b; -} -idx=idx%_6b; -} -} -}else{ -if(_6b<0){ -_6b*=-1; -if(idx>0){ -ub=idx; -idx=idx%_6b; -} -} -} -if(_6b>0){ -return function(_6c){ -var i=_48(_6c); -return (i>=lb)&&(ub<0||i<=ub)&&((i%_6b)==idx); -}; -}else{ -_69=idx; -} -} -var _6d=pi(_69); -return function(_6e){ -return (_48(_6e)==_6d); -}; -}}; -var _6f=(_2("ie")<9||_2("ie")==9&&_2("quirks"))?function(_70){ -var clc=_70.toLowerCase(); -if(clc=="class"){ -_70="className"; -} -return function(_71){ -return (_b?_71.getAttribute(_70):_71[_70]||_71[clc]); -}; -}:function(_72){ -return function(_73){ -return (_73&&_73.getAttribute&&_73.hasAttribute(_72)); -}; -}; -var _66=function(_74,_75){ -if(!_74){ -return _c; -} -_75=_75||{}; -var ff=null; -if(!("el" in _75)){ -ff=_21(ff,_25); -} -if(!("tag" in _75)){ -if(_74.tag!="*"){ -ff=_21(ff,function(_76){ -return (_76&&((_b?_76.tagName:_76.tagName.toUpperCase())==_74.getTag())); -}); -} -} -if(!("classes" in _75)){ -_7(_74.classes,function(_77,idx,arr){ -var re=new RegExp("(?:^|\\s)"+_77+"(?:\\s|$)"); -ff=_21(ff,function(_78){ -return re.test(_78.className); -}); -ff.count=idx; -}); -} -if(!("pseudos" in _75)){ -_7(_74.pseudos,function(_79){ -var pn=_79.name; -if(_50[pn]){ -ff=_21(ff,_50[pn](pn,_79.value)); -} -}); -} -if(!("attrs" in _75)){ -_7(_74.attrs,function(_7a){ -var _7b; -var a=_7a.attr; -if(_7a.type&&_2a[_7a.type]){ -_7b=_2a[_7a.type](a,_7a.matchFor); -}else{ -if(a.length){ -_7b=_6f(a); -} -} -if(_7b){ -ff=_21(ff,_7b); -} -}); -} -if(!("id" in _75)){ -if(_74.id){ -ff=_21(ff,function(_7c){ -return (!!_7c&&(_7c.id==_74.id)); -}); -} -} -if(!ff){ -if(!("default" in _75)){ -ff=_c; -} -} -return ff; -}; -var _7d=function(_7e){ -return function(_7f,ret,bag){ -while(_7f=_7f[_41]){ -if(_40&&(!_25(_7f))){ -continue; -} -if((!bag||_80(_7f,bag))&&_7e(_7f)){ -ret.push(_7f); -} -break; -} -return ret; -}; -}; -var _81=function(_82){ -return function(_83,ret,bag){ -var te=_83[_41]; -while(te){ -if(_43(te)){ -if(bag&&!_80(te,bag)){ -break; -} -if(_82(te)){ -ret.push(te); -} -} -te=te[_41]; -} -return ret; -}; -}; -var _84=function(_85){ -_85=_85||_c; -return function(_86,ret,bag){ -var te,x=0,_87=_86.children||_86.childNodes; -while(te=_87[x++]){ -if(_43(te)&&(!bag||_80(te,bag))&&(_85(te,x))){ -ret.push(te); -} -} -return ret; -}; -}; -var _88=function(_89,_8a){ -var pn=_89.parentNode; -while(pn){ -if(pn==_8a){ -break; -} -pn=pn.parentNode; -} -return !!pn; -}; -var _8b={}; -var _8c=function(_8d){ -var _8e=_8b[_8d.query]; -if(_8e){ -return _8e; -} -var io=_8d.infixOper; -var _8f=(io?io.oper:""); -var _90=_66(_8d,{el:1}); -var qt=_8d.tag; -var _91=("*"==qt); -var ecs=_8()["getElementsByClassName"]; -if(!_8f){ -if(_8d.id){ -_90=(!_8d.loops&&_91)?_c:_66(_8d,{el:1,id:1}); -_8e=function(_92,arr){ -var te=_1.byId(_8d.id,(_92.ownerDocument||_92)); -if(!te||!_90(te)){ -return; -} -if(9==_92.nodeType){ -return _24(te,arr); -}else{ -if(_88(te,_92)){ -return _24(te,arr); -} -} -}; -}else{ -if(ecs&&/\{\s*\[native code\]\s*\}/.test(String(ecs))&&_8d.classes.length&&!_9){ -_90=_66(_8d,{el:1,classes:1,id:1}); -var _93=_8d.classes.join(" "); -_8e=function(_94,arr,bag){ -var ret=_24(0,arr),te,x=0; -var _95=_94.getElementsByClassName(_93); -while((te=_95[x++])){ -if(_90(te,_94)&&_80(te,bag)){ -ret.push(te); -} -} -return ret; -}; -}else{ -if(!_91&&!_8d.loops){ -_8e=function(_96,arr,bag){ -var ret=_24(0,arr),te,x=0; -var tag=_8d.getTag(),_97=tag?_96.getElementsByTagName(tag):[]; -while((te=_97[x++])){ -if(_80(te,bag)){ -ret.push(te); -} -} -return ret; -}; -}else{ -_90=_66(_8d,{el:1,tag:1,id:1}); -_8e=function(_98,arr,bag){ -var ret=_24(0,arr),te,x=0; -var tag=_8d.getTag(),_99=tag?_98.getElementsByTagName(tag):[]; -while((te=_99[x++])){ -if(_90(te,_98)&&_80(te,bag)){ -ret.push(te); -} -} -return ret; -}; -} -} -} -}else{ -var _9a={el:1}; -if(_91){ -_9a.tag=1; -} -_90=_66(_8d,_9a); -if("+"==_8f){ -_8e=_7d(_90); -}else{ -if("~"==_8f){ -_8e=_81(_90); -}else{ -if(">"==_8f){ -_8e=_84(_90); -} -} -} -} -return _8b[_8d.query]=_8e; -}; -var _9b=function(_9c,_9d){ -var _9e=_24(_9c),qp,x,te,qpl=_9d.length,bag,ret; -for(var i=0;i0){ -bag={}; -ret.nozip=true; -} -var gef=_8c(qp); -for(var j=0;(te=_9e[j]);j++){ -gef(te,ret,bag); -} -if(!ret.length){ -break; -} -_9e=ret; -} -return ret; -}; -var _9f={},_a0={}; -var _a1=function(_a2){ -var _a3=_d(_6(_a2)); -if(_a3.length==1){ -var tef=_8c(_a3[0]); -return function(_a4){ -var r=tef(_a4,[]); -if(r){ -r.nozip=true; -} -return r; -}; -} -return function(_a5){ -return _9b(_a5,_a3); -}; -}; -var _a6=_2("ie")?"commentStrip":"nozip"; -var qsa="querySelectorAll"; -var _a7=!!_8()[qsa]; -var _a8=/\\[>~+]|n\+\d|([^ \\])?([>~+])([^ =])?/g; -var _a9=function(_aa,pre,ch,_ab){ -return ch?(pre?pre+" ":"")+ch+(_ab?" "+_ab:""):_aa; -}; -var _ac=/([^[]*)([^\]]*])?/g; -var _ad=function(_ae,_af,att){ -return _af.replace(_a8,_a9)+(att||""); -}; -var _b0=function(_b1,_b2){ -_b1=_b1.replace(_ac,_ad); -if(_a7){ -var _b3=_a0[_b1]; -if(_b3&&!_b2){ -return _b3; -} -} -var _b4=_9f[_b1]; -if(_b4){ -return _b4; -} -var qcz=_b1.charAt(0); -var _b5=(-1==_b1.indexOf(" ")); -if((_b1.indexOf("#")>=0)&&(_b5)){ -_b2=true; -} -var _b6=(_a7&&(!_b2)&&(_a.indexOf(qcz)==-1)&&(!_2("ie")||(_b1.indexOf(":")==-1))&&(!(_9&&(_b1.indexOf(".")>=0)))&&(_b1.indexOf(":contains")==-1)&&(_b1.indexOf(":checked")==-1)&&(_b1.indexOf("|=")==-1)); -if(_b6){ -var tq=(_a.indexOf(_b1.charAt(_b1.length-1))>=0)?(_b1+" *"):_b1; -return _a0[_b1]=function(_b7){ -try{ -if(!((9==_b7.nodeType)||_b5)){ -throw ""; -} -var r=_b7[qsa](tq); -r[_a6]=true; -return r; -} -catch(e){ -return _b0(_b1,true)(_b7); -} -}; -}else{ -var _b8=_b1.match(/([^\s,](?:"(?:\\.|[^"])+"|'(?:\\.|[^'])+'|[^,])*)/g); -return _9f[_b1]=((_b8.length<2)?_a1(_b1):function(_b9){ -var _ba=0,ret=[],tp; -while((tp=_b8[_ba++])){ -ret=ret.concat(_a1(tp)(_b9)); -} -return ret; -}); -} -}; -var _bb=0; -var _bc=_2("ie")?function(_bd){ -if(_b){ -return (_bd.getAttribute("_uid")||_bd.setAttribute("_uid",++_bb)||_bb); -}else{ -return _bd.uniqueID; -} -}:function(_be){ -return (_be._uid||(_be._uid=++_bb)); -}; -var _80=function(_bf,bag){ -if(!bag){ -return 1; -} -var id=_bc(_bf); -if(!bag[id]){ -return bag[id]=1; -} -return 0; -}; -var _c0="_zipIdx"; -var _c1=function(arr){ -if(arr&&arr.nozip){ -return arr; -} -if(!arr||!arr.length){ -return []; -} -if(arr.length<2){ -return [arr[0]]; -} -var ret=[]; -_bb++; -var x,te; -if(_2("ie")&&_b){ -var _c2=_bb+""; -for(x=0;x= 0){ - // if we end with a ">", "+", or "~", that means we're implicitly - // searching all children, so make it explicit - query += " * "; - }else{ - // if you have not provided a terminator, one will be provided for - // you... - query += " "; - } - - var ts = function(/*Integer*/ s, /*Integer*/ e){ - // trim and slice. - - // take an index to start a string slice from and an end position - // and return a trimmed copy of that sub-string - return trim(query.slice(s, e)); - }; - - // the overall data graph of the full query, as represented by queryPart objects - var queryParts = []; - - - // state keeping vars - var inBrackets = -1, inParens = -1, inMatchFor = -1, - inPseudo = -1, inClass = -1, inId = -1, inTag = -1, currentQuoteChar, - lc = "", cc = "", pStart; - - // iteration vars - var x = 0, // index in the query - ql = query.length, - currentPart = null, // data structure representing the entire clause - _cp = null; // the current pseudo or attr matcher - - // several temporary variables are assigned to this structure during a - // potential sub-expression match: - // attr: - // a string representing the current full attribute match in a - // bracket expression - // type: - // if there's an operator in a bracket expression, this is - // used to keep track of it - // value: - // the internals of parenthetical expression for a pseudo. for - // :nth-child(2n+1), value might be "2n+1" - - var endTag = function(){ - // called when the tokenizer hits the end of a particular tag name. - // Re-sets state variables for tag matching and sets up the matcher - // to handle the next type of token (tag or operator). - if(inTag >= 0){ - var tv = (inTag == x) ? null : ts(inTag, x); // .toLowerCase(); - currentPart[ (specials.indexOf(tv) < 0) ? "tag" : "oper" ] = tv; - inTag = -1; - } - }; - - var endId = function(){ - // called when the tokenizer might be at the end of an ID portion of a match - if(inId >= 0){ - currentPart.id = ts(inId, x).replace(/\\/g, ""); - inId = -1; - } - }; - - var endClass = function(){ - // called when the tokenizer might be at the end of a class name - // match. CSS allows for multiple classes, so we augment the - // current item with another class in its list - if(inClass >= 0){ - currentPart.classes.push(ts(inClass + 1, x).replace(/\\/g, "")); - inClass = -1; - } - }; - - var endAll = function(){ - // at the end of a simple fragment, so wall off the matches - endId(); - endTag(); - endClass(); - }; - - var endPart = function(){ - endAll(); - if(inPseudo >= 0){ - currentPart.pseudos.push({ name: ts(inPseudo + 1, x) }); - } - // hint to the selector engine to tell it whether or not it - // needs to do any iteration. Many simple selectors don't, and - // we can avoid significant construction-time work by advising - // the system to skip them - currentPart.loops = ( - currentPart.pseudos.length || - currentPart.attrs.length || - currentPart.classes.length ); - - currentPart.oquery = currentPart.query = ts(pStart, x); // save the full expression as a string - - - // otag/tag are hints to suggest to the system whether or not - // it's an operator or a tag. We save a copy of otag since the - // tag name is cast to upper-case in regular HTML matches. The - // system has a global switch to figure out if the current - // expression needs to be case sensitive or not and it will use - // otag or tag accordingly - currentPart.otag = currentPart.tag = (currentPart["oper"]) ? null : (currentPart.tag || "*"); - - if(currentPart.tag){ - // if we're in a case-insensitive HTML doc, we likely want - // the toUpperCase when matching on element.tagName. If we - // do it here, we can skip the string op per node - // comparison - currentPart.tag = currentPart.tag.toUpperCase(); - } - - // add the part to the list - if(queryParts.length && (queryParts[queryParts.length-1].oper)){ - // operators are always infix, so we remove them from the - // list and attach them to the next match. The evaluator is - // responsible for sorting out how to handle them. - currentPart.infixOper = queryParts.pop(); - currentPart.query = currentPart.infixOper.query + " " + currentPart.query; - /* - console.debug( "swapping out the infix", - currentPart.infixOper, - "and attaching it to", - currentPart); - */ - } - queryParts.push(currentPart); - - currentPart = null; - }; - - // iterate over the query, character by character, building up a - // list of query part objects - for(; lc=cc, cc=query.charAt(x), x < ql; x++){ - // cc: the current character in the match - // lc: the last character (if any) - - // someone is trying to escape something, so don't try to match any - // fragments. We assume we're inside a literal. - if(lc == "\\"){ continue; } - if(!currentPart){ // a part was just ended or none has yet been created - // NOTE: I hate all this alloc, but it's shorter than writing tons of if's - pStart = x; - // rules describe full CSS sub-expressions, like: - // #someId - // .className:first-child - // but not: - // thinger > div.howdy[type=thinger] - // the indidual components of the previous query would be - // split into 3 parts that would be represented a structure like: - // [ - // { - // query: "thinger", - // tag: "thinger", - // }, - // { - // query: "div.howdy[type=thinger]", - // classes: ["howdy"], - // infixOper: { - // query: ">", - // oper: ">", - // } - // }, - // ] - currentPart = { - query: null, // the full text of the part's rule - pseudos: [], // CSS supports multiple pseud-class matches in a single rule - attrs: [], // CSS supports multi-attribute match, so we need an array - classes: [], // class matches may be additive, e.g.: .thinger.blah.howdy - tag: null, // only one tag... - oper: null, // ...or operator per component. Note that these wind up being exclusive. - id: null, // the id component of a rule - getTag: function(){ - return caseSensitive ? this.otag : this.tag; - } - }; - - // if we don't have a part, we assume we're going to start at - // the beginning of a match, which should be a tag name. This - // might fault a little later on, but we detect that and this - // iteration will still be fine. - inTag = x; - } - - // Skip processing all quoted characters. - // If we are inside quoted text then currentQuoteChar stores the character that began the quote, - // thus that character that will end it. - if(currentQuoteChar){ - if(cc == currentQuoteChar){ - currentQuoteChar = null; - } - continue; - }else if (cc == "'" || cc == '"'){ - currentQuoteChar = cc; - continue; - } - - if(inBrackets >= 0){ - // look for a the close first - if(cc == "]"){ // if we're in a [...] clause and we end, do assignment - if(!_cp.attr){ - // no attribute match was previously begun, so we - // assume this is an attribute existence match in the - // form of [someAttributeName] - _cp.attr = ts(inBrackets+1, x); - }else{ - // we had an attribute already, so we know that we're - // matching some sort of value, as in [attrName=howdy] - _cp.matchFor = ts((inMatchFor||inBrackets+1), x); - } - var cmf = _cp.matchFor; - if(cmf){ - // try to strip quotes from the matchFor value. We want - // [attrName=howdy] to match the same - // as [attrName = 'howdy' ] - if( (cmf.charAt(0) == '"') || (cmf.charAt(0) == "'") ){ - _cp.matchFor = cmf.slice(1, -1); - } - } - // remove backslash escapes from an attribute match, since DOM - // querying will get attribute values without backslashes - if(_cp.matchFor){ - _cp.matchFor = _cp.matchFor.replace(/\\/g, ""); - } - - // end the attribute by adding it to the list of attributes. - currentPart.attrs.push(_cp); - _cp = null; // necessary? - inBrackets = inMatchFor = -1; - }else if(cc == "="){ - // if the last char was an operator prefix, make sure we - // record it along with the "=" operator. - var addToCc = ("|~^$*".indexOf(lc) >=0 ) ? lc : ""; - _cp.type = addToCc+cc; - _cp.attr = ts(inBrackets+1, x-addToCc.length); - inMatchFor = x+1; - } - // now look for other clause parts - }else if(inParens >= 0){ - // if we're in a parenthetical expression, we need to figure - // out if it's attached to a pseudo-selector rule like - // :nth-child(1) - if(cc == ")"){ - if(inPseudo >= 0){ - _cp.value = ts(inParens+1, x); - } - inPseudo = inParens = -1; - } - }else if(cc == "#"){ - // start of an ID match - endAll(); - inId = x+1; - }else if(cc == "."){ - // start of a class match - endAll(); - inClass = x; - }else if(cc == ":"){ - // start of a pseudo-selector match - endAll(); - inPseudo = x; - }else if(cc == "["){ - // start of an attribute match. - endAll(); - inBrackets = x; - // provide a new structure for the attribute match to fill-in - _cp = { - /*===== - attr: null, type: null, matchFor: null - =====*/ - }; - }else if(cc == "("){ - // we really only care if we've entered a parenthetical - // expression if we're already inside a pseudo-selector match - if(inPseudo >= 0){ - // provide a new structure for the pseudo match to fill-in - _cp = { - name: ts(inPseudo+1, x), - value: null - }; - currentPart.pseudos.push(_cp); - } - inParens = x; - }else if( - (cc == " ") && - // if it's a space char and the last char is too, consume the - // current one without doing more work - (lc != cc) - ){ - endPart(); - } - } - return queryParts; - }; - - - //////////////////////////////////////////////////////////////////////// - // DOM query infrastructure - //////////////////////////////////////////////////////////////////////// - - var agree = function(first, second){ - // the basic building block of the yes/no chaining system. agree(f1, - // f2) generates a new function which returns the boolean results of - // both of the passed functions to a single logical-anded result. If - // either are not passed, the other is used exclusively. - if(!first){ return second; } - if(!second){ return first; } - - return function(){ - return first.apply(window, arguments) && second.apply(window, arguments); - }; - }; - - var getArr = function(i, arr){ - // helps us avoid array alloc when we don't need it - var r = arr||[]; // FIXME: should this be 'new d._NodeListCtor()' ? - if(i){ r.push(i); } - return r; - }; - - var _isElement = function(n){ return (1 == n.nodeType); }; - - // FIXME: need to coalesce _getAttr with defaultGetter - var blank = ""; - var _getAttr = function(elem, attr){ - if(!elem){ return blank; } - if(attr == "class"){ - return elem.className || blank; - } - if(attr == "for"){ - return elem.htmlFor || blank; - } - if(attr == "style"){ - return elem.style.cssText || blank; - } - return (caseSensitive ? elem.getAttribute(attr) : elem.getAttribute(attr, 2)) || blank; - }; - - var attrs = { - "*=": function(attr, value){ - return function(elem){ - // E[foo*="bar"] - // an E element whose "foo" attribute value contains - // the substring "bar" - return (_getAttr(elem, attr).indexOf(value)>=0); - }; - }, - "^=": function(attr, value){ - // E[foo^="bar"] - // an E element whose "foo" attribute value begins exactly - // with the string "bar" - return function(elem){ - return (_getAttr(elem, attr).indexOf(value)==0); - }; - }, - "$=": function(attr, value){ - // E[foo$="bar"] - // an E element whose "foo" attribute value ends exactly - // with the string "bar" - return function(elem){ - var ea = " "+_getAttr(elem, attr); - var lastIndex = ea.lastIndexOf(value); - return lastIndex > -1 && (lastIndex==(ea.length-value.length)); - }; - }, - "~=": function(attr, value){ - // E[foo~="bar"] - // an E element whose "foo" attribute value is a list of - // space-separated values, one of which is exactly equal - // to "bar" - - // return "[contains(concat(' ',@"+attr+",' '), ' "+ value +" ')]"; - var tval = " "+value+" "; - return function(elem){ - var ea = " "+_getAttr(elem, attr)+" "; - return (ea.indexOf(tval)>=0); - }; - }, - "|=": function(attr, value){ - // E[hreflang|="en"] - // an E element whose "hreflang" attribute has a - // hyphen-separated list of values beginning (from the - // left) with "en" - var valueDash = value+"-"; - return function(elem){ - var ea = _getAttr(elem, attr); - return ( - (ea == value) || - (ea.indexOf(valueDash)==0) - ); - }; - }, - "=": function(attr, value){ - return function(elem){ - return (_getAttr(elem, attr) == value); - }; - } - }; - - // avoid testing for node type if we can. Defining this in the negative - // here to avoid negation in the fast path. - var _noNES = (typeof getDoc().firstChild.nextElementSibling == "undefined"); - var _ns = !_noNES ? "nextElementSibling" : "nextSibling"; - var _ps = !_noNES ? "previousElementSibling" : "previousSibling"; - var _simpleNodeTest = (_noNES ? _isElement : yesman); - - var _lookLeft = function(node){ - // look left - while(node = node[_ps]){ - if(_simpleNodeTest(node)){ return false; } - } - return true; - }; - - var _lookRight = function(node){ - // look right - while(node = node[_ns]){ - if(_simpleNodeTest(node)){ return false; } - } - return true; - }; - - var getNodeIndex = function(node){ - var root = node.parentNode; - root = root.nodeType != 7 ? root : root.nextSibling; // PROCESSING_INSTRUCTION_NODE - var i = 0, - tret = root.children || root.childNodes, - ci = (node["_i"]||node.getAttribute("_i")||-1), - cl = (root["_l"]|| (typeof root.getAttribute !== "undefined" ? root.getAttribute("_l") : -1)); - - if(!tret){ return -1; } - var l = tret.length; - - // we calculate the parent length as a cheap way to invalidate the - // cache. It's not 100% accurate, but it's much more honest than what - // other libraries do - if( cl == l && ci >= 0 && cl >= 0 ){ - // if it's legit, tag and release - return ci; - } - - // else re-key things - if(has("ie") && typeof root.setAttribute !== "undefined"){ - root.setAttribute("_l", l); - }else{ - root["_l"] = l; - } - ci = -1; - for(var te = root["firstElementChild"]||root["firstChild"]; te; te = te[_ns]){ - if(_simpleNodeTest(te)){ - if(has("ie")){ - te.setAttribute("_i", ++i); - }else{ - te["_i"] = ++i; - } - if(node === te){ - // NOTE: - // shortcutting the return at this step in indexing works - // very well for benchmarking but we avoid it here since - // it leads to potential O(n^2) behavior in sequential - // getNodexIndex operations on a previously un-indexed - // parent. We may revisit this at a later time, but for - // now we just want to get the right answer more often - // than not. - ci = i; - } - } - } - return ci; - }; - - var isEven = function(elem){ - return !((getNodeIndex(elem)) % 2); - }; - - var isOdd = function(elem){ - return ((getNodeIndex(elem)) % 2); - }; - - var pseudos = { - "checked": function(name, condition){ - return function(elem){ - return !!("checked" in elem ? elem.checked : elem.selected); - }; - }, - "disabled": function(name, condition){ - return function(elem){ - return elem.disabled; - }; - }, - "enabled": function(name, condition){ - return function(elem){ - return !elem.disabled; - }; - }, - "first-child": function(){ return _lookLeft; }, - "last-child": function(){ return _lookRight; }, - "only-child": function(name, condition){ - return function(node){ - return _lookLeft(node) && _lookRight(node); - }; - }, - "empty": function(name, condition){ - return function(elem){ - // DomQuery and jQuery get this wrong, oddly enough. - // The CSS 3 selectors spec is pretty explicit about it, too. - var cn = elem.childNodes; - var cnl = elem.childNodes.length; - // if(!cnl){ return true; } - for(var x=cnl-1; x >= 0; x--){ - var nt = cn[x].nodeType; - if((nt === 1)||(nt == 3)){ return false; } - } - return true; - }; - }, - "contains": function(name, condition){ - var cz = condition.charAt(0); - if( cz == '"' || cz == "'" ){ //remove quote - condition = condition.slice(1, -1); - } - return function(elem){ - return (elem.innerHTML.indexOf(condition) >= 0); - }; - }, - "not": function(name, condition){ - var p = getQueryParts(condition)[0]; - var ignores = { el: 1 }; - if(p.tag != "*"){ - ignores.tag = 1; - } - if(!p.classes.length){ - ignores.classes = 1; - } - var ntf = getSimpleFilterFunc(p, ignores); - return function(elem){ - return (!ntf(elem)); - }; - }, - "nth-child": function(name, condition){ - var pi = parseInt; - // avoid re-defining function objects if we can - if(condition == "odd"){ - return isOdd; - }else if(condition == "even"){ - return isEven; - } - // FIXME: can we shorten this? - if(condition.indexOf("n") != -1){ - var tparts = condition.split("n", 2); - var pred = tparts[0] ? ((tparts[0] == '-') ? -1 : pi(tparts[0])) : 1; - var idx = tparts[1] ? pi(tparts[1]) : 0; - var lb = 0, ub = -1; - if(pred > 0){ - if(idx < 0){ - idx = (idx % pred) && (pred + (idx % pred)); - }else if(idx>0){ - if(idx >= pred){ - lb = idx - idx % pred; - } - idx = idx % pred; - } - }else if(pred<0){ - pred *= -1; - // idx has to be greater than 0 when pred is negative; - // shall we throw an error here? - if(idx > 0){ - ub = idx; - idx = idx % pred; - } - } - if(pred > 0){ - return function(elem){ - var i = getNodeIndex(elem); - return (i>=lb) && (ub<0 || i<=ub) && ((i % pred) == idx); - }; - }else{ - condition = idx; - } - } - var ncount = pi(condition); - return function(elem){ - return (getNodeIndex(elem) == ncount); - }; - } - }; - - var defaultGetter = (has("ie") < 9 || has("ie") == 9 && has("quirks")) ? function(cond){ - var clc = cond.toLowerCase(); - if(clc == "class"){ cond = "className"; } - return function(elem){ - return (caseSensitive ? elem.getAttribute(cond) : elem[cond]||elem[clc]); - }; - } : function(cond){ - return function(elem){ - return (elem && elem.getAttribute && elem.hasAttribute(cond)); - }; - }; - - var getSimpleFilterFunc = function(query, ignores){ - // generates a node tester function based on the passed query part. The - // query part is one of the structures generated by the query parser - // when it creates the query AST. The "ignores" object specifies which - // (if any) tests to skip, allowing the system to avoid duplicating - // work where it may have already been taken into account by other - // factors such as how the nodes to test were fetched in the first - // place - if(!query){ return yesman; } - ignores = ignores||{}; - - var ff = null; - - if(!("el" in ignores)){ - ff = agree(ff, _isElement); - } - - if(!("tag" in ignores)){ - if(query.tag != "*"){ - ff = agree(ff, function(elem){ - return (elem && ((caseSensitive ? elem.tagName : elem.tagName.toUpperCase()) == query.getTag())); - }); - } - } - - if(!("classes" in ignores)){ - each(query.classes, function(cname, idx, arr){ - // get the class name - /* - var isWildcard = cname.charAt(cname.length-1) == "*"; - if(isWildcard){ - cname = cname.substr(0, cname.length-1); - } - // I dislike the regex thing, even if memoized in a cache, but it's VERY short - var re = new RegExp("(?:^|\\s)" + cname + (isWildcard ? ".*" : "") + "(?:\\s|$)"); - */ - var re = new RegExp("(?:^|\\s)" + cname + "(?:\\s|$)"); - ff = agree(ff, function(elem){ - return re.test(elem.className); - }); - ff.count = idx; - }); - } - - if(!("pseudos" in ignores)){ - each(query.pseudos, function(pseudo){ - var pn = pseudo.name; - if(pseudos[pn]){ - ff = agree(ff, pseudos[pn](pn, pseudo.value)); - } - }); - } - - if(!("attrs" in ignores)){ - each(query.attrs, function(attr){ - var matcher; - var a = attr.attr; - // type, attr, matchFor - if(attr.type && attrs[attr.type]){ - matcher = attrs[attr.type](a, attr.matchFor); - }else if(a.length){ - matcher = defaultGetter(a); - } - if(matcher){ - ff = agree(ff, matcher); - } - }); - } - - if(!("id" in ignores)){ - if(query.id){ - ff = agree(ff, function(elem){ - return (!!elem && (elem.id == query.id)); - }); - } - } - - if(!ff){ - if(!("default" in ignores)){ - ff = yesman; - } - } - return ff; - }; - - var _nextSibling = function(filterFunc){ - return function(node, ret, bag){ - while(node = node[_ns]){ - if(_noNES && (!_isElement(node))){ continue; } - if( - (!bag || _isUnique(node, bag)) && - filterFunc(node) - ){ - ret.push(node); - } - break; - } - return ret; - }; - }; - - var _nextSiblings = function(filterFunc){ - return function(root, ret, bag){ - var te = root[_ns]; - while(te){ - if(_simpleNodeTest(te)){ - if(bag && !_isUnique(te, bag)){ - break; - } - if(filterFunc(te)){ - ret.push(te); - } - } - te = te[_ns]; - } - return ret; - }; - }; - - // get an array of child *elements*, skipping text and comment nodes - var _childElements = function(filterFunc){ - filterFunc = filterFunc||yesman; - return function(root, ret, bag){ - // get an array of child elements, skipping text and comment nodes - var te, x = 0, tret = root.children || root.childNodes; - while(te = tret[x++]){ - if( - _simpleNodeTest(te) && - (!bag || _isUnique(te, bag)) && - (filterFunc(te, x)) - ){ - ret.push(te); - } - } - return ret; - }; - }; - - // test to see if node is below root - var _isDescendant = function(node, root){ - var pn = node.parentNode; - while(pn){ - if(pn == root){ - break; - } - pn = pn.parentNode; - } - return !!pn; - }; - - var _getElementsFuncCache = {}; - - var getElementsFunc = function(query){ - var retFunc = _getElementsFuncCache[query.query]; - // if we've got a cached dispatcher, just use that - if(retFunc){ return retFunc; } - // else, generate a new on - - // NOTE: - // this function returns a function that searches for nodes and - // filters them. The search may be specialized by infix operators - // (">", "~", or "+") else it will default to searching all - // descendants (the " " selector). Once a group of children is - // found, a test function is applied to weed out the ones we - // don't want. Many common cases can be fast-pathed. We spend a - // lot of cycles to create a dispatcher that doesn't do more work - // than necessary at any point since, unlike this function, the - // dispatchers will be called every time. The logic of generating - // efficient dispatchers looks like this in pseudo code: - // - // # if it's a purely descendant query (no ">", "+", or "~" modifiers) - // if infixOperator == " ": - // if only(id): - // return def(root): - // return d.byId(id, root); - // - // elif id: - // return def(root): - // return filter(d.byId(id, root)); - // - // elif cssClass && getElementsByClassName: - // return def(root): - // return filter(root.getElementsByClassName(cssClass)); - // - // elif only(tag): - // return def(root): - // return root.getElementsByTagName(tagName); - // - // else: - // # search by tag name, then filter - // return def(root): - // return filter(root.getElementsByTagName(tagName||"*")); - // - // elif infixOperator == ">": - // # search direct children - // return def(root): - // return filter(root.children); - // - // elif infixOperator == "+": - // # search next sibling - // return def(root): - // return filter(root.nextElementSibling); - // - // elif infixOperator == "~": - // # search rightward siblings - // return def(root): - // return filter(nextSiblings(root)); - - var io = query.infixOper; - var oper = (io ? io.oper : ""); - // the default filter func which tests for all conditions in the query - // part. This is potentially inefficient, so some optimized paths may - // re-define it to test fewer things. - var filterFunc = getSimpleFilterFunc(query, { el: 1 }); - var qt = query.tag; - var wildcardTag = ("*" == qt); - var ecs = getDoc()["getElementsByClassName"]; - - if(!oper){ - // if there's no infix operator, then it's a descendant query. ID - // and "elements by class name" variants can be accelerated so we - // call them out explicitly: - if(query.id){ - // testing shows that the overhead of yesman() is acceptable - // and can save us some bytes vs. re-defining the function - // everywhere. - filterFunc = (!query.loops && wildcardTag) ? - yesman : - getSimpleFilterFunc(query, { el: 1, id: 1 }); - - retFunc = function(root, arr){ - var te = dom.byId(query.id, (root.ownerDocument||root)); - if(!te || !filterFunc(te)){ return; } - if(9 == root.nodeType){ // if root's a doc, we just return directly - return getArr(te, arr); - }else{ // otherwise check ancestry - if(_isDescendant(te, root)){ - return getArr(te, arr); - } - } - }; - }else if( - ecs && - // isAlien check. Workaround for Prototype.js being totally evil/dumb. - /\{\s*\[native code\]\s*\}/.test(String(ecs)) && - query.classes.length && - !cssCaseBug - ){ - // it's a class-based query and we've got a fast way to run it. - - // ignore class and ID filters since we will have handled both - filterFunc = getSimpleFilterFunc(query, { el: 1, classes: 1, id: 1 }); - var classesString = query.classes.join(" "); - retFunc = function(root, arr, bag){ - var ret = getArr(0, arr), te, x=0; - var tret = root.getElementsByClassName(classesString); - while((te = tret[x++])){ - if(filterFunc(te, root) && _isUnique(te, bag)){ - ret.push(te); - } - } - return ret; - }; - - }else if(!wildcardTag && !query.loops){ - // it's tag only. Fast-path it. - retFunc = function(root, arr, bag){ - var ret = getArr(0, arr), te, x=0; - var tag = query.getTag(), - tret = tag ? root.getElementsByTagName(tag) : []; - while((te = tret[x++])){ - if(_isUnique(te, bag)){ - ret.push(te); - } - } - return ret; - }; - }else{ - // the common case: - // a descendant selector without a fast path. By now it's got - // to have a tag selector, even if it's just "*" so we query - // by that and filter - filterFunc = getSimpleFilterFunc(query, { el: 1, tag: 1, id: 1 }); - retFunc = function(root, arr, bag){ - var ret = getArr(0, arr), te, x=0; - // we use getTag() to avoid case sensitivity issues - var tag = query.getTag(), - tret = tag ? root.getElementsByTagName(tag) : []; - while((te = tret[x++])){ - if(filterFunc(te, root) && _isUnique(te, bag)){ - ret.push(te); - } - } - return ret; - }; - } - }else{ - // the query is scoped in some way. Instead of querying by tag we - // use some other collection to find candidate nodes - var skipFilters = { el: 1 }; - if(wildcardTag){ - skipFilters.tag = 1; - } - filterFunc = getSimpleFilterFunc(query, skipFilters); - if("+" == oper){ - retFunc = _nextSibling(filterFunc); - }else if("~" == oper){ - retFunc = _nextSiblings(filterFunc); - }else if(">" == oper){ - retFunc = _childElements(filterFunc); - } - } - // cache it and return - return _getElementsFuncCache[query.query] = retFunc; - }; - - var filterDown = function(root, queryParts){ - // NOTE: - // this is the guts of the DOM query system. It takes a list of - // parsed query parts and a root and finds children which match - // the selector represented by the parts - var candidates = getArr(root), qp, x, te, qpl = queryParts.length, bag, ret; - - for(var i = 0; i < qpl; i++){ - ret = []; - qp = queryParts[i]; - x = candidates.length - 1; - if(x > 0){ - // if we have more than one root at this level, provide a new - // hash to use for checking group membership but tell the - // system not to post-filter us since we will already have been - // guaranteed to be unique - bag = {}; - ret.nozip = true; - } - var gef = getElementsFunc(qp); - for(var j = 0; (te = candidates[j]); j++){ - // for every root, get the elements that match the descendant - // selector, adding them to the "ret" array and filtering them - // via membership in this level's bag. If there are more query - // parts, then this level's return will be used as the next - // level's candidates - gef(te, ret, bag); - } - if(!ret.length){ break; } - candidates = ret; - } - return ret; - }; - - //////////////////////////////////////////////////////////////////////// - // the query runner - //////////////////////////////////////////////////////////////////////// - - // these are the primary caches for full-query results. The query - // dispatcher functions are generated then stored here for hash lookup in - // the future - var _queryFuncCacheDOM = {}, - _queryFuncCacheQSA = {}; - - // this is the second level of splitting, from full-length queries (e.g., - // "div.foo .bar") into simple query expressions (e.g., ["div.foo", - // ".bar"]) - var getStepQueryFunc = function(query){ - var qparts = getQueryParts(trim(query)); - - // if it's trivial, avoid iteration and zipping costs - if(qparts.length == 1){ - // we optimize this case here to prevent dispatch further down the - // chain, potentially slowing things down. We could more elegantly - // handle this in filterDown(), but it's slower for simple things - // that need to be fast (e.g., "#someId"). - var tef = getElementsFunc(qparts[0]); - return function(root){ - var r = tef(root, []); - if(r){ r.nozip = true; } - return r; - }; - } - - // otherwise, break it up and return a runner that iterates over the parts recursively - return function(root){ - return filterDown(root, qparts); - }; - }; - - // NOTES: - // * we can't trust QSA for anything but document-rooted queries, so - // caching is split into DOM query evaluators and QSA query evaluators - // * caching query results is dirty and leak-prone (or, at a minimum, - // prone to unbounded growth). Other toolkits may go this route, but - // they totally destroy their own ability to manage their memory - // footprint. If we implement it, it should only ever be with a fixed - // total element reference # limit and an LRU-style algorithm since JS - // has no weakref support. Caching compiled query evaluators is also - // potentially problematic, but even on large documents the size of the - // query evaluators is often < 100 function objects per evaluator (and - // LRU can be applied if it's ever shown to be an issue). - // * since IE's QSA support is currently only for HTML documents and even - // then only in IE 8's "standards mode", we have to detect our dispatch - // route at query time and keep 2 separate caches. Ugg. - - // we need to determine if we think we can run a given query via - // querySelectorAll or if we'll need to fall back on DOM queries to get - // there. We need a lot of information about the environment and the query - // to make the determination (e.g. does it support QSA, does the query in - // question work in the native QSA impl, etc.). - - // IE QSA queries may incorrectly include comment nodes, so we throw the - // zipping function into "remove" comments mode instead of the normal "skip - // it" which every other QSA-clued browser enjoys - var noZip = has("ie") ? "commentStrip" : "nozip"; - - var qsa = "querySelectorAll"; - var qsaAvail = !!getDoc()[qsa]; - - //Don't bother with n+3 type of matches, IE complains if we modify those. - var infixSpaceRe = /\\[>~+]|n\+\d|([^ \\])?([>~+])([^ =])?/g; - var infixSpaceFunc = function(match, pre, ch, post){ - return ch ? (pre ? pre + " " : "") + ch + (post ? " " + post : "") : /*n+3*/ match; - }; - - //Don't apply the infixSpaceRe to attribute value selectors - var attRe = /([^[]*)([^\]]*])?/g; - var attFunc = function(match, nonAtt, att){ - return nonAtt.replace(infixSpaceRe, infixSpaceFunc) + (att||""); - }; - var getQueryFunc = function(query, forceDOM){ - //Normalize query. The CSS3 selectors spec allows for omitting spaces around - //infix operators, >, ~ and + - //Do the work here since detection for spaces is used as a simple "not use QSA" - //test below. - query = query.replace(attRe, attFunc); - - if(qsaAvail){ - // if we've got a cached variant and we think we can do it, run it! - var qsaCached = _queryFuncCacheQSA[query]; - if(qsaCached && !forceDOM){ return qsaCached; } - } - - // else if we've got a DOM cached variant, assume that we already know - // all we need to and use it - var domCached = _queryFuncCacheDOM[query]; - if(domCached){ return domCached; } - - // TODO: - // today we're caching DOM and QSA branches separately so we - // recalc useQSA every time. If we had a way to tag root+query - // efficiently, we'd be in good shape to do a global cache. - - var qcz = query.charAt(0); - var nospace = (-1 == query.indexOf(" ")); - - // byId searches are wicked fast compared to QSA, even when filtering - // is required - if( (query.indexOf("#") >= 0) && (nospace) ){ - forceDOM = true; - } - - var useQSA = ( - qsaAvail && (!forceDOM) && - // as per CSS 3, we can't currently start w/ combinator: - // http://www.w3.org/TR/css3-selectors/#w3cselgrammar - (specials.indexOf(qcz) == -1) && - // IE's QSA impl sucks on pseudos - (!has("ie") || (query.indexOf(":") == -1)) && - - (!(cssCaseBug && (query.indexOf(".") >= 0))) && - - // FIXME: - // need to tighten up browser rules on ":contains" and "|=" to - // figure out which aren't good - // Latest webkit (around 531.21.8) does not seem to do well with :checked on option - // elements, even though according to spec, selected options should - // match :checked. So go nonQSA for it: - // http://bugs.dojotoolkit.org/ticket/5179 - (query.indexOf(":contains") == -1) && (query.indexOf(":checked") == -1) && - (query.indexOf("|=") == -1) // some browsers don't grok it - ); - - // TODO: - // if we've got a descendant query (e.g., "> .thinger" instead of - // just ".thinger") in a QSA-able doc, but are passed a child as a - // root, it should be possible to give the item a synthetic ID and - // trivially rewrite the query to the form "#synid > .thinger" to - // use the QSA branch - - - if(useQSA){ - var tq = (specials.indexOf(query.charAt(query.length-1)) >= 0) ? - (query + " *") : query; - return _queryFuncCacheQSA[query] = function(root){ - try{ - // the QSA system contains an egregious spec bug which - // limits us, effectively, to only running QSA queries over - // entire documents. See: - // http://ejohn.org/blog/thoughts-on-queryselectorall/ - // despite this, we can also handle QSA runs on simple - // selectors, but we don't want detection to be expensive - // so we're just checking for the presence of a space char - // right now. Not elegant, but it's cheaper than running - // the query parser when we might not need to - if(!((9 == root.nodeType) || nospace)){ throw ""; } - var r = root[qsa](tq); - // skip expensive duplication checks and just wrap in a NodeList - r[noZip] = true; - return r; - }catch(e){ - // else run the DOM branch on this query, ensuring that we - // default that way in the future - return getQueryFunc(query, true)(root); - } - }; - }else{ - // DOM branch - var parts = query.match(/([^\s,](?:"(?:\\.|[^"])+"|'(?:\\.|[^'])+'|[^,])*)/g); - return _queryFuncCacheDOM[query] = ((parts.length < 2) ? - // if not a compound query (e.g., ".foo, .bar"), cache and return a dispatcher - getStepQueryFunc(query) : - // if it *is* a complex query, break it up into its - // constituent parts and return a dispatcher that will - // merge the parts when run - function(root){ - var pindex = 0, // avoid array alloc for every invocation - ret = [], - tp; - while((tp = parts[pindex++])){ - ret = ret.concat(getStepQueryFunc(tp)(root)); - } - return ret; - } - ); - } - }; - - var _zipIdx = 0; - - // NOTE: - // this function is Moo inspired, but our own impl to deal correctly - // with XML in IE - var _nodeUID = has("ie") ? function(node){ - if(caseSensitive){ - // XML docs don't have uniqueID on their nodes - return (node.getAttribute("_uid") || node.setAttribute("_uid", ++_zipIdx) || _zipIdx); - - }else{ - return node.uniqueID; - } - } : - function(node){ - return (node._uid || (node._uid = ++_zipIdx)); - }; - - // determine if a node in is unique in a "bag". In this case we don't want - // to flatten a list of unique items, but rather just tell if the item in - // question is already in the bag. Normally we'd just use hash lookup to do - // this for us but IE's DOM is busted so we can't really count on that. On - // the upside, it gives us a built in unique ID function. - var _isUnique = function(node, bag){ - if(!bag){ return 1; } - var id = _nodeUID(node); - if(!bag[id]){ return bag[id] = 1; } - return 0; - }; - - // attempt to efficiently determine if an item in a list is a dupe, - // returning a list of "uniques", hopefully in document order - var _zipIdxName = "_zipIdx"; - var _zip = function(arr){ - if(arr && arr.nozip){ return arr; } - - if(!arr || !arr.length){ return []; } - if(arr.length < 2){ return [arr[0]]; } - - var ret = []; - - _zipIdx++; - - // we have to fork here for IE and XML docs because we can't set - // expandos on their nodes (apparently). *sigh* - var x, te; - if(has("ie") && caseSensitive){ - var szidx = _zipIdx+""; - for(x = 0; x < arr.length; x++){ - if((te = arr[x]) && te.getAttribute(_zipIdxName) != szidx){ - ret.push(te); - te.setAttribute(_zipIdxName, szidx); - } - } - }else if(has("ie") && arr.commentStrip){ - try{ - for(x = 0; x < arr.length; x++){ - if((te = arr[x]) && _isElement(te)){ - ret.push(te); - } - } - }catch(e){ /* squelch */ } - }else{ - for(x = 0; x < arr.length; x++){ - if((te = arr[x]) && te[_zipIdxName] != _zipIdx){ - ret.push(te); - te[_zipIdxName] = _zipIdx; - } - } - } - return ret; - }; - - // the main executor - var query = function(/*String*/ query, /*String|DOMNode?*/ root){ - // summary: - // Returns nodes which match the given CSS3 selector, searching the - // entire document by default but optionally taking a node to scope - // the search by. Returns an array. - // description: - // dojo.query() is the swiss army knife of DOM node manipulation in - // Dojo. Much like Prototype's "$$" (bling-bling) function or JQuery's - // "$" function, dojo.query provides robust, high-performance - // CSS-based node selector support with the option of scoping searches - // to a particular sub-tree of a document. - // - // Supported Selectors: - // -------------------- - // - // acme supports a rich set of CSS3 selectors, including: - // - // - class selectors (e.g., `.foo`) - // - node type selectors like `span` - // - ` ` descendant selectors - // - `>` child element selectors - // - `#foo` style ID selectors - // - `*` universal selector - // - `~`, the preceded-by sibling selector - // - `+`, the immediately preceded-by sibling selector - // - attribute queries: - // - `[foo]` attribute presence selector - // - `[foo='bar']` attribute value exact match - // - `[foo~='bar']` attribute value list item match - // - `[foo^='bar']` attribute start match - // - `[foo$='bar']` attribute end match - // - `[foo*='bar']` attribute substring match - // - `:first-child`, `:last-child`, and `:only-child` positional selectors - // - `:empty` content emtpy selector - // - `:checked` pseudo selector - // - `:nth-child(n)`, `:nth-child(2n+1)` style positional calculations - // - `:nth-child(even)`, `:nth-child(odd)` positional selectors - // - `:not(...)` negation pseudo selectors - // - // Any legal combination of these selectors will work with - // `dojo.query()`, including compound selectors ("," delimited). - // Very complex and useful searches can be constructed with this - // palette of selectors and when combined with functions for - // manipulation presented by dojo/NodeList, many types of DOM - // manipulation operations become very straightforward. - // - // Unsupported Selectors: - // ---------------------- - // - // While dojo.query handles many CSS3 selectors, some fall outside of - // what's reasonable for a programmatic node querying engine to - // handle. Currently unsupported selectors include: - // - // - namespace-differentiated selectors of any form - // - all `::` pseduo-element selectors - // - certain pseudo-selectors which don't get a lot of day-to-day use: - // - `:root`, `:lang()`, `:target`, `:focus` - // - all visual and state selectors: - // - `:root`, `:active`, `:hover`, `:visited`, `:link`, - // `:enabled`, `:disabled` - // - `:*-of-type` pseudo selectors - // - // dojo.query and XML Documents: - // ----------------------------- - // - // `dojo.query` (as of dojo 1.2) supports searching XML documents - // in a case-sensitive manner. If an HTML document is served with - // a doctype that forces case-sensitivity (e.g., XHTML 1.1 - // Strict), dojo.query() will detect this and "do the right - // thing". Case sensitivity is dependent upon the document being - // searched and not the query used. It is therefore possible to - // use case-sensitive queries on strict sub-documents (iframes, - // etc.) or XML documents while still assuming case-insensitivity - // for a host/root document. - // - // Non-selector Queries: - // --------------------- - // - // If something other than a String is passed for the query, - // `dojo.query` will return a new `dojo/NodeList` instance - // constructed from that parameter alone and all further - // processing will stop. This means that if you have a reference - // to a node or NodeList, you can quickly construct a new NodeList - // from the original by calling `dojo.query(node)` or - // `dojo.query(list)`. - // - // query: - // The CSS3 expression to match against. For details on the syntax of - // CSS3 selectors, see - // root: - // A DOMNode (or node id) to scope the search from. Optional. - // returns: Array - // example: - // search the entire document for elements with the class "foo": - // | require(["dojo/query"], function(query) { - // | query(".foo").forEach(function(q) { console.log(q); }); - // | }); - // these elements will match: - // | - // | - // |

    - // example: - // search the entire document for elements with the classes "foo" *and* "bar": - // | require(["dojo/query"], function(query) { - // | query(".foo.bar").forEach(function(q) { console.log(q); }); - // | }); - - // these elements will match: - // | - // while these will not: - // | - // |

    - // example: - // find `` elements which are descendants of paragraphs and - // which have a "highlighted" class: - // | require(["dojo/query"], function(query) { - // | query("p span.highlighted").forEach(function(q) { console.log(q); }); - // | }); - // the innermost span in this fragment matches: - // |

    - // | ... - // | ... - // | - // |

    - // example: - // set an "odd" class on all odd table rows inside of the table - // `#tabular_data`, using the `>` (direct child) selector to avoid - // affecting any nested tables: - // | require(["dojo/query"], function(query) { - // | query("#tabular_data > tbody > tr:nth-child(odd)").addClass("odd"); - // | ); - // example: - // remove all elements with the class "error" from the document: - // | require(["dojo/query"], function(query) { - // | query(".error").orphan(); - // | ); - // example: - // add an onclick handler to every submit button in the document - // which causes the form to be sent via Ajax instead: - // | require(["dojo/query", "dojo/request", "dojo/dom-construct", "dojo/dom-style" - // | ], function (query, request, domConstruct, domStyle) { - // | query("input[type='submit']").on("click", function (e) { - // | e.stopPropagation(); - // | e.preventDefault(); - // | var btn = e.target; - // | request.post("", { data: btn.form, timeout: 2000 }) - // | .then(function (data) { - // | // replace the form with the response - // | domConstruct.create("div", { innerHTML: data }, btn.form, "after"); - // | domStyle.set(btn.form, "display", "none"); - // | }); - // | }); - // | }); - - - root = root || getDoc(); - - // throw the big case sensitivity switch - var od = root.ownerDocument || root; // root is either Document or a node inside the document - caseSensitive = (od.createElement("div").tagName === "div"); - - // NOTE: - // adding "true" as the 2nd argument to getQueryFunc is useful for - // testing the DOM branch without worrying about the - // behavior/performance of the QSA branch. - var r = getQueryFunc(query)(root); - - // FIXME: - // need to investigate this branch WRT #8074 and #8075 - if(r && r.nozip){ - return r; - } - return _zip(r); // dojo/NodeList - }; - query.filter = function(/*Node[]*/ nodeList, /*String*/ filter, /*String|DOMNode?*/ root){ - // summary: - // function for filtering a NodeList based on a selector, optimized for simple selectors - var tmpNodeList = [], - parts = getQueryParts(filter), - filterFunc = - (parts.length == 1 && !/[^\w#\.]/.test(filter)) ? - getSimpleFilterFunc(parts[0]) : - function(node){ - return array.indexOf(query(filter, dom.byId(root)), node) != -1; - }; - for(var x = 0, te; te = nodeList[x]; x++){ - if(filterFunc(te)){ tmpNodeList.push(te); } - } - return tmpNodeList; - }; - return query; -}); diff --git a/lib/dojo/selector/lite.js b/lib/dojo/selector/lite.js deleted file mode 100644 index c759dbb..0000000 --- a/lib/dojo/selector/lite.js +++ /dev/null @@ -1,222 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/selector/lite",["../has","../_base/kernel"],function(_1,_2){ -"use strict"; -var _3=document.createElement("div"); -var _4=_3.matches||_3.webkitMatchesSelector||_3.mozMatchesSelector||_3.msMatchesSelector||_3.oMatchesSelector; -var _5=_3.querySelectorAll; -var _6=/([^\s,](?:"(?:\\.|[^"])+"|'(?:\\.|[^'])+'|[^,])*)/g; -_1.add("dom-matches-selector",!!_4); -_1.add("dom-qsa",!!_5); -var _7=function(_8,_9){ -if(_a&&_8.indexOf(",")>-1){ -return _a(_8,_9); -} -var _b=_9?_9.ownerDocument||_9:_2.doc||document,_c=(_5?/^([\w]*)#([\w\-]+$)|^(\.)([\w\-\*]+$)|^(\w+$)/:/^([\w]*)#([\w\-]+)(?:\s+(.*))?$|(?:^|(>|.+\s+))([\w\-\*]+)(\S*$)/).exec(_8); -_9=_9||_b; -if(_c){ -if(_c[2]){ -var _d=_2.byId?_2.byId(_c[2],_b):_b.getElementById(_c[2]); -if(!_d||(_c[1]&&_c[1]!=_d.tagName.toLowerCase())){ -return []; -} -if(_9!=_b){ -var _e=_d; -while(_e!=_9){ -_e=_e.parentNode; -if(!_e){ -return []; -} -} -} -return _c[3]?_7(_c[3],_d):[_d]; -} -if(_c[3]&&_9.getElementsByClassName){ -return _9.getElementsByClassName(_c[4]); -} -var _d; -if(_c[5]){ -_d=_9.getElementsByTagName(_c[5]); -if(_c[4]||_c[6]){ -_8=(_c[4]||"")+_c[6]; -}else{ -return _d; -} -} -} -if(_5){ -if(_9.nodeType===1&&_9.nodeName.toLowerCase()!=="object"){ -return _f(_9,_8,_9.querySelectorAll); -}else{ -return _9.querySelectorAll(_8); -} -}else{ -if(!_d){ -_d=_9.getElementsByTagName("*"); -} -} -var _10=[]; -for(var i=0,l=_d.length;i-1&&(" "+_20.className+" ").indexOf(_1f)>-1; -}; -},"#":function(id){ -return function(_21){ -return _21.id==id; -}; -}}; -var _22={"^=":function(_23,_24){ -return _23.indexOf(_24)==0; -},"*=":function(_25,_26){ -return _25.indexOf(_26)>-1; -},"$=":function(_27,_28){ -return _27.substring(_27.length-_28.length,_27.length)==_28; -},"~=":function(_29,_2a){ -return (" "+_29+" ").indexOf(" "+_2a+" ")>-1; -},"|=":function(_2b,_2c){ -return (_2b+"-").indexOf(_2c+"-")==0; -},"=":function(_2d,_2e){ -return _2d==_2e; -},"":function(_2f,_30){ -return true; -}}; -function _31(_32,_33,_34){ -var _35=_33.charAt(0); -if(_35=="\""||_35=="'"){ -_33=_33.slice(1,-1); -} -_33=_33.replace(/\\/g,""); -var _36=_22[_34||""]; -return function(_37){ -var _38=_37.getAttribute(_32); -return _38&&_36(_38,_33); -}; -}; -function _39(_3a){ -return function(_3b,_3c){ -while((_3b=_3b.parentNode)!=_3c){ -if(_3a(_3b,_3c)){ -return true; -} -} -}; -}; -function _3d(_3e){ -return function(_3f,_40){ -_3f=_3f.parentNode; -return _3e?_3f!=_40&&_3e(_3f,_40):_3f==_40; -}; -}; -var _41={}; -function and(_42,_43){ -return _42?function(_44,_45){ -return _43(_44)&&_42(_44,_45); -}:_43; -}; -return function(_46,_47,_48){ -var _49=_41[_47]; -if(!_49){ -if(_47.replace(/(?:\s*([> ])\s*)|(#|\.)?((?:\\.|[\w-])+)|\[\s*([\w-]+)\s*(.?=)?\s*("(?:\\.|[^"])+"|'(?:\\.|[^'])+'|(?:\\.|[^\]])*)\s*\]/g,function(t,_4a,_4b,_4c,_4d,_4e,_4f){ -if(_4c){ -_49=and(_49,_1b[_4b||""](_4c.replace(/\\/g,""))); -}else{ -if(_4a){ -_49=(_4a==" "?_39:_3d)(_49); -}else{ -if(_4d){ -_49=and(_49,_31(_4d,_4f,_4e)); -} -} -} -return ""; -})){ -throw new Error("Syntax error in query"); -} -if(!_49){ -return true; -} -_41[_47]=_49; -} -return _49(_46,_48); -}; -})(); -} -if(!_1("dom-qsa")){ -var _a=function(_50,_51){ -var _52=_50.match(_6); -var _53=[]; -for(var i=0;i<_52.length;i++){ -_50=new String(_52[i].replace(/\s*$/,"")); -_50.indexOf=escape; -var _54=_7(_50,_51); -for(var j=0,l=_54.length;j -1){ - return combine(selector, root); - } - // use the root's ownerDocument if provided, otherwise try to use dojo.doc. Note - // that we don't use dojo/_base/window's doc to reduce dependencies, and - // fallback to plain document if dojo.doc hasn't been defined (by dojo/_base/window). - // presumably we will have a better way to do this in 2.0 - var doc = root ? root.ownerDocument || root : dojo.doc || document, - match = (querySelectorAll ? - /^([\w]*)#([\w\-]+$)|^(\.)([\w\-\*]+$)|^(\w+$)/ : // this one only matches on simple queries where we can beat qSA with specific methods - /^([\w]*)#([\w\-]+)(?:\s+(.*))?$|(?:^|(>|.+\s+))([\w\-\*]+)(\S*$)/) // this one matches parts of the query that we can use to speed up manual filtering - .exec(selector); - root = root || doc; - if(match){ - // fast path regardless of whether or not querySelectorAll exists - if(match[2]){ - // an #id - // use dojo.byId if available as it fixes the id retrieval in IE, note that we can't use the dojo namespace in 2.0, but if there is a conditional module use, we will use that - var found = dojo.byId ? dojo.byId(match[2], doc) : doc.getElementById(match[2]); - if(!found || (match[1] && match[1] != found.tagName.toLowerCase())){ - // if there is a tag qualifer and it doesn't match, no matches - return []; - } - if(root != doc){ - // there is a root element, make sure we are a child of it - var parent = found; - while(parent != root){ - parent = parent.parentNode; - if(!parent){ - return []; - } - } - } - return match[3] ? - liteEngine(match[3], found) - : [found]; - } - if(match[3] && root.getElementsByClassName){ - // a .class - return root.getElementsByClassName(match[4]); - } - var found; - if(match[5]){ - // a tag - found = root.getElementsByTagName(match[5]); - if(match[4] || match[6]){ - selector = (match[4] || "") + match[6]; - }else{ - // that was the entirety of the query, return results - return found; - } - } - } - if(querySelectorAll){ - // qSA works strangely on Element-rooted queries - // We can work around this by specifying an extra ID on the root - // and working up from there (Thanks to Andrew Dupont for the technique) - // IE 8 doesn't work on object elements - if (root.nodeType === 1 && root.nodeName.toLowerCase() !== "object"){ - return useRoot(root, selector, root.querySelectorAll); - }else{ - // we can use the native qSA - return root.querySelectorAll(selector); - } - }else if(!found){ - // search all children and then filter - found = root.getElementsByTagName("*"); - } - // now we filter the nodes that were found using the matchesSelector - var results = []; - for(var i = 0, l = found.length; i < l; i++){ - var node = found[i]; - if(node.nodeType == 1 && jsMatchesSelector(node, selector, root)){ - // keep the nodes that match the selector - results.push(node); - } - } - return results; -}; -var useRoot = function(context, query, method){ - // this function creates a temporary id so we can do rooted qSA queries, this is taken from sizzle - var oldContext = context, - old = context.getAttribute("id"), - nid = old || "__dojo__", - hasParent = context.parentNode, - relativeHierarchySelector = /^\s*[+~]/.test(query); - - if(relativeHierarchySelector && !hasParent){ - return []; - } - if(!old){ - context.setAttribute("id", nid); - }else{ - nid = nid.replace(/'/g, "\\$&"); - } - if(relativeHierarchySelector && hasParent){ - context = context.parentNode; - } - var selectors = query.match(unionSplit); - for(var i = 0; i < selectors.length; i++){ - selectors[i] = "[id='" + nid + "'] " + selectors[i]; - } - query = selectors.join(","); - - try{ - return method.call(context, query); - }finally{ - if(!old){ - oldContext.removeAttribute("id"); - } - } -}; - -if(!has("dom-matches-selector")){ - var jsMatchesSelector = (function(){ - // a JS implementation of CSS selector matching, first we start with the various handlers - var caseFix = testDiv.tagName == "div" ? "toLowerCase" : "toUpperCase"; - var selectorTypes = { - "": function(tagName){ - tagName = tagName[caseFix](); - return function(node){ - return node.tagName == tagName; - }; - }, - ".": function(className){ - var classNameSpaced = ' ' + className + ' '; - return function(node){ - return node.className.indexOf(className) > -1 && (' ' + node.className + ' ').indexOf(classNameSpaced) > -1; - }; - }, - "#": function(id){ - return function(node){ - return node.id == id; - }; - } - }; - var attrComparators = { - "^=": function(attrValue, value){ - return attrValue.indexOf(value) == 0; - }, - "*=": function(attrValue, value){ - return attrValue.indexOf(value) > -1; - }, - "$=": function(attrValue, value){ - return attrValue.substring(attrValue.length - value.length, attrValue.length) == value; - }, - "~=": function(attrValue, value){ - return (' ' + attrValue + ' ').indexOf(' ' + value + ' ') > -1; - }, - "|=": function(attrValue, value){ - return (attrValue + '-').indexOf(value + '-') == 0; - }, - "=": function(attrValue, value){ - return attrValue == value; - }, - "": function(attrValue, value){ - return true; - } - }; - function attr(name, value, type){ - var firstChar = value.charAt(0); - if(firstChar == '"' || firstChar == "'"){ - // it is quoted, remove the quotes - value = value.slice(1, -1); - } - value = value.replace(/\\/g,''); - var comparator = attrComparators[type || ""]; - return function(node){ - var attrValue = node.getAttribute(name); - return attrValue && comparator(attrValue, value); - }; - } - function ancestor(matcher){ - return function(node, root){ - while((node = node.parentNode) != root){ - if(matcher(node, root)){ - return true; - } - } - }; - } - function parent(matcher){ - return function(node, root){ - node = node.parentNode; - return matcher ? - node != root && matcher(node, root) - : node == root; - }; - } - var cache = {}; - function and(matcher, next){ - return matcher ? - function(node, root){ - return next(node) && matcher(node, root); - } - : next; - } - return function(node, selector, root){ - // this returns true or false based on if the node matches the selector (optionally within the given root) - var matcher = cache[selector]; // check to see if we have created a matcher function for the given selector - if(!matcher){ - // create a matcher function for the given selector - // parse the selectors - if(selector.replace(/(?:\s*([> ])\s*)|(#|\.)?((?:\\.|[\w-])+)|\[\s*([\w-]+)\s*(.?=)?\s*("(?:\\.|[^"])+"|'(?:\\.|[^'])+'|(?:\\.|[^\]])*)\s*\]/g, function(t, combinator, type, value, attrName, attrType, attrValue){ - if(value){ - matcher = and(matcher, selectorTypes[type || ""](value.replace(/\\/g, ''))); - } - else if(combinator){ - matcher = (combinator == " " ? ancestor : parent)(matcher); - } - else if(attrName){ - matcher = and(matcher, attr(attrName, attrValue, attrType)); - } - return ""; - })){ - throw new Error("Syntax error in query"); - } - if(!matcher){ - return true; - } - cache[selector] = matcher; - } - // now run the matcher function on the node - return matcher(node, root); - }; - })(); -} -if(!has("dom-qsa")){ - var combine = function(selector, root){ - // combined queries - var selectors = selector.match(unionSplit); - var indexed = []; - // add all results and keep unique ones, this only runs in IE, so we take advantage - // of known IE features, particularly sourceIndex which is unique and allows us to - // order the results - for(var i = 0; i < selectors.length; i++){ - selector = new String(selectors[i].replace(/\s*$/,'')); - selector.indexOf = escape; // keep it from recursively entering combine - var results = liteEngine(selector, root); - for(var j = 0, l = results.length; j < l; j++){ - var node = results[j]; - indexed[node.sourceIndex] = node; - } - } - // now convert from a sparse array to a dense array - var totalResults = []; - for(i in indexed){ - totalResults.push(indexed[i]); - } - return totalResults; - }; -} - -liteEngine.match = matchesSelector ? function(node, selector, root){ - if(root && root.nodeType != 9){ - // doesn't support three args, use rooted id trick - return useRoot(root, selector, function(query){ - return matchesSelector.call(node, query); - }); - } - // we have a native matchesSelector, use that - return matchesSelector.call(node, selector); -} : jsMatchesSelector; // otherwise use the JS matches impl - -return liteEngine; -}); diff --git a/lib/dojo/sniff.js b/lib/dojo/sniff.js deleted file mode 100644 index ebb907e..0000000 --- a/lib/dojo/sniff.js +++ /dev/null @@ -1,52 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/sniff",["./has"],function(_1){ -if(1){ -var n=navigator,_2=n.userAgent,_3=n.appVersion,tv=parseFloat(_3); -_1.add("air",_2.indexOf("AdobeAIR")>=0); -_1.add("msapp",parseFloat(_2.split("MSAppHost/")[1])||undefined); -_1.add("khtml",_3.indexOf("Konqueror")>=0?tv:undefined); -_1.add("webkit",parseFloat(_2.split("WebKit/")[1])||undefined); -_1.add("chrome",parseFloat(_2.split("Chrome/")[1])||undefined); -_1.add("safari",_3.indexOf("Safari")>=0&&!_1("chrome")?parseFloat(_3.split("Version/")[1]):undefined); -_1.add("mac",_3.indexOf("Macintosh")>=0); -_1.add("quirks",document.compatMode=="BackCompat"); -if(_2.match(/(iPhone|iPod|iPad)/)){ -var p=RegExp.$1.replace(/P/,"p"); -var v=_2.match(/OS ([\d_]+)/)?RegExp.$1:"1"; -var os=parseFloat(v.replace(/_/,".").replace(/_/g,"")); -_1.add(p,os); -_1.add("ios",os); -} -_1.add("android",parseFloat(_2.split("Android ")[1])||undefined); -_1.add("bb",(_2.indexOf("BlackBerry")>=0||_2.indexOf("BB10")>=0)&&parseFloat(_2.split("Version/")[1])||undefined); -_1.add("trident",parseFloat(_3.split("Trident/")[1])||undefined); -_1.add("svg",typeof SVGAngle!=="undefined"); -if(!_1("webkit")){ -if(_2.indexOf("Opera")>=0){ -_1.add("opera",tv>=9.8?parseFloat(_2.split("Version/")[1])||tv:tv); -} -if(_2.indexOf("Gecko")>=0&&!_1("khtml")&&!_1("webkit")&&!_1("trident")){ -_1.add("mozilla",tv); -} -if(_1("mozilla")){ -_1.add("ff",parseFloat(_2.split("Firefox/")[1]||_2.split("Minefield/")[1])||undefined); -} -if(document.all&&!_1("opera")){ -var _4=parseFloat(_3.split("MSIE ")[1])||undefined; -var _5=document.documentMode; -if(_5&&_5!=5&&Math.floor(_4)!=_5){ -_4=_5; -} -_1.add("ie",_4); -} -_1.add("wii",typeof opera!="undefined"&&opera.wiiremote); -} -} -return _1; -}); diff --git a/lib/dojo/sniff.js.uncompressed.js b/lib/dojo/sniff.js.uncompressed.js deleted file mode 100644 index 70e761b..0000000 --- a/lib/dojo/sniff.js.uncompressed.js +++ /dev/null @@ -1,81 +0,0 @@ -define("dojo/sniff", ["./has"], function(has){ - // module: - // dojo/sniff - - /*===== - return function(){ - // summary: - // This module sets has() flags based on the current browser. - // It returns the has() function. - }; - =====*/ - - if( 1 ){ - var n = navigator, - dua = n.userAgent, - dav = n.appVersion, - tv = parseFloat(dav); - - has.add("air", dua.indexOf("AdobeAIR") >= 0); - has.add("msapp", parseFloat(dua.split("MSAppHost/")[1]) || undefined); - has.add("khtml", dav.indexOf("Konqueror") >= 0 ? tv : undefined); - has.add("webkit", parseFloat(dua.split("WebKit/")[1]) || undefined); - has.add("chrome", parseFloat(dua.split("Chrome/")[1]) || undefined); - has.add("safari", dav.indexOf("Safari")>=0 && !has("chrome") ? parseFloat(dav.split("Version/")[1]) : undefined); - has.add("mac", dav.indexOf("Macintosh") >= 0); - has.add("quirks", document.compatMode == "BackCompat"); - if(dua.match(/(iPhone|iPod|iPad)/)){ - var p = RegExp.$1.replace(/P/, "p"); - var v = dua.match(/OS ([\d_]+)/) ? RegExp.$1 : "1"; - var os = parseFloat(v.replace(/_/, ".").replace(/_/g, "")); - has.add(p, os); // "iphone", "ipad" or "ipod" - has.add("ios", os); - } - has.add("android", parseFloat(dua.split("Android ")[1]) || undefined); - has.add("bb", (dua.indexOf("BlackBerry") >= 0 || dua.indexOf("BB10") >= 0) && parseFloat(dua.split("Version/")[1]) || undefined); - has.add("trident", parseFloat(dav.split("Trident/")[1]) || undefined); - - has.add("svg", typeof SVGAngle !== "undefined"); - - if(!has("webkit")){ - // Opera - if(dua.indexOf("Opera") >= 0){ - // see http://dev.opera.com/articles/view/opera-ua-string-changes and http://www.useragentstring.com/pages/Opera/ - // 9.8 has both styles; <9.8, 9.9 only old style - has.add("opera", tv >= 9.8 ? parseFloat(dua.split("Version/")[1]) || tv : tv); - } - - // Mozilla and firefox - if(dua.indexOf("Gecko") >= 0 && !has("khtml") && !has("webkit") && !has("trident")){ - has.add("mozilla", tv); - } - if(has("mozilla")){ - //We really need to get away from this. Consider a sane isGecko approach for the future. - has.add("ff", parseFloat(dua.split("Firefox/")[1] || dua.split("Minefield/")[1]) || undefined); - } - - // IE - if(document.all && !has("opera")){ - var isIE = parseFloat(dav.split("MSIE ")[1]) || undefined; - - //In cases where the page has an HTTP header or META tag with - //X-UA-Compatible, then it is in emulation mode. - //Make sure isIE reflects the desired version. - //document.documentMode of 5 means quirks mode. - //Only switch the value if documentMode's major version - //is different from isIE's major version. - var mode = document.documentMode; - if(mode && mode != 5 && Math.floor(isIE) != mode){ - isIE = mode; - } - - has.add("ie", isIE); - } - - // Wii - has.add("wii", typeof opera != "undefined" && opera.wiiremote); - } - } - - return has; -}); diff --git a/lib/dojo/store/Cache.js b/lib/dojo/store/Cache.js deleted file mode 100644 index 5d0dcaa..0000000 --- a/lib/dojo/store/Cache.js +++ /dev/null @@ -1,49 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/store/Cache",["../_base/lang","../when"],function(_1,_2){ -var _3=function(_4,_5,_6){ -_6=_6||{}; -return _1.delegate(_4,{query:function(_7,_8){ -var _9=_4.query(_7,_8); -_9.forEach(function(_a){ -if(!_6.isLoaded||_6.isLoaded(_a)){ -_5.put(_a); -} -}); -return _9; -},queryEngine:_4.queryEngine||_5.queryEngine,get:function(id,_b){ -return _2(_5.get(id),function(_c){ -return _c||_2(_4.get(id,_b),function(_d){ -if(_d){ -_5.put(_d,{id:id}); -} -return _d; -}); -}); -},add:function(_e,_f){ -return _2(_4.add(_e,_f),function(_10){ -_5.add(_10&&typeof _10=="object"?_10:_e,_f); -return _10; -}); -},put:function(_11,_12){ -_5.remove((_12&&_12.id)||this.getIdentity(_11)); -return _2(_4.put(_11,_12),function(_13){ -_5.put(_13&&typeof _13=="object"?_13:_11,_12); -return _13; -}); -},remove:function(id,_14){ -return _2(_4.remove(id,_14),function(_15){ -return _5.remove(id,_14); -}); -},evict:function(id){ -return _5.remove(id); -}}); -}; -_1.setObject("dojo.store.Cache",_3); -return _3; -}); diff --git a/lib/dojo/store/Cache.js.uncompressed.js b/lib/dojo/store/Cache.js.uncompressed.js deleted file mode 100644 index fcfdba9..0000000 --- a/lib/dojo/store/Cache.js.uncompressed.js +++ /dev/null @@ -1,146 +0,0 @@ -define("dojo/store/Cache", ["../_base/lang","../when" /*=====, "../_base/declare", "./api/Store" =====*/], -function(lang, when /*=====, declare, Store =====*/){ - -// module: -// dojo/store/Cache - -var Cache = function(masterStore, cachingStore, options){ - options = options || {}; - return lang.delegate(masterStore, { - query: function(query, directives){ - var results = masterStore.query(query, directives); - results.forEach(function(object){ - if(!options.isLoaded || options.isLoaded(object)){ - cachingStore.put(object); - } - }); - return results; - }, - // look for a queryEngine in either store - queryEngine: masterStore.queryEngine || cachingStore.queryEngine, - get: function(id, directives){ - return when(cachingStore.get(id), function(result){ - return result || when(masterStore.get(id, directives), function(result){ - if(result){ - cachingStore.put(result, {id: id}); - } - return result; - }); - }); - }, - add: function(object, directives){ - return when(masterStore.add(object, directives), function(result){ - // now put result in cache - cachingStore.add(result && typeof result == "object" ? result : object, directives); - return result; // the result from the add should be dictated by the masterStore and be unaffected by the cachingStore - }); - }, - put: function(object, directives){ - // first remove from the cache, so it is empty until we get a response from the master store - cachingStore.remove((directives && directives.id) || this.getIdentity(object)); - return when(masterStore.put(object, directives), function(result){ - // now put result in cache - cachingStore.put(result && typeof result == "object" ? result : object, directives); - return result; // the result from the put should be dictated by the masterStore and be unaffected by the cachingStore - }); - }, - remove: function(id, directives){ - return when(masterStore.remove(id, directives), function(result){ - return cachingStore.remove(id, directives); - }); - }, - evict: function(id){ - return cachingStore.remove(id); - } - }); -}; -lang.setObject("dojo.store.Cache", Cache); - -/*===== -var __CacheArgs = { - // summary: - // These are additional options for how caching is handled. - // isLoaded: Function? - // This is a function that will be called for each item in a query response to determine - // if it is cacheable. If isLoaded returns true, the item will be cached, otherwise it - // will not be cached. If isLoaded is not provided, all items will be cached. -}; - -Cache = declare(Store, { - // summary: - // The Cache store wrapper takes a master store and a caching store, - // caches data from the master into the caching store for faster - // lookup. Normally one would use a memory store for the caching - // store and a server store like JsonRest for the master store. - // example: - // | var master = new Memory(data); - // | var cacher = new Memory(); - // | var store = new Cache(master, cacher); - // - constructor: function(masterStore, cachingStore, options){ - // masterStore: - // This is the authoritative store, all uncached requests or non-safe requests will - // be made against this store. - // cachingStore: - // This is the caching store that will be used to store responses for quick access. - // Typically this should be a local store. - // options: __CacheArgs? - // These are additional options for how caching is handled. - }, - query: function(query, directives){ - // summary: - // Query the underlying master store and cache any results. - // query: Object|String - // The object or string containing query information. Dependent on the query engine used. - // directives: dojo/store/api/Store.QueryOptions? - // An optional keyword arguments object with additional parameters describing the query. - // returns: dojo/store/api/Store.QueryResults - // A QueryResults object that can be used to iterate over. - }, - get: function(id, directives){ - // summary: - // Get the object with the specific id. - // id: Number - // The identifier for the object in question. - // directives: Object? - // Any additional parameters needed to describe how the get should be performed. - // returns: dojo/store/api/Store.QueryResults - // A QueryResults object. - }, - add: function(object, directives){ - // summary: - // Add the given object to the store. - // object: Object - // The object to add to the store. - // directives: dojo/store/api/Store.AddOptions? - // Any additional parameters needed to describe how the add should be performed. - // returns: Number - // The new id for the object. - }, - put: function(object, directives){ - // summary: - // Put the object into the store (similar to an HTTP PUT). - // object: Object - // The object to put to the store. - // directives: dojo/store/api/Store.PutDirectives? - // Any additional parameters needed to describe how the put should be performed. - // returns: Number - // The new id for the object. - }, - remove: function(id){ - // summary: - // Remove the object with the specific id. - // id: Number - // The identifier for the object in question. - }, - evict: function(id){ - // summary: - // Remove the object with the given id from the underlying caching store. - // id: Number - // The identifier for the object in question. - } -}); -=====*/ - -return Cache; -}); diff --git a/lib/dojo/store/DataStore.js b/lib/dojo/store/DataStore.js deleted file mode 100644 index 3c2ff29..0000000 --- a/lib/dojo/store/DataStore.js +++ /dev/null @@ -1,162 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/store/DataStore",["../_base/lang","../_base/declare","../Deferred","../_base/array","./util/QueryResults","./util/SimpleQueryEngine"],function(_1,_2,_3,_4,_5,_6){ -var _7=null; -return _2("dojo.store.DataStore",_7,{target:"",constructor:function(_8){ -_1.mixin(this,_8); -if(!"idProperty" in _8){ -var _9; -try{ -_9=this.store.getIdentityAttributes(); -} -catch(e){ -} -this.idProperty=(!_9||!idAttributes[0])||this.idProperty; -} -var _a=this.store.getFeatures(); -if(!_a["dojo.data.api.Read"]){ -this.get=null; -} -if(!_a["dojo.data.api.Identity"]){ -this.getIdentity=null; -} -if(!_a["dojo.data.api.Write"]){ -this.put=this.add=null; -} -},idProperty:"id",store:null,queryEngine:_6,_objectConverter:function(_b){ -var _c=this.store; -var _d=this.idProperty; -function _e(_f){ -var _10={}; -var _11=_c.getAttributes(_f); -for(var i=0;i<_11.length;i++){ -var _12=_11[i]; -var _13=_c.getValues(_f,_12); -if(_13.length>1){ -for(var j=0;j<_13.length;j++){ -var _14=_13[j]; -if(typeof _14=="object"&&_c.isItem(_14)){ -_13[j]=_e(_14); -} -} -_14=_13; -}else{ -var _14=_c.getValue(_f,_12); -if(typeof _14=="object"&&_c.isItem(_14)){ -_14=_e(_14); -} -} -_10[_11[i]]=_14; -} -if(!(_d in _10)&&_c.getIdentity){ -_10[_d]=_c.getIdentity(_f); -} -return _10; -}; -return function(_15){ -return _b(_15&&_e(_15)); -}; -},get:function(id,_16){ -var _17,_18; -var _19=new _3(); -this.store.fetchItemByIdentity({identity:id,onItem:this._objectConverter(function(_1a){ -_19.resolve(_17=_1a); -}),onError:function(_1b){ -_19.reject(_18=_1b); -}}); -if(_17!==undefined){ -return _17==null?undefined:_17; -} -if(_18){ -throw _18; -} -return _19.promise; -},put:function(_1c,_1d){ -_1d=_1d||{}; -var id=typeof _1d.id!="undefined"?_1d.id:this.getIdentity(_1c); -var _1e=this.store; -var _1f=this.idProperty; -var _20=new _3(); -if(typeof id=="undefined"){ -_1e.newItem(_1c); -_1e.save({onComplete:function(){ -_20.resolve(_1c); -},onError:function(_21){ -_20.reject(_21); -}}); -}else{ -_1e.fetchItemByIdentity({identity:id,onItem:function(_22){ -if(_22){ -if(_1d.overwrite===false){ -return _20.reject(new Error("Overwriting existing object not allowed")); -} -for(var i in _1c){ -if(i!=_1f&&_1c.hasOwnProperty(i)&&_1e.getValue(_22,i)!=_1c[i]){ -_1e.setValue(_22,i,_1c[i]); -} -} -}else{ -if(_1d.overwrite===true){ -return _20.reject(new Error("Creating new object not allowed")); -} -_1e.newItem(_1c); -} -_1e.save({onComplete:function(){ -_20.resolve(_1c); -},onError:function(_23){ -_20.reject(_23); -}}); -},onError:function(_24){ -_20.reject(_24); -}}); -} -return _20.promise; -},add:function(_25,_26){ -(_26=_26||{}).overwrite=false; -return this.put(_25,_26); -},remove:function(id){ -var _27=this.store; -var _28=new _3(); -this.store.fetchItemByIdentity({identity:id,onItem:function(_29){ -try{ -if(_29==null){ -_28.resolve(false); -}else{ -_27.deleteItem(_29); -_27.save(); -_28.resolve(true); -} -} -catch(error){ -_28.reject(error); -} -},onError:function(_2a){ -_28.reject(_2a); -}}); -return _28.promise; -},query:function(_2b,_2c){ -var _2d; -var _2e=new _3(function(){ -_2d.abort&&_2d.abort(); -}); -_2e.total=new _3(); -var _2f=this._objectConverter(function(_30){ -return _30; -}); -_2d=this.store.fetch(_1.mixin({query:_2b,onBegin:function(_31){ -_2e.total.resolve(_31); -},onComplete:function(_32){ -_2e.resolve(_4.map(_32,_2f)); -},onError:function(_33){ -_2e.reject(_33); -}},_2c)); -return _5(_2e); -},getIdentity:function(_34){ -return _34[this.idProperty]; -}}); -}); diff --git a/lib/dojo/store/DataStore.js.uncompressed.js b/lib/dojo/store/DataStore.js.uncompressed.js deleted file mode 100644 index acb2123..0000000 --- a/lib/dojo/store/DataStore.js.uncompressed.js +++ /dev/null @@ -1,259 +0,0 @@ -define("dojo/store/DataStore", [ - "../_base/lang", "../_base/declare", "../Deferred", "../_base/array", - "./util/QueryResults", "./util/SimpleQueryEngine" /*=====, "./api/Store" =====*/ -], function(lang, declare, Deferred, array, QueryResults, SimpleQueryEngine /*=====, Store =====*/){ - -// module: -// dojo/store/DataStore - - -// No base class, but for purposes of documentation, the base class is dojo/store/api/Store -var base = null; -/*===== base = Store; =====*/ - -return declare("dojo.store.DataStore", base, { - // summary: - // This is an adapter for using Dojo Data stores with an object store consumer. - // You can provide a Dojo data store and use this adapter to interact with it through - // the Dojo object store API - - target: "", - constructor: function(options){ - // options: Object? - // This provides any configuration information that will be mixed into the store, - // including a reference to the Dojo data store under the property "store". - lang.mixin(this, options); - if(!"idProperty" in options){ - var idAttribute; - try{ - idAttribute = this.store.getIdentityAttributes(); - }catch(e){ - // some store are not requiring an item instance to give us the ID attributes - // but some other do and throw errors in that case. - } - // if no idAttribute we have implicit id - this.idProperty = (!idAttribute || !idAttributes[0]) || this.idProperty; - } - var features = this.store.getFeatures(); - // check the feature set and null out any methods that shouldn't be available - if(!features["dojo.data.api.Read"]){ - this.get = null; - } - if(!features["dojo.data.api.Identity"]){ - this.getIdentity = null; - } - if(!features["dojo.data.api.Write"]){ - this.put = this.add = null; - } - }, - // idProperty: String - // The object property to use to store the identity of the store items. - idProperty: "id", - // store: - // The object store to convert to a data store - store: null, - // queryEngine: Function - // Defines the query engine to use for querying the data store - queryEngine: SimpleQueryEngine, - - _objectConverter: function(callback){ - var store = this.store; - var idProperty = this.idProperty; - function convert(item){ - var object = {}; - var attributes = store.getAttributes(item); - for(var i = 0; i < attributes.length; i++){ - var attribute = attributes[i]; - var values = store.getValues(item, attribute); - if(values.length > 1){ - for(var j = 0; j < values.length; j++){ - var value = values[j]; - if(typeof value == 'object' && store.isItem(value)){ - values[j] = convert(value); - } - } - value = values; - }else{ - var value = store.getValue(item, attribute); - if(typeof value == 'object' && store.isItem(value)){ - value = convert(value); - } - } - object[attributes[i]] = value; - } - if(!(idProperty in object) && store.getIdentity){ - object[idProperty] = store.getIdentity(item); - } - return object; - } - return function(item){ - return callback(item && convert(item)); - }; - }, - get: function(id, options){ - // summary: - // Retrieves an object by it's identity. This will trigger a fetchItemByIdentity - // id: Object? - // The identity to use to lookup the object - var returnedObject, returnedError; - var deferred = new Deferred(); - this.store.fetchItemByIdentity({ - identity: id, - onItem: this._objectConverter(function(object){ - deferred.resolve(returnedObject = object); - }), - onError: function(error){ - deferred.reject(returnedError = error); - } - }); - if(returnedObject !== undefined){ - // if it was returned synchronously - return returnedObject == null ? undefined : returnedObject; - } - if(returnedError){ - throw returnedError; - } - return deferred.promise; - }, - put: function(object, options){ - // summary: - // Stores an object by its identity. - // object: Object - // The object to store. - // options: Object? - // Additional metadata for storing the data. Includes a reference to an id - // that the object may be stored with (i.e. { id: "foo" }). - options = options || {}; - var id = typeof options.id != "undefined" ? options.id : this.getIdentity(object); - var store = this.store; - var idProperty = this.idProperty; - var deferred = new Deferred(); - if(typeof id == "undefined"){ - store.newItem(object); - store.save({ - onComplete: function(){ - deferred.resolve(object); - }, - onError: function(error){ - deferred.reject(error); - } - }); - }else{ - store.fetchItemByIdentity({ - identity: id, - onItem: function(item){ - if(item){ - if(options.overwrite === false){ - return deferred.reject(new Error("Overwriting existing object not allowed")); - } - for(var i in object){ - if(i != idProperty && // don't copy id properties since they are immutable and should be omitted for implicit ids - object.hasOwnProperty(i) && // don't want to copy methods and inherited properties - store.getValue(item, i) != object[i]){ - store.setValue(item, i, object[i]); - } - } - }else{ - if(options.overwrite === true){ - return deferred.reject(new Error("Creating new object not allowed")); - } - store.newItem(object); - } - store.save({ - onComplete: function(){ - deferred.resolve(object); - }, - onError: function(error){ - deferred.reject(error); - } - }); - }, - onError: function(error){ - deferred.reject(error); - } - }); - } - return deferred.promise; - }, - add: function(object, options){ - // summary: - // Creates an object, throws an error if the object already exists - // object: Object - // The object to store. - // options: dojo/store/api/Store.PutDirectives? - // Additional metadata for storing the data. Includes an "id" - // property if a specific id is to be used. - // returns: Number - (options = options || {}).overwrite = false; - // call put with overwrite being false - return this.put(object, options); - }, - remove: function(id){ - // summary: - // Deletes an object by its identity. - // id: Object - // The identity to use to delete the object - var store = this.store; - var deferred = new Deferred(); - - this.store.fetchItemByIdentity({ - identity: id, - onItem: function(item){ - try{ - if(item == null){ - // no item found, return false - deferred.resolve(false); - }else{ - // delete and save the change - store.deleteItem(item); - store.save(); - deferred.resolve(true); - } - }catch(error){ - deferred.reject(error); - } - }, - onError: function(error){ - deferred.reject(error); - } - }); - return deferred.promise; - }, - query: function(query, options){ - // summary: - // Queries the store for objects. - // query: Object - // The query to use for retrieving objects from the store - // options: Object? - // Optional options object as used by the underlying dojo.data Store. - // returns: dojo/store/api/Store.QueryResults - // A query results object that can be used to iterate over results. - var fetchHandle; - var deferred = new Deferred(function(){ fetchHandle.abort && fetchHandle.abort(); }); - deferred.total = new Deferred(); - var converter = this._objectConverter(function(object){return object;}); - fetchHandle = this.store.fetch(lang.mixin({ - query: query, - onBegin: function(count){ - deferred.total.resolve(count); - }, - onComplete: function(results){ - deferred.resolve(array.map(results, converter)); - }, - onError: function(error){ - deferred.reject(error); - } - }, options)); - return QueryResults(deferred); - }, - getIdentity: function(object){ - // summary: - // Fetch the identity for the given object. - // object: Object - // The data object to get the identity from. - // returns: Number - // The id of the given object. - return object[this.idProperty]; - } -}); -}); diff --git a/lib/dojo/store/JsonRest.js b/lib/dojo/store/JsonRest.js deleted file mode 100644 index 9cda83f..0000000 --- a/lib/dojo/store/JsonRest.js +++ /dev/null @@ -1,79 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/store/JsonRest",["../_base/xhr","../_base/lang","../json","../_base/declare","./util/QueryResults"],function(_1,_2,_3,_4,_5){ -var _6=null; -return _4("dojo.store.JsonRest",_6,{constructor:function(_7){ -this.headers={}; -_4.safeMixin(this,_7); -},headers:{},target:"",idProperty:"id",ascendingPrefix:"+",descendingPrefix:"-",_getTarget:function(id){ -var _8=this.target; -if(typeof id!="undefined"){ -if(_8.charAt(_8.length-1)=="/"){ -_8+=id; -}else{ -_8+="/"+id; -} -} -return _8; -},get:function(id,_9){ -_9=_9||{}; -var _a=_2.mixin({Accept:this.accepts},this.headers,_9.headers||_9); -return _1("GET",{url:this._getTarget(id),handleAs:"json",headers:_a}); -},accepts:"application/javascript, application/json",getIdentity:function(_b){ -return _b[this.idProperty]; -},put:function(_c,_d){ -_d=_d||{}; -var id=("id" in _d)?_d.id:this.getIdentity(_c); -var _e=typeof id!="undefined"; -return _1(_e&&!_d.incremental?"PUT":"POST",{url:this._getTarget(id),postData:_3.stringify(_c),handleAs:"json",headers:_2.mixin({"Content-Type":"application/json",Accept:this.accepts,"If-Match":_d.overwrite===true?"*":null,"If-None-Match":_d.overwrite===false?"*":null},this.headers,_d.headers)}); -},add:function(_f,_10){ -_10=_10||{}; -_10.overwrite=false; -return this.put(_f,_10); -},remove:function(id,_11){ -_11=_11||{}; -return _1("DELETE",{url:this._getTarget(id),headers:_2.mixin({},this.headers,_11.headers)}); -},query:function(_12,_13){ -_13=_13||{}; -var _14=_2.mixin({Accept:this.accepts},this.headers,_13.headers); -var _15=this.target.indexOf("?")>-1; -if(_12&&typeof _12=="object"){ -_12=_1.objectToQuery(_12); -_12=_12?(_15?"&":"?")+_12:""; -} -if(_13.start>=0||_13.count>=0){ -_14["X-Range"]="items="+(_13.start||"0")+"-"+(("count" in _13&&_13.count!=Infinity)?(_13.count+(_13.start||0)-1):""); -if(this.rangeParam){ -_12+=(_12||_15?"&":"?")+this.rangeParam+"="+_14["X-Range"]; -_15=true; -}else{ -_14.Range=_14["X-Range"]; -} -} -if(_13&&_13.sort){ -var _16=this.sortParam; -_12+=(_12||_15?"&":"?")+(_16?_16+"=":"sort("); -for(var i=0;i<_13.sort.length;i++){ -var _17=_13.sort[i]; -_12+=(i>0?",":"")+(_17.descending?this.descendingPrefix:this.ascendingPrefix)+encodeURIComponent(_17.attribute); -} -if(!_16){ -_12+=")"; -} -} -var _18=_1("GET",{url:this.target+(_12||""),handleAs:"json",headers:_14}); -_18.total=_18.then(function(){ -var _19=_18.ioArgs.xhr.getResponseHeader("Content-Range"); -if(!_19){ -_19=_18.ioArgs.xhr.getResponseHeader("X-Content-Range"); -} -return _19&&(_19=_19.match(/\/(.*)/))&&+_19[1]; -}); -return _5(_18); -}}); -}); diff --git a/lib/dojo/store/JsonRest.js.uncompressed.js b/lib/dojo/store/JsonRest.js.uncompressed.js deleted file mode 100644 index f19b21d..0000000 --- a/lib/dojo/store/JsonRest.js.uncompressed.js +++ /dev/null @@ -1,226 +0,0 @@ -define("dojo/store/JsonRest", ["../_base/xhr", "../_base/lang", "../json", "../_base/declare", "./util/QueryResults" /*=====, "./api/Store" =====*/ -], function(xhr, lang, JSON, declare, QueryResults /*=====, Store =====*/){ - -// No base class, but for purposes of documentation, the base class is dojo/store/api/Store -var base = null; -/*===== base = Store; =====*/ - -/*===== -var __HeaderOptions = { - // headers: Object? - // Additional headers to send along with the request. - }, - __PutDirectives = declare(Store.PutDirectives, __HeaderOptions), - __QueryOptions = declare(Store.QueryOptions, __HeaderOptions); -=====*/ - -return declare("dojo.store.JsonRest", base, { - // summary: - // This is a basic store for RESTful communicating with a server through JSON - // formatted data. It implements dojo/store/api/Store. - - constructor: function(options){ - // summary: - // This is a basic store for RESTful communicating with a server through JSON - // formatted data. - // options: dojo/store/JsonRest - // This provides any configuration information that will be mixed into the store - this.headers = {}; - declare.safeMixin(this, options); - }, - - // headers: Object - // Additional headers to pass in all requests to the server. These can be overridden - // by passing additional headers to calls to the store. - headers: {}, - - // target: String - // The target base URL to use for all requests to the server. This string will be - // prepended to the id to generate the URL (relative or absolute) for requests - // sent to the server - target: "", - - // idProperty: String - // Indicates the property to use as the identity property. The values of this - // property should be unique. - idProperty: "id", - - // rangeParam: String - // Use a query parameter for the requested range. If this is omitted, than the - // Range header will be used. Independent of this, the X-Range header is always set. - - // sortParam: String - // The query parameter to used for holding sort information. If this is omitted, than - // the sort information is included in a functional query token to avoid colliding - // with the set of name/value pairs. - - // ascendingPrefix: String - // The prefix to apply to sort attribute names that are ascending - ascendingPrefix: "+", - - // descendingPrefix: String - // The prefix to apply to sort attribute names that are ascending - descendingPrefix: "-", - - _getTarget: function(id){ - // summary: - // If the target has no trailing '/', then append it. - // id: Number - // The identity of the requested target - var target = this.target; - if(typeof id != "undefined"){ - if(target.charAt(target.length-1) == '/'){ - target += id; - }else{ - target += '/' + id; - } - } - return target; - }, - - get: function(id, options){ - // summary: - // Retrieves an object by its identity. This will trigger a GET request to the server using - // the url `this.target + id`. - // id: Number - // The identity to use to lookup the object - // options: Object? - // HTTP headers. For consistency with other methods, if a `headers` key exists on this object, it will be - // used to provide HTTP headers instead. - // returns: Object - // The object in the store that matches the given id. - options = options || {}; - var headers = lang.mixin({ Accept: this.accepts }, this.headers, options.headers || options); - return xhr("GET", { - url: this._getTarget(id), - handleAs: "json", - headers: headers - }); - }, - - // accepts: String - // Defines the Accept header to use on HTTP requests - accepts: "application/javascript, application/json", - - getIdentity: function(object){ - // summary: - // Returns an object's identity - // object: Object - // The object to get the identity from - // returns: Number - return object[this.idProperty]; - }, - - put: function(object, options){ - // summary: - // Stores an object. This will trigger a PUT request to the server - // if the object has an id, otherwise it will trigger a POST request. - // object: Object - // The object to store. - // options: __PutDirectives? - // Additional metadata for storing the data. Includes an "id" - // property if a specific id is to be used. - // returns: dojo/_base/Deferred - options = options || {}; - var id = ("id" in options) ? options.id : this.getIdentity(object); - var hasId = typeof id != "undefined"; - return xhr(hasId && !options.incremental ? "PUT" : "POST", { - url: this._getTarget(id), - postData: JSON.stringify(object), - handleAs: "json", - headers: lang.mixin({ - "Content-Type": "application/json", - Accept: this.accepts, - "If-Match": options.overwrite === true ? "*" : null, - "If-None-Match": options.overwrite === false ? "*" : null - }, this.headers, options.headers) - }); - }, - - add: function(object, options){ - // summary: - // Adds an object. This will trigger a PUT request to the server - // if the object has an id, otherwise it will trigger a POST request. - // object: Object - // The object to store. - // options: __PutDirectives? - // Additional metadata for storing the data. Includes an "id" - // property if a specific id is to be used. - options = options || {}; - options.overwrite = false; - return this.put(object, options); - }, - - remove: function(id, options){ - // summary: - // Deletes an object by its identity. This will trigger a DELETE request to the server. - // id: Number - // The identity to use to delete the object - // options: __HeaderOptions? - // HTTP headers. - options = options || {}; - return xhr("DELETE", { - url: this._getTarget(id), - headers: lang.mixin({}, this.headers, options.headers) - }); - }, - - query: function(query, options){ - // summary: - // Queries the store for objects. This will trigger a GET request to the server, with the - // query added as a query string. - // query: Object - // The query to use for retrieving objects from the store. - // options: __QueryOptions? - // The optional arguments to apply to the resultset. - // returns: dojo/store/api/Store.QueryResults - // The results of the query, extended with iterative methods. - options = options || {}; - - var headers = lang.mixin({ Accept: this.accepts }, this.headers, options.headers); - - var hasQuestionMark = this.target.indexOf("?") > -1; - if(query && typeof query == "object"){ - query = xhr.objectToQuery(query); - query = query ? (hasQuestionMark ? "&" : "?") + query: ""; - } - if(options.start >= 0 || options.count >= 0){ - headers["X-Range"] = "items=" + (options.start || '0') + '-' + - (("count" in options && options.count != Infinity) ? - (options.count + (options.start || 0) - 1) : ''); - if(this.rangeParam){ - query += (query || hasQuestionMark ? "&" : "?") + this.rangeParam + "=" + headers["X-Range"]; - hasQuestionMark = true; - }else{ - headers.Range = headers["X-Range"]; - } - } - if(options && options.sort){ - var sortParam = this.sortParam; - query += (query || hasQuestionMark ? "&" : "?") + (sortParam ? sortParam + '=' : "sort("); - for(var i = 0; i 0 ? "," : "") + (sort.descending ? this.descendingPrefix : this.ascendingPrefix) + encodeURIComponent(sort.attribute); - } - if(!sortParam){ - query += ")"; - } - } - var results = xhr("GET", { - url: this.target + (query || ""), - handleAs: "json", - headers: headers - }); - results.total = results.then(function(){ - var range = results.ioArgs.xhr.getResponseHeader("Content-Range"); - if (!range){ - // At least Chrome drops the Content-Range header from cached replies. - range = results.ioArgs.xhr.getResponseHeader("X-Content-Range"); - } - return range && (range = range.match(/\/(.*)/)) && +range[1]; - }); - return QueryResults(results); - } -}); - -}); \ No newline at end of file diff --git a/lib/dojo/store/Memory.js b/lib/dojo/store/Memory.js deleted file mode 100644 index d86a463..0000000 --- a/lib/dojo/store/Memory.js +++ /dev/null @@ -1,56 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/store/Memory",["../_base/declare","./util/QueryResults","./util/SimpleQueryEngine"],function(_1,_2,_3){ -var _4=null; -return _1("dojo.store.Memory",_4,{constructor:function(_5){ -for(var i in _5){ -this[i]=_5[i]; -} -this.setData(this.data||[]); -},data:null,idProperty:"id",index:null,queryEngine:_3,get:function(id){ -return this.data[this.index[id]]; -},getIdentity:function(_6){ -return _6[this.idProperty]; -},put:function(_7,_8){ -var _9=this.data,_a=this.index,_b=this.idProperty; -var id=_7[_b]=(_8&&"id" in _8)?_8.id:_b in _7?_7[_b]:Math.random(); -if(id in _a){ -if(_8&&_8.overwrite===false){ -throw new Error("Object already exists"); -} -_9[_a[id]]=_7; -}else{ -_a[id]=_9.push(_7)-1; -} -return id; -},add:function(_c,_d){ -(_d=_d||{}).overwrite=false; -return this.put(_c,_d); -},remove:function(id){ -var _e=this.index; -var _f=this.data; -if(id in _e){ -_f.splice(_e[id],1); -this.setData(_f); -return true; -} -},query:function(_10,_11){ -return _2(this.queryEngine(_10,_11)(this.data)); -},setData:function(_12){ -if(_12.items){ -this.idProperty=_12.identifier||this.idProperty; -_12=this.data=_12.items; -}else{ -this.data=_12; -} -this.index={}; -for(var i=0,l=_12.length;i= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/store/Observable",["../_base/kernel","../_base/lang","../when","../_base/array"],function(_1,_2,_3,_4){ -var _5=function(_6){ -var _7,_8=[],_9=0; -_6=_2.delegate(_6); -_6.notify=function(_a,_b){ -_9++; -var _c=_8.slice(); -for(var i=0,l=_c.length;i-1?_1d:_1a.length; -_1a.splice(_20,0,_18); -_1e=_4.indexOf(_12(_1a),_18); -_1a.splice(_20,1); -if((_f.start&&_1e==0)||(!_1b&&_1e==_1a.length)){ -_1e=-1; -}else{ -_1a.splice(_1e,0,_18); -} -} -}else{ -if(_18){ -if(_19!==_7){ -_1e=_1d; -}else{ -if(!_f.start){ -_1e=_6.defaultIndex||0; -_1a.splice(_1e,0,_18); -} -} -} -} -if((_1d>-1||_1e>-1)&&(_17||!_12||(_1d!=_1e))){ -var _21=_14.slice(); -for(i=0;_16=_21[i];i++){ -_16(_18||_1c,_1d,_1e); -} -} -}); -}); -} -var _22={}; -_22.remove=_22.cancel=function(){ -var _23=_4.indexOf(_14,_16); -if(_23>-1){ -_14.splice(_23,1); -if(!_14.length){ -_8.splice(_4.indexOf(_8,_15),1); -} -} -}; -return _22; -}; -} -return _10; -}; -var _24; -function _25(_26,_27){ -var _28=_6[_26]; -if(_28){ -_6[_26]=function(_29){ -var _2a; -if(_26==="put"){ -_2a=_6.getIdentity(_29); -} -if(_24){ -return _28.apply(this,arguments); -} -_24=true; -try{ -var _2b=_28.apply(this,arguments); -_3(_2b,function(_2c){ -_27((typeof _2c=="object"&&_2c)||_29,_2a); -}); -return _2b; -} -finally{ -_24=false; -} -}; -} -}; -_25("put",function(_2d,_2e){ -_6.notify(_2d,_2e); -}); -_25("add",function(_2f){ -_6.notify(_2f); -}); -_25("remove",function(id){ -_6.notify(undefined,id); -}); -return _6; -}; -_2.setObject("dojo.store.Observable",_5); -return _5; -}); diff --git a/lib/dojo/store/Observable.js.uncompressed.js b/lib/dojo/store/Observable.js.uncompressed.js deleted file mode 100644 index 84bf29f..0000000 --- a/lib/dojo/store/Observable.js.uncompressed.js +++ /dev/null @@ -1,191 +0,0 @@ -define("dojo/store/Observable", ["../_base/kernel", "../_base/lang", "../when", "../_base/array" /*=====, "./api/Store" =====*/ -], function(kernel, lang, when, array /*=====, Store =====*/){ - -// module: -// dojo/store/Observable - -var Observable = function(/*Store*/ store){ - // summary: - // The Observable store wrapper takes a store and sets an observe method on query() - // results that can be used to monitor results for changes. - // - // description: - // Observable wraps an existing store so that notifications can be made when a query - // is performed. - // - // example: - // Create a Memory store that returns an observable query, and then log some - // information about that query. - // - // | var store = Observable(new Memory({ - // | data: [ - // | {id: 1, name: "one", prime: false}, - // | {id: 2, name: "two", even: true, prime: true}, - // | {id: 3, name: "three", prime: true}, - // | {id: 4, name: "four", even: true, prime: false}, - // | {id: 5, name: "five", prime: true} - // | ] - // | })); - // | var changes = [], results = store.query({ prime: true }); - // | var observer = results.observe(function(object, previousIndex, newIndex){ - // | changes.push({previousIndex:previousIndex, newIndex:newIndex, object:object}); - // | }); - // - // See the Observable tests for more information. - - var undef, queryUpdaters = [], revision = 0; - // a Comet driven store could directly call notify to notify observers when data has - // changed on the backend - // create a new instance - store = lang.delegate(store); - - store.notify = function(object, existingId){ - revision++; - var updaters = queryUpdaters.slice(); - for(var i = 0, l = updaters.length; i < l; i++){ - updaters[i](object, existingId); - } - }; - var originalQuery = store.query; - store.query = function(query, options){ - options = options || {}; - var results = originalQuery.apply(this, arguments); - if(results && results.forEach){ - var nonPagedOptions = lang.mixin({}, options); - delete nonPagedOptions.start; - delete nonPagedOptions.count; - - var queryExecutor = store.queryEngine && store.queryEngine(query, nonPagedOptions); - var queryRevision = revision; - var listeners = [], queryUpdater; - results.observe = function(listener, includeObjectUpdates){ - if(listeners.push(listener) == 1){ - // first listener was added, create the query checker and updater - queryUpdaters.push(queryUpdater = function(changed, existingId){ - when(results, function(resultsArray){ - var atEnd = resultsArray.length != options.count; - var i, l, listener; - if(++queryRevision != revision){ - throw new Error("Query is out of date, you must observe() the query prior to any data modifications"); - } - var removedObject, removedFrom = -1, insertedInto = -1; - if(existingId !== undef){ - // remove the old one - for(i = 0, l = resultsArray.length; i < l; i++){ - var object = resultsArray[i]; - if(store.getIdentity(object) == existingId){ - removedObject = object; - removedFrom = i; - if(queryExecutor || !changed){// if it was changed and we don't have a queryExecutor, we shouldn't remove it because updated objects would be eliminated - resultsArray.splice(i, 1); - } - break; - } - } - } - if(queryExecutor){ - // add the new one - if(changed && - // if a matches function exists, use that (probably more efficient) - (queryExecutor.matches ? queryExecutor.matches(changed) : queryExecutor([changed]).length)){ - - var firstInsertedInto = removedFrom > -1 ? - removedFrom : // put back in the original slot so it doesn't move unless it needs to (relying on a stable sort below) - resultsArray.length; - resultsArray.splice(firstInsertedInto, 0, changed); // add the new item - insertedInto = array.indexOf(queryExecutor(resultsArray), changed); // sort it - // we now need to push the change back into the original results array - resultsArray.splice(firstInsertedInto, 1); // remove the inserted item from the previous index - - if((options.start && insertedInto == 0) || - (!atEnd && insertedInto == resultsArray.length)){ - // if it is at the end of the page, assume it goes into the prev or next page - insertedInto = -1; - }else{ - resultsArray.splice(insertedInto, 0, changed); // and insert into the results array with the correct index - } - } - }else if(changed){ - // we don't have a queryEngine, so we can't provide any information - // about where it was inserted or moved to. If it is an update, we leave it's position alone, other we at least indicate a new object - if(existingId !== undef){ - // an update, keep the index the same - insertedInto = removedFrom; - }else if(!options.start){ - // a new object - insertedInto = store.defaultIndex || 0; - resultsArray.splice(insertedInto, 0, changed); - } - } - if((removedFrom > -1 || insertedInto > -1) && - (includeObjectUpdates || !queryExecutor || (removedFrom != insertedInto))){ - var copyListeners = listeners.slice(); - for(i = 0;listener = copyListeners[i]; i++){ - listener(changed || removedObject, removedFrom, insertedInto); - } - } - }); - }); - } - var handle = {}; - // TODO: Remove cancel in 2.0. - handle.remove = handle.cancel = function(){ - // remove this listener - var index = array.indexOf(listeners, listener); - if(index > -1){ // check to make sure we haven't already called cancel - listeners.splice(index, 1); - if(!listeners.length){ - // no more listeners, remove the query updater too - queryUpdaters.splice(array.indexOf(queryUpdaters, queryUpdater), 1); - } - } - }; - return handle; - }; - } - return results; - }; - var inMethod; - function whenFinished(method, action){ - var original = store[method]; - if(original){ - store[method] = function(value){ - var originalId; - if(method === 'put'){ - originalId = store.getIdentity(value); - } - if(inMethod){ - // if one method calls another (like add() calling put()) we don't want two events - return original.apply(this, arguments); - } - inMethod = true; - try{ - var results = original.apply(this, arguments); - when(results, function(results){ - action((typeof results == "object" && results) || value, originalId); - }); - return results; - }finally{ - inMethod = false; - } - }; - } - } - // monitor for updates by listening to these methods - whenFinished("put", function(object, originalId){ - store.notify(object, originalId); - }); - whenFinished("add", function(object){ - store.notify(object); - }); - whenFinished("remove", function(id){ - store.notify(undefined, id); - }); - - return store; -}; - -lang.setObject("dojo.store.Observable", Observable); - -return Observable; -}); diff --git a/lib/dojo/store/README b/lib/dojo/store/README deleted file mode 100644 index 4fb5ac7..0000000 --- a/lib/dojo/store/README +++ /dev/null @@ -1,6 +0,0 @@ -This folder contains the stores and utilities implementing the Dojo Object Store API, -a successor and unifier to Dojo Data, Dojo Storage, and potentially Dojo Model. These -stores are designed to provide simple lightweight implementations -providing core functionality for typical applications. - -See http://dojotoolkit.org/features/1.6/object-store for more information \ No newline at end of file diff --git a/lib/dojo/store/api/Store.js b/lib/dojo/store/api/Store.js deleted file mode 100644 index d50a17a..0000000 --- a/lib/dojo/store/api/Store.js +++ /dev/null @@ -1,40 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/store/api/Store",["../../_base/declare"],function(_1){ -var _2=_1(null,{idProperty:"id",queryEngine:null,get:function(id){ -},getIdentity:function(_3){ -},put:function(_4,_5){ -},add:function(_6,_7){ -},remove:function(id){ -delete this.index[id]; -var _8=this.data,_9=this.idProperty; -for(var i=0,l=_8.length;i filtered array - // The returned query function may have a "matches" property that can be - // used to determine if an object matches the query. For example: - // | query.matches({id:"some-object", foo:"bar"}) -> true - // | query.matches({id:"some-object", foo:"something else"}) -> false - queryEngine: null, - - get: function(id){ - // summary: - // Retrieves an object by its identity - // id: Number - // The identity to use to lookup the object - // returns: Object - // The object in the store that matches the given id. - }, - getIdentity: function(object){ - // summary: - // Returns an object's identity - // object: Object - // The object to get the identity from - // returns: String|Number - }, - put: function(object, directives){ - // summary: - // Stores an object - // object: Object - // The object to store. - // directives: dojo/store/api/Store.PutDirectives? - // Additional directives for storing objects. - // returns: Number|String - }, - add: function(object, directives){ - // summary: - // Creates an object, throws an error if the object already exists - // object: Object - // The object to store. - // directives: dojo/store/api/Store.PutDirectives? - // Additional directives for creating objects. - // returns: Number|String - }, - remove: function(id){ - // summary: - // Deletes an object by its identity - // id: Number - // The identity to use to delete the object - delete this.index[id]; - var data = this.data, - idProperty = this.idProperty; - for(var i = 0, l = data.length; i < l; i++){ - if(data[i][idProperty] == id){ - data.splice(i, 1); - return; - } - } - }, - query: function(query, options){ - // summary: - // Queries the store for objects. This does not alter the store, but returns a - // set of data from the store. - // query: String|Object|Function - // The query to use for retrieving objects from the store. - // options: dojo/store/api/Store.QueryOptions - // The optional arguments to apply to the resultset. - // returns: dojo/store/api/Store.QueryResults - // The results of the query, extended with iterative methods. - // - // example: - // Given the following store: - // - // ...find all items where "prime" is true: - // - // | store.query({ prime: true }).forEach(function(object){ - // | // handle each object - // | }); - }, - transaction: function(){ - // summary: - // Starts a new transaction. - // Note that a store user might not call transaction() prior to using put, - // delete, etc. in which case these operations effectively could be thought of - // as "auto-commit" style actions. - // returns: dojo/store/api/Store.Transaction - // This represents the new current transaction. - }, - getChildren: function(parent, options){ - // summary: - // Retrieves the children of an object. - // parent: Object - // The object to find the children of. - // options: dojo/store/api/Store.QueryOptions? - // Additional options to apply to the retrieval of the children. - // returns: dojo/store/api/Store.QueryResults - // A result set of the children of the parent object. - }, - getMetadata: function(object){ - // summary: - // Returns any metadata about the object. This may include attribution, - // cache directives, history, or version information. - // object: Object - // The object to return metadata for. - // returns: Object - // An object containing metadata. - } -}); - -Store.PutDirectives = declare(null, { - // summary: - // Directives passed to put() and add() handlers for guiding the update and - // creation of stored objects. - // id: String|Number? - // Indicates the identity of the object if a new object is created - // before: Object? - // If the collection of objects in the store has a natural ordering, - // this indicates that the created or updated object should be placed before the - // object specified by the value of this property. A value of null indicates that the - // object should be last. - // parent: Object?, - // If the store is hierarchical (with single parenting) this property indicates the - // new parent of the created or updated object. - // overwrite: Boolean? - // If this is provided as a boolean it indicates that the object should or should not - // overwrite an existing object. A value of true indicates that a new object - // should not be created, the operation should update an existing object. A - // value of false indicates that an existing object should not be updated, a new - // object should be created (which is the same as an add() operation). When - // this property is not provided, either an update or creation is acceptable. -}); - -Store.SortInformation = declare(null, { - // summary: - // An object describing what attribute to sort on, and the direction of the sort. - // attribute: String - // The name of the attribute to sort on. - // descending: Boolean - // The direction of the sort. Default is false. -}); - -Store.QueryOptions = declare(null, { - // summary: - // Optional object with additional parameters for query results. - // sort: dojo/store/api/Store.SortInformation[]? - // A list of attributes to sort on, as well as direction - // For example: - // | [{attribute:"price, descending: true}]. - // If the sort parameter is omitted, then the natural order of the store may be - // applied if there is a natural order. - // start: Number? - // The first result to begin iteration on - // count: Number? - // The number of how many results should be returned. -}); - -Store.QueryResults = declare(null, { - // summary: - // This is an object returned from query() calls that provides access to the results - // of a query. Queries may be executed asynchronously. - - forEach: function(callback, thisObject){ - // summary: - // Iterates over the query results, based on - // https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Objects/Array/forEach. - // Note that this may executed asynchronously. The callback may be called - // after this function returns. - // callback: - // Function that is called for each object in the query results - // thisObject: - // The object to use as |this| in the callback. - - }, - filter: function(callback, thisObject){ - // summary: - // Filters the query results, based on - // https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Objects/Array/filter. - // Note that this may executed asynchronously. The callback may be called - // after this function returns. - // callback: - // Function that is called for each object in the query results - // thisObject: - // The object to use as |this| in the callback. - // returns: dojo/store/api/Store.QueryResults - }, - map: function(callback, thisObject){ - // summary: - // Maps the query results, based on - // https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Objects/Array/map. - // Note that this may executed asynchronously. The callback may be called - // after this function returns. - // callback: - // Function that is called for each object in the query results - // thisObject: - // The object to use as |this| in the callback. - // returns: dojo/store/api/Store.QueryResults - }, - then: function(callback, errorHandler){ - // summary: - // This registers a callback for when the query is complete, if the query is asynchronous. - // This is an optional method, and may not be present for synchronous queries. - // callback: - // This is called when the query is completed successfully, and is passed a single argument - // that is an array representing the query results. - // errorHandler: - // This is called if the query failed, and is passed a single argument that is the error - // for the failure. - }, - observe: function(listener, includeAllUpdates){ - // summary: - // This registers a callback for notification of when data is modified in the query results. - // This is an optional method, and is usually provided by dojo/store/Observable. - // listener: Function - // The listener function is called when objects in the query results are modified - // to affect the query result. The listener function is called with the following arguments: - // | listener(object, removedFrom, insertedInto); - // - // - The object parameter indicates the object that was create, modified, or deleted. - // - The removedFrom parameter indicates the index in the result array where - // the object used to be. If the value is -1, then the object is an addition to - // this result set (due to a new object being created, or changed such that it - // is a part of the result set). - // - The insertedInto parameter indicates the index in the result array where - // the object should be now. If the value is -1, then the object is a removal - // from this result set (due to an object being deleted, or changed such that it - // is not a part of the result set). - // includeAllUpdates: - // This indicates whether or not to include object updates that do not affect - // the inclusion or order of the object in the query results. By default this is false, - // which means that if any object is updated in such a way that it remains - // in the result set and it's position in result sets is not affected, then the listener - // will not be fired. - - }, - // total: Number|Promise? - // This property should be included in if the query options included the "count" - // property limiting the result set. This property indicates the total number of objects - // matching the query (as if "start" and "count" weren't present). This may be - // a promise if the query is asynchronous. - total: 0 -}); - -Store.Transaction = declare(null, { - // summary: - // This is an object returned from transaction() calls that represents the current - // transaction. - - commit: function(){ - // summary: - // Commits the transaction. This may throw an error if it fails. Of if the operation - // is asynchronous, it may return a promise that represents the eventual success - // or failure of the commit. - }, - abort: function(callback, thisObject){ - // summary: - // Aborts the transaction. This may throw an error if it fails. Of if the operation - // is asynchronous, it may return a promise that represents the eventual success - // or failure of the abort. - } -}); -return Store; -}); diff --git a/lib/dojo/store/util/QueryResults.js b/lib/dojo/store/util/QueryResults.js deleted file mode 100644 index 9750933..0000000 --- a/lib/dojo/store/util/QueryResults.js +++ /dev/null @@ -1,41 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/store/util/QueryResults",["../../_base/array","../../_base/lang","../../when"],function(_1,_2,_3){ -var _4=function(_5){ -if(!_5){ -return _5; -} -var _6=!!_5.then; -if(_6){ -_5=_2.delegate(_5); -} -function _7(_8){ -_5[_8]=function(){ -var _9=arguments; -var _a=_3(_5,function(_b){ -Array.prototype.unshift.call(_9,_b); -return _4(_1[_8].apply(_1,_9)); -}); -if(_8!=="forEach"||_6){ -return _a; -} -}; -}; -_7("forEach"); -_7("filter"); -_7("map"); -if(_5.total==null){ -_5.total=_3(_5,function(_c){ -return _c.length; -}); -} -return _5; -}; -_2.setObject("dojo.store.util.QueryResults",_4); -return _4; -}); diff --git a/lib/dojo/store/util/QueryResults.js.uncompressed.js b/lib/dojo/store/util/QueryResults.js.uncompressed.js deleted file mode 100644 index ad829df..0000000 --- a/lib/dojo/store/util/QueryResults.js.uncompressed.js +++ /dev/null @@ -1,71 +0,0 @@ -define("dojo/store/util/QueryResults", ["../../_base/array", "../../_base/lang", "../../when" -], function(array, lang, when){ - -// module: -// dojo/store/util/QueryResults - -var QueryResults = function(results){ - // summary: - // A function that wraps the results of a store query with additional - // methods. - // description: - // QueryResults is a basic wrapper that allows for array-like iteration - // over any kind of returned data from a query. While the simplest store - // will return a plain array of data, other stores may return deferreds or - // promises; this wrapper makes sure that *all* results can be treated - // the same. - // - // Additional methods include `forEach`, `filter` and `map`. - // results: Array|dojo/promise/Promise - // The result set as an array, or a promise for an array. - // returns: - // An array-like object that can be used for iterating over. - // example: - // Query a store and iterate over the results. - // - // | store.query({ prime: true }).forEach(function(item){ - // | // do something - // | }); - - if(!results){ - return results; - } - - var isPromise = !!results.then; - // if it is a promise it may be frozen - if(isPromise){ - results = lang.delegate(results); - } - function addIterativeMethod(method){ - // Always add the iterative methods so a QueryResults is - // returned whether the environment is ES3 or ES5 - results[method] = function(){ - var args = arguments; - var result = when(results, function(results){ - Array.prototype.unshift.call(args, results); - return QueryResults(array[method].apply(array, args)); - }); - // forEach should only return the result of when() - // when we're wrapping a promise - if(method !== "forEach" || isPromise){ - return result; - } - }; - } - - addIterativeMethod("forEach"); - addIterativeMethod("filter"); - addIterativeMethod("map"); - if(results.total == null){ - results.total = when(results, function(results){ - return results.length; - }); - } - return results; // Object -}; - -lang.setObject("dojo.store.util.QueryResults", QueryResults); - -return QueryResults; - -}); diff --git a/lib/dojo/store/util/SimpleQueryEngine.js b/lib/dojo/store/util/SimpleQueryEngine.js deleted file mode 100644 index 0923884..0000000 --- a/lib/dojo/store/util/SimpleQueryEngine.js +++ /dev/null @@ -1,66 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/store/util/SimpleQueryEngine",["../../_base/array"],function(_1){ -return function(_2,_3){ -switch(typeof _2){ -default: -throw new Error("Can not query with a "+typeof _2); -case "object": -case "undefined": -var _4=_2; -_2=function(_5){ -for(var _6 in _4){ -var _7=_4[_6]; -if(_7&&_7.test){ -if(!_7.test(_5[_6],_5)){ -return false; -} -}else{ -if(_7!=_5[_6]){ -return false; -} -} -} -return true; -}; -break; -case "string": -if(!this[_2]){ -throw new Error("No filter function "+_2+" was found in store"); -} -_2=this[_2]; -case "function": -} -function _8(_9){ -var _a=_1.filter(_9,_2); -var _b=_3&&_3.sort; -if(_b){ -_a.sort(typeof _b=="function"?_b:function(a,b){ -for(var _c,i=0;_c=_b[i];i++){ -var _d=a[_c.attribute]; -var _e=b[_c.attribute]; -_d=_d!=null?_d.valueOf():_d; -_e=_e!=null?_e.valueOf():_e; -if(_d!=_e){ -return !!_c.descending==(_d==null||_d>_e)?-1:1; -} -} -return 0; -}); -} -if(_3&&(_3.start||_3.count)){ -var _f=_a.length; -_a=_a.slice(_3.start||0,(_3.start||0)+(_3.count||Infinity)); -_a.total=_f; -} -return _a; -}; -_8.matches=_2; -return _8; -}; -}); diff --git a/lib/dojo/store/util/SimpleQueryEngine.js.uncompressed.js b/lib/dojo/store/util/SimpleQueryEngine.js.uncompressed.js deleted file mode 100644 index 2f5dd39..0000000 --- a/lib/dojo/store/util/SimpleQueryEngine.js.uncompressed.js +++ /dev/null @@ -1,113 +0,0 @@ -define("dojo/store/util/SimpleQueryEngine", ["../../_base/array" /*=====, "../api/Store" =====*/], function(arrayUtil /*=====, Store =====*/){ - -// module: -// dojo/store/util/SimpleQueryEngine - -return function(query, options){ - // summary: - // Simple query engine that matches using filter functions, named filter - // functions or objects by name-value on a query object hash - // - // description: - // The SimpleQueryEngine provides a way of getting a QueryResults through - // the use of a simple object hash as a filter. The hash will be used to - // match properties on data objects with the corresponding value given. In - // other words, only exact matches will be returned. - // - // This function can be used as a template for more complex query engines; - // for example, an engine can be created that accepts an object hash that - // contains filtering functions, or a string that gets evaluated, etc. - // - // When creating a new dojo.store, simply set the store's queryEngine - // field as a reference to this function. - // - // query: Object - // An object hash with fields that may match fields of items in the store. - // Values in the hash will be compared by normal == operator, but regular expressions - // or any object that provides a test() method are also supported and can be - // used to match strings by more complex expressions - // (and then the regex's or object's test() method will be used to match values). - // - // options: dojo/store/api/Store.QueryOptions? - // An object that contains optional information such as sort, start, and count. - // - // returns: Function - // A function that caches the passed query under the field "matches". See any - // of the "query" methods on dojo.stores. - // - // example: - // Define a store with a reference to this engine, and set up a query method. - // - // | var myStore = function(options){ - // | // ...more properties here - // | this.queryEngine = SimpleQueryEngine; - // | // define our query method - // | this.query = function(query, options){ - // | return QueryResults(this.queryEngine(query, options)(this.data)); - // | }; - // | }; - - // create our matching query function - switch(typeof query){ - default: - throw new Error("Can not query with a " + typeof query); - case "object": case "undefined": - var queryObject = query; - query = function(object){ - for(var key in queryObject){ - var required = queryObject[key]; - if(required && required.test){ - // an object can provide a test method, which makes it work with regex - if(!required.test(object[key], object)){ - return false; - } - }else if(required != object[key]){ - return false; - } - } - return true; - }; - break; - case "string": - // named query - if(!this[query]){ - throw new Error("No filter function " + query + " was found in store"); - } - query = this[query]; - // fall through - case "function": - // fall through - } - function execute(array){ - // execute the whole query, first we filter - var results = arrayUtil.filter(array, query); - // next we sort - var sortSet = options && options.sort; - if(sortSet){ - results.sort(typeof sortSet == "function" ? sortSet : function(a, b){ - for(var sort, i=0; sort = sortSet[i]; i++){ - var aValue = a[sort.attribute]; - var bValue = b[sort.attribute]; - // valueOf enables proper comparison of dates - aValue = aValue != null ? aValue.valueOf() : aValue; - bValue = bValue != null ? bValue.valueOf() : bValue; - if (aValue != bValue){ - return !!sort.descending == (aValue == null || aValue > bValue) ? -1 : 1; - } - } - return 0; - }); - } - // now we paginate - if(options && (options.start || options.count)){ - var total = results.length; - results = results.slice(options.start || 0, (options.start || 0) + (options.count || Infinity)); - results.total = total; - } - return results; - } - execute.matches = query; - return execute; -}; - -}); diff --git a/lib/dojo/string.js b/lib/dojo/string.js deleted file mode 100644 index fedf7b1..0000000 --- a/lib/dojo/string.js +++ /dev/null @@ -1,68 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/string",["./_base/kernel","./_base/lang"],function(_1,_2){ -var _3=/[&<>'"\/]/g; -var _4={"&":"&","<":"<",">":">","\"":""","'":"'","/":"/"}; -var _5={}; -_2.setObject("dojo.string",_5); -_5.escape=function(_6){ -if(!_6){ -return ""; -} -return _6.replace(_3,function(c){ -return _4[c]; -}); -}; -_5.rep=function(_7,_8){ -if(_8<=0||!_7){ -return ""; -} -var _9=[]; -for(;;){ -if(_8&1){ -_9.push(_7); -} -if(!(_8>>=1)){ -break; -} -_7+=_7; -} -return _9.join(""); -}; -_5.pad=function(_a,_b,ch,_c){ -if(!ch){ -ch="0"; -} -var _d=String(_a),_e=_5.rep(ch,Math.ceil((_b-_d.length)/ch.length)); -return _c?_d+_e:_e+_d; -}; -_5.substitute=function(_f,map,_10,_11){ -_11=_11||_1.global; -_10=_10?_2.hitch(_11,_10):function(v){ -return v; -}; -return _f.replace(/\$\{([^\s\:\}]+)(?:\:([^\s\:\}]+))?\}/g,function(_12,key,_13){ -var _14=_2.getObject(key,false,map); -if(_13){ -_14=_2.getObject(_13,false,_11).call(_11,_14,key); -} -return _10(_14,key).toString(); -}); -}; -_5.trim=String.prototype.trim?_2.trim:function(str){ -str=str.replace(/^\s+/,""); -for(var i=str.length-1;i>=0;i--){ -if(/\S/.test(str.charAt(i))){ -str=str.substring(0,i+1); -break; -} -} -return str; -}; -return _5; -}); diff --git a/lib/dojo/string.js.uncompressed.js b/lib/dojo/string.js.uncompressed.js deleted file mode 100644 index 7c01082..0000000 --- a/lib/dojo/string.js.uncompressed.js +++ /dev/null @@ -1,181 +0,0 @@ -define("dojo/string", [ - "./_base/kernel", // kernel.global - "./_base/lang" -], function(kernel, lang){ - -// module: -// dojo/string -var ESCAPE_REGEXP = /[&<>'"\/]/g; -var ESCAPE_MAP = { - '&': '&', - '<': '<', - '>': '>', - '"': '"', - "'": ''', - '/': '/' -}; -var string = { - // summary: - // String utilities for Dojo -}; -lang.setObject("dojo.string", string); - -string.escape = function(/*String*/str){ - // summary: - // Efficiently escape a string for insertion into HTML (innerHTML or attributes), replacing &, <, >, ", ', and / characters. - // str: - // the string to escape - if(!str){ return ""; } - return str.replace(ESCAPE_REGEXP, function(c) { - return ESCAPE_MAP[c]; - }); -}; - -string.rep = function(/*String*/str, /*Integer*/num){ - // summary: - // Efficiently replicate a string `n` times. - // str: - // the string to replicate - // num: - // number of times to replicate the string - - if(num <= 0 || !str){ return ""; } - - var buf = []; - for(;;){ - if(num & 1){ - buf.push(str); - } - if(!(num >>= 1)){ break; } - str += str; - } - return buf.join(""); // String -}; - -string.pad = function(/*String*/text, /*Integer*/size, /*String?*/ch, /*Boolean?*/end){ - // summary: - // Pad a string to guarantee that it is at least `size` length by - // filling with the character `ch` at either the start or end of the - // string. Pads at the start, by default. - // text: - // the string to pad - // size: - // length to provide padding - // ch: - // character to pad, defaults to '0' - // end: - // adds padding at the end if true, otherwise pads at start - // example: - // | // Fill the string to length 10 with "+" characters on the right. Yields "Dojo++++++". - // | string.pad("Dojo", 10, "+", true); - - if(!ch){ - ch = '0'; - } - var out = String(text), - pad = string.rep(ch, Math.ceil((size - out.length) / ch.length)); - return end ? out + pad : pad + out; // String -}; - -string.substitute = function( /*String*/ template, - /*Object|Array*/map, - /*Function?*/ transform, - /*Object?*/ thisObject){ - // summary: - // Performs parameterized substitutions on a string. Throws an - // exception if any parameter is unmatched. - // template: - // a string with expressions in the form `${key}` to be replaced or - // `${key:format}` which specifies a format function. keys are case-sensitive. - // map: - // hash to search for substitutions - // transform: - // a function to process all parameters before substitution takes - // place, e.g. mylib.encodeXML - // thisObject: - // where to look for optional format function; default to the global - // namespace - // example: - // Substitutes two expressions in a string from an Array or Object - // | // returns "File 'foo.html' is not found in directory '/temp'." - // | // by providing substitution data in an Array - // | string.substitute( - // | "File '${0}' is not found in directory '${1}'.", - // | ["foo.html","/temp"] - // | ); - // | - // | // also returns "File 'foo.html' is not found in directory '/temp'." - // | // but provides substitution data in an Object structure. Dotted - // | // notation may be used to traverse the structure. - // | string.substitute( - // | "File '${name}' is not found in directory '${info.dir}'.", - // | { name: "foo.html", info: { dir: "/temp" } } - // | ); - // example: - // Use a transform function to modify the values: - // | // returns "file 'foo.html' is not found in directory '/temp'." - // | string.substitute( - // | "${0} is not found in ${1}.", - // | ["foo.html","/temp"], - // | function(str){ - // | // try to figure out the type - // | var prefix = (str.charAt(0) == "/") ? "directory": "file"; - // | return prefix + " '" + str + "'"; - // | } - // | ); - // example: - // Use a formatter - // | // returns "thinger -- howdy" - // | string.substitute( - // | "${0:postfix}", ["thinger"], null, { - // | postfix: function(value, key){ - // | return value + " -- howdy"; - // | } - // | } - // | ); - - thisObject = thisObject || kernel.global; - transform = transform ? - lang.hitch(thisObject, transform) : function(v){ return v; }; - - return template.replace(/\$\{([^\s\:\}]+)(?:\:([^\s\:\}]+))?\}/g, - function(match, key, format){ - var value = lang.getObject(key, false, map); - if(format){ - value = lang.getObject(format, false, thisObject).call(thisObject, value, key); - } - return transform(value, key).toString(); - }); // String -}; - -string.trim = String.prototype.trim ? - lang.trim : // aliasing to the native function - function(str){ - str = str.replace(/^\s+/, ''); - for(var i = str.length - 1; i >= 0; i--){ - if(/\S/.test(str.charAt(i))){ - str = str.substring(0, i + 1); - break; - } - } - return str; - }; - -/*===== - string.trim = function(str){ - // summary: - // Trims whitespace from both sides of the string - // str: String - // String to be trimmed - // returns: String - // Returns the trimmed string - // description: - // This version of trim() was taken from [Steven Levithan's blog](http://blog.stevenlevithan.com/archives/faster-trim-javascript). - // The short yet performant version of this function is dojo/_base/lang.trim(), - // which is part of Dojo base. Uses String.prototype.trim instead, if available. - return ""; // String - }; - =====*/ - - return string; -}); diff --git a/lib/dojo/text.js b/lib/dojo/text.js deleted file mode 100644 index 1929059..0000000 --- a/lib/dojo/text.js +++ /dev/null @@ -1,99 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/text",["./_base/kernel","require","./has","./request"],function(_1,_2,_3,_4){ -var _5; -if(1){ -_5=function(_6,_7,_8){ -_4(_6,{sync:!!_7,headers:{"X-Requested-With":null}}).then(_8); -}; -}else{ -if(_2.getText){ -_5=_2.getText; -}else{ -console.error("dojo/text plugin failed to load because loader does not support getText"); -} -} -var _9={},_a=function(_b){ -if(_b){ -_b=_b.replace(/^\s*<\?xml(\s)+version=[\'\"](\d)*.(\d)*[\'\"](\s)*\?>/im,""); -var _c=_b.match(/]*>\s*([\s\S]+)\s*<\/body>/im); -if(_c){ -_b=_c[1]; -} -}else{ -_b=""; -} -return _b; -},_d={},_e={}; -_1.cache=function(_f,url,_10){ -var key; -if(typeof _f=="string"){ -if(/\//.test(_f)){ -key=_f; -_10=url; -}else{ -key=_2.toUrl(_f.replace(/\./g,"/")+(url?("/"+url):"")); -} -}else{ -key=_f+""; -_10=url; -} -var val=(_10!=undefined&&typeof _10!="string")?_10.value:_10,_11=_10&&_10.sanitize; -if(typeof val=="string"){ -_9[key]=val; -return _11?_a(val):val; -}else{ -if(val===null){ -delete _9[key]; -return null; -}else{ -if(!(key in _9)){ -_5(key,true,function(_12){ -_9[key]=_12; -}); -} -return _11?_a(_9[key]):_9[key]; -} -} -}; -return {dynamic:true,normalize:function(id,_13){ -var _14=id.split("!"),url=_14[0]; -return (/^\./.test(url)?_13(url):url)+(_14[1]?"!"+_14[1]:""); -},load:function(id,_15,_16){ -var _17=id.split("!"),_18=_17.length>1,_19=_17[0],url=_15.toUrl(_17[0]),_1a="url:"+url,_1b=_d,_1c=function(_1d){ -_16(_18?_a(_1d):_1d); -}; -if(_19 in _9){ -_1b=_9[_19]; -}else{ -if(_15.cache&&_1a in _15.cache){ -_1b=_15.cache[_1a]; -}else{ -if(url in _9){ -_1b=_9[url]; -} -} -} -if(_1b===_d){ -if(_e[url]){ -_e[url].push(_1c); -}else{ -var _1e=_e[url]=[_1c]; -_5(url,!_15.async,function(_1f){ -_9[_19]=_9[url]=_1f; -for(var i=0;i<_1e.length;){ -_1e[i++](_1f); -} -delete _e[url]; -}); -} -}else{ -_1c(_1b); -} -}}; -}); diff --git a/lib/dojo/text.js.uncompressed.js b/lib/dojo/text.js.uncompressed.js deleted file mode 100644 index 9aec8d2..0000000 --- a/lib/dojo/text.js.uncompressed.js +++ /dev/null @@ -1,218 +0,0 @@ -define("dojo/text", ["./_base/kernel", "require", "./has", "./request"], function(dojo, require, has, request){ - // module: - // dojo/text - - var getText; - if( 1 ){ - getText= function(url, sync, load){ - request(url, {sync:!!sync, headers: { 'X-Requested-With': null } }).then(load); - }; - }else{ - // Path for node.js and rhino, to load from local file system. - // TODO: use node.js native methods rather than depending on a require.getText() method to exist. - if(require.getText){ - getText= require.getText; - }else{ - console.error("dojo/text plugin failed to load because loader does not support getText"); - } - } - - var - theCache = {}, - - strip= function(text){ - //Strips declarations so that external SVG and XML - //documents can be added to a document without worry. Also, if the string - //is an HTML document, only the part inside the body tag is returned. - if(text){ - text= text.replace(/^\s*<\?xml(\s)+version=[\'\"](\d)*.(\d)*[\'\"](\s)*\?>/im, ""); - var matches= text.match(/]*>\s*([\s\S]+)\s*<\/body>/im); - if(matches){ - text= matches[1]; - } - }else{ - text = ""; - } - return text; - }, - - notFound = {}, - - pending = {}; - - dojo.cache = function(/*String||Object*/module, /*String*/url, /*String||Object?*/value){ - // summary: - // A getter and setter for storing the string content associated with the - // module and url arguments. - // description: - // If module is a string that contains slashes, then it is interpretted as a fully - // resolved path (typically a result returned by require.toUrl), and url should not be - // provided. This is the preferred signature. If module is a string that does not - // contain slashes, then url must also be provided and module and url are used to - // call `dojo.moduleUrl()` to generate a module URL. This signature is deprecated. - // If value is specified, the cache value for the moduleUrl will be set to - // that value. Otherwise, dojo.cache will fetch the moduleUrl and store it - // in its internal cache and return that cached value for the URL. To clear - // a cache value pass null for value. Since XMLHttpRequest (XHR) is used to fetch the - // the URL contents, only modules on the same domain of the page can use this capability. - // The build system can inline the cache values though, to allow for xdomain hosting. - // module: String||Object - // If a String with slashes, a fully resolved path; if a String without slashes, the - // module name to use for the base part of the URL, similar to module argument - // to `dojo.moduleUrl`. If an Object, something that has a .toString() method that - // generates a valid path for the cache item. For example, a dojo._Url object. - // url: String - // The rest of the path to append to the path derived from the module argument. If - // module is an object, then this second argument should be the "value" argument instead. - // value: String||Object? - // If a String, the value to use in the cache for the module/url combination. - // If an Object, it can have two properties: value and sanitize. The value property - // should be the value to use in the cache, and sanitize can be set to true or false, - // to indicate if XML declarations should be removed from the value and if the HTML - // inside a body tag in the value should be extracted as the real value. The value argument - // or the value property on the value argument are usually only used by the build system - // as it inlines cache content. - // example: - // To ask dojo.cache to fetch content and store it in the cache (the dojo["cache"] style - // of call is used to avoid an issue with the build system erroneously trying to intern - // this example. To get the build system to intern your dojo.cache calls, use the - // "dojo.cache" style of call): - // | //If template.html contains "

    Hello

    " that will be - // | //the value for the text variable. - // | //Note: This is pre-AMD, deprecated syntax - // | var text = dojo["cache"]("my.module", "template.html"); - // example: - // To ask dojo.cache to fetch content and store it in the cache, and sanitize the input - // (the dojo["cache"] style of call is used to avoid an issue with the build system - // erroneously trying to intern this example. To get the build system to intern your - // dojo.cache calls, use the "dojo.cache" style of call): - // | //If template.html contains "

    Hello

    ", the - // | //text variable will contain just "

    Hello

    ". - // | //Note: This is pre-AMD, deprecated syntax - // | var text = dojo["cache"]("my.module", "template.html", {sanitize: true}); - // example: - // Same example as previous, but demonstrates how an object can be passed in as - // the first argument, then the value argument can then be the second argument. - // | //If template.html contains "

    Hello

    ", the - // | //text variable will contain just "

    Hello

    ". - // | //Note: This is pre-AMD, deprecated syntax - // | var text = dojo["cache"](new dojo._Url("my/module/template.html"), {sanitize: true}); - - // * (string string [value]) => (module, url, value) - // * (object [value]) => (module, value), url defaults to "" - // - // * if module is an object, then it must be convertable to a string - // * (module, url) module + (url ? ("/" + url) : "") must be a legal argument to require.toUrl - // * value may be a string or an object; if an object then may have the properties "value" and/or "sanitize" - var key; - if(typeof module=="string"){ - if(/\//.test(module)){ - // module is a version 1.7+ resolved path - key = module; - value = url; - }else{ - // module is a version 1.6- argument to dojo.moduleUrl - key = require.toUrl(module.replace(/\./g, "/") + (url ? ("/" + url) : "")); - } - }else{ - key = module + ""; - value = url; - } - var - val = (value != undefined && typeof value != "string") ? value.value : value, - sanitize = value && value.sanitize; - - if(typeof val == "string"){ - //We have a string, set cache value - theCache[key] = val; - return sanitize ? strip(val) : val; - }else if(val === null){ - //Remove cached value - delete theCache[key]; - return null; - }else{ - //Allow cache values to be empty strings. If key property does - //not exist, fetch it. - if(!(key in theCache)){ - getText(key, true, function(text){ - theCache[key]= text; - }); - } - return sanitize ? strip(theCache[key]) : theCache[key]; - } - }; - - return { - // summary: - // This module implements the dojo/text! plugin and the dojo.cache API. - // description: - // We choose to include our own plugin to leverage functionality already contained in dojo - // and thereby reduce the size of the plugin compared to various foreign loader implementations. - // Also, this allows foreign AMD loaders to be used without their plugins. - // - // CAUTION: this module is designed to optionally function synchronously to support the dojo v1.x synchronous - // loader. This feature is outside the scope of the CommonJS plugins specification. - - // the dojo/text caches it's own resources because of dojo.cache - dynamic: true, - - normalize: function(id, toAbsMid){ - // id is something like (path may be relative): - // - // "path/to/text.html" - // "path/to/text.html!strip" - var parts= id.split("!"), - url= parts[0]; - return (/^\./.test(url) ? toAbsMid(url) : url) + (parts[1] ? "!" + parts[1] : ""); - }, - - load: function(id, require, load){ - // id: String - // Path to the resource. - // require: Function - // Object that include the function toUrl with given id returns a valid URL from which to load the text. - // load: Function - // Callback function which will be called, when the loading finished. - - // id is something like (path is always absolute): - // - // "path/to/text.html" - // "path/to/text.html!strip" - var - parts= id.split("!"), - stripFlag= parts.length>1, - absMid= parts[0], - url = require.toUrl(parts[0]), - requireCacheUrl = "url:" + url, - text = notFound, - finish = function(text){ - load(stripFlag ? strip(text) : text); - }; - if(absMid in theCache){ - text = theCache[absMid]; - }else if(require.cache && requireCacheUrl in require.cache){ - text = require.cache[requireCacheUrl]; - }else if(url in theCache){ - text = theCache[url]; - } - if(text===notFound){ - if(pending[url]){ - pending[url].push(finish); - }else{ - var pendingList = pending[url] = [finish]; - getText(url, !require.async, function(text){ - theCache[absMid]= theCache[url]= text; - for(var i = 0; i= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/throttle",[],function(){ -return function(cb,_1){ -var _2=true; -return function(){ -if(!_2){ -return; -} -_2=false; -cb.apply(this,arguments); -setTimeout(function(){ -_2=true; -},_1); -}; -}; -}); diff --git a/lib/dojo/throttle.js.uncompressed.js b/lib/dojo/throttle.js.uncompressed.js deleted file mode 100644 index 4f0bcbc..0000000 --- a/lib/dojo/throttle.js.uncompressed.js +++ /dev/null @@ -1,31 +0,0 @@ -define("dojo/throttle", [], function(){ - // module: - // dojo/throttle - // summary: - // This module provide a throttler - - return function(cb, wait){ - // summary: - // Create a function that will only execute once per `wait` periods. - // description: - // Create a function that will only execute once per `wait` periods - // from last execution when called repeatedly. Useful for preventing excessive - // calculations in rapidly firing events, such as window.resize, node.mousemove - // and so on. - // cb: Function - // The callback to fire. - // wait: Integer - // time to delay before allowing cb to call again. - var canrun = true; - return function(){ - if(!canrun){ - return; - } - canrun = false; - cb.apply(this, arguments); - setTimeout(function(){ - canrun = true; - }, wait); - }; - }; -}); diff --git a/lib/dojo/topic.js b/lib/dojo/topic.js deleted file mode 100644 index be1f80d..0000000 --- a/lib/dojo/topic.js +++ /dev/null @@ -1,15 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/topic",["./Evented"],function(_1){ -var _2=new _1; -return {publish:function(_3,_4){ -return _2.emit.apply(_2,arguments); -},subscribe:function(_5,_6){ -return _2.on.apply(_2,arguments); -}}; -}); diff --git a/lib/dojo/topic.js.uncompressed.js b/lib/dojo/topic.js.uncompressed.js deleted file mode 100644 index 35e1937..0000000 --- a/lib/dojo/topic.js.uncompressed.js +++ /dev/null @@ -1,38 +0,0 @@ -define("dojo/topic", ["./Evented"], function(Evented){ - - // module: - // dojo/topic - - var hub = new Evented; - return { - // summary: - // Pubsub hub. - // example: - // | topic.subscribe("some/topic", function(event){ - // | ... do something with event - // | }); - // | topic.publish("some/topic", {name:"some event", ...}); - - publish: function(topic, event){ - // summary: - // Publishes a message to a topic on the pub/sub hub. All arguments after - // the first will be passed to the subscribers, so any number of arguments - // can be provided (not just event). - // topic: String - // The name of the topic to publish to - // event: Object - // An event to distribute to the topic listeners - return hub.emit.apply(hub, arguments); - }, - - subscribe: function(topic, listener){ - // summary: - // Subscribes to a topic on the pub/sub hub - // topic: String - // The topic to subscribe to - // listener: Function - // A function to call when a message is published to the given topic - return hub.on.apply(hub, arguments); - } - }; -}); diff --git a/lib/dojo/touch.js b/lib/dojo/touch.js deleted file mode 100644 index be57cea..0000000 --- a/lib/dojo/touch.js +++ /dev/null @@ -1,175 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/touch",["./_base/kernel","./aspect","./dom","./dom-class","./_base/lang","./on","./has","./mouse","./domReady","./_base/window"],function(_1,_2,_3,_4,_5,on,_6,_7,_8,_9){ -var _a=_6("ios")<5; -var _b=_6("pointer-events")||_6("MSPointer"),_c=(function(){ -var _d={}; -for(var _e in {down:1,move:1,up:1,cancel:1,over:1,out:1}){ -_d[_e]=_6("MSPointer")?"MSPointer"+_e.charAt(0).toUpperCase()+_e.slice(1):"pointer"+_e; -} -return _d; -})(); -var _f=_6("touch-events"); -var _10,_11,_12=false,_13,_14,_15,_16,_17,_18; -var _19; -function _1a(_1b,_1c,_1d){ -if(_b&&_1d){ -return function(_1e,_1f){ -return on(_1e,_1d,_1f); -}; -}else{ -if(_f){ -return function(_20,_21){ -var _22=on(_20,_1c,function(evt){ -_21.call(this,evt); -_19=(new Date()).getTime(); -}),_23=on(_20,_1b,function(evt){ -if(!_19||(new Date()).getTime()>_19+1000){ -_21.call(this,evt); -} -}); -return {remove:function(){ -_22.remove(); -_23.remove(); -}}; -}; -}else{ -return function(_24,_25){ -return on(_24,_1b,_25); -}; -} -} -}; -function _26(_27){ -do{ -if(_27.dojoClick!==undefined){ -return _27; -} -}while(_27=_27.parentNode); -}; -function _28(e,_29,_2a){ -var _2b=_26(e.target); -_11=!e.target.disabled&&_2b&&_2b.dojoClick; -if(_11){ -_12=(_11=="useTarget"); -_13=(_12?_2b:e.target); -if(_12){ -e.preventDefault(); -} -_14=e.changedTouches?e.changedTouches[0].pageX-_9.global.pageXOffset:e.clientX; -_15=e.changedTouches?e.changedTouches[0].pageY-_9.global.pageYOffset:e.clientY; -_16=(typeof _11=="object"?_11.x:(typeof _11=="number"?_11:0))||4; -_17=(typeof _11=="object"?_11.y:(typeof _11=="number"?_11:0))||4; -if(!_10){ -_10=true; -function _2c(e){ -if(_12){ -_11=_3.isDescendant(_9.doc.elementFromPoint((e.changedTouches?e.changedTouches[0].pageX-_9.global.pageXOffset:e.clientX),(e.changedTouches?e.changedTouches[0].pageY-_9.global.pageYOffset:e.clientY)),_13); -}else{ -_11=_11&&(e.changedTouches?e.changedTouches[0].target:e.target)==_13&&Math.abs((e.changedTouches?e.changedTouches[0].pageX-_9.global.pageXOffset:e.clientX)-_14)<=_16&&Math.abs((e.changedTouches?e.changedTouches[0].pageY-_9.global.pageYOffset:e.clientY)-_15)<=_17; -} -}; -_9.doc.addEventListener(_29,function(e){ -_2c(e); -if(_12){ -e.preventDefault(); -} -},true); -_9.doc.addEventListener(_2a,function(e){ -_2c(e); -if(_11){ -_18=(new Date()).getTime(); -var _2d=(_12?_13:e.target); -if(_2d.tagName==="LABEL"){ -_2d=_3.byId(_2d.getAttribute("for"))||_2d; -} -var src=(e.changedTouches)?e.changedTouches[0]:e; -var _2e=document.createEvent("MouseEvents"); -_2e._dojo_click=true; -_2e.initMouseEvent("click",true,true,e.view,e.detail,src.screenX,src.screenY,src.clientX,src.clientY,e.ctrlKey,e.altKey,e.shiftKey,e.metaKey,0,null); -setTimeout(function(){ -on.emit(_2d,"click",_2e); -_18=(new Date()).getTime(); -},0); -} -},true); -function _2f(_30){ -_9.doc.addEventListener(_30,function(e){ -if(!e._dojo_click&&(new Date()).getTime()<=_18+1000&&!(e.target.tagName=="INPUT"&&_4.contains(e.target,"dijitOffScreen"))){ -e.stopPropagation(); -e.stopImmediatePropagation&&e.stopImmediatePropagation(); -if(_30=="click"&&(e.target.tagName!="INPUT"||e.target.type=="radio"||e.target.type=="checkbox")&&e.target.tagName!="TEXTAREA"&&e.target.tagName!="AUDIO"&&e.target.tagName!="VIDEO"){ -e.preventDefault(); -} -} -},true); -}; -_2f("click"); -_2f("mousedown"); -_2f("mouseup"); -} -} -}; -var _31; -if(_b){ -_8(function(){ -_9.doc.addEventListener(_c.down,function(evt){ -_28(evt,_c.move,_c.up); -},true); -}); -}else{ -if(_f){ -_8(function(){ -_31=_9.body(); -_9.doc.addEventListener("touchstart",function(evt){ -_19=(new Date()).getTime(); -var _32=_31; -_31=evt.target; -on.emit(_32,"dojotouchout",{relatedTarget:_31,bubbles:true}); -on.emit(_31,"dojotouchover",{relatedTarget:_32,bubbles:true}); -_28(evt,"touchmove","touchend"); -},true); -function _33(evt){ -var _34=_5.delegate(evt,{bubbles:true}); -if(_6("ios")>=6){ -_34.touches=evt.touches; -_34.altKey=evt.altKey; -_34.changedTouches=evt.changedTouches; -_34.ctrlKey=evt.ctrlKey; -_34.metaKey=evt.metaKey; -_34.shiftKey=evt.shiftKey; -_34.targetTouches=evt.targetTouches; -} -return _34; -}; -on(_9.doc,"touchmove",function(evt){ -_19=(new Date()).getTime(); -var _35=_9.doc.elementFromPoint(evt.pageX-(_a?0:_9.global.pageXOffset),evt.pageY-(_a?0:_9.global.pageYOffset)); -if(_35){ -if(_31!==_35){ -on.emit(_31,"dojotouchout",{relatedTarget:_35,bubbles:true}); -on.emit(_35,"dojotouchover",{relatedTarget:_31,bubbles:true}); -_31=_35; -} -if(!on.emit(_35,"dojotouchmove",_33(evt))){ -evt.preventDefault(); -} -} -}); -on(_9.doc,"touchend",function(evt){ -_19=(new Date()).getTime(); -var _36=_9.doc.elementFromPoint(evt.pageX-(_a?0:_9.global.pageXOffset),evt.pageY-(_a?0:_9.global.pageYOffset))||_9.body(); -on.emit(_36,"dojotouchend",_33(evt)); -}); -}); -} -} -var _37={press:_1a("mousedown","touchstart",_c.down),move:_1a("mousemove","dojotouchmove",_c.move),release:_1a("mouseup","dojotouchend",_c.up),cancel:_1a(_7.leave,"touchcancel",_b?_c.cancel:null),over:_1a("mouseover","dojotouchover",_c.over),out:_1a("mouseout","dojotouchout",_c.out),enter:_7._eventHandler(_1a("mouseover","dojotouchover",_c.over)),leave:_7._eventHandler(_1a("mouseout","dojotouchout",_c.out))}; -1&&(_1.touch=_37); -return _37; -}); diff --git a/lib/dojo/touch.js.uncompressed.js b/lib/dojo/touch.js.uncompressed.js deleted file mode 100644 index c76df14..0000000 --- a/lib/dojo/touch.js.uncompressed.js +++ /dev/null @@ -1,447 +0,0 @@ -define("dojo/touch", ["./_base/kernel", "./aspect", "./dom", "./dom-class", "./_base/lang", "./on", "./has", "./mouse", "./domReady", "./_base/window"], -function(dojo, aspect, dom, domClass, lang, on, has, mouse, domReady, win){ - - // module: - // dojo/touch - - var ios4 = has("ios") < 5; - - // Detect if platform supports Pointer Events, and if so, the names of the events (pointerdown vs. MSPointerDown). - var hasPointer = has("pointer-events") || has("MSPointer"), - pointer = (function () { - var pointer = {}; - for (var type in { down: 1, move: 1, up: 1, cancel: 1, over: 1, out: 1 }) { - pointer[type] = has("MSPointer") ? - "MSPointer" + type.charAt(0).toUpperCase() + type.slice(1) : - "pointer" + type; - } - return pointer; - })(); - - // Detect if platform supports the webkit touchstart/touchend/... events - var hasTouch = has("touch-events"); - - // Click generation variables - var clicksInited, clickTracker, useTarget = false, clickTarget, clickX, clickY, clickDx, clickDy, clickTime; - - // Time of most recent touchstart, touchmove, or touchend event - var lastTouch; - - function dualEvent(mouseType, touchType, pointerType){ - // Returns synthetic event that listens for both the specified mouse event and specified touch event. - // But ignore fake mouse events that were generated due to the user touching the screen. - if(hasPointer && pointerType){ - // IE10+: MSPointer* events are designed to handle both mouse and touch in a uniform way, - // so just use that regardless of hasTouch. - return function(node, listener){ - return on(node, pointerType, listener); - } - }else if(hasTouch){ - return function(node, listener){ - var handle1 = on(node, touchType, function(evt){ - listener.call(this, evt); - - // On slow mobile browsers (see https://bugs.dojotoolkit.org/ticket/17634), - // a handler for a touch event may take >1s to run. That time shouldn't - // be included in the calculation for lastTouch. - lastTouch = (new Date()).getTime(); - }), - handle2 = on(node, mouseType, function(evt){ - if(!lastTouch || (new Date()).getTime() > lastTouch + 1000){ - listener.call(this, evt); - } - }); - return { - remove: function(){ - handle1.remove(); - handle2.remove(); - } - }; - }; - }else{ - // Avoid creating listeners for touch events on performance sensitive older browsers like IE6 - return function(node, listener){ - return on(node, mouseType, listener); - } - } - } - - function marked(/*DOMNode*/ node){ - // Search for node ancestor has been marked with the dojoClick property to indicate special processing. - // Returns marked ancestor. - do{ - if(node.dojoClick !== undefined){ return node; } - }while(node = node.parentNode); - } - - function doClicks(e, moveType, endType){ - // summary: - // Setup touch listeners to generate synthetic clicks immediately (rather than waiting for the browser - // to generate clicks after the double-tap delay) and consistently (regardless of whether event.preventDefault() - // was called in an event listener. Synthetic clicks are generated only if a node or one of its ancestors has - // its dojoClick property set to truthy. If a node receives synthetic clicks because one of its ancestors has its - // dojoClick property set to truthy, you can disable synthetic clicks on this node by setting its own dojoClick property - // to falsy. - - var markedNode = marked(e.target); - clickTracker = !e.target.disabled && markedNode && markedNode.dojoClick; // click threshold = true, number, x/y object, or "useTarget" - if(clickTracker){ - useTarget = (clickTracker == "useTarget"); - clickTarget = (useTarget?markedNode:e.target); - if(useTarget){ - // We expect a click, so prevent any other - // default action on "touchpress" - e.preventDefault(); - } - clickX = e.changedTouches ? e.changedTouches[0].pageX - win.global.pageXOffset : e.clientX; - clickY = e.changedTouches ? e.changedTouches[0].pageY - win.global.pageYOffset : e.clientY; - clickDx = (typeof clickTracker == "object" ? clickTracker.x : (typeof clickTracker == "number" ? clickTracker : 0)) || 4; - clickDy = (typeof clickTracker == "object" ? clickTracker.y : (typeof clickTracker == "number" ? clickTracker : 0)) || 4; - - // add move/end handlers only the first time a node with dojoClick is seen, - // so we don't add too much overhead when dojoClick is never set. - if(!clicksInited){ - clicksInited = true; - - function updateClickTracker(e){ - if(useTarget){ - clickTracker = dom.isDescendant( - win.doc.elementFromPoint( - (e.changedTouches ? e.changedTouches[0].pageX - win.global.pageXOffset : e.clientX), - (e.changedTouches ? e.changedTouches[0].pageY - win.global.pageYOffset : e.clientY)), - clickTarget); - }else{ - clickTracker = clickTracker && - (e.changedTouches ? e.changedTouches[0].target : e.target) == clickTarget && - Math.abs((e.changedTouches ? e.changedTouches[0].pageX - win.global.pageXOffset : e.clientX) - clickX) <= clickDx && - Math.abs((e.changedTouches ? e.changedTouches[0].pageY - win.global.pageYOffset : e.clientY) - clickY) <= clickDy; - } - } - - win.doc.addEventListener(moveType, function(e){ - updateClickTracker(e); - if(useTarget){ - // prevent native scroll event and ensure touchend is - // fire after touch moves between press and release. - e.preventDefault(); - } - }, true); - - win.doc.addEventListener(endType, function(e){ - updateClickTracker(e); - if(clickTracker){ - clickTime = (new Date()).getTime(); - var target = (useTarget?clickTarget:e.target); - if(target.tagName === "LABEL"){ - // when clicking on a label, forward click to its associated input if any - target = dom.byId(target.getAttribute("for")) || target; - } - //some attributes can be on the Touch object, not on the Event: - //http://www.w3.org/TR/touch-events/#touch-interface - var src = (e.changedTouches) ? e.changedTouches[0] : e; - //create the synthetic event. - //http://www.w3.org/TR/DOM-Level-3-Events/#widl-MouseEvent-initMouseEvent - var clickEvt = document.createEvent("MouseEvents"); - clickEvt._dojo_click = true; - clickEvt.initMouseEvent("click", - true, //bubbles - true, //cancelable - e.view, - e.detail, - src.screenX, - src.screenY, - src.clientX, - src.clientY, - e.ctrlKey, - e.altKey, - e.shiftKey, - e.metaKey, - 0, //button - null //related target - ); - setTimeout(function(){ - on.emit(target, "click", clickEvt); - - // refresh clickTime in case app-defined click handler took a long time to run - clickTime = (new Date()).getTime(); - }, 0); - } - }, true); - - function stopNativeEvents(type){ - win.doc.addEventListener(type, function(e){ - // Stop native events when we emitted our own click event. Note that the native click may occur - // on a different node than the synthetic click event was generated on. For example, - // click on a menu item, causing the menu to disappear, and then (~300ms later) the browser - // sends a click event to the node that was *underneath* the menu. So stop all native events - // sent shortly after ours, similar to what is done in dualEvent. - // The INPUT.dijitOffScreen test is for offscreen inputs used in dijit/form/Button, on which - // we call click() explicitly, we don't want to stop this event. - if(!e._dojo_click && - (new Date()).getTime() <= clickTime + 1000 && - !(e.target.tagName == "INPUT" && domClass.contains(e.target, "dijitOffScreen"))){ - e.stopPropagation(); - e.stopImmediatePropagation && e.stopImmediatePropagation(); - if(type == "click" && (e.target.tagName != "INPUT" || e.target.type == "radio" || e.target.type == "checkbox") - && e.target.tagName != "TEXTAREA" && e.target.tagName != "AUDIO" && e.target.tagName != "VIDEO"){ - // preventDefault() breaks textual s on android, keyboard doesn't popup, - // but it is still needed for checkboxes and radio buttons, otherwise in some cases - // the checked state becomes inconsistent with the widget's state - e.preventDefault(); - } - } - }, true); - } - - stopNativeEvents("click"); - - // We also stop mousedown/up since these would be sent well after with our "fast" click (300ms), - // which can confuse some dijit widgets. - stopNativeEvents("mousedown"); - stopNativeEvents("mouseup"); - } - } - } - - var hoveredNode; - - if(hasPointer){ - // MSPointer (IE10+) already has support for over and out, so we just need to init click support - domReady(function(){ - win.doc.addEventListener(pointer.down, function(evt){ - doClicks(evt, pointer.move, pointer.up); - }, true); - }); - }else if(hasTouch){ - domReady(function(){ - // Keep track of currently hovered node - hoveredNode = win.body(); // currently hovered node - - win.doc.addEventListener("touchstart", function(evt){ - lastTouch = (new Date()).getTime(); - - // Precede touchstart event with touch.over event. DnD depends on this. - // Use addEventListener(cb, true) to run cb before any touchstart handlers on node run, - // and to ensure this code runs even if the listener on the node does event.stop(). - var oldNode = hoveredNode; - hoveredNode = evt.target; - on.emit(oldNode, "dojotouchout", { - relatedTarget: hoveredNode, - bubbles: true - }); - on.emit(hoveredNode, "dojotouchover", { - relatedTarget: oldNode, - bubbles: true - }); - - doClicks(evt, "touchmove", "touchend"); // init click generation - }, true); - - function copyEventProps(evt){ - // Make copy of event object and also set bubbles:true. Used when calling on.emit(). - var props = lang.delegate(evt, { - bubbles: true - }); - - if(has("ios") >= 6){ - // On iOS6 "touches" became a non-enumerable property, which - // is not hit by for...in. Ditto for the other properties below. - props.touches = evt.touches; - props.altKey = evt.altKey; - props.changedTouches = evt.changedTouches; - props.ctrlKey = evt.ctrlKey; - props.metaKey = evt.metaKey; - props.shiftKey = evt.shiftKey; - props.targetTouches = evt.targetTouches; - } - - return props; - } - - on(win.doc, "touchmove", function(evt){ - lastTouch = (new Date()).getTime(); - - var newNode = win.doc.elementFromPoint( - evt.pageX - (ios4 ? 0 : win.global.pageXOffset), // iOS 4 expects page coords - evt.pageY - (ios4 ? 0 : win.global.pageYOffset) - ); - - if(newNode){ - // Fire synthetic touchover and touchout events on nodes since the browser won't do it natively. - if(hoveredNode !== newNode){ - // touch out on the old node - on.emit(hoveredNode, "dojotouchout", { - relatedTarget: newNode, - bubbles: true - }); - - // touchover on the new node - on.emit(newNode, "dojotouchover", { - relatedTarget: hoveredNode, - bubbles: true - }); - - hoveredNode = newNode; - } - - // Unlike a listener on "touchmove", on(node, "dojotouchmove", listener) fires when the finger - // drags over the specified node, regardless of which node the touch started on. - if(!on.emit(newNode, "dojotouchmove", copyEventProps(evt))){ - // emit returns false when synthetic event "dojotouchmove" is cancelled, so we prevent the - // default behavior of the underlying native event "touchmove". - evt.preventDefault(); - } - } - }); - - // Fire a dojotouchend event on the node where the finger was before it was removed from the screen. - // This is different than the native touchend, which fires on the node where the drag started. - on(win.doc, "touchend", function(evt){ - lastTouch = (new Date()).getTime(); - var node = win.doc.elementFromPoint( - evt.pageX - (ios4 ? 0 : win.global.pageXOffset), // iOS 4 expects page coords - evt.pageY - (ios4 ? 0 : win.global.pageYOffset) - ) || win.body(); // if out of the screen - - on.emit(node, "dojotouchend", copyEventProps(evt)); - }); - }); - } - - //device neutral events - touch.press|move|release|cancel/over/out - var touch = { - press: dualEvent("mousedown", "touchstart", pointer.down), - move: dualEvent("mousemove", "dojotouchmove", pointer.move), - release: dualEvent("mouseup", "dojotouchend", pointer.up), - cancel: dualEvent(mouse.leave, "touchcancel", hasPointer ? pointer.cancel : null), - over: dualEvent("mouseover", "dojotouchover", pointer.over), - out: dualEvent("mouseout", "dojotouchout", pointer.out), - enter: mouse._eventHandler(dualEvent("mouseover","dojotouchover", pointer.over)), - leave: mouse._eventHandler(dualEvent("mouseout", "dojotouchout", pointer.out)) - }; - - /*===== - touch = { - // summary: - // This module provides unified touch event handlers by exporting - // press, move, release and cancel which can also run well on desktop. - // Based on http://dvcs.w3.org/hg/webevents/raw-file/tip/touchevents.html - // Also, if the dojoClick property is set to truthy on a DOM node, dojo/touch generates - // click events immediately for this node and its descendants (except for descendants that - // have a dojoClick property set to falsy), to avoid the delay before native browser click events, - // and regardless of whether evt.preventDefault() was called in a touch.press event listener. - // - // example: - // Used with dojo/on - // | define(["dojo/on", "dojo/touch"], function(on, touch){ - // | on(node, touch.press, function(e){}); - // | on(node, touch.move, function(e){}); - // | on(node, touch.release, function(e){}); - // | on(node, touch.cancel, function(e){}); - // example: - // Used with touch.* directly - // | touch.press(node, function(e){}); - // | touch.move(node, function(e){}); - // | touch.release(node, function(e){}); - // | touch.cancel(node, function(e){}); - // example: - // Have dojo/touch generate clicks without delay, with a default move threshold of 4 pixels - // | node.dojoClick = true; - // example: - // Have dojo/touch generate clicks without delay, with a move threshold of 10 pixels horizontally and vertically - // | node.dojoClick = 10; - // example: - // Have dojo/touch generate clicks without delay, with a move threshold of 50 pixels horizontally and 10 pixels vertically - // | node.dojoClick = {x:50, y:5}; - // example: - // Disable clicks without delay generated by dojo/touch on a node that has an ancestor with property dojoClick set to truthy - // | node.dojoClick = false; - - press: function(node, listener){ - // summary: - // Register a listener to 'touchstart'|'mousedown' for the given node - // node: Dom - // Target node to listen to - // listener: Function - // Callback function - // returns: - // A handle which will be used to remove the listener by handle.remove() - }, - move: function(node, listener){ - // summary: - // Register a listener that fires when the mouse cursor or a finger is dragged over the given node. - // node: Dom - // Target node to listen to - // listener: Function - // Callback function - // returns: - // A handle which will be used to remove the listener by handle.remove() - }, - release: function(node, listener){ - // summary: - // Register a listener to releasing the mouse button while the cursor is over the given node - // (i.e. "mouseup") or for removing the finger from the screen while touching the given node. - // node: Dom - // Target node to listen to - // listener: Function - // Callback function - // returns: - // A handle which will be used to remove the listener by handle.remove() - }, - cancel: function(node, listener){ - // summary: - // Register a listener to 'touchcancel'|'mouseleave' for the given node - // node: Dom - // Target node to listen to - // listener: Function - // Callback function - // returns: - // A handle which will be used to remove the listener by handle.remove() - }, - over: function(node, listener){ - // summary: - // Register a listener to 'mouseover' or touch equivalent for the given node - // node: Dom - // Target node to listen to - // listener: Function - // Callback function - // returns: - // A handle which will be used to remove the listener by handle.remove() - }, - out: function(node, listener){ - // summary: - // Register a listener to 'mouseout' or touch equivalent for the given node - // node: Dom - // Target node to listen to - // listener: Function - // Callback function - // returns: - // A handle which will be used to remove the listener by handle.remove() - }, - enter: function(node, listener){ - // summary: - // Register a listener to mouse.enter or touch equivalent for the given node - // node: Dom - // Target node to listen to - // listener: Function - // Callback function - // returns: - // A handle which will be used to remove the listener by handle.remove() - }, - leave: function(node, listener){ - // summary: - // Register a listener to mouse.leave or touch equivalent for the given node - // node: Dom - // Target node to listen to - // listener: Function - // Callback function - // returns: - // A handle which will be used to remove the listener by handle.remove() - } - }; - =====*/ - - 1 && (dojo.touch = touch); - - return touch; -}); diff --git a/lib/dojo/uacss.js b/lib/dojo/uacss.js deleted file mode 100644 index 0e637fc..0000000 --- a/lib/dojo/uacss.js +++ /dev/null @@ -1,33 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/uacss",["./dom-geometry","./_base/lang","./domReady","./sniff","./_base/window"],function(_1,_2,_3,_4,_5){ -var _6=_5.doc.documentElement,ie=_4("ie"),_7=_4("opera"),_8=Math.floor,ff=_4("ff"),_9=_1.boxModel.replace(/-/,""),_a={"dj_quirks":_4("quirks"),"dj_opera":_7,"dj_khtml":_4("khtml"),"dj_webkit":_4("webkit"),"dj_safari":_4("safari"),"dj_chrome":_4("chrome"),"dj_gecko":_4("mozilla"),"dj_ios":_4("ios"),"dj_android":_4("android")}; -if(ie){ -_a["dj_ie"]=true; -_a["dj_ie"+_8(ie)]=true; -_a["dj_iequirks"]=_4("quirks"); -} -if(ff){ -_a["dj_ff"+_8(ff)]=true; -} -_a["dj_"+_9]=true; -var _b=""; -for(var _c in _a){ -if(_a[_c]){ -_b+=_c+" "; -} -} -_6.className=_2.trim(_6.className+" "+_b); -_3(function(){ -if(!_1.isBodyLtr()){ -var _d="dj_rtl dijitRtl "+_b.replace(/ /g,"-rtl "); -_6.className=_2.trim(_6.className+" "+_d+"dj_rtl dijitRtl "+_b.replace(/ /g,"-rtl ")); -} -}); -return _4; -}); diff --git a/lib/dojo/uacss.js.uncompressed.js b/lib/dojo/uacss.js.uncompressed.js deleted file mode 100644 index 475f9b5..0000000 --- a/lib/dojo/uacss.js.uncompressed.js +++ /dev/null @@ -1,79 +0,0 @@ -define("dojo/uacss", ["./dom-geometry", "./_base/lang", "./domReady", "./sniff", "./_base/window"], - function(geometry, lang, domReady, has, baseWindow){ - - // module: - // dojo/uacss - - /*===== - return { - // summary: - // Applies pre-set CSS classes to the top-level HTML node, based on: - // - // - browser (ex: dj_ie) - // - browser version (ex: dj_ie6) - // - box model (ex: dj_contentBox) - // - text direction (ex: dijitRtl) - // - // In addition, browser, browser version, and box model are - // combined with an RTL flag when browser text is RTL. ex: dj_ie-rtl. - // - // Returns the has() method. - }; - =====*/ - - var - html = baseWindow.doc.documentElement, - ie = has("ie"), - opera = has("opera"), - maj = Math.floor, - ff = has("ff"), - boxModel = geometry.boxModel.replace(/-/,''), - - classes = { - "dj_quirks": has("quirks"), - - // NOTE: Opera not supported by dijit - "dj_opera": opera, - - "dj_khtml": has("khtml"), - - "dj_webkit": has("webkit"), - "dj_safari": has("safari"), - "dj_chrome": has("chrome"), - - "dj_gecko": has("mozilla"), - - "dj_ios": has("ios"), - "dj_android": has("android") - }; // no dojo unsupported browsers - - if(ie){ - classes["dj_ie"] = true; - classes["dj_ie" + maj(ie)] = true; - classes["dj_iequirks"] = has("quirks"); - } - if(ff){ - classes["dj_ff" + maj(ff)] = true; - } - - classes["dj_" + boxModel] = true; - - // apply browser, browser version, and box model class names - var classStr = ""; - for(var clz in classes){ - if(classes[clz]){ - classStr += clz + " "; - } - } - html.className = lang.trim(html.className + " " + classStr); - - // If RTL mode, then add dj_rtl flag plus repeat existing classes with -rtl extension. - // We can't run the code below until the tag has loaded (so we can check for dir=rtl). - domReady(function(){ - if(!geometry.isBodyLtr()){ - var rtlClassStr = "dj_rtl dijitRtl " + classStr.replace(/ /g, "-rtl "); - html.className = lang.trim(html.className + " " + rtlClassStr + "dj_rtl dijitRtl " + classStr.replace(/ /g, "-rtl ")); - } - }); - return has; -}); diff --git a/lib/dojo/when.js b/lib/dojo/when.js deleted file mode 100644 index 5e5b2db..0000000 --- a/lib/dojo/when.js +++ /dev/null @@ -1,31 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/when",["./Deferred","./promise/Promise"],function(_1,_2){ -"use strict"; -return function when(_3,_4,_5,_6){ -var _7=_3&&typeof _3.then==="function"; -var _8=_7&&_3 instanceof _2; -if(!_7){ -if(arguments.length>1){ -return _4?_4(_3):_3; -}else{ -return new _1().resolve(_3); -} -}else{ -if(!_8){ -var _9=new _1(_3.cancel); -_3.then(_9.resolve,_9.reject,_9.progress); -_3=_9.promise; -} -} -if(_4||_5||_6){ -return _3.then(_4,_5,_6); -} -return _3; -}; -}); diff --git a/lib/dojo/when.js.uncompressed.js b/lib/dojo/when.js.uncompressed.js deleted file mode 100644 index 6f0ee27..0000000 --- a/lib/dojo/when.js.uncompressed.js +++ /dev/null @@ -1,55 +0,0 @@ -define("dojo/when", [ - "./Deferred", - "./promise/Promise" -], function(Deferred, Promise){ - "use strict"; - - // module: - // dojo/when - - return function when(valueOrPromise, callback, errback, progback){ - // summary: - // Transparently applies callbacks to values and/or promises. - // description: - // Accepts promises but also transparently handles non-promises. If no - // callbacks are provided returns a promise, regardless of the initial - // value. Foreign promises are converted. - // - // If callbacks are provided and the initial value is not a promise, - // the callback is executed immediately with no error handling. Returns - // a promise if the initial value is a promise, or the result of the - // callback otherwise. - // valueOrPromise: - // Either a regular value or an object with a `then()` method that - // follows the Promises/A specification. - // callback: Function? - // Callback to be invoked when the promise is resolved, or a non-promise - // is received. - // errback: Function? - // Callback to be invoked when the promise is rejected. - // progback: Function? - // Callback to be invoked when the promise emits a progress update. - // returns: dojo/promise/Promise - // Promise, or if a callback is provided, the result of the callback. - - var receivedPromise = valueOrPromise && typeof valueOrPromise.then === "function"; - var nativePromise = receivedPromise && valueOrPromise instanceof Promise; - - if(!receivedPromise){ - if(arguments.length > 1){ - return callback ? callback(valueOrPromise) : valueOrPromise; - }else{ - return new Deferred().resolve(valueOrPromise); - } - }else if(!nativePromise){ - var deferred = new Deferred(valueOrPromise.cancel); - valueOrPromise.then(deferred.resolve, deferred.reject, deferred.progress); - valueOrPromise = deferred.promise; - } - - if(callback || errback || progback){ - return valueOrPromise.then(callback, errback, progback); - } - return valueOrPromise; - }; -}); diff --git a/lib/dojo/window.js b/lib/dojo/window.js deleted file mode 100644 index eb2f55f..0000000 --- a/lib/dojo/window.js +++ /dev/null @@ -1,146 +0,0 @@ -/* - Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved. - Available via Academic Free License >= 2.1 OR the modified BSD license. - see: http://dojotoolkit.org/license for details -*/ - -//>>built -define("dojo/window",["./_base/lang","./sniff","./_base/window","./dom","./dom-geometry","./dom-style","./dom-construct"],function(_1,_2,_3,_4,_5,_6,_7){ -_2.add("rtl-adjust-position-for-verticalScrollBar",function(_8,_9){ -var _a=_3.body(_9),_b=_7.create("div",{style:{overflow:"scroll",overflowX:"visible",direction:"rtl",visibility:"hidden",position:"absolute",left:"0",top:"0",width:"64px",height:"64px"}},_a,"last"),_c=_7.create("div",{style:{overflow:"hidden",direction:"ltr"}},_b,"last"),_d=_5.position(_c).x!=0; -_b.removeChild(_c); -_a.removeChild(_b); -return _d; -}); -_2.add("position-fixed-support",function(_e,_f){ -var _10=_3.body(_f),_11=_7.create("span",{style:{visibility:"hidden",position:"fixed",left:"1px",top:"1px"}},_10,"last"),_12=_7.create("span",{style:{position:"fixed",left:"0",top:"0"}},_11,"last"),ret=_5.position(_12).x!=_5.position(_11).x; -_11.removeChild(_12); -_10.removeChild(_11); -return ret; -}); -var _13={getBox:function(doc){ -doc=doc||_3.doc; -var _14=(doc.compatMode=="BackCompat")?_3.body(doc):doc.documentElement,_15=_5.docScroll(doc),w,h; -if(_2("touch")){ -var _16=_13.get(doc); -w=_16.innerWidth||_14.clientWidth; -h=_16.innerHeight||_14.clientHeight; -}else{ -w=_14.clientWidth; -h=_14.clientHeight; -} -return {l:_15.x,t:_15.y,w:w,h:h}; -},get:function(doc){ -if(_2("ie")&&_13!==document.parentWindow){ -doc.parentWindow.execScript("document._parentWindow = window;","Javascript"); -var win=doc._parentWindow; -doc._parentWindow=null; -return win; -} -return doc.parentWindow||doc.defaultView; -},scrollIntoView:function(_17,pos){ -try{ -_17=_4.byId(_17); -var doc=_17.ownerDocument||_3.doc,_18=_3.body(doc),_19=doc.documentElement||_18.parentNode,_1a=_2("ie"),_1b=_2("webkit"); -if(_17==_18||_17==_19){ -return; -} -if(!(_2("mozilla")||_1a||_1b||_2("opera")||_2("trident"))&&("scrollIntoView" in _17)){ -_17.scrollIntoView(false); -return; -} -var _1c=doc.compatMode=="BackCompat",_1d=Math.min(_18.clientWidth||_19.clientWidth,_19.clientWidth||_18.clientWidth),_1e=Math.min(_18.clientHeight||_19.clientHeight,_19.clientHeight||_18.clientHeight),_1f=(_1b||_1c)?_18:_19,_20=pos||_5.position(_17),el=_17.parentNode,_21=function(el){ -return (_1a<=6||(_1a==7&&_1c))?false:(_2("position-fixed-support")&&(_6.get(el,"position").toLowerCase()=="fixed")); -},_22=this,_23=function(el,x,y){ -if(el.tagName=="BODY"||el.tagName=="HTML"){ -_22.get(el.ownerDocument).scrollBy(x,y); -}else{ -x&&(el.scrollLeft+=x); -y&&(el.scrollTop+=y); -} -}; -if(_21(_17)){ -return; -} -while(el){ -if(el==_18){ -el=_1f; -} -var _24=_5.position(el),_25=_21(el),rtl=_6.getComputedStyle(el).direction.toLowerCase()=="rtl"; -if(el==_1f){ -_24.w=_1d; -_24.h=_1e; -if(_1f==_19&&_1a&&rtl){ -_24.x+=_1f.offsetWidth-_24.w; -} -if(_24.x<0||!_1a||_1a>=9){ -_24.x=0; -} -if(_24.y<0||!_1a||_1a>=9){ -_24.y=0; -} -}else{ -var pb=_5.getPadBorderExtents(el); -_24.w-=pb.w; -_24.h-=pb.h; -_24.x+=pb.l; -_24.y+=pb.t; -var _26=el.clientWidth,_27=_24.w-_26; -if(_26>0&&_27>0){ -if(rtl&&_2("rtl-adjust-position-for-verticalScrollBar")){ -_24.x+=_27; -} -_24.w=_26; -} -_26=el.clientHeight; -_27=_24.h-_26; -if(_26>0&&_27>0){ -_24.h=_26; -} -} -if(_25){ -if(_24.y<0){ -_24.h+=_24.y; -_24.y=0; -} -if(_24.x<0){ -_24.w+=_24.x; -_24.x=0; -} -if(_24.y+_24.h>_1e){ -_24.h=_1e-_24.y; -} -if(_24.x+_24.w>_1d){ -_24.w=_1d-_24.x; -} -} -var l=_20.x-_24.x,t=_20.y-_24.y,r=l+_20.w-_24.w,bot=t+_20.h-_24.h; -var s,old; -if(r*l>0&&(!!el.scrollLeft||el==_1f||el.scrollWidth>el.offsetHeight)){ -s=Math[l<0?"max":"min"](l,r); -if(rtl&&((_1a==8&&!_1c)||_1a>=9)){ -s=-s; -} -old=el.scrollLeft; -_23(el,s,0); -s=el.scrollLeft-old; -_20.x-=s; -} -if(bot*t>0&&(!!el.scrollTop||el==_1f||el.scrollHeight>el.offsetHeight)){ -s=Math.ceil(Math[t<0?"max":"min"](t,bot)); -old=el.scrollTop; -_23(el,0,s); -s=el.scrollTop-old; -_20.y-=s; -} -el=(el!=_1f)&&!_25&&el.parentNode; -} -} -catch(error){ -console.error("scrollIntoView: "+error); -_17.scrollIntoView(false); -} -}}; -1&&_1.setObject("dojo.window",_13); -return _13; -}); diff --git a/lib/dojo/window.js.uncompressed.js b/lib/dojo/window.js.uncompressed.js deleted file mode 100644 index eddd9d3..0000000 --- a/lib/dojo/window.js.uncompressed.js +++ /dev/null @@ -1,238 +0,0 @@ -define("dojo/window", ["./_base/lang", "./sniff", "./_base/window", "./dom", "./dom-geometry", "./dom-style", "./dom-construct"], - function(lang, has, baseWindow, dom, geom, style, domConstruct){ - - // feature detection - /* not needed but included here for future reference - has.add("rtl-innerVerticalScrollBar-on-left", function(win, doc){ - var body = baseWindow.body(doc), - scrollable = domConstruct.create('div', { - style: {overflow:'scroll', overflowX:'hidden', direction:'rtl', visibility:'hidden', position:'absolute', left:'0', width:'64px', height:'64px'} - }, body, "last"), - center = domConstruct.create('center', { - style: {overflow:'hidden', direction:'ltr'} - }, scrollable, "last"), - inner = domConstruct.create('div', { - style: {overflow:'visible', display:'inline' } - }, center, "last"); - inner.innerHTML=" "; - var midPoint = Math.max(inner.offsetLeft, geom.position(inner).x); - var ret = midPoint >= 32; - center.removeChild(inner); - scrollable.removeChild(center); - body.removeChild(scrollable); - return ret; - }); - */ - has.add("rtl-adjust-position-for-verticalScrollBar", function(win, doc){ - var body = baseWindow.body(doc), - scrollable = domConstruct.create('div', { - style: {overflow:'scroll', overflowX:'visible', direction:'rtl', visibility:'hidden', position:'absolute', left:'0', top:'0', width:'64px', height:'64px'} - }, body, "last"), - div = domConstruct.create('div', { - style: {overflow:'hidden', direction:'ltr'} - }, scrollable, "last"), - ret = geom.position(div).x != 0; - scrollable.removeChild(div); - body.removeChild(scrollable); - return ret; - }); - - has.add("position-fixed-support", function(win, doc){ - // IE6, IE7+quirks, and some older mobile browsers don't support position:fixed - var body = baseWindow.body(doc), - outer = domConstruct.create('span', { - style: {visibility:'hidden', position:'fixed', left:'1px', top:'1px'} - }, body, "last"), - inner = domConstruct.create('span', { - style: {position:'fixed', left:'0', top:'0'} - }, outer, "last"), - ret = geom.position(inner).x != geom.position(outer).x; - outer.removeChild(inner); - body.removeChild(outer); - return ret; - }); - - // module: - // dojo/window - - var window = { - // summary: - // TODOC - - getBox: function(/*Document?*/ doc){ - // summary: - // Returns the dimensions and scroll position of the viewable area of a browser window - - doc = doc || baseWindow.doc; - - var - scrollRoot = (doc.compatMode == 'BackCompat') ? baseWindow.body(doc) : doc.documentElement, - // get scroll position - scroll = geom.docScroll(doc), // scrollRoot.scrollTop/Left should work - w, h; - - if(has("touch")){ // if(scrollbars not supported) - var uiWindow = window.get(doc); // use UI window, not dojo.global window - // on mobile, scrollRoot.clientHeight <= uiWindow.innerHeight <= scrollRoot.offsetHeight, return uiWindow.innerHeight - w = uiWindow.innerWidth || scrollRoot.clientWidth; // || scrollRoot.clientXXX probably never evaluated - h = uiWindow.innerHeight || scrollRoot.clientHeight; - }else{ - // on desktops, scrollRoot.clientHeight <= scrollRoot.offsetHeight <= uiWindow.innerHeight, return scrollRoot.clientHeight - // uiWindow.innerWidth/Height includes the scrollbar and cannot be used - w = scrollRoot.clientWidth; - h = scrollRoot.clientHeight; - } - return { - l: scroll.x, - t: scroll.y, - w: w, - h: h - }; - }, - - get: function(/*Document*/ doc){ - // summary: - // Get window object associated with document doc. - // doc: - // The document to get the associated window for. - - // In some IE versions (at least 6.0), document.parentWindow does not return a - // reference to the real window object (maybe a copy), so we must fix it as well - // We use IE specific execScript to attach the real window reference to - // document._parentWindow for later use - if(has("ie") && window !== document.parentWindow){ - /* - In IE 6, only the variable "window" can be used to connect events (others - may be only copies). - */ - doc.parentWindow.execScript("document._parentWindow = window;", "Javascript"); - //to prevent memory leak, unset it after use - //another possibility is to add an onUnload handler which seems overkill to me (liucougar) - var win = doc._parentWindow; - doc._parentWindow = null; - return win; // Window - } - - return doc.parentWindow || doc.defaultView; // Window - }, - - scrollIntoView: function(/*DomNode*/ node, /*Object?*/ pos){ - // summary: - // Scroll the passed node into view using minimal movement, if it is not already. - - // Don't rely on node.scrollIntoView working just because the function is there since - // it forces the node to the page's bottom or top (and left or right in IE) without consideration for the minimal movement. - // WebKit's node.scrollIntoViewIfNeeded doesn't work either for inner scrollbars in right-to-left mode - // and when there's a fixed position scrollable element - - try{ // catch unexpected/unrecreatable errors (#7808) since we can recover using a semi-acceptable native method - node = dom.byId(node); - var doc = node.ownerDocument || baseWindow.doc, // TODO: why baseWindow.doc? Isn't node.ownerDocument always defined? - body = baseWindow.body(doc), - html = doc.documentElement || body.parentNode, - isIE = has("ie"), - isWK = has("webkit"); - // if an untested browser, then use the native method - if(node == body || node == html){ return; } - if(!(has("mozilla") || isIE || isWK || has("opera") || has("trident")) && ("scrollIntoView" in node)){ - node.scrollIntoView(false); // short-circuit to native if possible - return; - } - var backCompat = doc.compatMode == 'BackCompat', - rootWidth = Math.min(body.clientWidth || html.clientWidth, html.clientWidth || body.clientWidth), - rootHeight = Math.min(body.clientHeight || html.clientHeight, html.clientHeight || body.clientHeight), - scrollRoot = (isWK || backCompat) ? body : html, - nodePos = pos || geom.position(node), - el = node.parentNode, - isFixed = function(el){ - return (isIE <= 6 || (isIE == 7 && backCompat)) - ? false - : (has("position-fixed-support") && (style.get(el, 'position').toLowerCase() == "fixed")); - }, - self = this, - scrollElementBy = function(el, x, y){ - if(el.tagName == "BODY" || el.tagName == "HTML"){ - self.get(el.ownerDocument).scrollBy(x, y); - }else{ - x && (el.scrollLeft += x); - y && (el.scrollTop += y); - } - }; - if(isFixed(node)){ return; } // nothing to do - while(el){ - if(el == body){ el = scrollRoot; } - var elPos = geom.position(el), - fixedPos = isFixed(el), - rtl = style.getComputedStyle(el).direction.toLowerCase() == "rtl"; - - if(el == scrollRoot){ - elPos.w = rootWidth; elPos.h = rootHeight; - if(scrollRoot == html && isIE && rtl){ elPos.x += scrollRoot.offsetWidth-elPos.w; } // IE workaround where scrollbar causes negative x - if(elPos.x < 0 || !isIE || isIE >= 9){ elPos.x = 0; } // older IE can have values > 0 - if(elPos.y < 0 || !isIE || isIE >= 9){ elPos.y = 0; } - }else{ - var pb = geom.getPadBorderExtents(el); - elPos.w -= pb.w; elPos.h -= pb.h; elPos.x += pb.l; elPos.y += pb.t; - var clientSize = el.clientWidth, - scrollBarSize = elPos.w - clientSize; - if(clientSize > 0 && scrollBarSize > 0){ - if(rtl && has("rtl-adjust-position-for-verticalScrollBar")){ - elPos.x += scrollBarSize; - } - elPos.w = clientSize; - } - clientSize = el.clientHeight; - scrollBarSize = elPos.h - clientSize; - if(clientSize > 0 && scrollBarSize > 0){ - elPos.h = clientSize; - } - } - if(fixedPos){ // bounded by viewport, not parents - if(elPos.y < 0){ - elPos.h += elPos.y; elPos.y = 0; - } - if(elPos.x < 0){ - elPos.w += elPos.x; elPos.x = 0; - } - if(elPos.y + elPos.h > rootHeight){ - elPos.h = rootHeight - elPos.y; - } - if(elPos.x + elPos.w > rootWidth){ - elPos.w = rootWidth - elPos.x; - } - } - // calculate overflow in all 4 directions - var l = nodePos.x - elPos.x, // beyond left: < 0 -// t = nodePos.y - Math.max(elPos.y, 0), // beyond top: < 0 - t = nodePos.y - elPos.y, // beyond top: < 0 - r = l + nodePos.w - elPos.w, // beyond right: > 0 - bot = t + nodePos.h - elPos.h; // beyond bottom: > 0 - var s, old; - if(r * l > 0 && (!!el.scrollLeft || el == scrollRoot || el.scrollWidth > el.offsetHeight)){ - s = Math[l < 0? "max" : "min"](l, r); - if(rtl && ((isIE == 8 && !backCompat) || isIE >= 9)){ s = -s; } - old = el.scrollLeft; - scrollElementBy(el, s, 0); - s = el.scrollLeft - old; - nodePos.x -= s; - } - if(bot * t > 0 && (!!el.scrollTop || el == scrollRoot || el.scrollHeight > el.offsetHeight)){ - s = Math.ceil(Math[t < 0? "max" : "min"](t, bot)); - old = el.scrollTop; - scrollElementBy(el, 0, s); - s = el.scrollTop - old; - nodePos.y -= s; - } - el = (el != scrollRoot) && !fixedPos && el.parentNode; - } - }catch(error){ - console.error('scrollIntoView: ' + error); - node.scrollIntoView(false); - } - } - }; - - 1 && lang.setObject("dojo.window", window); - - return window; -}); diff --git a/lib/jquery/jquery-1.11.0.min.js b/lib/jquery/jquery-1.11.0.min.js deleted file mode 100644 index 73f33fb..0000000 --- a/lib/jquery/jquery-1.11.0.min.js +++ /dev/null @@ -1,4 +0,0 @@ -/*! jQuery v1.11.0 | (c) 2005, 2014 jQuery Foundation, Inc. | jquery.org/license */ -!function(a,b){"object"==typeof module&&"object"==typeof module.exports?module.exports=a.document?b(a,!0):function(a){if(!a.document)throw new Error("jQuery requires a window with a document");return b(a)}:b(a)}("undefined"!=typeof window?window:this,function(a,b){var c=[],d=c.slice,e=c.concat,f=c.push,g=c.indexOf,h={},i=h.toString,j=h.hasOwnProperty,k="".trim,l={},m="1.11.0",n=function(a,b){return new n.fn.init(a,b)},o=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,p=/^-ms-/,q=/-([\da-z])/gi,r=function(a,b){return b.toUpperCase()};n.fn=n.prototype={jquery:m,constructor:n,selector:"",length:0,toArray:function(){return d.call(this)},get:function(a){return null!=a?0>a?this[a+this.length]:this[a]:d.call(this)},pushStack:function(a){var b=n.merge(this.constructor(),a);return b.prevObject=this,b.context=this.context,b},each:function(a,b){return n.each(this,a,b)},map:function(a){return this.pushStack(n.map(this,function(b,c){return a.call(b,c,b)}))},slice:function(){return this.pushStack(d.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},eq:function(a){var b=this.length,c=+a+(0>a?b:0);return this.pushStack(c>=0&&b>c?[this[c]]:[])},end:function(){return this.prevObject||this.constructor(null)},push:f,sort:c.sort,splice:c.splice},n.extend=n.fn.extend=function(){var a,b,c,d,e,f,g=arguments[0]||{},h=1,i=arguments.length,j=!1;for("boolean"==typeof g&&(j=g,g=arguments[h]||{},h++),"object"==typeof g||n.isFunction(g)||(g={}),h===i&&(g=this,h--);i>h;h++)if(null!=(e=arguments[h]))for(d in e)a=g[d],c=e[d],g!==c&&(j&&c&&(n.isPlainObject(c)||(b=n.isArray(c)))?(b?(b=!1,f=a&&n.isArray(a)?a:[]):f=a&&n.isPlainObject(a)?a:{},g[d]=n.extend(j,f,c)):void 0!==c&&(g[d]=c));return g},n.extend({expando:"jQuery"+(m+Math.random()).replace(/\D/g,""),isReady:!0,error:function(a){throw new Error(a)},noop:function(){},isFunction:function(a){return"function"===n.type(a)},isArray:Array.isArray||function(a){return"array"===n.type(a)},isWindow:function(a){return null!=a&&a==a.window},isNumeric:function(a){return a-parseFloat(a)>=0},isEmptyObject:function(a){var b;for(b in a)return!1;return!0},isPlainObject:function(a){var b;if(!a||"object"!==n.type(a)||a.nodeType||n.isWindow(a))return!1;try{if(a.constructor&&!j.call(a,"constructor")&&!j.call(a.constructor.prototype,"isPrototypeOf"))return!1}catch(c){return!1}if(l.ownLast)for(b in a)return j.call(a,b);for(b in a);return void 0===b||j.call(a,b)},type:function(a){return null==a?a+"":"object"==typeof a||"function"==typeof a?h[i.call(a)]||"object":typeof a},globalEval:function(b){b&&n.trim(b)&&(a.execScript||function(b){a.eval.call(a,b)})(b)},camelCase:function(a){return a.replace(p,"ms-").replace(q,r)},nodeName:function(a,b){return a.nodeName&&a.nodeName.toLowerCase()===b.toLowerCase()},each:function(a,b,c){var d,e=0,f=a.length,g=s(a);if(c){if(g){for(;f>e;e++)if(d=b.apply(a[e],c),d===!1)break}else for(e in a)if(d=b.apply(a[e],c),d===!1)break}else if(g){for(;f>e;e++)if(d=b.call(a[e],e,a[e]),d===!1)break}else for(e in a)if(d=b.call(a[e],e,a[e]),d===!1)break;return a},trim:k&&!k.call("\ufeff\xa0")?function(a){return null==a?"":k.call(a)}:function(a){return null==a?"":(a+"").replace(o,"")},makeArray:function(a,b){var c=b||[];return null!=a&&(s(Object(a))?n.merge(c,"string"==typeof a?[a]:a):f.call(c,a)),c},inArray:function(a,b,c){var d;if(b){if(g)return g.call(b,a,c);for(d=b.length,c=c?0>c?Math.max(0,d+c):c:0;d>c;c++)if(c in b&&b[c]===a)return c}return-1},merge:function(a,b){var c=+b.length,d=0,e=a.length;while(c>d)a[e++]=b[d++];if(c!==c)while(void 0!==b[d])a[e++]=b[d++];return a.length=e,a},grep:function(a,b,c){for(var d,e=[],f=0,g=a.length,h=!c;g>f;f++)d=!b(a[f],f),d!==h&&e.push(a[f]);return e},map:function(a,b,c){var d,f=0,g=a.length,h=s(a),i=[];if(h)for(;g>f;f++)d=b(a[f],f,c),null!=d&&i.push(d);else for(f in a)d=b(a[f],f,c),null!=d&&i.push(d);return e.apply([],i)},guid:1,proxy:function(a,b){var c,e,f;return"string"==typeof b&&(f=a[b],b=a,a=f),n.isFunction(a)?(c=d.call(arguments,2),e=function(){return a.apply(b||this,c.concat(d.call(arguments)))},e.guid=a.guid=a.guid||n.guid++,e):void 0},now:function(){return+new Date},support:l}),n.each("Boolean Number String Function Array Date RegExp Object Error".split(" "),function(a,b){h["[object "+b+"]"]=b.toLowerCase()});function s(a){var b=a.length,c=n.type(a);return"function"===c||n.isWindow(a)?!1:1===a.nodeType&&b?!0:"array"===c||0===b||"number"==typeof b&&b>0&&b-1 in a}var t=function(a){var b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s="sizzle"+-new Date,t=a.document,u=0,v=0,w=eb(),x=eb(),y=eb(),z=function(a,b){return a===b&&(j=!0),0},A="undefined",B=1<<31,C={}.hasOwnProperty,D=[],E=D.pop,F=D.push,G=D.push,H=D.slice,I=D.indexOf||function(a){for(var b=0,c=this.length;c>b;b++)if(this[b]===a)return b;return-1},J="checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",K="[\\x20\\t\\r\\n\\f]",L="(?:\\\\.|[\\w-]|[^\\x00-\\xa0])+",M=L.replace("w","w#"),N="\\["+K+"*("+L+")"+K+"*(?:([*^$|!~]?=)"+K+"*(?:(['\"])((?:\\\\.|[^\\\\])*?)\\3|("+M+")|)|)"+K+"*\\]",O=":("+L+")(?:\\(((['\"])((?:\\\\.|[^\\\\])*?)\\3|((?:\\\\.|[^\\\\()[\\]]|"+N.replace(3,8)+")*)|.*)\\)|)",P=new RegExp("^"+K+"+|((?:^|[^\\\\])(?:\\\\.)*)"+K+"+$","g"),Q=new RegExp("^"+K+"*,"+K+"*"),R=new RegExp("^"+K+"*([>+~]|"+K+")"+K+"*"),S=new RegExp("="+K+"*([^\\]'\"]*?)"+K+"*\\]","g"),T=new RegExp(O),U=new RegExp("^"+M+"$"),V={ID:new RegExp("^#("+L+")"),CLASS:new RegExp("^\\.("+L+")"),TAG:new RegExp("^("+L.replace("w","w*")+")"),ATTR:new RegExp("^"+N),PSEUDO:new RegExp("^"+O),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+K+"*(even|odd|(([+-]|)(\\d*)n|)"+K+"*(?:([+-]|)"+K+"*(\\d+)|))"+K+"*\\)|)","i"),bool:new RegExp("^(?:"+J+")$","i"),needsContext:new RegExp("^"+K+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+K+"*((?:-\\d)?\\d*)"+K+"*\\)|)(?=[^-]|$)","i")},W=/^(?:input|select|textarea|button)$/i,X=/^h\d$/i,Y=/^[^{]+\{\s*\[native \w/,Z=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,$=/[+~]/,_=/'|\\/g,ab=new RegExp("\\\\([\\da-f]{1,6}"+K+"?|("+K+")|.)","ig"),bb=function(a,b,c){var d="0x"+b-65536;return d!==d||c?b:0>d?String.fromCharCode(d+65536):String.fromCharCode(d>>10|55296,1023&d|56320)};try{G.apply(D=H.call(t.childNodes),t.childNodes),D[t.childNodes.length].nodeType}catch(cb){G={apply:D.length?function(a,b){F.apply(a,H.call(b))}:function(a,b){var c=a.length,d=0;while(a[c++]=b[d++]);a.length=c-1}}}function db(a,b,d,e){var f,g,h,i,j,m,p,q,u,v;if((b?b.ownerDocument||b:t)!==l&&k(b),b=b||l,d=d||[],!a||"string"!=typeof a)return d;if(1!==(i=b.nodeType)&&9!==i)return[];if(n&&!e){if(f=Z.exec(a))if(h=f[1]){if(9===i){if(g=b.getElementById(h),!g||!g.parentNode)return d;if(g.id===h)return d.push(g),d}else if(b.ownerDocument&&(g=b.ownerDocument.getElementById(h))&&r(b,g)&&g.id===h)return d.push(g),d}else{if(f[2])return G.apply(d,b.getElementsByTagName(a)),d;if((h=f[3])&&c.getElementsByClassName&&b.getElementsByClassName)return G.apply(d,b.getElementsByClassName(h)),d}if(c.qsa&&(!o||!o.test(a))){if(q=p=s,u=b,v=9===i&&a,1===i&&"object"!==b.nodeName.toLowerCase()){m=ob(a),(p=b.getAttribute("id"))?q=p.replace(_,"\\$&"):b.setAttribute("id",q),q="[id='"+q+"'] ",j=m.length;while(j--)m[j]=q+pb(m[j]);u=$.test(a)&&mb(b.parentNode)||b,v=m.join(",")}if(v)try{return G.apply(d,u.querySelectorAll(v)),d}catch(w){}finally{p||b.removeAttribute("id")}}}return xb(a.replace(P,"$1"),b,d,e)}function eb(){var a=[];function b(c,e){return a.push(c+" ")>d.cacheLength&&delete b[a.shift()],b[c+" "]=e}return b}function fb(a){return a[s]=!0,a}function gb(a){var b=l.createElement("div");try{return!!a(b)}catch(c){return!1}finally{b.parentNode&&b.parentNode.removeChild(b),b=null}}function hb(a,b){var c=a.split("|"),e=a.length;while(e--)d.attrHandle[c[e]]=b}function ib(a,b){var c=b&&a,d=c&&1===a.nodeType&&1===b.nodeType&&(~b.sourceIndex||B)-(~a.sourceIndex||B);if(d)return d;if(c)while(c=c.nextSibling)if(c===b)return-1;return a?1:-1}function jb(a){return function(b){var c=b.nodeName.toLowerCase();return"input"===c&&b.type===a}}function kb(a){return function(b){var c=b.nodeName.toLowerCase();return("input"===c||"button"===c)&&b.type===a}}function lb(a){return fb(function(b){return b=+b,fb(function(c,d){var e,f=a([],c.length,b),g=f.length;while(g--)c[e=f[g]]&&(c[e]=!(d[e]=c[e]))})})}function mb(a){return a&&typeof a.getElementsByTagName!==A&&a}c=db.support={},f=db.isXML=function(a){var b=a&&(a.ownerDocument||a).documentElement;return b?"HTML"!==b.nodeName:!1},k=db.setDocument=function(a){var b,e=a?a.ownerDocument||a:t,g=e.defaultView;return e!==l&&9===e.nodeType&&e.documentElement?(l=e,m=e.documentElement,n=!f(e),g&&g!==g.top&&(g.addEventListener?g.addEventListener("unload",function(){k()},!1):g.attachEvent&&g.attachEvent("onunload",function(){k()})),c.attributes=gb(function(a){return a.className="i",!a.getAttribute("className")}),c.getElementsByTagName=gb(function(a){return a.appendChild(e.createComment("")),!a.getElementsByTagName("*").length}),c.getElementsByClassName=Y.test(e.getElementsByClassName)&&gb(function(a){return a.innerHTML="
    ",a.firstChild.className="i",2===a.getElementsByClassName("i").length}),c.getById=gb(function(a){return m.appendChild(a).id=s,!e.getElementsByName||!e.getElementsByName(s).length}),c.getById?(d.find.ID=function(a,b){if(typeof b.getElementById!==A&&n){var c=b.getElementById(a);return c&&c.parentNode?[c]:[]}},d.filter.ID=function(a){var b=a.replace(ab,bb);return function(a){return a.getAttribute("id")===b}}):(delete d.find.ID,d.filter.ID=function(a){var b=a.replace(ab,bb);return function(a){var c=typeof a.getAttributeNode!==A&&a.getAttributeNode("id");return c&&c.value===b}}),d.find.TAG=c.getElementsByTagName?function(a,b){return typeof b.getElementsByTagName!==A?b.getElementsByTagName(a):void 0}:function(a,b){var c,d=[],e=0,f=b.getElementsByTagName(a);if("*"===a){while(c=f[e++])1===c.nodeType&&d.push(c);return d}return f},d.find.CLASS=c.getElementsByClassName&&function(a,b){return typeof b.getElementsByClassName!==A&&n?b.getElementsByClassName(a):void 0},p=[],o=[],(c.qsa=Y.test(e.querySelectorAll))&&(gb(function(a){a.innerHTML="",a.querySelectorAll("[t^='']").length&&o.push("[*^$]="+K+"*(?:''|\"\")"),a.querySelectorAll("[selected]").length||o.push("\\["+K+"*(?:value|"+J+")"),a.querySelectorAll(":checked").length||o.push(":checked")}),gb(function(a){var b=e.createElement("input");b.setAttribute("type","hidden"),a.appendChild(b).setAttribute("name","D"),a.querySelectorAll("[name=d]").length&&o.push("name"+K+"*[*^$|!~]?="),a.querySelectorAll(":enabled").length||o.push(":enabled",":disabled"),a.querySelectorAll("*,:x"),o.push(",.*:")})),(c.matchesSelector=Y.test(q=m.webkitMatchesSelector||m.mozMatchesSelector||m.oMatchesSelector||m.msMatchesSelector))&&gb(function(a){c.disconnectedMatch=q.call(a,"div"),q.call(a,"[s!='']:x"),p.push("!=",O)}),o=o.length&&new RegExp(o.join("|")),p=p.length&&new RegExp(p.join("|")),b=Y.test(m.compareDocumentPosition),r=b||Y.test(m.contains)?function(a,b){var c=9===a.nodeType?a.documentElement:a,d=b&&b.parentNode;return a===d||!(!d||1!==d.nodeType||!(c.contains?c.contains(d):a.compareDocumentPosition&&16&a.compareDocumentPosition(d)))}:function(a,b){if(b)while(b=b.parentNode)if(b===a)return!0;return!1},z=b?function(a,b){if(a===b)return j=!0,0;var d=!a.compareDocumentPosition-!b.compareDocumentPosition;return d?d:(d=(a.ownerDocument||a)===(b.ownerDocument||b)?a.compareDocumentPosition(b):1,1&d||!c.sortDetached&&b.compareDocumentPosition(a)===d?a===e||a.ownerDocument===t&&r(t,a)?-1:b===e||b.ownerDocument===t&&r(t,b)?1:i?I.call(i,a)-I.call(i,b):0:4&d?-1:1)}:function(a,b){if(a===b)return j=!0,0;var c,d=0,f=a.parentNode,g=b.parentNode,h=[a],k=[b];if(!f||!g)return a===e?-1:b===e?1:f?-1:g?1:i?I.call(i,a)-I.call(i,b):0;if(f===g)return ib(a,b);c=a;while(c=c.parentNode)h.unshift(c);c=b;while(c=c.parentNode)k.unshift(c);while(h[d]===k[d])d++;return d?ib(h[d],k[d]):h[d]===t?-1:k[d]===t?1:0},e):l},db.matches=function(a,b){return db(a,null,null,b)},db.matchesSelector=function(a,b){if((a.ownerDocument||a)!==l&&k(a),b=b.replace(S,"='$1']"),!(!c.matchesSelector||!n||p&&p.test(b)||o&&o.test(b)))try{var d=q.call(a,b);if(d||c.disconnectedMatch||a.document&&11!==a.document.nodeType)return d}catch(e){}return db(b,l,null,[a]).length>0},db.contains=function(a,b){return(a.ownerDocument||a)!==l&&k(a),r(a,b)},db.attr=function(a,b){(a.ownerDocument||a)!==l&&k(a);var e=d.attrHandle[b.toLowerCase()],f=e&&C.call(d.attrHandle,b.toLowerCase())?e(a,b,!n):void 0;return void 0!==f?f:c.attributes||!n?a.getAttribute(b):(f=a.getAttributeNode(b))&&f.specified?f.value:null},db.error=function(a){throw new Error("Syntax error, unrecognized expression: "+a)},db.uniqueSort=function(a){var b,d=[],e=0,f=0;if(j=!c.detectDuplicates,i=!c.sortStable&&a.slice(0),a.sort(z),j){while(b=a[f++])b===a[f]&&(e=d.push(f));while(e--)a.splice(d[e],1)}return i=null,a},e=db.getText=function(a){var b,c="",d=0,f=a.nodeType;if(f){if(1===f||9===f||11===f){if("string"==typeof a.textContent)return a.textContent;for(a=a.firstChild;a;a=a.nextSibling)c+=e(a)}else if(3===f||4===f)return a.nodeValue}else while(b=a[d++])c+=e(b);return c},d=db.selectors={cacheLength:50,createPseudo:fb,match:V,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(a){return a[1]=a[1].replace(ab,bb),a[3]=(a[4]||a[5]||"").replace(ab,bb),"~="===a[2]&&(a[3]=" "+a[3]+" "),a.slice(0,4)},CHILD:function(a){return a[1]=a[1].toLowerCase(),"nth"===a[1].slice(0,3)?(a[3]||db.error(a[0]),a[4]=+(a[4]?a[5]+(a[6]||1):2*("even"===a[3]||"odd"===a[3])),a[5]=+(a[7]+a[8]||"odd"===a[3])):a[3]&&db.error(a[0]),a},PSEUDO:function(a){var b,c=!a[5]&&a[2];return V.CHILD.test(a[0])?null:(a[3]&&void 0!==a[4]?a[2]=a[4]:c&&T.test(c)&&(b=ob(c,!0))&&(b=c.indexOf(")",c.length-b)-c.length)&&(a[0]=a[0].slice(0,b),a[2]=c.slice(0,b)),a.slice(0,3))}},filter:{TAG:function(a){var b=a.replace(ab,bb).toLowerCase();return"*"===a?function(){return!0}:function(a){return a.nodeName&&a.nodeName.toLowerCase()===b}},CLASS:function(a){var b=w[a+" "];return b||(b=new RegExp("(^|"+K+")"+a+"("+K+"|$)"))&&w(a,function(a){return b.test("string"==typeof a.className&&a.className||typeof a.getAttribute!==A&&a.getAttribute("class")||"")})},ATTR:function(a,b,c){return function(d){var e=db.attr(d,a);return null==e?"!="===b:b?(e+="","="===b?e===c:"!="===b?e!==c:"^="===b?c&&0===e.indexOf(c):"*="===b?c&&e.indexOf(c)>-1:"$="===b?c&&e.slice(-c.length)===c:"~="===b?(" "+e+" ").indexOf(c)>-1:"|="===b?e===c||e.slice(0,c.length+1)===c+"-":!1):!0}},CHILD:function(a,b,c,d,e){var f="nth"!==a.slice(0,3),g="last"!==a.slice(-4),h="of-type"===b;return 1===d&&0===e?function(a){return!!a.parentNode}:function(b,c,i){var j,k,l,m,n,o,p=f!==g?"nextSibling":"previousSibling",q=b.parentNode,r=h&&b.nodeName.toLowerCase(),t=!i&&!h;if(q){if(f){while(p){l=b;while(l=l[p])if(h?l.nodeName.toLowerCase()===r:1===l.nodeType)return!1;o=p="only"===a&&!o&&"nextSibling"}return!0}if(o=[g?q.firstChild:q.lastChild],g&&t){k=q[s]||(q[s]={}),j=k[a]||[],n=j[0]===u&&j[1],m=j[0]===u&&j[2],l=n&&q.childNodes[n];while(l=++n&&l&&l[p]||(m=n=0)||o.pop())if(1===l.nodeType&&++m&&l===b){k[a]=[u,n,m];break}}else if(t&&(j=(b[s]||(b[s]={}))[a])&&j[0]===u)m=j[1];else while(l=++n&&l&&l[p]||(m=n=0)||o.pop())if((h?l.nodeName.toLowerCase()===r:1===l.nodeType)&&++m&&(t&&((l[s]||(l[s]={}))[a]=[u,m]),l===b))break;return m-=e,m===d||m%d===0&&m/d>=0}}},PSEUDO:function(a,b){var c,e=d.pseudos[a]||d.setFilters[a.toLowerCase()]||db.error("unsupported pseudo: "+a);return e[s]?e(b):e.length>1?(c=[a,a,"",b],d.setFilters.hasOwnProperty(a.toLowerCase())?fb(function(a,c){var d,f=e(a,b),g=f.length;while(g--)d=I.call(a,f[g]),a[d]=!(c[d]=f[g])}):function(a){return e(a,0,c)}):e}},pseudos:{not:fb(function(a){var b=[],c=[],d=g(a.replace(P,"$1"));return d[s]?fb(function(a,b,c,e){var f,g=d(a,null,e,[]),h=a.length;while(h--)(f=g[h])&&(a[h]=!(b[h]=f))}):function(a,e,f){return b[0]=a,d(b,null,f,c),!c.pop()}}),has:fb(function(a){return function(b){return db(a,b).length>0}}),contains:fb(function(a){return function(b){return(b.textContent||b.innerText||e(b)).indexOf(a)>-1}}),lang:fb(function(a){return U.test(a||"")||db.error("unsupported lang: "+a),a=a.replace(ab,bb).toLowerCase(),function(b){var c;do if(c=n?b.lang:b.getAttribute("xml:lang")||b.getAttribute("lang"))return c=c.toLowerCase(),c===a||0===c.indexOf(a+"-");while((b=b.parentNode)&&1===b.nodeType);return!1}}),target:function(b){var c=a.location&&a.location.hash;return c&&c.slice(1)===b.id},root:function(a){return a===m},focus:function(a){return a===l.activeElement&&(!l.hasFocus||l.hasFocus())&&!!(a.type||a.href||~a.tabIndex)},enabled:function(a){return a.disabled===!1},disabled:function(a){return a.disabled===!0},checked:function(a){var b=a.nodeName.toLowerCase();return"input"===b&&!!a.checked||"option"===b&&!!a.selected},selected:function(a){return a.parentNode&&a.parentNode.selectedIndex,a.selected===!0},empty:function(a){for(a=a.firstChild;a;a=a.nextSibling)if(a.nodeType<6)return!1;return!0},parent:function(a){return!d.pseudos.empty(a)},header:function(a){return X.test(a.nodeName)},input:function(a){return W.test(a.nodeName)},button:function(a){var b=a.nodeName.toLowerCase();return"input"===b&&"button"===a.type||"button"===b},text:function(a){var b;return"input"===a.nodeName.toLowerCase()&&"text"===a.type&&(null==(b=a.getAttribute("type"))||"text"===b.toLowerCase())},first:lb(function(){return[0]}),last:lb(function(a,b){return[b-1]}),eq:lb(function(a,b,c){return[0>c?c+b:c]}),even:lb(function(a,b){for(var c=0;b>c;c+=2)a.push(c);return a}),odd:lb(function(a,b){for(var c=1;b>c;c+=2)a.push(c);return a}),lt:lb(function(a,b,c){for(var d=0>c?c+b:c;--d>=0;)a.push(d);return a}),gt:lb(function(a,b,c){for(var d=0>c?c+b:c;++db;b++)d+=a[b].value;return d}function qb(a,b,c){var d=b.dir,e=c&&"parentNode"===d,f=v++;return b.first?function(b,c,f){while(b=b[d])if(1===b.nodeType||e)return a(b,c,f)}:function(b,c,g){var h,i,j=[u,f];if(g){while(b=b[d])if((1===b.nodeType||e)&&a(b,c,g))return!0}else while(b=b[d])if(1===b.nodeType||e){if(i=b[s]||(b[s]={}),(h=i[d])&&h[0]===u&&h[1]===f)return j[2]=h[2];if(i[d]=j,j[2]=a(b,c,g))return!0}}}function rb(a){return a.length>1?function(b,c,d){var e=a.length;while(e--)if(!a[e](b,c,d))return!1;return!0}:a[0]}function sb(a,b,c,d,e){for(var f,g=[],h=0,i=a.length,j=null!=b;i>h;h++)(f=a[h])&&(!c||c(f,d,e))&&(g.push(f),j&&b.push(h));return g}function tb(a,b,c,d,e,f){return d&&!d[s]&&(d=tb(d)),e&&!e[s]&&(e=tb(e,f)),fb(function(f,g,h,i){var j,k,l,m=[],n=[],o=g.length,p=f||wb(b||"*",h.nodeType?[h]:h,[]),q=!a||!f&&b?p:sb(p,m,a,h,i),r=c?e||(f?a:o||d)?[]:g:q;if(c&&c(q,r,h,i),d){j=sb(r,n),d(j,[],h,i),k=j.length;while(k--)(l=j[k])&&(r[n[k]]=!(q[n[k]]=l))}if(f){if(e||a){if(e){j=[],k=r.length;while(k--)(l=r[k])&&j.push(q[k]=l);e(null,r=[],j,i)}k=r.length;while(k--)(l=r[k])&&(j=e?I.call(f,l):m[k])>-1&&(f[j]=!(g[j]=l))}}else r=sb(r===g?r.splice(o,r.length):r),e?e(null,g,r,i):G.apply(g,r)})}function ub(a){for(var b,c,e,f=a.length,g=d.relative[a[0].type],i=g||d.relative[" "],j=g?1:0,k=qb(function(a){return a===b},i,!0),l=qb(function(a){return I.call(b,a)>-1},i,!0),m=[function(a,c,d){return!g&&(d||c!==h)||((b=c).nodeType?k(a,c,d):l(a,c,d))}];f>j;j++)if(c=d.relative[a[j].type])m=[qb(rb(m),c)];else{if(c=d.filter[a[j].type].apply(null,a[j].matches),c[s]){for(e=++j;f>e;e++)if(d.relative[a[e].type])break;return tb(j>1&&rb(m),j>1&&pb(a.slice(0,j-1).concat({value:" "===a[j-2].type?"*":""})).replace(P,"$1"),c,e>j&&ub(a.slice(j,e)),f>e&&ub(a=a.slice(e)),f>e&&pb(a))}m.push(c)}return rb(m)}function vb(a,b){var c=b.length>0,e=a.length>0,f=function(f,g,i,j,k){var m,n,o,p=0,q="0",r=f&&[],s=[],t=h,v=f||e&&d.find.TAG("*",k),w=u+=null==t?1:Math.random()||.1,x=v.length;for(k&&(h=g!==l&&g);q!==x&&null!=(m=v[q]);q++){if(e&&m){n=0;while(o=a[n++])if(o(m,g,i)){j.push(m);break}k&&(u=w)}c&&((m=!o&&m)&&p--,f&&r.push(m))}if(p+=q,c&&q!==p){n=0;while(o=b[n++])o(r,s,g,i);if(f){if(p>0)while(q--)r[q]||s[q]||(s[q]=E.call(j));s=sb(s)}G.apply(j,s),k&&!f&&s.length>0&&p+b.length>1&&db.uniqueSort(j)}return k&&(u=w,h=t),r};return c?fb(f):f}g=db.compile=function(a,b){var c,d=[],e=[],f=y[a+" "];if(!f){b||(b=ob(a)),c=b.length;while(c--)f=ub(b[c]),f[s]?d.push(f):e.push(f);f=y(a,vb(e,d))}return f};function wb(a,b,c){for(var d=0,e=b.length;e>d;d++)db(a,b[d],c);return c}function xb(a,b,e,f){var h,i,j,k,l,m=ob(a);if(!f&&1===m.length){if(i=m[0]=m[0].slice(0),i.length>2&&"ID"===(j=i[0]).type&&c.getById&&9===b.nodeType&&n&&d.relative[i[1].type]){if(b=(d.find.ID(j.matches[0].replace(ab,bb),b)||[])[0],!b)return e;a=a.slice(i.shift().value.length)}h=V.needsContext.test(a)?0:i.length;while(h--){if(j=i[h],d.relative[k=j.type])break;if((l=d.find[k])&&(f=l(j.matches[0].replace(ab,bb),$.test(i[0].type)&&mb(b.parentNode)||b))){if(i.splice(h,1),a=f.length&&pb(i),!a)return G.apply(e,f),e;break}}}return g(a,m)(f,b,!n,e,$.test(a)&&mb(b.parentNode)||b),e}return c.sortStable=s.split("").sort(z).join("")===s,c.detectDuplicates=!!j,k(),c.sortDetached=gb(function(a){return 1&a.compareDocumentPosition(l.createElement("div"))}),gb(function(a){return a.innerHTML="","#"===a.firstChild.getAttribute("href")})||hb("type|href|height|width",function(a,b,c){return c?void 0:a.getAttribute(b,"type"===b.toLowerCase()?1:2)}),c.attributes&&gb(function(a){return a.innerHTML="",a.firstChild.setAttribute("value",""),""===a.firstChild.getAttribute("value")})||hb("value",function(a,b,c){return c||"input"!==a.nodeName.toLowerCase()?void 0:a.defaultValue}),gb(function(a){return null==a.getAttribute("disabled")})||hb(J,function(a,b,c){var d;return c?void 0:a[b]===!0?b.toLowerCase():(d=a.getAttributeNode(b))&&d.specified?d.value:null}),db}(a);n.find=t,n.expr=t.selectors,n.expr[":"]=n.expr.pseudos,n.unique=t.uniqueSort,n.text=t.getText,n.isXMLDoc=t.isXML,n.contains=t.contains;var u=n.expr.match.needsContext,v=/^<(\w+)\s*\/?>(?:<\/\1>|)$/,w=/^.[^:#\[\.,]*$/;function x(a,b,c){if(n.isFunction(b))return n.grep(a,function(a,d){return!!b.call(a,d,a)!==c});if(b.nodeType)return n.grep(a,function(a){return a===b!==c});if("string"==typeof b){if(w.test(b))return n.filter(b,a,c);b=n.filter(b,a)}return n.grep(a,function(a){return n.inArray(a,b)>=0!==c})}n.filter=function(a,b,c){var d=b[0];return c&&(a=":not("+a+")"),1===b.length&&1===d.nodeType?n.find.matchesSelector(d,a)?[d]:[]:n.find.matches(a,n.grep(b,function(a){return 1===a.nodeType}))},n.fn.extend({find:function(a){var b,c=[],d=this,e=d.length;if("string"!=typeof a)return this.pushStack(n(a).filter(function(){for(b=0;e>b;b++)if(n.contains(d[b],this))return!0}));for(b=0;e>b;b++)n.find(a,d[b],c);return c=this.pushStack(e>1?n.unique(c):c),c.selector=this.selector?this.selector+" "+a:a,c},filter:function(a){return this.pushStack(x(this,a||[],!1))},not:function(a){return this.pushStack(x(this,a||[],!0))},is:function(a){return!!x(this,"string"==typeof a&&u.test(a)?n(a):a||[],!1).length}});var y,z=a.document,A=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]*))$/,B=n.fn.init=function(a,b){var c,d;if(!a)return this;if("string"==typeof a){if(c="<"===a.charAt(0)&&">"===a.charAt(a.length-1)&&a.length>=3?[null,a,null]:A.exec(a),!c||!c[1]&&b)return!b||b.jquery?(b||y).find(a):this.constructor(b).find(a);if(c[1]){if(b=b instanceof n?b[0]:b,n.merge(this,n.parseHTML(c[1],b&&b.nodeType?b.ownerDocument||b:z,!0)),v.test(c[1])&&n.isPlainObject(b))for(c in b)n.isFunction(this[c])?this[c](b[c]):this.attr(c,b[c]);return this}if(d=z.getElementById(c[2]),d&&d.parentNode){if(d.id!==c[2])return y.find(a);this.length=1,this[0]=d}return this.context=z,this.selector=a,this}return a.nodeType?(this.context=this[0]=a,this.length=1,this):n.isFunction(a)?"undefined"!=typeof y.ready?y.ready(a):a(n):(void 0!==a.selector&&(this.selector=a.selector,this.context=a.context),n.makeArray(a,this))};B.prototype=n.fn,y=n(z);var C=/^(?:parents|prev(?:Until|All))/,D={children:!0,contents:!0,next:!0,prev:!0};n.extend({dir:function(a,b,c){var d=[],e=a[b];while(e&&9!==e.nodeType&&(void 0===c||1!==e.nodeType||!n(e).is(c)))1===e.nodeType&&d.push(e),e=e[b];return d},sibling:function(a,b){for(var c=[];a;a=a.nextSibling)1===a.nodeType&&a!==b&&c.push(a);return c}}),n.fn.extend({has:function(a){var b,c=n(a,this),d=c.length;return this.filter(function(){for(b=0;d>b;b++)if(n.contains(this,c[b]))return!0})},closest:function(a,b){for(var c,d=0,e=this.length,f=[],g=u.test(a)||"string"!=typeof a?n(a,b||this.context):0;e>d;d++)for(c=this[d];c&&c!==b;c=c.parentNode)if(c.nodeType<11&&(g?g.index(c)>-1:1===c.nodeType&&n.find.matchesSelector(c,a))){f.push(c);break}return this.pushStack(f.length>1?n.unique(f):f)},index:function(a){return a?"string"==typeof a?n.inArray(this[0],n(a)):n.inArray(a.jquery?a[0]:a,this):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(a,b){return this.pushStack(n.unique(n.merge(this.get(),n(a,b))))},addBack:function(a){return this.add(null==a?this.prevObject:this.prevObject.filter(a))}});function E(a,b){do a=a[b];while(a&&1!==a.nodeType);return a}n.each({parent:function(a){var b=a.parentNode;return b&&11!==b.nodeType?b:null},parents:function(a){return n.dir(a,"parentNode")},parentsUntil:function(a,b,c){return n.dir(a,"parentNode",c)},next:function(a){return E(a,"nextSibling")},prev:function(a){return E(a,"previousSibling")},nextAll:function(a){return n.dir(a,"nextSibling")},prevAll:function(a){return n.dir(a,"previousSibling")},nextUntil:function(a,b,c){return n.dir(a,"nextSibling",c)},prevUntil:function(a,b,c){return n.dir(a,"previousSibling",c)},siblings:function(a){return n.sibling((a.parentNode||{}).firstChild,a)},children:function(a){return n.sibling(a.firstChild)},contents:function(a){return n.nodeName(a,"iframe")?a.contentDocument||a.contentWindow.document:n.merge([],a.childNodes)}},function(a,b){n.fn[a]=function(c,d){var e=n.map(this,b,c);return"Until"!==a.slice(-5)&&(d=c),d&&"string"==typeof d&&(e=n.filter(d,e)),this.length>1&&(D[a]||(e=n.unique(e)),C.test(a)&&(e=e.reverse())),this.pushStack(e)}});var F=/\S+/g,G={};function H(a){var b=G[a]={};return n.each(a.match(F)||[],function(a,c){b[c]=!0}),b}n.Callbacks=function(a){a="string"==typeof a?G[a]||H(a):n.extend({},a);var b,c,d,e,f,g,h=[],i=!a.once&&[],j=function(l){for(c=a.memory&&l,d=!0,f=g||0,g=0,e=h.length,b=!0;h&&e>f;f++)if(h[f].apply(l[0],l[1])===!1&&a.stopOnFalse){c=!1;break}b=!1,h&&(i?i.length&&j(i.shift()):c?h=[]:k.disable())},k={add:function(){if(h){var d=h.length;!function f(b){n.each(b,function(b,c){var d=n.type(c);"function"===d?a.unique&&k.has(c)||h.push(c):c&&c.length&&"string"!==d&&f(c)})}(arguments),b?e=h.length:c&&(g=d,j(c))}return this},remove:function(){return h&&n.each(arguments,function(a,c){var d;while((d=n.inArray(c,h,d))>-1)h.splice(d,1),b&&(e>=d&&e--,f>=d&&f--)}),this},has:function(a){return a?n.inArray(a,h)>-1:!(!h||!h.length)},empty:function(){return h=[],e=0,this},disable:function(){return h=i=c=void 0,this},disabled:function(){return!h},lock:function(){return i=void 0,c||k.disable(),this},locked:function(){return!i},fireWith:function(a,c){return!h||d&&!i||(c=c||[],c=[a,c.slice?c.slice():c],b?i.push(c):j(c)),this},fire:function(){return k.fireWith(this,arguments),this},fired:function(){return!!d}};return k},n.extend({Deferred:function(a){var b=[["resolve","done",n.Callbacks("once memory"),"resolved"],["reject","fail",n.Callbacks("once memory"),"rejected"],["notify","progress",n.Callbacks("memory")]],c="pending",d={state:function(){return c},always:function(){return e.done(arguments).fail(arguments),this},then:function(){var a=arguments;return n.Deferred(function(c){n.each(b,function(b,f){var g=n.isFunction(a[b])&&a[b];e[f[1]](function(){var a=g&&g.apply(this,arguments);a&&n.isFunction(a.promise)?a.promise().done(c.resolve).fail(c.reject).progress(c.notify):c[f[0]+"With"](this===d?c.promise():this,g?[a]:arguments)})}),a=null}).promise()},promise:function(a){return null!=a?n.extend(a,d):d}},e={};return d.pipe=d.then,n.each(b,function(a,f){var g=f[2],h=f[3];d[f[1]]=g.add,h&&g.add(function(){c=h},b[1^a][2].disable,b[2][2].lock),e[f[0]]=function(){return e[f[0]+"With"](this===e?d:this,arguments),this},e[f[0]+"With"]=g.fireWith}),d.promise(e),a&&a.call(e,e),e},when:function(a){var b=0,c=d.call(arguments),e=c.length,f=1!==e||a&&n.isFunction(a.promise)?e:0,g=1===f?a:n.Deferred(),h=function(a,b,c){return function(e){b[a]=this,c[a]=arguments.length>1?d.call(arguments):e,c===i?g.notifyWith(b,c):--f||g.resolveWith(b,c)}},i,j,k;if(e>1)for(i=new Array(e),j=new Array(e),k=new Array(e);e>b;b++)c[b]&&n.isFunction(c[b].promise)?c[b].promise().done(h(b,k,c)).fail(g.reject).progress(h(b,j,i)):--f;return f||g.resolveWith(k,c),g.promise()}});var I;n.fn.ready=function(a){return n.ready.promise().done(a),this},n.extend({isReady:!1,readyWait:1,holdReady:function(a){a?n.readyWait++:n.ready(!0)},ready:function(a){if(a===!0?!--n.readyWait:!n.isReady){if(!z.body)return setTimeout(n.ready);n.isReady=!0,a!==!0&&--n.readyWait>0||(I.resolveWith(z,[n]),n.fn.trigger&&n(z).trigger("ready").off("ready"))}}});function J(){z.addEventListener?(z.removeEventListener("DOMContentLoaded",K,!1),a.removeEventListener("load",K,!1)):(z.detachEvent("onreadystatechange",K),a.detachEvent("onload",K))}function K(){(z.addEventListener||"load"===event.type||"complete"===z.readyState)&&(J(),n.ready())}n.ready.promise=function(b){if(!I)if(I=n.Deferred(),"complete"===z.readyState)setTimeout(n.ready);else if(z.addEventListener)z.addEventListener("DOMContentLoaded",K,!1),a.addEventListener("load",K,!1);else{z.attachEvent("onreadystatechange",K),a.attachEvent("onload",K);var c=!1;try{c=null==a.frameElement&&z.documentElement}catch(d){}c&&c.doScroll&&!function e(){if(!n.isReady){try{c.doScroll("left")}catch(a){return setTimeout(e,50)}J(),n.ready()}}()}return I.promise(b)};var L="undefined",M;for(M in n(l))break;l.ownLast="0"!==M,l.inlineBlockNeedsLayout=!1,n(function(){var a,b,c=z.getElementsByTagName("body")[0];c&&(a=z.createElement("div"),a.style.cssText="border:0;width:0;height:0;position:absolute;top:0;left:-9999px;margin-top:1px",b=z.createElement("div"),c.appendChild(a).appendChild(b),typeof b.style.zoom!==L&&(b.style.cssText="border:0;margin:0;width:1px;padding:1px;display:inline;zoom:1",(l.inlineBlockNeedsLayout=3===b.offsetWidth)&&(c.style.zoom=1)),c.removeChild(a),a=b=null)}),function(){var a=z.createElement("div");if(null==l.deleteExpando){l.deleteExpando=!0;try{delete a.test}catch(b){l.deleteExpando=!1}}a=null}(),n.acceptData=function(a){var b=n.noData[(a.nodeName+" ").toLowerCase()],c=+a.nodeType||1;return 1!==c&&9!==c?!1:!b||b!==!0&&a.getAttribute("classid")===b};var N=/^(?:\{[\w\W]*\}|\[[\w\W]*\])$/,O=/([A-Z])/g;function P(a,b,c){if(void 0===c&&1===a.nodeType){var d="data-"+b.replace(O,"-$1").toLowerCase();if(c=a.getAttribute(d),"string"==typeof c){try{c="true"===c?!0:"false"===c?!1:"null"===c?null:+c+""===c?+c:N.test(c)?n.parseJSON(c):c}catch(e){}n.data(a,b,c)}else c=void 0}return c}function Q(a){var b;for(b in a)if(("data"!==b||!n.isEmptyObject(a[b]))&&"toJSON"!==b)return!1;return!0}function R(a,b,d,e){if(n.acceptData(a)){var f,g,h=n.expando,i=a.nodeType,j=i?n.cache:a,k=i?a[h]:a[h]&&h;if(k&&j[k]&&(e||j[k].data)||void 0!==d||"string"!=typeof b)return k||(k=i?a[h]=c.pop()||n.guid++:h),j[k]||(j[k]=i?{}:{toJSON:n.noop}),("object"==typeof b||"function"==typeof b)&&(e?j[k]=n.extend(j[k],b):j[k].data=n.extend(j[k].data,b)),g=j[k],e||(g.data||(g.data={}),g=g.data),void 0!==d&&(g[n.camelCase(b)]=d),"string"==typeof b?(f=g[b],null==f&&(f=g[n.camelCase(b)])):f=g,f -}}function S(a,b,c){if(n.acceptData(a)){var d,e,f=a.nodeType,g=f?n.cache:a,h=f?a[n.expando]:n.expando;if(g[h]){if(b&&(d=c?g[h]:g[h].data)){n.isArray(b)?b=b.concat(n.map(b,n.camelCase)):b in d?b=[b]:(b=n.camelCase(b),b=b in d?[b]:b.split(" ")),e=b.length;while(e--)delete d[b[e]];if(c?!Q(d):!n.isEmptyObject(d))return}(c||(delete g[h].data,Q(g[h])))&&(f?n.cleanData([a],!0):l.deleteExpando||g!=g.window?delete g[h]:g[h]=null)}}}n.extend({cache:{},noData:{"applet ":!0,"embed ":!0,"object ":"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"},hasData:function(a){return a=a.nodeType?n.cache[a[n.expando]]:a[n.expando],!!a&&!Q(a)},data:function(a,b,c){return R(a,b,c)},removeData:function(a,b){return S(a,b)},_data:function(a,b,c){return R(a,b,c,!0)},_removeData:function(a,b){return S(a,b,!0)}}),n.fn.extend({data:function(a,b){var c,d,e,f=this[0],g=f&&f.attributes;if(void 0===a){if(this.length&&(e=n.data(f),1===f.nodeType&&!n._data(f,"parsedAttrs"))){c=g.length;while(c--)d=g[c].name,0===d.indexOf("data-")&&(d=n.camelCase(d.slice(5)),P(f,d,e[d]));n._data(f,"parsedAttrs",!0)}return e}return"object"==typeof a?this.each(function(){n.data(this,a)}):arguments.length>1?this.each(function(){n.data(this,a,b)}):f?P(f,a,n.data(f,a)):void 0},removeData:function(a){return this.each(function(){n.removeData(this,a)})}}),n.extend({queue:function(a,b,c){var d;return a?(b=(b||"fx")+"queue",d=n._data(a,b),c&&(!d||n.isArray(c)?d=n._data(a,b,n.makeArray(c)):d.push(c)),d||[]):void 0},dequeue:function(a,b){b=b||"fx";var c=n.queue(a,b),d=c.length,e=c.shift(),f=n._queueHooks(a,b),g=function(){n.dequeue(a,b)};"inprogress"===e&&(e=c.shift(),d--),e&&("fx"===b&&c.unshift("inprogress"),delete f.stop,e.call(a,g,f)),!d&&f&&f.empty.fire()},_queueHooks:function(a,b){var c=b+"queueHooks";return n._data(a,c)||n._data(a,c,{empty:n.Callbacks("once memory").add(function(){n._removeData(a,b+"queue"),n._removeData(a,c)})})}}),n.fn.extend({queue:function(a,b){var c=2;return"string"!=typeof a&&(b=a,a="fx",c--),arguments.lengthh;h++)b(a[h],c,g?d:d.call(a[h],h,b(a[h],c)));return e?a:j?b.call(a):i?b(a[0],c):f},X=/^(?:checkbox|radio)$/i;!function(){var a=z.createDocumentFragment(),b=z.createElement("div"),c=z.createElement("input");if(b.setAttribute("className","t"),b.innerHTML="
    a",l.leadingWhitespace=3===b.firstChild.nodeType,l.tbody=!b.getElementsByTagName("tbody").length,l.htmlSerialize=!!b.getElementsByTagName("link").length,l.html5Clone="<:nav>"!==z.createElement("nav").cloneNode(!0).outerHTML,c.type="checkbox",c.checked=!0,a.appendChild(c),l.appendChecked=c.checked,b.innerHTML="",l.noCloneChecked=!!b.cloneNode(!0).lastChild.defaultValue,a.appendChild(b),b.innerHTML="",l.checkClone=b.cloneNode(!0).cloneNode(!0).lastChild.checked,l.noCloneEvent=!0,b.attachEvent&&(b.attachEvent("onclick",function(){l.noCloneEvent=!1}),b.cloneNode(!0).click()),null==l.deleteExpando){l.deleteExpando=!0;try{delete b.test}catch(d){l.deleteExpando=!1}}a=b=c=null}(),function(){var b,c,d=z.createElement("div");for(b in{submit:!0,change:!0,focusin:!0})c="on"+b,(l[b+"Bubbles"]=c in a)||(d.setAttribute(c,"t"),l[b+"Bubbles"]=d.attributes[c].expando===!1);d=null}();var Y=/^(?:input|select|textarea)$/i,Z=/^key/,$=/^(?:mouse|contextmenu)|click/,_=/^(?:focusinfocus|focusoutblur)$/,ab=/^([^.]*)(?:\.(.+)|)$/;function bb(){return!0}function cb(){return!1}function db(){try{return z.activeElement}catch(a){}}n.event={global:{},add:function(a,b,c,d,e){var f,g,h,i,j,k,l,m,o,p,q,r=n._data(a);if(r){c.handler&&(i=c,c=i.handler,e=i.selector),c.guid||(c.guid=n.guid++),(g=r.events)||(g=r.events={}),(k=r.handle)||(k=r.handle=function(a){return typeof n===L||a&&n.event.triggered===a.type?void 0:n.event.dispatch.apply(k.elem,arguments)},k.elem=a),b=(b||"").match(F)||[""],h=b.length;while(h--)f=ab.exec(b[h])||[],o=q=f[1],p=(f[2]||"").split(".").sort(),o&&(j=n.event.special[o]||{},o=(e?j.delegateType:j.bindType)||o,j=n.event.special[o]||{},l=n.extend({type:o,origType:q,data:d,handler:c,guid:c.guid,selector:e,needsContext:e&&n.expr.match.needsContext.test(e),namespace:p.join(".")},i),(m=g[o])||(m=g[o]=[],m.delegateCount=0,j.setup&&j.setup.call(a,d,p,k)!==!1||(a.addEventListener?a.addEventListener(o,k,!1):a.attachEvent&&a.attachEvent("on"+o,k))),j.add&&(j.add.call(a,l),l.handler.guid||(l.handler.guid=c.guid)),e?m.splice(m.delegateCount++,0,l):m.push(l),n.event.global[o]=!0);a=null}},remove:function(a,b,c,d,e){var f,g,h,i,j,k,l,m,o,p,q,r=n.hasData(a)&&n._data(a);if(r&&(k=r.events)){b=(b||"").match(F)||[""],j=b.length;while(j--)if(h=ab.exec(b[j])||[],o=q=h[1],p=(h[2]||"").split(".").sort(),o){l=n.event.special[o]||{},o=(d?l.delegateType:l.bindType)||o,m=k[o]||[],h=h[2]&&new RegExp("(^|\\.)"+p.join("\\.(?:.*\\.|)")+"(\\.|$)"),i=f=m.length;while(f--)g=m[f],!e&&q!==g.origType||c&&c.guid!==g.guid||h&&!h.test(g.namespace)||d&&d!==g.selector&&("**"!==d||!g.selector)||(m.splice(f,1),g.selector&&m.delegateCount--,l.remove&&l.remove.call(a,g));i&&!m.length&&(l.teardown&&l.teardown.call(a,p,r.handle)!==!1||n.removeEvent(a,o,r.handle),delete k[o])}else for(o in k)n.event.remove(a,o+b[j],c,d,!0);n.isEmptyObject(k)&&(delete r.handle,n._removeData(a,"events"))}},trigger:function(b,c,d,e){var f,g,h,i,k,l,m,o=[d||z],p=j.call(b,"type")?b.type:b,q=j.call(b,"namespace")?b.namespace.split("."):[];if(h=l=d=d||z,3!==d.nodeType&&8!==d.nodeType&&!_.test(p+n.event.triggered)&&(p.indexOf(".")>=0&&(q=p.split("."),p=q.shift(),q.sort()),g=p.indexOf(":")<0&&"on"+p,b=b[n.expando]?b:new n.Event(p,"object"==typeof b&&b),b.isTrigger=e?2:3,b.namespace=q.join("."),b.namespace_re=b.namespace?new RegExp("(^|\\.)"+q.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,b.result=void 0,b.target||(b.target=d),c=null==c?[b]:n.makeArray(c,[b]),k=n.event.special[p]||{},e||!k.trigger||k.trigger.apply(d,c)!==!1)){if(!e&&!k.noBubble&&!n.isWindow(d)){for(i=k.delegateType||p,_.test(i+p)||(h=h.parentNode);h;h=h.parentNode)o.push(h),l=h;l===(d.ownerDocument||z)&&o.push(l.defaultView||l.parentWindow||a)}m=0;while((h=o[m++])&&!b.isPropagationStopped())b.type=m>1?i:k.bindType||p,f=(n._data(h,"events")||{})[b.type]&&n._data(h,"handle"),f&&f.apply(h,c),f=g&&h[g],f&&f.apply&&n.acceptData(h)&&(b.result=f.apply(h,c),b.result===!1&&b.preventDefault());if(b.type=p,!e&&!b.isDefaultPrevented()&&(!k._default||k._default.apply(o.pop(),c)===!1)&&n.acceptData(d)&&g&&d[p]&&!n.isWindow(d)){l=d[g],l&&(d[g]=null),n.event.triggered=p;try{d[p]()}catch(r){}n.event.triggered=void 0,l&&(d[g]=l)}return b.result}},dispatch:function(a){a=n.event.fix(a);var b,c,e,f,g,h=[],i=d.call(arguments),j=(n._data(this,"events")||{})[a.type]||[],k=n.event.special[a.type]||{};if(i[0]=a,a.delegateTarget=this,!k.preDispatch||k.preDispatch.call(this,a)!==!1){h=n.event.handlers.call(this,a,j),b=0;while((f=h[b++])&&!a.isPropagationStopped()){a.currentTarget=f.elem,g=0;while((e=f.handlers[g++])&&!a.isImmediatePropagationStopped())(!a.namespace_re||a.namespace_re.test(e.namespace))&&(a.handleObj=e,a.data=e.data,c=((n.event.special[e.origType]||{}).handle||e.handler).apply(f.elem,i),void 0!==c&&(a.result=c)===!1&&(a.preventDefault(),a.stopPropagation()))}return k.postDispatch&&k.postDispatch.call(this,a),a.result}},handlers:function(a,b){var c,d,e,f,g=[],h=b.delegateCount,i=a.target;if(h&&i.nodeType&&(!a.button||"click"!==a.type))for(;i!=this;i=i.parentNode||this)if(1===i.nodeType&&(i.disabled!==!0||"click"!==a.type)){for(e=[],f=0;h>f;f++)d=b[f],c=d.selector+" ",void 0===e[c]&&(e[c]=d.needsContext?n(c,this).index(i)>=0:n.find(c,this,null,[i]).length),e[c]&&e.push(d);e.length&&g.push({elem:i,handlers:e})}return h]","i"),ib=/^\s+/,jb=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/gi,kb=/<([\w:]+)/,lb=/\s*$/g,sb={option:[1,""],legend:[1,"
    ","
    "],area:[1,"",""],param:[1,"",""],thead:[1,"","
    "],tr:[2,"","
    "],col:[2,"","
    "],td:[3,"","
    "],_default:l.htmlSerialize?[0,"",""]:[1,"X
    ","
    "]},tb=eb(z),ub=tb.appendChild(z.createElement("div"));sb.optgroup=sb.option,sb.tbody=sb.tfoot=sb.colgroup=sb.caption=sb.thead,sb.th=sb.td;function vb(a,b){var c,d,e=0,f=typeof a.getElementsByTagName!==L?a.getElementsByTagName(b||"*"):typeof a.querySelectorAll!==L?a.querySelectorAll(b||"*"):void 0;if(!f)for(f=[],c=a.childNodes||a;null!=(d=c[e]);e++)!b||n.nodeName(d,b)?f.push(d):n.merge(f,vb(d,b));return void 0===b||b&&n.nodeName(a,b)?n.merge([a],f):f}function wb(a){X.test(a.type)&&(a.defaultChecked=a.checked)}function xb(a,b){return n.nodeName(a,"table")&&n.nodeName(11!==b.nodeType?b:b.firstChild,"tr")?a.getElementsByTagName("tbody")[0]||a.appendChild(a.ownerDocument.createElement("tbody")):a}function yb(a){return a.type=(null!==n.find.attr(a,"type"))+"/"+a.type,a}function zb(a){var b=qb.exec(a.type);return b?a.type=b[1]:a.removeAttribute("type"),a}function Ab(a,b){for(var c,d=0;null!=(c=a[d]);d++)n._data(c,"globalEval",!b||n._data(b[d],"globalEval"))}function Bb(a,b){if(1===b.nodeType&&n.hasData(a)){var c,d,e,f=n._data(a),g=n._data(b,f),h=f.events;if(h){delete g.handle,g.events={};for(c in h)for(d=0,e=h[c].length;e>d;d++)n.event.add(b,c,h[c][d])}g.data&&(g.data=n.extend({},g.data))}}function Cb(a,b){var c,d,e;if(1===b.nodeType){if(c=b.nodeName.toLowerCase(),!l.noCloneEvent&&b[n.expando]){e=n._data(b);for(d in e.events)n.removeEvent(b,d,e.handle);b.removeAttribute(n.expando)}"script"===c&&b.text!==a.text?(yb(b).text=a.text,zb(b)):"object"===c?(b.parentNode&&(b.outerHTML=a.outerHTML),l.html5Clone&&a.innerHTML&&!n.trim(b.innerHTML)&&(b.innerHTML=a.innerHTML)):"input"===c&&X.test(a.type)?(b.defaultChecked=b.checked=a.checked,b.value!==a.value&&(b.value=a.value)):"option"===c?b.defaultSelected=b.selected=a.defaultSelected:("input"===c||"textarea"===c)&&(b.defaultValue=a.defaultValue)}}n.extend({clone:function(a,b,c){var d,e,f,g,h,i=n.contains(a.ownerDocument,a);if(l.html5Clone||n.isXMLDoc(a)||!hb.test("<"+a.nodeName+">")?f=a.cloneNode(!0):(ub.innerHTML=a.outerHTML,ub.removeChild(f=ub.firstChild)),!(l.noCloneEvent&&l.noCloneChecked||1!==a.nodeType&&11!==a.nodeType||n.isXMLDoc(a)))for(d=vb(f),h=vb(a),g=0;null!=(e=h[g]);++g)d[g]&&Cb(e,d[g]);if(b)if(c)for(h=h||vb(a),d=d||vb(f),g=0;null!=(e=h[g]);g++)Bb(e,d[g]);else Bb(a,f);return d=vb(f,"script"),d.length>0&&Ab(d,!i&&vb(a,"script")),d=h=e=null,f},buildFragment:function(a,b,c,d){for(var e,f,g,h,i,j,k,m=a.length,o=eb(b),p=[],q=0;m>q;q++)if(f=a[q],f||0===f)if("object"===n.type(f))n.merge(p,f.nodeType?[f]:f);else if(mb.test(f)){h=h||o.appendChild(b.createElement("div")),i=(kb.exec(f)||["",""])[1].toLowerCase(),k=sb[i]||sb._default,h.innerHTML=k[1]+f.replace(jb,"<$1>")+k[2],e=k[0];while(e--)h=h.lastChild;if(!l.leadingWhitespace&&ib.test(f)&&p.push(b.createTextNode(ib.exec(f)[0])),!l.tbody){f="table"!==i||lb.test(f)?""!==k[1]||lb.test(f)?0:h:h.firstChild,e=f&&f.childNodes.length;while(e--)n.nodeName(j=f.childNodes[e],"tbody")&&!j.childNodes.length&&f.removeChild(j)}n.merge(p,h.childNodes),h.textContent="";while(h.firstChild)h.removeChild(h.firstChild);h=o.lastChild}else p.push(b.createTextNode(f));h&&o.removeChild(h),l.appendChecked||n.grep(vb(p,"input"),wb),q=0;while(f=p[q++])if((!d||-1===n.inArray(f,d))&&(g=n.contains(f.ownerDocument,f),h=vb(o.appendChild(f),"script"),g&&Ab(h),c)){e=0;while(f=h[e++])pb.test(f.type||"")&&c.push(f)}return h=null,o},cleanData:function(a,b){for(var d,e,f,g,h=0,i=n.expando,j=n.cache,k=l.deleteExpando,m=n.event.special;null!=(d=a[h]);h++)if((b||n.acceptData(d))&&(f=d[i],g=f&&j[f])){if(g.events)for(e in g.events)m[e]?n.event.remove(d,e):n.removeEvent(d,e,g.handle);j[f]&&(delete j[f],k?delete d[i]:typeof d.removeAttribute!==L?d.removeAttribute(i):d[i]=null,c.push(f))}}}),n.fn.extend({text:function(a){return W(this,function(a){return void 0===a?n.text(this):this.empty().append((this[0]&&this[0].ownerDocument||z).createTextNode(a))},null,a,arguments.length)},append:function(){return this.domManip(arguments,function(a){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var b=xb(this,a);b.appendChild(a)}})},prepend:function(){return this.domManip(arguments,function(a){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var b=xb(this,a);b.insertBefore(a,b.firstChild)}})},before:function(){return this.domManip(arguments,function(a){this.parentNode&&this.parentNode.insertBefore(a,this)})},after:function(){return this.domManip(arguments,function(a){this.parentNode&&this.parentNode.insertBefore(a,this.nextSibling)})},remove:function(a,b){for(var c,d=a?n.filter(a,this):this,e=0;null!=(c=d[e]);e++)b||1!==c.nodeType||n.cleanData(vb(c)),c.parentNode&&(b&&n.contains(c.ownerDocument,c)&&Ab(vb(c,"script")),c.parentNode.removeChild(c));return this},empty:function(){for(var a,b=0;null!=(a=this[b]);b++){1===a.nodeType&&n.cleanData(vb(a,!1));while(a.firstChild)a.removeChild(a.firstChild);a.options&&n.nodeName(a,"select")&&(a.options.length=0)}return this},clone:function(a,b){return a=null==a?!1:a,b=null==b?a:b,this.map(function(){return n.clone(this,a,b)})},html:function(a){return W(this,function(a){var b=this[0]||{},c=0,d=this.length;if(void 0===a)return 1===b.nodeType?b.innerHTML.replace(gb,""):void 0;if(!("string"!=typeof a||nb.test(a)||!l.htmlSerialize&&hb.test(a)||!l.leadingWhitespace&&ib.test(a)||sb[(kb.exec(a)||["",""])[1].toLowerCase()])){a=a.replace(jb,"<$1>");try{for(;d>c;c++)b=this[c]||{},1===b.nodeType&&(n.cleanData(vb(b,!1)),b.innerHTML=a);b=0}catch(e){}}b&&this.empty().append(a)},null,a,arguments.length)},replaceWith:function(){var a=arguments[0];return this.domManip(arguments,function(b){a=this.parentNode,n.cleanData(vb(this)),a&&a.replaceChild(b,this)}),a&&(a.length||a.nodeType)?this:this.remove()},detach:function(a){return this.remove(a,!0)},domManip:function(a,b){a=e.apply([],a);var c,d,f,g,h,i,j=0,k=this.length,m=this,o=k-1,p=a[0],q=n.isFunction(p);if(q||k>1&&"string"==typeof p&&!l.checkClone&&ob.test(p))return this.each(function(c){var d=m.eq(c);q&&(a[0]=p.call(this,c,d.html())),d.domManip(a,b)});if(k&&(i=n.buildFragment(a,this[0].ownerDocument,!1,this),c=i.firstChild,1===i.childNodes.length&&(i=c),c)){for(g=n.map(vb(i,"script"),yb),f=g.length;k>j;j++)d=i,j!==o&&(d=n.clone(d,!0,!0),f&&n.merge(g,vb(d,"script"))),b.call(this[j],d,j);if(f)for(h=g[g.length-1].ownerDocument,n.map(g,zb),j=0;f>j;j++)d=g[j],pb.test(d.type||"")&&!n._data(d,"globalEval")&&n.contains(h,d)&&(d.src?n._evalUrl&&n._evalUrl(d.src):n.globalEval((d.text||d.textContent||d.innerHTML||"").replace(rb,"")));i=c=null}return this}}),n.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(a,b){n.fn[a]=function(a){for(var c,d=0,e=[],g=n(a),h=g.length-1;h>=d;d++)c=d===h?this:this.clone(!0),n(g[d])[b](c),f.apply(e,c.get());return this.pushStack(e)}});var Db,Eb={};function Fb(b,c){var d=n(c.createElement(b)).appendTo(c.body),e=a.getDefaultComputedStyle?a.getDefaultComputedStyle(d[0]).display:n.css(d[0],"display");return d.detach(),e}function Gb(a){var b=z,c=Eb[a];return c||(c=Fb(a,b),"none"!==c&&c||(Db=(Db||n("