Last change
on this file was 468, checked in by chronos, 12 months ago |
- Added: High DPI support integrated into trunk branch. It can be enabled by adding DPI define to compiler parameters for main project and packages.
|
File size:
848 bytes
|
Line | |
---|
1 | {$INCLUDE Switches.inc}
|
---|
2 | unit LocalPlayer;
|
---|
3 |
|
---|
4 | interface
|
---|
5 |
|
---|
6 | procedure Client(Command, Player: Integer; var Data); stdcall;
|
---|
7 | procedure SetAIName(P: Integer; Name: string);
|
---|
8 |
|
---|
9 |
|
---|
10 | implementation
|
---|
11 |
|
---|
12 | uses
|
---|
13 | Term, CityScreen, Nego, BaseWin,
|
---|
14 | {$IFDEF DPI}Dpi.Forms{$ELSE}Forms{$ENDIF};
|
---|
15 |
|
---|
16 | var
|
---|
17 | FormsCreated: Boolean;
|
---|
18 |
|
---|
19 | procedure Client(Command, Player: Integer; var Data);
|
---|
20 | begin
|
---|
21 | if not FormsCreated then
|
---|
22 | begin
|
---|
23 | FormsCreated := True;
|
---|
24 | // TODO: Changing application name in runtime will cause change of Linux XML registry file path
|
---|
25 | // Application.MainForm := MainScreen;
|
---|
26 | Application.CreateForm(TMainScreen, MainScreen);
|
---|
27 | end;
|
---|
28 | MainScreen.Client(Command, Player, Data);
|
---|
29 | end;
|
---|
30 |
|
---|
31 | procedure SetAIName(P: Integer; Name: string);
|
---|
32 | begin
|
---|
33 | MainScreen.SetAIName(P, Name);
|
---|
34 | end;
|
---|
35 |
|
---|
36 | initialization
|
---|
37 |
|
---|
38 | FormsCreated := False;
|
---|
39 |
|
---|
40 | end.
|
---|
Note:
See
TracBrowser
for help on using the repository browser.