Index: third_party/WebKit/Source/core/css/CSSImageSetValue.cpp |
diff --git a/third_party/WebKit/Source/core/css/CSSImageSetValue.cpp b/third_party/WebKit/Source/core/css/CSSImageSetValue.cpp |
index a1fdbd14778d3dff499a62718d1cdd1314636808..3f5cb8ab1f2ee36007ff732fbaf08cbfd8aa95d0 100644 |
--- a/third_party/WebKit/Source/core/css/CSSImageSetValue.cpp |
+++ b/third_party/WebKit/Source/core/css/CSSImageSetValue.cpp |
@@ -29,6 +29,7 @@ |
#include "core/css/CSSImageValue.h" |
#include "core/css/CSSPrimitiveValue.h" |
#include "core/dom/Document.h" |
+#include "core/dom/TaskRunnerHelper.h" |
#include "core/frame/Settings.h" |
#include "core/loader/resource/ImageResourceContent.h" |
#include "core/style/StyleFetchedImageSet.h" |
@@ -123,8 +124,11 @@ StyleImage* CSSImageSetValue::CacheImage( |
document.GetSettings()->GetFetchImagePlaceholders()) |
params.SetAllowImagePlaceholder(); |
- if (ImageResourceContent* cached_image = |
- ImageResourceContent::Fetch(params, document.Fetcher())) { |
+ // TODO(delphick): const_cast |
+ RefPtr<WebTaskRunner> task_runner = TaskRunnerHelper::Get( |
Sami
2017/04/27 17:38:17
Interesting, can TaskRunnerHelper be changed to ta
Dan Elphick
2017/05/03 09:41:06
not required now we're not using getting the sched
|
+ TaskType::kAnimationTimer, const_cast<Document*>(&document)); |
+ if (ImageResourceContent* cached_image = ImageResourceContent::Fetch( |
+ task_runner, params, document.Fetcher())) { |
cached_image_ = StyleFetchedImageSet::Create( |
cached_image, image.scale_factor, this, params.Url()); |
} else { |