#include "actionmodifydeletequick.h"
-#include "rs_dialogfactory.h"
+#include "debug.h"
+#include "dialogfactory.h"
#include "graphicview.h"
ActionModifyDeleteQuick::ActionModifyDeleteQuick(
- RS_EntityContainer & container, GraphicView & graphicView):
+ EntityContainer & container, GraphicView & graphicView):
ActionInterface("Quick Delete Entities", container, graphicView)
{
en = NULL;
*/
void ActionModifyDeleteQuick::trigger()
{
- RS_DEBUG->print("ActionModifyDeleteQuick::trigger()");
+ DEBUG->print("ActionModifyDeleteQuick::trigger()");
- if (en != NULL)
+ if (en)
{
- RS_DEBUG->print("Entity found");
- RS_EntityContainer * parent = en->getParent();
+ DEBUG->print("Entity found");
+ EntityContainer * parent = en->getParent();
- if (parent != NULL)
+ if (parent)
{
en->setSelected(false);
+#warning "!!! Old rendering path need upgrade !!!"
+#if 0
graphicView->deleteEntity(en);
+#endif
en->changeUndoState();
if (document)
}
}
- RS_DIALOGFACTORY->updateSelectionWidget(container->countSelected());
+ DIALOGFACTORY->updateSelectionWidget(container->countSelected());
}
else
- RS_DEBUG->print("ActionModifyDeleteQuick::mousePressEvent:"
+ DEBUG->print("ActionModifyDeleteQuick::mousePressEvent:"
" Entity is NULL\n");
}
switch (getStatus())
{
case 0:
- RS_DIALOGFACTORY->updateMouseWidget(tr("Pick entity to delete"),
+ DIALOGFACTORY->updateMouseWidget(tr("Pick entity to delete"),
tr("Cancel"));
break;
default:
- RS_DIALOGFACTORY->updateMouseWidget("", "");
+ DIALOGFACTORY->updateMouseWidget("", "");
break;
}
}