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

Side by Side Diff: Source/core/rendering/RenderObject.cpp

Issue 46353003: Switch AutoscrollController to use animation system instead of timer (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@gclient
Patch Set: addresses review feedback Created 7 years, 1 month 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 unified diff | Download patch
« no previous file with comments | « Source/core/rendering/RenderBox.cpp ('k') | Source/web/PageWidgetDelegate.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org)
3 * (C) 1999 Antti Koivisto (koivisto@kde.org) 3 * (C) 1999 Antti Koivisto (koivisto@kde.org)
4 * (C) 2000 Dirk Mueller (mueller@kde.org) 4 * (C) 2000 Dirk Mueller (mueller@kde.org)
5 * (C) 2004 Allan Sandfeld Jensen (kde@carewolf.com) 5 * (C) 2004 Allan Sandfeld Jensen (kde@carewolf.com)
6 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2011 Apple Inc. All rights reserv ed. 6 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2011 Apple Inc. All rights reserv ed.
7 * Copyright (C) 2009 Google Inc. All rights reserved. 7 * Copyright (C) 2009 Google Inc. All rights reserved.
8 * Copyright (C) 2009 Torch Mobile Inc. All rights reserved. (http://www.torchmo bile.com/) 8 * Copyright (C) 2009 Torch Mobile Inc. All rights reserved. (http://www.torchmo bile.com/)
9 * 9 *
10 * This library is free software; you can redistribute it and/or 10 * This library is free software; you can redistribute it and/or
(...skipping 21 matching lines...) Expand all
32 #include "core/accessibility/AXObjectCache.h" 32 #include "core/accessibility/AXObjectCache.h"
33 #include "core/animation/ActiveAnimations.h" 33 #include "core/animation/ActiveAnimations.h"
34 #include "core/css/resolver/StyleResolver.h" 34 #include "core/css/resolver/StyleResolver.h"
35 #include "core/editing/EditingBoundary.h" 35 #include "core/editing/EditingBoundary.h"
36 #include "core/editing/FrameSelection.h" 36 #include "core/editing/FrameSelection.h"
37 #include "core/editing/htmlediting.h" 37 #include "core/editing/htmlediting.h"
38 #include "core/html/HTMLAnchorElement.h" 38 #include "core/html/HTMLAnchorElement.h"
39 #include "core/html/HTMLElement.h" 39 #include "core/html/HTMLElement.h"
40 #include "core/html/HTMLHtmlElement.h" 40 #include "core/html/HTMLHtmlElement.h"
41 #include "core/html/HTMLTableElement.h" 41 #include "core/html/HTMLTableElement.h"
42 #include "core/page/AutoscrollController.h"
42 #include "core/page/EventHandler.h" 43 #include "core/page/EventHandler.h"
43 #include "core/frame/Frame.h" 44 #include "core/frame/Frame.h"
44 #include "core/frame/FrameView.h" 45 #include "core/frame/FrameView.h"
45 #include "core/page/Page.h" 46 #include "core/page/Page.h"
46 #include "core/page/Settings.h" 47 #include "core/page/Settings.h"
47 #include "core/page/UseCounter.h" 48 #include "core/page/UseCounter.h"
48 #include "core/frame/animation/AnimationController.h" 49 #include "core/frame/animation/AnimationController.h"
49 #include "core/platform/graphics/GraphicsContext.h" 50 #include "core/platform/graphics/GraphicsContext.h"
50 #include "core/rendering/CompositedLayerMapping.h" 51 #include "core/rendering/CompositedLayerMapping.h"
51 #include "core/rendering/FlowThreadController.h" 52 #include "core/rendering/FlowThreadController.h"
(...skipping 2499 matching lines...) Expand 10 before | Expand all | Expand 10 after
2551 } 2552 }
2552 } 2553 }
2553 2554
2554 void RenderObject::willBeDestroyed() 2555 void RenderObject::willBeDestroyed()
2555 { 2556 {
2556 // Destroy any leftover anonymous children. 2557 // Destroy any leftover anonymous children.
2557 RenderObjectChildList* children = virtualChildren(); 2558 RenderObjectChildList* children = virtualChildren();
2558 if (children) 2559 if (children)
2559 children->destroyLeftoverChildren(); 2560 children->destroyLeftoverChildren();
2560 2561
2561 // If this renderer is being autoscrolled, stop the autoscroll timer 2562 // If this renderer is being autoscrolled, stop the autoscrolling.
2562 if (Frame* frame = this->frame()) { 2563 if (Frame* frame = this->frame()) {
2563 if (frame->page()) 2564 if (frame->page())
2564 frame->page()->stopAutoscrollIfNeeded(this); 2565 frame->page()->autoscrollController().stopAutoscrollIfNeeded(this);
2565 frame->animation().cancelAnimations(this); 2566 frame->animation().cancelAnimations(this);
2566 } 2567 }
2567 2568
2568 // For accessibility management, notify the parent of the imminent change to its child set. 2569 // For accessibility management, notify the parent of the imminent change to its child set.
2569 // We do it now, before remove(), while the parent pointer is still availabl e. 2570 // We do it now, before remove(), while the parent pointer is still availabl e.
2570 if (AXObjectCache* cache = document().existingAXObjectCache()) 2571 if (AXObjectCache* cache = document().existingAXObjectCache())
2571 cache->childrenChanged(this->parent()); 2572 cache->childrenChanged(this->parent());
2572 2573
2573 remove(); 2574 remove();
2574 2575
(...skipping 818 matching lines...) Expand 10 before | Expand all | Expand 10 after
3393 { 3394 {
3394 if (object1) { 3395 if (object1) {
3395 const WebCore::RenderObject* root = object1; 3396 const WebCore::RenderObject* root = object1;
3396 while (root->parent()) 3397 while (root->parent())
3397 root = root->parent(); 3398 root = root->parent();
3398 root->showRenderTreeAndMark(object1, "*", object2, "-", 0); 3399 root->showRenderTreeAndMark(object1, "*", object2, "-", 0);
3399 } 3400 }
3400 } 3401 }
3401 3402
3402 #endif 3403 #endif
OLDNEW
« no previous file with comments | « Source/core/rendering/RenderBox.cpp ('k') | Source/web/PageWidgetDelegate.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698