- 30/11/2018 at 23:26 #9056JohnParticipant
I am building an application for a school project using the Tobii EyeTracker 4C. My project group is building a UI that uses the gaze to open various applications. What I noticed is that while our application is GazeAware, when it opens up a new application that comes to the foreground overtop of the MainWindow we have designed, there is no way to bring our application to the foreground without using the mouse. Though I am no expert in .Net, it seems the Tobii Core SDK only makes objects within the MainWindow GazeAware, and therefore the icon for the MainWindow in the taskbar is not able to be GazeAware.
So my question goes out to those of you with more experience with .Net and the Tobii Core SDK: is there a way to make an icon in the Taskbar GazeAware? Let me know if my description isn’t detailed enough and I will provide more info.
Thanks for reading!07/12/2018 at 09:34 #9096Grant [Tobii]Keymaster
Hi @jsneal519, thanks for your query and patience whilst we tried to find a solution for your needs. There is within .NET the possibility to “SetFocus”: https://docs.microsoft.com/en-us/windows/desktop/api/winuser/nf-winuser-setfocus
Which you could implement to run after a certain time in which no gaze data is received within the application. Alternatively, you could try to set your gaze-aware application to be ‘always on top’ which you can implement using .NET: https://docs.microsoft.com/en-us/dotnet/api/system.windows.forms.form.topmost?view=netframework-4.7.2 or alternatively a third party program or even a simple script via Autohotkey. Although this technique may not necessarily be full proof.
As it stands, there is not currently a method to make the taskbar icon gaze aware, so hopefully one of these workarounds should satisfy your requirements.
Please let us know if we can be of any further assistance.19/12/2018 at 22:00 #9165JohnParticipant
Thanks, Grant! Sorry for responding so late. I’ve been in end of semester hell. We ended up using the Window.Topmost() = true workaround to make our floating icon, a Window, always appear on top of any other windows opened while using our UI. This allowed one to access our UI hands-free even if the user had other windows open, and it served well for presenting the project and demoing the UI to other students. Is it a long-term solution for the application if it were to be made into a product? I have no idea, and would need to do more research.20/12/2018 at 09:42 #9168Grant [Tobii]Keymaster
Hi @jsneal519, thanks for your feedback. Indeed, making the window topmost is not fullproof as it can be overridden by other windows which have been also given topmost status. Long term, I think ‘setfocus’ call as explained above would be more appropriate.
Try it out and let us know how you get on. Best wishes.
- You must be logged in to reply to this topic.