Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

60 lines
1.6 KiB

  1. #ifndef _PDEV_H
  2. #define _PDEV_H
  3. //
  4. // Files necessary for OEM plug-in.
  5. //
  6. #ifdef __cplusplus
  7. extern "C" {
  8. #endif // cplusplus
  9. #include <minidrv.h>
  10. #include <stdio.h>
  11. #ifdef __cplusplus
  12. }
  13. #endif // cplusplus
  14. #include <prcomoem.h>
  15. //
  16. // Misc definitions follows.
  17. //
  18. ////////////////////////////////////////////////////////
  19. // OEM UD Defines
  20. ////////////////////////////////////////////////////////
  21. #define VALID_PDEVOBJ(pdevobj) \
  22. ((pdevobj) && (pdevobj)->dwSize >= sizeof(DEVOBJ) && \
  23. (pdevobj)->hEngine && (pdevobj)->hPrinter && \
  24. (pdevobj)->pPublicDM && (pdevobj)->pDrvProcs )
  25. //
  26. // ASSERT_VALID_PDEVOBJ can be used to verify the passed in "pdevobj". However,
  27. // it does NOT check "pdevOEM" and "pOEMDM" fields since not all OEM DLL's create
  28. // their own pdevice structure or need their own private devmode. If a particular
  29. // OEM DLL does need them, additional checks should be added. For example, if
  30. // an OEM DLL needs a private pdevice structure, then it should use
  31. // ASSERT(VALID_PDEVOBJ(pdevobj) && pdevobj->pdevOEM && ...)
  32. //
  33. #define ASSERT_VALID_PDEVOBJ(pdevobj) ASSERT(VALID_PDEVOBJ(pdevobj))
  34. // Debug text.
  35. //#define ERRORTEXT(s) "ERROR " DLLTEXT(s)
  36. ////////////////////////////////////////////////////////
  37. // OEM UD Prototypes
  38. ////////////////////////////////////////////////////////
  39. //
  40. // OEM Signature and version.
  41. //
  42. #define OEM_SIGNATURE 'NCDL' // NEC NPDL2 series dll
  43. #define DLLTEXT(s) "NCDL: " s
  44. #define OEM_VERSION 0x00010000L
  45. #endif // _PDEV_H