File tree Expand file tree Collapse file tree 2 files changed +3
-1
lines changed
Expand file tree Collapse file tree 2 files changed +3
-1
lines changed Original file line number Diff line number Diff line change @@ -1561,6 +1561,8 @@ procedure TFrameViews.Activate;
15611561var
15621562 Command: TRibbonCommand;
15631563begin
1564+ if TreeViewRibbon.Items.Count = 0 then
1565+ exit;// Nothing to do here
15641566 ActionDelete.ShortCut := ShortCut(VK_DELETE, [ssCtrl]);
15651567 ActionMoveUp.ShortCut := ShortCut(VK_UP, [ssCtrl]);
15661568 ActionMoveDown.ShortCut := ShortCut(VK_DOWN, [ssCtrl]);;
Original file line number Diff line number Diff line change @@ -55,7 +55,7 @@ procedure TFrameXmlSource.Activate;
5555 TreeViewXmlSource.Items.BeginUpdate;
5656 try
5757 TreeViewXmlSource.Items.Clear;
58- if FileExists(FDocument.Filename) then
58+ if Assigned(FDocument) and FileExists(FDocument.Filename) then
5959 begin
6060 FXmlDoc.LoadFromFile(FDocument.Filename);
6161 LineNum := 2 ;
You can’t perform that action at this time.
0 commit comments