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

Side by Side Diff: chrome/renderer/content_settings_observer.h

Issue 498513002: Respect the clipboardRead and clipboardWrite permissions in content scripts. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix extensions test compile Created 6 years, 3 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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 CHROME_RENDERER_CONTENT_SETTINGS_OBSERVER_H_ 5 #ifndef CHROME_RENDERER_CONTENT_SETTINGS_OBSERVER_H_
6 #define CHROME_RENDERER_CONTENT_SETTINGS_OBSERVER_H_ 6 #define CHROME_RENDERER_CONTENT_SETTINGS_OBSERVER_H_
7 7
8 #include <map> 8 #include <map>
9 #include <set> 9 #include <set>
10 10
(...skipping 93 matching lines...) Expand 10 before | Expand all | Expand 10 after
104 void ClearBlockedContentSettings(); 104 void ClearBlockedContentSettings();
105 105
106 // Whether the observed RenderFrame is for a platform app. 106 // Whether the observed RenderFrame is for a platform app.
107 bool IsPlatformApp(); 107 bool IsPlatformApp();
108 108
109 #if defined(ENABLE_EXTENSIONS) 109 #if defined(ENABLE_EXTENSIONS)
110 // If |origin| corresponds to an installed extension, returns that extension. 110 // If |origin| corresponds to an installed extension, returns that extension.
111 // Otherwise returns NULL. 111 // Otherwise returns NULL.
112 const extensions::Extension* GetExtension( 112 const extensions::Extension* GetExtension(
113 const blink::WebSecurityOrigin& origin) const; 113 const blink::WebSecurityOrigin& origin) const;
114
115 #endif 114 #endif
116 115
117 // Helpers. 116 // Helpers.
118 // True if |frame| contains content that is white-listed for content settings. 117 // True if |frame| contains content that is white-listed for content settings.
119 static bool IsWhitelistedForContentSettings(content::RenderFrame* frame); 118 static bool IsWhitelistedForContentSettings(content::RenderFrame* frame);
120 static bool IsWhitelistedForContentSettings( 119 static bool IsWhitelistedForContentSettings(
121 const blink::WebSecurityOrigin& origin, 120 const blink::WebSecurityOrigin& origin,
122 const GURL& document_url); 121 const GURL& document_url);
123 122
124 #if defined(ENABLE_EXTENSIONS) 123 #if defined(ENABLE_EXTENSIONS)
(...skipping 26 matching lines...) Expand all
151 bool npapi_plugins_blocked_; 150 bool npapi_plugins_blocked_;
152 151
153 int current_request_id_; 152 int current_request_id_;
154 typedef std::map<int, blink::WebPermissionCallbacks> PermissionRequestMap; 153 typedef std::map<int, blink::WebPermissionCallbacks> PermissionRequestMap;
155 PermissionRequestMap permission_requests_; 154 PermissionRequestMap permission_requests_;
156 155
157 DISALLOW_COPY_AND_ASSIGN(ContentSettingsObserver); 156 DISALLOW_COPY_AND_ASSIGN(ContentSettingsObserver);
158 }; 157 };
159 158
160 #endif // CHROME_RENDERER_CONTENT_SETTINGS_OBSERVER_H_ 159 #endif // CHROME_RENDERER_CONTENT_SETTINGS_OBSERVER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698