From fa3ebf391db168d7c4ebcc86450c66684eeeb5cd Mon Sep 17 00:00:00 2001 From: Jose Antonio Marquez Date: Wed, 21 Mar 2012 11:11:51 -0700 Subject: Removing usage of webRequest APIs Removed the usage of the webRequest API since all files are parsed on open to handle prefixing correct origin. This will most likely not work for assets that are added dynamically and will most likely break, all those adding linking to assets should make use of a function in the mediator to mask the display value and actual value of the linked asset. --- js/controllers/document-controller.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'js') diff --git a/js/controllers/document-controller.js b/js/controllers/document-controller.js index 7d982a62..3db4c7d4 100755 --- a/js/controllers/document-controller.js +++ b/js/controllers/document-controller.js @@ -73,13 +73,15 @@ var DocumentController = exports.DocumentController = Montage.create(Component, - //////////////////////////////////////////////////////////////////// + /* +//////////////////////////////////////////////////////////////////// // handleWebRequest: { value: function (request) { //TODO: Check if frameId is proper if (this._hackRootFlag && request.parentFrameId !== -1) { //TODO: Optimize creating string + console.log(request); //console.log(this.application.ninja.coreIoApi.rootUrl+this.application.ninja.documentController.documentHackReference.root.split(this.application.ninja.coreIoApi.cloudData.root)[1], request.url); //return {redirectUrl: this.application.ninja.coreIoApi.rootUrl+this.application.ninja.documentController.documentHackReference.root.split(this.application.ninja.coreIoApi.cloudData.root)[1]+request.url.split('/')[request.url.split('/').length-1]}; return {redirectUrl: this.application.ninja.coreIoApi.rootUrl+this.application.ninja.documentController.documentHackReference.root.split(this.application.ninja.coreIoApi.cloudData.root)[1]+request.url.split(chrome.extension.getURL('js/document/templates/montage-html/'))[1]}; @@ -102,6 +104,7 @@ var DocumentController = exports.DocumentController = Montage.create(Component, } }, //////////////////////////////////////////////////////////////////// +*/ -- cgit v1.2.3 From 873bb850a44d3b388fe6742c6aadc6e0caaae30b Mon Sep 17 00:00:00 2001 From: Jose Antonio Marquez Date: Wed, 21 Mar 2012 12:03:36 -0700 Subject: Fix: Chrome 19 I/O Bug Fixed creating new files. --- js/io/system/coreioapi.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'js') diff --git a/js/io/system/coreioapi.js b/js/io/system/coreioapi.js index f428a229..ae249480 100755 --- a/js/io/system/coreioapi.js +++ b/js/io/system/coreioapi.js @@ -393,12 +393,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 -- cgit v1.2.3