summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKazumasa Mitsunari <knimitz@witz-inc.co.jp>2018-11-15 19:01:04 +0900
committerKazumasa Mitsunari <knimitz@witz-inc.co.jp>2018-11-15 19:02:13 +0900
commit39f79014e874492dc47d76b64badb715b198db79 (patch)
tree7deb111e68255bde43ddde52af1177f1d6f4a574
parent6a712584e9b66fe48494c5d20690a072320baf14 (diff)
Use graphic_role
Window Manager set role name as lower_case, then change role as lower_case. Change-Id: Iee62ff0832bef3b70adf76698efbf7168fd5af69 Signed-off-by: Kazumasa Mitsunari <knimitz@witz-inc.co.jp>
-rw-r--r--homescreen/src/main.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/homescreen/src/main.cpp b/homescreen/src/main.cpp
index 620c869..8ecfd68 100644
--- a/homescreen/src/main.cpp
+++ b/homescreen/src/main.cpp
@@ -78,6 +78,7 @@ int main(int argc, char *argv[])
int port = 1700;
QString token = "wm";
+ QString graphic_role = "homescreen"; // defined in layers.json in Window Manager
if (positionalArguments.length() == 2) {
port = positionalArguments.takeFirst().toInt();
@@ -99,12 +100,12 @@ int main(int argc, char *argv[])
AGLScreenInfo screenInfo(layoutHandler->get_scale_factor());
- if (layoutHandler->requestSurface(QString("HomeScreen")) != 0) {
+ if (layoutHandler->requestSurface(graphic_role) != 0) {
exit(EXIT_FAILURE);
}
- layoutHandler->set_event_handler(QLibWindowmanager::Event_SyncDraw, [layoutHandler](json_object *object) {
- layoutHandler->endDraw(QString("HomeScreen"));
+ layoutHandler->set_event_handler(QLibWindowmanager::Event_SyncDraw, [layoutHandler, &graphic_role](json_object *object) {
+ layoutHandler->endDraw(graphic_role);
});
layoutHandler->set_event_handler(QLibWindowmanager::Event_ScreenUpdated, [layoutHandler, launcher](json_object *object) {