| 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_FIND_BAR_GTK_H_ | 5 #ifndef CHROME_BROWSER_UI_GTK_FIND_BAR_GTK_H_ |
| 6 #define CHROME_BROWSER_UI_GTK_FIND_BAR_GTK_H_ | 6 #define CHROME_BROWSER_UI_GTK_FIND_BAR_GTK_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <gtk/gtk.h> | 9 #include <gtk/gtk.h> |
| 10 | 10 |
| (...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 61 | 61 |
| 62 // Methods from FindBarTesting. | 62 // Methods from FindBarTesting. |
| 63 virtual bool GetFindBarWindowInfo(gfx::Point* position, | 63 virtual bool GetFindBarWindowInfo(gfx::Point* position, |
| 64 bool* fully_visible); | 64 bool* fully_visible); |
| 65 virtual string16 GetFindText(); | 65 virtual string16 GetFindText(); |
| 66 virtual string16 GetFindSelectedText(); | 66 virtual string16 GetFindSelectedText(); |
| 67 virtual string16 GetMatchCountText(); | 67 virtual string16 GetMatchCountText(); |
| 68 virtual int GetWidth(); | 68 virtual int GetWidth(); |
| 69 | 69 |
| 70 // Overridden from NotificationObserver: | 70 // Overridden from NotificationObserver: |
| 71 virtual void Observe(NotificationType type, | 71 virtual void Observe(int type, |
| 72 const NotificationSource& source, | 72 const NotificationSource& source, |
| 73 const NotificationDetails& details); | 73 const NotificationDetails& details); |
| 74 | 74 |
| 75 private: | 75 private: |
| 76 void InitWidgets(); | 76 void InitWidgets(); |
| 77 | 77 |
| 78 // Store the currently focused widget if it is not in the find bar. | 78 // Store the currently focused widget if it is not in the find bar. |
| 79 // This should always be called before we claim focus. | 79 // This should always be called before we claim focus. |
| 80 void StoreOutsideFocus(); | 80 void StoreOutsideFocus(); |
| 81 | 81 |
| (...skipping 151 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 233 // The selection rect we are currently showing. We cache it to avoid covering | 233 // The selection rect we are currently showing. We cache it to avoid covering |
| 234 // it up. | 234 // it up. |
| 235 gfx::Rect selection_rect_; | 235 gfx::Rect selection_rect_; |
| 236 | 236 |
| 237 NotificationRegistrar registrar_; | 237 NotificationRegistrar registrar_; |
| 238 | 238 |
| 239 DISALLOW_COPY_AND_ASSIGN(FindBarGtk); | 239 DISALLOW_COPY_AND_ASSIGN(FindBarGtk); |
| 240 }; | 240 }; |
| 241 | 241 |
| 242 #endif // CHROME_BROWSER_UI_GTK_FIND_BAR_GTK_H_ | 242 #endif // CHROME_BROWSER_UI_GTK_FIND_BAR_GTK_H_ |
| OLD | NEW |