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

Unified Diff: chrome/browser/ui/gtk/html_dialog_gtk.cc

Issue 9225053: Add a blocking version of the sync promo dialog (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 8 years, 11 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/gtk/html_dialog_gtk.cc
diff --git a/chrome/browser/ui/gtk/html_dialog_gtk.cc b/chrome/browser/ui/gtk/html_dialog_gtk.cc
index 7c47641f630f7571e1c19391b852a4efbba76780..0153503a2215b5632a115f4e73aa225f4b132ae4 100644
--- a/chrome/browser/ui/gtk/html_dialog_gtk.cc
+++ b/chrome/browser/ui/gtk/html_dialog_gtk.cc
@@ -38,6 +38,10 @@ gfx::NativeWindow ShowHtmlDialog(gfx::NativeWindow parent,
return html_dialog->InitDialog();
}
+void CloseHtmlDialog(gfx::NativeWindow window) {
+ gtk_widget_destroy(window);
+}
+
} // namespace browser
namespace {
@@ -151,6 +155,30 @@ void HtmlDialogGtk::CloseContents(WebContents* source) {
OnDialogClosed(std::string());
}
+content::WebContents* HtmlDialogGtk::OpenURLFromTab(
+ content::WebContents* source,
+ const content::OpenURLParams& params) {
+ content::WebContents* new_contents = NULL;
+ if (delegate_ &&
+ delegate_->HandleOpenURLFromTab(source, params, &new_contents)) {
+ return new_contents;
+ }
+ return HtmlDialogTabContentsDelegate::OpenURLFromTab(source, params);
+}
+
+void HtmlDialogGtk::AddNewContents(content::WebContents* source,
+ content::WebContents* new_contents,
+ WindowOpenDisposition disposition,
+ const gfx::Rect& initial_pos,
+ bool user_gesture) {
+ if (delegate_ && delegate_->HandlerAddNewContents(
+ source, new_contents, disposition, initial_pos, user_gesture)) {
+ return;
+ }
+ HtmlDialogTabContentsDelegate::AddNewContents(
+ source, new_contents, disposition, initial_pos, user_gesture);
+}
+
bool HtmlDialogGtk::ShouldShowDialogTitle() const {
return true;
}

Powered by Google App Engine
This is Rietveld 408576698