gepetto::gui::SelectionEvent Class Reference

#include <gepetto/gui/selection-event.hh>

Inheritance diagram for gepetto::gui::SelectionEvent:
[legend]
Collaboration diagram for gepetto::gui::SelectionEvent:
[legend]

Public Types

enum  Type {
  FromOsgWindow,
  FromBodyTree
}
 

Public Slots

Type type () const
 
QString nodeName () const
 
Qt::KeyboardModifiers modKey () const
 
bool hasIntersection ()
 
QVector3D normal (bool local) const
 
QVector3D point (bool local) const
 
void done ()
 User must call this in slots using SelectionEvent. More...
 

Public Member Functions

 SelectionEvent (const Type &t, NodePtr_t node=NodePtr_t(), Qt::KeyboardModifiers modKey=Qt::NoModifier)
 
 SelectionEvent (const Type &t, Qt::KeyboardModifiers modKey)
 
void setupIntersection (const osgUtil::LineSegmentIntersector::Intersection &it)
 
const NodePtr_tnode () const
 
void modKey (const Qt::KeyboardModifiers &m)
 
void setCounter (int c)
 Set this to the number of slots that will receive the event. More...
 

Member Enumeration Documentation

Enumerator
FromOsgWindow 
FromBodyTree 

Constructor & Destructor Documentation

gepetto::gui::SelectionEvent::SelectionEvent ( const Type t,
NodePtr_t  node = NodePtr_t(),
Qt::KeyboardModifiers  modKey = Qt::NoModifier 
)
inline

References node().

gepetto::gui::SelectionEvent::SelectionEvent ( const Type t,
Qt::KeyboardModifiers  modKey 
)
inline

References setupIntersection().

Member Function Documentation

void gepetto::gui::SelectionEvent::done ( )
slot

User must call this in slots using SelectionEvent.

This decreases the internal counter and destroys the object when it reaches zero. This is thread-safe.

Referenced by point().

bool gepetto::gui::SelectionEvent::hasIntersection ( )
inlineslot
void gepetto::gui::SelectionEvent::modKey ( const Qt::KeyboardModifiers &  m)
inline
Qt::KeyboardModifiers gepetto::gui::SelectionEvent::modKey ( ) const
inlineslot
const NodePtr_t& gepetto::gui::SelectionEvent::node ( ) const
inline

Referenced by SelectionEvent().

QString gepetto::gui::SelectionEvent::nodeName ( ) const
inlineslot
QVector3D gepetto::gui::SelectionEvent::normal ( bool  local) const
inlineslot
QVector3D gepetto::gui::SelectionEvent::point ( bool  local) const
inlineslot

References done().

void gepetto::gui::SelectionEvent::setCounter ( int  c)
inline

Set this to the number of slots that will receive the event.

Warning
Not thread-safe
void gepetto::gui::SelectionEvent::setupIntersection ( const osgUtil::LineSegmentIntersector::Intersection &  it)

Referenced by SelectionEvent().

Type gepetto::gui::SelectionEvent::type ( ) const
inlineslot