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

Issue 10942034: Revert 156318 - I had originally tried to build upon http://codereview.chromium.org/10869066/, but … (Closed)

Created:
8 years, 3 months ago by Ian Vollick
Modified:
8 years, 3 months ago
Reviewers:
Ian Vollick
CC:
chromium-reviews, Ian Vollick, tfarina, piman+watch_chromium.org, jonathan.backer
Visibility:
Public.

Description

Revert 156318 - I had originally tried to build upon http://codereview.chromium.org/10869066/, but the number of functions that needed to return (or needed to cope with) DestroyedType's was spiralling out of control and it seemed likely that a mistake would be made and bugs introduced. pkotwicz suggested I make the layer animator ref counted, and this seemed to be a much simpler and safer approach. This way, whenever we're in a LayerAnimator function that may notify observers, we create a scoped_refptr<LayerAnimator> for |this|. If the animator's owning layer gets deleted by an observer, then |this| will be safely destroyed when the function exits and the scoped_refptr falls out of scope. BUG=150604 TEST=LayerAnimatorTest.ObserverDeletesAnimatorAfter[FinishingAnimation|StoppingAnimation|Scheduling|Aborted] Review URL: https://chromiumcodereview.appspot.com/10919195 TBR=sky@chromium.org Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=157567

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+148 lines, -348 lines) Patch
M ui/compositor/layer.h View 1 chunk +1 line, -1 line 0 comments Download
M ui/compositor/layer.cc View 2 chunks +2 lines, -4 lines 0 comments Download
M ui/compositor/layer_animation_sequence.h View 1 chunk +3 lines, -3 lines 0 comments Download
M ui/compositor/layer_animation_sequence.cc View 2 chunks +4 lines, -7 lines 0 comments Download
M ui/compositor/layer_animator.h View 7 chunks +17 lines, -20 lines 0 comments Download
M ui/compositor/layer_animator.cc View 17 chunks +86 lines, -53 lines 0 comments Download
M ui/compositor/layer_animator_unittest.cc View 33 chunks +35 lines, -257 lines 0 comments Download
M ui/views/view_unittest.cc View 1 chunk +0 lines, -3 lines 0 comments Download

Messages

Total messages: 1 (0 generated)
Ian Vollick
8 years, 3 months ago (2012-09-19 17:58:55 UTC) #1

          

Powered by Google App Engine
This is Rietveld 408576698