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

Unified Diff: chrome/browser/ui/webui/constrained_web_dialog_delegate_base.cc

Issue 10214001: WebDialogs (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 years, 8 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/webui/constrained_web_dialog_delegate_base.cc
===================================================================
--- chrome/browser/ui/webui/constrained_web_dialog_delegate_base.cc (revision 133680)
+++ chrome/browser/ui/webui/constrained_web_dialog_delegate_base.cc (working copy)
@@ -2,7 +2,7 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#include "chrome/browser/ui/webui/constrained_html_ui_delegate_impl.h"
+#include "chrome/browser/ui/webui/constrained_web_dialog_delegate_base.h"
#include <string>
@@ -10,18 +10,18 @@
#include "chrome/browser/profiles/profile.h"
#include "chrome/browser/ui/constrained_window.h"
#include "chrome/browser/ui/tab_contents/tab_contents_wrapper.h"
-#include "chrome/browser/ui/webui/html_dialog_tab_contents_delegate.h"
-#include "chrome/browser/ui/webui/html_dialog_ui.h"
+#include "chrome/browser/ui/webui/web_dialog_web_contents_delegate.h"
+#include "chrome/browser/ui/webui/web_dialog_ui.h"
#include "content/public/browser/web_contents.h"
using content::WebContents;
-ConstrainedHtmlUIDelegateImpl::ConstrainedHtmlUIDelegateImpl(
+ConstrainedWebDialogDelegateBase::ConstrainedWebDialogDelegateBase(
Profile* profile,
- HtmlDialogUIDelegate* delegate,
- HtmlDialogTabContentsDelegate* tab_delegate)
- : HtmlDialogTabContentsDelegate(profile),
- html_delegate_(delegate),
+ WebDialogDelegate* delegate,
+ WebDialogWebContentsDelegate* tab_delegate)
+ : WebDialogWebContentsDelegate(profile),
+ web_dialog_delegate_(delegate),
window_(NULL),
closed_via_webui_(false),
release_tab_on_close_(false) {
@@ -35,8 +35,8 @@
} else {
web_contents->SetDelegate(this);
}
- // Set |this| as a property so the ConstrainedHtmlUI can retrieve it.
- ConstrainedHtmlUI::GetPropertyAccessor().SetProperty(
+ // Set |this| as a property so the ConstrainedWebDialogUI can retrieve it.
+ ConstrainedWebDialogUI::GetPropertyAccessor().SetProperty(
web_contents->GetPropertyBag(), this);
web_contents->GetController().LoadURL(delegate->GetDialogContentURL(),
@@ -45,51 +45,51 @@
std::string());
}
-ConstrainedHtmlUIDelegateImpl::~ConstrainedHtmlUIDelegateImpl() {
+ConstrainedWebDialogDelegateBase::~ConstrainedWebDialogDelegateBase() {
if (release_tab_on_close_)
ignore_result(tab_.release());
}
-const HtmlDialogUIDelegate*
-ConstrainedHtmlUIDelegateImpl::GetHtmlDialogUIDelegate() const {
- return html_delegate_;
+const WebDialogDelegate*
+ ConstrainedWebDialogDelegateBase::GetWebDialogDelegate() const {
+ return web_dialog_delegate_;
}
-HtmlDialogUIDelegate*
-ConstrainedHtmlUIDelegateImpl::GetHtmlDialogUIDelegate() {
- return html_delegate_;
+WebDialogDelegate*
+ ConstrainedWebDialogDelegateBase::GetWebDialogDelegate() {
+ return web_dialog_delegate_;
}
-void ConstrainedHtmlUIDelegateImpl::OnDialogCloseFromWebUI() {
+void ConstrainedWebDialogDelegateBase::OnDialogCloseFromWebUI() {
closed_via_webui_ = true;
window_->CloseConstrainedWindow();
}
-void ConstrainedHtmlUIDelegateImpl::set_window(ConstrainedWindow* window) {
+void ConstrainedWebDialogDelegateBase::set_window(ConstrainedWindow* window) {
window_ = window;
}
-void ConstrainedHtmlUIDelegateImpl::set_override_tab_delegate(
- HtmlDialogTabContentsDelegate* override_tab_delegate) {
+void ConstrainedWebDialogDelegateBase::set_override_tab_delegate(
+ WebDialogWebContentsDelegate* override_tab_delegate) {
override_tab_delegate_.reset(override_tab_delegate);
}
-bool ConstrainedHtmlUIDelegateImpl::closed_via_webui() const {
+bool ConstrainedWebDialogDelegateBase::closed_via_webui() const {
return closed_via_webui_;
}
-void ConstrainedHtmlUIDelegateImpl::ReleaseTabContentsOnDialogClose() {
+void ConstrainedWebDialogDelegateBase::ReleaseTabContentsOnDialogClose() {
release_tab_on_close_ = true;
}
-ConstrainedWindow* ConstrainedHtmlUIDelegateImpl::window() {
+ConstrainedWindow* ConstrainedWebDialogDelegateBase::window() {
return window_;
}
-TabContentsWrapper* ConstrainedHtmlUIDelegateImpl::tab() {
+TabContentsWrapper* ConstrainedWebDialogDelegateBase::tab() {
return tab_.get();
}
-void ConstrainedHtmlUIDelegateImpl::HandleKeyboardEvent(
+void ConstrainedWebDialogDelegateBase::HandleKeyboardEvent(
const NativeWebKeyboardEvent& event) {
}
« no previous file with comments | « chrome/browser/ui/webui/constrained_web_dialog_delegate_base.h ('k') | chrome/browser/ui/webui/constrained_web_dialog_ui.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698