33 #include <QStringList>
39 #include <QKeySequence>
41 ImportExportPlugin::ImportExportPlugin()
46 ImportExportPlugin::~ImportExportPlugin()
51 bool ImportExportPlugin::initialize(
const QStringList &args, QString *errMsg)
63 cmd->
action()->setText(tr(
"GCS Settings Import/Export..."));
70 connect(cmd->
action(), &QAction::triggered,
this, &ImportExportPlugin::importExport);
75 void ImportExportPlugin::importExport()
80 void ImportExportPlugin::extensionsInitialized()
85 void ImportExportPlugin::shutdown()
virtual QAction * action() const =0
virtual Command * registerAction(QAction *action, const QString &id, const QList< int > &context)=0
Makes an action known to the system under the specified string id.
virtual ActionContainer * actionContainer(const QString &id) const =0
Returns the IActionContainter object that is know to the system under the given string id...
virtual ActionManager * actionManager() const =0
Returns the application's action manager.
const char *const G_FILE_SAVE
static ICore * instance()
virtual void addAction(Core::Command *action, const QString &group=QString())=0
virtual void setDefaultKeySequence(const QKeySequence &key)=0
The action manager is responsible for registration of menus and menu items and keyboard shortcuts...
The class Command represents an action like a menu item, tool button, or shortcut. You don't create Command objects directly, instead use {ActionManager::registerAction()} to register an action and retrieve a Command. The Command object represents the user visible action and its properties. If multiple actions are registered with the same ID (but different contexts) the returned Command is the shared one between these actions.