o: ActiveSupport::Cache::Entry	:@value"{I"
class:EFI"ProcessedAsset;�FI"logical_path;�FI"anjlab/uploads/util.js;�TI"
pathname;�FI"K/Users/yury/Work/uploads/app/assets/javascripts/anjlab/uploads/util.js;�TI"content_type;�FI"application/javascript;�FI"
mtime;�FI"2013-01-25T21:09:05+04:00;�FI"length;�FiI"digest;�F"%3d81cb16e3c2ea986eca7c4582fb3cc6I"source;�FI"@AnjLab ?= {}

@AnjLab.Uploads = {
  log: (message, level)->
    if window.console
        if !level || level === 'info'
          window.console.log(message)
        else
          if window.console[level]
            window.console[level](message)
          else
            window.console.log "[#{level}] #{message}"

  isXhrUploadSupported: ->
    input = document.createElement('input')
    input.type = 'file'

    input.multiple !== undefined &&
      typeof File !== "undefined" &&
      typeof FormData !== "undefined" &&
      typeof (new XMLHttpRequest()).upload !== "undefined"

  isFolderDropSupported: (dataTransfer)->
    dataTransfer.items && dataTransfer.items[0].webkitGetAsEntry

  isFileChunkingSupported: ->
    @android() && //android's impl of Blob.slice is broken
    @isXhrUploadSupported() &&
    (File.prototype.slice || File.prototype.webkitSlice || File.prototype.mozSlice)


// qq.isFileOrInput = function(maybeFileOrInput) {
//     "use strict";
//     if (window.File && maybeFileOrInput instanceof File) {
//         return true;
//     }
//     else if (window.HTMLInputElement) {
//         if (maybeFileOrInput instanceof HTMLInputElement) {
//             if (maybeFileOrInput.type && maybeFileOrInput.type.toLowerCase() === 'file') {
//                 return true;
//             }
//         }
//     }
//     else if (maybeFileOrInput.tagName) {
//         if (maybeFileOrInput.tagName.toLowerCase() === 'input') {
//             if (maybeFileOrInput.type && maybeFileOrInput.type.toLowerCase() === 'file') {
//                 return true;
//             }
//         }
//     }

//     return false;
// };



// //this is a version 4 UUID
// qq.getUniqueId = function(){
//     "use strict";

//     return 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, function(c) {
//         /*jslint eqeq: true, bitwise: true*/
//         var r = Math.random()*16|0, v = c == 'x' ? r : (r&0x3|0x8);
//         return v.toString(16);
//     });
// };

// //
// // Browsers and platforms detection

// qq.ie       = function(){
//     "use strict";
//     return navigator.userAgent.indexOf('MSIE') !== -1;
// };
// qq.ie10     = function(){
//     "use strict";
//     return navigator.userAgent.indexOf('MSIE 10') !== -1;
// };
// qq.safari   = function(){
//     "use strict";
//     return navigator.vendor !== undefined && navigator.vendor.indexOf("Apple") !== -1;
// };
// qq.chrome   = function(){
//     "use strict";
//     return navigator.vendor !== undefined && navigator.vendor.indexOf('Google') !== -1;
// };
// qq.firefox  = function(){
//     "use strict";
//     return (navigator.userAgent.indexOf('Mozilla') !== -1 && navigator.vendor !== undefined && navigator.vendor === '');
// };
// qq.windows  = function(){
//     "use strict";
//     return navigator.platform === "Win32";
// };
// qq.android = function(){
//     "use strict";
//     return navigator.userAgent.toLowerCase().indexOf('android') !== -1;
// };


// qq.setCookie = function(name, value, days) {
//     var date = new Date(),
//         expires = "";

// 	if (days) {
// 		date.setTime(date.getTime()+(days*24*60*60*1000));
// 		expires = "; expires="+date.toGMTString();
// 	}

// 	document.cookie = name+"="+value+expires+"; path=/";
// };

// qq.getCookie = function(name) {
// 	var nameEQ = name + "=",
//         ca = document.cookie.split(';'),
//         c;

// 	for(var i=0;i < ca.length;i++) {
// 		c = ca[i];
// 		while (c.charAt(0)==' ') {
//             c = c.substring(1,c.length);
//         }
// 		if (c.indexOf(nameEQ) === 0) {
//             return c.substring(nameEQ.length,c.length);
//         }
// 	}
// };

// qq.getCookieNames = function(regexp) {
//     var cookies = document.cookie.split(';'),
//         cookieNames = [];

//     qq.each(cookies, function(idx, cookie) {
//         cookie = cookie.trim();

//         var equalsIdx = cookie.indexOf("=");

//         if (cookie.match(regexp)) {
//             cookieNames.push(cookie.substr(0, equalsIdx));
//         }
//     });

//     return cookieNames;
// };

// qq.deleteCookie = function(name) {
// 	qq.setCookie(name, "", -1);
// };

// qq.areCookiesEnabled = function() {
//     var randNum = Math.random() * 100000,
//         name = "qqCookieTest:" + randNum;
//     qq.setCookie(name, 1);

//     if (qq.getCookie(name)) {
//         qq.deleteCookie(name);
//         return true;
//     }
//     return false;
// };

// /**
//  * Not recommended for use outside of Fine Uploader since this falls back to an unchecked eval if JSON.parse is not
//  * implemented.  For a more secure JSON.parse polyfill, use Douglas Crockford's json2.js.
//  */
// qq.parseJson = function(json) {
//     /*jshint evil: true*/
//     if (typeof JSON.parse === "function") {
//         return JSON.parse(json);
//     } else {
//         return eval("(" + json + ")");
//     }
// };

// /**
//  * A generic module which supports object disposing in dispose() method.
//  * */
// qq.DisposeSupport = function() {
//     "use strict";
//     var disposers = [];

//     return {
//         /** Run all registered disposers */
//         dispose: function() {
//             var disposer;
//             do {
//                 disposer = disposers.shift();
//                 if (disposer) {
//                     disposer();
//                 }
//             }
//             while (disposer);
//         },

//         /** Attach event handler and register de-attacher as a disposer */
//         attach: function() {
//             var args = arguments;
//             /*jslint undef:true*/
//             this.addDisposer(qq(args[0]).attach.apply(this, Array.prototype.slice.call(arguments, 1)));
//         },

//         /** Add disposer to the collection */
//         addDisposer: function(disposeFunction) {
//             disposers.push(disposeFunction);
//         }
//     };
// };
;�FI"dependency_digest;�F"%558a40834cbc9ab33fe73f7ce1a49b7eI"required_paths;�F[I"K/Users/yury/Work/uploads/app/assets/javascripts/anjlab/uploads/util.js;�TI"dependency_paths;�F[{I"	path;�FI"K/Users/yury/Work/uploads/app/assets/javascripts/anjlab/uploads/util.js;�TI"
mtime;�FI"2013-01-25T21:09:05+04:00;�FI"digest;�F"%3d81cb16e3c2ea986eca7c4582fb3cc6I"
_version;�F"%6776f581a4329e299531e1d52aa59832:@created_atf1359133766.518733:@expires_in0:@compressedF