mirror of
https://github.com/arcan1s/awesome-widgets.git
synced 2025-07-10 04:15:51 +00:00
try to implement concurent data update
This commit is contained in:
@ -68,6 +68,8 @@ Item {
|
||||
|
||||
property alias cfg_text: textPattern.text
|
||||
|
||||
signal dropSource(string sourceName)
|
||||
|
||||
|
||||
Column {
|
||||
id: pageColumn
|
||||
@ -360,7 +362,7 @@ Item {
|
||||
|
||||
onNewData: {
|
||||
if (debug) console.debug("Update source", sourceName)
|
||||
awKeys.setDataBySource(sourceName, data, settings)
|
||||
awKeys.dataUpdateReceived(sourceName, data, settings)
|
||||
}
|
||||
}
|
||||
|
||||
@ -372,7 +374,7 @@ Item {
|
||||
|
||||
onNewData: {
|
||||
if (debug) console.debug("Update source", sourceName)
|
||||
awKeys.setDataBySource(sourceName, data, settings)
|
||||
awKeys.dataUpdateReceived(sourceName, data, settings)
|
||||
}
|
||||
}
|
||||
|
||||
@ -384,14 +386,22 @@ Item {
|
||||
|
||||
onNewData: {
|
||||
if (debug) console.debug("Update source", sourceName)
|
||||
awKeys.setDataBySource(sourceName, data, settings)
|
||||
awKeys.dataUpdateReceived(sourceName, data, settings)
|
||||
}
|
||||
}
|
||||
|
||||
Component.onCompleted: {
|
||||
if (debug) console.debug()
|
||||
|
||||
awKeys.dropSourceFromDataengine.connect(dropSource)
|
||||
// init submodule
|
||||
awKeys.initKeys(plasmoid.configuration.text)
|
||||
}
|
||||
|
||||
onDropSource: {
|
||||
if (debug) console.debug()
|
||||
if (debug) console.debug("Source", sourceName)
|
||||
|
||||
systemmonitorDE.disconnectSource(sourceName)
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user