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_BROWSER_UI_VIEWS_FIND_BAR_HOST_H_ | 5 #ifndef CHROME_BROWSER_UI_VIEWS_FIND_BAR_HOST_H_ |
6 #define CHROME_BROWSER_UI_VIEWS_FIND_BAR_HOST_H_ | 6 #define CHROME_BROWSER_UI_VIEWS_FIND_BAR_HOST_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include "chrome/browser/renderer_host/render_view_host_delegate.h" | 9 #include "chrome/browser/renderer_host/render_view_host_delegate.h" |
10 #include "chrome/browser/ui/find_bar/find_bar.h" | 10 #include "chrome/browser/ui/find_bar/find_bar.h" |
(...skipping 54 matching lines...) Loading... |
65 virtual void RestoreSavedFocus(); | 65 virtual void RestoreSavedFocus(); |
66 virtual FindBarTesting* GetFindBarTesting(); | 66 virtual FindBarTesting* GetFindBarTesting(); |
67 | 67 |
68 // Overridden from views::AcceleratorTarget in DropdownBarHost class: | 68 // Overridden from views::AcceleratorTarget in DropdownBarHost class: |
69 virtual bool AcceleratorPressed(const views::Accelerator& accelerator); | 69 virtual bool AcceleratorPressed(const views::Accelerator& accelerator); |
70 | 70 |
71 // FindBarTesting implementation: | 71 // FindBarTesting implementation: |
72 virtual bool GetFindBarWindowInfo(gfx::Point* position, | 72 virtual bool GetFindBarWindowInfo(gfx::Point* position, |
73 bool* fully_visible); | 73 bool* fully_visible); |
74 virtual string16 GetFindText(); | 74 virtual string16 GetFindText(); |
| 75 virtual string16 GetFindSelectedText(); |
75 virtual string16 GetMatchCountText(); | 76 virtual string16 GetMatchCountText(); |
76 | 77 |
77 // Overridden from DropdownBarHost: | 78 // Overridden from DropdownBarHost: |
78 // Returns the rectangle representing where to position the find bar. It uses | 79 // Returns the rectangle representing where to position the find bar. It uses |
79 // GetDialogBounds and positions itself within that, either to the left (if an | 80 // GetDialogBounds and positions itself within that, either to the left (if an |
80 // InfoBar is present) or to the right (no InfoBar). If | 81 // InfoBar is present) or to the right (no InfoBar). If |
81 // |avoid_overlapping_rect| is specified, the return value will be a rectangle | 82 // |avoid_overlapping_rect| is specified, the return value will be a rectangle |
82 // located immediately to the left of |avoid_overlapping_rect|, as long as | 83 // located immediately to the left of |avoid_overlapping_rect|, as long as |
83 // there is enough room for the dialog to draw within the bounds. If not, the | 84 // there is enough room for the dialog to draw within the bounds. If not, the |
84 // dialog position returned will overlap |avoid_overlapping_rect|. | 85 // dialog position returned will overlap |avoid_overlapping_rect|. |
(...skipping 37 matching lines...) Loading... |
122 // Returns the FindBarView. | 123 // Returns the FindBarView. |
123 FindBarView* find_bar_view(); | 124 FindBarView* find_bar_view(); |
124 | 125 |
125 // A pointer back to the owning controller. | 126 // A pointer back to the owning controller. |
126 FindBarController* find_bar_controller_; | 127 FindBarController* find_bar_controller_; |
127 | 128 |
128 DISALLOW_COPY_AND_ASSIGN(FindBarHost); | 129 DISALLOW_COPY_AND_ASSIGN(FindBarHost); |
129 }; | 130 }; |
130 | 131 |
131 #endif // CHROME_BROWSER_UI_VIEWS_FIND_BAR_HOST_H_ | 132 #endif // CHROME_BROWSER_UI_VIEWS_FIND_BAR_HOST_H_ |
OLD | NEW |