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

Side by Side Diff: public/platform/WebPushPermissionCallback.h

Issue 658723003: Blink implementation of PushManager#hasPermission() (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years, 2 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
OLDNEW
(Empty)
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
3 // found in the LICENSE file.
4
5 #ifndef WebPushPermissionCallback_h
6 #define WebPushPermissionCallback_h
7
8 // Interface to be used by the embedder in order
9 // to inform Blink when once the permission status for push has been checked.
10 namespace blink {
11
12 class WebPushPermissionCallback {
Peter Beverloo 2014/10/20 12:23:49 Instead of re-inventing the callback API, can you
Miguel Garcia 2014/10/22 12:58:44 We discussed this at length with the main reviewer
13 public:
Michael van Ouwerkerk 2014/10/20 11:25:43 All of this indent -4. Just run "git cl format"
Miguel Garcia 2014/10/22 12:58:44 Done.
Miguel Garcia 2014/10/22 12:58:44 Done.
14
15 enum PushPermissionStatus {
16 PushPermissionGranted = 0,
Michael van Ouwerkerk 2014/10/20 11:25:43 Enum members must start with the full enum name.
Miguel Garcia 2014/10/22 12:58:44 Done.
17 PushPermissionDenied,
18 PushPermissionDefault,
19
20 // Used for IPC message range checks.
21 PushPermissionTypeLast = PushPermissionDefault
22 };
23
24 virtual ~WebPushPermissionCallback() { }
25
26 // Called if the embedder is able to check the status of the push permis sion.
27 virtual void onSuccess(PushPermissionStatus) = 0;
28
29 // Called if for some reason the status of the push permission cannot be checked.
30 virtual void onError() = 0;
31 };
32
33 } // namespace blink
Peter Beverloo 2014/10/20 12:23:49 nit: new line after this one.
Miguel Garcia 2014/10/22 12:58:44 Done.
34 #endif // WebPushPermissionCallback_h
OLDNEW
« public/platform/WebPushClient.h ('K') | « public/platform/WebPushClient.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698