mirror of
https://github.com/arcan1s/awesome-widgets.git
synced 2025-07-21 01:29:58 +00:00
commit before tests
This commit is contained in:
@ -62,18 +62,20 @@ void AwesomeWidget::reinit()
|
||||
values[QString("netdev")] = getNetworkDevice();
|
||||
// thread()->wait(60000);
|
||||
connectToEngine();
|
||||
updateText(true);
|
||||
resize(10, 10);
|
||||
}
|
||||
|
||||
|
||||
void AwesomeWidget::updateText()
|
||||
void AwesomeWidget::updateText(bool clear)
|
||||
{
|
||||
if (debug) qDebug() << PDEBUG;
|
||||
|
||||
QString text = configuration[QString("text")];
|
||||
for (int i=0; i<foundKeys.count(); i++)
|
||||
text.replace(QString("$") + foundKeys[i] + QString("$"), values[foundKeys[i]]);
|
||||
textLabel->setText(text);
|
||||
if (!clear)
|
||||
for (int i=0; i<foundKeys.count(); i++)
|
||||
text.replace(QString("$") + foundKeys[i] + QString("$"), values[foundKeys[i]]);
|
||||
textLabel->setText(formatLine[0] + text + formatLine[1]);
|
||||
}
|
||||
|
||||
|
||||
|
Reference in New Issue
Block a user