summaryrefslogtreecommitdiffstats
path: root/chrome/browser/views/detachable_toolbar_view.h
diff options
context:
space:
mode:
authorfinnur@chromium.org <finnur@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-01-22 22:00:09 +0000
committerfinnur@chromium.org <finnur@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-01-22 22:00:09 +0000
commitbd5a00a743c92290ec01d6ea603a5fd96098093e (patch)
treee2db07ba7b8f7e75911e5dede215bb9551216450 /chrome/browser/views/detachable_toolbar_view.h
parenta26b7d4950c1e684ab1620674a335ff3a27eda5c (diff)
downloadchromium_src-bd5a00a743c92290ec01d6ea603a5fd96098093e.zip
chromium_src-bd5a00a743c92290ec01d6ea603a5fd96098093e.tar.gz
chromium_src-bd5a00a743c92290ec01d6ea603a5fd96098093e.tar.bz2
Resize and overflow for browser actions (part 1).
This changelist implements the following: - A resize gripper and chevron in the browser action container - Overflow when icons don't fit - Snap to multiple of icon size (no excess pixels) - Animation when resizing container / adding&removing icons (disable, enable). - Persists the last width of the browser action container. Known issues: - No menu (yes, the chevron button doesn't do anything yet). BUG=32101 TEST=Install and uninstall browser actions & make sure install bubble appears in the right location. Make sure browser action container does not expand if chevron is showing when you add browser action. Make sure container loses chevron when no overflow occurs. Make sure browser action icons never disappear due to shrinking when you release the mouse (when resizing). Make sure snapping works. Review URL: http://codereview.chromium.org/553039 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@36905 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/views/detachable_toolbar_view.h')
-rw-r--r--chrome/browser/views/detachable_toolbar_view.h12
1 files changed, 8 insertions, 4 deletions
diff --git a/chrome/browser/views/detachable_toolbar_view.h b/chrome/browser/views/detachable_toolbar_view.h
index d27ee53..7d49c9b 100644
--- a/chrome/browser/views/detachable_toolbar_view.h
+++ b/chrome/browser/views/detachable_toolbar_view.h
@@ -1,4 +1,4 @@
-// Copyright (c) 2009 The Chromium Authors. All rights reserved.
+// Copyright (c) 2010 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
@@ -66,9 +66,13 @@ class DetachableToolbarView : public AccessibleToolbarView {
const SkRect& rect,
double roundness);
- // Paint a themed gradient divider at location |x|. The color of the divider
- // is a gradient starting with |top_color| at the top, and changing into
- // |middle_color| and then over to |bottom_color| as you go further down.
+ // Paint a themed gradient divider at location |x|. |height| is the full
+ // height of the view you want to paint the divider into, not the height of
+ // the divider. The height of the divider will become:
+ // |height| - 2 * |vertical_padding|.
+ // The color of the divider is a gradient starting with |top_color| at the
+ // top, and changing into |middle_color| and then over to |bottom_color| as
+ // you go further down.
static void PaintVerticalDivider(gfx::Canvas* canvas,
int x,
int height,