OLD | NEW |
1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2006-2008 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 // PageNavigator defines an interface that can be used to express the user's | 5 // PageNavigator defines an interface that can be used to express the user's |
6 // intention to navigate to a particular URL. The implementing class should | 6 // intention to navigate to a particular URL. The implementing class should |
7 // perform the navigation. | 7 // perform the navigation. |
8 | 8 |
9 #ifndef CONTENT_BROWSER_TAB_CONTENTS_PAGE_NAVIGATOR_H_ | 9 #ifndef CONTENT_BROWSER_TAB_CONTENTS_PAGE_NAVIGATOR_H_ |
10 #define CONTENT_BROWSER_TAB_CONTENTS_PAGE_NAVIGATOR_H_ | 10 #define CONTENT_BROWSER_TAB_CONTENTS_PAGE_NAVIGATOR_H_ |
11 #pragma once | 11 #pragma once |
12 | 12 |
13 #include "chrome/common/page_transition_types.h" | 13 #include "content/common/page_transition_types.h" |
14 #include "webkit/glue/window_open_disposition.h" | 14 #include "webkit/glue/window_open_disposition.h" |
15 | 15 |
16 class GURL; | 16 class GURL; |
17 | 17 |
18 class PageNavigator { | 18 class PageNavigator { |
19 public: | 19 public: |
20 // Opens a URL with the given disposition. The transition specifies how this | 20 // Opens a URL with the given disposition. The transition specifies how this |
21 // navigation should be recorded in the history system (for example, typed). | 21 // navigation should be recorded in the history system (for example, typed). |
22 virtual void OpenURL(const GURL& url, const GURL& referrer, | 22 virtual void OpenURL(const GURL& url, const GURL& referrer, |
23 WindowOpenDisposition disposition, | 23 WindowOpenDisposition disposition, |
24 PageTransition::Type transition) = 0; | 24 PageTransition::Type transition) = 0; |
25 | 25 |
26 protected: | 26 protected: |
27 virtual ~PageNavigator() {} | 27 virtual ~PageNavigator() {} |
28 }; | 28 }; |
29 | 29 |
30 #endif // CONTENT_BROWSER_TAB_CONTENTS_PAGE_NAVIGATOR_H_ | 30 #endif // CONTENT_BROWSER_TAB_CONTENTS_PAGE_NAVIGATOR_H_ |
OLD | NEW |