//
// Who When What
// --- ---------- -----------------------------------------------------------
-// JLH 05/22/2010 Added this text. :-)
+// JLH 06/22/2010 Added this text. :-)
//
#include "rs_actionselectall.h"
+
+#include "rs_dialogfactory.h"
#include "rs_selection.h"
-RS_ActionSelectAll::RS_ActionSelectAll(RS_EntityContainer& container,
- RS_GraphicView& graphicView, bool select):
+RS_ActionSelectAll::RS_ActionSelectAll(RS_EntityContainer & container,
+ RS_GraphicView & graphicView, bool select):
RS_ActionInterface("Select All Entities", container, graphicView)
{
- this->select = select;
+ this->select = select;
}
-QAction * RS_ActionSelectAll::createGUIAction(RS2::ActionType type, QObject * parent)
+RS_ActionSelectAll::~RS_ActionSelectAll()
{
- QAction * action;
-
- if (type == RS2::ActionSelectAll)
- {
- action = new QAction(tr("Select &All"), parent);
- action->setShortcut(Qt::CTRL + Qt::Key_A);
-// action = new QAction(tr("Select All"), tr("Select &All"),
-// CTRL+Key_A, parent);
- action->setStatusTip(tr("Selects all Entities"));
- }
- else
- {
- action = new QAction(tr("Deselect &all"), parent);
- action->setShortcut(Qt::CTRL + Qt::Key_K);
-// action = new QAction(tr("Deselect all"), tr("Deselect &all"),
-// CTRL+Key_K, parent);
- action->setStatusTip(tr("Deselects all Entities"));
- }
-
- return action;
}
+/*virtual*/ RS2::ActionType RS_ActionSelectAll::rtti()
+{
+ return RS2::ActionSelectAll;
+}
void RS_ActionSelectAll::init(int status)
{
RS_DIALOGFACTORY->updateSelectionWidget(container->countSelected());
}
-
-// EOF