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

Side by Side Diff: content/browser/javascript_dialog_delegate.h

Issue 7096016: Remove JS dialog dependency from content. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: one more DEPS item removal Created 9 years, 6 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
(Empty)
1 // Copyright (c) 2011 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 #ifndef CONTENT_BROWSER_JAVASCRIPT_DIALOG_DELEGATE_H_
6 #define CONTENT_BROWSER_JAVASCRIPT_DIALOG_DELEGATE_H_
7 #pragma once
8
9 #include "ui/gfx/native_widget_types.h"
10
11 class ExtensionHost;
12 class TabContents;
13
14 namespace IPC {
15 class Message;
16 }
17
18 namespace content {
19
20 class JavaScriptDialogDelegate {
21 public:
22 // This callback is invoked when the dialog is closed.
23 virtual void OnDialogClosed(IPC::Message* reply_msg,
24 bool success,
25 const string16& user_input) = 0;
26
27 // Returns the root native window with which to associate the dialog.
28 virtual gfx::NativeWindow GetDialogRootWindow() = 0;
29
30 // Returns the TabContents implementing this delegate, or NULL if there is
31 // none. TODO(avi): This breaks encapsulation and in general sucks; figure out
32 // a better way of doing this.
33 virtual TabContents* AsTabContents() = 0;
34
35 // Returns the ExtensionHost implementing this delegate, or NULL if there is
36 // none. TODO(avi): This is even suckier than AsTabContents above as it breaks
37 // layering; figure out a better way of doing this. http://crbug.com/84604
38 virtual ExtensionHost* AsExtensionHost() = 0;
39
40 protected:
41 virtual ~JavaScriptDialogDelegate() {}
42 };
43
44 } // namespace content
45
46 #endif // CONTENT_BROWSER_JAVASCRIPT_DIALOG_DELEGATE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698