X-Git-Url: https://gerrit.automotivelinux.org/gerrit/gitweb?a=blobdiff_plain;f=sample%2Fapp%2Fmain.qml;h=2feab6d400589bd9e49d0bf0b89b7ac1ef7f9c1e;hb=3007e9ca8e0636e6a2a4e61eb113869bfcc1385b;hp=f0a65e99d94df38ad277ef515d6724b3d8534bfd;hpb=cd39ff2c9987904617c53685a75f5fe89513ce81;p=apps%2Fonscreenapp.git diff --git a/sample/app/main.qml b/sample/app/main.qml index f0a65e9..2feab6d 100644 --- a/sample/app/main.qml +++ b/sample/app/main.qml @@ -20,6 +20,7 @@ ApplicationWindow { property string postmsg: qsTr("") property string btndata: qsTr("") property int pid: -1 + property bool onscreen_role_set: false Label { id: title @@ -340,13 +341,22 @@ ApplicationWindow { else postmsg += "}" + if (!onscreen_role_set) { + console.log("onscreen_role_set is not set") + eventHandler.set_window_popup(onsId, 0, 218) + console.log("setting for popup for " + onsId) + onscreen_role_set = true + } + // if the application is not already started, start it - if (pid == -1) { + if (pid === -1) { // if the application is not started, then the first time // we start we also display it using the default policy engine pid = eventHandler.start(onsId, postmsg) + console.log("calling eventHandler.start for " + onsId + " with pid " + pid) } else { // we just need to display it + console.log("calling eventHandler.showWindow for " + onsId) eventHandler.showWindow(onsId, postmsg) } }