Hide options when use context menu.

--HG--
branch : feature
This commit is contained in:
dismine 2014-09-01 14:01:50 +03:00
parent c412d0c51b
commit d4a71f7664
2 changed files with 4 additions and 1 deletions

View File

@ -36,6 +36,7 @@
#include "../../dialogs/tools/dialogtool.h"
#include "../../widgets/vmaingraphicsscene.h"
#include "../../xml/vpattern.h"
#include "../../widgets/vmaingraphicsview.h"
/**
* @brief The VDrawTool abstract class for all draw tool.
@ -120,6 +121,7 @@ protected:
QAction *selectedAction = menu.exec(event->screenPos());
if (selectedAction == actionOption)
{
qApp->getSceneView()->itemClicked(nullptr);
dialog = new Dialog(getData(), id, qApp->getMainWindow());
dialog->setModal(true);
@ -136,6 +138,7 @@ protected:
}
if (selectedAction == actionRemove)
{
qApp->getSceneView()->itemClicked(nullptr);
DeleteTool();
}
}

View File

@ -87,7 +87,7 @@ void VToolOptionsPropertyBrowser::ShowItemOptions(QGraphicsItem *item)
AddPropertyPointsList(i, tr("Base point"), i->getBasePointId(), VAbstractTool::AttrBasePoint);
AddPropertyLineType(i, tr("Line type"));
AddPropertyFormula(tr("Length"), i->getFormulaLength(), VAbstractTool::AttrLength);
AddPropertyFormula(tr("Angle"), i->getFormulaLength(), VAbstractTool::AttrAngle);
AddPropertyFormula(tr("Angle"), i->getFormulaAngle(), VAbstractTool::AttrAngle);
break;
}
case VToolAlongLine::Type: