mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-08-09 13:22:24 +03:00
0031035: Coding - uninitialized class fields reported by Visual Studio Code Analysis
Added initialization of fields that had not initialization Added default constructors to classes without constructors
This commit is contained in:
@@ -26,6 +26,10 @@ IMPLEMENT_STANDARD_RTTIEXT(Draw_Drawable3D,Standard_Transient)
|
||||
//purpose :
|
||||
//=======================================================================
|
||||
Draw_Drawable3D::Draw_Drawable3D() :
|
||||
myXmin(0.0),
|
||||
myXmax(0.0),
|
||||
myYmin(0.0),
|
||||
myYmax(0.0),
|
||||
isVisible(Standard_False),
|
||||
isProtected(Standard_False),
|
||||
myName(NULL)
|
||||
|
@@ -277,7 +277,8 @@ Draw_Interpretor::Draw_Interpretor(const Draw_PInterp& p) :
|
||||
isAllocated(Standard_False),
|
||||
myInterp(p),
|
||||
myDoLog(Standard_False),
|
||||
myDoEcho(Standard_False)
|
||||
myDoEcho(Standard_False),
|
||||
myFDLog(-1)
|
||||
{
|
||||
}
|
||||
|
||||
|
@@ -40,7 +40,7 @@ Draw_Marker2D::Draw_Marker2D(const gp_Pnt2d& P, const Draw_MarkerShape T,
|
||||
|
||||
Draw_Marker2D::Draw_Marker2D(const gp_Pnt2d& P, const Draw_MarkerShape T,
|
||||
const Draw_Color& C, const Standard_Real /*RSize*/) :
|
||||
myPos(P), myCol(C), myTyp(T)
|
||||
myPos(P), myCol(C), myTyp(T), mySiz(0)
|
||||
{
|
||||
}
|
||||
|
||||
|
@@ -29,7 +29,7 @@ IMPLEMENT_STANDARD_RTTIEXT(Draw_Marker3D,Draw_Drawable3D)
|
||||
//=======================================================================
|
||||
Draw_Marker3D::Draw_Marker3D(const gp_Pnt& P, const Draw_MarkerShape T,
|
||||
const Draw_Color& C, const Standard_Integer S) :
|
||||
myPos(P), myCol(C), myTyp(T), mySiz(S), myIsRSiz(Standard_False)
|
||||
myPos(P), myCol(C), myTyp(T), mySiz(S), myRSiz(0.0), myIsRSiz(Standard_False)
|
||||
{
|
||||
}
|
||||
|
||||
@@ -40,7 +40,7 @@ Draw_Marker3D::Draw_Marker3D(const gp_Pnt& P, const Draw_MarkerShape T,
|
||||
|
||||
Draw_Marker3D::Draw_Marker3D(const gp_Pnt& P, const Draw_MarkerShape T,
|
||||
const Draw_Color& C, const Standard_Real RSize) :
|
||||
myPos(P), myCol(C), myTyp(T), myRSiz(RSize), myIsRSiz(Standard_True)
|
||||
myPos(P), myCol(C), myTyp(T), mySiz(0), myRSiz(RSize), myIsRSiz(Standard_True)
|
||||
{
|
||||
}
|
||||
|
||||
|
@@ -40,6 +40,7 @@ Draw_View::Draw_View(Standard_Integer theId,
|
||||
myFrameX1 (0),
|
||||
myFrameY1 (0)
|
||||
{
|
||||
memset (myType, 0, sizeof (myType));
|
||||
}
|
||||
|
||||
//=======================================================================
|
||||
@@ -68,6 +69,7 @@ Draw_View::Draw_View(Standard_Integer theId,
|
||||
myFrameX1 (0),
|
||||
myFrameY1 (0)
|
||||
{
|
||||
memset (myType, 0, sizeof (myType));
|
||||
}
|
||||
|
||||
//=======================================================================
|
||||
@@ -96,6 +98,7 @@ Draw_View::Draw_View(Standard_Integer theId,
|
||||
myFrameX1 (0),
|
||||
myFrameY1 (0)
|
||||
{
|
||||
memset (myType, 0, sizeof (myType));
|
||||
}
|
||||
#endif
|
||||
|
||||
@@ -130,6 +133,7 @@ Draw_View::Draw_View(Standard_Integer theId,
|
||||
myFrameX1 (0),
|
||||
myFrameY1 (0)
|
||||
{
|
||||
memset (myType, 0, sizeof (myType));
|
||||
}
|
||||
|
||||
//=======================================================================
|
||||
|
@@ -1453,7 +1453,9 @@ DrawWindow::DrawWindow() :
|
||||
next(firstWindow),
|
||||
previous(NULL),
|
||||
myMemHbm(NULL),
|
||||
myUseBuffer(Standard_False)
|
||||
myUseBuffer(Standard_False),
|
||||
myCurrPen(0),
|
||||
myCurrMode(0)
|
||||
{
|
||||
if (firstWindow) firstWindow->previous = this;
|
||||
firstWindow = this;
|
||||
|
@@ -370,7 +370,13 @@ class Segment
|
||||
friend class DrawWindow;
|
||||
public :
|
||||
//constructeur
|
||||
Segment () {}
|
||||
Segment ()
|
||||
: x1(0),
|
||||
y1(0),
|
||||
x2(0),
|
||||
y2(0)
|
||||
{
|
||||
}
|
||||
//destructeur
|
||||
~Segment () {}
|
||||
|
||||
|
Reference in New Issue
Block a user