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

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

Issue 8528053: Print Preview: Making margin selection sticky (part 2/2, again) (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fixing Created 9 years, 1 month 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/printing/print_preview_message_handler.cc
diff --git a/chrome/browser/printing/print_preview_message_handler.cc b/chrome/browser/printing/print_preview_message_handler.cc
index 802db6a6077d81f60c954982ab6f38f7207d6b2a..b4037fc4b1f175481ce7407ca590d06e98d983c7 100644
--- a/chrome/browser/printing/print_preview_message_handler.cc
+++ b/chrome/browser/printing/print_preview_message_handler.cc
@@ -99,8 +99,16 @@ PrintPreviewUI* PrintPreviewMessageHandler::OnFailure(int document_cookie) {
return static_cast<PrintPreviewUI*>(print_preview_tab->web_ui());
}
-void PrintPreviewMessageHandler::OnRequestPrintPreview() {
+void PrintPreviewMessageHandler::OnRequestPrintPreview(
+ bool source_is_modifiable) {
PrintPreviewTabController::PrintPreview(tab_contents_wrapper());
+
+ TabContentsWrapper* print_preview_tab = GetPrintPreviewTab();
+ if (!print_preview_tab || !print_preview_tab->web_ui())
+ return;
+ PrintPreviewUI* print_preview_ui =
+ static_cast<PrintPreviewUI*>(print_preview_tab->web_ui());
+ print_preview_ui->SetSourceIsModifiable(source_is_modifiable);
}
void PrintPreviewMessageHandler::OnDidGetPreviewPageCount(
« no previous file with comments | « chrome/browser/printing/print_preview_message_handler.h ('k') | chrome/browser/printing/print_system_task_proxy.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698