mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-04-20 12:19:31 +02:00
Fix unwanted disabling of TMenuItem.Action in the designer. Issue #41109.
This commit is contained in:
parent
35c1846863
commit
93af67085a
@ -433,13 +433,15 @@ var
|
|||||||
begin
|
begin
|
||||||
if FItems = nil then
|
if FItems = nil then
|
||||||
Exit;
|
Exit;
|
||||||
|
if not (csDesigning in ComponentState) then // issue #41109
|
||||||
InitiateActions; // actions may update items visibility
|
|
||||||
if InternalRethinkLines(False) then
|
|
||||||
begin
|
begin
|
||||||
// Especially to re-index the items in native way
|
InitiateActions; // actions may update items visibility
|
||||||
for i := 0 to Count - 1 do
|
if InternalRethinkLines(False) then
|
||||||
Items[I].DestroyHandle;
|
begin
|
||||||
|
// Especially to re-index the items in native way
|
||||||
|
for i := 0 to Count - 1 do
|
||||||
|
Items[I].DestroyHandle;
|
||||||
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
AMenu := GetMenu(Self);
|
AMenu := GetMenu(Self);
|
||||||
|
Loading…
Reference in New Issue
Block a user