User avatar
DiNWw
Topic Author
Posts: 5
Joined: 17 Nov 2020, 08:27

Out-of-focus window render

07 Jun 2021, 11:12

Hello

I am developing a Windows program to display various data coming from other programs. I am using Application Framework with C++. I have faced with the fact that most of the time the program window may not be active (the focus is on another application), but I need to see all the changes that occur in real time, not when I return the focus. How can I solve this issue?
 
User avatar
jsantos
Site Admin
Posts: 3906
Joined: 20 Jan 2012, 17:18
Contact:

Re: Out-of-focus window render

07 Jun 2021, 12:06

DisplayLauncher exposes a virtual function for that purpose:
virtual bool GetRunInBackgroundOverride() const;
It is implemented by default to read from the command line but you can reimplement it on you AppLauncher.
bool DisplayLauncher::GetRunInBackgroundOverride() const
{
    return GetArguments().HasOption("runInBackground");
}
 
User avatar
DiNWw
Topic Author
Posts: 5
Joined: 17 Nov 2020, 08:27

Re: Out-of-focus window render

07 Jun 2021, 13:57

Thank you for such a quick response, now everything is working as it should :)

Who is online

Users browsing this forum: Google [Bot] and 11 guests