mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-19 16:40:54 +02:00
Fixes wince memo text change
git-svn-id: trunk@21286 -
This commit is contained in:
parent
ae18dd25ea
commit
3dcceaa569
@ -16,7 +16,7 @@ TWinCEMemoStrings = class(TStrings)
|
|||||||
function GetCount: integer; override;
|
function GetCount: integer; override;
|
||||||
function Get(Index : Integer) : string; override;
|
function Get(Index : Integer) : string; override;
|
||||||
//procedure SetSorted(Val : boolean); virtual;
|
//procedure SetSorted(Val : boolean); virtual;
|
||||||
procedure SetUpdateState(Updating: Boolean); override;
|
procedure SetUpdateState(Updating: Boolean); override;
|
||||||
public
|
public
|
||||||
constructor Create(Handle: HWND; TheOwner: TWinControl);
|
constructor Create(Handle: HWND; TheOwner: TWinControl);
|
||||||
destructor Destroy; override;
|
destructor Destroy; override;
|
||||||
@ -24,7 +24,7 @@ TWinCEMemoStrings = class(TStrings)
|
|||||||
procedure Clear; override;
|
procedure Clear; override;
|
||||||
procedure Delete(Index : integer); override;
|
procedure Delete(Index : integer); override;
|
||||||
procedure Insert(Index : integer; const S: string); override;
|
procedure Insert(Index : integer; const S: string); override;
|
||||||
procedure SetText(TheText: PChar); override;
|
procedure SetTextStr(const Value: string); override;
|
||||||
//procedure Sort; virtual;
|
//procedure Sort; virtual;
|
||||||
public
|
public
|
||||||
//property Sorted: boolean read FSorted write SetSorted;
|
//property Sorted: boolean read FSorted write SetSorted;
|
||||||
@ -148,9 +148,17 @@ begin
|
|||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TWinCEMemoStrings.SetText(TheText: PChar);
|
procedure TWinCEMemoStrings.SetTextStr(const Value: string);
|
||||||
|
var
|
||||||
|
Msg: TLMessage;
|
||||||
begin
|
begin
|
||||||
Windows.SetWindowTextW(fHandle, PWideChar(Utf8Decode(TheText)))
|
if (Value <> Text) then
|
||||||
|
begin
|
||||||
|
Windows.SetWindowTextW(fHandle, PWideChar(Utf8Decode(Value)));
|
||||||
|
FillChar(Msg, SizeOf(Msg), 0);
|
||||||
|
Msg.Msg := CM_TEXTCHANGED;
|
||||||
|
DeliverMessage(Owner, Msg);
|
||||||
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
{$ENDIF}
|
{$ENDIF}
|
||||||
|
@ -34,7 +34,7 @@ uses
|
|||||||
{$ifdef Win32}win32compat,{$endif}
|
{$ifdef Win32}win32compat,{$endif}
|
||||||
// RTL, FCL, LCL
|
// RTL, FCL, LCL
|
||||||
SysUtils, LCLType, Classes, StdCtrls, Controls, Graphics, Forms, WinCEProc,
|
SysUtils, LCLType, Classes, StdCtrls, Controls, Graphics, Forms, WinCEProc,
|
||||||
InterfaceBase,
|
InterfaceBase, LMessages, LCLMessageGlue,
|
||||||
// Widgetset
|
// Widgetset
|
||||||
WSControls, WSStdCtrls, WSLCLClasses, WinCEInt, WinCEWSControls, WinCEExtra,
|
WSControls, WSStdCtrls, WSLCLClasses, WinCEInt, WinCEWSControls, WinCEExtra,
|
||||||
WSProc;
|
WSProc;
|
||||||
|
Loading…
Reference in New Issue
Block a user