| 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_AUTOCOMPLETE_AUTOCOMPLETE_EDIT_VIEW_GTK_H_ | 5 #ifndef CHROME_BROWSER_AUTOCOMPLETE_AUTOCOMPLETE_EDIT_VIEW_GTK_H_ |
| 6 #define CHROME_BROWSER_AUTOCOMPLETE_AUTOCOMPLETE_EDIT_VIEW_GTK_H_ | 6 #define CHROME_BROWSER_AUTOCOMPLETE_AUTOCOMPLETE_EDIT_VIEW_GTK_H_ |
| 7 | 7 |
| 8 #include <gtk/gtk.h> | 8 #include <gtk/gtk.h> |
| 9 | 9 |
| 10 #include <algorithm> | 10 #include <algorithm> |
| (...skipping 120 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 131 | 131 |
| 132 void SetBaseColor(); | 132 void SetBaseColor(); |
| 133 | 133 |
| 134 // Used by LocationBarViewGtk to inform AutocompleteEditViewGtk if the tab to | 134 // Used by LocationBarViewGtk to inform AutocompleteEditViewGtk if the tab to |
| 135 // search should be enabled or not. See the comment of |enable_tab_to_search_| | 135 // search should be enabled or not. See the comment of |enable_tab_to_search_| |
| 136 // for details. | 136 // for details. |
| 137 void set_enable_tab_to_search(bool enable) { | 137 void set_enable_tab_to_search(bool enable) { |
| 138 enable_tab_to_search_ = enable; | 138 enable_tab_to_search_ = enable; |
| 139 } | 139 } |
| 140 | 140 |
| 141 GtkWidget* text_view() { |
| 142 return text_view_; |
| 143 } |
| 144 |
| 141 private: | 145 private: |
| 142 CHROMEG_CALLBACK_0(AutocompleteEditViewGtk, void, HandleBeginUserAction, | 146 CHROMEG_CALLBACK_0(AutocompleteEditViewGtk, void, HandleBeginUserAction, |
| 143 GtkTextBuffer*); | 147 GtkTextBuffer*); |
| 144 CHROMEG_CALLBACK_0(AutocompleteEditViewGtk, void, HandleEndUserAction, | 148 CHROMEG_CALLBACK_0(AutocompleteEditViewGtk, void, HandleEndUserAction, |
| 145 GtkTextBuffer*); | 149 GtkTextBuffer*); |
| 146 CHROMEG_CALLBACK_2(AutocompleteEditViewGtk, void, HandleMarkSet, | 150 CHROMEG_CALLBACK_2(AutocompleteEditViewGtk, void, HandleMarkSet, |
| 147 GtkTextBuffer*, GtkTextIter*, GtkTextMark*); | 151 GtkTextBuffer*, GtkTextIter*, GtkTextMark*); |
| 148 // As above, but called after the default handler. | 152 // As above, but called after the default handler. |
| 149 CHROMEG_CALLBACK_2(AutocompleteEditViewGtk, void, HandleMarkSetAfter, | 153 CHROMEG_CALLBACK_2(AutocompleteEditViewGtk, void, HandleMarkSetAfter, |
| 150 GtkTextBuffer*, GtkTextIter*, GtkTextMark*); | 154 GtkTextBuffer*, GtkTextIter*, GtkTextMark*); |
| (...skipping 231 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 382 | 386 |
| 383 // Indicate if the tab to search should be enabled or not. It's true by | 387 // Indicate if the tab to search should be enabled or not. It's true by |
| 384 // default and will only be set to false if the location bar view is not able | 388 // default and will only be set to false if the location bar view is not able |
| 385 // to show the tab to search hint. | 389 // to show the tab to search hint. |
| 386 bool enable_tab_to_search_; | 390 bool enable_tab_to_search_; |
| 387 | 391 |
| 388 DISALLOW_COPY_AND_ASSIGN(AutocompleteEditViewGtk); | 392 DISALLOW_COPY_AND_ASSIGN(AutocompleteEditViewGtk); |
| 389 }; | 393 }; |
| 390 | 394 |
| 391 #endif // CHROME_BROWSER_AUTOCOMPLETE_AUTOCOMPLETE_EDIT_VIEW_GTK_H_ | 395 #endif // CHROME_BROWSER_AUTOCOMPLETE_AUTOCOMPLETE_EDIT_VIEW_GTK_H_ |
| OLD | NEW |