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

Unified Diff: chrome/browser/printing/print_dialog_cloud.cc

Issue 9147040: Change cloud print dialog style in Aura (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix constants 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/printing/print_dialog_cloud.cc
diff --git a/chrome/browser/printing/print_dialog_cloud.cc b/chrome/browser/printing/print_dialog_cloud.cc
index daf1213cd8e18e85a72adf877a03a795178f9069..1ceb5ef017d3161b19b4575d622405f552df2f60 100644
--- a/chrome/browser/printing/print_dialog_cloud.cc
+++ b/chrome/browser/printing/print_dialog_cloud.cc
@@ -42,6 +42,12 @@
#include "grit/generated_resources.h"
+#if defined(USE_AURA)
+#include "chrome/browser/ui/browser_window.h"
+#include "chrome/browser/ui/views/html_dialog_view.h"
+#include "ui/views/widget/widget.h"
+#endif
+
// This module implements the UI support in Chrome for cloud printing.
// This means hosting a dialog containing HTML/JavaScript and using
// the published cloud print user interface integration APIs to get
@@ -640,7 +646,16 @@ void CreateDialogImpl(const FilePath& path_to_file,
file_type, modal, delete_on_close);
if (modal) {
DCHECK(browser);
+#if defined(USE_AURA)
+ HtmlDialogView* html_view =
+ new HtmlDialogView(profile, dialog_delegate);
+ views::Widget::CreateWindowWithParent(html_view,
+ browser->window()->GetNativeHandle());
+ html_view->InitDialog();
+ html_view->GetWidget()->Show();
+#else
browser->BrowserShowHtmlDialog(dialog_delegate, NULL, STYLE_GENERIC);
+#endif
} else {
browser::ShowHtmlDialog(NULL, profile, dialog_delegate, STYLE_GENERIC);
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698