Expose whether CanvasElement is visible
This commit is contained in:
@@ -210,6 +210,12 @@ namespace canvas
|
||||
return true;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------
|
||||
bool Element::isVisible() const
|
||||
{
|
||||
return _transform->getNodeMask() != 0;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------
|
||||
osg::ref_ptr<osg::MatrixTransform> Element::getMatrixTransform()
|
||||
{
|
||||
|
||||
@@ -82,6 +82,11 @@ namespace canvas
|
||||
virtual bool hitBound( const osg::Vec2f& pos,
|
||||
const osg::Vec2f& local_pos ) const;
|
||||
|
||||
/**
|
||||
* Get whether the element is visible or hidden (Can be changed with
|
||||
* setting property "visible" accordingly).
|
||||
*/
|
||||
bool isVisible() const;
|
||||
|
||||
osg::ref_ptr<osg::MatrixTransform> getMatrixTransform();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user