This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var reader = new FileReader(); | |
reader.readAsBinaryString(fileData); | |
reader.onload = function (e) | |
{ | |
var contentType = fileData.type || MimeTypes.Unknown; | |
var runUpload = function (folderID) | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
define(function (require, exports, module) | |
{ | |
var g = require('globals'), | |
C = require('Constants'), | |
goog = require('goog'), | |
AccountManager = require('AccountManager'); | |
function DriveUploader(file, email, onProgress, onComplete, onError) | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
self.JSONP = function (params)//(url, data, method, callback) | |
{ | |
self.Assert(params.url, 'Must supply a valid URL to fetch'); | |
self.Assert(params.cb, 'Must supply a valid callback'); | |
var url = params.url; | |
var data = params.data; | |
var cb = params.cb; | |
if (data) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
window.log = console.log.bind(console); | |
window.inspectRemote = function(input) | |
{ | |
if (!input) | |
{ | |
log('Must specify either an item ID or item object to inspect'); | |
return; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
define(['ko'], | |
function (ko) { | |
var self = { }; | |
var cachedTemplatesDomDataKey = "__cached_template__"; | |
// | |
// When rendering a template, a source is what returns either the text or the already-created DOM | |
// nodes to clone. The default implementation of a template source in knockout doesn't cache the | |
// DOM nodes that it creates, and instead requests the text of the <script> tag the template is |