diff options
author | amogh.bihani <amogh.bihani@samsung.com> | 2014-08-31 23:06:51 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2014-09-01 06:09:32 +0000 |
commit | ee85a1188ee2454e62dc24c58477df39970a990b (patch) | |
tree | 65d471266bae846beb2dc5a85a71f4540fb1f3f3 /url | |
parent | dd5a6c66313724c6f009db75ccb488639286cef9 (diff) | |
download | chromium_src-ee85a1188ee2454e62dc24c58477df39970a990b.zip chromium_src-ee85a1188ee2454e62dc24c58477df39970a990b.tar.gz chromium_src-ee85a1188ee2454e62dc24c58477df39970a990b.tar.bz2 |
Updating buffered duration of local resource in android
OnBufferingUpdate does not work for local resources. Because of this
the buffered range does not get updated. This patch updates the bufferd
range atleast untill the video has played so that media controls can be
painted properly.
TBR=abarth@chromium.org
BUG=405474
Review URL: https://codereview.chromium.org/496683002
Cr-Commit-Position: refs/heads/master@{#292837}
Diffstat (limited to 'url')
-rw-r--r-- | url/gurl.h | 5 | ||||
-rw-r--r-- | url/gurl_unittest.cc | 6 |
2 files changed, 11 insertions, 0 deletions
@@ -236,6 +236,11 @@ class URL_EXPORT GURL { (SchemeIsFileSystem() && inner_url() && inner_url()->SchemeIsSecure()); } + // Returns true if the scheme is "blob". + bool SchemeIsBlob() const { + return SchemeIs(url::kBlobScheme); + } + // The "content" of the URL is everything after the scheme (skipping the // scheme delimiting colon). It is an error to get the origin of an invalid // URL. The result will be an empty string. diff --git a/url/gurl_unittest.cc b/url/gurl_unittest.cc index 489b9d2..f38d7f9 100644 --- a/url/gurl_unittest.cc +++ b/url/gurl_unittest.cc @@ -635,4 +635,10 @@ TEST(GURLTest, SchemeIsWSOrWSS) { EXPECT_FALSE(GURL("http://bar/").SchemeIsWSOrWSS()); } +TEST(GURLTest, SchemeIsBlob) { + EXPECT_TRUE(GURL("BLOB://BAR/").SchemeIsBlob()); + EXPECT_TRUE(GURL("blob://bar/").SchemeIsBlob()); + EXPECT_FALSE(GURL("http://bar/").SchemeIsBlob()); +} + } // namespace url |