Hi all, there are several of us that would love to see if it is possible to get Mouse Click Relative to UI Element working on the Dolby Atmos Renderer.
Currently I’m doing a bunch of stuff with press keys. But there are some things for ex entering in TC for punching in and out that would be really great to have set up with a push of a button.
When I try to get that set up with Mouse Click Relative to UI Element it won’t work. Is there a possible fix for this?
Thanks so much!!
- Christian Scheuer @chrscheuer2021-03-28 17:14:16.662Z
When I try to get that set up with Mouse Click Relative to UI Element it won’t work
Can I get you to quote your script here that you're using? Which part about it doesn't work (what does actually happen vs what did you expect to happen)?
Generally, Mouse Click Relative to UI Element should work in all apps, so I wonder if it's because it's being set up incorrectly or if there's something specific to the Renderer.
Christian Scheuer @chrscheuer2021-03-28 17:15:44.028Z
For future reference, please use the "Script Help" workflow here as it guides you on how to embed macros/scripts into the question so it's easier to help :)
- MMichael Keeley @Michael_Keeley
Copy will do. Here is the script. Is there anything that I'm doing wrong here?
Thx
quoted text
sf.ui.app("com.dolby.atmos.renderer").mainWindow.mouseClickElement({
relativePosition: {"x":1023,"y":98},
anchor: "TopCenter",
});quoted text
Christian Scheuer @chrscheuer2021-03-28 20:44:25.900Z
This looks correct, provided that you want to measure from the horizontal center (in x-coords) of the top of the window. Normally people would measure most things from the top left corner, but there are cases where you want to measure from other anchor points.
But to figure out if this is wrong or not, I would need to know what you're trying to do and what you're experiencing when running this code :) I can't guess it.For example, if you show us a screenshot in 1x1 resolution with a description of the button you're trying to press, it'd be easier :) But just from the code and with no description of what's actually happenning when you run it, it's impossible to say if it's correct code or not.
- MMichael Keeley @Michael_Keeley
Copy here you go with this command I'm trying to toggle the Mute button. Also fyi when picking the UI elementl. On the Dolby Renderer it is only letting me choose the entire screen and not individual sub boxes like PT.
- MMichael Keeley @Michael_Keeley
Christian Scheuer @chrscheuer2021-03-29 14:52:53.574Z
Right. From this it looks like you're incorrectly using TopCenter - you should use Top Left anchor.
The whole window being highlighted is a limitation in the Renderer and expected.
sf.ui.app("com.dolby.atmos.renderer").mainWindow.mouseClickElement({ relativePosition: {"x":1023,"y":98}, anchor: "TopLeft", });
Christian Scheuer @chrscheuer2021-03-29 14:53:32.759Z
I'd recommend this tutorial to learn how to use this:
- MMichael Keeley @Michael_Keeley
Thanks yes I’ve watched this. I originally used the left anchor and it has the same result and doesn’t work.
Christian Scheuer @chrscheuer2021-03-30 09:01:04.847Z
Gotcha. Besides adding an application activate main window action before this call I probably can't help much since I don't have the renderer myself.
Christian Scheuer @chrscheuer2021-03-30 09:11:54.797Z
@Ivan_Markovic - I think you have this working, right? Maybe you can help Michael.
Christian Scheuer @chrscheuer2021-03-30 09:12:38.018Z
I think @Sreejesh_Nair @Sreejesh_Nair2 may also be using this :)
Christian Scheuer @chrscheuer2021-03-30 09:21:21.081Z
This is the code I would put in front of your script:
sf.ui.app("com.dolby.atmos.renderer").appActivateMainWindow();
To make sure that the renderer is focused before you simulate the mouse click.
- In reply tochrscheuer⬆:IIvan Markovic @Ivan_Markovic
I made it work somehow, it was pretty straightforward actually. But then I switched to the keyboard shortcuts they added in the new version of the renderer so I don't use it anymore.
This is the screenshot when I made it work:
- MMichael Keeley @Michael_Keeley
Ivan Thank you that's it. It needed the activate app's main window before mouse click relative to UI. I've switched a bunch of stuff over with the new quick key commands as well. But now with this I can select punch in and out. Which is huge when having to deal with crazy qc notes..
@Sreejesh_Nair this is what I was missing. It now works great!Thanks @chrscheuer !!
- IIvan Markovic @Ivan_Markovic
Happy to help!