* add commit SHA information

* allow to open link in quotes editor
* fix bug with no data updates in configuration ui
This commit is contained in:
arcan1s
2015-09-28 19:27:55 +03:00
parent 92ce241742
commit 84f6f1a820
10 changed files with 45 additions and 19 deletions

View File

@ -345,7 +345,7 @@ Item {
if (debug) console.debug()
// init submodule
awKeys.initKeys(plasmoid.configuration.text)
awKeys.initKeys(plasmoid.configuration.text, plasmoid.configuration.queueLimit)
}
Component.onDestruction: {

View File

@ -349,11 +349,7 @@ Item {
engine: "systemmonitor"
connectedSources: systemmonitorDE.sources
interval: 5000
onNewData: {
if (debug) console.debug("Update source", sourceName)
awKeys.dataUpdateReceived(sourceName, data)
}
onNewData: awKeys.dataUpdateReceived(sourceName, data)
}
PlasmaCore.DataSource {
@ -365,7 +361,6 @@ Item {
onNewData: {
// even after a disconnect it is possible that we'll receive an update
if (sourceName == "update") return
if (debug) console.debug("Update source", sourceName)
awKeys.dataUpdateReceived(sourceName, data)
}
}
@ -375,11 +370,7 @@ Item {
engine: "time"
connectedSources: ["Local"]
interval: 5000
onNewData: {
if (debug) console.debug("Update source", sourceName)
awKeys.dataUpdateReceived(sourceName, data)
}
onNewData: awKeys.dataUpdateReceived(sourceName, data)
}
@ -398,6 +389,7 @@ Item {
awKeys.setAggregatorProperty("customUptime", plasmoid.configuration.customUptime)
awKeys.setAggregatorProperty("tempUnits", plasmoid.configuration.tempUnits)
awKeys.setAggregatorProperty("translate", plasmoid.configuration.translateStrings)
awKeys.unlock()
}
onDropSource: {

View File

@ -118,9 +118,10 @@ QString AWActions::getAboutText(const QString type) const
QString text;
if (type == QString("header"))
text = QString(NAME);
else if (type == QString("version"))
else if (type == QString("version")) {
text = i18n("Version %1 (build date %2)", QString(VERSION), QString(BUILD_DATE));
else if (type == QString("description"))
if (!QString(COMMIT_SHA).isEmpty()) text += QString(" (%1)").arg(QString(COMMIT_SHA));
} else if (type == QString("description"))
text = i18n("A set of minimalistic plasmoid widgets");
else if (type == QString("links"))
text = i18n("Links:") + QString("<br>") +
@ -237,6 +238,7 @@ void AWActions::showInfo(const QString version) const
qCDebug(LOG_AW) << "Version" << version;
QString text = i18n("You are using the actual version %1", version);
if (!QString(COMMIT_SHA).isEmpty()) text += QString(" (%1)").arg(QString(COMMIT_SHA));
QMessageBox::information(nullptr, i18n("No new version found"), text);
}
@ -248,7 +250,8 @@ void AWActions::showUpdates(const QString version) const
qCDebug(LOG_AW) << "Version" << version;
QString text;
text += i18n("Current version : %1", QString(VERSION)) + QString("\n");
text += i18n("Current version : %1", QString(VERSION));
text += QString(COMMIT_SHA).isEmpty() ? QString("\n") : QString(" (%1)\n").arg(QString(COMMIT_SHA));
text += i18n("New version : %1", version) + QString("\n\n");
text += i18n("Click \"Ok\" to download");

View File

@ -464,6 +464,7 @@ void AWKeys::reinitKeys()
// init
QStringList allKeys = dictKeys();
#ifdef BUILD_TEST
// not documented feature - place all available tags
m_pattern = m_pattern.replace(QString("$ALL"), [allKeys]() {
QStringList strings;
@ -471,6 +472,7 @@ void AWKeys::reinitKeys()
strings.append(QString("%1: $%1").arg(tag));
return strings.join(QString(" | "));
}());
#endif /* BUILD_TEST */
// append lists
// bars