Deprecates IntfSendsUTF8KeyPress in favor of GetLCLCapability(lcSendsUTF8KeyPress)

git-svn-id: trunk@33862 -
This commit is contained in:
sekelsenmat 2011-11-30 09:19:10 +00:00
parent 6354fb85b9
commit 2c0508fb0b
4 changed files with 8 additions and 4 deletions

View File

@ -96,6 +96,9 @@ begin
lcModalWindow,
lcReceivesLMClearCutCopyPasteReliably:
Result := LCL_CAPABILITY_YES;
lcSendsUTF8KeyPress:
if IntfSendsUTF8KeyPress() then Result := LCL_CAPABILITY_YES
else Result := LCL_CAPABILITY_NO;
else
Result := LCL_CAPABILITY_NO;
end;

View File

@ -68,7 +68,7 @@ procedure DrawGrid(DC: HDC; const R: TRect; DX, DY: Integer); {$IFDEF IF_BASE_ME
function ExtUTF8Out(DC: HDC; X, Y: Integer; Options: Longint; Rect: PRect; Str: PChar; Count: Longint; Dx: PInteger): Boolean; {$IFDEF IF_BASE_MEMBER}virtual;{$ENDIF}
function FontCanUTF8(Font: HFont): boolean; {$IFDEF IF_BASE_MEMBER}virtual; deprecated;{$ENDIF}
function FontCanUTF8(Font: HFont): boolean; {$IFDEF IF_BASE_MEMBER}virtual;{$ENDIF} deprecated;
function FontIsMonoSpace(Font: HFont): boolean; {$IFDEF IF_BASE_MEMBER}virtual;{$ENDIF}
function Frame(DC: HDC; const ARect: TRect): Integer; {$IFDEF IF_BASE_MEMBER}virtual;{$ENDIF}
function Frame3d(DC: HDC; var ARect: TRect; const FrameWidth : integer; const Style : TGraphicsBevelCut): Boolean; {$IFDEF IF_BASE_MEMBER}virtual;{$ENDIF}
@ -86,7 +86,7 @@ function GetScrollBarSize(Handle: HWND; SBStyle: Integer): integer; {$IFDEF IF_B
function GetScrollbarVisible(Handle: HWND; SBStyle: Integer): boolean; {$IFDEF IF_BASE_MEMBER}virtual;{$ENDIF}
function GetWindowRelativePosition(Handle : hwnd; var Left, Top: integer): boolean; {$IFDEF IF_BASE_MEMBER}virtual;{$ENDIF}
function IntfSendsUTF8KeyPress: Boolean; {$IFDEF IF_BASE_MEMBER}virtual;{$ENDIF}
function IntfSendsUTF8KeyPress: Boolean; {$IFDEF IF_BASE_MEMBER}virtual;{$ENDIF} deprecated;
function InvalidateFrame(aHandle : HWND; ARect : pRect; bErase : Boolean; BorderWidth: integer) : Boolean; {$IFDEF IF_BASE_MEMBER}virtual;{$ENDIF}
function IsDesignerDC(WindowHandle: HWND; DC: HDC): Boolean; {$IFDEF IF_BASE_MEMBER}virtual;{$ENDIF}

View File

@ -7016,7 +7016,7 @@ var
c: TUTF8Char;
begin
//debugln('TWinControl.CNChar B ',DbgSName(Self),' ',dbgs(Message.CharCode),' ',dbgs(IntfSendsUTF8KeyPress));
if not IntfSendsUTF8KeyPress then
if Widgetset.GetLCLCapability(lcSendsUTF8KeyPress) = LCL_CAPABILITY_NO then
begin
// current interface does not (yet) send UTF8 key press notifications
// -> emulate

View File

@ -83,7 +83,8 @@ type
lcAntialiasingEnabledByDefault,
// is amDontCare = amOn for the widgetset
lcLMHelpSupport, // support for LM_HELP command
lcReceivesLMClearCutCopyPasteReliably // In Carbon we do not receive LM_CLEAR, CUT, COPY, PASTE, etc reliably, and this affects DB controls. See bug http://bugs.freepascal.org/view.php?id=20394
lcReceivesLMClearCutCopyPasteReliably, // In Carbon we do not receive LM_CLEAR, CUT, COPY, PASTE, etc reliably, and this affects DB controls. See bug http://bugs.freepascal.org/view.php?id=20394
lcSendsUTF8KeyPress // If the interface does not yet send UTF8KeyPress directly, then it will be emulated in TWinControl.CNChar
);
{ TDialogButton }