Add Thread::callbacks and Post::callbacks.

This commit is contained in:
Nicolas Stepien 2012-08-27 04:41:13 +02:00
parent 4a3da8bafb
commit fbf7fc0cdc
2 changed files with 6 additions and 0 deletions

View File

@ -624,6 +624,8 @@
g.threads["" + board.ID + "." + this.ID] = board.threads[this.ID] = this; g.threads["" + board.ID + "." + this.ID] = board.threads[this.ID] = this;
} }
Thread.prototype.callbacks = [];
return Thread; return Thread;
})(); })();
@ -639,6 +641,8 @@
g.posts["" + board.ID + "." + this.ID] = thread.posts[this.ID] = board.posts[this.ID] = this; g.posts["" + board.ID + "." + this.ID] = thread.posts[this.ID] = board.posts[this.ID] = this;
} }
Post.prototype.callbacks = [];
return Post; return Post;
})(); })();

View File

@ -486,6 +486,7 @@ class Thread
@posts = {} @posts = {}
g.threads["#{board.ID}.#{@ID}"] = board.threads[@ID] = @ g.threads["#{board.ID}.#{@ID}"] = board.threads[@ID] = @
callbacks: []
class Post class Post
constructor: (@root, @thread, @board) -> constructor: (@root, @thread, @board) ->
@ -493,6 +494,7 @@ class Post
@el = $ '.post', root @el = $ '.post', root
g.posts["#{board.ID}.#{@ID}"] = thread.posts[@ID] = board.posts[@ID] = @ g.posts["#{board.ID}.#{@ID}"] = thread.posts[@ID] = board.posts[@ID] = @
callbacks: []
Main = Main =
init: -> init: ->