Followup (r222427): SynchronizedFixedQueue should not have a public constructor
authorcommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 26 Sep 2017 22:40:51 +0000 (22:40 +0000)
committercommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 26 Sep 2017 22:40:51 +0000 (22:40 +0000)
commitc4ecb898dc811cf0ae38fa7c7de009bbdd3d8b89
treebdf549e0fb7bee46f3f95a5543a02e5f549c4796
parent6d5a89457866635779f3dbc23605053f7a1583cb
Followup (r222427): SynchronizedFixedQueue should not have a public constructor
https://bugs.webkit.org/show_bug.cgi?id=177458

Patch by Said Abou-Hallawa <sabouhallawa@apple.com> on 2017-09-26
Reviewed by Tim Horton.

Source/WebCore:

ImageFrameCache::decodingQueue() and frameRequestQueue() should return
raw references instead of Ref objects.

* platform/graphics/ImageFrameCache.cpp:
(WebCore::ImageFrameCache::decodingQueue):
(WebCore::ImageFrameCache::frameRequestQueue):
(WebCore::ImageFrameCache::startAsyncDecodingQueue):
* platform/graphics/ImageFrameCache.h:

Source/WTF:

Since SynchronizedFixedQueue is now derived from ThreadSafeRefCounted<SynchronizedFixedQueue>,
the standard way to have an instance of it is to call SynchronizedFixedQueue::create()
which returns a Ref<SynchronizedFixedQueue>. Now it does not make sense to still
have the constructor public.

* wtf/SynchronizedFixedQueue.h:
(WTF::SynchronizedFixedQueue::SynchronizedFixedQueue):

Tools:

Fix the definition and the creation of SynchronizedFixedQueue.

* TestWebKitAPI/Tests/WTF/SynchronizedFixedQueue.cpp:
(TestWebKitAPI::ToUpperConverter::ToUpperConverter):
(TestWebKitAPI::ToUpperConverter::startProducing):
(TestWebKitAPI::ToUpperConverter::startConsuming):
(TestWebKitAPI::ToUpperConverter::stopProducing):
(TestWebKitAPI::ToUpperConverter::stopConsuming):
(TestWebKitAPI::ToUpperConverter::enqueueLower):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@222530 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Source/WTF/ChangeLog
Source/WTF/wtf/SynchronizedFixedQueue.h
Source/WebCore/ChangeLog
Source/WebCore/platform/graphics/ImageFrameCache.cpp
Source/WebCore/platform/graphics/ImageFrameCache.h
Tools/ChangeLog
Tools/TestWebKitAPI/Tests/WTF/SynchronizedFixedQueue.cpp