| OLD | NEW |
| 1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2009 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_COMMON_GTK_UTIL_H_ | 5 #ifndef CHROME_COMMON_GTK_UTIL_H_ |
| 6 #define CHROME_COMMON_GTK_UTIL_H_ | 6 #define CHROME_COMMON_GTK_UTIL_H_ |
| 7 | 7 |
| 8 #include <gtk/gtk.h> | 8 #include <gtk/gtk.h> |
| 9 #include <string> | 9 #include <string> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 185 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 196 | 196 |
| 197 // Get a rectangle corresponding to a widget's allocation relative to its | 197 // Get a rectangle corresponding to a widget's allocation relative to its |
| 198 // toplevel window's origin. | 198 // toplevel window's origin. |
| 199 gfx::Rect GetWidgetRectRelativeToToplevel(GtkWidget* widget); | 199 gfx::Rect GetWidgetRectRelativeToToplevel(GtkWidget* widget); |
| 200 | 200 |
| 201 // A helper function for gtk_message_dialog_new() to work around a KDE 3 window | 201 // A helper function for gtk_message_dialog_new() to work around a KDE 3 window |
| 202 // manager bugs. You should always call it after creating a dialog with | 202 // manager bugs. You should always call it after creating a dialog with |
| 203 // gtk_message_dialog_new. | 203 // gtk_message_dialog_new. |
| 204 void ApplyMessageDialogQuirks(GtkWidget* dialog); | 204 void ApplyMessageDialogQuirks(GtkWidget* dialog); |
| 205 | 205 |
| 206 // Don't allow the widget to paint anything, and instead propagate the expose |
| 207 // to its children. This is similar to calling |
| 208 // |
| 209 // gtk_widget_set_app_paintable(container, TRUE); |
| 210 // |
| 211 // except that it will always work, and it should be called after any custom |
| 212 // expose events are connected. |
| 213 void SuppressDefaultPainting(GtkWidget* container); |
| 214 |
| 206 } // namespace gtk_util | 215 } // namespace gtk_util |
| 207 | 216 |
| 208 #endif // CHROME_COMMON_GTK_UTIL_H_ | 217 #endif // CHROME_COMMON_GTK_UTIL_H_ |
| OLD | NEW |