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.

65 lines
2.2 KiB

  1. /*
  2. * htmlstr.h
  3. *
  4. * HTML string constants
  5. *
  6. */
  7. #ifndef _HTMLSTR_H
  8. #define _HTMLSTR_H
  9. #if !defined( WIN16 ) || !defined( __WATCOMC__ )
  10. #ifdef DEFINE_STRING_CONSTANTS
  11. #define MAKEBSTR(name, count, strdata) \
  12. extern "C" CDECL const WORD DATA_##name [] = {(count * sizeof(OLECHAR)), 0x00, L##strdata}; \
  13. extern "C" CDECL BSTR name = (BSTR)& DATA_##name[2];
  14. #define STR_GLOBAL(x,y) extern "C" CDECL const TCHAR x[] = TEXT(y)
  15. #define STR_GLOBAL_ANSI(x,y) extern "C" CDECL const char x[] = y
  16. #define STR_GLOBAL_WIDE(x,y) extern "C" CDECL const WCHAR x[] = L##y
  17. #else
  18. #define MAKEBSTR(name, count, strdata) extern "C" CDECL LPCWSTR name
  19. #define STR_GLOBAL(x,y) extern "C" CDECL const TCHAR x[]
  20. #define STR_GLOBAL_ANSI(x,y) extern "C" CDECL const char x[]
  21. #define STR_GLOBAL_WIDE(x,y) extern "C" CDECL const WCHAR x[]
  22. #endif
  23. #else // !WIN16 || !__WATCOMC__
  24. #ifdef DEFINE_STRING_CONSTANTS
  25. #define MAKEBSTR(name, count, strdata) \
  26. extern "C" const char CDECL DATA_##name [] = {(count * sizeof(OLECHAR)), 0x00, strdata}; \
  27. extern "C" BSTR CDECL name = (BSTR)& DATA_##name[2];
  28. #define STR_GLOBAL(x,y) extern "C" const TCHAR CDECL x[] = TEXT(y)
  29. #define STR_GLOBAL_ANSI(x,y) extern "C" const char CDECL x[] = y
  30. #define STR_GLOBAL_WIDE(x,y) extern "C" const WCHAR CDECL x[] = y
  31. #else
  32. #define MAKEBSTR(name, count, strdata) extern "C" LPCWSTR CDECL name
  33. #define STR_GLOBAL(x,y) extern "C" const TCHAR CDECL x[]
  34. #define STR_GLOBAL_ANSI(x,y) extern "C" const char CDECL x[]
  35. #define STR_GLOBAL_WIDE(x,y) extern "C" const WCHAR CDECL x[]
  36. #endif
  37. #endif // !WIN16 || !__WATCOMC__
  38. STR_GLOBAL(c_szHtml_MetaTagf, "<META HTTP-EQUIV=\"Content-Type\" CONTENT=\"text/html;charset=%s\">\r\n");
  39. MAKEBSTR(c_bstr_Word, 4, "Word");
  40. MAKEBSTR(c_bstr_Character, 9, "Character");
  41. MAKEBSTR(c_bstr_StartToEnd, 10, "StartToEnd");
  42. MAKEBSTR(c_bstr_EndToEnd, 8, "EndToEnd");
  43. MAKEBSTR(c_bstr_StartToStart, 12, "StartToStart");
  44. MAKEBSTR(c_bstr_EndToStart, 10, "EndToStart");
  45. MAKEBSTR(c_bstr_OnNewMail, 9, "onNewMail");
  46. MAKEBSTR(c_bstr_OnAccountChange, 15, "onAccountChange");
  47. #endif //_HTMLSTR_H