Members of the KDE Community are recommended to subscribe to the kde-community mailing list at https://mail.kde.org/mailman/listinfo/kde-community to allow them to participate in important discussions and receive other important announcements

Commit 4650224f authored by Boudewijn Rempt's avatar Boudewijn Rempt

Remove some unused code

parent 8e212571
......@@ -103,8 +103,8 @@ public:
// This is the main place containing ActionInfoItems.
QMap<QString, ActionInfoItem> actionInfoList;
void loadActionFiles();
void loadActionCollections();
void loadCustomShortcuts(QString filename = QStringLiteral("kritashortcutsrc"));
ActionInfoItem &actionInfo(const QString &name) {
if (!actionInfoList.contains(name)) {
dbgAction << "Tried to look up info for unknown action" << name;
......@@ -113,7 +113,6 @@ public:
};
KisActionRegistry *q;
KActionCollection * defaultActionCollection;
QMap<QString, KActionCollection*> actionCollections;
};
......@@ -129,13 +128,10 @@ KisActionRegistry *KisActionRegistry::instance()
KisActionRegistry::KisActionRegistry()
: d(new KisActionRegistry::Private(this))
{
d->loadActionFiles();
KConfigGroup cg = KSharedConfig::openConfig()->group("Shortcut Schemes");
QString schemeName = cg.readEntry("Current Scheme", "Default");
loadShortcutScheme(schemeName);
loadCustomShortcuts();
}
QList<QKeySequence> KisActionRegistry::getCustomShortcut(const QString &name)
......@@ -201,7 +197,6 @@ void KisActionRegistry::loadShortcutScheme(const QString &schemeName)
if (schemeName != QStringLiteral("Default")) {
QString schemeFileName = KShortcutSchemesHelper::schemeFileLocations().value(schemeName);
if (schemeFileName.isEmpty()) {
// qDebug() << "No configuration file found for scheme" << schemeName;
return;
}
KConfig schemeConfig(schemeFileName, KConfig::SimpleConfig);
......@@ -380,6 +375,7 @@ void KisActionRegistry::Private::loadActionFiles()
QStringList actionDefinitions =
KoResourcePaths::findAllResources("kis_actions", "*.action", KoResourcePaths::Recursive);
// Extract actions all XML .action files.
Q_FOREACH (const QString &actionDefinition, actionDefinitions) {
QDomDocument doc;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment