| OLD | NEW |
| 1 /* | 1 /* |
| 2 Copyright (C) 1998 Lars Knoll (knoll@mpi-hd.mpg.de) | 2 Copyright (C) 1998 Lars Knoll (knoll@mpi-hd.mpg.de) |
| 3 Copyright (C) 2001 Dirk Mueller (mueller@kde.org) | 3 Copyright (C) 2001 Dirk Mueller (mueller@kde.org) |
| 4 Copyright (C) 2002 Waldo Bastian (bastian@kde.org) | 4 Copyright (C) 2002 Waldo Bastian (bastian@kde.org) |
| 5 Copyright (C) 2006 Samuel Weinig (sam.weinig@gmail.com) | 5 Copyright (C) 2006 Samuel Weinig (sam.weinig@gmail.com) |
| 6 Copyright (C) 2004, 2005, 2006, 2007 Apple Inc. All rights reserved. | 6 Copyright (C) 2004, 2005, 2006, 2007 Apple Inc. All rights reserved. |
| 7 | 7 |
| 8 This library is free software; you can redistribute it and/or | 8 This library is free software; you can redistribute it and/or |
| 9 modify it under the terms of the GNU Library General Public | 9 modify it under the terms of the GNU Library General Public |
| 10 License as published by the Free Software Foundation; either | 10 License as published by the Free Software Foundation; either |
| (...skipping 353 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 364 if (!image || image != m_image) | 364 if (!image || image != m_image) |
| 365 return; | 365 return; |
| 366 Resource::didAccessDecodedData(); | 366 Resource::didAccessDecodedData(); |
| 367 } | 367 } |
| 368 | 368 |
| 369 bool ImageResource::shouldPauseAnimation(const blink::Image* image) | 369 bool ImageResource::shouldPauseAnimation(const blink::Image* image) |
| 370 { | 370 { |
| 371 if (!image || image != m_image) | 371 if (!image || image != m_image) |
| 372 return false; | 372 return false; |
| 373 | 373 |
| 374 ResourceClientWalker<ImageResourceClient> w(m_clients); | |
| 375 while (ImageResourceClient* c = w.next()) { | |
| 376 if (c->willRenderImage(this)) | |
| 377 return false; | |
| 378 } | |
| 379 | |
| 380 return true; | 374 return true; |
| 381 } | 375 } |
| 382 | 376 |
| 383 void ImageResource::animationAdvanced(const blink::Image* image) | 377 void ImageResource::animationAdvanced(const blink::Image* image) |
| 384 { | 378 { |
| 385 if (!image || image != m_image) | 379 if (!image || image != m_image) |
| 386 return; | 380 return; |
| 387 notifyObservers(); | 381 notifyObservers(); |
| 388 } | 382 } |
| 389 | 383 |
| 390 void ImageResource::changedInRect(const blink::Image* image, const IntRect& rect
) | 384 void ImageResource::changedInRect(const blink::Image* image, const IntRect& rect
) |
| 391 { | 385 { |
| 392 if (!image || image != m_image) | 386 if (!image || image != m_image) |
| 393 return; | 387 return; |
| 394 notifyObservers(&rect); | 388 notifyObservers(&rect); |
| 395 } | 389 } |
| 396 | 390 |
| 397 bool ImageResource::currentFrameKnownToBeOpaque(const RenderObject* renderer) | 391 bool ImageResource::currentFrameKnownToBeOpaque(const RenderObject* renderer) |
| 398 { | 392 { |
| 399 blink::Image* image = imageForRenderer(renderer); | 393 blink::Image* image = imageForRenderer(renderer); |
| 400 if (image->isBitmapImage()) | 394 if (image->isBitmapImage()) |
| 401 image->nativeImageForCurrentFrame(); // force decode | 395 image->nativeImageForCurrentFrame(); // force decode |
| 402 return image->currentFrameKnownToBeOpaque(); | 396 return image->currentFrameKnownToBeOpaque(); |
| 403 } | 397 } |
| 404 | 398 |
| 405 } // namespace blink | 399 } // namespace blink |
| OLD | NEW |