Home | History | Annotate | Download | only in bookmarks
      1 // Copyright (c) 2011 The Chromium Authors. All rights reserved.
      2 // Use of this source code is governed by a BSD-style license that can be
      3 // found in the LICENSE file.
      4 
      5 // Constants used for positioning the bookmark bar. These aren't placed in a
      6 // different file because they're conditionally included in cross platform code
      7 // and thus no Objective-C++ stuff.
      8 
      9 #ifndef CHROME_BROWSER_UI_COCOA_BOOKMARKS_BOOKMARK_BAR_CONSTANTS_H_
     10 #define CHROME_BROWSER_UI_COCOA_BOOKMARKS_BOOKMARK_BAR_CONSTANTS_H_
     11 
     12 #include "chrome/browser/ui/bookmarks/bookmark_bar_constants.h"
     13 
     14 namespace bookmarks {
     15 
     16 // Correction used for computing other values based on the height.
     17 const int kVisualHeightOffset = 2;
     18 
     19 // Bar height, when opened in "always visible" mode. This is actually a little
     20 // smaller than it should be (by |kVisualHeightOffset| points) because of the
     21 // visual overlap with the main toolbar. When using this to compute values
     22 // other than the actual height of the toolbar, be sure to add
     23 // |kVisualHeightOffset|.
     24 const int kBookmarkBarHeight = 26;
     25 
     26 // The amount of space between the inner bookmark bar and the outer toolbar on
     27 // new tab pages.
     28 const int kNTPBookmarkBarPadding =
     29     (chrome::kNTPBookmarkBarHeight -
     30         (kBookmarkBarHeight + kVisualHeightOffset)) / 2;
     31 
     32 // The height of buttons in the bookmark bar.
     33 const int kBookmarkButtonHeight = kBookmarkBarHeight + kVisualHeightOffset;
     34 
     35 // The height of buttons in a bookmark bar folder menu.
     36 const CGFloat kBookmarkFolderButtonHeight = 24.0;
     37 
     38 // The radius of the corner curves on the menu. Also used for sizing the shadow
     39 // window behind the menu window at times when the menu can be scrolled.
     40 const CGFloat kBookmarkBarMenuCornerRadius = 4.0;
     41 
     42 // Overlap (in pixels) between the toolbar and the bookmark bar (when showing in
     43 // normal mode).
     44 const CGFloat kBookmarkBarOverlap = 3.0;
     45 
     46 }  // namespace bookmarks
     47 
     48 #endif  // CHROME_BROWSER_UI_COCOA_BOOKMARKS_BOOKMARK_BAR_CONSTANTS_H_
     49