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

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

Issue 1543053002: Switch to standard integer types in extensions/. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@int-extensions-browser
Patch Set: Created 5 years 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
« no previous file with comments | « extensions/renderer/runtime_custom_bindings.cc ('k') | extensions/renderer/script_context.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 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 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef SCOPED_WEB_FRAME_H_ 5 #ifndef SCOPED_WEB_FRAME_H_
6 #define SCOPED_WEB_FRAME_H_ 6 #define SCOPED_WEB_FRAME_H_
7 7
8 #include "base/macros.h"
8 #include "third_party/WebKit/public/web/WebLocalFrame.h" 9 #include "third_party/WebKit/public/web/WebLocalFrame.h"
9 #include "third_party/WebKit/public/web/WebView.h" 10 #include "third_party/WebKit/public/web/WebView.h"
10 11
11 namespace extensions { 12 namespace extensions {
12 13
13 // ScopedWebFrame is a class to create a dummy webview and frame for testing. 14 // ScopedWebFrame is a class to create a dummy webview and frame for testing.
14 // The dymmy webview and frame will be destructed when the scope exits. 15 // The dymmy webview and frame will be destructed when the scope exits.
15 class ScopedWebFrame { 16 class ScopedWebFrame {
16 public: 17 public:
17 ScopedWebFrame(); 18 ScopedWebFrame();
18 ~ScopedWebFrame(); 19 ~ScopedWebFrame();
19 20
20 blink::WebLocalFrame* frame() { return frame_; } 21 blink::WebLocalFrame* frame() { return frame_; }
21 22
22 private: 23 private:
23 // The webview and the frame are kept alive by the ScopedWebFrame 24 // The webview and the frame are kept alive by the ScopedWebFrame
24 // because they are not destructed unless ~ScopedWebFrame explicitly 25 // because they are not destructed unless ~ScopedWebFrame explicitly
25 // closes the webview and the frame. 26 // closes the webview and the frame.
26 blink::WebView* view_; 27 blink::WebView* view_;
27 blink::WebLocalFrame* frame_; 28 blink::WebLocalFrame* frame_;
28 DISALLOW_COPY_AND_ASSIGN(ScopedWebFrame); 29 DISALLOW_COPY_AND_ASSIGN(ScopedWebFrame);
29 }; 30 };
30 31
31 } // namespace extensions 32 } // namespace extensions
32 33
33 #endif // SCOPED_WEB_FRAME_H_ 34 #endif // SCOPED_WEB_FRAME_H_
OLDNEW
« no previous file with comments | « extensions/renderer/runtime_custom_bindings.cc ('k') | extensions/renderer/script_context.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698