1
我想在用户接受密钥添加后添加注册表项。 关键会告诉Firefox哪里可以找到我们的插件(存储在应用程序文件夹中)Inno Setup中运行条目中运行脚本代码(添加注册表项)而不是可执行文件
用户将得到一个复选框“install ff plug-in?”与我们问“安装Chrome插件”和“安装即插件?。
[Code]
function GetHKLM: Integer;
begin
if IsWin64 then
Result := HKLM64
else
Result := HKLM32;
end;
function CheckForMozilla: Boolean;
begin
Result := False;
if RegKeyExists(GetHKLM(), 'SOFTWARE\Mozilla\Mozilla Firefox') then
begin
Result := True;
end;
if RegKeyExists(GetHKLM(), 'SOFTWARE\Mozilla\Firefox') then
begin
Result := True;
end;
end;
function AddFFKey : Boolean;
begin
// Some way to write this key in code section :
GetHKLM()\SOFTWARE\Mozilla\Mozilla Firefox\extensions\[email protected]'
end;
[Run]
Filename: AddFFKey; Flags: runascurrentuser postinstall ; \
Check: CheckForMozilla; Description: "Install firefox plug-in"
谢谢大家!
史蒂夫