unit UnitFrmDatabaseUpdate;

interface

uses
  Winapi.Windows, Winapi.Messages, System.SysUtils, System.Variants, System.Classes, Vcl.Graphics,
  Vcl.Controls, Vcl.Forms, Vcl.Dialogs, Vcl.StdCtrls, Vcl.ExtCtrls;

type
  TfrmDatabaseUpdate = class(TForm)
    timAutoShow: TTimer;
    Label1: TLabel;

  private
    { Private declarations }
  public
    { Public declarations }
    procedure MyShow;
    procedure MyHide;
  end;

var
  frmDatabaseUpdate: TfrmDatabaseUpdate;

implementation

{$R *.dfm}

uses UnitMisc, UnitFocusManager;

procedure TfrmDatabaseUpdate.MyShow;
begin
    if not self.Visible then begin
        TFocusManager.ForceForeground(Application.Handle);
        self.Show;
        TFocusManager.ForceForeground(self.Handle);
        Application.ProcessMessages;
    end;
end;
procedure TfrmDatabaseUpdate.MyHide;
begin
    self.Hide;
end;



end.
