#include <Iguana/Studio/interface/IgQtAppDebug.h>
Public Member Functions | |
IgQtAppDumpStateInfo (IgState *state, QWidget *parent) | |
Protected Member Functions | |
virtual void | populate (IgState *state, QListViewItem *item) |
virtual void | update (void) |
Private Attributes | |
IgState * | m_state |
Definition at line 81 of file IgQtAppDebug.h.
IgQtAppDumpStateInfo::IgQtAppDumpStateInfo | ( | IgState * | state, | |
QWidget * | parent | |||
) |
Definition at line 228 of file IgQtAppDebug.cc.
References IgQtAppDebugInfo::list().
00230 : IgQtAppDebugInfo (parent, false), 00231 m_state (state->root ()) 00232 { 00233 list ()->addColumn ("States"); 00234 00235 setCaption ("IGUANA State tree"); 00236 resize (600, 200); 00237 }
Definition at line 250 of file IgQtAppDebug.cc.
References IgState::child(), IgState::children(), element(), IgState::element(), IgState::elements(), i, IgStateKey::label(), and IgStateElement::stateKey().
Referenced by update().
00251 { 00252 item->setOpen (true); 00253 00254 QListViewItem* element = new QListViewItem (item, "Elements"); 00255 bool hasElements = false; 00256 for (unsigned int i=0; i<state->elements(); i++) 00257 { 00258 if (state->element (i)) 00259 { 00260 new QListViewItem (element, 00261 state->element (i)->stateKey().label ().c_str()); 00262 hasElements = true; 00263 } 00264 } 00265 if (!hasElements) 00266 delete element; 00267 else 00268 element->setOpen (true); 00269 00270 if (state->children()) 00271 for (unsigned int i=0; i<state->children(); i++) 00272 populate (state->child(i), new QListViewItem (item, "State")); 00273 }
Implements IgQtAppDebugInfo.
Definition at line 240 of file IgQtAppDebug.cc.
References ASSERT, IgQtAppDebugInfo::list(), m_state, and populate().
00241 { 00242 QListView *props = list (); 00243 ASSERT (props); 00244 00245 props->clear (); 00246 populate (m_state, new QListViewItem (props, "State")); 00247 }
IgState* IgQtAppDumpStateInfo::m_state [private] |