Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(74)

Unified Diff: ui/views/bubble/bubble_border.h

Issue 2519313002: MacViews: For "NO_ASSET" MD bubbles, just use the border drawn by the window server. (Closed)
Patch Set: respond to comments Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | ui/views/bubble/bubble_border.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/views/bubble/bubble_border.h
diff --git a/ui/views/bubble/bubble_border.h b/ui/views/bubble/bubble_border.h
index 181f5daee38a035677d9bec6f59f8cff23aa5dfa..ec1e25a88b5895e28593612c87c76494130f8dbc 100644
--- a/ui/views/bubble/bubble_border.h
+++ b/ui/views/bubble/bubble_border.h
@@ -15,6 +15,7 @@
#include "ui/views/border.h"
class SkPath;
+class SkRRect;
namespace gfx {
class Path;
@@ -230,8 +231,18 @@ class VIEWS_EXPORT BubbleBorder : public Border {
SkPath* path) const;
void DrawArrow(gfx::Canvas* canvas, const gfx::Rect& arrow_bounds) const;
+ // Returns the region within |view| representing the client area. This can be
+ // set as a canvas clip to ensure any fill or shadow from the border does not
+ // draw over the contents of the bubble.
+ SkRRect GetClientRect(const View& view) const;
+
+ // Paints an MD border. Ignores |shadow_|.
void PaintMd(const View& view, gfx::Canvas* canvas);
+ // Paint for the NO_ASSETS shadow type. This just paints transparent pixels
+ // to make the window shape based on insets and GetBorderCornerRadius().
+ void PaintNoAssets(const View& view, gfx::Canvas* canvas);
+
internal::BorderImages* GetImagesForTest() const;
Arrow arrow_;
« no previous file with comments | « no previous file | ui/views/bubble/bubble_border.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698