tt-rss/lib/dojo/cookie.js
Anders Kaseorg 6887a0f573 lib: Upgrade Dojo and Dijit from 1.8.3 to 1.12.1
The itemNode and expandoNode elements have changed from img to
span (https://bugs.dojotoolkit.org/ticket/16699), so we now put our
tree icons inside them rather than replacing them.

Signed-off-by: Anders Kaseorg <andersk@mit.edu>
2017-01-21 13:22:14 -05:00

8 行
無檔案結尾符
1.1 KiB
JavaScript

/*
Copyright (c) 2004-2016, The JS 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/cookie",["./_base/kernel","./regexp"],function(_1,_2){_1.cookie=function(_3,_4,_5){var c=document.cookie,_6;if(arguments.length==1){var _7=c.match(new RegExp("(?:^|; )"+_2.escapeString(_3)+"=([^;]*)"));_6=_7?decodeURIComponent(_7[1]):undefined;}else{_5=_5||{};var _8=_5.expires;if(typeof _8=="number"){var d=new Date();d.setTime(d.getTime()+_8*24*60*60*1000);_8=_5.expires=d;}if(_8&&_8.toUTCString){_5.expires=_8.toUTCString();}_4=encodeURIComponent(_4);var _9=_3+"="+_4,_a;for(_a in _5){_9+="; "+_a;var _b=_5[_a];if(_b!==true){_9+="="+_b;}}document.cookie=_9;}return _6;};_1.cookie.isSupported=function(){if(!("cookieEnabled" in navigator)){this("__djCookieTest__","CookiesAllowed");navigator.cookieEnabled=this("__djCookieTest__")=="CookiesAllowed";if(navigator.cookieEnabled){this("__djCookieTest__","",{expires:-1});}}return navigator.cookieEnabled;};return _1.cookie;});