Solved Standalone app having focus
-
In this example I'm trying to set focus to a standalone application built in Hise, in this example I want the "spacebar" to control start and stop of the midi player.
It's working when compiled but it seems this is not the way to do it sooo...
How do I script this the right way, anybody?HiseSnippet 2239.3oc2Ys0baabEFTRHsh9RSxjoSebGMclR23gDf2ky3ZdWhVhTTDT1t9gjYIvBhUBbALvBIQkwuzeY4mP+az27+f1yB.RB3Paqnjzoob7Xi8bY2uyk8rmc8HOGchuuimTlrSV3RjxbeYsELtUaKLkI0uiTlGJq4h0ISwdirwKjZsvE66SLjxjY6CDxjY2cjB+8tm0BaiY5j0jjjdgCUmbLcNkul5nFGQss6gMHSnySHc4F80cXscrcB.7rsrhDrvWfmQFhEhskrzgXeKoL+U4p56WQYJQoRk5kKUub4pkqVQwToj4z5UKOsTsxkLJWQUujTlOqqAk63owwbhuTlcZ4XrPyx4JVzB7BpOcpMQLPURCV4Hx8brMDlnfpTaKpswnkNJeIoLxiV611Nxs8UxCnFzUzW6997PFn0ZjzAlYqzva6TvSMI7TR.uM.osR.oe2xHYHjffFwKDJ6JOHdTRLzNvyiv3Zj2DPRE7d2yhYMwCBCIoeriiaWFFPlQRxhIeJHplKIMiLaeqMS0OpYJIrndTahvjyrb.Hsv7f7iNXNVJy+RVslRd1jpGUu8X2ASxmeLyrOOeI+l07tHvG90r64kq6+JxMdmpby4UGdQmWMryaNys9EWaOsXvgcw0TmvLGz+liZeZq80u9k6e7o6W504a87JFyeC0bHAe9MG2qpd6utZ9is3m3ZdyEO+0mh6oQNxLv3qubg9fRcza+Jy4Wc5qOo942b1LVGe8R0NKeOyh8Ik6ke1M9V.aW0WGbfti0Y27hSoAGd4A0LpdV8AO2n9P5gKl1r2kdlG1T65yO55i0dU6EuNedVvnNVsjDVezli2HW3Lehmeg.aO5EScLHrBCB7o5ENj5SJbXestnQiO44caOQqPygcF2TqvHv8hffEHfWg04JEV4jKL1ZA2ZdgVmno0L5uQsZpokeNUj5H18pQmwv7.O.Be1vf4svPXZUj+wMF5LmB7EYk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Fwd2HW4WF1F5Iv9Cn3SjGasMbO4pkJVVoXoJkjR5Atub4h0qoVp19Eqm1GDxoTohp6Wpbb+dOW96yhP6sJn22XumfVcr5iE75C6YuFnpDNBZu214pWB6jBK4BzCqcl8svENDM7lvqEFXk9I3F+CI559i4HG13WTG48gntpR0pJkpn9SwSVrZ0xJJ2AOo5OaO4tQdxGF6IaEv4NrPe3txwGT8A8de6m1682ZrYHH1q.MqJO53l+cIenFeel37ZBOZ+Up86OH898vVmBQ3CSRQ8mytkM.y0luID+0n2j5NxQ3Oqr1nls61p43TIAPDshRohUpTLRW9B6vpYiIyBrwdgDitvfnBmIFNTQh.Uhwqtk4FZlFtBqiAnNO88ZE29OlATyOUC0hllY9T9hT2B7WpK6dag3WHOhx0s1LF2ZCXTbO5eEvX7SD7.4tllP+PqA3Nx8d0uNuGPxk+gQK+8j0f1yBuAR3h+GCGidonKmCHLhmv4o9Qdem+4s88cbu0uuyI5bX4m3gY9tN9olXMxb5DXCgeRhvUb64QdyXQzLI81Nv8N2Dq28rdfQtQczDWaMLsn4bm.Vpac99OXwN2t1S9DOazN+O2yF8afM6Yxj.i6tDiZz4t1jtrKI1PGbgX7KWVPaI0z4xCbXNtVNLpdx.8XB2iNaFwKI12nA0jyS8JXeUiwDaBNYR6etwwPxF1C7Sj6nuP816K9Xwq+jbDbQhMfne6Vjd6++tH8Xm.QuiCvPRHzBg7vf4ZPsQcBr5Ln+NwEixrkn9VzXEw3nhiLivA+a3WLSUw3LwLUWx7+Jqwbrtmy2oGckOQd5uOjBX2r3dMFHFiTkBuFXxXo3Yl9Nc8zS0ORwh2UEKcWUr7cUwJ2UEqdWUr1cUw5eZEEGB0Lf6LOZqojzfQcitpPlU+G.jYao+CT8fR4B
-
@ulrik You want the app to be on screen somewhere and no matter what window the user is in they can press space to start/stop MIDI playback?
-
@d-healey No, only if the app active, I tried this without the timer now, and it works nicely
As soon as I make the app active it's possible to use the setKeypressCallback
So in. the snippet, I removed the timer function and it worked
-
-