Add a flushing mechanism for the WebVTTParser

In the WebVTT parser there's an ad-hoc "end-of-stream" check for when
a pending cue should be flushed from the parser. The condition used
however is not reliable given multiple buffers.

To rectify this, add a flush() method to WebVTTParser, and call it
from TextTrackLoader::notifyFinished. Then let this new flush() method
take care of flushing any pending cue from the parser.

BUG=231460

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

git-svn-id: svn://svn.chromium.org/blink/trunk@161519 bbb929c8-8fbe-4397-9dbb-9b2b20218538