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

Side by Side Diff: content/renderer/push_messaging_dispatcher.h

Issue 366323002: Push API: use an enum to indicate status. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase. Tweak mock error message. Created 6 years, 5 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
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CONTENT_RENDERER_PUSH_MESSAGING_DISPATCHER_H_ 5 #ifndef CONTENT_RENDERER_PUSH_MESSAGING_DISPATCHER_H_
6 #define CONTENT_RENDERER_PUSH_MESSAGING_DISPATCHER_H_ 6 #define CONTENT_RENDERER_PUSH_MESSAGING_DISPATCHER_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/id_map.h" 10 #include "base/id_map.h"
11 #include "content/public/common/push_messaging_status.h"
11 #include "content/public/renderer/render_frame_observer.h" 12 #include "content/public/renderer/render_frame_observer.h"
12 #include "third_party/WebKit/public/platform/WebPushClient.h" 13 #include "third_party/WebKit/public/platform/WebPushClient.h"
13 14
14 class GURL; 15 class GURL;
15 16
16 namespace IPC { 17 namespace IPC {
17 class Message; 18 class Message;
18 } // namespace IPC 19 } // namespace IPC
19 20
20 namespace blink { 21 namespace blink {
(...skipping 20 matching lines...) Expand all
41 blink::WebPushRegistrationCallbacks* callbacks); 42 blink::WebPushRegistrationCallbacks* callbacks);
42 virtual void registerPushMessaging( 43 virtual void registerPushMessaging(
43 const blink::WebString& sender_id, 44 const blink::WebString& sender_id,
44 blink::WebPushRegistrationCallbacks* callbacks, 45 blink::WebPushRegistrationCallbacks* callbacks,
45 blink::WebServiceWorkerProvider* service_worker_provider); 46 blink::WebServiceWorkerProvider* service_worker_provider);
46 47
47 void OnRegisterSuccess(int32 callbacks_id, 48 void OnRegisterSuccess(int32 callbacks_id,
48 const GURL& endpoint, 49 const GURL& endpoint,
49 const std::string& registration_id); 50 const std::string& registration_id);
50 51
51 void OnRegisterError(int32 callbacks_id); 52 void OnRegisterError(int32 callbacks_id, PushMessagingStatus status);
52 53
53 IDMap<blink::WebPushRegistrationCallbacks, IDMapOwnPointer> 54 IDMap<blink::WebPushRegistrationCallbacks, IDMapOwnPointer>
54 registration_callbacks_; 55 registration_callbacks_;
55 56
56 DISALLOW_COPY_AND_ASSIGN(PushMessagingDispatcher); 57 DISALLOW_COPY_AND_ASSIGN(PushMessagingDispatcher);
57 }; 58 };
58 59
59 } // namespace content 60 } // namespace content
60 61
61 #endif // CONTENT_RENDERER_PUSH_MESSAGING_DISPATCHER_H_ 62 #endif // CONTENT_RENDERER_PUSH_MESSAGING_DISPATCHER_H_
OLDNEW
« no previous file with comments | « content/public/common/push_messaging_status.cc ('k') | content/renderer/push_messaging_dispatcher.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698