| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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_GTK_TABS_TAB_STRIP_GTK_H_ | 5 #ifndef CHROME_BROWSER_UI_GTK_TABS_TAB_STRIP_GTK_H_ |
| 6 #define CHROME_BROWSER_UI_GTK_TABS_TAB_STRIP_GTK_H_ | 6 #define CHROME_BROWSER_UI_GTK_TABS_TAB_STRIP_GTK_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <gtk/gtk.h> | 9 #include <gtk/gtk.h> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 96 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 107 int index, | 107 int index, |
| 108 bool foreground); | 108 bool foreground); |
| 109 virtual void TabDetachedAt(TabContentsWrapper* contents, int index); | 109 virtual void TabDetachedAt(TabContentsWrapper* contents, int index); |
| 110 virtual void TabSelectedAt(TabContentsWrapper* old_contents, | 110 virtual void TabSelectedAt(TabContentsWrapper* old_contents, |
| 111 TabContentsWrapper* contents, | 111 TabContentsWrapper* contents, |
| 112 int index, | 112 int index, |
| 113 bool user_gesture); | 113 bool user_gesture); |
| 114 virtual void TabMoved(TabContentsWrapper* contents, | 114 virtual void TabMoved(TabContentsWrapper* contents, |
| 115 int from_index, | 115 int from_index, |
| 116 int to_index); | 116 int to_index); |
| 117 virtual void TabSelectionChanged(std::set<int>& indices_affected); |
| 117 virtual void TabChangedAt(TabContentsWrapper* contents, int index, | 118 virtual void TabChangedAt(TabContentsWrapper* contents, int index, |
| 118 TabChangeType change_type); | 119 TabChangeType change_type); |
| 119 virtual void TabReplacedAt(TabStripModel* tab_strip_model, | 120 virtual void TabReplacedAt(TabStripModel* tab_strip_model, |
| 120 TabContentsWrapper* old_contents, | 121 TabContentsWrapper* old_contents, |
| 121 TabContentsWrapper* new_contents, | 122 TabContentsWrapper* new_contents, |
| 122 int index); | 123 int index); |
| 123 virtual void TabMiniStateChanged(TabContentsWrapper* contents, int index); | 124 virtual void TabMiniStateChanged(TabContentsWrapper* contents, int index); |
| 124 virtual void TabBlockedStateChanged(TabContentsWrapper* contents, | 125 virtual void TabBlockedStateChanged(TabContentsWrapper* contents, |
| 125 int index); | 126 int index); |
| 126 | 127 |
| 127 // TabGtk::TabDelegate implementation: | 128 // TabGtk::TabDelegate implementation: |
| 129 virtual bool IsTabActive(const TabGtk* tab) const; |
| 128 virtual bool IsTabSelected(const TabGtk* tab) const; | 130 virtual bool IsTabSelected(const TabGtk* tab) const; |
| 129 virtual bool IsTabPinned(const TabGtk* tab) const; | 131 virtual bool IsTabPinned(const TabGtk* tab) const; |
| 130 virtual bool IsTabDetached(const TabGtk* tab) const; | 132 virtual bool IsTabDetached(const TabGtk* tab) const; |
| 131 virtual void SelectTab(TabGtk* tab); | 133 virtual void ActivateTab(TabGtk* tab); |
| 134 virtual void ToggleTabSelection(TabGtk* tab); |
| 135 virtual void ExtendTabSelection(TabGtk* tab); |
| 132 virtual void CloseTab(TabGtk* tab); | 136 virtual void CloseTab(TabGtk* tab); |
| 133 virtual bool IsCommandEnabledForTab( | 137 virtual bool IsCommandEnabledForTab( |
| 134 TabStripModel::ContextMenuCommand command_id, const TabGtk* tab) const; | 138 TabStripModel::ContextMenuCommand command_id, const TabGtk* tab) const; |
| 135 virtual void ExecuteCommandForTab( | 139 virtual void ExecuteCommandForTab( |
| 136 TabStripModel::ContextMenuCommand command_id, TabGtk* tab); | 140 TabStripModel::ContextMenuCommand command_id, TabGtk* tab); |
| 137 virtual void StartHighlightTabsForCommand( | 141 virtual void StartHighlightTabsForCommand( |
| 138 TabStripModel::ContextMenuCommand command_id, TabGtk* tab); | 142 TabStripModel::ContextMenuCommand command_id, TabGtk* tab); |
| 139 virtual void StopHighlightTabsForCommand( | 143 virtual void StopHighlightTabsForCommand( |
| 140 TabStripModel::ContextMenuCommand command_id, TabGtk* tab); | 144 TabStripModel::ContextMenuCommand command_id, TabGtk* tab); |
| 141 virtual void StopAllHighlighting(); | 145 virtual void StopAllHighlighting(); |
| 142 virtual void MaybeStartDrag(TabGtk* tab, const gfx::Point& point); | 146 virtual void MaybeStartDrag(TabGtk* tab, const gfx::Point& point); |
| 143 virtual void ContinueDrag(GdkDragContext* context); | 147 virtual void ContinueDrag(GdkDragContext* context); |
| 144 virtual bool EndDrag(bool canceled); | 148 virtual bool EndDrag(bool canceled); |
| 145 virtual bool HasAvailableDragActions() const; | 149 virtual bool HasAvailableDragActions() const; |
| 146 virtual ui::ThemeProvider* GetThemeProvider(); | 150 virtual ui::ThemeProvider* GetThemeProvider(); |
| 151 virtual TabStripMenuController* GetTabStripMenuControllerForTab(TabGtk* tab); |
| 147 | 152 |
| 148 // MessageLoop::Observer implementation: | 153 // MessageLoop::Observer implementation: |
| 149 virtual void WillProcessEvent(GdkEvent* event); | 154 virtual void WillProcessEvent(GdkEvent* event); |
| 150 virtual void DidProcessEvent(GdkEvent* event); | 155 virtual void DidProcessEvent(GdkEvent* event); |
| 151 | 156 |
| 152 // Overridden from NotificationObserver: | 157 // Overridden from NotificationObserver: |
| 153 virtual void Observe(NotificationType type, | 158 virtual void Observe(NotificationType type, |
| 154 const NotificationSource& source, | 159 const NotificationSource& source, |
| 155 const NotificationDetails& details); | 160 const NotificationDetails& details); |
| 156 | 161 |
| (...skipping 304 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 461 // True if the tabstrip has already been added as a MessageLoop observer. | 466 // True if the tabstrip has already been added as a MessageLoop observer. |
| 462 bool added_as_message_loop_observer_; | 467 bool added_as_message_loop_observer_; |
| 463 | 468 |
| 464 // Helper for performing tab selection as a result of dragging over a tab. | 469 // Helper for performing tab selection as a result of dragging over a tab. |
| 465 HoverTabSelector hover_tab_selector_; | 470 HoverTabSelector hover_tab_selector_; |
| 466 | 471 |
| 467 DISALLOW_COPY_AND_ASSIGN(TabStripGtk); | 472 DISALLOW_COPY_AND_ASSIGN(TabStripGtk); |
| 468 }; | 473 }; |
| 469 | 474 |
| 470 #endif // CHROME_BROWSER_UI_GTK_TABS_TAB_STRIP_GTK_H_ | 475 #endif // CHROME_BROWSER_UI_GTK_TABS_TAB_STRIP_GTK_H_ |
| OLD | NEW |