#include <ModuleBase_Tools.h>
#include <Events_Loop.h>
+#include <Config_PropManager.h>
#include <QLayout>
#include <QPushButton>
#include <QEvent>
#include <QKeyEvent>
#include <QDialogButtonBox>
+#include <QShortcut>
enum ColumnType {
Col_Name,
connect(myAddBtn, SIGNAL(clicked(bool)), SLOT(onAdd()));
aBtnLayout->addWidget(myAddBtn);
+ QString aAddStr(Config_PropManager::string("Shortcuts", "add_parameter_shortcut").c_str());
+ if (aAddStr.isEmpty())
+ aAddStr = "Ctrl+A";
+
+ QShortcut* aAddShc = new QShortcut(QKeySequence(aAddStr), myAddBtn);
+ connect(aAddShc, SIGNAL(activated()), SLOT(onAdd()));
+
myInsertBtn = new QPushButton(translate("Insert"), this);
connect(myInsertBtn, SIGNAL(clicked(bool)), SLOT(onInsert()));
aBtnLayout->addWidget(myInsertBtn);
Config_PropManager::registerProp("Visualization", "sketch_dimension_color",
"Dimension color",
Config_Prop::Color, SKETCH_DIMENSION_COLOR);
+
+ Config_PropManager::registerProp("Shortcuts", "add_parameter_shortcut",
+ "Add parameter in parameters manager dialog",
+ Config_Prop::Shortcut, "Ctrl+A");
}
//******************************************************