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

Side by Side Diff: chrome/browser/ui/webui/tab_modal_confirm_dialog_webui.h

Issue 10534098: TabContentsWrapper -> TabContents, part 51. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 8 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
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 CHROME_BROWSER_UI_WEBUI_TAB_MODAL_CONFIRM_DIALOG_WEBUI_H_ 5 #ifndef CHROME_BROWSER_UI_WEBUI_TAB_MODAL_CONFIRM_DIALOG_WEBUI_H_
6 #define CHROME_BROWSER_UI_WEBUI_TAB_MODAL_CONFIRM_DIALOG_WEBUI_H_ 6 #define CHROME_BROWSER_UI_WEBUI_TAB_MODAL_CONFIRM_DIALOG_WEBUI_H_
7 #pragma once 7 #pragma once
8 8
9 #if !(defined(USE_AURA) || defined(OS_CHROMEOS)) 9 #if !(defined(USE_AURA) || defined(OS_CHROMEOS))
10 #error Tab-modal confirm dialog should be shown with native UI. 10 #error Tab-modal confirm dialog should be shown with native UI.
11 #endif 11 #endif
12 12
13 #include "base/basictypes.h" 13 #include "base/basictypes.h"
14 #include "base/memory/scoped_ptr.h" 14 #include "base/memory/scoped_ptr.h"
15 #include "ui/web_dialogs/web_dialog_delegate.h" 15 #include "ui/web_dialogs/web_dialog_delegate.h"
16 16
17 class TabContents; 17 class TabContents;
18 typedef TabContents TabContentsWrapper;
19 class TabModalConfirmDialogDelegate; 18 class TabModalConfirmDialogDelegate;
20 19
21 namespace ui { 20 namespace ui {
22 class ConstrainedWebDialogDelegate; 21 class ConstrainedWebDialogDelegate;
23 } 22 }
24 23
25 // Displays a tab-modal dialog, i.e. a dialog that will block the current page 24 // Displays a tab-modal dialog, i.e. a dialog that will block the current page
26 // but still allow the user to switch to a different page. 25 // but still allow the user to switch to a different page.
27 // To display the dialog, allocate this object on the heap. It will open the 26 // To display the dialog, allocate this object on the heap. It will open the
28 // dialog from its constructor and then delete itself when the user dismisses 27 // dialog from its constructor and then delete itself when the user dismisses
29 // the dialog. 28 // the dialog.
30 class TabModalConfirmDialogWebUI : public ui::WebDialogDelegate { 29 class TabModalConfirmDialogWebUI : public ui::WebDialogDelegate {
31 public: 30 public:
32 TabModalConfirmDialogWebUI( 31 TabModalConfirmDialogWebUI(
33 TabModalConfirmDialogDelegate* dialog_delegate, 32 TabModalConfirmDialogDelegate* dialog_delegate,
34 TabContentsWrapper* wrapper); 33 TabContents* tab_contents);
35 34
36 // ui::WebDialogDelegate implementation. 35 // ui::WebDialogDelegate implementation.
37 virtual ui::ModalType GetDialogModalType() const OVERRIDE; 36 virtual ui::ModalType GetDialogModalType() const OVERRIDE;
38 virtual string16 GetDialogTitle() const OVERRIDE; 37 virtual string16 GetDialogTitle() const OVERRIDE;
39 virtual GURL GetDialogContentURL() const OVERRIDE; 38 virtual GURL GetDialogContentURL() const OVERRIDE;
40 virtual void GetWebUIMessageHandlers( 39 virtual void GetWebUIMessageHandlers(
41 std::vector<content::WebUIMessageHandler*>* handlers) const OVERRIDE; 40 std::vector<content::WebUIMessageHandler*>* handlers) const OVERRIDE;
42 virtual void GetDialogSize(gfx::Size* size) const OVERRIDE; 41 virtual void GetDialogSize(gfx::Size* size) const OVERRIDE;
43 virtual std::string GetDialogArgs() const OVERRIDE; 42 virtual std::string GetDialogArgs() const OVERRIDE;
44 virtual void OnDialogClosed(const std::string& json_retval) OVERRIDE; 43 virtual void OnDialogClosed(const std::string& json_retval) OVERRIDE;
(...skipping 10 matching lines...) Expand all
55 54
56 scoped_ptr<TabModalConfirmDialogDelegate> delegate_; 55 scoped_ptr<TabModalConfirmDialogDelegate> delegate_;
57 56
58 // Deletes itself. 57 // Deletes itself.
59 ui::ConstrainedWebDialogDelegate* constrained_web_dialog_delegate_; 58 ui::ConstrainedWebDialogDelegate* constrained_web_dialog_delegate_;
60 59
61 DISALLOW_COPY_AND_ASSIGN(TabModalConfirmDialogWebUI); 60 DISALLOW_COPY_AND_ASSIGN(TabModalConfirmDialogWebUI);
62 }; 61 };
63 62
64 #endif // CHROME_BROWSER_UI_WEBUI_TAB_MODAL_CONFIRM_DIALOG_WEBUI_H_ 63 #endif // CHROME_BROWSER_UI_WEBUI_TAB_MODAL_CONFIRM_DIALOG_WEBUI_H_
OLDNEW
« no previous file with comments | « chrome/browser/ui/webui/sync_internals_ui.cc ('k') | chrome/browser/ui/webui/tab_modal_confirm_dialog_webui.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698