diff options
author | Iain Merrick <husky@google.com> | 2010-11-01 12:19:54 +0000 |
---|---|---|
committer | Iain Merrick <husky@google.com> | 2010-11-03 10:21:10 +0000 |
commit | 731df977c0511bca2206b5f333555b1205ff1f43 (patch) | |
tree | 0e750b949b3f00a1ac11fda25d3c2de512f2b465 /chrome/browser/gtk/gtk_util.h | |
parent | 5add15e10e7bb80512f2c597ca57221314abe577 (diff) | |
download | external_chromium-731df977c0511bca2206b5f333555b1205ff1f43.zip external_chromium-731df977c0511bca2206b5f333555b1205ff1f43.tar.gz external_chromium-731df977c0511bca2206b5f333555b1205ff1f43.tar.bz2 |
Merge Chromium at r63472 : Initial merge by git.
Change-Id: Ifb9ee821af006a5f2211e81471be93ae440a1f5a
Diffstat (limited to 'chrome/browser/gtk/gtk_util.h')
-rw-r--r-- | chrome/browser/gtk/gtk_util.h | 16 |
1 files changed, 15 insertions, 1 deletions
diff --git a/chrome/browser/gtk/gtk_util.h b/chrome/browser/gtk/gtk_util.h index 9c59fb5..466ba7e 100644 --- a/chrome/browser/gtk/gtk_util.h +++ b/chrome/browser/gtk/gtk_util.h @@ -14,8 +14,10 @@ #include "base/string16.h" #include "gfx/point.h" #include "gfx/rect.h" +#include "third_party/WebKit/WebKit/chromium/public/WebDragOperation.h" #include "webkit/glue/window_open_disposition.h" +typedef struct _cairo cairo_t; typedef struct _GtkWidget GtkWidget; class GtkThemeProvider; @@ -55,6 +57,9 @@ const int kContentAreaSpacing = 18; // Horizontal Spacing between controls in a form. const int kFormControlSpacing = 10; +// Height for the infobar drop shadow. +const int kInfoBarDropShadowHeight = 6; + // Create a table of labeled controls, using proper spacing and alignment. // Arguments should be pairs of const char*, GtkWidget*, concluding with a // NULL. The first argument is a vector in which to place all labels @@ -82,7 +87,6 @@ GtkWidget* LeftAlignMisc(GtkWidget* misc); // Create a left-aligned label with the given text in bold. GtkWidget* CreateBoldLabel(const std::string& text); - // As above, but a convenience method for configuring dialog size. // |width_id| and |height_id| are resource IDs for the size. If either of these // are set to -1, the respective size will be set to the widget default. @@ -335,6 +339,16 @@ void SetLabelWidth(GtkWidget* label, int pixel_width); // to make sure the pango can get correct font information for the calculation. void InitLabelSizeRequestAndEllipsizeMode(GtkWidget* label); +// Convenience methods for converting between web drag operations and the GDK +// equivalent. +GdkDragAction WebDragOpToGdkDragAction(WebKit::WebDragOperationsMask op); +WebKit::WebDragOperationsMask GdkDragActionToWebDragOp(GdkDragAction action); + +// Code to draw the drop shadow below an infobar (at the top of the render +// view). +void DrawTopDropShadowForRenderView(cairo_t* cr, const gfx::Point& origin, + const gfx::Rect& paint_rect); + } // namespace gtk_util #endif // CHROME_BROWSER_GTK_GTK_UTIL_H_ |