Cleanups for VTTTokenizer

Get rid of VTTTokenizer::m_token, and hence remove the need to play
games with pointers to the resulting token, since the token is now
produced at the end of VTTTokenizer::nextToken. This renders the reset()
method empty (and it wasn't previously used outside of VTTTokenizer), so
remove it.

Make a local, tailored, version of the ADVANCE_TO macro to get rid of the
redundant check of advance(). This in turn allows removing the (now
useless) part of the scaffolding which is haveBufferedCharacterToken(),
as well as turning VTTTokenizer::m_state into the local 'state' and
moving the definition of the state enumeration into the cpp-file.
This also means the state defintions can be moved from the header-file,
so do that as well.

BUG=319391

Review URL: https://codereview.chromium.org/98763004

git-svn-id: svn://svn.chromium.org/blink/trunk@162994 bbb929c8-8fbe-4397-9dbb-9b2b20218538
2 files changed
tree: 799eb4622a6418dbc21b4f7b7b8143ff56ce530b
  1. third_party/