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_SEARCH_SEARCH_DELEGATE_H_ | 5 #ifndef CHROME_BROWSER_UI_SEARCH_SEARCH_DELEGATE_H_ |
6 #define CHROME_BROWSER_UI_SEARCH_SEARCH_DELEGATE_H_ | 6 #define CHROME_BROWSER_UI_SEARCH_SEARCH_DELEGATE_H_ |
7 | 7 |
8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
9 #include "base/compiler_specific.h" | 9 #include "base/compiler_specific.h" |
10 #include "chrome/browser/ui/search/search_model_observer.h" | 10 #include "chrome/browser/ui/search/search_model_observer.h" |
(...skipping 11 matching lines...) Expand all Loading... | |
22 // SearchModel through to the toolbar, tabstrip and other UI | 22 // SearchModel through to the toolbar, tabstrip and other UI |
23 // observers. | 23 // observers. |
24 // Changes are propagated from the active tab's model via this class to the | 24 // Changes are propagated from the active tab's model via this class to the |
25 // Browser-level model. | 25 // Browser-level model. |
26 class SearchDelegate : public SearchModelObserver { | 26 class SearchDelegate : public SearchModelObserver { |
27 public: | 27 public: |
28 explicit SearchDelegate(SearchModel* model); | 28 explicit SearchDelegate(SearchModel* model); |
29 virtual ~SearchDelegate(); | 29 virtual ~SearchDelegate(); |
30 | 30 |
31 // Overrides for SearchModelObserver: | 31 // Overrides for SearchModelObserver: |
32 virtual void ModeChanged(const Mode& mode) OVERRIDE; | 32 virtual void ModeChanged(const Mode& old_mode, const Mode& new_mode) OVERRIDE; |
sky
2012/08/03 17:29:40
Would be nice if you did this in a separate change
kuan
2012/08/03 17:46:49
i'm sorry abt that :(
this cl, and its original in
| |
33 | 33 |
34 // When the active tab is changed, the model state of this new active tab is | 34 // When the active tab is changed, the model state of this new active tab is |
35 // propagated to the browser. | 35 // propagated to the browser. |
36 void OnTabActivated(TabContents* contents); | 36 void OnTabActivated(TabContents* contents); |
37 | 37 |
38 // When a tab is deactivated, this class no longer observes changes to the | 38 // When a tab is deactivated, this class no longer observes changes to the |
39 // tab's model. | 39 // tab's model. |
40 void OnTabDeactivated(TabContents* contents); | 40 void OnTabDeactivated(TabContents* contents); |
41 | 41 |
42 // When a tab is detached, this class no longer observes changes to the | 42 // When a tab is detached, this class no longer observes changes to the |
(...skipping 20 matching lines...) Expand all Loading... | |
63 // NTP to SEARCH. | 63 // NTP to SEARCH. |
64 ToolbarSearchAnimator toolbar_search_animator_; | 64 ToolbarSearchAnimator toolbar_search_animator_; |
65 | 65 |
66 DISALLOW_COPY_AND_ASSIGN(SearchDelegate); | 66 DISALLOW_COPY_AND_ASSIGN(SearchDelegate); |
67 }; | 67 }; |
68 | 68 |
69 } // namespace search | 69 } // namespace search |
70 } // namespace chrome | 70 } // namespace chrome |
71 | 71 |
72 #endif // CHROME_BROWSER_UI_SEARCH_SEARCH_DELEGATE_H_ | 72 #endif // CHROME_BROWSER_UI_SEARCH_SEARCH_DELEGATE_H_ |
OLD | NEW |