mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-05-31 02:12:35 +02:00
lhelp - fixed the Default page of a chm being loaded twice on initial opening of a chm
git-svn-id: trunk@26981 -
This commit is contained in:
parent
8d83a14a6d
commit
a3ba202973
@ -548,6 +548,7 @@ var
|
||||
ATreeNode: TContentTreeNode;
|
||||
ARootNode: TTreeNode;
|
||||
fChm: TChmReader = nil;
|
||||
Uri: String;
|
||||
begin
|
||||
if (fContentsTree.Selected = nil) then Exit;
|
||||
if fContentsTree.Selected.Parent = nil then
|
||||
@ -556,8 +557,13 @@ begin
|
||||
fActiveChmTitle:= fChm.Title;
|
||||
UpdateTitle;
|
||||
if fChm.DefaultPage <> '' then
|
||||
DoLoadUri(MakeURI(fChm.DefaultPage, fChm));
|
||||
begin
|
||||
Uri := MakeURI(fChm.DefaultPage, fChm);
|
||||
if ((fHtml.MasterFrame <> nil) and (MakeURI(fHtml.CurURL, fChm) = Uri)) = False then
|
||||
DoLoadUri(Uri);
|
||||
end;
|
||||
Exit;
|
||||
|
||||
end;
|
||||
|
||||
ATreeNode := TContentTreeNode(fContentsTree.Selected);
|
||||
|
Loading…
Reference in New Issue
Block a user