]> git.saurik.com Git - wxWidgets.git/blobdiff - include/wx/gtk/dataform.h
No changes, synchronised source names that appear commented at the top of files with...
[wxWidgets.git] / include / wx / gtk / dataform.h
index 1fc8372227b8beee615eaa89c1858d4ae44eecfa..efb2ba523f2a6e940f0b6e7ba000d3fcc38400e0 100644 (file)
@@ -1,5 +1,5 @@
 ///////////////////////////////////////////////////////////////////////////////
-// Name:        gtk/dataform.h
+// Name:        wx/gtk/dataform.h
 // Purpose:     declaration of the wxDataFormat class
 // Author:      Vadim Zeitlin
 // Modified by:
@@ -30,7 +30,14 @@ public:
     wxDataFormat( const wxCStrData& id ) { InitFromString(id); }
 
     wxDataFormat& operator=(const wxDataFormat& format)
-        { m_type = format.m_type; m_format = format.m_format; return *this; }
+    {
+        if (&format != this)
+        {
+            m_type = format.m_type;
+            m_format = format.m_format;
+        }
+        return *this;
+    }
     wxDataFormat& operator=(NativeFormat format)
         { SetId(format); return *this; }