json-rpc - origin, ui update (#407)

* try ace

* .

* update

* ...

* update

* update

* test

* -

* update

* fix

* .

* Revert "."

This reverts commit 631c30f8c0.

* Revert "fix"

This reverts commit be3dbc9cbd.

* Revert "update"

This reverts commit 50fc89e800.

* Revert "-"

This reverts commit 8a6c1fdab3.

* Revert "test"

This reverts commit 50b3641490.

* update schema

* update ui

* flags

* adjustments
This commit is contained in:
brindosch
2017-02-28 17:53:41 +01:00
committed by redPanther
parent a76abdaafe
commit 31f352e7ce
45 changed files with 1883 additions and 9591 deletions

View File

@@ -365,6 +365,7 @@ void JsonClientConnection::handleColorCommand(const QJsonObject& message, const
// extract parameters
int priority = message["priority"].toInt();
int duration = message["duration"].toInt(-1);
QString origin = message["origin"].toString();
std::vector<ColorRgb> colorData(_hyperion->getLedCount());
const QJsonArray & jsonColor = message["color"].toArray();
@@ -391,7 +392,7 @@ void JsonClientConnection::handleColorCommand(const QJsonObject& message, const
}
// set output
_hyperion->setColors(priority, colorData, duration, true, hyperion::COMP_COLOR);
_hyperion->setColors(priority, colorData, duration, true, hyperion::COMP_COLOR, origin);
// send reply
sendSuccessReply(command, tan);
@@ -598,6 +599,7 @@ void JsonClientConnection::handleServerInfoCommand(const QJsonObject&, const QSt
item["owner"] = QString(hyperion::componentToIdString(priorityInfo.componentId));
item["componentId"] = priorityInfo.componentId;
item["origin"] = priorityInfo.origin;
item["component"] = QString(hyperion::componentToString(priorityInfo.componentId));
item["active"] = true;
item["visible"] = (priority == currentPriority);

View File

@@ -20,6 +20,10 @@
"type": "integer",
"required": false
},
"origin": {
"type": "string",
"required": true
},
"color": {
"type": "array",
"required": true,

View File

@@ -20,6 +20,10 @@
"type": "integer",
"required": false
},
"origin": {
"type": "string",
"required": true
},
"effect": {
"type": "object",
"required": true,