Changeset 167789 in webkit


Ignore:
Timestamp:
Apr 24, 2014 8:59:46 PM (10 years ago)
Author:
gyuyoung.kim@samsung.com
Message:

Mark Supplement instead of RefCountedSupplement in NavigatorContentUtils
https://bugs.webkit.org/show_bug.cgi?id=132151

Reviewed by Darin Adler.

Though Original goal was to make it sharable across navigator instances, the NavigatorContentUtils
has used RefCountedSupplement<Page> instead of RefCountedSupplement<Navigator>. This patch makes it
use Supplement<Page> because there is no scenario which needs to be shared across navigator instances.

Blink merge from https://src.chromium.org/viewvc/blink?view=rev&revision=171403.

No new tests, no behavior changes.

  • Modules/navigatorcontentutils/NavigatorContentUtils.cpp:

(WebCore::NavigatorContentUtils::from):
(WebCore::NavigatorContentUtils::create):
(WebCore::provideNavigatorContentUtilsTo):

  • Modules/navigatorcontentutils/NavigatorContentUtils.h:
Location:
trunk/Source/WebCore
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r167788 r167789  
     12014-04-24  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
     2
     3        Mark Supplement instead of RefCountedSupplement in NavigatorContentUtils
     4        https://bugs.webkit.org/show_bug.cgi?id=132151
     5
     6        Reviewed by Darin Adler.
     7
     8        Though Original goal was to make it sharable across navigator instances, the NavigatorContentUtils
     9        has used RefCountedSupplement<Page> instead of RefCountedSupplement<Navigator>. This patch makes it
     10        use Supplement<Page> because there is no scenario which needs to be shared across navigator instances.
     11
     12        Blink merge from https://src.chromium.org/viewvc/blink?view=rev&revision=171403.
     13
     14        No new tests, no behavior changes.
     15
     16        * Modules/navigatorcontentutils/NavigatorContentUtils.cpp:
     17        (WebCore::NavigatorContentUtils::from):
     18        (WebCore::NavigatorContentUtils::create):
     19        (WebCore::provideNavigatorContentUtilsTo):
     20        * Modules/navigatorcontentutils/NavigatorContentUtils.h:
     21
    1222014-04-24  Commit Queue  <commit-queue@webkit.org>
    223
  • trunk/Source/WebCore/Modules/navigatorcontentutils/NavigatorContentUtils.cpp

    r167308 r167789  
    120120NavigatorContentUtils* NavigatorContentUtils::from(Page* page)
    121121{
    122     return static_cast<NavigatorContentUtils*>(RefCountedSupplement<Page, NavigatorContentUtils>::from(page, NavigatorContentUtils::supplementName()));
     122    return static_cast<NavigatorContentUtils*>(Supplement<Page>::from(page, supplementName()));
    123123}
    124124
     
    127127}
    128128
    129 PassRef<NavigatorContentUtils> NavigatorContentUtils::create(std::unique_ptr<NavigatorContentUtilsClient> client)
    130 {
    131     return adoptRef(*new NavigatorContentUtils(std::move(client)));
     129PassOwnPtr<NavigatorContentUtils> NavigatorContentUtils::create(std::unique_ptr<NavigatorContentUtilsClient> client)
     130{
     131    return adoptPtr(new NavigatorContentUtils(std::move(client)));
    132132}
    133133
     
    210210void provideNavigatorContentUtilsTo(Page* page, std::unique_ptr<NavigatorContentUtilsClient> client)
    211211{
    212     RefCountedSupplement<Page, NavigatorContentUtils>::provideTo(page, NavigatorContentUtils::supplementName(), NavigatorContentUtils::create(std::move(client)));
     212    NavigatorContentUtils::provideTo(page, NavigatorContentUtils::supplementName(), NavigatorContentUtils::create(std::move(client)));
    213213}
    214214
  • trunk/Source/WebCore/Modules/navigatorcontentutils/NavigatorContentUtils.h

    r166915 r167789  
    4242typedef int ExceptionCode;
    4343
    44 class NavigatorContentUtils final : public RefCountedSupplement<Page, NavigatorContentUtils> {
     44class NavigatorContentUtils final : public Supplement<Page> {
    4545public:
    4646    virtual ~NavigatorContentUtils();
     
    5656#endif
    5757
    58     static PassRef<NavigatorContentUtils> create(std::unique_ptr<NavigatorContentUtilsClient>);
     58    static PassOwnPtr<NavigatorContentUtils> create(std::unique_ptr<NavigatorContentUtilsClient>);
    5959
    6060private:
Note: See TracChangeset for help on using the changeset viewer.