mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-11 17:16:01 +02:00
lcl: some work on TCustomMemo.WantReturns (part of issue #0022732). The memo already calls default action but still not eat a key
git-svn-id: trunk@41659 -
This commit is contained in:
parent
f03b51d173
commit
915f42b9b9
@ -227,7 +227,7 @@ end;
|
|||||||
{------------------------------------------------------------------------------
|
{------------------------------------------------------------------------------
|
||||||
procedure TCustomMemo.SetScrollbars(const Value : TScrollStyle);
|
procedure TCustomMemo.SetScrollbars(const Value : TScrollStyle);
|
||||||
------------------------------------------------------------------------------}
|
------------------------------------------------------------------------------}
|
||||||
procedure TCustomMemo.SetScrollbars(const Value: TScrollStyle);
|
procedure TCustomMemo.SetScrollBars(const Value: TScrollStyle);
|
||||||
begin
|
begin
|
||||||
if Value <> FScrollbars then begin
|
if Value <> FScrollbars then begin
|
||||||
FScrollbars:= Value;
|
FScrollbars:= Value;
|
||||||
@ -260,6 +260,16 @@ begin
|
|||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
procedure TCustomMemo.WMGetDlgCode(var Message: TLMNoParams);
|
||||||
|
begin
|
||||||
|
inherited;
|
||||||
|
Message.Result := Message.Result and not (DLGC_WANTTAB or DLGC_WANTALLKEYS);
|
||||||
|
if WantTabs then
|
||||||
|
Message.Result := Message.Result or DLGC_WANTTAB;
|
||||||
|
if WantReturns then
|
||||||
|
Message.Result := Message.Result or DLGC_WANTALLKEYS;
|
||||||
|
end;
|
||||||
|
|
||||||
class function TCustomMemo.GetControlClassDefaultSize: TSize;
|
class function TCustomMemo.GetControlClassDefaultSize: TSize;
|
||||||
begin
|
begin
|
||||||
Result.CX := 150;
|
Result.CX := 150;
|
||||||
|
@ -820,6 +820,7 @@ type
|
|||||||
procedure SetScrollBars(const Value: TScrollStyle);
|
procedure SetScrollBars(const Value: TScrollStyle);
|
||||||
procedure Loaded; override;
|
procedure Loaded; override;
|
||||||
procedure CMWantSpecialKey(var Message: TCMWantSpecialKey); message CM_WANTSPECIALKEY;
|
procedure CMWantSpecialKey(var Message: TCMWantSpecialKey); message CM_WANTSPECIALKEY;
|
||||||
|
procedure WMGetDlgCode(var Message: TLMNoParams); message LM_GETDLGCODE;
|
||||||
class function GetControlClassDefaultSize: TSize; override;
|
class function GetControlClassDefaultSize: TSize; override;
|
||||||
public
|
public
|
||||||
constructor Create(AOwner: TComponent); override;
|
constructor Create(AOwner: TComponent); override;
|
||||||
|
Loading…
Reference in New Issue
Block a user