Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(465)

Side by Side Diff: extensions/renderer/scoped_web_frame.cc

Issue 1210513002: ScriptContextSetTest should close the main frame before finishing the test (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
(Empty)
1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #include "extensions/renderer/scoped_web_frame.h"
6
7 #include "third_party/WebKit/public/web/WebHeap.h"
8
9 namespace extensions {
10
11 ScopedWebFrame::ScopedWebFrame() : view_(nullptr), frame_(nullptr) {
12 view_ = blink::WebView::create(nullptr);
13 frame_ = blink::WebLocalFrame::create(
14 blink::WebTreeScopeType::Document, nullptr);
15 view_->setMainFrame(frame_);
16 }
17
18 ScopedWebFrame::~ScopedWebFrame() {
19 view_->close();
20 frame_->close();
21 blink::WebHeap::collectAllGarbageForTesting();
22 }
23
24 } // namespace extensions
OLDNEW
« no previous file with comments | « extensions/renderer/scoped_web_frame.h ('k') | extensions/renderer/script_context_set_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698