user541686
user541686

Reputation: 210352

Why do my buttons stay highlighted simultaneously?

You usually only have one button that looks like a "default button".

However, I made a child window and placed two buttons in it (with the child window as their parent). Then I put the child window inside a dialog and displayed it.

Suddenly, the buttons stay highlighted even when I click other buttons!

Why?

Upvotes: 0

Views: 135

Answers (1)

user541686
user541686

Reputation: 210352

Your child window needs the WS_EX_CONTROLPARENT style, to allow the dialog to handle the notifications from its children.

Upvotes: 2

Related Questions