gl_utils.h: fix compil issue on Windows
__WINDOWS__ is defined in wxWidgets. the right preprocessor symbol is _WIN32 for Windows 32/64 bits
This commit is contained in:
parent
7ba6a77c94
commit
286c36b7da
|
@ -24,7 +24,7 @@
|
||||||
#ifndef GL_UTILS_H
|
#ifndef GL_UTILS_H
|
||||||
#define GL_UTILS_H
|
#define GL_UTILS_H
|
||||||
|
|
||||||
#ifndef __WINDOWS__
|
#ifndef _WIN32
|
||||||
#include <GL/glxew.h>
|
#include <GL/glxew.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
@ -42,7 +42,7 @@ public:
|
||||||
{
|
{
|
||||||
/// This routine is written for Linux only. The equivalent functions under Windows would
|
/// This routine is written for Linux only. The equivalent functions under Windows would
|
||||||
/// include <wglext.h> and call wglSwapIntervalEXT
|
/// include <wglext.h> and call wglSwapIntervalEXT
|
||||||
#ifndef __WINDOWS__
|
#ifndef _WIN32
|
||||||
Display *dpy = glXGetCurrentDisplay();
|
Display *dpy = glXGetCurrentDisplay();
|
||||||
GLXDrawable drawable = glXGetCurrentDrawable();
|
GLXDrawable drawable = glXGetCurrentDrawable();
|
||||||
|
|
||||||
|
|
|
@ -342,7 +342,8 @@ void D_PAD::BuildEffectiveShapes() const
|
||||||
//
|
//
|
||||||
m_effectiveBoundingRadius = calcBoundingRadius();
|
m_effectiveBoundingRadius = calcBoundingRadius();
|
||||||
|
|
||||||
m_effectiveBoundingBox = EDA_RECT(); // reset to prepare for merging
|
// reset the bbox to uninitialized state to prepare for merging
|
||||||
|
m_effectiveBoundingBox = EDA_RECT();
|
||||||
|
|
||||||
for( const std::shared_ptr<SHAPE>& shape : m_effectiveShapes )
|
for( const std::shared_ptr<SHAPE>& shape : m_effectiveShapes )
|
||||||
{
|
{
|
||||||
|
@ -350,7 +351,6 @@ void D_PAD::BuildEffectiveShapes() const
|
||||||
m_effectiveBoundingBox.Merge( EDA_RECT( (wxPoint) r.GetOrigin(),
|
m_effectiveBoundingBox.Merge( EDA_RECT( (wxPoint) r.GetOrigin(),
|
||||||
wxSize( r.GetWidth(), r.GetHeight() ) ) );
|
wxSize( r.GetWidth(), r.GetHeight() ) ) );
|
||||||
}
|
}
|
||||||
|
|
||||||
// Hole shape
|
// Hole shape
|
||||||
//
|
//
|
||||||
wxSize half_size = m_Drill / 2;
|
wxSize half_size = m_Drill / 2;
|
||||||
|
|
Loading…
Reference in New Issue