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

Side by Side Diff: public/platform/modules/background_sync/WebSyncRegistration.h

Issue 950013002: Add platform files for Background Sync API (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Make platform methods pure virtual Created 5 years, 9 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
« no previous file with comments | « public/platform/modules/background_sync/WebSyncProvider.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 // Copyright 2015 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 WebSyncRegistration_h
6 #define WebSyncRegistration_h
7
8 #include "public/platform/WebPrivatePtr.h"
9 #include "public/platform/WebString.h"
10
11 namespace blink {
12
13 struct WebSyncRegistrationOptions {
14 enum NetworkType {
15 NetworkTypeAny = 0,
16 NetworkTypeOffline,
17 NetworkTypeOnline,
18 NetworkTypeNonMobile,
19 NetworkTypeLast = NetworkTypeNonMobile
20 };
21
22 WebSyncRegistrationOptions(NetworkType networkType, bool allowOnBattery, boo l idleRequired)
23 : networkType(networkType)
24 , allowOnBattery(allowOnBattery)
25 , idleRequired(idleRequired)
26 {
27 }
28
29 NetworkType networkType;
30 bool allowOnBattery;
31 bool idleRequired;
32 };
33
34
35 struct WebSyncRegistration {
36 WebSyncRegistration(const WebString& registrationId, const WebSyncRegistrati onOptions& options)
37 : id(registrationId)
38 , options(options)
39 {
40 }
41
42 WebString id;
43 WebSyncRegistrationOptions options;
44 };
45
46 } // namespace blink
47
48 #endif // WebSyncRegistration_h
OLDNEW
« no previous file with comments | « public/platform/modules/background_sync/WebSyncProvider.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698