| Index: sky/engine/bindings-dart/core/dart/DartPersistentValue.h
|
| diff --git a/sky/engine/platform/LayoutTestSupport.h b/sky/engine/bindings-dart/core/dart/DartPersistentValue.h
|
| similarity index 74%
|
| copy from sky/engine/platform/LayoutTestSupport.h
|
| copy to sky/engine/bindings-dart/core/dart/DartPersistentValue.h
|
| index 72ceaf4fe1e0b3684086703f569f25eb12707959..db92b4e5a71663ec38855c178ef6964d52139f7c 100644
|
| --- a/sky/engine/platform/LayoutTestSupport.h
|
| +++ b/sky/engine/bindings-dart/core/dart/DartPersistentValue.h
|
| @@ -28,21 +28,29 @@
|
| * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
| */
|
|
|
| -#ifndef SKY_ENGINE_PLATFORM_LAYOUTTESTSUPPORT_H_
|
| -#define SKY_ENGINE_PLATFORM_LAYOUTTESTSUPPORT_H_
|
| +#ifndef DartPersistentValue_h
|
| +#define DartPersistentValue_h
|
|
|
| -#include "sky/engine/platform/PlatformExport.h"
|
| +#include "bindings/core/dart/DartIsolateDestructionObserver.h"
|
| +#include "wtf/Noncopyable.h"
|
| +#include "wtf/RefPtr.h"
|
| +#include <dart_api.h>
|
|
|
| namespace blink {
|
|
|
| -class LayoutTestSupport {
|
| +class DartPersistentValue : public DartIsolateDestructionObserver {
|
| + WTF_MAKE_NONCOPYABLE(DartPersistentValue);
|
| public:
|
| - PLATFORM_EXPORT static bool isRunningLayoutTest();
|
| - PLATFORM_EXPORT static void setIsRunningLayoutTest(bool);
|
| - PLATFORM_EXPORT static bool isFontAntialiasingEnabledForTest();
|
| - PLATFORM_EXPORT static void setFontAntialiasingEnabledForTest(bool);
|
| + explicit DartPersistentValue(Dart_Handle value);
|
| + ~DartPersistentValue();
|
| +
|
| + Dart_PersistentHandle value() const { return m_value; }
|
| + void clear();
|
| +
|
| +private:
|
| + Dart_PersistentHandle m_value;
|
| };
|
|
|
| -} // namespace blink
|
| +}
|
|
|
| -#endif // SKY_ENGINE_PLATFORM_LAYOUTTESTSUPPORT_H_
|
| +#endif // DartPersistentValue_h
|
|
|