]> git.saurik.com Git - wxWidgets.git/commitdiff
Put wxAny implementation entirely in the header.
authorVadim Zeitlin <vadim@wxwidgets.org>
Sun, 20 Sep 2009 12:37:16 +0000 (12:37 +0000)
committerVadim Zeitlin <vadim@wxwidgets.org>
Sun, 20 Sep 2009 12:37:16 +0000 (12:37 +0000)
This allows to remove WXDLLIMPEXP_BASE from the class declaration and should
hopefully fix VC6 linking errors when building the unit test.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@61981 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

include/wx/any.h
src/common/any.cpp

index e4aacabba9706f692e76a486dbcdb7c1fa24f724..13e5d1080326c66ce4250f32ae7855e7f4b9a5ad 100644 (file)
@@ -514,7 +514,7 @@ bool operator==(TUS value) const \
 // As standard, wxAny can store value of almost any type, in a fairly
 // optimal manner even.
 //
-class WXDLLIMPEXP_BASE wxAny
+class wxAny
 {
 public:
     /**
@@ -755,7 +755,15 @@ public:
 
 private:
     // Assignment functions
-    void AssignAny(const wxAny &any);
+    void AssignAny(const wxAny& any)
+    {
+        if ( !any.m_type->IsSameType(m_type) )
+        {
+            m_type->DeleteValue(m_buffer);
+            m_type = any.m_type;
+        }
+        m_type->CopyBuffer(any.m_buffer, m_buffer);
+    }
 
     template<typename T>
     void Assign(const T &value)
index 9923d3ef07cac0bde6e81588448828b78bff6fed..9ac859b6e17712fea33beb575bcb32e735da2030 100644 (file)
@@ -105,20 +105,6 @@ wxAnyValueType::wxAnyValueType()
     g_wxAnyValueTypeGlobals->RegisterValueType(this);
 }
 
-//-------------------------------------------------------------------------
-// wxAny
-//-------------------------------------------------------------------------
-
-void wxAny::AssignAny(const wxAny &any)
-{
-    if ( !any.m_type->IsSameType(m_type) )
-    {
-        m_type->DeleteValue(m_buffer);
-        m_type = any.m_type;
-    }
-    m_type->CopyBuffer(any.m_buffer, m_buffer);
-}
-
 //-------------------------------------------------------------------------
 // Dynamic conversion member functions
 //-------------------------------------------------------------------------