icon.h 2.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374
  1. /////////////////////////////////////////////////////////////////////////////
  2. // Name: wx/icon.h
  3. // Purpose: wxIcon base header
  4. // Author: Julian Smart
  5. // Modified by:
  6. // Created:
  7. // Copyright: (c) Julian Smart
  8. // Licence: wxWindows licence
  9. /////////////////////////////////////////////////////////////////////////////
  10. #ifndef _WX_ICON_H_BASE_
  11. #define _WX_ICON_H_BASE_
  12. #include "wx/iconloc.h"
  13. // a more readable way to tell
  14. #define wxICON_SCREEN_DEPTH (-1)
  15. // the wxICON_DEFAULT_TYPE (the wxIcon equivalent of wxBITMAP_DEFAULT_TYPE)
  16. // constant defines the default argument value for wxIcon ctor and wxIcon::LoadFile()
  17. // functions.
  18. #if defined(__WXMSW__)
  19. #define wxICON_DEFAULT_TYPE wxBITMAP_TYPE_ICO_RESOURCE
  20. #include "wx/msw/icon.h"
  21. #elif defined(__WXMOTIF__)
  22. #define wxICON_DEFAULT_TYPE wxBITMAP_TYPE_XPM
  23. #include "wx/motif/icon.h"
  24. #elif defined(__WXGTK20__)
  25. #ifdef __WINDOWS__
  26. #define wxICON_DEFAULT_TYPE wxBITMAP_TYPE_ICO_RESOURCE
  27. #else
  28. #define wxICON_DEFAULT_TYPE wxBITMAP_TYPE_XPM
  29. #endif
  30. #include "wx/generic/icon.h"
  31. #elif defined(__WXGTK__)
  32. #define wxICON_DEFAULT_TYPE wxBITMAP_TYPE_XPM
  33. #include "wx/generic/icon.h"
  34. #elif defined(__WXX11__)
  35. #define wxICON_DEFAULT_TYPE wxBITMAP_TYPE_XPM
  36. #include "wx/generic/icon.h"
  37. #elif defined(__WXDFB__)
  38. #define wxICON_DEFAULT_TYPE wxBITMAP_TYPE_XPM
  39. #include "wx/generic/icon.h"
  40. #elif defined(__WXMAC__)
  41. #if wxOSX_USE_COCOA_OR_CARBON
  42. #define wxICON_DEFAULT_TYPE wxBITMAP_TYPE_ICON_RESOURCE
  43. #include "wx/osx/icon.h"
  44. #else
  45. #define wxICON_DEFAULT_TYPE wxBITMAP_TYPE_PNG_RESOURCE
  46. #include "wx/generic/icon.h"
  47. #endif
  48. #elif defined(__WXCOCOA__)
  49. #define wxICON_DEFAULT_TYPE wxBITMAP_TYPE_ICON_RESOURCE
  50. #include "wx/cocoa/icon.h"
  51. #elif defined(__WXPM__)
  52. #define wxICON_DEFAULT_TYPE wxBITMAP_TYPE_ICO_RESOURCE
  53. #include "wx/os2/icon.h"
  54. #endif
  55. //-----------------------------------------------------------------------------
  56. // wxVariant support
  57. //-----------------------------------------------------------------------------
  58. #if wxUSE_VARIANT
  59. #include "wx/variant.h"
  60. DECLARE_VARIANT_OBJECT_EXPORTED(wxIcon,WXDLLIMPEXP_CORE)
  61. #endif
  62. #endif
  63. // _WX_ICON_H_BASE_