make sure virtual method isn't inlined away

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@56650 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Stefan Csomor 2008-11-02 19:13:54 +00:00
parent 81d3348a9b
commit 74cc3ec18e
2 changed files with 15 additions and 4 deletions

View File

@ -132,12 +132,23 @@
#ifdef WXMAKINGDLL_CORE
# define WXDLLIMPEXP_CORE WXEXPORT
# define WXDLLIMPEXP_DATA_CORE(type) WXEXPORT type
# if defined(HAVE_VISIBILITY)
# define WXDLLIMPEXP_INLINE_CORE WXEXPORT
# else
# define WXDLLIMPEXP_INLINE_CORE
# endif
#elif defined(WXUSINGDLL)
# define WXDLLIMPEXP_CORE WXIMPORT
# define WXDLLIMPEXP_DATA_CORE(type) WXIMPORT type
# if defined(HAVE_VISIBILITY)
# define WXDLLIMPEXP_INLINE_CORE WXIMPORT
# else
# define WXDLLIMPEXP_INLINE_CORE
# endif
#else /* not making nor using DLL */
# define WXDLLIMPEXP_CORE
# define WXDLLIMPEXP_DATA_CORE(type) type
# define WXDLLIMPEXP_INLINE_CORE
#endif
#ifdef WXMAKINGDLL_ADV

View File

@ -32,10 +32,10 @@ public:
// accessors
virtual bool IsOk() const { return m_cgColour; }
ChannelType Red() const { return m_red; }
ChannelType Green() const { return m_green; }
ChannelType Blue() const { return m_blue; }
ChannelType Alpha() const { return m_alpha; }
virtual WXDLLIMPEXP_INLINE_CORE ChannelType Red() const { return m_red; }
virtual WXDLLIMPEXP_INLINE_CORE ChannelType Green() const { return m_green; }
virtual WXDLLIMPEXP_INLINE_CORE ChannelType Blue() const { return m_blue; }
virtual WXDLLIMPEXP_INLINE_CORE ChannelType Alpha() const { return m_alpha; }
// comparison
bool operator == (const wxColour& colour) const;