Bug 1061215 - [Messages][Refactoring] Improve handling of remaining chars counter. r=schung

can't we have a class for this too ? :)