Merge branch 'testing'

This commit is contained in:
ccd0 2014-05-24 01:29:17 -07:00
commit e8d8e639dd
2 changed files with 4 additions and 2 deletions

View File

@ -131,6 +131,7 @@ Get =
$.cache url, $.cache url,
-> Get.archivedPost @, boardID, postID, root, context -> Get.archivedPost @, boardID, postID, root, context
, ,
responseType: 'json'
withCredentials: url.archive.withCredentials withCredentials: url.archive.withCredentials
else else
$.addClass root, 'warning' $.addClass root, 'warning'

View File

@ -18,10 +18,11 @@ Fourchan =
# https://github.com/MayhemYDG/4chan-x/issues/645#issuecomment-13704562 # https://github.com/MayhemYDG/4chan-x/issues/645#issuecomment-13704562
$.globalEval ''' $.globalEval '''
window.addEventListener('jsmath', function(e) { window.addEventListener('jsmath', function(e) {
if (!jsMath) return;
if (jsMath.loaded) { if (jsMath.loaded) {
// process one post // process one post
jsMath.ProcessBeforeShowing(e.detail); jsMath.ProcessBeforeShowing(e.detail);
} else { } else if (jsMath.Autoload && jsMath.Autoload.checked) {
// load jsMath and process whole document // load jsMath and process whole document
jsMath.Autoload.Script.Push('ProcessBeforeShowing', [null]); jsMath.Autoload.Script.Push('ProcessBeforeShowing', [null]);
jsMath.Autoload.LoadJsMath(); jsMath.Autoload.LoadJsMath();
@ -40,7 +41,7 @@ Fourchan =
$.off window, 'prettyprint:cb', apply $.off window, 'prettyprint:cb', apply
return return
math: -> math: ->
return if @isClone or !$ '.math', @nodes.comment return if (@isClone and doc.contains @origin.nodes.root) or !$ '.math', @nodes.comment
$.event 'jsmath', @nodes.post, window $.event 'jsmath', @nodes.post, window
parseThread: (threadID, offset, limit) -> parseThread: (threadID, offset, limit) ->
# Fix /sci/ # Fix /sci/