-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathIconClassic.dpr
68 lines (60 loc) · 1.96 KB
/
IconClassic.dpr
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
program IconClassic;
uses
Windows,
Messages,
SysUtils,
Forms,
uIconClassic in 'uIconClassic.pas' {frmIconClassic},
uAvaliacao in 'uAvaliacao.pas' {frmAvaliacao},
cFavorites in 'cFavorites.pas',
cTipos in 'cTipos.pas',
uGlobal in 'uGlobal.pas',
udmIconesProntos in 'udmIconesProntos.pas' {dmIconesProntos: TDataModule},
uTestarIcone in 'TestarIcone\uTestarIcone.pas' {frmTestarIcone},
uFrArrastar in 'Pesquisa\uFrArrastar.pas' {fFrArrastar: TFrame},
uShellExtensao in 'ShellExtensao\uShellExtensao.pas' {frmShellExtensao},
uFrWebBrowser in 'Pesquisa\uFrWebBrowser.pas' {fFrWebBrowser: TFrame},
UIcoFiles in 'UIcoFiles.pas',
u3d in 'Formatos\3D\u3d.pas' {frm3d},
uGis in 'Formatos\GIS\uGis.pas' {frmGis};
{$R *.res}
var
hwnd: THandle;
cds: CopyDataStruct;
lstr_Temp: String;
lint_Loop: Integer;
begin
hwnd := FindWindow('TfrmIconClassic', 'Icon Classic - 2007');
if (hwnd = 0) then
begin
Application.Initialize;
Application.Title := 'Icon Classic - 2009';
Application.CreateForm(TdmIconesProntos, dmIconesProntos);
Application.CreateForm(TfrmIconClassic, frmIconClassic);
Application.Run;
end
else
begin
lstr_Temp := '';
for lint_Loop := 1 to ParamCount do
begin
if (lint_Loop = 1) then
lstr_Temp := ExtractShortPathName(ParamStr(lint_Loop))
else
begin
if (ExtractShortPathName(ParamStr(lint_Loop)) <> '') then
lstr_Temp := lstr_Temp + ' ' + ExtractShortPathName(ParamStr(lint_Loop))
else
lstr_Temp := lstr_Temp + ' ' + ParamStr(lint_Loop);
end;
end;
if (lstr_Temp <> '') then
begin
cds.dwData := 0;
cds.cbData := Length(lstr_Temp);
cds.lpData := PChar(lstr_Temp);
end;
SetForegroundWindow(hwnd);
SendMessage(hwnd, wm_CopyData, 0, Integer(@cds));
end;
end.