mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-09-21 00:59:18 +02:00
LCL: Make MessageDlg default button work on Windows 7. Issue #19863, patch from Bart Broersma
git-svn-id: trunk@32035 -
This commit is contained in:
parent
8c23048e7d
commit
a21fbde6ef
@ -731,7 +731,11 @@ begin
|
||||
DialogButtons[i].pszButtonText := UTF8StringToPWideChar(GetButtonCaption(Buttons[i]));
|
||||
end;
|
||||
TaskConfig.pButtons := DialogButtons;
|
||||
TaskConfig.nDefaultButton := DefaultIndex;
|
||||
//we need idButtonXX value
|
||||
if DefaultIndex < ButtonCount then
|
||||
TaskConfig.nDefaultButton := Buttons[DefaultIndex]
|
||||
else
|
||||
TaskConfig.nDefaultButton := 0;
|
||||
|
||||
State := SaveApplicationState;
|
||||
try
|
||||
|
Loading…
Reference in New Issue
Block a user