[Lazarus] WMEnterSizeMove Messages not firing

Aradeonas aradeonas at operamail.com
Thu Oct 8 16:01:31 CEST 2015


Hi,

Just tested this code and only WMMove works and WMEnterSizeMove doesn't.
It simply works in Delphi. Why?
> unit Unit1;
>
> {$mode objfpc}{$H+}
>
> interface
>
> uses  Classes, SysUtils, FileUtil, Forms, Controls, Graphics, Dialogs,
> Messages;
>
> type
>
> { TForm1 }
>
> TForm1 = class(TForm)  private  public    procedure
> WMEnterSizeMove(var Message: TMessage); message WM_ENTERSIZEMOVE;
> procedure WMMove(var Message: TMessage); message WM_MOVE;    procedure
> WMExitSizeMove(var Message: TMessage); message WM_EXITSIZEMOVE;  end;
>
> var  Form1: TForm1;
>
> implementation
>
> {$R *.lfm}
>
> { TForm1 }
>
> procedure TForm1.WMEnterSizeMove(var Message: TMessage); begin
> Caption := 'Move / resize started'; end; (*WMEnterSizeMove*)
>
> procedure TForm1.WMMove(var Message: TMessage); begin  Caption :=
> Format('Form is being moved. Client area x: %d, y:%d',
> [TWMMove(Message).XPos, TWMMove(Message).YPos]); end; (*WMMove*)
>
> procedure TForm1.WMExitSizeMove(var Message: TMessage); begin
> ShowMessage('Move / resize complete!'); end; (*WMExitSizeMove*)
>
> end.
>

Regards, Ara

-- 
http://www.fastmail.com - Accessible with your email software
                          or over the web

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.lazarus-ide.org/pipermail/lazarus/attachments/20151008/09976b42/attachment-0002.html>


More information about the Lazarus mailing list