selectionWidget = NULL;
cadToolBar = NULL;
commandWidget = NULL;
- mainWindow = NULL;
+ mainWindowIntf = NULL;
DEBUG->print("QG_DialogFactory::QG_DialogFactory: OK");
}
/**
* Links the dialog factory to a main app window.
*/
-/*virtual*/ void QG_DialogFactory::setMainWindow(QG_MainWindowInterface * mw)
+/*virtual*/ void QG_DialogFactory::setMainWindow(QG_MainWindowInterface * mwi)
{
- mainWindow = mw;
+ mainWindowIntf = mwi;
}
/**
*/
GraphicView * QG_DialogFactory::requestNewDocument(const QString & fileName, Document * doc)
{
- if (mainWindow != NULL)
+ if (mainWindowIntf != NULL)
{
- mainWindow->createNewDocument(fileName, doc);
- return mainWindow->getGraphicView();
+ mainWindowIntf->createNewDocument(fileName, doc);
+ return mainWindowIntf->getGraphicView();
}
return NULL;
*/
void QG_DialogFactory::requestSimulationControls()
{
- if (mainWindow != NULL)
+ if (mainWindowIntf != NULL)
{
- mainWindow->showSimulationControls();
+ mainWindowIntf->showSimulationControls();
}
}
}
/*
if (layerList==NULL) {
- if (container!=NULL && container->rtti()==RS2::EntityGraphic) {
+ if (container!=NULL && container->rtti()==RS2::EntityDrawing) {
layerList = (LayerList*)container;
} else {
return NULL;
*/
BlockData QG_DialogFactory::requestBlockAttributesDialog(BlockList * blockList)
{
- //Block* block = NULL;
- BlockData ret;
- ret = BlockData("", Vector(false), false);
+ BlockData ret("", Vector(false), false);
+// ret = BlockData("", Vector(false), false);
if (blockList == NULL)
{
"blockList is NULL");
return ret;
}
- /*
- if (blockList==NULL) {
- if (container!=NULL && container->rtti()==RS2::EntityGraphic) {
- blockList = (BlockList*)container;
- } else {
- return NULL;
- }
- }*/
-
- // Block for parameter livery
- //block = blockList->getActive();
BlockDialog dlg(parent);//WAS:, "Rename Block");
#warning "!!! WTF !!! WHY DO WE HAVE TO PREFIX tr WITH QObject:: ???"
if (dlg.exec())
{
- //dlg.updateBlock();
- //block->setData();
ret = dlg.getBlockData();
}
- //else {
- // ret = BlockData("", Vector(false));
- //}
return ret;
}