| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef CHROME_BROWSER_UI_VIEWS_LOCATION_BAR_LOCATION_BAR_VIEW_H_ | 5 #ifndef CHROME_BROWSER_UI_VIEWS_LOCATION_BAR_LOCATION_BAR_VIEW_H_ |
| 6 #define CHROME_BROWSER_UI_VIEWS_LOCATION_BAR_LOCATION_BAR_VIEW_H_ | 6 #define CHROME_BROWSER_UI_VIEWS_LOCATION_BAR_LOCATION_BAR_VIEW_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| (...skipping 274 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 285 static const int kBubblePadding; | 285 static const int kBubblePadding; |
| 286 | 286 |
| 287 private: | 287 private: |
| 288 typedef std::vector<ContentSettingImageView*> ContentSettingViews; | 288 typedef std::vector<ContentSettingImageView*> ContentSettingViews; |
| 289 | 289 |
| 290 friend class PageActionImageView; | 290 friend class PageActionImageView; |
| 291 friend class PageActionWithBadgeView; | 291 friend class PageActionWithBadgeView; |
| 292 typedef std::vector<ExtensionAction*> PageActions; | 292 typedef std::vector<ExtensionAction*> PageActions; |
| 293 typedef std::vector<PageActionWithBadgeView*> PageActionViews; | 293 typedef std::vector<PageActionWithBadgeView*> PageActionViews; |
| 294 | 294 |
| 295 // Helper for GetMinimumWidth(). Calculates the incremental minimum width |
| 296 // |view| should add to the trailing width after the omnibox. |
| 297 static int IncrementalMinimumWidth(views::View* view); |
| 298 |
| 295 // Returns the thickness of any visible left and right edge, in pixels. | 299 // Returns the thickness of any visible left and right edge, in pixels. |
| 296 int GetHorizontalEdgeThickness() const; | 300 int GetHorizontalEdgeThickness() const; |
| 297 | 301 |
| 298 // The same, but for the top and bottom edges. | 302 // The same, but for the top and bottom edges. |
| 299 int vertical_edge_thickness() const { | 303 int vertical_edge_thickness() const { |
| 300 return is_popup_mode_ ? kPopupEdgeThickness : kNormalEdgeThickness; | 304 return is_popup_mode_ ? kPopupEdgeThickness : kNormalEdgeThickness; |
| 301 } | 305 } |
| 302 | 306 |
| 303 // Updates the visibility state of the Content Blocked icons to reflect what | 307 // Updates the visibility state of the Content Blocked icons to reflect what |
| 304 // is actually blocked on the current page. Returns true if the visibility | 308 // is actually blocked on the current page. Returns true if the visibility |
| (...skipping 220 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 525 // Used to register for notifications received by NotificationObserver. | 529 // Used to register for notifications received by NotificationObserver. |
| 526 content::NotificationRegistrar registrar_; | 530 content::NotificationRegistrar registrar_; |
| 527 | 531 |
| 528 // Used to bind callback functions to this object. | 532 // Used to bind callback functions to this object. |
| 529 base::WeakPtrFactory<LocationBarView> weak_ptr_factory_; | 533 base::WeakPtrFactory<LocationBarView> weak_ptr_factory_; |
| 530 | 534 |
| 531 DISALLOW_COPY_AND_ASSIGN(LocationBarView); | 535 DISALLOW_COPY_AND_ASSIGN(LocationBarView); |
| 532 }; | 536 }; |
| 533 | 537 |
| 534 #endif // CHROME_BROWSER_UI_VIEWS_LOCATION_BAR_LOCATION_BAR_VIEW_H_ | 538 #endif // CHROME_BROWSER_UI_VIEWS_LOCATION_BAR_LOCATION_BAR_VIEW_H_ |
| OLD | NEW |