DateFormat dateFormat = DateFormat.getInstance();
HTMLNode table = threadsTable.addChild("tbody");
final WoTIdentityManager identityManager = mFreetalk.getIdentityManager();
// TODO: We don't want to lock the identity manager here to make the displaying of the board FAST - it shouldn't wait until the lock
// is available: Introduce a non-locking getIdentity() in the identity manager and use it - the locking one will cause deadlocks
// if we do not lock the identity manager before the board.
synchronized(identityManager) {
synchronized(mBoard) {
boolean firstUnread = true;
for(BoardThreadLink threadReference : mBoard.getThreads()) {
// TODO: The author in the threadReference is guessed from the ID if the thread was not downloaded...
// we should display a warning that the fact "the original thread was written by X" might not be true because
// thread-IDs can be spoofed - dunno how to do that in the table, maybe with colors?
String authorText;
String authorScore;
// Author related stuff
{
Identity author = null;
// TODO: Use a colored "unknown" if the author/score is unknown
// TODO: Use a special color if author == yourself
authorText = "?"; // TODO: l10n
authorScore = "?";
try {
author = identityManager.getIdentity(threadReference.getAuthorID());
authorText = author.getShortestUniqueName();
// TODO: Get rid of the cast somehow, we should maybe call this WoTBoardPage :|
final int score = ((WoTOwnIdentity)mOwnIdentity).getScoreFor((WoTIdentity)author);
if (score == Integer.MAX_VALUE)