OLD | NEW |
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_BROWSER_UI_ANDROID_TAB_MODEL_TAB_MODEL_H_ | 5 #ifndef CHROME_BROWSER_UI_ANDROID_TAB_MODEL_TAB_MODEL_H_ |
6 #define CHROME_BROWSER_UI_ANDROID_TAB_MODEL_TAB_MODEL_H_ | 6 #define CHROME_BROWSER_UI_ANDROID_TAB_MODEL_TAB_MODEL_H_ |
7 | 7 |
8 #include "base/memory/scoped_ptr.h" | 8 #include "base/memory/scoped_ptr.h" |
9 #include "chrome/browser/sessions/session_id.h" | 9 #include "chrome/browser/sessions/session_id.h" |
10 #include "chrome/browser/sync/glue/synced_window_delegate.h" | 10 #include "chrome/browser/sync/glue/synced_window_delegate.h" |
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
47 virtual void CreateTab(content::WebContents* web_contents, | 47 virtual void CreateTab(content::WebContents* web_contents, |
48 int parent_tab_id) = 0; | 48 int parent_tab_id) = 0; |
49 | 49 |
50 // Used by Developer Tools to create a new tab with a given URL. | 50 // Used by Developer Tools to create a new tab with a given URL. |
51 // Replaces CreateTabForTesting. | 51 // Replaces CreateTabForTesting. |
52 virtual content::WebContents* CreateNewTabForDevTools(const GURL& url) = 0; | 52 virtual content::WebContents* CreateNewTabForDevTools(const GURL& url) = 0; |
53 | 53 |
54 // Return true if we are currently restoring sessions asynchronously. | 54 // Return true if we are currently restoring sessions asynchronously. |
55 virtual bool IsSessionRestoreInProgress() const = 0; | 55 virtual bool IsSessionRestoreInProgress() const = 0; |
56 | 56 |
57 virtual void OpenClearBrowsingData() const = 0; | |
58 | |
59 protected: | 57 protected: |
60 explicit TabModel(Profile* profile); | 58 explicit TabModel(Profile* profile); |
61 virtual ~TabModel(); | 59 virtual ~TabModel(); |
62 | 60 |
63 // Instructs the TabModel to broadcast a notification that all tabs are now | 61 // Instructs the TabModel to broadcast a notification that all tabs are now |
64 // loaded from storage. | 62 // loaded from storage. |
65 void BroadcastSessionRestoreComplete(); | 63 void BroadcastSessionRestoreComplete(); |
66 | 64 |
67 ToolbarModel* GetToolbarModel(); | 65 ToolbarModel* GetToolbarModel(); |
68 | 66 |
(...skipping 17 matching lines...) Expand all Loading... |
86 // across sessions. | 84 // across sessions. |
87 SessionID session_id_; | 85 SessionID session_id_; |
88 | 86 |
89 // The Registrar used to register TabModel for notifications. | 87 // The Registrar used to register TabModel for notifications. |
90 content::NotificationRegistrar registrar_; | 88 content::NotificationRegistrar registrar_; |
91 | 89 |
92 DISALLOW_COPY_AND_ASSIGN(TabModel); | 90 DISALLOW_COPY_AND_ASSIGN(TabModel); |
93 }; | 91 }; |
94 | 92 |
95 #endif // CHROME_BROWSER_UI_ANDROID_TAB_MODEL_TAB_MODEL_H_ | 93 #endif // CHROME_BROWSER_UI_ANDROID_TAB_MODEL_TAB_MODEL_H_ |
OLD | NEW |