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

Unified Diff: trunk/src/ui/views/bubble/bubble_frame_view.cc

Issue 14765016: Revert 198491 "Render opaque border with no shadow for web conte..." (Closed) Base URL: svn://svn.chromium.org/chrome/
Patch Set: Created 7 years, 7 months 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 | « trunk/src/ui/views/bubble/bubble_border.cc ('k') | trunk/src/ui/views/window/dialog_delegate.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: trunk/src/ui/views/bubble/bubble_frame_view.cc
===================================================================
--- trunk/src/ui/views/bubble/bubble_frame_view.cc (revision 198505)
+++ trunk/src/ui/views/bubble/bubble_frame_view.cc (working copy)
@@ -9,7 +9,6 @@
#include "grit/ui_resources.h"
#include "ui/base/hit_test.h"
#include "ui/base/resource/resource_bundle.h"
-#include "ui/gfx/path.h"
#include "ui/gfx/screen.h"
#include "ui/views/bubble/bubble_border.h"
#include "ui/views/controls/button/label_button.h"
@@ -97,43 +96,8 @@
}
void BubbleFrameView::GetWindowMask(const gfx::Size& size,
- gfx::Path* window_mask) {
- if (bubble_border_->shadow() != BubbleBorder::NO_SHADOW_OPAQUE_BORDER)
- return;
+ gfx::Path* window_mask) {}
- // Use a window mask roughly matching the border in the image assets.
-
- // Stroke size in pixels of borders in image assets.
- static const int kBorderStrokeSize = 1;
-
- gfx::Insets border_insets = bubble_border_->GetInsets();
- SkRect rect = {border_insets.left() - kBorderStrokeSize,
- border_insets.top() - kBorderStrokeSize,
- size.width() - border_insets.right() + kBorderStrokeSize,
- size.height() - border_insets.bottom() + kBorderStrokeSize};
-
- // Approximate rounded corners matching the border.
- SkPoint polygon[] = {
- {rect.left() + 2, rect.top()},
- {rect.left() + 1, rect.top() + 1},
- {rect.left(), rect.top() + 2},
-
- {rect.left(), rect.bottom() - 3},
- {rect.left() + 1, rect.bottom() - 2},
- {rect.left() + 2, rect.bottom()},
-
- {rect.right() - 3, rect.bottom()},
- {rect.right() - 1, rect.bottom() - 2},
- {rect.right(), rect.bottom() - 3},
-
- {rect.right(), rect.top() + 2},
- {rect.right() - 1, rect.top() + 1},
- {rect.right() - 2, rect.top()}
- };
-
- window_mask->addPoly(polygon, sizeof(polygon)/sizeof(polygon[0]), true);
-}
-
void BubbleFrameView::ResetWindowControls() {}
void BubbleFrameView::UpdateWindowIcon() {}
« no previous file with comments | « trunk/src/ui/views/bubble/bubble_border.cc ('k') | trunk/src/ui/views/window/dialog_delegate.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698