Skip to content
Snippets Groups Projects
Commit 56e8f7f6 authored by Julien Michel's avatar Julien Michel
Browse files

ENH: (Visu Refactoring) Adding a Visible status flag to GlComponent

parent 41758522
Branches
Tags
No related merge requests found
......@@ -264,7 +264,10 @@ void Curves2DWidget::RenderCurves()
for(CurveListType::Iterator it = m_Curves->Begin();
it!=m_Curves->End(); ++it)
{
it.Get()->Render(m_Extent,m_SpaceToScreenTransform);
if(it.Get()->GetVisible())
{
it.Get()->Render(m_Extent,m_SpaceToScreenTransform);
}
}
}
......
......@@ -56,9 +56,14 @@ public:
/// Render the curve according to display extent and axis characteristics
virtual void Render(const RegionType& extent,const AffineTransformType * space2ScreenTransform) = 0;
/** Set/Get the visible status */
itkSetMacro(Visible,bool);
itkGetMacro(Visible,bool);
itkBooleanMacro(Visible);
protected:
/** Constructor */
GlComponent()
GlComponent() : m_Visible(true)
{}
/** Destructor */
virtual ~GlComponent(){}
......@@ -72,6 +77,9 @@ private:
GlComponent(const Self&); // purposely not implemented
void operator=(const Self&); // purposely not implemented
/// Is the component visible ?
bool m_Visible;
}; // end class
} // end namespace otb
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment