|
Remove dependency from infobars component to the embedder
The infobars::InfoBar::kSeparatorLineHeight, ... constants were declared
in the infobars component but only defined in the embedder. Due to that,
the component was not self contained and every client had to contains
those symbols and ensure they were only defined once (or encounter linker
errors).
This change the constants to globals defined in infobars::InfoBar that
should be initialized by the embedder using infobars::InfoBar::Initialize.
Default values are provided in the component so that they can be used for
the unit tests or as default values by the embedder.
Added a call to infobars::Infobar::Initialize in chrome_browser_main.cc
and define constants in the Chrome embedder that have varying value in
function of the UI system used (views, cocoa, android, ios).
BUG= 382924
|
Unified diffs |
Side-by-side diffs |
Delta from patch set |
Stats (+174 lines, -86 lines) |
Patch |
|
M |
chrome/browser/chrome_browser_main.cc
|
View
|
|
3 chunks |
+7 lines, -0 lines |
0 comments
|
Download
|
|
M |
chrome/browser/extensions/extension_infobar_delegate.cc
|
View
|
|
1 chunk |
+2 lines, -2 lines |
0 comments
|
Download
|
|
A |
chrome/browser/ui/android/infobars/infobar_constants.cc
|
View
|
|
1 chunk |
+16 lines, -0 lines |
0 comments
|
Download
|
|
M |
chrome/browser/ui/cocoa/browser_window_controller_browsertest.mm
|
View
|
|
1 chunk |
+2 lines, -2 lines |
0 comments
|
Download
|
|
M |
chrome/browser/ui/cocoa/infobars/infobar_cocoa.mm
|
View
|
|
1 chunk |
+0 lines, -8 lines |
0 comments
|
Download
|
|
A |
chrome/browser/ui/cocoa/infobars/infobar_constants.cc
|
View
|
|
1 chunk |
+16 lines, -0 lines |
0 comments
|
Download
|
|
M |
chrome/browser/ui/cocoa/infobars/infobar_gradient_view.mm
|
View
|
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
|
M |
chrome/browser/ui/cocoa/infobars/infobar_utilities.mm
|
View
|
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
|
A |
chrome/browser/ui/infobar_constants.h
|
View
|
|
1 chunk |
+22 lines, -0 lines |
0 comments
|
Download
|
|
A |
chrome/browser/ui/ios/infobars/infobar_constants.cc
|
View
|
|
1 chunk |
+16 lines, -0 lines |
0 comments
|
Download
|
|
M |
chrome/browser/ui/views/infobars/extension_infobar.cc
|
View
|
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
|
M |
chrome/browser/ui/views/infobars/infobar_background.cc
|
View
|
|
2 chunks |
+3 lines, -3 lines |
0 comments
|
Download
|
|
A |
chrome/browser/ui/views/infobars/infobar_constants.cc
|
View
|
|
1 chunk |
+19 lines, -0 lines |
0 comments
|
Download
|
|
M |
chrome/browser/ui/views/infobars/infobar_view.cc
|
View
|
|
4 chunks |
+4 lines, -16 lines |
0 comments
|
Download
|
|
M |
chrome/chrome_browser_ui.gypi
|
View
|
|
6 chunks |
+6 lines, -1 line |
0 comments
|
Download
|
|
M |
components/infobars.gypi
|
View
|
|
1 chunk |
+0 lines, -1 line |
0 comments
|
Download
|
|
M |
components/infobars/core/infobar.h
|
View
|
|
1 chunk |
+18 lines, -7 lines |
0 comments
|
Download
|
|
M |
components/infobars/core/infobar.cc
|
View
|
|
4 chunks |
+33 lines, -10 lines |
0 comments
|
Download
|
|
D |
components/infobars/core/infobar_android.cc
|
View
|
|
1 chunk |
+0 lines, -15 lines |
0 comments
|
Download
|
|
M |
components/infobars/core/infobar_container.cc
|
View
|
|
3 chunks |
+5 lines, -5 lines |
0 comments
|
Download
|
|
M |
components/infobars/test/infobar_test.cc
|
View
|
|
1 chunk |
+2 lines, -13 lines |
0 comments
|
Download
|
Total messages: 10 (1 generated)
|