Designer: Improve the fix for #24386. Prevent Copy/Paste of PageControl only with GTK2 bindings.

git-svn-id: trunk@52096 -
This commit is contained in:
juha 2016-04-01 09:12:15 +00:00
parent 93b5f73def
commit ce7000ecf8

View File

@ -2907,7 +2907,11 @@ var
begin
for i:=0 to FControls.Count-1 do
if (Items[i].Persistent is TCustomTabControl)
or (Items[i].Persistent is TCustomPage) then
{$IFDEF LCLGTK2} // Copying PageControl (TCustomPage) fails with GTK2
// in Destroy with LCLRefCount>0 due to some messages used. Issue #r51950.
or (Items[i].Persistent is TCustomPage)
{$ENDIF}
then
Exit(False);
Result:=True;
end;