From 7bee50379c1df86bb571e0e8d6c08e24d25231f5 Mon Sep 17 00:00:00 2001 From: Kris Kowal Date: Mon, 9 Jul 2012 16:38:08 -0700 Subject: BSD License --- js/io/system/chromeapi.js | 27 ++++++++-------- js/io/system/coreioapi.js | 37 +++++++++++----------- js/io/system/fileio.js | 29 +++++++++-------- js/io/system/ninjalibrary.js | 35 ++++++++++---------- js/io/system/projectio.js | 23 +++++++------- js/io/ui/cloudpopup.reel/cloudpopup.html | 23 +++++++------- js/io/ui/cloudpopup.reel/cloudpopup.js | 23 +++++++------- js/io/ui/cloudpopup.reel/css/cloudpopup.css | 23 +++++++------- js/io/ui/cloudpopup.reel/css/cloudpopup.scss | 23 +++++++------- .../file-input-field.reel/file-input-field.css | 23 +++++++------- .../file-input-field.reel/file-input-field.html | 23 +++++++------- .../file-input-field.reel/file-input-field.js | 23 +++++++------- js/io/ui/file-picker/file-picker-controller.js | 23 +++++++------- js/io/ui/file-picker/file-picker-model.js | 23 +++++++------- .../picker-navigator.reel/picker-navigator.css | 23 +++++++------- .../picker-navigator.reel/picker-navigator.html | 23 +++++++------- .../picker-navigator.reel/picker-navigator.js | 27 ++++++++-------- .../new-file-location.reel/new-file-location.css | 23 +++++++------- .../new-file-location.reel/new-file-location.html | 23 +++++++------- .../new-file-location.reel/new-file-location.js | 23 +++++++------- .../new-file-options-navigator.css | 23 +++++++------- .../new-file-options-navigator.html | 23 +++++++------- .../new-file-options-navigator.js | 25 ++++++++------- .../new-file-workflow-controller.js | 23 +++++++------- .../ui/new-file-dialog/new-file-workflow-model.js | 23 +++++++------- js/io/ui/save-as-dialog.reel/save-as-dialog.css | 23 +++++++------- js/io/ui/save-as-dialog.reel/save-as-dialog.html | 23 +++++++------- js/io/ui/save-as-dialog.reel/save-as-dialog.js | 23 +++++++------- 28 files changed, 357 insertions(+), 329 deletions(-) (limited to 'js/io') diff --git a/js/io/system/chromeapi.js b/js/io/system/chromeapi.js index 0650385f..44afd10c 100644 --- a/js/io/system/chromeapi.js +++ b/js/io/system/chromeapi.js @@ -1,24 +1,25 @@ /* -Copyright (c) 2012, Motorola Mobility, Inc +Copyright (c) 2012, Motorola Mobility LLC. All Rights Reserved. -BSD License. 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 Motorola Mobility nor the names of its contributors - may be used to endorse or promote products derived from this software - without specific prior written permission. +* 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 Motorola Mobility LLC 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 +ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER 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 @@ -34,7 +35,7 @@ NOTES: The init function starts up the file system API, and a size must be set, no unlimited available as of now. - + //////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////// */ // @@ -287,7 +288,7 @@ exports.ChromeApi = Montage.create(Object.prototype, { } } //////////////////////////////////////////////////////////////////// - //////////////////////////////////////////////////////////////////// + //////////////////////////////////////////////////////////////////// }); //////////////////////////////////////////////////////////////////////// //////////////////////////////////////////////////////////////////////// diff --git a/js/io/system/coreioapi.js b/js/io/system/coreioapi.js index d3977106..b8c08832 100755 --- a/js/io/system/coreioapi.js +++ b/js/io/system/coreioapi.js @@ -1,24 +1,25 @@ /* -Copyright (c) 2012, Motorola Mobility, Inc +Copyright (c) 2012, Motorola Mobility LLC. All Rights Reserved. -BSD License. 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 Motorola Mobility nor the names of its contributors - may be used to endorse or promote products derived from this software - without specific prior written permission. +* 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 Motorola Mobility LLC 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 +ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER 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 @@ -33,7 +34,7 @@ POSSIBILITY OF SUCH DAMAGE. NOTES: Core API reference in NINJA: this.application.ninja.coreIoApi - + //////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////// */ var Montage = require("montage/core/core").Montage, @@ -101,7 +102,7 @@ exports.CoreIoApi = Montage.create(Component, { this.ninjaLibrary.addEventListener('sync', this, false); //Sending library to be synced to chrome this.ninjaLibrary.synchronize(e._event.ninjaChromeLibrary, this.chromeFileSystem); - + } }, //////////////////////////////////////////////////////////////////// @@ -389,7 +390,7 @@ exports.CoreIoApi = Montage.create(Component, { try { var serviceURL = this._prepareServiceURL(this.fileServiceURL, file.uri), xhr = new XMLHttpRequest(); - // + // xhr.open("GET", serviceURL, false); xhr.setRequestHeader("check-existence-only", "true"); xhr.send(); @@ -434,12 +435,12 @@ exports.CoreIoApi = Montage.create(Component, { xhr = new XMLHttpRequest(); // xhr.open("POST", serviceURL, false); - //xhr.responseType = "arraybuffer"; + //xhr.responseType = "arraybuffer"; if(file.contentType && file.contentType.length) xhr.setRequestHeader("Content-Type", file.contentType); else xhr.setRequestHeader("Content-Type", "text/plain"); - + if (file.contents) xhr.send(file.contents); else @@ -700,7 +701,7 @@ exports.CoreIoApi = Montage.create(Component, { // status: int indicating the request HTTP status code // 200 - the file was read and its contents were returned // 404 - the file does not exist - // 500 - unknown server error occurred + // 500 - unknown server error occurred readExternalFile: { enumerable: false, value: function(file) { @@ -893,7 +894,7 @@ exports.CoreIoApi = Montage.create(Component, { var retValue = { success:null, content:null, status:null }; if(dir && dir.uri && dir.uri.length) { try { - var serviceURL = this._prepareServiceURL(this.directoryServiceURL, dir.uri), + var serviceURL = this._prepareServiceURL(this.directoryServiceURL, dir.uri), xhr = new XMLHttpRequest(); // xhr.open("GET", serviceURL, false); diff --git a/js/io/system/fileio.js b/js/io/system/fileio.js index d4de74f9..0c9bf9fb 100755 --- a/js/io/system/fileio.js +++ b/js/io/system/fileio.js @@ -1,24 +1,25 @@ /* -Copyright (c) 2012, Motorola Mobility, Inc +Copyright (c) 2012, Motorola Mobility LLC. All Rights Reserved. -BSD License. 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 Motorola Mobility nor the names of its contributors - may be used to endorse or promote products derived from this software - without specific prior written permission. +* 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 Motorola Mobility LLC 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 +ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER 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 @@ -35,9 +36,9 @@ NOTES: For newFile, only the 'uri' is required, if contents is empty, such empty file will be created. 'contents' should be a string to be saved as the file. 'contentType' is the mime type of the file. - + Core API reference in NINJA: this.application.ninja.coreIoApi - + //////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////// */ // @@ -245,7 +246,7 @@ exports.FileIo = Montage.create(Component, { } } //////////////////////////////////////////////////////////////////// - //////////////////////////////////////////////////////////////////// + //////////////////////////////////////////////////////////////////// }); //////////////////////////////////////////////////////////////////////// //////////////////////////////////////////////////////////////////////// diff --git a/js/io/system/ninjalibrary.js b/js/io/system/ninjalibrary.js index 1467d18f..4f051b67 100644 --- a/js/io/system/ninjalibrary.js +++ b/js/io/system/ninjalibrary.js @@ -1,24 +1,25 @@ /* -Copyright (c) 2012, Motorola Mobility, Inc +Copyright (c) 2012, Motorola Mobility LLC. All Rights Reserved. -BSD License. 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 Motorola Mobility nor the names of its contributors - may be used to endorse or promote products derived from this software - without specific prior written permission. +* 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 Motorola Mobility LLC 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 +ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER 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 @@ -140,7 +141,7 @@ exports.NinjaLibrary = Montage.create(Object.prototype, { } else if (contents[i].isFile){ // tracking.total++; - //Copying file + //Copying file this.chromeApi.fileContent(contents[i].fullPath, function (result) { //Using binary when copying files to allow images and such to work var file = this.coreApi.createFile({uri: (fileRoot+result.file.fullPath).replace(/\/\//gi, '/'), contents: result.content}); @@ -197,7 +198,7 @@ exports.NinjaLibrary = Montage.create(Object.prototype, { } } } - + } else { //No library is present, must copy all for (var j in libs.libraries) { @@ -223,7 +224,7 @@ exports.NinjaLibrary = Montage.create(Object.prototype, { //Getting file contents xhr = new XMLHttpRequest(); xhr.open("GET", tocopylibs[i].path, false); - xhr.responseType = "arraybuffer"; + xhr.responseType = "arraybuffer"; xhr.send(); //Checking for status if (xhr.readyState === 4) { @@ -265,7 +266,7 @@ exports.NinjaLibrary = Montage.create(Object.prototype, { for (i=0; this.files[i]; i++) { xhr = new XMLHttpRequest(); xhr.open("GET", this.root+this.files[i], false); - xhr.responseType = "arraybuffer"; + xhr.responseType = "arraybuffer"; xhr.send(); //Checking for status if (xhr.readyState === 4) { @@ -277,7 +278,7 @@ exports.NinjaLibrary = Montage.create(Object.prototype, { this.main.libraryCopied(); } }.bind(this)); - } + } } } }.bind(libjson)); @@ -362,7 +363,7 @@ exports.NinjaLibrary = Montage.create(Object.prototype, { } } //////////////////////////////////////////////////////////////////// - //////////////////////////////////////////////////////////////////// + //////////////////////////////////////////////////////////////////// }); //////////////////////////////////////////////////////////////////////// //////////////////////////////////////////////////////////////////////// diff --git a/js/io/system/projectio.js b/js/io/system/projectio.js index 785c7d7c..2402a4f5 100755 --- a/js/io/system/projectio.js +++ b/js/io/system/projectio.js @@ -1,24 +1,25 @@ /* -Copyright (c) 2012, Motorola Mobility, Inc +Copyright (c) 2012, Motorola Mobility LLC. All Rights Reserved. -BSD License. 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 Motorola Mobility nor the names of its contributors - may be used to endorse or promote products derived from this software - without specific prior written permission. +* 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 Motorola Mobility LLC 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 +ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER 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 diff --git a/js/io/ui/cloudpopup.reel/cloudpopup.html b/js/io/ui/cloudpopup.reel/cloudpopup.html index cd6e4c94..446c5c65 100755 --- a/js/io/ui/cloudpopup.reel/cloudpopup.html +++ b/js/io/ui/cloudpopup.reel/cloudpopup.html @@ -1,26 +1,27 @@