| Index: chrome/browser/views/tabs/tab_overview_container.cc
|
| ===================================================================
|
| --- chrome/browser/views/tabs/tab_overview_container.cc (revision 18731)
|
| +++ chrome/browser/views/tabs/tab_overview_container.cc (working copy)
|
| @@ -4,13 +4,9 @@
|
|
|
| #include "chrome/browser/views/tabs/tab_overview_container.h"
|
|
|
| -#include <gtk/gtk.h>
|
| -
|
| #include "app/gfx/canvas.h"
|
| -#include "app/gfx/path.h"
|
| #include "chrome/browser/views/tabs/tab_overview_grid.h"
|
| #include "third_party/skia/include/effects/SkGradientShader.h"
|
| -#include "views/widget/widget_gtk.h"
|
|
|
| // Padding between the edges of us and the grid.
|
| static const int kVerticalPadding = 43;
|
| @@ -19,9 +15,6 @@
|
| // Height of the arrow.
|
| static const int kArrowHeight = 28;
|
|
|
| -// Inset of the slight rounding on the corners.
|
| -static const int kEdgeInset = 5;
|
| -
|
| TabOverviewContainer::TabOverviewContainer() {
|
| }
|
|
|
| @@ -34,33 +27,6 @@
|
| max_size.height() - kVerticalPadding * 2 - kArrowHeight));
|
| }
|
|
|
| -void TabOverviewContainer::UpdateWidgetShape(int horizontal_center,
|
| - int width, int height) {
|
| - int bottom_y = height - kArrowHeight;
|
| - int right_edge = width - 1;
|
| - int center = width / 2;
|
| - // The points, in alternating x,y pairs.
|
| - int points[] = {
|
| - kEdgeInset, 0,
|
| - right_edge - kEdgeInset, 0,
|
| - right_edge, kEdgeInset,
|
| - right_edge, bottom_y - kEdgeInset - 1,
|
| - right_edge - kEdgeInset, bottom_y - 1,
|
| - center + kArrowHeight / 2, bottom_y - 1,
|
| - center, bottom_y - 1 + kArrowHeight,
|
| - center - kArrowHeight / 2, bottom_y - 1,
|
| - kEdgeInset, bottom_y - 1,
|
| - 0, bottom_y - 1 - kEdgeInset,
|
| - 0, kEdgeInset,
|
| - };
|
| - gfx::Path path;
|
| - path.moveTo(SkIntToScalar(points[0]), SkIntToScalar(points[1]));
|
| - for (size_t i = 2; i < arraysize(points); i += 2)
|
| - path.lineTo(SkIntToScalar(points[i]), SkIntToScalar(points[i + 1]));
|
| -
|
| - GetWidget()->SetShape(path);
|
| -}
|
| -
|
| gfx::Size TabOverviewContainer::GetPreferredSize() {
|
| gfx::Size tab_overview_pref = GetTabOverviewGrid()->GetPreferredSize();
|
| return gfx::Size(kHorizontalPadding * 2 + tab_overview_pref.width(),
|
| @@ -90,11 +56,6 @@
|
| canvas->drawPaint(paint);
|
| }
|
|
|
| -void TabOverviewContainer::DidChangeBounds(const gfx::Rect& previous,
|
| - const gfx::Rect& current) {
|
| - Layout();
|
| -}
|
| -
|
| TabOverviewGrid* TabOverviewContainer::GetTabOverviewGrid() {
|
| return static_cast<TabOverviewGrid*>(GetChildViewAt(0));
|
| }
|
|
|