* Added error message with the hint to specify the libxpcom-filename when xulrunner failed to load

git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@2359 8e941d3f-bd1b-0410-a28a-d453659cc2b4
This commit is contained in:
loesje_
2012-03-19 15:45:09 +00:00
parent ac9a9208db
commit 189313c236

View File

@ -7,7 +7,9 @@ uses
Math,
{$ENDIF}
{$ENDIF}
sysutils,
Forms,
GeckoInit,
gec10 in 'gec10.pas';
@ -20,6 +22,18 @@ begin
{$ENDIF}
Application.Initialize;
try
GeckoComponentsStartup(ParamStr(1));
except
on E: Exception do
raise Exception.CreateFmt('Failed to initialize xulrunner. Try to pass the complete filename ' +
'of the libxpcom library (including the path) as first parameter to ' +
'the command line. Original error message: %s', [E.Message]);
end;
try
Application.CreateForm(TForm1, Form1);
Application.Run;
finally
GeckoComponentsShutdown;
end;
end.