FIX: Viewer - wrong initial image size and position

(cherry picked from commit 741e55c0ea)
This commit is contained in:
Alexander Koblov 2024-02-09 22:03:17 +03:00
commit 7f090a336d

View file

@ -3238,6 +3238,10 @@ end;
procedure TfrmViewer.ActivatePanel(Panel: TPanel);
begin
bPlugin := (Panel = nil);
bAnimation := (Panel = pnlImage) and (GifAnim.Visible);
bImage := (Panel = pnlImage) and (bAnimation = False);
if Panel <> pnlText then pnlText.Hide;
if Panel <> pnlCode then pnlCode.Hide;
if Panel <> pnlImage then pnlImage.Hide;
@ -3290,9 +3294,6 @@ begin
ToolBar1.Visible:= not (bQuickView or (miFullScreen.Checked and not ToolBar1.MouseInClient));
end;
bAnimation := (Panel = pnlImage) and (GifAnim.Visible);
bImage := (Panel = pnlImage) and (bAnimation = False);
bPlugin := (Panel = nil);
miPlugins.Checked := (Panel = nil);
miGraphics.Checked := (Panel = pnlImage);
miEncoding.Visible := (Panel = nil) or (Panel = pnlText) or (Panel = pnlCode);