| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2012 Google Inc. All rights reserved. | 2 * Copyright (C) 2012 Google 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 * 1. Redistributions of source code must retain the above copyright | 7 * 1. Redistributions of source code must retain the above copyright |
| 8 * notice, this list of conditions and the following disclaimer. | 8 * notice, this list of conditions and the following disclaimer. |
| 9 * 2. Redistributions in binary form must reproduce the above copyright | 9 * 2. Redistributions in binary form must reproduce the above copyright |
| 10 * notice, this list of conditions and the following disclaimer in the | 10 * notice, this list of conditions and the following disclaimer in the |
| (...skipping 109 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 120 class WebCompositorSupportMock : public WebCompositorSupport { | 120 class WebCompositorSupportMock : public WebCompositorSupport { |
| 121 public: | 121 public: |
| 122 MOCK_METHOD3(createAnimation, WebCompositorAnimation*(const WebComposito
rAnimationCurve& curve, WebCompositorAnimation::TargetProperty target, int anima
tionId)); | 122 MOCK_METHOD3(createAnimation, WebCompositorAnimation*(const WebComposito
rAnimationCurve& curve, WebCompositorAnimation::TargetProperty target, int anima
tionId)); |
| 123 MOCK_METHOD0(createFloatAnimationCurve, WebFloatAnimationCurve*()); | 123 MOCK_METHOD0(createFloatAnimationCurve, WebFloatAnimationCurve*()); |
| 124 }; | 124 }; |
| 125 | 125 |
| 126 private: | 126 private: |
| 127 class PlatformProxy : public Platform { | 127 class PlatformProxy : public Platform { |
| 128 public: | 128 public: |
| 129 PlatformProxy(WebCompositorSupportMock** compositor) : m_compositor(comp
ositor) { } | 129 PlatformProxy(WebCompositorSupportMock** compositor) : m_compositor(comp
ositor) { } |
| 130 | |
| 131 virtual void cryptographicallyRandomValues(unsigned char* buffer, size_t
length) { ASSERT_NOT_REACHED(); } | |
| 132 private: | 130 private: |
| 133 WebCompositorSupportMock** m_compositor; | 131 WebCompositorSupportMock** m_compositor; |
| 134 virtual WebCompositorSupport* compositorSupport() override { return *m_c
ompositor; } | 132 virtual WebCompositorSupport* compositorSupport() override { return *m_c
ompositor; } |
| 135 }; | 133 }; |
| 136 | 134 |
| 137 WebCompositorSupportMock* m_mockCompositor; | 135 WebCompositorSupportMock* m_mockCompositor; |
| 138 PlatformProxy m_proxyPlatform; | 136 PlatformProxy m_proxyPlatform; |
| 139 | 137 |
| 140 protected: | 138 protected: |
| 141 Platform* m_platform; | 139 Platform* m_platform; |
| (...skipping 13 matching lines...) Expand all Loading... |
| 155 void setCompositorForTesting(WebCompositorSupportMock& mock) | 153 void setCompositorForTesting(WebCompositorSupportMock& mock) |
| 156 { | 154 { |
| 157 ASSERT(!m_mockCompositor); | 155 ASSERT(!m_mockCompositor); |
| 158 m_mockCompositor = &mock; | 156 m_mockCompositor = &mock; |
| 159 } | 157 } |
| 160 }; | 158 }; |
| 161 | 159 |
| 162 } | 160 } |
| 163 | 161 |
| 164 #endif | 162 #endif |
| OLD | NEW |