Holy shit, it's working.
This commit is contained in:
parent
890277f296
commit
226ea6c27c
@ -2994,7 +2994,7 @@
|
||||
return nodes;
|
||||
},
|
||||
fullThread: function(board, data) {
|
||||
return [Build.postFromObject(data, board.ID)];
|
||||
return Build.postFromObject(data, board.ID);
|
||||
}
|
||||
};
|
||||
|
||||
@ -12066,11 +12066,10 @@
|
||||
}
|
||||
},
|
||||
parse: function(data) {
|
||||
var OP, board, errors, makePost, nodes, obj, post, posts, thread, threadRoot, _i, _len;
|
||||
var OP, board, errors, makePost, obj, post, posts, thread, threadRoot, _i, _len;
|
||||
board = g.BOARD;
|
||||
threadRoot = Build.thread(board, OP = data.shift(), true);
|
||||
Navigate.threadRoot = threadRoot = Build.thread(board, OP = data.shift(), true);
|
||||
thread = new Thread(OP.no, board);
|
||||
nodes = [threadRoot];
|
||||
posts = [];
|
||||
errors = null;
|
||||
makePost = function(postNode) {
|
||||
@ -12091,13 +12090,13 @@
|
||||
makePost($('.opContainer', threadRoot));
|
||||
for (_i = 0, _len = data.length; _i < _len; _i++) {
|
||||
obj = data[_i];
|
||||
nodes.push(post = Build.postFromObject(obj, board));
|
||||
post = Build.postFromObject(obj, board);
|
||||
makePost(post);
|
||||
$.add(threadRoot, post);
|
||||
}
|
||||
if (errors) {
|
||||
Main.handleErrors(errors);
|
||||
}
|
||||
$.nodes(Navigate.nodes = nodes);
|
||||
Main.callbackNodes(Thread, [thread]);
|
||||
Main.callbackNodes(Post, posts);
|
||||
Navigate.ready();
|
||||
@ -12108,7 +12107,7 @@
|
||||
var board;
|
||||
board = $('.board');
|
||||
$.rmAll(board);
|
||||
return $.add(board, Navigate.nodes);
|
||||
return $.add(board, Navigate.threadRoot);
|
||||
},
|
||||
popstate: function() {
|
||||
var a;
|
||||
|
||||
@ -3004,7 +3004,7 @@
|
||||
return nodes;
|
||||
},
|
||||
fullThread: function(board, data) {
|
||||
return [Build.postFromObject(data, board.ID)];
|
||||
return Build.postFromObject(data, board.ID);
|
||||
}
|
||||
};
|
||||
|
||||
@ -12055,11 +12055,10 @@
|
||||
}
|
||||
},
|
||||
parse: function(data) {
|
||||
var OP, board, errors, makePost, nodes, obj, post, posts, thread, threadRoot, _i, _len;
|
||||
var OP, board, errors, makePost, obj, post, posts, thread, threadRoot, _i, _len;
|
||||
board = g.BOARD;
|
||||
threadRoot = Build.thread(board, OP = data.shift(), true);
|
||||
Navigate.threadRoot = threadRoot = Build.thread(board, OP = data.shift(), true);
|
||||
thread = new Thread(OP.no, board);
|
||||
nodes = [threadRoot];
|
||||
posts = [];
|
||||
errors = null;
|
||||
makePost = function(postNode) {
|
||||
@ -12080,13 +12079,13 @@
|
||||
makePost($('.opContainer', threadRoot));
|
||||
for (_i = 0, _len = data.length; _i < _len; _i++) {
|
||||
obj = data[_i];
|
||||
nodes.push(post = Build.postFromObject(obj, board));
|
||||
post = Build.postFromObject(obj, board);
|
||||
makePost(post);
|
||||
$.add(threadRoot, post);
|
||||
}
|
||||
if (errors) {
|
||||
Main.handleErrors(errors);
|
||||
}
|
||||
$.nodes(Navigate.nodes = nodes);
|
||||
Main.callbackNodes(Thread, [thread]);
|
||||
Main.callbackNodes(Post, posts);
|
||||
Navigate.ready();
|
||||
@ -12097,7 +12096,7 @@
|
||||
var board;
|
||||
board = $('.board');
|
||||
$.rmAll(board);
|
||||
return $.add(board, Navigate.nodes);
|
||||
return $.add(board, Navigate.threadRoot);
|
||||
},
|
||||
popstate: function() {
|
||||
return Navigate.popstate = function() {
|
||||
|
||||
@ -233,5 +233,4 @@ Build =
|
||||
nodes.push Build.summary board.ID, data.no, posts, files
|
||||
nodes
|
||||
|
||||
fullThread: (board, data) ->
|
||||
[Build.postFromObject data, board.ID]
|
||||
fullThread: (board, data) -> Build.postFromObject data, board.ID
|
||||
@ -217,10 +217,9 @@ Navigate =
|
||||
|
||||
parse: (data) ->
|
||||
board = g.BOARD
|
||||
threadRoot = Build.thread board, OP = data.shift(), true
|
||||
Navigate.threadRoot = threadRoot = Build.thread board, OP = data.shift(), true
|
||||
thread = new Thread OP.no, board
|
||||
|
||||
nodes = [threadRoot]
|
||||
posts = []
|
||||
errors = null
|
||||
|
||||
@ -237,13 +236,12 @@ Navigate =
|
||||
makePost $('.opContainer', threadRoot)
|
||||
|
||||
for obj in data
|
||||
nodes.push post = Build.postFromObject obj, board
|
||||
post = Build.postFromObject obj, board
|
||||
makePost post
|
||||
$.add threadRoot, post
|
||||
|
||||
Main.handleErrors errors if errors
|
||||
|
||||
# Add the thread to a container to make sure all features work.
|
||||
$.nodes Navigate.nodes = nodes
|
||||
Main.callbackNodes Thread, [thread]
|
||||
Main.callbackNodes Post, posts
|
||||
|
||||
@ -255,7 +253,7 @@ Navigate =
|
||||
buildThread: ->
|
||||
board = $ '.board'
|
||||
$.rmAll board
|
||||
$.add board, Navigate.nodes
|
||||
$.add board, Navigate.threadRoot
|
||||
|
||||
popstate: -> <% if (type === 'crx') { %> Navigate.popstate = -> <% } %> # blink/webkit throw a popstate on page load. Not what we want.
|
||||
a = $.el 'a',
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user