OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 #include "chrome/browser/printing/print_dialog_cloud.h" | 5 #include "chrome/browser/printing/print_dialog_cloud.h" |
6 #include "chrome/browser/printing/print_dialog_cloud_internal.h" | 6 #include "chrome/browser/printing/print_dialog_cloud_internal.h" |
7 | 7 |
8 #include "base/base64.h" | 8 #include "base/base64.h" |
9 #include "base/bind.h" | 9 #include "base/bind.h" |
10 #include "base/bind_helpers.h" | 10 #include "base/bind_helpers.h" |
(...skipping 395 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
406 PrintMsg_Print_Params default_settings; | 406 PrintMsg_Print_Params default_settings; |
407 default_settings.printable_size = gfx::Size(kWidth, kHeight); | 407 default_settings.printable_size = gfx::Size(kWidth, kHeight); |
408 default_settings.dpi = kDPI; | 408 default_settings.dpi = kDPI; |
409 default_settings.min_shrink = kMinPageShrink; | 409 default_settings.min_shrink = kMinPageShrink; |
410 default_settings.max_shrink = kMaxPageShrink; | 410 default_settings.max_shrink = kMaxPageShrink; |
411 default_settings.desired_dpi = kDPI; | 411 default_settings.desired_dpi = kDPI; |
412 default_settings.document_cookie = 0; | 412 default_settings.document_cookie = 0; |
413 default_settings.selection_only = false; | 413 default_settings.selection_only = false; |
414 default_settings.preview_request_id = 0; | 414 default_settings.preview_request_id = 0; |
415 default_settings.is_first_request = true; | 415 default_settings.is_first_request = true; |
| 416 default_settings.print_to_pdf = false; |
416 | 417 |
417 if (!GetPageSetupParameters(json, default_settings)) { | 418 if (!GetPageSetupParameters(json, default_settings)) { |
418 NOTREACHED(); | 419 NOTREACHED(); |
419 return; | 420 return; |
420 } | 421 } |
421 | 422 |
422 // TODO(scottbyer) - Here is where we would kick the originating | 423 // TODO(scottbyer) - Here is where we would kick the originating |
423 // renderer thread with these new parameters in order to get it to | 424 // renderer thread with these new parameters in order to get it to |
424 // re-generate the PDF data and hand it back to us. window.print() is | 425 // re-generate the PDF data and hand it back to us. window.print() is |
425 // currently synchronous, so there's a lot of work to do to get to | 426 // currently synchronous, so there's a lot of work to do to get to |
(...skipping 290 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
716 file_type, | 717 file_type, |
717 false, | 718 false, |
718 delete_on_close); | 719 delete_on_close); |
719 return true; | 720 return true; |
720 } | 721 } |
721 } | 722 } |
722 return false; | 723 return false; |
723 } | 724 } |
724 | 725 |
725 } // end namespace | 726 } // end namespace |
OLD | NEW |