home *** CD-ROM | disk | FTP | other *** search
/ Tools / WinSN5.0Ver.iso / NETSCAP.50 / WIN1998.ZIP / ns / xpcom / src / nsCom.h < prev    next >
Encoding:
C/C++ Source or Header  |  1998-04-08  |  1.7 KB  |  66 lines

  1. /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
  2. /*
  3.  * The contents of this file are subject to the Netscape Public License
  4.  * Version 1.0 (the "NPL"); you may not use this file except in
  5.  * compliance with the NPL.  You may obtain a copy of the NPL at
  6.  * http://www.mozilla.org/NPL/
  7.  *
  8.  * Software distributed under the NPL is distributed on an "AS IS" basis,
  9.  * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the NPL
  10.  * for the specific language governing rights and limitations under the
  11.  * NPL.
  12.  *
  13.  * The Initial Developer of this code under the NPL is Netscape
  14.  * Communications Corporation.  Portions created by Netscape are
  15.  * Copyright (C) 1998 Netscape Communications Corporation.  All Rights
  16.  * Reserved.
  17.  */
  18.  
  19. #ifndef nsCom_h__
  20. #define nsCom_h__
  21.  
  22. /*
  23.  * API Import/Export macros
  24.  */
  25.  
  26. #ifdef _IMPL_NS_COM
  27. #  ifdef XP_PC
  28. #    define NS_COM _declspec(dllexport)
  29. #  else  // !XP_PC
  30. #    define NS_COM
  31. #  endif // !XP_PC
  32. #else  // !_IMPL_NS_COM
  33. #  ifdef XP_PC
  34. #    define NS_COM _declspec(dllimport)
  35. #  else  // !XP_PC
  36. #    define NS_COM
  37. #  endif // !XP_PC
  38. #endif // !_IMPL_NS_COM
  39.  
  40. /*
  41.  * DLL Export macro
  42.  */
  43.  
  44. #ifndef NS_EXPORT
  45. #  ifdef XP_PC
  46. #    define NS_EXPORT           _declspec(dllexport)
  47. #  else  // !XP_PC
  48. #    define NS_EXPORT
  49. #  endif // !XP_PC
  50. #endif // !NS_EXPORT
  51.  
  52. #ifdef XP_PC
  53. #  define NS_METHOD_(Type)      Type __stdcall
  54. #  define NS_METHOD             nsresult __stdcall
  55. #else  // !XP_PC
  56. #  define NS_METHOD_(Type)      Type
  57. #  define NS_METHOD             nsresult
  58. #endif // !XP_PC
  59.  
  60. #define NS_IMETHOD_(Type)       virtual NS_METHOD_(Type)
  61. #define NS_IMETHOD              virtual NS_METHOD
  62.  
  63. #endif
  64.  
  65.  
  66.