Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(264)

Side by Side Diff: Source/web/ServiceWorkerGlobalScopeClientImpl.cpp

Issue 255983003: Oilpan: Move all supplements of Page, Document, and WorkerClients to the managed heap. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: using namespace WebCore Created 6 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « Source/web/ServiceWorkerGlobalScopeClientImpl.h ('k') | Source/web/StorageQuotaClientImpl.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2014 Google Inc. All rights reserved. 2 * Copyright (C) 2014 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 20 matching lines...) Expand all
31 #include "config.h" 31 #include "config.h"
32 #include "web/ServiceWorkerGlobalScopeClientImpl.h" 32 #include "web/ServiceWorkerGlobalScopeClientImpl.h"
33 33
34 #include "modules/serviceworkers/Response.h" 34 #include "modules/serviceworkers/Response.h"
35 #include "platform/NotImplemented.h" 35 #include "platform/NotImplemented.h"
36 #include "public/platform/WebServiceWorkerResponse.h" 36 #include "public/platform/WebServiceWorkerResponse.h"
37 #include "public/platform/WebURL.h" 37 #include "public/platform/WebURL.h"
38 #include "public/web/WebServiceWorkerContextClient.h" 38 #include "public/web/WebServiceWorkerContextClient.h"
39 #include "wtf/PassOwnPtr.h" 39 #include "wtf/PassOwnPtr.h"
40 40
41 using namespace WebCore;
42
41 namespace blink { 43 namespace blink {
42 44
43 PassOwnPtr<WebCore::ServiceWorkerGlobalScopeClient> ServiceWorkerGlobalScopeClie ntImpl::create(PassOwnPtr<WebServiceWorkerContextClient> client) 45 PassOwnPtrWillBeRawPtr<ServiceWorkerGlobalScopeClient> ServiceWorkerGlobalScopeC lientImpl::create(PassOwnPtr<WebServiceWorkerContextClient> client)
44 { 46 {
45 return adoptPtr(new ServiceWorkerGlobalScopeClientImpl(client)); 47 return adoptPtrWillBeNoop(new ServiceWorkerGlobalScopeClientImpl(client));
46 } 48 }
47 49
48 ServiceWorkerGlobalScopeClientImpl::~ServiceWorkerGlobalScopeClientImpl() 50 ServiceWorkerGlobalScopeClientImpl::~ServiceWorkerGlobalScopeClientImpl()
49 { 51 {
50 } 52 }
51 53
52 void ServiceWorkerGlobalScopeClientImpl::getClients(WebServiceWorkerClientsCallb acks* callbacks) 54 void ServiceWorkerGlobalScopeClientImpl::getClients(WebServiceWorkerClientsCallb acks* callbacks)
53 { 55 {
54 m_client->getClients(callbacks); 56 m_client->getClients(callbacks);
55 } 57 }
56 58
57 WebURL ServiceWorkerGlobalScopeClientImpl::scope() const 59 WebURL ServiceWorkerGlobalScopeClientImpl::scope() const
58 { 60 {
59 return m_client->scope(); 61 return m_client->scope();
60 } 62 }
61 63
62 void ServiceWorkerGlobalScopeClientImpl::didHandleActivateEvent(int eventID, Web ServiceWorkerEventResult result) 64 void ServiceWorkerGlobalScopeClientImpl::didHandleActivateEvent(int eventID, Web ServiceWorkerEventResult result)
63 { 65 {
64 m_client->didHandleActivateEvent(eventID, result); 66 m_client->didHandleActivateEvent(eventID, result);
65 } 67 }
66 68
67 void ServiceWorkerGlobalScopeClientImpl::didHandleInstallEvent(int installEventI D, WebServiceWorkerEventResult result) 69 void ServiceWorkerGlobalScopeClientImpl::didHandleInstallEvent(int installEventI D, WebServiceWorkerEventResult result)
68 { 70 {
69 m_client->didHandleInstallEvent(installEventID, result); 71 m_client->didHandleInstallEvent(installEventID, result);
70 } 72 }
71 73
72 void ServiceWorkerGlobalScopeClientImpl::didHandleFetchEvent(int fetchEventID, P assRefPtr<WebCore::Response> response) 74 void ServiceWorkerGlobalScopeClientImpl::didHandleFetchEvent(int fetchEventID, P assRefPtr<Response> response)
73 { 75 {
74 if (!response) { 76 if (!response) {
75 m_client->didHandleFetchEvent(fetchEventID); 77 m_client->didHandleFetchEvent(fetchEventID);
76 return; 78 return;
77 } 79 }
78 80
79 WebServiceWorkerResponse webResponse; 81 WebServiceWorkerResponse webResponse;
80 response->populateWebServiceWorkerResponse(webResponse); 82 response->populateWebServiceWorkerResponse(webResponse);
81 m_client->didHandleFetchEvent(fetchEventID, webResponse); 83 m_client->didHandleFetchEvent(fetchEventID, webResponse);
82 } 84 }
83 85
84 void ServiceWorkerGlobalScopeClientImpl::didHandleSyncEvent(int syncEventID) 86 void ServiceWorkerGlobalScopeClientImpl::didHandleSyncEvent(int syncEventID)
85 { 87 {
86 m_client->didHandleSyncEvent(syncEventID); 88 m_client->didHandleSyncEvent(syncEventID);
87 } 89 }
88 90
89 ServiceWorkerGlobalScopeClientImpl::ServiceWorkerGlobalScopeClientImpl(PassOwnPt r<WebServiceWorkerContextClient> client) 91 ServiceWorkerGlobalScopeClientImpl::ServiceWorkerGlobalScopeClientImpl(PassOwnPt r<WebServiceWorkerContextClient> client)
90 : m_client(client) 92 : m_client(client)
91 { 93 {
92 ASSERT(m_client); 94 ASSERT(m_client);
93 } 95 }
94 96
95 } // namespace blink 97 } // namespace blink
OLDNEW
« no previous file with comments | « Source/web/ServiceWorkerGlobalScopeClientImpl.h ('k') | Source/web/StorageQuotaClientImpl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698