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

Unified Diff: views/animation/bounds_animator.cc

Issue 1609008: Adds some debugging info in hopes of tracking leak in (Closed)
Patch Set: Removes supression Created 10 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « tools/valgrind/memcheck/suppressions.txt ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: views/animation/bounds_animator.cc
diff --git a/views/animation/bounds_animator.cc b/views/animation/bounds_animator.cc
index 65ba415082f3b19596363edbc1f183a545434923..fc23e3899984e22102fdb75cf7f18af55e7792b5 100644
--- a/views/animation/bounds_animator.cc
+++ b/views/animation/bounds_animator.cc
@@ -87,6 +87,13 @@ const SlideAnimation* BoundsAnimator::GetAnimationForView(View* view) {
void BoundsAnimator::SetAnimationDelegate(View* view,
AnimationDelegate* delegate,
bool delete_when_done) {
+#if defined(OS_LINUX)
+ if (!IsAnimating(view))
+ LOG(ERROR) << "SetAnimationDelegate: not animating view";
+ if (data_[view].delegate)
+ LOG(ERROR) << "SetAnimationDelegate: delegate already set: leaking";
+#endif
+
DCHECK(IsAnimating(view));
data_[view].delegate = delegate;
data_[view].delete_delegate_when_done = delete_when_done;
@@ -111,6 +118,10 @@ void BoundsAnimator::Cancel() {
if (data_.empty())
return;
+#if defined(OS_LINUX)
+ LOG(ERROR) << "Cancelling animations";
+#endif
+
while (!data_.empty())
data_.begin()->second.animation->Stop();
« no previous file with comments | « tools/valgrind/memcheck/suppressions.txt ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698