mirror of
git://git.code.sf.net/p/cdesktopenv/code
synced 2025-02-15 04:32:24 +00:00
dtpad: stub out XmPrint stuff if there is no XmPrint support.
This commit is contained in:
parent
362a921245
commit
c39212f684
1 changed files with 16 additions and 0 deletions
|
@ -374,6 +374,8 @@ _pjCreatePrintShell(PrintJob *pJob)
|
||||||
pJob->parentShell == NULL ||
|
pJob->parentShell == NULL ||
|
||||||
pJob->pSetup == NULL) return;
|
pJob->pSetup == NULL) return;
|
||||||
|
|
||||||
|
#if defined(PRINTING_SUPPORTED)
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Create the print shell and
|
* Create the print shell and
|
||||||
* the print output widgets
|
* the print output widgets
|
||||||
|
@ -440,6 +442,8 @@ _pjCreatePrintShell(PrintJob *pJob)
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
if (pJob->pShell == NULL) return;
|
if (pJob->pShell == NULL) return;
|
||||||
|
#endif /* PRINTING_SUPPORTED */
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -585,6 +589,8 @@ _pjCreateOutputWidgets(PrintJob *pJob)
|
||||||
static void
|
static void
|
||||||
_pjDoPrint(PrintJob *pJob)
|
_pjDoPrint(PrintJob *pJob)
|
||||||
{
|
{
|
||||||
|
#if defined(PRINTING_SUPPORTED)
|
||||||
|
|
||||||
static char buf[1024];
|
static char buf[1024];
|
||||||
static char *format;
|
static char *format;
|
||||||
DtPrintSetupData *psd = NULL;
|
DtPrintSetupData *psd = NULL;
|
||||||
|
@ -651,6 +657,9 @@ _pjDoPrint(PrintJob *pJob)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
#endif /* PRINTING_SUPPORTED */
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/************************************************************************
|
/************************************************************************
|
||||||
|
@ -878,6 +887,7 @@ _pjPrintCB (Widget widget, XtPointer client_data, XtPointer call_data)
|
||||||
static void
|
static void
|
||||||
_pjPdmSetupCB(Widget print_setup, XtPointer client_data, XtPointer call_data)
|
_pjPdmSetupCB(Widget print_setup, XtPointer client_data, XtPointer call_data)
|
||||||
{
|
{
|
||||||
|
#if defined(PRINTING_SUPPORTED)
|
||||||
char *pname = "_pjPdmSetupCB";
|
char *pname = "_pjPdmSetupCB";
|
||||||
PrintJob *pJob = (PrintJob *) client_data;
|
PrintJob *pJob = (PrintJob *) client_data;
|
||||||
DtPrintSetupCallbackStruct
|
DtPrintSetupCallbackStruct
|
||||||
|
@ -899,6 +909,7 @@ _pjPdmSetupCB(Widget print_setup, XtPointer client_data, XtPointer call_data)
|
||||||
else
|
else
|
||||||
fprintf(stderr, "Internal Error %s: Missing XmPrintShell.", pname);
|
fprintf(stderr, "Internal Error %s: Missing XmPrintShell.", pname);
|
||||||
}
|
}
|
||||||
|
#endif /* PRINTING_SUPPORTED */
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -909,6 +920,7 @@ _pjPdmSetupCB(Widget print_setup, XtPointer client_data, XtPointer call_data)
|
||||||
static void
|
static void
|
||||||
_pjPdmNotificationCB (Widget widget, XtPointer client_data, XtPointer call_data)
|
_pjPdmNotificationCB (Widget widget, XtPointer client_data, XtPointer call_data)
|
||||||
{
|
{
|
||||||
|
#if defined(PRINTING_SUPPORTED)
|
||||||
PrintJob *pJob = (PrintJob*) client_data;
|
PrintJob *pJob = (PrintJob*) client_data;
|
||||||
XmPrintShellCallbackStruct *pscbs = (XmPrintShellCallbackStruct*)call_data;
|
XmPrintShellCallbackStruct *pscbs = (XmPrintShellCallbackStruct*)call_data;
|
||||||
char *message = NULL;
|
char *message = NULL;
|
||||||
|
@ -931,6 +943,7 @@ _pjPdmNotificationCB (Widget widget, XtPointer client_data, XtPointer call_data)
|
||||||
|
|
||||||
if (message != NULL)
|
if (message != NULL)
|
||||||
Warning( pJob->pPad, message, XmDIALOG_WARNING);
|
Warning( pJob->pPad, message, XmDIALOG_WARNING);
|
||||||
|
#endif /* PRINTING_SUPPORTED */
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -946,6 +959,7 @@ _pjPrintOnePageCB(
|
||||||
XtPointer call_data
|
XtPointer call_data
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
|
#if defined(PRINTING_SUPPORTED)
|
||||||
PrintJob *pJob = (PrintJob *) client_data;
|
PrintJob *pJob = (PrintJob *) client_data;
|
||||||
|
|
||||||
XmPrintShellCallbackStruct *pscbs = (XmPrintShellCallbackStruct*)call_data;
|
XmPrintShellCallbackStruct *pscbs = (XmPrintShellCallbackStruct*)call_data;
|
||||||
|
@ -1049,4 +1063,6 @@ _pjPrintOnePageCB(
|
||||||
if (pJob->npagesDone >= pJob->npagesTotal)
|
if (pJob->npagesDone >= pJob->npagesTotal)
|
||||||
pscbs->last_page = TRUE;
|
pscbs->last_page = TRUE;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#endif /* PRINTING_SUPPORTED */
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue