Changeset 271725 in webkit


Ignore:
Timestamp:
Jan 21, 2021 5:10:51 PM (18 months ago)
Author:
Peng Liu
Message:

Videos on Facebook Stories do not play
https://bugs.webkit.org/show_bug.cgi?id=220834

Reviewed by Jer Noble.

Add a quirk (for the iOS port) to allow videos (with audio) on Facebook stories to play.

  • page/Quirks.cpp:

(WebCore::Quirks::shouldAutoplayForArbitraryUserGesture const):

Location:
trunk/Source/WebCore
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r271723 r271725  
     12021-01-21  Peng Liu  <peng.liu6@apple.com>
     2
     3        Videos on Facebook Stories do not play
     4        https://bugs.webkit.org/show_bug.cgi?id=220834
     5
     6        Reviewed by Jer Noble.
     7
     8        Add a quirk (for the iOS port) to allow videos (with audio) on Facebook stories to play.
     9
     10        * page/Quirks.cpp:
     11        (WebCore::Quirks::shouldAutoplayForArbitraryUserGesture const):
     12
    1132021-01-21  Sam Weinig  <weinig@apple.com>
    214
  • trunk/Source/WebCore/page/Quirks.cpp

    r271667 r271725  
    151151        return false;
    152152
    153     auto host = m_document->url().host();
    154     return equalLettersIgnoringASCIICase(host, "twitter.com") || host.endsWithIgnoringASCIICase(".twitter.com");
     153    auto domain = RegistrableDomain { m_document->topDocument().url() };
     154    return domain == "twitter.com"_s || domain == "facebook.com"_s;
    155155#endif
    156156}
Note: See TracChangeset for help on using the changeset viewer.