]> git.saurik.com Git - wxWidgets.git/commitdiff
disable VC++ warning 4355 in wx/defs.h once and for all instead of doing it in 4...
authorVadim Zeitlin <vadim@wxwidgets.org>
Sun, 9 Oct 2005 22:34:08 +0000 (22:34 +0000)
committerVadim Zeitlin <vadim@wxwidgets.org>
Sun, 9 Oct 2005 22:34:08 +0000 (22:34 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@35866 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

include/wx/defs.h
include/wx/event.h
include/wx/generic/scrolwin.h
include/wx/rawbmp.h

index 48561360f0adff5b24b24b8ecff9906ae61b6c3e..674b4db3e1a25d076deb4fd981ed3fd59531672b 100644 (file)
 #ifdef __VISUALC__
     /*  the only "real" warning here is 4244 but there are just too many of them */
     /*  in our code... one day someone should go and fix them but until then... */
+#   pragma warning(disable:4097)    /*  typedef used as class */
 #   pragma warning(disable:4201)    /*  nonstandard extension used: nameless struct/union */
 #   pragma warning(disable:4244)    /*  conversion from double to float */
-#   pragma warning(disable:4710)    /*  function not inlined */
-#   pragma warning(disable:4097)    /*  typedef used as class */
+#   pragma warning(disable:4355)    /* 'this' used in base member initializer list */
 #   pragma warning(disable:4511)    /*  copy ctor couldn't be generated */
 #   pragma warning(disable:4512)    /*  operator=() couldn't be generated */
-#ifndef WIN32
-#   pragma warning(disable:4135)    /*  conversion between different integral types */
-#   pragma warning(disable:4769)    /*  assignment of near pointer to long integer */
-/*  This one is really annoying, since it occurs for each cast to (HANDLE)... */
-#   pragma warning(disable:4305)    /*  truncation of long to near ptr */
-#endif
+#   pragma warning(disable:4710)    /*  function not inlined */
 #endif /*  __VISUALC__ */
 
 /*  suppress some Salford C++ warnings */
index 939e8fce1e66dfc5c9179e0fbe1746ccdf02c871..11cbcd1fc39a5812b3a396d862bc6c096a863de0 100644 (file)
@@ -504,14 +504,6 @@ private:
 };
 #endif
 
-#ifdef __VISUALC__
-    // 'this' : used in base member initializer list (for m_commandString)
-    #if _MSC_VER > 1100
-        #pragma warning(push)
-    #endif
-    #pragma warning(disable:4355)
-#endif
-
 class WXDLLIMPEXP_CORE wxCommandEvent : public wxEvent
 {
 public:
@@ -574,10 +566,6 @@ private:
     DECLARE_DYNAMIC_CLASS_NO_ASSIGN(wxCommandEvent)
 };
 
-#if defined(__VISUALC__) && (_MSC_VER > 1100)
-    #pragma warning(pop)
-#endif
-
 #if WXWIN_COMPATIBILITY_2_4
 inline void wxCommandEventStringHelper::operator=(const wxString &str)
 {
index 2163b7141d34dca546ce4eec9fe2554a023a8787..5586fd5a3cab454e1eae24d4eae793eb5963a0f5 100644 (file)
@@ -26,14 +26,6 @@ extern WXDLLEXPORT_DATA(const wxChar*) wxPanelNameStr;
     #define wxScrolledWindowStyle (wxHSCROLL | wxVSCROLL)
 #endif
 
-// avoid triggering this stupid VC++ warning
-#ifdef __VISUALC__
-    #if _MSC_VER > 1100
-        #pragma warning(push)
-    #endif
-    #pragma warning(disable:4355) // 'this' used in base member initializer list
-#endif
-
 // ----------------------------------------------------------------------------
 // wxGenericScrolledWindow
 // ----------------------------------------------------------------------------
@@ -94,10 +86,5 @@ private:
     DECLARE_EVENT_TABLE()
 };
 
-#if defined(__VISUALC__) && (_MSC_VER > 1100)
-    #pragma warning(pop)
-#endif
-
-#endif
-    // _WX_GENERIC_SCROLLWIN_H_
+#endif // _WX_GENERIC_SCROLLWIN_H_
 
index 1595183e51a05d72ae6003d6df9f584fdb2f0e01..db4c014d15af516d32e763bf620b5224702625df 100644 (file)
     }
  */
 
-#ifdef __VISUALC__
-    // VC++ gives an absolutely harmless warning for wxPixelData<wxBitmap> ctor
-    #pragma warning(push)
-    #pragma warning(disable: 4355) // 'this' used in initializer list
-#endif
-
 /*
     Note: we do not use WXDLLEXPORT with classes in this file because VC++ has
     problems with exporting inner class defined inside a specialization of a
@@ -658,14 +652,6 @@ struct wxPixelDataOut<wxBitmap>
 };
 #endif //wxUSE_GUI
 
-#ifdef __VISUALC__
-    // typedef-name 'foo' used as synonym for class-name 'bar'
-    // (VC++ gives this warning each time wxPixelData::Base is used but it
-    //  doesn't make any sense here -- what's wrong with using typedef instead
-    //  of class, this is what it is here for!)
-    #pragma warning(disable: 4097)
-#endif // __VISUALC__
-
 template <class Image, class PixelFormat = wxPixelFormatFor<Image> >
 class wxPixelData :
     public wxPixelDataOut<Image>::template wxPixelDataIn<PixelFormat>
@@ -717,9 +703,5 @@ struct wxPixelIterator : public wxPixelData<Image, PixelFormat>::Iterator
 {
 };
 
-#ifdef __VISUALC__
-    #pragma warning(pop)
-#endif
-
 #endif // _WX_RAWBMP_H_BASE_