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

Issue 284313008: Move TranslateInfoBarDelegate and OptionsMenuModel to the Translate component. (Closed)

Created:
6 years, 7 months ago by droger
Modified:
6 years, 6 months ago
CC:
chromium-reviews, benquan, tfarina, browser-components-watch_chromium.org, Dane Wallinga, dyu1, estade+watch_chromium.org, Ilya Sherman, rouslan+autofillwatch_chromium.org
Visibility:
Public.

Description

Move TranslateInfoBarDelegate and OptionsMenuModel to the Translate component. To solve the dependency on chrome_command_ids, this CL removes the IDC_OPTIONS_TRANSLATE_* constants and instead defines the command IDs locally in the file, which is an approach already used at several other places in the code. To solve the dependency on themes, the icon ID for the translate infobar is no longer hardcoded, but fetched from the translate client instead. BUG=371845 TBR=estade, joaodasilva Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=274252

Patch Set 1 #

Patch Set 2 : #

Patch Set 3 : comments #

Patch Set 4 : rebase #

Total comments: 7

Patch Set 5 : review comments #

Patch Set 6 : format #

Patch Set 7 : fix link error on android #

Patch Set 8 : fix ios compilation #

Patch Set 9 : fix android link again #

Patch Set 10 : fix android compile #

Total comments: 3

Patch Set 11 : fix android compilation #

Total comments: 2

Patch Set 12 : Rebase + review comments #

Unified diffs Side-by-side diffs Delta from patch set Stats (+156 lines, -914 lines) Patch
M build/ios/grit_whitelist.txt View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +15 lines, -0 lines 0 comments Download
M chrome/app/chrome_command_ids.h View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +2 lines, -7 lines 0 comments Download
M chrome/browser/autofill/autofill_interactive_uitest.cc View 1 2 3 4 2 chunks +1 line, -1 line 0 comments Download
M chrome/browser/policy/policy_browsertest.cc View 1 2 3 4 5 6 7 8 9 10 11 2 chunks +1 line, -1 line 0 comments Download
D chrome/browser/translate/options_menu_model.h View 1 chunk +0 lines, -34 lines 0 comments Download
D chrome/browser/translate/options_menu_model.cc View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +0 lines, -140 lines 0 comments Download
M chrome/browser/translate/translate_browsertest.cc View 2 chunks +1 line, -1 line 0 comments Download
D chrome/browser/translate/translate_infobar_delegate.h View 1 chunk +0 lines, -229 lines 0 comments Download
D chrome/browser/translate/translate_infobar_delegate.cc View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +0 lines, -384 lines 0 comments Download
M chrome/browser/translate/translate_manager_render_view_host_unittest.cc View 2 chunks +1 line, -1 line 0 comments Download
M chrome/browser/translate/translate_tab_helper.h View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +3 lines, -0 lines 0 comments Download
M chrome/browser/translate/translate_tab_helper.cc View 1 2 3 4 5 6 7 8 9 10 4 chunks +9 lines, -1 line 0 comments Download
M chrome/browser/ui/android/infobars/infobar_android.cc View 1 2 3 4 5 6 7 8 9 10 1 chunk +0 lines, -12 lines 0 comments Download
M chrome/browser/ui/android/infobars/translate_infobar.cc View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +5 lines, -5 lines 0 comments Download
M chrome/browser/ui/cocoa/infobars/translate_infobar_base.h View 1 chunk +2 lines, -2 lines 0 comments Download
M chrome/browser/ui/cocoa/infobars/translate_infobar_base.mm View 1 2 3 4 5 6 7 8 9 10 11 3 chunks +4 lines, -4 lines 0 comments Download
M chrome/browser/ui/cocoa/infobars/translate_infobar_unittest.mm View 1 2 3 4 5 6 7 8 9 10 3 chunks +7 lines, -5 lines 0 comments Download
M chrome/browser/ui/views/infobars/after_translate_infobar.cc View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +2 lines, -2 lines 0 comments Download
M chrome/browser/ui/views/infobars/before_translate_infobar.cc View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +2 lines, -2 lines 0 comments Download
M chrome/browser/ui/views/infobars/translate_infobar_base.cc View 1 2 3 4 5 6 7 8 9 10 11 2 chunks +4 lines, -5 lines 0 comments Download
M chrome/browser/ui/views/infobars/translate_language_menu_model.cc View 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/ui/views/infobars/translate_message_infobar.cc View 1 2 3 1 chunk +1 line, -1 line 0 comments Download
M chrome/chrome_browser.gypi View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +0 lines, -4 lines 0 comments Download
M components/infobars.gypi View 1 2 3 4 5 6 7 8 1 chunk +1 line, -0 lines 0 comments Download
A components/infobars/core/infobar_android.cc View 1 2 3 4 5 6 7 8 9 1 chunk +15 lines, -0 lines 0 comments Download
M components/translate.gypi View 1 2 3 4 5 6 7 3 chunks +7 lines, -0 lines 0 comments Download
M components/translate/DEPS View 1 chunk +1 line, -0 lines 0 comments Download
A + components/translate/core/browser/options_menu_model.h View 1 2 3 4 5 3 chunks +12 lines, -3 lines 0 comments Download
A + components/translate/core/browser/options_menu_model.cc View 1 2 3 4 5 6 7 8 9 10 11 6 chunks +26 lines, -29 lines 0 comments Download
M components/translate/core/browser/translate_client.h View 1 2 3 4 5 6 7 8 9 10 11 3 chunks +13 lines, -0 lines 0 comments Download
A + components/translate/core/browser/translate_infobar_delegate.h View 1 2 3 4 5 6 7 8 9 10 3 chunks +3 lines, -11 lines 0 comments Download
A + components/translate/core/browser/translate_infobar_delegate.cc View 1 2 3 4 5 6 7 8 9 10 11 10 chunks +17 lines, -29 lines 0 comments Download

Messages

Total messages: 25 (0 generated)
droger
6 years, 7 months ago (2014-05-21 09:08:27 UTC) #1
blundell
LGTM!
6 years, 7 months ago (2014-05-21 15:04:57 UTC) #2
droger
+pkasting as OWNER of chrome/browser/ui and also for the DEPS change (components/translate now depends on ...
6 years, 7 months ago (2014-05-21 15:41:14 UTC) #3
Peter Kasting
The whole translate infobar UI is going away in favor of the new bubble UI, ...
6 years, 7 months ago (2014-05-21 19:31:09 UTC) #4
droger
On 2014/05/21 19:31:09, Peter Kasting wrote: > The whole translate infobar UI is going away ...
6 years, 7 months ago (2014-05-21 19:41:43 UTC) #5
Peter Kasting
LGTM https://codereview.chromium.org/284313008/diff/60001/components/translate/core/browser/options_menu_model.cc File components/translate/core/browser/options_menu_model.cc (right): https://codereview.chromium.org/284313008/diff/60001/components/translate/core/browser/options_menu_model.cc#newcode28 components/translate/core/browser/options_menu_model.cc:28: const int OptionsMenuModel::kOptionsReportBadDetection = 4; Hmm, looks like ...
6 years, 7 months ago (2014-05-21 20:38:23 UTC) #6
cpu_(ooo_6.6-7.5)
lgtm for chrome_command_ids.h
6 years, 7 months ago (2014-05-22 00:27:11 UTC) #7
droger
Thanks, I applied the comments. TBR=estade for autofill TBR=joaodasilva for policy https://codereview.chromium.org/284313008/diff/60001/components/translate/core/browser/options_menu_model.cc File components/translate/core/browser/options_menu_model.cc (right): ...
6 years, 7 months ago (2014-05-22 12:33:36 UTC) #8
droger
The CQ bit was checked by droger@chromium.org
6 years, 7 months ago (2014-05-22 12:33:50 UTC) #9
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/droger@chromium.org/284313008/90001
6 years, 7 months ago (2014-05-22 12:34:33 UTC) #10
Joao da Silva
policy lgtm
6 years, 7 months ago (2014-05-22 13:01:51 UTC) #11
Peter Kasting
https://codereview.chromium.org/284313008/diff/20002/chrome/browser/ui/android/infobars/infobar_android.cc File chrome/browser/ui/android/infobars/infobar_android.cc (left): https://codereview.chromium.org/284313008/diff/20002/chrome/browser/ui/android/infobars/infobar_android.cc#oldcode16 chrome/browser/ui/android/infobars/infobar_android.cc:16: Nit: Leave two blank lines up here https://codereview.chromium.org/284313008/diff/20002/components/translate/core/browser/translate_infobar_delegate.cc File ...
6 years, 7 months ago (2014-05-22 17:37:23 UTC) #12
droger
blundell, pkasting: I had to make non-trivial changes to the CL after your LGTMs, so ...
6 years, 7 months ago (2014-05-26 12:16:04 UTC) #13
blundell
lgtm
6 years, 7 months ago (2014-05-26 12:32:50 UTC) #14
Peter Kasting
I will try to review this tomorrow.
6 years, 6 months ago (2014-05-28 02:17:27 UTC) #15
Peter Kasting
LGTM https://codereview.chromium.org/284313008/diff/180001/components/translate/core/browser/translate_client.h File components/translate/core/browser/translate_client.h (right): https://codereview.chromium.org/284313008/diff/180001/components/translate/core/browser/translate_client.h#newcode50 components/translate/core/browser/translate_client.h:50: scoped_ptr<TranslateInfoBarDelegate> delegate) = 0; Does this really need ...
6 years, 6 months ago (2014-05-28 19:25:55 UTC) #16
droger
https://codereview.chromium.org/284313008/diff/180001/components/translate/core/browser/translate_client.h File components/translate/core/browser/translate_client.h (right): https://codereview.chromium.org/284313008/diff/180001/components/translate/core/browser/translate_client.h#newcode50 components/translate/core/browser/translate_client.h:50: scoped_ptr<TranslateInfoBarDelegate> delegate) = 0; On 2014/05/28 19:25:55, Peter Kasting ...
6 years, 6 months ago (2014-06-02 11:30:14 UTC) #17
droger
The CQ bit was checked by droger@chromium.org
6 years, 6 months ago (2014-06-02 11:30:23 UTC) #18
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/droger@chromium.org/284313008/210001
6 years, 6 months ago (2014-06-02 11:31:16 UTC) #19
blundell
On 2014/06/02 11:30:14, droger wrote: > https://codereview.chromium.org/284313008/diff/180001/components/translate/core/browser/translate_client.h > File components/translate/core/browser/translate_client.h (right): > > https://codereview.chromium.org/284313008/diff/180001/components/translate/core/browser/translate_client.h#newcode50 > ...
6 years, 6 months ago (2014-06-02 11:42:54 UTC) #20
commit-bot: I haz the power
FYI, CQ is re-trying this CL (attempt #1). The failing builders are: linux_chromium_rel on tryserver.chromium ...
6 years, 6 months ago (2014-06-02 13:28:10 UTC) #21
droger
The CQ bit was unchecked by droger@chromium.org
6 years, 6 months ago (2014-06-02 14:52:17 UTC) #22
droger
The CQ bit was checked by droger@chromium.org
6 years, 6 months ago (2014-06-02 14:52:19 UTC) #23
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/droger@chromium.org/284313008/210001
6 years, 6 months ago (2014-06-02 14:53:51 UTC) #24
commit-bot: I haz the power
6 years, 6 months ago (2014-06-02 16:01:33 UTC) #25
Message was sent while issue was closed.
Change committed as 274252

Powered by Google App Engine
This is Rietveld 408576698