`monitorHandle` value does not always match monitor list handle values

Issue Description:
There is some issues with the monitor handle values returned from getRunningGameInfo and getMonitorsList.

I am trying to determine which monitor the game is running on, but the monitorHandle from getRunningGameInfo doesn’t always match the handle value from getMonitorsList.

Sometimes the monitorHandle.value from getRunningGameInfo is 0, and sometimes the handle.value from getMonitorList is 0.

Sometimes, the monitorHandle.value has the value of the incorrect monitor. The game will open on my secondary display, but it will have the handle value of my primary monitor.


[Top is getRunningGameInfo. Bottom is getMonitorsList. The secondary display has a handle value of 0, which I suspect is wrong.]

How my monitors are setup:
image

  • monitor 1 is my laptop. 1920x1080 with 125% scaling.
  • monitor 2 is a secondary monitor attached with HDMI. 1920x1080 with 100% scaling.
  • the monitors are extended in the Windows settings.

Other Observations:

  • if the virtual monitors are lined up such that their ‘x’ values are both 0 (like above or with monitor 1 above monitor 2), then the attached display has a handle value of ‘0’.
  • if the ‘x’ values differ, then the secondary monitor has a non-zero handle value

imageimage
[Monitors arranged vertically with small offset on ‘x’ axis. The handle values are non-zero.]

imageimage
[Monitors arranged horizontally. The handle values are non-zero.]


[Sometimes the monitorHandle.value from getRunningGameInfo is 0. This is logged in a background window where the app was launched by opening a game. I’m unsure how to reproduce this case.]

Do you currently have a workaround?
No. I don’t have another way to determine which monitor the game is running on.

Please reproduce and attach a zip package of your OW client logs
Here are the logs after I did some testing with various monitor arrangements.
Testing done on Mar 1, 2022 around 10:30 AM to 11:40 AM.
monitorHandle values incorrect OverwolfLogs_2022-03-01_11-47-12.zip (1.6 MB)

fixed for next version (194), deploy to Developers in few days

I am Overwolf version 0.195.0.15 and I am having huge problems with these monitorHandles.

Note that my primary display actually has a negative monitor handle value, us that intended?
Additionally, the window I have the game currently at, is not in my monitorlist.

we are not able to reproduce it,
does it happen for every game?

Hi!
This might be fixed in iteration 199 which should be available for developers from today.
If it is not, please let us know, and we will try to look into it again and let you know!