Jump to content
  • Advertisement

Archived

This topic is now archived and is closed to further replies.

Fullscreen on 2nd monitor in DX8: lost kb focus forces app to minimize

This topic is 5771 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I''m writing a DirectX 8 app that is almost ready for multiple monitor setups. The only problem remaining is that when I have the app running fullscreen/exclusive on one adapter (monitor), and then click on something on the other monitor, the app automatically minimizes. I''d like it to just nicely relinquish the keyboard focus *and keep running (fullscreen) on the second monitor*, but I can''t seem to convince it to do that. Has anyone run into this before? As a workaround I''ve implemented a ''fake'' fullscreen mode, which makes a window that takes up the entire monitor area, but doesn''t really run in windowed mode. This works fairly well, but I''d prefer to get it working without this hack... Thanks in advance... Ryan Geiss

Share this post


Link to post
Share on other sites
Advertisement
A special thanks goes out to Phil Taylor (leader of the team responsible for the wonderful MS DirectX 8 SDK) for helping me solve this one. I was at Siggraph last week and Phil and I and some other guys were walking around San Antonio quite late at night, and I hit him with this question. He nailed it. Here''s what he said to do:

1) make sure I''m using HWND_TOPMOST for my window
(when fullscreen; I was only using HWND_TOP before).

2) return 0 when you receive the WM_NCACTIVATE (or
possibly WM_ACTIVATE or WM_ACTIVATEAPP) message
and the wParam is 0 (a deactivate).

The combination worked; I''d tried both independently, but not together, but you need them both the make it go. There you have it...

Thanks Phil, you rock.

Cheers,
Ryan Geiss
Nullsoft, Inc.

http://www.geisswerks.com/
http://www.nullsoft.com/
http://www.winamp.com/

Share this post


Link to post
Share on other sites

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

Participate in the game development conversation and more when you create an account on GameDev.net!

Sign me up!