-
Notifications
You must be signed in to change notification settings - Fork 3
/
EliteBindingsTools.pas
3866 lines (3410 loc) · 125 KB
/
EliteBindingsTools.pas
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
{*******************************************************}
{ }
{ MaxiDonkey Library }
{ }
{ Elite Dangerous Functions interface }
{ Bindings tools for Custom.3.0.Binds }
{ }
{ 08/2020 - copyleft }
{ }
{*******************************************************}
{...............................................................................
1/ FONCTION NON IMPLEMENTEES
MouseReset YawToRollButton
UseAlternateFlightValuesToggle HMDReset
MicrophoneMute UIFocus
ShowPGScoreSummaryInput HeadLookToggle
UI_Toggle HeadLookReset
HeadLookPitchUp HeadLookPitchDown
HeadLookYawLeft HeadLookYawRight
CamTranslateZHold UIFocus_Buggy
HeadLookToggle_Buggy FreeCamToggleHUD
FreeCamSpeedInc FreeCamSpeedDec
ToggleReverseThrottleInputFreeCam MoveFreeCamForward
MoveFreeCamBackwards MoveFreeCamRight
MoveFreeCamLeft MoveFreeCamUp
MoveFreeCamDown PitchCameraUp
PitchCameraDown YawCameraLeft
YawCameraRight RollCameraLeft
RollCameraRight ToggleRotationLock
FixCameraRelativeToggle FixCameraWorldToggle
QuitCamera ToggleAdvanceMode
FreeCamZoomIn FreeCamZoomOut
FStopDec FStopInc
StoreEnableRotation StoreCamZoomIn
StoreCamZoomOut StoreToggle
CommanderCreator_Undo CommanderCreator_Redo
CommanderCreator_Rotation_MouseToggle
2/ Display managed functions by code
. KeyInventory.CatalogTxt : return a string with keys combination code
associated to the functions.
Example : BackwardKey=165000335 for keys combination "Key_RightAlt + Key_O"
VkKeyScan( Key_Right ) = 165
VkKeyScan( Key_O ) = 335
3/ Call function by function name
. KeyInventory.KeyTrigger_( function_name , WITH_KEYUP/WITHOUT_KEYUP)
Example : KeyInventory.KeyTrigger_( PrimaryFire , WITH_KEYUP)
4/ Instantiation
. Create -->
TKeyMessageSender.Initialize;
. Show -->
try
TKeyInventory.Initialize;
except
on E:Exception do begin
MessageDlg(E.Message, mtWarning, [mbOK], 0);
Application.Terminate;
end
end;
5/ Finalization
. Destroy -->
TKeyInventory.Finalize;
TKeyMessageSender.Finalize;
6/ Operating mechanism
. Copy ...Elite...Options\Bindings\Custom.3.0.binds
to ...App..\Temp.Custom.3.0.binds
Extract from xml file functions and keys combinations
if changes are made to Temp.Custom.3.0.binds then a copy of this file is
send to ...Elite...Options\Bindings\Custom.3.0.binds
...............................................................................}
unit EliteBindingsTools;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, ExtCtrls, StdCtrls, Math,
{Spec}
uRegistry, StrCopyUtils;
const
KEYEVENTF_KEYDOWN = 0;
WITH_KEYUP = True;
WITHOUT_KEYUP = False;
SHELL_ACCES = 'Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders'; //Registry key
SAVE_GAMES_KEY = '{4C5C32FF-BB9D-43B0-B5B4-2D72E54EAAA4}'; //Registry key
BINDING_OPT_KEY = 'Local AppData';
LOCAL_SAVE = 'SaveBindigs';
TEMP_CUSTOM_FILE = 'Temp.Custom.3.0.binds';
CUSTOM_FILE = 'Custom.3.0.binds';
START_PRESET = 'StartPreset.start';
DISPLAY_SETTINGS = 'DisplaySettings.xml';
var
SavedGamesW : string = 'Frontier Developments\Elite Dangerous';
BindingsFolder : string = 'Frontier Developments\Elite Dangerous\Options\Bindings';
GraphicsFolder : string = 'Frontier Developments\Elite Dangerous\Options\Graphics';
function GetFrontierSaveGames: string;
function GetEliteBindingsFolder: string;
function GetEliteGraphicsFolder: string;
function EncodeKey(const Key, Mod1, Mod2: Word): Cardinal; overload;
function EncodeKey(const Key, Mod1, Mod2: string): Cardinal; overload;
const
{$EXTERNALSYM MOUSEEVENTF_XDOWN}
MOUSEEVENTF_XDOWN = $0080;
{$EXTERNALSYM MOUSEEVENTF_XUP}
MOUSEEVENTF_XUP = $0100;
XBUTTON1 = $0001;
XBUTTON2 = $0002;
var
ELITE_CLASS : string = 'FrontierDevelopmentsAppWinClass';
function ExtractBalises(const Src: string; Full: Boolean):string;
{*** VOL - ROTATION; 17-63}
type
TVolRotationType =
( vrt_yawleft, vrt_yawright,
vrt_rollleft, vrt_rollright,
vrt_pitchleft, vrt_pitchright );
TVolRotationArea = 0..Integer(High(TVolRotationType));
TArrayVolRotation = array[TVolRotationArea] of string;
var
VolRotation : TArrayVolRotation = (
'YawLeftButton', 'YawRightButton',
'RollLeftButton', 'RollRightButton',
'PitchUpButton', 'PitchDownButton'
);
function GetVolRotation(const Value: string):TVolRotationType;
function IsVolRotation(const Value: string):Boolean;
{*** VOL - POUSSEE; 64-115}
type
TVolPousseType =
( vpt_thrustleft, vpt_thrustright,
vpt_thrustup, vpt_thrustdown,
vpt_thrustforward, vpt_thrustbackward );
TVolPousseArea = 0..Integer(high(TVolPousseType));
TArrayVolPousse = array[TVolPousseArea] of string;
var
VolPoussee : TArrayVolPousse = (
'LeftThrustButton', 'RightThrustButton',
'UpThrustButton', 'DownThrustButton',
'ForwardThrustButton', 'BackwardThrustButton'
);
function GetVolPousee(const Value: string): TVolPousseType;
function IsVolPousee(const Value: string):Boolean;
{*** VOL - PROPULSION; 146-225}
type
TVolPropulsionType =
( vlt_reverse,
vlt_forward, vlt_backward,
vlt_speedmin100, vlt_speedmin75, vlt_speedmin50, vlt_speedmin25,
vlt_speedzero,
vlt_speed25, vlt_speed50, vlt_speed75, vlt_speed100 );
TVolPropulsionArea = 0..Integer(high(TVolPropulsionType));
TArrayVolPropulsion = array[TVolPropulsionArea] of string;
var
VolPropulsion : TArrayVolPropulsion =
( 'ToggleReverseThrottleInput',
'ForwardKey', 'BackwardKey',
'SetSpeedMinus100', 'SetSpeedMinus75', 'SetSpeedMinus50', 'SetSpeedMinus25',
'SetSpeedZero',
'SetSpeed25', 'SetSpeed50', 'SetSpeed75', 'SetSpeed100'
);
function GetVolPropulsion(const Value: string): TVolPropulsionType;
function IsVolPropulsion(const Value: string):Boolean;
{*** VOL - DIVERS; 305-348}
type
TVolDiversType =
( vdt_flightassist, vdt_boost,
vdt_hypersuper, vdt_supercruise, vdt_hyperspace,
vdt_rotationcorrect, vdt_orbitlines );
TVolDiversArea = 0..Integer(high(TVolDiversType));
TArrayVolDivers = array[TVolDiversArea] of string;
var
VolDivers : TArrayVolDivers =
( 'ToggleFlightAssist', 'UseBoostJuice',
'HyperSuperCombination', 'Supercruise', 'Hyperspace',
'DisableRotationCorrectToggle', 'OrbitLinesToggle'
);
function GetVolDivers(const Value: string): TVolDiversType;
function IsVolDivers(const Value: string):Boolean;
{*** VISEE; 349-432}
type
TViseeType =
( vt_selecttarget, vt_nexttarget, vt_previoustarget,
vt_highestthreat, vt_nexthostile, vt_previoushostile,
vt_wingman0, vt_wingman1, vt_wingman2,
vt_wingmantarget, vt_navlock,
vt_nextsubsystem, vt_prevuoissubsystem, vt_nextroute );
TViseeArea = 0..Integer(high(TViseeType));
TArrayVisee = array[TViseeArea] of string;
var
Visee : TArrayVisee =
( 'SelectTarget', 'CycleNextTarget', 'CyclePreviousTarget',
'SelectHighestThreat', 'CycleNextHostileTarget', 'CyclePreviousHostileTarget',
'TargetWingman0', 'TargetWingman1', 'TargetWingman2',
'SelectTargetsTarget', 'WingNavLock',
'CycleNextSubsystem', 'CyclePreviousSubsystem', 'TargetNextRouteSystem'
);
function GetVisee(const Value: string): TViseeType;
function IsVisee(const Value: string):Boolean;
{*** ARMES; 433-459}
type
TArmesType =
( at_primary, at_secondary,
at_groupnext, at_groupprevious, at_hardpoint );
TArmesArea = 0..Integer(high(TArmesType));
TArrayArmes = array[TArmesArea] of string;
var
Armes : TArrayArmes =
( 'PrimaryFire', 'SecondaryFire',
'CycleFireGroupNext', 'CycleFireGroupPrevious', 'DeployHardpointToggle'
);
function GetArmes(const Value: string): TArmesType;
function IsArmes(const Value: string):Boolean;
{*** REFROIDISSEMENT; 460-472}
type
TFreezeType = ( ft_stealthy, ft_heatsink );
TFreezeArea = 0..Integer(high(TFreezeType));
TArrayFreeze = array[TFreezeArea] of string;
var
Freeze : TArrayFreeze =
( 'ToggleButtonUpInput', 'DeployHeatSink' );
function GetFreeze(const Value: string): TFreezeType;
function IsFreeze(const Value: string):Boolean;
{*** DIVERS; 473-590}
type
TDiversType =
( dt_spotlight, dt_increaserange, dt_decreaserange,
dt_powerengine, dt_powerweapon, dt_powersystem, dt_powerreset,
dt_cargoscoop, dt_ejectcargo, dt_landinggear,
dt_shielcell, dt_firechaft, dt_chargeecm,
dt_colorweapon, dt_colorengine, dt_nightvision
);
TDiversArea = 0..Integer(high(TDiversType));
TArrayDivers = array[TDiversArea] of string;
var
Divers : TArrayDivers =
( 'ShipSpotLightToggle', 'RadarIncreaseRange', 'RadarDecreaseRange',
'IncreaseEnginesPower', 'IncreaseWeaponsPower', 'IncreaseSystemsPower', 'ResetPowerDistribution',
'ToggleCargoScoop', 'EjectAllCargo', 'LandingGearToggle',
'UseShieldCell', 'FireChaffLauncher', 'ChargeECM',
'WeaponColourToggle', 'EngineColourToggle', 'NightVisionToggle'
);
function GetDivers(const Value: string): TDiversType;
function IsDivers(const Value: string):Boolean;
{*** CHANGEMENT DE MODE; 591-688}
type
TModeChangetype =
( mct_panelleft, mct_paneltop, mct_quickcom,
mct_panelbottom, mct_panelright,
mct_galaxymap, mct_systemmap,
mct_pause, mct_friend,
mct_codex,
mct_hudmode, mct_explorationfss );
TModeChangeArea = 0..Integer(high(TModeChangetype));
TArrayModeChange = array[TModeChangeArea] of string;
var
ModeChange : TArrayModeChange =
( 'FocusLeftPanel', 'FocusCommsPanel', 'QuickCommsPanel',
'FocusRadarPanel', 'FocusRightPanel',
'GalaxyMapOpen', 'SystemMapOpen',
'Pause', 'FriendsMenu',
'OpenCodexGoToDiscovery',
'PlayerHUDModeToggle', 'ExplorationFSSEnter'
);
function GetModeChange(const Value: string): TModeChangetype;
function IsModeChange(const Value: string):Boolean;
{*** MODE TABLEAU DE BORD; 689-732}
type
TModeBoardType =
( mb_up, mb_down, mb_left, mb_right, mb_select,
mb_back, mb_nextpanel, mb_previouspanel, mb_nextpage, mb_previouspage
);
TModeBoardArea = 0..Integer(high(TModeBoardType));
TArrayModeBoard = array[TModeBoardArea] of string;
var
ModeBoard : TArrayModeBoard =
( 'UI_Up', 'UI_Down', 'UI_Left', 'UI_Right', 'UI_Select',
'UI_Back', 'CycleNextPanel', 'CyclePreviousPanel', 'CycleNextPage', 'CyclePreviousPage'
);
function GetModeBoard(const Value: string): TModeBoardType;
function IsModeBoard(const Value: string):Boolean;
{*** CONDUITE; 862-968}
type
TConduiteType =
( ct_driveassist, ct_steerleft, ct_steerright, ct_rollleft, ct_rollright,
ct_pichup, ct_pichdown, ct_verticalthruster, ct_fireprimary, ct_firesecondary,
ct_autobreak, ct_vrslight, ct_turret, ct_groupnext, ct_groupprevious );
TConduiteArea = 0..Integer(high(TConduiteType));
TArrayConduite = array[TConduiteArea] of string;
var
Conduite : TArrayConduite =
( 'ToggleDriveAssist', 'SteerLeftButton', 'SteerRightButton', 'BuggyRollLeftButton', 'BuggyRollRightButton',
'BuggyPitchUpButton', 'BuggyPitchDownButton', 'VerticalThrustersButton', 'BuggyPrimaryFireButton', 'BuggySecondaryFireButton',
'AutoBreakBuggyButton', 'HeadlightsBuggyButton', 'ToggleBuggyTurretButton', 'BuggyCycleFireGroupNext', 'BuggyCycleFireGroupPrevious'
);
function GetConduite(const Value: string): TConduiteType;
function IsConduite(const Value: string):Boolean;
{*** CONDUITE VISEEE; 969-974}
type
TConduiteViseeType = ( cvt_buggyselecttarget );
TConduiteViseeArea = 0..Integer(high(TConduiteViseeType));
TArrayConduiteVisee = array[TConduiteViseeArea] of string;
var
ConduiteVisee : TArrayConduiteVisee =
( 'SelectTarget_Buggy' );
function GetConduiteVisee(const Value: string): TConduiteViseeType;
function IsConduiteVisee(const Value: string):Boolean;
{*** CONDUITE TOURELLE; 975-1019}
type
TConduiteTurretType =
( ctt_turretyawleft, ctt_turretyawright,
ctt_turretpichup, ctt_turretpichdown );
TConduiteTurretArea = 0..Integer(high(TConduiteTurretType));
TArrayConduiteTurret = array[TConduiteTurretArea] of string;
var
ConduiteTurret : TArrayConduiteTurret =
( 'BuggyTurretYawLeftButton', 'BuggyTurretYawRightButton',
'BuggyTurretPitchUpButton', 'BuggyTurretPitchDownButton'
);
function GetConduiteTurret(const Value: string): TConduiteTurretType;
function IsConduiteTurret(const Value: string):Boolean;
{*** CONDUITE PROPULSION; 1020-1055}
type
TConduitePropulsionType =
( cpt_buggyreverse, cpt_increasespeed, cpt_decreasespeed );
TConduitePropulsionArea = 0..Integer(high(TConduitePropulsionType));
TArrayConduitePropulsion = array[TConduitePropulsionArea] of string;
var
ConduitePropulsion : TArrayConduitePropulsion =
( 'BuggyToggleReverseThrottleInput',
'IncreaseSpeedButtonMax',
'DecreaseSpeedButtonMax'
);
function GetConduitePropulsion(const Value: string): TConduitePropulsionType;
function IsConduitePropulsion(const Value: string):Boolean;
{*** CONDUITE DIVERS; 1056-1099}
type
TConduiteDiversType =
( cdt_buggypowerengine, cdt_buggypowerweapons,
cdt_buggypowersystem, cdt_buggypowerreset,
cdt_buggycargoscoop, cdt_buggyejectcargo,
cdt_buggyrecallship );
TConduiteDiversArea = 0..Integer(high(TConduiteDiversType));
TArrayConduiteDivers = array[TConduiteDiversArea] of string;
var
ConduiteDivers : TArrayConduiteDivers =
( 'IncreaseEnginesPower_Buggy', 'IncreaseWeaponsPower_Buggy',
'IncreaseSystemsPower_Buggy', 'ResetPowerDistribution_Buggy',
'ToggleCargoScoop_Buggy', 'EjectAllCargo_Buggy',
'RecallDismissShip'
);
function GetConduiteDivers(const Value: string): TConduiteDiversType;
function IsConduiteDivers(const Value: string):Boolean;
{*** CONDUITE MODES; 1100-1165}
type
TConduiteModeType =
( cmt_panelleft, cmt_panelTop,
cmt_quickcom,
cmt_panelbottom, cmt_panelright,
cmt_galaxymap, cmt_systemmap,
cmt_codex,
cmt_hudmode );
TConduiteModeArea = 0..Integer(high(TConduiteModeType));
TArrayConduiteMode = array[TConduiteModeArea] of string;
var
ConduiteMode : TArrayConduiteMode =
( 'FocusLeftPanel_Buggy', 'FocusCommsPanel_Buggy',
'QuickCommsPanel_Buggy',
'FocusRadarPanel_Buggy', 'FocusRightPanel_Buggy',
'GalaxyMapOpen_Buggy', 'SystemMapOpen_Buggy',
'OpenCodexGoToDiscovery_Buggy',
'PlayerHUDModeToggle_Buggy'
);
function GetConduiteMode(const Value: string): TConduiteModeType;
function IsConduiteMode(const Value: string):Boolean;
{*** ORDRES AU CHASSEUR; 1238-1290}
type
TChasseurOrderType =
( cot_requestdock,
cot_defensivebehaviour, cot_aggressivebehaviour,
cot_focustarget, cot_holdfire,
cot_holdpositon,
cot_follow, cot_openorders );
TChasseurOrderArea = 0..Integer(high(TChasseurOrderType));
TArrayChasseurOrder = array[TChasseurOrderArea] of string;
var
ChasseurOrder : TArrayChasseurOrder =
( 'OrderRequestDock',
'OrderDefensiveBehaviour', 'OrderAggressiveBehaviour',
'OrderFocusTarget', 'OrderHoldFire',
'OrderHoldPosition',
'OrderFollow', 'OpenOrders'
);
function GetChasseurOrder(const Value: string): TChasseurOrderType;
function IsChasseurOrder(const Value: string):Boolean;
{*** DETECTEUR D'ANALYSE COMPLETE DU SYSTEME; 1561-1659}
type
TExplorationFssType =
( eft_Campitchinc, eft_Campitchdec,
eft_Camyawinc, eft_Camyawdec,
eft_zoomin, eft_zoomout,
eft_minizoomin, eft_minizoomout,
eft_radioinc, eft_radiodec,
eft_discoveryscan, eft_quit,
eft_targetsibling, eft_help );
TExplorationFssArea = 0..Integer(high(TExplorationFssType));
TArrayExplorationFss = array[TExplorationFssArea] of string;
var
ExplorationFss : TArrayExplorationFss =
( 'ExplorationFSSCameraPitchIncreaseButton', 'ExplorationFSSCameraPitchDecreaseButton',
'ExplorationFSSCameraYawIncreaseButton', 'ExplorationFSSCameraYawDecreaseButton',
'ExplorationFSSZoomIn', 'ExplorationFSSZoomOut',
'ExplorationFSSMiniZoomIn', 'ExplorationFSSMiniZoomOut',
'ExplorationFSSRadioTuningX_Increase', 'ExplorationFSSRadioTuningX_Decrease',
'ExplorationFSSDiscoveryScan', 'ExplorationFSSQuit',
'ExplorationFSSTarget', 'ExplorationFSSShowHelp'
);
function GetExplorationFss(const Value: string): TExplorationFssType;
function IsExplorationFss(const Value: string):Boolean;
{*** DETECTEUR DE SURFACE DETAILLEE; 1660-1714}
type
TSurfaceDetailleeType =
( sdt_areaview, sdt_exit,
sdt_yawleft, sdt_yawright,
sdt_pitchleft, sdt_pitchright,
sdt_fovout, sdt_fovin );
TSurfaceDetailleeArea = 0..Integer(high(TSurfaceDetailleeType));
TArraySurfaceDetaillee = array[TSurfaceDetailleeArea] of string;
var
SurfaceDetaillee : TArraySurfaceDetaillee =
( 'ExplorationSAAChangeScannedAreaViewToggle', 'ExplorationSAAExitThirdPerson',
'SAAThirdPersonYawLeftButton', 'SAAThirdPersonYawRightButton',
'SAAThirdPersonPitchUpButton', 'SAAThirdPersonPitchDownButton',
'SAAThirdPersonFovOutButton', 'SAAThirdPersonFovInButton'
);
function GetSurfaceDetaillee(const Value: string): TSurfaceDetailleeType;
function IsSurfaceDetaillee(const Value: string):Boolean;
{*** VOL ATTERRISSAGE MANUEL 226-305}
type
TManualLandingType =
( mlt_yawleft, mlt_yawright, mlt_pitchup, mlt_pitdown,
mlt_rollleft, mlt_rollright, mlt_thrustleft, mlt_thrustright,
mlt_thrustup, mlt_thrustdown, mlt_thrustforward, mlt_thrustbackward );
TManualLandingArea = 0..Integer(high(TManualLandingType));
TArrayManualLanding = array[TManualLandingArea] of string;
var
ManualLanding : TArrayManualLanding =
( 'YawLeftButton_Landing', 'YawRightButton_Landing',
'PitchUpButton_Landing', 'PitchDownButton_Landing',
'RollLeftButton_Landing', 'RollRightButton_Landing',
'LeftThrustButton_Landing', 'RightThrustButton_Landing',
'UpThrustButton_Landing', 'DownThrustButton_Landing',
'ForwardThrustButton_Landing', 'BackwardThrustButton_Landing'
);
function GetManualLanding(const Value: string): TManualLandingType;
function IsManualLanding(const Value: string):Boolean;
{*** EQUIPAGE MULTIPLE 1186-1257}
type
TMultiCrewType =
( mcr_togglemode, mcr_primaryfire, mcr_secondaryfire,
mcr_primaryutility, mcr_secondaryutility, mcr_tpyawleft,
mcr_tpyawright, mcr_tppitchup, mcr_tppitchdown,
mcr_tpfovout, mcr_tpfovin, mcr_cockpituiforward,
mcr_cockpituibackward );
TMultiCrewArea = 0..Integer(high(TMultiCrewType));
TArrayMultiCrew = array[TMultiCrewArea] of string;
var
MultiCrew : TArrayMultiCrew =
( 'MultiCrewToggleMode', 'MultiCrewPrimaryFire',
'MultiCrewSecondaryFire', 'MultiCrewPrimaryUtilityFire',
'MultiCrewSecondaryUtilityFire', 'MultiCrewThirdPersonYawLeftButton',
'MultiCrewThirdPersonYawRightButton', 'MultiCrewThirdPersonPitchUpButton',
'MultiCrewThirdPersonPitchDownButton', 'MultiCrewThirdPersonFovOutButton',
'MultiCrewThirdPersonFovInButton', 'MultiCrewCockpitUICycleForward',
'MultiCrewCockpitUICycleBackward'
);
function GetMultiCrew(const Value: string): TMultiCrewType;
function IsMultiCrew(const Value: string):Boolean;
{*** CARTE DE LA GALAXIE 781-867}
type
TGalaxyMapType =
( gmt_campitchup, gmt_campitchdown, gmt_camyawleft,
gmt_camyawright, gmt_translateforward, gmt_translatebackward,
gmt_translateleft, gmt_translateright, gmt_translateup,
gmt_translatedown, gmt_camzoomin, gmt_camzoomout,
gmt_galawymaphome );
TGalaxyMapArea = 0..Integer(high(TGalaxyMapType));
TArrayGalaxyMap = array[TGalaxyMapArea] of string;
var
GalaxyMap : TArrayGalaxyMap =
( 'CamPitchUp', 'CamPitchDown',
'CamYawLeft', 'CamYawRight',
'CamTranslateForward', 'CamTranslateBackward',
'CamTranslateLeft', 'CamTranslateRight',
'CamTranslateUp', 'CamTranslateDown',
'CamZoomIn', 'CamZoomOut',
'GalaxyMapHome'
);
function GetGalaxyMap(const Value: string): TGalaxyMapType;
function IsGalaxyMap(const Value: string):Boolean;
{*** SYSTÈME DE CAMERAS 1311-1370}
type
TCamSystemType =
( cst_shipview, cst_crsview, cst_scrollleft, cst_scrollright,
cst_freecam, cst_camone, cst_camtwo, cst_camthree,
cst_camfour, cst_camfive, cst_camsix, cst_camseven,
cst_cameight, cst_camnine );
TCamSystemArea = 0..Integer(high(TCamSystemType));
TArrayCamSystem = array[TCamSystemArea] of string;
var
CamSystem : TArrayCamSystem =
( 'PhotoCameraToggle', 'PhotoCameraToggle_Buggy',
'VanityCameraScrollLeft', 'VanityCameraScrollRight',
'ToggleFreeCam', 'VanityCameraOne',
'VanityCameraTwo', 'VanityCameraThree',
'VanityCameraFour', 'VanityCameraFive',
'VanityCameraSix', 'VanityCameraSeven',
'VanityCameraEight', 'VanityCameraNine'
);
function GetCamSystem(const Value: string): TCamSystemType;
function IsCamSystem(const Value: string):Boolean;
{*** Liste de lecture 1564-1580}
type
TGalnetReaderType =
( grt_playpause, grt_skipforward, grt_skipbackward, grt_clearqueue );
TGalnetReaderArea = 0..Integer(high(TGalnetReaderType));
TArrayGalnetReader = array[TGalnetReaderArea] of string;
var
GalnetReader : TArrayGalnetReader =
( 'GalnetAudio_Play_Pause', 'GalnetAudio_SkipForward',
'GalnetAudio_SkipBackward', 'GalnetAudio_ClearQueue'
);
function GetGalnetReader(const Value: string): TGalnetReaderType;
function IsGalnetReader(const Value: string):Boolean;
{*** CAMERA LIBRE 1401-
}
type
TCamFreeType = (ToggleHud);
TCamFreeArea = 0..Integer(high(TCamFreeType));
TArrayCamFree = array[TCamFreeArea] of string;
var
CamFree : TArrayCamFree = ('FreeCamToggleHUD');
function GetCamFree(const Value: string): TCamFreeType;
function IsCamFree(const Value: string):Boolean;
{*** Managed categories resumed }
type
TBindCategoriesType =
( bct_volrotation, bct_volpousee, bct_volpropulsion,
bct_voldivers, bct_visee, bct_armes,
bct_freeze, bct_divers, bct_modechange,
bct_modeboard, bct_conduite, bct_conduitevisee,
bct_conduiteturret, bct_conduitepropulsion, bct_conduitedivers,
bct_conduitemode, bct_chasseurorder, bct_explorationfss,
bct_surfacedetaillee, bct_manuallanding, bct_multicrew,
bct_galaxymap, bct_camsystem, bct_galnetreader,
bct_camfree );
TBindCategoriesArea = 0..Integer(high(TBindCategoriesType));
TArrayOfBindCategories = array[TBindCategoriesArea] of string;
var
MCR : TArrayOfBindCategories =
( 'Vol rotation', 'Vol poussée', 'Vol propulsion',
'Vol divers', 'Visée', 'Armes',
'Refroisissement', 'Divers', 'Changement de mode',
'Tableau de bord', 'Conduite', 'Conduite visée',
'Conduite tourelle', 'Conduite propulsion', 'Conduite divers',
'Conduite modes', 'Ordres au chasseur', 'ACS',
'Détecteur de surface', 'Atterrissage manuel', 'Equipage multiple',
'Carte de la galaxie', 'Système de caméras', 'Liste de lecture',
'Camera libre'
);
function GetBindCategories(const Value: string): TBindCategoriesType;
function IsBindCategories(const Value: string):Boolean;
{*** Elite keys dedined }
type
TEliteKeyType =
( Key_A, Key_B, Key_C, Key_D,
Key_E, Key_F, Key_G, Key_H,
Key_I, Key_J, Key_K, Key_L,
Key_M, Key_N, Key_O, Key_P,
Key_Q, Key_R, Key_S, Key_T,
Key_U, Key_V, Key_W, Key_X,
Key_Y, Key_Z, Key_Space, Key_F1,
Key_F2, Key_F3, Key_F4, Key_F5,
Key_F6, Key_F7, Key_F8, Key_F9,
Key_F10, Key_F11, Key_F12, Key_Enter,
Key_RightArrow, Key_DownArrow, Key_LeftArrow, Key_UpArrow,
Key_Insert, Key_Delete, Key_Home, Key_End,
Key_PageUp, Key_PageDown, Key_ScrollLock, Key_Pause,
Key_Numpad_0, Key_Numpad_1, Key_Numpad_2, Key_Numpad_3,
Key_Numpad_4, Key_Numpad_5, Key_Numpad_6, Key_Numpad_7,
Key_Numpad_8, Key_Numpad_9, Key_NumLock, Key_Numpad_Divide,
Key_Numpad_Multiply, Key_Numpad_Subtract, Key_Numpad_Add, Key_Numpad_Enter,
Key_Numpad_Decimal, Key_CapsLock, Mouse_1, Mouse_2,
Mouse_3, Mouse_4, Mouse_5, Key_Tab,
Key_SuperscriptTwo, Key_Ampersand, Key_é, Key_DoubleQuote,
Key_Apostrophe, Key_LeftParenthesis, Key_Minus, Key_è,
Key_Underline, Key_ç, Key_à, Key_RightParenthesis,
Key_Equals, Key_Comma, Key_SemiColon, Key_Colon,
Key_ExclamationPoint, Key_ù, Key_Asterisk, Key_Circumflex,
Key_Dollar, Key_LessThan, Key_Apps, Key_Backspace,
Key_Echap, Key_LeftAlt, Key_RightAlt, Key_LeftControl,
Key_RightControl, Key_LeftShift, Key_RightShift );
TEliteKeysArea = 0..Integer(high(TEliteKeyType));
TArrayEliteKey = array[TEliteKeysArea] of string;
var
ArrayEliteKey : TArrayEliteKey =
('Key_A', 'Key_B', 'Key_C', 'Key_D',
'Key_E', 'Key_F', 'Key_G', 'Key_H',
'Key_I', 'Key_J', 'Key_K', 'Key_L',
'Key_M', 'Key_N', 'Key_O', 'Key_P',
'Key_Q', 'Key_R', 'Key_S', 'Key_T',
'Key_U', 'Key_V', 'Key_W', 'Key_X',
'Key_Y', 'Key_Z', 'Key_Space', 'Key_F1',
'Key_F2', 'Key_F3', 'Key_F4', 'Key_F5',
'Key_F6', 'Key_F7', 'Key_F8', 'Key_F9',
'Key_F10', 'Key_F11', 'Key_F12', 'Key_Enter',
'Key_RightArrow', 'Key_DownArrow', 'Key_LeftArrow', 'Key_UpArrow',
'Key_Insert', 'Key_Delete', 'Key_Home', 'Key_End',
'Key_PageUp', 'Key_PageDown', 'Key_ScrollLock', 'Key_Pause',
'Key_Numpad_0', 'Key_Numpad_1', 'Key_Numpad_2', 'Key_Numpad_3',
'Key_Numpad_4', 'Key_Numpad_5', 'Key_Numpad_6', 'Key_Numpad_7',
'Key_Numpad_8', 'Key_Numpad_9', 'Key_NumLock', 'Key_Numpad_Divide',
'Key_Numpad_Multiply', 'Key_Numpad_Subtract', 'Key_Numpad_Add', 'Key_Numpad_Enter',
'Key_Numpad_Decimal', 'Key_CapsLock', 'Mouse_1', 'Mouse_2',
'Mouse_3', 'Mouse_4', 'Mouse_5', 'Key_Tab',
'Key_SuperscriptTwo', 'Key_Ampersand', 'Key_é', 'Key_DoubleQuote',
'Key_Apostrophe', 'Key_LeftParenthesis', 'Key_Minus', 'Key_è',
'Key_Underline', 'Key_ç', 'Key_à', 'Key_RightParenthesis',
'Key_Equals', 'Key_Comma', 'Key_SemiColon', 'Key_Colon',
'Key_ExclamationPoint','Key_ù', 'Key_Asterisk', 'Key_Circumflex',
'Key_Dollar', 'Key_LessThan', 'Key_Apps', 'Key_Backspace',
'Key_Echap', 'Key_LeftAlt', 'Key_RightAlt', 'Key_LeftControl',
'Key_RightControl', 'Key_LeftShift', 'Key_RightShift'
);
function GetEliteKey(const Value: string): TEliteKeyType;
function IsEliteKey(const Value: string):Boolean;
function EliteKeyToScanValue(const Value: string):SmallInt; overload;
function EliteKeyToScanValue(const Value: TEliteKeyType):SmallInt; overload;
function KeyScanToEliteString(const Value: SmallInt):string;
function GetKeyNext(const Value:TEliteKeyType):TEliteKeyType;
function GetKeyFuncNext(const Value:TEliteKeyType):TEliteKeyType;
function KeyTypeToStr(const Value:TEliteKeyType): string;
function IdKeyToStr(const IdKey: Cardinal):string;
{*** Duplicatas pour un même signal de combinaison de touches }
type
TKeyDuplicataType =
( kdt_PrimaryFire, kdt_SecondaryFire, kdt_UI_Select,
kdt_UI_Down, kdt_UI_Left, kdt_UI_Back,
kdt_UI_Right, kdt_UI_Up, kdt_RollRight,
kdt_RollLeft, kdt_OpenCodexGoToDiscovery, kdt_PlayerHUDModeToggle,
kdt_IncreaseWeaponsPower, kdt_ResetPowerDistribution, kdt_CycleFireGroupPrevious,
kdt_IncreaseEnginesPower, kdt_IncreaseSystemsPower, kdt_CycleFireGroupNext,
kdt_LeftThrust, kdt_ToggleCargoScoop, kdt_ShipSpotLightToggle,
kdt_EjectAllCargo, kdt_SelectTarget, kdt_FocusRightPanel,
kdt_GalaxyMapOpen, kdt_SystemMapOpen, kdt_ToggleReverseThrottleInput,
kdt_FocusLeftPanel, kdt_FocusCommsPanel, kdt_FocusRadarPanel,
kdt_PitchUp, kdt_PitchDown, kdt_YawRight,
kdt_YawLeft );
TKeyDuplicataArea = 0..Integer(high(TKeyDuplicataType));
TArrayDuplicata = array[1..9] of string;
TDuplicata = array[TKeyDuplicataType] of TArrayDuplicata;
TPreferenceKeys = array[TKeyDuplicataType] of Cardinal;
const
DPrimaryFire : TArrayDuplicata = ('PrimaryFire', 'BuggyPrimaryFireButton', 'MultiCrewPrimaryFire', '', '', '', '', '', ''); //ExplorationFSSDiscoveryScan
DSecondaryFire : TArrayDuplicata = ('SecondaryFire', 'BuggySecondaryFireButton', 'MultiCrewSecondaryFire', '', '', '', '', '', '');
DUI_Select : TArrayDuplicata = ('UI_Select', 'ExplorationFSSTarget', '', '', '', '', '', '', '');
DUI_Down : TArrayDuplicata = ('UI_Down', 'ExplorationFSSMiniZoomIn', '', '', '', '', '', '', '');
DUI_Left : TArrayDuplicata = ('UI_Left', '', '', '', '', '', '', '', '');
DUI_Back : TArrayDuplicata = ('UI_Back', 'ExplorationFSSQuit', '', '', '', '', '', '', '');
DUI_Right : TArrayDuplicata = ('UI_Right', 'ExplorationFSSZoomOut', '', '', '', '', '', '', '');
DUI_Up : TArrayDuplicata = ('UI_Up', 'ExplorationFSSZoomIn', '', '', '', '', '', '', '');
DRollRight : TArrayDuplicata = ('RollRightButton', 'BackwardThrustButton_Landing', 'ExplorationFSSRadioTuningX_Increase',
'SAAThirdPersonFovInButton', 'ToggleBuggyTurretButton', 'CamTranslateBackward', '', '', '');
DRollLeft : TArrayDuplicata = ('RollLeftButton', 'AutoBreakBuggyButton', 'ExplorationFSSRadioTuningX_Decrease',
'ForwardThrustButton_Landing', 'SAAThirdPersonFovOutButton', 'CamTranslateForward', '', '', '');
DOpenCodexGoToDiscovery : TArrayDuplicata = ('OpenCodexGoToDiscovery', 'OpenCodexGoToDiscovery_Buggy', '', '', '', '', '', '', '');
DPlayerHUDModeToggle : TArrayDuplicata = ('PlayerHUDModeToggle', 'PlayerHUDModeToggle_Buggy', '', '', '', '', '', '', '');
DIncreaseWeaponsPower : TArrayDuplicata = ('IncreaseWeaponsPower', 'IncreaseWeaponsPower_Buggy', '', '', '', '', '', '', '');
DResetPowerDistribution : TArrayDuplicata = ('ResetPowerDistribution', 'ResetPowerDistribution_Buggy', '', '', '', '', '', '', '');
DCycleFireGroupPrevious : TArrayDuplicata = ('CycleFireGroupPrevious', 'BuggyCycleFireGroupPrevious', '', '', '', '', '', '', '');
DIncreaseEnginesPower : TArrayDuplicata = ('IncreaseEnginesPower', 'IncreaseEnginesPower_Buggy', '', '', '', '', '', '', '');
DIncreaseSystemsPower : TArrayDuplicata = ('IncreaseSystemsPower', 'IncreaseSystemsPower_Buggy', '', '', '', '', '', '', '');
DCycleFireGroupNext : TArrayDuplicata = ('CycleFireGroupNext', 'BuggyCycleFireGroupNext', '', '', '', '', '', '', '');
DLeftThrust : TArrayDuplicata = ('LeftThrustButton', 'OrderHoldPosition', '', '', '', '', '', '', '');
DToggleCargoScoop : TArrayDuplicata = ('ToggleCargoScoop', 'ToggleCargoScoop_Buggy', '', '', '', '', '', '', '');
DShipSpotLightToggle : TArrayDuplicata = ('ShipSpotLightToggle', 'HeadlightsBuggyButton', '', '', '', '', '', '', '');
DEjectAllCargo : TArrayDuplicata = ('EjectAllCargo', 'EjectAllCargo_Buggy', '', '', '', '', '', '', '');
DSelectTarget : TArrayDuplicata = ('SelectTarget', 'SelectTarget_Buggy', '', '', '', '', '', '', '');
DFocusRightPanel : TArrayDuplicata = ('FocusRightPanel', 'FocusRightPanel_Buggy', '', '', '', '', '', '', '');
DGalaxyMapOpen : TArrayDuplicata = ('GalaxyMapOpen', 'GalaxyMapOpen_Buggy', '', '', '', '', '', '', '');
DSystemMapOpen : TArrayDuplicata = ('SystemMapOpen', 'SystemMapOpen_Buggy', '', '', '', '', '', '', '');
DToggleReverseThrottleInput : TArrayDuplicata = ('ToggleReverseThrottleInput', '', '', '', '', '', '', '', ''); //BuggyToggleReverseThrottleInput
DFocusLeftPanel : TArrayDuplicata = ('FocusLeftPanel', 'FocusLeftPanel_Buggy', '', '', '', '', '', '', '');
DFocusCommsPanel : TArrayDuplicata = ('FocusCommsPanel', 'FocusCommsPanel_Buggy', '', '', '', '', '', '', '');
DFocusRadarPanel : TArrayDuplicata = ('FocusRadarPanel', 'FocusRadarPanel_Buggy', '', '', '', '', '', '', '');
DPitchUp : TArrayDuplicata = ('PitchUpButton', 'BuggyTurretPitchUpButton', 'ExplorationFSSCameraPitchDecreaseButton',
'IncreaseSpeedButtonMax', 'MultiCrewThirdPersonPitchUpButton', 'SAAThirdPersonPitchUpButton', 'UpThrustButton_Landing', 'CamTranslateUp', '');
DPitchDown : TArrayDuplicata = ('PitchDownButton', 'BuggyTurretPitchDownButton', 'DecreaseSpeedButtonMax',
'DownThrustButton_Landing', 'ExplorationFSSCameraPitchIncreaseButton', 'MultiCrewThirdPersonPitchDownButton', 'SAAThirdPersonPitchDownButton', 'CamTranslateDown', '');
DYawRight : TArrayDuplicata = ('YawRightButton', 'BuggyTurretYawRightButton', 'ExplorationFSSCameraYawIncreaseButton',
'MultiCrewThirdPersonYawRightButton', 'RightThrustButton_Landing', 'SAAThirdPersonYawRightButton', 'SteerRightButton', 'CamTranslateRight', '');
DYawLeft : TArrayDuplicata = ('YawLeftButton', 'BuggyTurretYawLeftButton', 'ExplorationFSSCameraYawDecreaseButton',
'LeftThrustButton_Landing', 'MultiCrewThirdPersonYawLeftButton', 'SAAThirdPersonYawLeftButton', 'SteerLeftButton', 'CamTranslateLeft', '');
var
Duplicatas : TDuplicata;
PreferenceKeys : TPreferenceKeys;
procedure DuplicatasInitialize;
procedure PreferenceKeysInitialize;
function DuplicataItemsCount(const Value: TKeyDuplicataType):Integer;
function DuplicataItem(const Value: TKeyDuplicataType; index: Integer): string;
{*** Resumed detailled bindings }
type
TBindsArrayTools = class
private
FSource : string;
FVolRotation : TArrayVolRotation;
FVolPousse : TArrayVolPousse;
FVolPropulsion : TArrayVolPropulsion;
FVolDivers : TArrayVolDivers;
FVisee : TArrayVisee;
FArmes : TArrayArmes;
FFreeze : TArrayFreeze;
FDivers : TArrayDivers;
FModeChange : TArrayModeChange;
FModeBoard : TArrayModeBoard;
FConduite : TArrayConduite;
FConduiteVisee : TArrayConduiteVisee;
FConduiteTurret : TArrayConduiteTurret;
FConduitePropulsion : TArrayConduitePropulsion;
FConduiteDivers : TArrayConduiteDivers;
FConduiteMode : TArrayConduiteMode;
FChasseurOrder : TArrayChasseurOrder;
FExplorationFss : TArrayExplorationFss;
FSurfaceDetaillee : TArraySurfaceDetaillee;
FManualLanding : TArrayManualLanding;
FMultiCrew : TArrayMultiCrew;
FGalaxyMap : TArrayGalaxyMap;
FCamSystem : TArrayCamSystem;
FGalnetReader : TArrayGalnetReader;
FCamFree : TArrayCamFree;
function ToStringEx(const AValues: array of string): string;
function GetBindsXMLtext: string;
function ExtractXMLByBind(const BindValue: string):string;
public
procedure SetSource(const Value: string);
function BindsByCategory_(const Category: TBindCategoriesType):string;
property BindsXMLtext_: string read GetBindsXMLtext;
constructor Create;
class function BindsXMLtext: string;
class function BindsByCategory(const Category: TBindCategoriesType):string;
class function Extract(const ASource, BindValue: string):string;
class function AllButtonBalises(const ASource: string; Full: Boolean):string;
end;
type
TRecordKey = packed record
Device : string;
Key : string;
end;
TRecordKeySection = packed record
Count : Byte; // --- 0..3
MainKey : TRecordKey;
Modifier1 : TRecordKey;
Modifier2 : TRecordKey;
end;
TRecordKeySignal = packed record
Mouse : Boolean;
Key : SmallInt;
Func1 : SmallInt;
Func2 : SmallInt;
end;
TKeyOrder = (ko_primary, ko_secondary);
TKeyInventory = class;
TKeyItemInventory = class
private
FOwner : TKeyInventory;
FXmlSource : string;
FXMLPrimary : string;
FXMLSecondary : string;
FXMLToggleOn : string;
Buffer : string;
FBind : string;
FPrimary : TRecordKeySection;
FSecondary : TRecordKeySection;
FToggle : Boolean;
FToggleValue : string;
FSignal1Checked : Boolean;
FSignal1 : TRecordKeySignal;
FSignal2Checked : Boolean;
FSignal2 : TRecordKeySignal;
FId1 : Cardinal;
FId2 : Cardinal;
procedure SetXmlSource(const Value: string);
function GetText: string;
function GetUsable: Boolean;
function GetPrimaryEnable: Boolean;
function GetSecondaryEnable: Boolean;
function GetPrimaryAvailable: Boolean;
function GetSecondaryAvailable: Boolean;
private
{ --- Read and Extract XML data }
procedure GetDeviceKey(const Src: string; var Device, Key: string);
procedure AssignToKey(ACount: Byte; var AKey: TRecordKeySection;
var ASection: TRecordKey; Device, Key: string);
procedure ExtractToggle;
procedure ExtractSecondary;
procedure ExtractPrimary;
procedure ExtractData;
private
{ --- Transformer les données en signal utilisable avec "key_event" ou "mouse_event" }
function EliteKeyToKeyBoard(const KeySelection: TRecordKeySection;
var KeyResult: TRecordKeySignal):Boolean;
{ --- Méthode de signature des signaux }
function IdSigning(const Key, Mod1, Mod2: Word):Cardinal; overload;
function IdSigning(const Value: TRecordKeySignal):Cardinal; overload;
{ --- Ajouter des signatures au catalogue }
procedure AddToCatalog(const Order: TKeyOrder);
procedure AddToErrors(const Msg: string);
procedure AddToHashTable(const Order: TKeyOrder);
procedure CheckCombination;
private
{ --- Chech values }
function IsJoyUsed(const Value: TRecordKeySection):Boolean;
function IsCombinationJoyBusy: Boolean;
function IsCombinatonFree: Boolean;
private
{ --- Build availaible conbibnation }
function FindFreeCombination(var Key, Func1, Func2: TEliteKeyType;
var UseTwoFunc: Boolean; var NewSignal: Cardinal):Boolean;
private
{ --- XML tools }
function XMLIndentation:string;
public
function ConcatXML:string;
function ReplaceSourceXML:string;
property Owner: TKeyInventory read FOwner;
property Bind: string read FBind write FBind;
property PrimaryAvailable: Boolean read GetPrimaryAvailable;
property PrimaryEnable: Boolean read GetPrimaryEnable;
property PrimarySignal: TRecordKeySignal read FSignal1;
property PrimarySignalChecked: Boolean read FSignal1Checked;
property PrimaryIdKey: Cardinal read FId1;
property SecondaryAvailable: Boolean read GetSecondaryAvailable;
property SecondaryEnable: Boolean read GetSecondaryEnable;
property SecondarySignal: TRecordKeySignal read FSignal2;
property SecondarySignalChecked: Boolean read FSignal2Checked;
property SecondaryIdKey: Cardinal read FId2;
property Text: string read GetText;
{Usable: Avant synchronisation une des deux possibilités doit être disponible }
property Usable: Boolean read GetUsable;
property XMLSource: string read FXmlSource write SetXmlSource;