Chromium Code Reviews| Index: sky/engine/public/sky/sky_view.cc |
| diff --git a/sky/engine/public/sky/sky_view.cc b/sky/engine/public/sky/sky_view.cc |
| index 694f39f921474aaa448fec199922e638ab1035b8..8b365b24623c07b98122956700f5cc52e2990df2 100644 |
| --- a/sky/engine/public/sky/sky_view.cc |
| +++ b/sky/engine/public/sky/sky_view.cc |
| @@ -5,6 +5,9 @@ |
| #include "config.h" |
| #include "sky/engine/public/sky/sky_view.h" |
| +#include "sky/engine/core/script/dart_controller.h" |
| +#include "sky/engine/platform/weborigin/KURL.h" |
| + |
| namespace blink { |
| std::unique_ptr<SkyView> SkyView::Create() { |
| @@ -15,12 +18,17 @@ SkyView::SkyView() { |
| } |
| SkyView::~SkyView() { |
| + if (dart_controller_) |
| + dart_controller_->ClearForClose(); |
|
eseidel
2015/05/19 17:20:37
Why is this separate from the destructor?
abarth-chromium
2015/05/19 17:26:49
Because it thinks its part of a Frame and can be r
|
| } |
| void SkyView::SetDisplayMetrics(const SkyDisplayMetrics& metrics) { |
| } |
| void SkyView::Load(const WebURL& url) { |
| + dart_controller_.reset(new DartController); |
| + dart_controller_->CreateIsolateFor(nullptr); |
| + dart_controller_->LoadMainLibrary(url); |
| } |
| skia::RefPtr<SkPicture> SkyView::Paint() { |