mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-27 21:00:23 +02:00
Added cleanup code for keyboard tables
git-svn-id: trunk@4731 -
This commit is contained in:
parent
053ea37be4
commit
9077473f14
@ -1939,6 +1939,40 @@ begin
|
|||||||
end;
|
end;
|
||||||
{$ENDIF}
|
{$ENDIF}
|
||||||
|
|
||||||
|
{------------------------------------------------------------------------------
|
||||||
|
Procedure: DoneKeyboardTables
|
||||||
|
Params: none
|
||||||
|
Returns: none
|
||||||
|
|
||||||
|
Frees the dynamic keyboard tables
|
||||||
|
------------------------------------------------------------------------------}
|
||||||
|
procedure DoneKeyboardTables;
|
||||||
|
var
|
||||||
|
n1, n2, n3: Byte;
|
||||||
|
K1: PVKeyArray1;
|
||||||
|
K2: PVKeyArray2;
|
||||||
|
K3: PVKeyArray3;
|
||||||
|
begin
|
||||||
|
for n3 := 0 to 255 do
|
||||||
|
begin
|
||||||
|
K3 := MKeySymToVK[n3];
|
||||||
|
if K3 = nil then Continue;
|
||||||
|
for n2 := 0 to 255 do
|
||||||
|
begin
|
||||||
|
K2 := K3^[n2];
|
||||||
|
if K2 = nil then Continue;
|
||||||
|
for n1 := 0 to 255 do
|
||||||
|
begin
|
||||||
|
K1 := K2^[n1];
|
||||||
|
if K1 = nil then Continue;
|
||||||
|
Dispose(K1);
|
||||||
|
end;
|
||||||
|
Dispose(K2);
|
||||||
|
end;
|
||||||
|
Dispose(K3);
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
|
||||||
{------------------------------------------------------------------------------
|
{------------------------------------------------------------------------------
|
||||||
Function: CharToVKandFlags
|
Function: CharToVKandFlags
|
||||||
Params: AChar: A character to translate
|
Params: AChar: A character to translate
|
||||||
@ -5484,6 +5518,9 @@ end;
|
|||||||
{ =============================================================================
|
{ =============================================================================
|
||||||
|
|
||||||
$Log$
|
$Log$
|
||||||
|
Revision 1.222 2003/10/24 21:28:16 marc
|
||||||
|
Added cleanup code for keyboard tables
|
||||||
|
|
||||||
Revision 1.221 2003/10/22 20:37:31 ajgenius
|
Revision 1.221 2003/10/22 20:37:31 ajgenius
|
||||||
fix accel group test to remove GTK2 warnings
|
fix accel group test to remove GTK2 warnings
|
||||||
|
|
||||||
|
@ -337,6 +337,7 @@ type
|
|||||||
end;
|
end;
|
||||||
|
|
||||||
procedure InitKeyboardTables;
|
procedure InitKeyboardTables;
|
||||||
|
procedure DoneKeyboardTables;
|
||||||
function CharToVKandFlags(const AChar: Char): Word;
|
function CharToVKandFlags(const AChar: Char): Word;
|
||||||
function GetVKeyInfo(const AVKey: Byte): TVKeyInfo;
|
function GetVKeyInfo(const AVKey: Byte): TVKeyInfo;
|
||||||
function IsToggleKey(const AVKey: Byte): Boolean;
|
function IsToggleKey(const AVKey: Byte): Boolean;
|
||||||
@ -741,5 +742,7 @@ finalization
|
|||||||
|
|
||||||
GdkTrapCalls := 0;
|
GdkTrapCalls := 0;
|
||||||
EndGDKErrorTrap;
|
EndGDKErrorTrap;
|
||||||
|
|
||||||
|
DoneKeyboardTables;
|
||||||
end.
|
end.
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user