As it is the flag links do not link to the actual translated thread URL. This is creating a lot of extra redirects and really isn't good for overall SEO. Please keep alternate tags in mind as well.
I'm not sure exactly how this could be done on the fly, but I would hope the thread URLs could be cached in some way as to not increase the amount of queries per page.