class GroupBlock;\r
class FunctionalBlock;\r
class GroupScene;\r
+class AbstractBoxItem;\r
class GroupItem;\r
class BoxItem;\r
class InterfaceItem;\r
class Graph;\r
+class GroupWidget;\r
\r
#include "BlockImplementation.h"\r
+#include "ExternalResource.h"\r
\r
#include "Exception.h"\r
class Exception;\r
inline void setCursorState(CursorState state) { cursorState = state; }\r
inline void setDispatcher(Dispatcher* _dispatcher) { dispatcher = _dispatcher;}\r
\r
+ // testers\r
+\r
+ // others\r
+ static QString normalizeName(const QString& name);\r
+ QList<ExternalResource*> searchResourceByName(const QString& name);\r
+\r
/***************************************************\r
attributes that are general to the application\r
***************************************************/ \r
BlockLibraryTree* categoryTree;\r
QList<QString> refPathes;\r
QList<QString> implPathes;\r
+ QList<QString> sourcePathes;\r
QList<ReferenceBlock*> availableBlocks;\r
QList<BlockImplementation*> availableImplementations;\r
+ QList<ExternalResource*> availableResources;\r
\r
+ ReferenceBlock* delayRef;\r
+ BlockImplementation* delayImpl; \r
\r
QString refLib;\r
QString implLib;\r
// defaults for vhdl\r
int wbDataWidth;\r
int wbAddressWidth;\r
+ QString validityExtension; //! the string to add to ports to obtain the name of the associated validity port.\r
+ \r
// defaults for scene elements\r
int defaultBlockWidth;\r
int defaultBlockHeight;\r
QString defaultIfaceFontName;\r
int defaultIfaceFontSize;\r
int connGapLength;\r
- QPainterPath inArrow;\r
- QPainterPath outArrow;\r
+ QPainterPath dataArrowIn;\r
+ QPainterPath dataArrowOut;\r
+ QPainterPath clkrstArrow;\r
+\r
\r
/***************************************************\r
attributes that are specific for the current project\r
EditState editState; // takes values from EDIT_STATE_XXX\r
bool unsaveModif;\r
bool isRstClkShown;\r
+ QMap<FunctionalBlock*, BoxItem*> blockToItem; // allow to retrieve a box item from a functionnal block\r
+ QString projectPath;\r
+ QString projectName;\r
+ QString projectFile; // equals to projectPath/projectName.xml\r
+ bool autoConnMainClk; // true if auto-connection to main clock (i.e. ext_clk) \r
+ double mainClock; // main clock freq (reported in graph->clocks(0))\r
\r
- Graph* createGraph();\r
+ Graph* initGraph(bool createTopGroupIfaces = true);\r
void destroyGraph();\r
inline Graph* getGraph() { return graph; } \r
ReferenceBlock* getReferenceBlock(int idCategory, int idBlock); // get the reference block from its category and index\r
- FunctionalBlock* duplicateFunctionalBlock(FunctionalBlock* block); // adding a copy of a functional block to current group\r
-\r
+ ReferenceBlock* getHiddenReferenceBlock(QString blockName); // get a hidden block by name, i.e. in category 100 \r
\r
void clear();\r
\r
QDomElement openProjectFile(const QString& projectFileName) throw(Exception);\r
- void loadProject(QDomElement root);\r
+ GroupWidget *loadProject(QDomElement root) throw(Exception);\r
\r
void loadBlastConfiguration(QString confFile) throw(Exception);\r
void loadReferencesFromXml() throw(Exception);\r
void loadReferencesFromLib() throw(Exception);\r
void saveReferencesToLib() throw(Exception);\r
+ void createDelayBlock();\r
\r
void loadImplementationsFromXml() throw(Exception);\r
void loadImplementationsFromLib() throw(Exception);\r
void saveImplementationsToLib() throw(Exception);\r
\r
+ void loadSources() throw(Exception);\r
+\r
void addAvailableBlock(ReferenceBlock *block); \r
void parametersValidation();\r
void connectionsValidation();\r
ReferenceBlock* searchBlockByXml(QString xmlName);\r
ReferenceBlock* searchBlockByMd5(QString sumMd5);\r
\r
+ BoxItem* searchFunctionalBlock(AbstractBlock* block);\r
+\r
void save(QString confFile);\r
\r
\r
- QString projectPath;\r
+\r
\r
private:\r
Graph* graph; // the graph model of blocks\r
\r
GroupScene* searchSceneById(int id, GroupScene* scene);\r
BoxItem* searchBlockItemById(int id, GroupScene* scene);\r
+ BoxItem* searchFunctionalBlockRecur(AbstractBlock* block, GroupScene* scene);\r
GroupItem* searchGroupItemById(int id, GroupScene* scene);\r
InterfaceItem* searchInterfaceItemById(int id, GroupScene *scene);\r
\r