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_GTK_OMNIBOX_OMNIBOX_POPUP_VIEW_GTK_H_ | 5 #ifndef CHROME_BROWSER_UI_GTK_OMNIBOX_OMNIBOX_POPUP_VIEW_GTK_H_ |
6 #define CHROME_BROWSER_UI_GTK_OMNIBOX_OMNIBOX_POPUP_VIEW_GTK_H_ | 6 #define CHROME_BROWSER_UI_GTK_OMNIBOX_OMNIBOX_POPUP_VIEW_GTK_H_ |
7 | 7 |
8 #include <gtk/gtk.h> | 8 #include <gtk/gtk.h> |
9 | 9 |
10 #include <map> | 10 #include <map> |
(...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
85 gfx::Image IconForMatch(const AutocompleteMatch& match, | 85 gfx::Image IconForMatch(const AutocompleteMatch& match, |
86 bool selected, | 86 bool selected, |
87 bool is_selected_keyword); | 87 bool is_selected_keyword); |
88 | 88 |
89 // Returns the |index|th element of match, unless we're selected and showing | 89 // Returns the |index|th element of match, unless we're selected and showing |
90 // the associated keyword match. | 90 // the associated keyword match. |
91 void GetVisibleMatchForInput(size_t index, | 91 void GetVisibleMatchForInput(size_t index, |
92 const AutocompleteMatch** match, | 92 const AutocompleteMatch** match, |
93 bool* is_selected_keyword); | 93 bool* is_selected_keyword); |
94 | 94 |
| 95 // Returns the number of hidden matches at the top of the popup. This is |
| 96 // non-zero when a verbatim match like search-what-you-typed is present but |
| 97 // should not be shown. |
| 98 size_t GetHiddenMatchCount(); |
| 99 |
95 CHROMEGTK_CALLBACK_1(OmniboxPopupViewGtk, gboolean, HandleMotion, | 100 CHROMEGTK_CALLBACK_1(OmniboxPopupViewGtk, gboolean, HandleMotion, |
96 GdkEventMotion*); | 101 GdkEventMotion*); |
97 | 102 |
98 CHROMEGTK_CALLBACK_1(OmniboxPopupViewGtk, gboolean, HandleButtonPress, | 103 CHROMEGTK_CALLBACK_1(OmniboxPopupViewGtk, gboolean, HandleButtonPress, |
99 GdkEventButton*); | 104 GdkEventButton*); |
100 | 105 |
101 CHROMEGTK_CALLBACK_1(OmniboxPopupViewGtk, gboolean, HandleButtonRelease, | 106 CHROMEGTK_CALLBACK_1(OmniboxPopupViewGtk, gboolean, HandleButtonRelease, |
102 GdkEventButton*); | 107 GdkEventButton*); |
103 | 108 |
104 CHROMEGTK_CALLBACK_1(OmniboxPopupViewGtk, gboolean, HandleExpose, | 109 CHROMEGTK_CALLBACK_1(OmniboxPopupViewGtk, gboolean, HandleExpose, |
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
143 // erroneously ignore the next drag. | 148 // erroneously ignore the next drag. |
144 bool ignore_mouse_drag_; | 149 bool ignore_mouse_drag_; |
145 | 150 |
146 // Whether our popup is currently open / shown, or closed / hidden. | 151 // Whether our popup is currently open / shown, or closed / hidden. |
147 bool opened_; | 152 bool opened_; |
148 | 153 |
149 DISALLOW_COPY_AND_ASSIGN(OmniboxPopupViewGtk); | 154 DISALLOW_COPY_AND_ASSIGN(OmniboxPopupViewGtk); |
150 }; | 155 }; |
151 | 156 |
152 #endif // CHROME_BROWSER_UI_GTK_OMNIBOX_OMNIBOX_POPUP_VIEW_GTK_H_ | 157 #endif // CHROME_BROWSER_UI_GTK_OMNIBOX_OMNIBOX_POPUP_VIEW_GTK_H_ |
OLD | NEW |