[Mac] forced subtitle track should change when audio track language changes
https://bugs.webkit.org/show_bug.cgi?id=115043

Reviewed by Jer Noble.

No new tests, it isn't possible to test this automatically because there is currently no way
to enable/disable audio tracks.

* html/HTMLMediaElement.cpp:
(WebCore::HTMLMediaElement::configureTextTrackGroup): Set m_forcedOrAutomaticSubtitleTrackLanguage.
(WebCore::HTMLMediaElement::mediaPlayerCharacteristicChanged):  Call markCaptionAndSubtitleTracksAsUnconfigured
    after a delay if the language of the primary audio track changes.
(WebCore::HTMLMediaElement::setClosedCaptionsVisible): markCaptionAndSubtitleTracksAsUnconfigured API change.
(WebCore::HTMLMediaElement::markCaptionAndSubtitleTracksAsUnconfigured): Take parameter to allow
    the reconfiguration to happen after a delay to avoid doing it during a callback from the
    media engine. Clear the ConfigureTextTracks bit in m_pendingActionFlags to cancel any pending 
    asynch configuration.
* html/HTMLMediaElement.h:

* page/CaptionUserPreferencesMac.mm:
(WebCore::CaptionUserPreferencesMac::textTrackSelectionScore): Clean up logic.

* platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
(WebCore::MediaPlayerPrivateAVFoundationObjC::tracksChanged): Call characteristicChanged when
    the primary audio track language changes.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@149005 268f45cc-cd09-0410-ab3c-d52691b4dbfc