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

Side by Side Diff: components/html_viewer/html_widget.h

Issue 1362983004: Mandoline: fix the crash when a remote subframe tries to access session storage. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 3 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
« no previous file with comments | « no previous file | components/html_viewer/html_widget.cc » ('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 COMPONENTS_HTML_VIEWER_HTML_WIDGET_H_ 5 #ifndef COMPONENTS_HTML_VIEWER_HTML_WIDGET_H_
6 #define COMPONENTS_HTML_VIEWER_HTML_WIDGET_H_ 6 #define COMPONENTS_HTML_VIEWER_HTML_WIDGET_H_
7 7
8 #include "third_party/WebKit/public/web/WebViewClient.h" 8 #include "third_party/WebKit/public/web/WebViewClient.h"
9 #include "third_party/WebKit/public/web/WebWidgetClient.h" 9 #include "third_party/WebKit/public/web/WebWidgetClient.h"
10 10
(...skipping 20 matching lines...) Expand all
31 class HTMLWidget { 31 class HTMLWidget {
32 public: 32 public:
33 virtual ~HTMLWidget() {} 33 virtual ~HTMLWidget() {}
34 34
35 virtual blink::WebWidget* GetWidget() = 0; 35 virtual blink::WebWidget* GetWidget() = 0;
36 36
37 virtual void OnViewBoundsChanged(mus::View* view) = 0; 37 virtual void OnViewBoundsChanged(mus::View* view) = 0;
38 }; 38 };
39 39
40 // Used for the root frame when the root frame is remote. 40 // Used for the root frame when the root frame is remote.
41 class HTMLWidgetRootRemote : public HTMLWidget { 41 class HTMLWidgetRootRemote : public HTMLWidget, public blink::WebViewClient {
42 public: 42 public:
43 HTMLWidgetRootRemote(); 43 HTMLWidgetRootRemote();
44 ~HTMLWidgetRootRemote() override; 44 ~HTMLWidgetRootRemote() override;
45 45
46 private: 46 private:
47 // WebViewClient methods:
48 virtual blink::WebStorageNamespace* createSessionStorageNamespace();
49 virtual bool allowsBrokenNullLayerTreeView() const;
50
47 // HTMLWidget: 51 // HTMLWidget:
48 blink::WebWidget* GetWidget() override; 52 blink::WebWidget* GetWidget() override;
49 void OnViewBoundsChanged(mus::View* view) override; 53 void OnViewBoundsChanged(mus::View* view) override;
50 54
51 blink::WebView* web_view_; 55 blink::WebView* web_view_;
52 56
53 DISALLOW_COPY_AND_ASSIGN(HTMLWidgetRootRemote); 57 DISALLOW_COPY_AND_ASSIGN(HTMLWidgetRootRemote);
54 }; 58 };
55 59
56 // Used for the root frame when the frame is local. If there is only one 60 // Used for the root frame when the frame is local. If there is only one
(...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after
128 blink::WebFrameWidget* web_frame_widget_; 132 blink::WebFrameWidget* web_frame_widget_;
129 scoped_ptr<WebLayerTreeViewImpl> web_layer_tree_view_impl_; 133 scoped_ptr<WebLayerTreeViewImpl> web_layer_tree_view_impl_;
130 scoped_ptr<ImeController> ime_controller_; 134 scoped_ptr<ImeController> ime_controller_;
131 135
132 DISALLOW_COPY_AND_ASSIGN(HTMLWidgetLocalRoot); 136 DISALLOW_COPY_AND_ASSIGN(HTMLWidgetLocalRoot);
133 }; 137 };
134 138
135 } // namespace html_viewer 139 } // namespace html_viewer
136 140
137 #endif // COMPONENTS_HTML_VIEWER_HTML_WIDGET_H_ 141 #endif // COMPONENTS_HTML_VIEWER_HTML_WIDGET_H_
OLDNEW
« no previous file with comments | « no previous file | components/html_viewer/html_widget.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698