Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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_FRAME_CHROME_FRAME_DELEGATE_H_ | 5 #ifndef CHROME_FRAME_CHROME_FRAME_DELEGATE_H_ |
| 6 #define CHROME_FRAME_CHROME_FRAME_DELEGATE_H_ | 6 #define CHROME_FRAME_CHROME_FRAME_DELEGATE_H_ |
| 7 | 7 |
| 8 #include <atlbase.h> | 8 #include <atlbase.h> |
| 9 #include <atlwin.h> | 9 #include <atlwin.h> |
| 10 #include <queue> | 10 #include <queue> |
| (...skipping 194 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 205 return true; | 205 return true; |
| 206 } | 206 } |
| 207 | 207 |
| 208 return false; | 208 return false; |
| 209 } | 209 } |
| 210 | 210 |
| 211 Lock lock_; | 211 Lock lock_; |
| 212 std::queue<Task*> pending_tasks_; | 212 std::queue<Task*> pending_tasks_; |
| 213 }; | 213 }; |
| 214 | 214 |
| 215 // Provides an interface which controls navigation within ChromeFrame. | |
| 216 class NavigationConstraints { | |
| 217 public: | |
| 218 virtual bool AllowUnsafeUrls() = 0; | |
| 219 virtual bool IsSchemeAllowed(const GURL&url) = 0; | |
|
amit
2010/12/10 23:56:17
nit: spacing after &
ananta
2010/12/11 02:11:11
Done and moved these classes to the navigation_con
| |
| 220 virtual bool IsZoneAllowed(const GURL& url) = 0; | |
| 221 }; | |
| 222 | |
| 223 // Provides default implementation for the NavigationConstraints interface. | |
| 224 class NavigationConstraintsImpl : public NavigationConstraints { | |
|
amit
2010/12/10 23:56:17
why not move this into its own source file and inc
ananta
2010/12/11 02:11:11
I thought about that. Decided against that for the
| |
| 225 public: | |
| 226 virtual ~NavigationConstraintsImpl() {} | |
| 227 | |
| 228 // NavigationConstraints method overrides. | |
| 229 virtual bool AllowUnsafeUrls(); | |
| 230 virtual bool IsSchemeAllowed(const GURL&url); | |
| 231 virtual bool IsZoneAllowed(const GURL& url); | |
| 232 }; | |
| 233 | |
| 215 #endif // CHROME_FRAME_CHROME_FRAME_DELEGATE_H_ | 234 #endif // CHROME_FRAME_CHROME_FRAME_DELEGATE_H_ |
| OLD | NEW |