-
Notifications
You must be signed in to change notification settings - Fork 2
/
ServerController.pas
53 lines (34 loc) · 963 Bytes
/
ServerController.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
unit ServerController;
interface
uses
SysUtils, Classes, IWServerControllerBase, IWBaseForm, HTTPApp,
// For OnNewSession Event
UserSessionUnit, IWApplication, IWAppForm, IW.Browser.Browser;
type
TIWServerController = class(TIWServerControllerBase)
procedure IWServerControllerBaseNewSession(ASession: TIWApplication);
private
public
end;
function UserSession: TIWUserSession;
function IWServerController: TIWServerController;
implementation
{$R *.dfm}
uses
IWInit, IWGlobal;
function IWServerController: TIWServerController;
begin
Result := TIWServerController(GServerController);
end;
function UserSession: TIWUserSession;
begin
Result := TIWUserSession(WebApplication.Data);
end;
procedure TIWServerController.IWServerControllerBaseNewSession(
ASession: TIWApplication);
begin
ASession.Data := TIWUserSession.Create(nil, ASession);
end;
initialization
TIWServerController.SetServerControllerClass;
end.