Chromium Code Reviews| Index: third_party/WebKit/Source/core/css/CSSPaintImageGenerator.h |
| diff --git a/third_party/WebKit/Source/core/css/CSSPaintImageGenerator.h b/third_party/WebKit/Source/core/css/CSSPaintImageGenerator.h |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..3dc28311dcc28b321ef18e5a6dd2d3acfd7ed832 |
| --- /dev/null |
| +++ b/third_party/WebKit/Source/core/css/CSSPaintImageGenerator.h |
| @@ -0,0 +1,38 @@ |
| +// Copyright 2016 The Chromium Authors. All rights reserved. |
| +// Use of this source code is governed by a BSD-style license that can be |
| +// found in the LICENSE file. |
| + |
| +#ifndef CSSPaintImageGenerator_h |
| +#define CSSPaintImageGenerator_h |
| + |
| +#include "core/CoreExport.h" |
| +#include "platform/geometry/IntSize.h" |
| +#include "platform/heap/Handle.h" |
| + |
| +namespace blink { |
| + |
| +class Document; |
| +class Image; |
| + |
| +class CORE_EXPORT CSSPaintImageGenerator : public GarbageCollectedFinalized<CSSPaintImageGenerator> { |
|
chrishtr
2016/04/06 18:55:20
Why do you need both a CSSPaintImageGenerator and
ikilpatrick
2016/04/07 23:03:00
Source/core cannot depend on Source/modules. Hence
|
| +public: |
| + class Observer { |
| + public: |
| + virtual ~Observer() { }; |
| + virtual void paintImageGeneratorReady() = 0; |
| + }; |
| + |
| + static CSSPaintImageGenerator* create(const String& name, Document&, Observer*); |
| + virtual ~CSSPaintImageGenerator(); |
| + |
| + typedef CSSPaintImageGenerator* (*CSSPaintImageGeneratorCreateFunction)(const String&, Document&, Observer*); |
| + static void init(CSSPaintImageGeneratorCreateFunction); |
| + |
| + virtual PassRefPtr<Image> paint(const IntSize&) = 0; |
| + |
| + DEFINE_INLINE_VIRTUAL_TRACE() { } |
| +}; |
| + |
| +} // namespace blink |
| + |
| +#endif // CSSPaintImageGenerator_h |