Carbon intf: fixed bugs #0009713: Carbon Form.Show does not bring already displayed window to front and #0009714: Carbon menuitem remains active after selecting Form.show

git-svn-id: trunk@12107 -
This commit is contained in:
tombo 2007-09-21 09:12:19 +00:00
parent 69c6ec9a96
commit 82944ea49d

View File

@ -1306,7 +1306,10 @@ begin
//DebugLn('TCarbonWindow.ShowHide ' + DbgSName(LCLobject),' ', DbgS(AVisible));
if AVisible or (csDesigning in LCLobject.ComponentState) then
FPCMacOSAll.ShowWindow(WindowRef(Widget))
begin
SelectWindow(WindowRef(Widget)); // activate and move window to front
FPCMacOSAll.ShowWindow(WindowRef(Widget));
end
else
FPCMacOSAll.HideWindow(WindowRef(Widget));
end;