inline QList<BoxItem*> getBlockItems() { return blockItems; }
inline QList<ConnectionItem*> getConnectionItems() { return connectionItems; }
inline QList<GroupScene*> getChildrenScene() { return childrenScene; }
- inline GroupWidget* getGroupWindow() { return window; }
+ inline GroupScene* getParentScene() { return parentScene; }
+ inline GroupWidget* getGroupWidget() { return window; }
inline int getId() { return id; }
inline EditMode getEditionMode() { return editMode; }
InterfaceItem* getSelectedInterface(int id);
// others
- BoxItem* createBlockItem(AbstractBlock* block);
- void addBlockItem(BoxItem* item);
+ BoxItem* createBlockItem(AbstractBlock* block); //! create a new BoxItem and place it at the center of the scene
+ void addBlockItem(BoxItem* item); //! add an already configured BoxItem in the scene.
void removeBlockItem(BoxItem* item);
void createConnectionItem(InterfaceItem* iface1, InterfaceItem* iface2);
ConnectionItem* searchConnectionItem(InterfaceItem* iface1, InterfaceItem* iface2);
void removeConnectionItem(ConnectionItem* item);
void removeGroupItem();
inline void addChildScene(GroupScene* child) { childrenScene.append(child); }
+ inline void removeChildScene(GroupScene* child) { childrenScene.removeAll(child); }
+ inline int getNbChildScene() { return childrenScene.size(); }
void unselecteInterfaces();
QList<AbstractBoxItem*> getGroupAndBlocks();
private:
Dispatcher *dispatcher;
Parameters *params;
- GroupScene* parentScene; // the parnet scene, =NULL for top scene
+ GroupScene* parentScene; // the parent scene, =NULL for top scene
GroupWidget* window; // the GroupWindow that contains that scene
int id;
GroupItem *groupItem; // mandatory to be an instance of GroupItem.