namespaces up in this mf
This commit is contained in:
parent
ba0ef9b51f
commit
2a6ace1aec
16
4chan_x.js
16
4chan_x.js
@ -58,7 +58,7 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
(function() {
|
(function() {
|
||||||
var $, $$, a, arr, as, autoWatch, callback, changeCheckbox, changeValue, clearHidden, config, d, delform, down, editSauce, el, expand, expandComment, expandThread, g, getThread, href, html, i, id, imageClick, imageExpand, imageExpandClick, imageHover, imageResize, imageThumb, imageToggle, imageType, imageTypeChange, img, input, inputs, keyModeInsert, keyModeNormal, keydown, keypress, l1, log, navbotr, navtopr, nodeInserted, omitted, onloadComment, onloadThread, option, options, parseResponse, pathname, qr, recaptcha, recaptchaListener, recaptchaReload, redirect, replyHiding, replyNav, report, request, scroll, scrollThread, span, src, temp, text, textContent, threadHiding, threads, tzOffset, ui, up, updateAuto, updateCallback, updateFavicon, updateInterval, updateNow, updateTime, updateTitle, updateVerbose, updaterMake, watch, watchX, watcher, watcherUpdate, _i, _j, _k, _l, _len, _len2, _len3, _len4, _len5, _len6, _len7, _m, _n, _ref, _ref2, _ref3, _ref4;
|
var $, $$, NAMESPACE, a, arr, as, autoWatch, callback, changeCheckbox, changeValue, clearHidden, config, d, delform, down, editSauce, el, expand, expandComment, expandThread, g, getThread, href, html, i, id, imageClick, imageExpand, imageExpandClick, imageHover, imageResize, imageThumb, imageToggle, imageType, imageTypeChange, img, input, inputs, keyModeInsert, keyModeNormal, keydown, keypress, l1, log, navbotr, navtopr, nodeInserted, omitted, onloadComment, onloadThread, option, options, parseResponse, pathname, qr, recaptcha, recaptchaListener, recaptchaReload, redirect, replyHiding, replyNav, report, request, scroll, scrollThread, span, src, temp, text, textContent, threadHiding, threads, tzOffset, ui, up, updateAuto, updateCallback, updateFavicon, updateInterval, updateNow, updateTime, updateTitle, updateVerbose, updaterMake, watch, watchX, watcher, watcherUpdate, _i, _j, _k, _l, _len, _len2, _len3, _len4, _len5, _len6, _len7, _m, _n, _ref, _ref2, _ref3, _ref4;
|
||||||
var __slice = Array.prototype.slice;
|
var __slice = Array.prototype.slice;
|
||||||
if (typeof console != "undefined" && console !== null) {
|
if (typeof console != "undefined" && console !== null) {
|
||||||
log = console.log;
|
log = console.log;
|
||||||
@ -226,6 +226,19 @@
|
|||||||
return object;
|
return object;
|
||||||
};
|
};
|
||||||
$.extend($, {
|
$.extend($, {
|
||||||
|
getValue: function(name, defaultValue) {
|
||||||
|
var value;
|
||||||
|
name = NAMESPACE + name;
|
||||||
|
if (value = localStorage[name]) {
|
||||||
|
return value = JSON.parse(value);
|
||||||
|
} else {
|
||||||
|
return defaultValue;
|
||||||
|
}
|
||||||
|
},
|
||||||
|
setValue: function(name, value) {
|
||||||
|
name = NAMESPACE + name;
|
||||||
|
return localStorage[name] = JSON.stringify(value);
|
||||||
|
},
|
||||||
addStyle: function(css) {
|
addStyle: function(css) {
|
||||||
var style;
|
var style;
|
||||||
style = document.createElement('style');
|
style = document.createElement('style');
|
||||||
@ -1592,6 +1605,7 @@
|
|||||||
return favicon.src = g.favEmpty;
|
return favicon.src = g.favEmpty;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
NAMESPACE = 'AEOS.4chan_x.';
|
||||||
g = {
|
g = {
|
||||||
callbacks: [],
|
callbacks: [],
|
||||||
expand: false,
|
expand: false,
|
||||||
|
|||||||
@ -127,6 +127,15 @@ $.extend = (object, properties) ->
|
|||||||
object
|
object
|
||||||
|
|
||||||
$.extend $,
|
$.extend $,
|
||||||
|
getValue: (name, defaultValue) ->
|
||||||
|
name = NAMESPACE + name
|
||||||
|
if value = localStorage[name]
|
||||||
|
value = JSON.parse value
|
||||||
|
else
|
||||||
|
defaultValue
|
||||||
|
setValue: (name, value) ->
|
||||||
|
name = NAMESPACE + name
|
||||||
|
localStorage[name] = JSON.stringify value
|
||||||
addStyle: (css) ->
|
addStyle: (css) ->
|
||||||
style = document.createElement 'style'
|
style = document.createElement 'style'
|
||||||
style.type = 'text/css'
|
style.type = 'text/css'
|
||||||
@ -1226,6 +1235,7 @@ watchX = ->
|
|||||||
|
|
||||||
|
|
||||||
#main
|
#main
|
||||||
|
NAMESPACE = 'AEOS.4chan_x.'
|
||||||
g =
|
g =
|
||||||
callbacks: []
|
callbacks: []
|
||||||
expand: false
|
expand: false
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user