project groups: copy file name for removed targets, disable actions for removed targets

git-svn-id: trunk@50401 -
This commit is contained in:
mattias 2015-11-18 16:42:33 +00:00
parent a33c0dd6d6
commit 30000af935

View File

@ -669,7 +669,7 @@ Var
T: TPGCompileTarget; T: TPGCompileTarget;
begin begin
T:=SelectedTarget; T:=SelectedTarget;
Result:=Assigned(T) and (ATargetAction in T.AllowedActions); Result:=Assigned(T) and (not T.Removed) and (ATargetAction in T.AllowedActions);
If Assigned(AAction) then If Assigned(AAction) then
AAction.Enabled:=Result; AAction.Enabled:=Result;
end; end;
@ -736,7 +736,8 @@ var
ND: TNodeData; ND: TNodeData;
begin begin
ND:=SelectedNodeData; ND:=SelectedNodeData;
(Sender as TAction).Enabled:=(ND<>nil) and (ND.NodeType in [ntTarget,ntProjectGroup,ntFile]); (Sender as TAction).Enabled:=(ND<>nil)
and ((ND.Target<>nil) or (ND.NodeType in [ntFile]));
UpdateIDEMenuCommandFromAction(Sender,cmdTargetCopyFilename); UpdateIDEMenuCommandFromAction(Sender,cmdTargetCopyFilename);
end; end;