| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2012 Apple Inc. All rights reserved. | 2 * Copyright (C) 2012 Apple Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions | 5 * modification, are permitted provided that the following conditions |
| 6 * are met: | 6 * are met: |
| 7 * | 7 * |
| 8 * 1. Redistributions of source code must retain the above copyright | 8 * 1. Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * 2. Redistributions in binary form must reproduce the above copyright | 10 * 2. Redistributions in binary form must reproduce the above copyright |
| (...skipping 20 matching lines...) Expand all Loading... |
| 31 | 31 |
| 32 #include "core/loader/EmptyClients.h" | 32 #include "core/loader/EmptyClients.h" |
| 33 #include "platform/Timer.h" | 33 #include "platform/Timer.h" |
| 34 | 34 |
| 35 namespace blink { | 35 namespace blink { |
| 36 | 36 |
| 37 class SVGImage; | 37 class SVGImage; |
| 38 | 38 |
| 39 class SVGImageChromeClient final : public EmptyChromeClient { | 39 class SVGImageChromeClient final : public EmptyChromeClient { |
| 40 public: | 40 public: |
| 41 static PassOwnPtrWillBeRawPtr<SVGImageChromeClient> create(SVGImage*); | 41 static RawPtr<SVGImageChromeClient> create(SVGImage*); |
| 42 | 42 |
| 43 bool isSVGImageChromeClient() const override; | 43 bool isSVGImageChromeClient() const override; |
| 44 | 44 |
| 45 SVGImage* image() const { return m_image; } | 45 SVGImage* image() const { return m_image; } |
| 46 | 46 |
| 47 private: | 47 private: |
| 48 explicit SVGImageChromeClient(SVGImage*); | 48 explicit SVGImageChromeClient(SVGImage*); |
| 49 | 49 |
| 50 void chromeDestroyed() override; | 50 void chromeDestroyed() override; |
| 51 void invalidateRect(const IntRect&) override; | 51 void invalidateRect(const IntRect&) override; |
| 52 void scheduleAnimation(Widget*) override; | 52 void scheduleAnimation(Widget*) override; |
| 53 | 53 |
| 54 void animationTimerFired(Timer<SVGImageChromeClient>*); | 54 void animationTimerFired(Timer<SVGImageChromeClient>*); |
| 55 | 55 |
| 56 SVGImage* m_image; | 56 SVGImage* m_image; |
| 57 Timer<SVGImageChromeClient> m_animationTimer; | 57 Timer<SVGImageChromeClient> m_animationTimer; |
| 58 }; | 58 }; |
| 59 | 59 |
| 60 DEFINE_TYPE_CASTS(SVGImageChromeClient, ChromeClient, client, client->isSVGImage
ChromeClient(), client.isSVGImageChromeClient()); | 60 DEFINE_TYPE_CASTS(SVGImageChromeClient, ChromeClient, client, client->isSVGImage
ChromeClient(), client.isSVGImageChromeClient()); |
| 61 | 61 |
| 62 } // namespace blink | 62 } // namespace blink |
| 63 | 63 |
| 64 #endif // SVGImageChromeClient_h | 64 #endif // SVGImageChromeClient_h |
| OLD | NEW |