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

Side by Side Diff: chrome/browser/ui/infobar_container_delegate.h

Issue 2196203002: [Mac] The infobar's top arrow should be hidden while the omnibox popup is shown (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Revert to the patch set 1 Created 4 years, 4 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 unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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_INFOBAR_CONTAINER_DELEGATE_H_ 5 #ifndef CHROME_BROWSER_UI_INFOBAR_CONTAINER_DELEGATE_H_
6 #define CHROME_BROWSER_UI_INFOBAR_CONTAINER_DELEGATE_H_ 6 #define CHROME_BROWSER_UI_INFOBAR_CONTAINER_DELEGATE_H_
7 7
8 #include <stddef.h> 8 #include <stddef.h>
9 9
10 #include "base/macros.h" 10 #include "base/macros.h"
(...skipping 15 matching lines...) Expand all
26 InfoBarContainerDelegate(); 26 InfoBarContainerDelegate();
27 ~InfoBarContainerDelegate() override; 27 ~InfoBarContainerDelegate() override;
28 28
29 // Called when the distance between what the top infobar's "unspoofable" arrow 29 // Called when the distance between what the top infobar's "unspoofable" arrow
30 // would point to and the top infobar itself changes. Sets the maximum height 30 // would point to and the top infobar itself changes. Sets the maximum height
31 // of the top arrow to the new |height| and asks |container| to update its 31 // of the top arrow to the new |height| and asks |container| to update its
32 // infobars accordingly. This enables the top infobar to show a longer arrow 32 // infobars accordingly. This enables the top infobar to show a longer arrow
33 // (e.g. because of a visible bookmark bar) or shorter (e.g. due to being in a 33 // (e.g. because of a visible bookmark bar) or shorter (e.g. due to being in a
34 // popup window) if desired. 34 // popup window) if desired.
35 void SetMaxTopArrowHeight(int height, infobars::InfoBarContainer* container); 35 void SetMaxTopArrowHeight(int height, infobars::InfoBarContainer* container);
36 int DefaultMaxTopArrowHeight() const;
36 37
37 // infobars::InfoBarContainer::Delegate: 38 // infobars::InfoBarContainer::Delegate:
38 int ArrowTargetHeightForInfoBar( 39 int ArrowTargetHeightForInfoBar(
39 size_t index, 40 size_t index,
40 const gfx::SlideAnimation& animation) const override; 41 const gfx::SlideAnimation& animation) const override;
41 void ComputeInfoBarElementSizes(const gfx::SlideAnimation& animation, 42 void ComputeInfoBarElementSizes(const gfx::SlideAnimation& animation,
42 int arrow_target_height, 43 int arrow_target_height,
43 int bar_target_height, 44 int bar_target_height,
44 int* arrow_height, 45 int* arrow_height,
45 int* arrow_half_width, 46 int* arrow_half_width,
46 int* bar_height) const override; 47 int* bar_height) const override;
47 48
48 private: 49 private:
49 int top_arrow_target_height_; 50 int top_arrow_target_height_;
50 51
51 DISALLOW_COPY_AND_ASSIGN(InfoBarContainerDelegate); 52 DISALLOW_COPY_AND_ASSIGN(InfoBarContainerDelegate);
52 }; 53 };
53 54
54 #endif // CHROME_BROWSER_UI_INFOBAR_CONTAINER_DELEGATE_H_ 55 #endif // CHROME_BROWSER_UI_INFOBAR_CONTAINER_DELEGATE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698