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

Issue 15067008: [InfoBar] Add InfoBarDelegate::GetIconID() (Closed)

Created:
7 years, 7 months ago by gone
Modified:
7 years, 7 months ago
Reviewers:
Peter Kasting, sky
CC:
chromium-reviews, asanka, Raman Kakilate, jam, Aaron Boodman, benquan, feature-media-reviews_chromium.org, ahutter, browser-components-watch_chromium.org, dbeam+watch-autofill_chromium.org, chromium-apps-reviews_chromium.org, benjhayden+dwatch_chromium.org, pam+watch_chromium.org, Dane Wallinga, dyu1, Albert Bodenhamer, sail+watch_chromium.org, estade+watch_chromium.org, markusheintz_, Ilya Sherman, tfarina, stuartmorgan+watch_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Visibility:
Public.

Description

[InfoBar] Add InfoBarDelegate::GetIconID() Splits apart the GetIcon() call to allow accessing the ID of the resource in addition to the loaded image. This is needed so that the Android port can determine which of the Java-side resources it needs to load for its UI. * GetIconID() is a function that gets overridden by subclasses instead of GetIcon(). GetIconID() returns the IDR_* tag that represents the icon that it would normally load. * GetIcon() now calls GetIconID() and shouldn't be overridden. * Small change to the SimpleAlertInfoBarDelegate::Create() call to account for invalid icon IDs (was NULL for bitmaps, 0 for non-existent icons). BUG=237034 Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=200598

Patch Set 1 #

Patch Set 2 : Platform fixes #

Patch Set 3 : Compile fixes #

Patch Set 4 : Renaming back to GetIcon() #

Total comments: 2

Patch Set 5 : Remove unused includes #

Total comments: 4

Patch Set 6 : Addressing comments #

Total comments: 3

Patch Set 7 : Adding ownership info #

Patch Set 8 : Replaced invalid icon ID with 0 for related CL #

Patch Set 9 : Rebase ate a function #

Patch Set 10 : Removed pointer #

Patch Set 11 : Explicitly defined an invalid icon ID #

Patch Set 12 : Compile fix #

Patch Set 13 : Re-uploading #

Patch Set 14 : Missed one #

Total comments: 4

Patch Set 15 : Nit fixes #

Total comments: 2

Patch Set 16 : Nit fixes redux #

Unified diffs Side-by-side diffs Delta from patch set Stats (+131 lines, -167 lines) Patch
M chrome/browser/accessibility/accessibility_extension_apitest.cc View 1 2 3 4 5 6 7 8 9 10 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/autofill/autofill_cc_infobar_delegate.h View 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/autofill/autofill_cc_infobar_delegate.cc View 1 2 3 4 2 chunks +2 lines, -4 lines 0 comments Download
M chrome/browser/download/download_request_infobar_delegate.h View 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/download/download_request_infobar_delegate.cc View 1 2 3 4 2 chunks +2 lines, -4 lines 0 comments Download
M chrome/browser/extensions/theme_installed_infobar_delegate.h View 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/extensions/theme_installed_infobar_delegate.cc View 1 2 3 4 2 chunks +2 lines, -4 lines 0 comments Download
M chrome/browser/geolocation/geolocation_browsertest.cc View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/geolocation/geolocation_infobar_delegate.h View 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/geolocation/geolocation_infobar_delegate.cc View 1 2 3 4 2 chunks +2 lines, -4 lines 0 comments Download
M chrome/browser/infobars/infobar_delegate.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 3 chunks +10 lines, -3 lines 0 comments Download
M chrome/browser/infobars/infobar_delegate.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 3 chunks +11 lines, -2 lines 0 comments Download
M chrome/browser/infobars/simple_alert_infobar_delegate.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 chunk +4 lines, -4 lines 0 comments Download
M chrome/browser/infobars/simple_alert_infobar_delegate.cc View 2 chunks +6 lines, -6 lines 0 comments Download
M chrome/browser/managed_mode/managed_mode_navigation_observer.cc View 1 2 3 4 5 6 7 8 9 10 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/media/media_stream_infobar_delegate.h View 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/media/media_stream_infobar_delegate.cc View 1 2 3 4 2 chunks +3 lines, -5 lines 0 comments Download
M chrome/browser/notifications/desktop_notification_service.cc View 1 2 3 4 5 2 chunks +3 lines, -4 lines 0 comments Download
M chrome/browser/omnibox_search_hint.cc View 1 2 3 4 3 chunks +3 lines, -5 lines 0 comments Download
M chrome/browser/password_manager/password_manager_delegate_impl.cc View 1 2 3 4 3 chunks +3 lines, -5 lines 0 comments Download
M chrome/browser/pepper_broker_infobar_delegate.h View 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/pepper_broker_infobar_delegate.cc View 1 2 3 4 2 chunks +2 lines, -4 lines 0 comments Download
M chrome/browser/plugins/plugin_infobar_delegates.h View 3 chunks +3 lines, -3 lines 0 comments Download
M chrome/browser/plugins/plugin_infobar_delegates.cc View 1 2 3 4 4 chunks +6 lines, -10 lines 0 comments Download
M chrome/browser/plugins/plugin_observer.cc View 1 2 3 4 3 chunks +3 lines, -7 lines 0 comments Download
M chrome/browser/ssl/ssl_tab_helper.cc View 1 2 3 4 3 chunks +3 lines, -5 lines 0 comments Download
M chrome/browser/translate/translate_infobar_delegate.h View 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/translate/translate_infobar_delegate.cc View 1 2 3 4 2 chunks +2 lines, -4 lines 0 comments Download
M chrome/browser/ui/auto_login_infobar_delegate.h View 1 2 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/ui/auto_login_infobar_delegate.cc View 1 2 3 4 2 chunks +2 lines, -4 lines 0 comments Download
M chrome/browser/ui/browser.cc View 1 2 3 4 5 6 7 8 9 10 2 chunks +2 lines, -2 lines 0 comments Download
M chrome/browser/ui/chrome_select_file_policy.cc View 1 2 3 4 5 6 7 8 9 10 1 chunk +2 lines, -1 line 0 comments Download
M chrome/browser/ui/cocoa/infobars/infobar_controller.mm View 1 2 3 4 5 6 7 8 9 1 chunk +2 lines, -2 lines 0 comments Download
M chrome/browser/ui/cocoa/infobars/mock_confirm_infobar_delegate.h View 1 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/ui/cocoa/infobars/mock_confirm_infobar_delegate.cc View 1 2 3 4 5 6 7 8 9 10 1 chunk +2 lines, -2 lines 0 comments Download
M chrome/browser/ui/cocoa/keystone_infobar_delegate.mm View 1 2 3 4 3 chunks +3 lines, -5 lines 0 comments Download
M chrome/browser/ui/collected_cookies_infobar_delegate.h View 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/ui/collected_cookies_infobar_delegate.cc View 1 2 3 4 2 chunks +2 lines, -4 lines 0 comments Download
M chrome/browser/ui/content_settings/content_setting_changed_infobar_delegate.h View 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/ui/content_settings/content_setting_changed_infobar_delegate.cc View 1 2 3 4 2 chunks +2 lines, -3 lines 0 comments Download
M chrome/browser/ui/content_settings/content_setting_changed_infobar_delegate_unittest.cc View 1 2 3 4 2 chunks +1 line, -3 lines 0 comments Download
M chrome/browser/ui/extensions/app_metro_infobar_delegate_win.h View 1 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/ui/extensions/app_metro_infobar_delegate_win.cc View 1 2 3 4 2 chunks +2 lines, -4 lines 0 comments Download
M chrome/browser/ui/gtk/infobars/infobar_gtk.cc View 1 2 3 4 5 6 7 8 9 1 chunk +3 lines, -3 lines 0 comments Download
M chrome/browser/ui/hung_plugin_tab_helper.cc View 1 2 3 4 4 chunks +3 lines, -7 lines 0 comments Download
M chrome/browser/ui/omnibox/alternate_nav_infobar_delegate.h View 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/ui/omnibox/alternate_nav_infobar_delegate.cc View 1 2 3 4 2 chunks +2 lines, -4 lines 0 comments Download
M chrome/browser/ui/startup/autolaunch_prompt_win.cc View 1 2 3 4 3 chunks +3 lines, -5 lines 0 comments Download
M chrome/browser/ui/startup/bad_flags_prompt.cc View 1 2 3 4 5 6 7 8 9 10 1 chunk +2 lines, -1 line 0 comments Download
M chrome/browser/ui/startup/default_browser_prompt.cc View 1 2 3 4 3 chunks +3 lines, -5 lines 0 comments Download
M chrome/browser/ui/startup/session_crashed_prompt.h View 1 2 3 4 5 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/ui/startup/session_crashed_prompt.cc View 1 2 3 4 5 2 chunks +2 lines, -4 lines 0 comments Download
M chrome/browser/ui/views/infobars/infobar_view.cc View 1 2 3 4 5 6 7 8 9 1 chunk +3 lines, -3 lines 0 comments Download
M chrome/browser/ui/website_settings/website_settings_infobar_delegate.h View 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/ui/website_settings/website_settings_infobar_delegate.cc View 1 2 3 4 2 chunks +2 lines, -4 lines 0 comments Download

Messages

Total messages: 23 (0 generated)
gone
Hey all, This CL is a stepping stone to getting properly sized resources on Android; ...
7 years, 7 months ago (2013-05-11 00:41:26 UTC) #1
tfarina
https://chromiumcodereview.appspot.com/15067008/diff/19001/chrome/browser/infobars/infobar_delegate.h File chrome/browser/infobars/infobar_delegate.h (right): https://chromiumcodereview.appspot.com/15067008/diff/19001/chrome/browser/infobars/infobar_delegate.h#newcode87 chrome/browser/infobars/infobar_delegate.h:87: gfx::Image* GetIcon() const; if you kept the virtual, you ...
7 years, 7 months ago (2013-05-11 00:44:23 UTC) #2
gone
https://chromiumcodereview.appspot.com/15067008/diff/19001/chrome/browser/infobars/infobar_delegate.h File chrome/browser/infobars/infobar_delegate.h (right): https://chromiumcodereview.appspot.com/15067008/diff/19001/chrome/browser/infobars/infobar_delegate.h#newcode87 chrome/browser/infobars/infobar_delegate.h:87: gfx::Image* GetIcon() const; On 2013/05/11 00:44:23, tfarina wrote: > ...
7 years, 7 months ago (2013-05-11 00:48:24 UTC) #3
Jói
Hi Dan, You have three reviewers listed; can you specify which bits you wanted which ...
7 years, 7 months ago (2013-05-11 12:04:11 UTC) #4
gone
I'm honestly not sure who's the best to review it; the main change is actually ...
7 years, 7 months ago (2013-05-11 17:22:22 UTC) #5
tfarina
Yes, Peter took infobars and since then he is the main reviewer/OWNER for API changes ...
7 years, 7 months ago (2013-05-11 19:31:38 UTC) #6
Peter Kasting
Rubber-stamp LGTM. I did not review code outside infobar_delegate.* except for a few spot checks. ...
7 years, 7 months ago (2013-05-14 00:50:49 UTC) #7
gone
Thanks! Added sky@ to get through the rest of the directories. Sky: the changes in ...
7 years, 7 months ago (2013-05-14 17:50:17 UTC) #8
sky
https://chromiumcodereview.appspot.com/15067008/diff/42001/chrome/browser/infobars/infobar_delegate.h File chrome/browser/infobars/infobar_delegate.h (right): https://chromiumcodereview.appspot.com/15067008/diff/42001/chrome/browser/infobars/infobar_delegate.h#newcode107 chrome/browser/infobars/infobar_delegate.h:107: // NULL, no icon is shown. nit: document ownership ...
7 years, 7 months ago (2013-05-14 21:02:02 UTC) #9
gone
https://chromiumcodereview.appspot.com/15067008/diff/42001/chrome/browser/infobars/infobar_delegate.h File chrome/browser/infobars/infobar_delegate.h (right): https://chromiumcodereview.appspot.com/15067008/diff/42001/chrome/browser/infobars/infobar_delegate.h#newcode107 chrome/browser/infobars/infobar_delegate.h:107: // NULL, no icon is shown. I think it's ...
7 years, 7 months ago (2013-05-14 22:31:43 UTC) #10
Peter Kasting
https://chromiumcodereview.appspot.com/15067008/diff/42001/chrome/browser/infobars/infobar_delegate.h File chrome/browser/infobars/infobar_delegate.h (right): https://chromiumcodereview.appspot.com/15067008/diff/42001/chrome/browser/infobars/infobar_delegate.h#newcode107 chrome/browser/infobars/infobar_delegate.h:107: // NULL, no icon is shown. On 2013/05/14 22:31:44, ...
7 years, 7 months ago (2013-05-15 00:18:51 UTC) #11
gone
On 2013/05/15 00:18:51, Peter Kasting wrote: > https://chromiumcodereview.appspot.com/15067008/diff/42001/chrome/browser/infobars/infobar_delegate.h > File chrome/browser/infobars/infobar_delegate.h (right): > > https://chromiumcodereview.appspot.com/15067008/diff/42001/chrome/browser/infobars/infobar_delegate.h#newcode107 ...
7 years, 7 months ago (2013-05-15 00:27:15 UTC) #12
gone
On 2013/05/15 00:27:15, dfalcantara wrote: > On 2013/05/15 00:18:51, Peter Kasting wrote: > > > ...
7 years, 7 months ago (2013-05-15 00:31:54 UTC) #13
Peter Kasting
On 2013/05/15 00:31:54, dfalcantara wrote: > > What should the return value be here when ...
7 years, 7 months ago (2013-05-15 01:03:57 UTC) #14
gone
On 2013/05/15 01:03:57, Peter Kasting wrote: > On 2013/05/15 00:31:54, dfalcantara wrote: > > > ...
7 years, 7 months ago (2013-05-15 19:37:51 UTC) #15
sky
LGTM https://chromiumcodereview.appspot.com/15067008/diff/94001/chrome/browser/infobars/infobar_delegate.h File chrome/browser/infobars/infobar_delegate.h (right): https://chromiumcodereview.appspot.com/15067008/diff/94001/chrome/browser/infobars/infobar_delegate.h#newcode103 chrome/browser/infobars/infobar_delegate.h:103: static const int kNoIconID = 0; nit: constants ...
7 years, 7 months ago (2013-05-15 20:47:06 UTC) #16
gone
Thanks! Peter, is this good to go? https://chromiumcodereview.appspot.com/15067008/diff/94001/chrome/browser/infobars/infobar_delegate.h File chrome/browser/infobars/infobar_delegate.h (right): https://chromiumcodereview.appspot.com/15067008/diff/94001/chrome/browser/infobars/infobar_delegate.h#newcode103 chrome/browser/infobars/infobar_delegate.h:103: static const ...
7 years, 7 months ago (2013-05-15 21:42:59 UTC) #17
Peter Kasting
LGTM https://chromiumcodereview.appspot.com/15067008/diff/103001/chrome/browser/infobars/infobar_delegate.h File chrome/browser/infobars/infobar_delegate.h (right): https://chromiumcodereview.appspot.com/15067008/diff/103001/chrome/browser/infobars/infobar_delegate.h#newcode51 chrome/browser/infobars/infobar_delegate.h:51: static const int kNoIconID = 0; You may ...
7 years, 7 months ago (2013-05-15 21:47:42 UTC) #18
gone
Done, thanks! https://chromiumcodereview.appspot.com/15067008/diff/103001/chrome/browser/infobars/infobar_delegate.h File chrome/browser/infobars/infobar_delegate.h (right): https://chromiumcodereview.appspot.com/15067008/diff/103001/chrome/browser/infobars/infobar_delegate.h#newcode51 chrome/browser/infobars/infobar_delegate.h:51: static const int kNoIconID = 0; On ...
7 years, 7 months ago (2013-05-15 22:06:25 UTC) #19
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/dfalcantara@chromium.org/15067008/1054
7 years, 7 months ago (2013-05-15 22:07:19 UTC) #20
commit-bot: I haz the power
Retried try job too often on win_rel for step(s) interactive_ui_tests http://build.chromium.org/p/tryserver.chromium/buildstatus?builder=win_rel&number=149421
7 years, 7 months ago (2013-05-16 05:10:34 UTC) #21
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/dfalcantara@chromium.org/15067008/1054
7 years, 7 months ago (2013-05-16 17:04:04 UTC) #22
commit-bot: I haz the power
7 years, 7 months ago (2013-05-16 19:04:00 UTC) #23
Message was sent while issue was closed.
Change committed as 200598

Powered by Google App Engine
This is Rietveld 408576698