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

Issue 2336453002: BackgroundGradientView: -drawBackground: → -drawRect: (Closed)

Created:
4 years, 3 months ago by Sidney San Martín
Modified:
4 years, 3 months ago
Reviewers:
Nico
CC:
chromium-reviews, asanka, tfarina, dbeam+watch-downloads_chromium.org
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

BackgroundGradientView: -drawBackground: → -drawRect: BackgroundGradientView had a -drawBackground: method that its clients were expected to call. This change moves background drawing to -drawRect: so that the it happens by default. Subclasses that did custom drawing already override -drawRect:, but this removes a couple of overrides that just forwarded to -drawBackground:. BUG=589943 Committed: https://crrev.com/6b1939a26d2839136aeeba2aa0e359fce0c20281 Cr-Commit-Position: refs/heads/master@{#418358}

Patch Set 1 #

Total comments: 3

Patch Set 2 : Put this back. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+13 lines, -33 lines) Patch
M chrome/browser/ui/cocoa/background_gradient_view.h View 1 chunk +1 line, -4 lines 0 comments Download
M chrome/browser/ui/cocoa/background_gradient_view.mm View 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/ui/cocoa/background_gradient_view_unittest.mm View 1 chunk +3 lines, -16 lines 0 comments Download
M chrome/browser/ui/cocoa/bookmarks/bookmark_bar_toolbar_view.mm View 3 chunks +4 lines, -4 lines 0 comments Download
M chrome/browser/ui/cocoa/download/download_shelf_view_cocoa.mm View 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/ui/cocoa/find_bar/find_bar_view_cocoa.mm View 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/ui/cocoa/tabs/tab_strip_view.mm View 1 2 chunks +2 lines, -2 lines 0 comments Download
M chrome/browser/ui/cocoa/toolbar/toolbar_view_cocoa.mm View 1 chunk +0 lines, -4 lines 0 comments Download

Dependent Patchsets:

Messages

Total messages: 17 (9 generated)
Sidney San Martín
4 years, 3 months ago (2016-09-12 11:59:17 UTC) #6
Nico
https://codereview.chromium.org/2336453002/diff/1/chrome/browser/ui/cocoa/tabs/tab_strip_view.mm File chrome/browser/ui/cocoa/tabs/tab_strip_view.mm (left): https://codereview.chromium.org/2336453002/diff/1/chrome/browser/ui/cocoa/tabs/tab_strip_view.mm#oldcode69 chrome/browser/ui/cocoa/tabs/tab_strip_view.mm:69: [self drawBackground:backgroundRect]; this looks unrelated? https://codereview.chromium.org/2336453002/diff/1/chrome/browser/ui/cocoa/tabs/tab_strip_view.mm#oldcode94 chrome/browser/ui/cocoa/tabs/tab_strip_view.mm:94: } ditto
4 years, 3 months ago (2016-09-12 13:36:11 UTC) #7
Sidney San Martín
https://codereview.chromium.org/2336453002/diff/1/chrome/browser/ui/cocoa/tabs/tab_strip_view.mm File chrome/browser/ui/cocoa/tabs/tab_strip_view.mm (left): https://codereview.chromium.org/2336453002/diff/1/chrome/browser/ui/cocoa/tabs/tab_strip_view.mm#oldcode69 chrome/browser/ui/cocoa/tabs/tab_strip_view.mm:69: [self drawBackground:backgroundRect]; On 2016/09/12 13:36:11, Nico wrote: > this ...
4 years, 3 months ago (2016-09-13 19:35:40 UTC) #9
Nico
lgtm
4 years, 3 months ago (2016-09-13 19:43:34 UTC) #10
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2336453002/40001
4 years, 3 months ago (2016-09-13 19:44:25 UTC) #12
commit-bot: I haz the power
Committed patchset #2 (id:40001)
4 years, 3 months ago (2016-09-13 20:45:06 UTC) #14
commit-bot: I haz the power
Patchset 2 (id:??) landed as https://crrev.com/6b1939a26d2839136aeeba2aa0e359fce0c20281 Cr-Commit-Position: refs/heads/master@{#418358}
4 years, 3 months ago (2016-09-13 20:47:37 UTC) #16
Sidney San Martín
4 years, 3 months ago (2016-09-14 22:12:54 UTC) #17
Message was sent while issue was closed.
A revert of this CL (patchset #2 id:40001) has been created in
https://codereview.chromium.org/2339143003/ by sdy@chromium.org.

The reason for reverting is: AnimatableView inherits from
BackgroundGradientView, so a number of
other views which *don't* want backgrounds end up inheriting from
BackgroundGradientView. This widened the scope of the change beyond what
I intended..

Powered by Google App Engine
This is Rietveld 408576698