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

Side by Side Diff: ui/views/controls/webview/web_dialog_view.h

Issue 10868116: Pass result of blockage across content API when new tab blocked. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 UI_VIEWS_CONTROLS_WEBVIEW_WEB_DIALOG_VIEW_H_ 5 #ifndef UI_VIEWS_CONTROLS_WEBVIEW_WEB_DIALOG_VIEW_H_
6 #define UI_VIEWS_CONTROLS_WEBVIEW_WEB_DIALOG_VIEW_H_ 6 #define UI_VIEWS_CONTROLS_WEBVIEW_WEB_DIALOG_VIEW_H_
7 7
8 #include <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after
99 content::WebContents* source, 99 content::WebContents* source,
100 const content::NativeWebKeyboardEvent& event) OVERRIDE; 100 const content::NativeWebKeyboardEvent& event) OVERRIDE;
101 virtual void CloseContents(content::WebContents* source) OVERRIDE; 101 virtual void CloseContents(content::WebContents* source) OVERRIDE;
102 virtual content::WebContents* OpenURLFromTab( 102 virtual content::WebContents* OpenURLFromTab(
103 content::WebContents* source, 103 content::WebContents* source,
104 const content::OpenURLParams& params) OVERRIDE; 104 const content::OpenURLParams& params) OVERRIDE;
105 virtual void AddNewContents(content::WebContents* source, 105 virtual void AddNewContents(content::WebContents* source,
106 content::WebContents* new_contents, 106 content::WebContents* new_contents,
107 WindowOpenDisposition disposition, 107 WindowOpenDisposition disposition,
108 const gfx::Rect& initial_pos, 108 const gfx::Rect& initial_pos,
109 bool user_gesture) OVERRIDE; 109 bool user_gesture,
110 bool* was_blocked) OVERRIDE;
110 virtual void LoadingStateChanged(content::WebContents* source) OVERRIDE; 111 virtual void LoadingStateChanged(content::WebContents* source) OVERRIDE;
111 112
112 private: 113 private:
113 FRIEND_TEST_ALL_PREFIXES(WebDialogBrowserTest, WebContentRendered); 114 FRIEND_TEST_ALL_PREFIXES(WebDialogBrowserTest, WebContentRendered);
114 115
115 // Initializes the contents of the dialog. 116 // Initializes the contents of the dialog.
116 void InitDialog(); 117 void InitDialog();
117 118
118 // Whether the view is initialized. That is, dialog accelerators is registered 119 // Whether the view is initialized. That is, dialog accelerators is registered
119 // and FreezeUpdates property is set to prevent WM from showing the window 120 // and FreezeUpdates property is set to prevent WM from showing the window
120 // until the property is removed. 121 // until the property is removed.
121 bool initialized_; 122 bool initialized_;
122 123
123 // This view is a delegate to the HTML content since it needs to get notified 124 // This view is a delegate to the HTML content since it needs to get notified
124 // about when the dialog is closing. For all other actions (besides dialog 125 // about when the dialog is closing. For all other actions (besides dialog
125 // closing) we delegate to the creator of this view, which we keep track of 126 // closing) we delegate to the creator of this view, which we keep track of
126 // using this variable. 127 // using this variable.
127 ui::WebDialogDelegate* delegate_; 128 ui::WebDialogDelegate* delegate_;
128 129
129 views::WebView* web_view_; 130 views::WebView* web_view_;
130 131
131 DISALLOW_COPY_AND_ASSIGN(WebDialogView); 132 DISALLOW_COPY_AND_ASSIGN(WebDialogView);
132 }; 133 };
133 134
134 } // namespace views 135 } // namespace views
135 136
136 #endif // UI_VIEWS_CONTROLS_WEBVIEW_WEB_DIALOG_VIEW_H_ 137 #endif // UI_VIEWS_CONTROLS_WEBVIEW_WEB_DIALOG_VIEW_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698