www.pudn.com > d4psp31.zip > fmBar.pas, change:1998-07-01,size:1316b


unit fmBar; 
 
interface 
 
uses 
  Windows, Messages, SysUtils, Classes, Graphics, Controls, Forms, Dialogs, 
  fmPower, Buttons, ExtCtrls, cmpTimerSpeedButton; 
 
type 
  TBarForm = class(TPowerForm) 
    LStretcher: TTimerSpeedButton; 
    RStretcher: TTimerSpeedButton; 
    procedure FormShow(Sender: TObject); 
    procedure FormResize(Sender: TObject); 
  private 
    procedure AdjustHeader; 
  public 
    procedure Notify (tp : TActiveFormNotify); override; 
 
  end; 
 
var 
  BarForm: TBarForm; 
 
implementation 
 
{$R *.DFM} 
 
(*-------------------------------------------------------------------- 
 | 
 |                                                                    | 
 | 
 |                                                                    | 
 | Parameters                                                         | 
 | 
 | The function returns 
 *--------------------------------------------------------------------*) 
procedure TBarForm.AdjustHeader; 
begin 
  RStretcher.Left := ClientWidth - RStretcher.Width * 2 - 2; 
end; 
 
procedure TBarForm.Notify (tp : TActiveFormNotify); 
begin 
end; 
 
procedure TBarForm.FormShow(Sender: TObject); 
begin 
  inherited; 
  AdjustHeader 
end; 
 
procedure TBarForm.FormResize(Sender: TObject); 
begin 
  inherited; 
  AdjustHeader; 
end; 
 
end.