Jump to content
  • Advertisement
Sign in to follow this  
O-san

Common dialog problems

This topic is 4000 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

Hello! I'm using GetOpenFileName function with explorer style - not oldstyle, to get user selected files. When I move the dialog the background behind it gets messed up. My background is an OpenGL scene, so I tried catching the WM_MOVE message and redraw the scene when needed but GetOpenFileName dialog doesn't send any such message :( If I change the style of the dialog to the oldstyle I get the WM_MOVE message and all works as expected. Does anyone know whats causing the loss of the WM_MOVE message?? :S Thanks!

Share this post


Link to post
Share on other sites
Advertisement
The WM_MOVE message is sent to a window that has moved. When you move the file dialog, only that dialog gets the WM_MOVE, it doesn't pass it on to any other window (nor should it). When the file dialog moves, any window (or part of) underneath it that becomes visible gets a WM_PAINT message. The main app probably isn't handling the WM_PAINT message correctly. In windowed mode, you want OpenGL to render to a backbuffer and then copy the backbuffer to the screen in response to a WM_PAINT message.

Skizz

Share this post


Link to post
Share on other sites
I have a hook proc on my openfiledialog that catches the WM_MOVE message, but I never got the message when I moved the dialog :S I did however get the WM_INITDIALOG message. If I switch to the old style dialog it sends the WM_MOVE message (strange?). But now it works anyways, I had totally forgot about WM_PAINT :D thanks for refreshing my memory! works like a charm =)

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • 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!