]> Creatis software - creaMaracasVisu.git/blobdiff - lib/maracasVisuLib/src/interface/wxWindows/widgets/pPlotter/mathplot.cxx
#3128 creaMaracasVisu Feature New Normal - branch changeWx28to30 compilation with...
[creaMaracasVisu.git] / lib / maracasVisuLib / src / interface / wxWindows / widgets / pPlotter / mathplot.cxx
index af3e86591c91280d11a42fa6a1869c3fdfb7df18..a465765e2663c6fb4835b3df0a097e4abc96f2d2 100644 (file)
@@ -368,12 +368,10 @@ void mpScaleY::Plot(wxDC & dc, mpWindow & w, int orgy)
        if (tmp>=1)
        {
                fmt = wxT("%.f");
-       }
-       else
-       {
+       } else {
                tmp=8-tmp;
                fmt.Printf(wxT("%%.%df"), tmp >= -1 ? 2 : -tmp);
-       }
+       } // if temp
 
        double n = floor( (w.GetPosY() - (double)extend / w.GetScaleY()) / step ) * step ;
 
@@ -389,8 +387,8 @@ void mpScaleY::Plot(wxDC & dc, mpWindow & w, int orgy)
                {
                        dc.DrawText( s, orgx+4, GetYTranslated(sizedc,p-ty/2));
                        tmp=p-ty/2;
-               }
-       }
+               } // if
+       } // for
 
        dc.GetTextExtent(m_name, &tx, &ty);
        dc.DrawText( m_name, orgx-tx-4, GetYTranslated(sizedc,-extend + ty + 4));
@@ -400,7 +398,13 @@ void mpScaleY::Plot(wxDC & dc, mpWindow & w, int orgy)
 // mpWindow
 //-----------------------------------------------------------------------------
 
-IMPLEMENT_DYNAMIC_CLASS(mpWindow, wxScrolledWindow)
+//EED 2017-09-16 Migration wxWidgets 2.8 to 3.0
+#if wxMAJOR_VERSION <= 2
+       IMPLEMENT_DYNAMIC_CLASS(mpWindow, wxScrolledWindow)
+#else
+       wxIMPLEMENT_DYNAMIC_CLASS(mpWindow, wxScrolledWindow);
+#endif
+
 
 BEGIN_EVENT_TABLE(mpWindow, wxScrolledWindow)
 EVT_PAINT    ( mpWindow::OnPaint)