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

Side by Side Diff: Source/core/layout/LayoutObject.cpp

Issue 1147183003: Restore not-unused LayoutObject::getImageAnimationPolicy (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 years, 7 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « Source/core/layout/LayoutObject.h ('k') | no next file » | 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 2894 matching lines...) Expand 10 before | Expand all | Expand 10 after
2905 2905
2906 // We will not render a new image when Active DOM is suspended 2906 // We will not render a new image when Active DOM is suspended
2907 if (document().activeDOMObjectsAreSuspended()) 2907 if (document().activeDOMObjectsAreSuspended())
2908 return false; 2908 return false;
2909 2909
2910 // If we're not in a window (i.e., we're dormant from being in a background tab) 2910 // If we're not in a window (i.e., we're dormant from being in a background tab)
2911 // then we don't want to render either. 2911 // then we don't want to render either.
2912 return document().view()->isVisible(); 2912 return document().view()->isVisible();
2913 } 2913 }
2914 2914
2915 bool LayoutObject::getImageAnimationPolicy(ImageResource*, ImageAnimationPolicy& policy)
2916 {
2917 if (!document().settings())
2918 return false;
2919 policy = document().settings()->imageAnimationPolicy();
2920 return true;
2921 }
2922
2915 int LayoutObject::caretMinOffset() const 2923 int LayoutObject::caretMinOffset() const
2916 { 2924 {
2917 return 0; 2925 return 0;
2918 } 2926 }
2919 2927
2920 int LayoutObject::caretMaxOffset() const 2928 int LayoutObject::caretMaxOffset() const
2921 { 2929 {
2922 if (isReplaced()) 2930 if (isReplaced())
2923 return node() ? std::max(1U, node()->countChildren()) : 1; 2931 return node() ? std::max(1U, node()->countChildren()) : 1;
2924 if (isHR()) 2932 if (isHR())
(...skipping 361 matching lines...) Expand 10 before | Expand all | Expand 10 after
3286 const blink::LayoutObject* root = object1; 3294 const blink::LayoutObject* root = object1;
3287 while (root->parent()) 3295 while (root->parent())
3288 root = root->parent(); 3296 root = root->parent();
3289 root->showLayoutTreeAndMark(object1, "*", object2, "-", 0); 3297 root->showLayoutTreeAndMark(object1, "*", object2, "-", 0);
3290 } else { 3298 } else {
3291 fprintf(stderr, "Cannot showLayoutTree. Root is (nil)\n"); 3299 fprintf(stderr, "Cannot showLayoutTree. Root is (nil)\n");
3292 } 3300 }
3293 } 3301 }
3294 3302
3295 #endif 3303 #endif
OLDNEW
« no previous file with comments | « Source/core/layout/LayoutObject.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698