|
Refactored the translate infobars.
Since some work is needed on Linux and Mac to use the new translate infobar delegate, I created a new version of the refactored classes instead of replacing them. Once Linux and Mac use the new classes, we can make the swicth.
The TranslateInfoBarDelegate now contains all states, so there is no more logic on the infobar classes.
I broke down the single infobar class into multiple ones (there is now an infobar for each state: before translate, translating, after translate, error): it makes the code simpler.
I had to fix ReplaceInfoBar on Windows as it was not working properly.
BUG= 40828
TEST=Test thoroughly the translate feature.
Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=49307
Total comments: 53
|
Unified diffs |
Side-by-side diffs |
Delta from patch set |
Stats (+3651 lines, -217 lines) |
Patch |
 |
M |
app/l10n_util.h
|
View
|
|
1 chunk |
+3 lines, -0 lines |
0 comments
|
Download
|
 |
M |
app/l10n_util.cc
|
View
|
|
1 chunk |
+9 lines, -0 lines |
0 comments
|
Download
|
 |
M |
chrome/app/generated_resources.grd
|
View
|
1
2
3
4
|
1 chunk |
+3 lines, -0 lines |
0 comments
|
Download
|
 |
M |
chrome/browser/browser_main.cc
|
View
|
1
2
3
4
|
2 chunks |
+8 lines, -0 lines |
0 comments
|
Download
|
 |
M |
chrome/browser/tab_contents/infobar_delegate.h
|
View
|
|
2 chunks |
+4 lines, -0 lines |
0 comments
|
Download
|
 |
M |
chrome/browser/tab_contents/render_view_context_menu.cc
|
View
|
1
2
3
4
|
2 chunks |
+8 lines, -0 lines |
0 comments
|
Download
|
 |
A |
chrome/browser/translate/languages_menu_model2.h
|
View
|
1
|
1 chunk |
+40 lines, -0 lines |
0 comments
|
Download
|
 |
A |
chrome/browser/translate/languages_menu_model2.cc
|
View
|
|
1 chunk |
+49 lines, -0 lines |
0 comments
|
Download
|
 |
M |
chrome/browser/translate/options_menu_model.h
|
View
|
|
1 chunk |
+10 lines, -2 lines |
0 comments
|
Download
|
 |
M |
chrome/browser/translate/options_menu_model.cc
|
View
|
|
3 chunks |
+17 lines, -1 line |
0 comments
|
Download
|
 |
A |
chrome/browser/translate/options_menu_model2.h
|
View
|
|
1 chunk |
+36 lines, -0 lines |
0 comments
|
Download
|
 |
A |
chrome/browser/translate/options_menu_model2.cc
|
View
|
1
|
1 chunk |
+114 lines, -0 lines |
0 comments
|
Download
|
 |
A |
chrome/browser/translate/translate_infobar_delegate2.h
|
View
|
1
2
3
|
1 chunk |
+178 lines, -0 lines |
0 comments
|
Download
|
 |
A |
chrome/browser/translate/translate_infobar_delegate2.cc
|
View
|
1
2
3
4
|
1 chunk |
+305 lines, -0 lines |
0 comments
|
Download
|
 |
A |
chrome/browser/translate/translate_infobar_view.h
|
View
|
1
|
1 chunk |
+19 lines, -0 lines |
0 comments
|
Download
|
 |
A |
chrome/browser/translate/translate_manager2.h
|
View
|
|
1 chunk |
+170 lines, -0 lines |
0 comments
|
Download
|
 |
A |
chrome/browser/translate/translate_manager2.cc
|
View
|
1
2
|
1 chunk |
+549 lines, -0 lines |
0 comments
|
Download
|
 |
A |
chrome/browser/translate/translate_manager2_unittest.cc
|
View
|
|
1 chunk |
+999 lines, -0 lines |
0 comments
|
Download
|
 |
A |
chrome/browser/views/infobars/after_translate_infobar.h
|
View
|
1
|
1 chunk |
+82 lines, -0 lines |
0 comments
|
Download
|
 |
A |
chrome/browser/views/infobars/after_translate_infobar.cc
|
View
|
1
2
3
4
|
1 chunk |
+170 lines, -0 lines |
0 comments
|
Download
|
 |
A |
chrome/browser/views/infobars/before_translate_infobar.h
|
View
|
1
|
1 chunk |
+76 lines, -0 lines |
0 comments
|
Download
|
 |
A |
chrome/browser/views/infobars/before_translate_infobar.cc
|
View
|
1
2
3
4
|
1 chunk |
+137 lines, -0 lines |
0 comments
|
Download
|
 |
A |
chrome/browser/views/infobars/infobar_button_border.h
|
View
|
1
|
1 chunk |
+52 lines, -0 lines |
0 comments
|
Download
|
 |
A |
chrome/browser/views/infobars/infobar_button_border.cc
|
View
|
1
|
1 chunk |
+142 lines, -0 lines |
0 comments
|
Download
|
 |
A |
chrome/browser/views/infobars/infobar_text_button.h
|
View
|
|
1 chunk |
+35 lines, -0 lines |
0 comments
|
Download
|
 |
A |
chrome/browser/views/infobars/infobar_text_button.cc
|
View
|
|
1 chunk |
+50 lines, -0 lines |
0 comments
|
Download
|
 |
M |
chrome/browser/views/infobars/infobars.cc
|
View
|
|
1 chunk |
+4 lines, -1 line |
0 comments
|
Download
|
 |
A |
chrome/browser/views/infobars/translate_infobar_base.h
|
View
|
1
2
|
1 chunk |
+76 lines, -0 lines |
0 comments
|
Download
|
 |
A |
chrome/browser/views/infobars/translate_infobar_base.cc
|
View
|
1
2
|
1 chunk |
+179 lines, -0 lines |
0 comments
|
Download
|
 |
M |
chrome/browser/views/infobars/translate_infobars.h
|
View
|
|
2 chunks |
+5 lines, -5 lines |
0 comments
|
Download
|
 |
M |
chrome/browser/views/infobars/translate_infobars.cc
|
View
|
|
6 chunks |
+9 lines, -204 lines |
0 comments
|
Download
|
 |
A |
chrome/browser/views/infobars/translate_message_infobar.h
|
View
|
1
|
1 chunk |
+28 lines, -0 lines |
0 comments
|
Download
|
 |
A |
chrome/browser/views/infobars/translate_message_infobar.cc
|
View
|
|
1 chunk |
+57 lines, -0 lines |
0 comments
|
Download
|
 |
M |
chrome/chrome_browser.gypi
|
View
|
1
2
3
4
|
2 chunks |
+21 lines, -0 lines |
0 comments
|
Download
|
 |
M |
chrome/chrome_tests.gypi
|
View
|
1
2
3
4
|
5 chunks |
+7 lines, -4 lines |
0 comments
|
Download
|
Total messages: 6 (0 generated)
|