~ubuntu-branches/ubuntu/raring/hplip/raring

« back to all changes in this revision

Viewing changes to prnt/hpijs/dj9xxvip.cpp

  • Committer: Bazaar Package Importer
  • Author(s): Mark Purcell
  • Date: 2009-12-28 16:36:32 UTC
  • mfrom: (9.1.1 sid)
  • Revision ID: james.westby@ubuntu.com-20091228163632-1o41x9uqye26ml5x
Tags: 3.9.12-2
* NEW package libhpmud0 - splits hard dependency between hpijs & hplip 
  - Fix "hpijs linked against libhpmud.so.0 in hplip package - brings
  large (14Mb) depends" (Closes: #454117)
  - Fix "automatically got a systray app which I don't need" (Closes: #484801)
  - Fix "depends (via hplip) on cups, to no purpose" (Closes: #561134)
* Soften bug/presubj. Fixes "requiring authentication" (Closes: #494420)
* dh_desktop-is-deprecated - removed
* dh_python obsolete as dh_pysupport exists
* Add debian/README.source - fixes patch-system-but-no-source-readme
  - Upgrade to Standards-Version: 3.8.3 

Show diffs side-by-side

added added

removed removed

Lines of Context:
96
96
    pMode[ModeCount++] = new DJ990BestMode ();         // Photo Best
97
97
    pMode[ModeCount++] = new DJ990PhotoNormalMode ();  // Photo Normal
98
98
 
99
 
    m_cExtraDryTime = 0;
 
99
    m_cExtraDryTime    = 0;
 
100
    m_iLeftOverspray   = 0;
 
101
    m_iTopOverspray    = 0;
 
102
    m_iRightOverspray  = 0;
 
103
    m_iBottomOverspray = 0;
100
104
}
101
105
 
102
106
GrayModeDJ990::GrayModeDJ990
328
332
        */ 
329
333
} //UseGUIMode
330
334
 
 
335
DRIVER_ERROR DJ9xxVIP::AddPJLHeader ()
 
336
{
 
337
    char            *szPJLBuffer = NULL;
 
338
    DRIVER_ERROR    err = NO_ERROR;
 
339
    int             iPJLBufferSize;
 
340
    if (((iPJLBufferSize = pSS->GetPJLHeaderBuffer (&szPJLBuffer)) > 0) && (szPJLBuffer != NULL))
 
341
    {
 
342
        err = Send ((const BYTE *) szPJLBuffer, iPJLBufferSize);
 
343
    }
 
344
    return err;
 
345
}
331
346
 
332
347
Mode10::Mode10
333
348
(
502
517
 
503
518
    thePrintContext->GetPrintModeSettings (eQualityMode, eMediaType, eColorMode, bDeviceText);
504
519
 
505
 
#ifdef APDK_EXTENDED_MEDIASIZE
506
 
/*
507
 
 *  A different media type may have been set via ppd that is different than
508
 
 *  what is initialized in the PrintMode constructor, for example, eMediaType
509
 
 *  set to 2, which maps to PCL mediatype of 3, rather than PCL mediatype 5
510
 
 *  for 1200 dpi mode for Officejet Pro K5400. Here, set the media type based
511
 
 *  on what was selected from ppd.
512
 
 */
513
 
 
514
 
    SetMediaType (MediaTypeToPcl (eMediaType));
515
 
#endif
516
 
 
517
520
    if (eMediaType == MEDIA_CDDVD)
518
521
    {
519
522
        thePrintContext->SetMediaSource (sourceTrayCDDVD);
685
688
 
686
689
    err = thePrinter->Send((const BYTE*)UEL,sizeof(UEL));
687
690
    ERRCHECK;
688
 
 
 
691
 
 
692
    err = thePrinter->AddPJLHeader ();
 
693
    ERRCHECK;
 
694
 
689
695
    err = thePrinter->Send((const BYTE*)EnterLanguage,sizeof(EnterLanguage));
690
696
    ERRCHECK;
691
697
 
705
711
 
706
712
    err = Modes ();            // Set media source, type, size and quality modes.
707
713
    ERRCHECK;
 
714
 
 
715
//  Send media subtype if set
 
716
    int    iMediaSubtype = thePrintContext->GetMediaSubtype ();
 
717
    if (iMediaSubtype != APDK_INVALID_VALUE)
 
718
    {
 
719
        BYTE    szMediaSubtypeSeq[] = {0x1B, '*', 'o', '5', 'W', 0x0D, 0x03, 0x00, 0x00, 0x00};
 
720
        szMediaSubtypeSeq[8] = (BYTE) ((iMediaSubtype & 0xFF00) >> 8);
 
721
        szMediaSubtypeSeq[9] = (BYTE) (iMediaSubtype & 0x00FF);
 
722
        err = thePrinter->Send ((const BYTE *) szMediaSubtypeSeq, sizeof(szMediaSubtypeSeq));
 
723
        ERRCHECK;
 
724
    }
708
725
 
709
726
    if (!thePrinter->UseGUIMode(thePrintContext->CurrentMode))
710
727
    {