更新
This commit is contained in:
JianjunLiu 2023-07-13 09:58:26 +08:00
parent dfc015ea12
commit 42ee9c066c
6 changed files with 12 additions and 5 deletions

Binary file not shown.

Binary file not shown.

View File

@ -274,11 +274,16 @@ public //֪ͨ
@param(Value)(bool) 状态值 %% @param(Value)(bool) 状态值 %%
@param(SetChildren)(bool) 是否修改子控件状态 %% @param(SetChildren)(bool) 是否修改子控件状态 %%
**} **}
if ifnil(SetChildren)then SetChildren := true; //if ifnil(SetChildren)then SetChildren := true;
If Value then If Value then
begin
includestate(FComponentState,csDesigning); includestate(FComponentState,csDesigning);
else if (self(true) is class(tcontrol)) then self(true).visible := true; //设置可见
end
else
begin
excludestate(FComponentState,csDesigning); excludestate(FComponentState,csDesigning);
end
if SetChildren then if SetChildren then
begin begin
items := FComponents.data; items := FComponents.data;
@ -460,7 +465,7 @@ public //
if AComponent.ValidateContainer(Self)then if AComponent.ValidateContainer(Self)then
begin begin
self.Insert(AComponent); self.Insert(AComponent);
If csDesigning in FComponentState then AComponent.SetDesigning(true); //If csDesigning in FComponentState then AComponent.SetDesigning(true);
Notification(AComponent,opInsert); Notification(AComponent,opInsert);
end end
end; end;
@ -470,7 +475,7 @@ public //
@explan(说明)移除子节点 %% @explan(说明)移除子节点 %%
**} **}
Notification(AComponent,opRemove); Notification(AComponent,opRemove);
if Remove(AComponent)then Acomponent.Setdesigning(False); Remove(AComponent);//if Remove(AComponent)then Acomponent.Setdesigning(False);
end; end;
function Assigned(o);virtual; function Assigned(o);virtual;
begin begin
@ -631,6 +636,7 @@ public //
iv := otype.UnformatEdit(v); //反转换 iv := otype.UnformatEdit(v); //反转换
if FChangedProperties[n]=vi then continue; //没有改变 if FChangedProperties[n]=vi then continue; //没有改变
SetChangedPublish(n,iv,pp); //保存 SetChangedPublish(n,iv,pp); //保存
if n="visible" or n="wspopup" or n="enabled" then return 1; // 屏蔽几个属性
if vit="eventhandler" then //分类保存 if vit="eventhandler" then //分类保存
begin begin
FEventsProperties[n]:= iv; FEventsProperties[n]:= iv;

View File

@ -107,7 +107,7 @@ private
{** {**
@explan(说明) 删除hmenu节点 %% @explan(说明) 删除hmenu节点 %%
**} **}
if _wapi.RemoveMenu(FHandle,pi,MF_BYPOSITION)then menuchanged(); _wapi.RemoveMenu(FHandle,pi,MF_BYPOSITION);
end end
function addhmenuitem(item,bef); function addhmenuitem(item,bef);
begin begin
@ -790,6 +790,7 @@ private
end end
end end
item.setfparent(nil); item.setfparent(nil);
menuchanged();
end end
private private
function setparentforproperty(f); function setparentforproperty(f);

Binary file not shown.

Binary file not shown.