diff options
author | avi@chromium.org <avi@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-04-27 16:28:40 +0000 |
---|---|---|
committer | avi@chromium.org <avi@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-04-27 16:28:40 +0000 |
commit | 238049450762af7812c709f14c623a6419f8cf81 (patch) | |
tree | fee036234ff29737a2eb41c5abc1cfb51c72957c /printing | |
parent | ad6b3cd72b40bc04276170127215f0fc104ac77e (diff) | |
download | chromium_src-238049450762af7812c709f14c623a6419f8cf81.zip chromium_src-238049450762af7812c709f14c623a6419f8cf81.tar.gz chromium_src-238049450762af7812c709f14c623a6419f8cf81.tar.bz2 |
Set the job title of print jobs.
BUG=http://crbug.com/29188
TEST=as in bug
Review URL: http://codereview.chromium.org/1756014
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@45704 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'printing')
-rw-r--r-- | printing/printing_context_mac.mm | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/printing/printing_context_mac.mm b/printing/printing_context_mac.mm index acc9c28..c4f09b0 100644 --- a/printing/printing_context_mac.mm +++ b/printing/printing_context_mac.mm @@ -8,6 +8,7 @@ #import <AppKit/AppKit.h> #include "base/logging.h" +#include "base/sys_string_conversions.h" namespace printing { @@ -122,6 +123,11 @@ PrintingContext::Result PrintingContext::NewDocument( static_cast<PMPrintSettings>([print_info_ PMPrintSettings]); PMPageFormat page_format = static_cast<PMPageFormat>([print_info_ PMPageFormat]); + + scoped_cftyperef<CFStringRef> job_title( + base::SysWideToCFStringRef(document_name)); + PMPrintSettingsSetJobName(print_settings, job_title.get()); + OSStatus status = PMSessionBeginCGDocumentNoDialog(print_session, print_settings, page_format); |