Recent

Author Topic: Taskbar hiding with fsSystemStayOnTop  (Read 681 times)

caiov1n1c1us

  • New Member
  • *
  • Posts: 14
Taskbar hiding with fsSystemStayOnTop
« on: March 31, 2024, 11:24:26 pm »
Hi guys!

I'm doing a kind of bar that needs to be always on top and always positioned in front of the taskbar.

The property "fsSystemStayOnTop" works fine, but when I click on the taskbar (any part of it) the TForm goes behind the taskbar as you can see in the image below.

Is there anyway to detect this behavior and bring back the Form/Bar to the top again?

I tried "OnDeactivate" and "OnHide" and it didn't work.

Thanks!

furious programming

  • Hero Member
  • *****
  • Posts: 862
Re: Taskbar hiding with fsSystemStayOnTop
« Reply #1 on: April 01, 2024, 01:05:26 pm »
Try handling the WM_WINDOWPOSCHANGING message and bring the window to the top of all windows. The BringWindowToTop function should do the job.
« Last Edit: April 01, 2024, 01:08:34 pm by furious programming »
Lazarus 3.2 with FPC 3.2.2, Windows 10 — all 64-bit

Working solo on an acrade, action/adventure game in retro style (pixelart), programming the engine and shell from scratch, using Free Pascal and SDL. Release planned in 2026.

 

TinyPortal © 2005-2018