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

Side by Side Diff: content/child/permissions/permission_dispatcher.h

Issue 1164073005: Allow script to request durable storage permission (chrome side) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: ToT Created 5 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
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 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 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_CHILD_PERMISSIONS_PERMISSION_DISPATCHER_H_ 5 #ifndef CONTENT_CHILD_PERMISSIONS_PERMISSION_DISPATCHER_H_
6 #define CONTENT_CHILD_PERMISSIONS_PERMISSION_DISPATCHER_H_ 6 #define CONTENT_CHILD_PERMISSIONS_PERMISSION_DISPATCHER_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/callback_forward.h" 10 #include "base/callback_forward.h"
(...skipping 19 matching lines...) Expand all
30 // Returns whether the given WebPermissionType is observable. Some types have 30 // Returns whether the given WebPermissionType is observable. Some types have
31 // static values that never changes. 31 // static values that never changes.
32 static bool IsObservable(blink::WebPermissionType type); 32 static bool IsObservable(blink::WebPermissionType type);
33 33
34 // The caller must guarantee that |service_registry| will have a lifetime 34 // The caller must guarantee that |service_registry| will have a lifetime
35 // larger than this instance of PermissionDispatcher. 35 // larger than this instance of PermissionDispatcher.
36 explicit PermissionDispatcher(ServiceRegistry* service_registry); 36 explicit PermissionDispatcher(ServiceRegistry* service_registry);
37 virtual ~PermissionDispatcher(); 37 virtual ~PermissionDispatcher();
38 38
39 // blink::WebPermissionClient implementation. 39 // blink::WebPermissionClient implementation.
40 virtual void requestDurablePermission(const blink::WebURL&,
41 blink::WebPermissionQueryCallback*);
40 virtual void queryPermission(blink::WebPermissionType type, 42 virtual void queryPermission(blink::WebPermissionType type,
41 const blink::WebURL& origin, 43 const blink::WebURL& origin,
42 blink::WebPermissionQueryCallback* callback); 44 blink::WebPermissionQueryCallback* callback);
43 virtual void startListening(blink::WebPermissionType type, 45 virtual void startListening(blink::WebPermissionType type,
44 const blink::WebURL& origin, 46 const blink::WebURL& origin,
45 blink::WebPermissionObserver* observer); 47 blink::WebPermissionObserver* observer);
46 virtual void stopListening(blink::WebPermissionObserver* observer); 48 virtual void stopListening(blink::WebPermissionObserver* observer);
47 49
48 // The following methods must be called by workers on the main thread. 50 // The following methods must be called by workers on the main thread.
49 void QueryPermissionForWorker(blink::WebPermissionType type, 51 void QueryPermissionForWorker(blink::WebPermissionType type,
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after
116 118
117 ServiceRegistry* service_registry_; 119 ServiceRegistry* service_registry_;
118 PermissionServicePtr permission_service_; 120 PermissionServicePtr permission_service_;
119 121
120 DISALLOW_COPY_AND_ASSIGN(PermissionDispatcher); 122 DISALLOW_COPY_AND_ASSIGN(PermissionDispatcher);
121 }; 123 };
122 124
123 } // namespace content 125 } // namespace content
124 126
125 #endif // CONTENT_CHILD_PERMISSIONS_PERMISSION_DISPATCHER_H_ 127 #endif // CONTENT_CHILD_PERMISSIONS_PERMISSION_DISPATCHER_H_
OLDNEW
« no previous file with comments | « content/browser/permissions/permission_service_impl.cc ('k') | content/child/permissions/permission_dispatcher.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698