akvirtualcamera/ports/deploy/installscript.windows.qs
Gonzalo Exequiel Pedone 84d630e422
Windows plugin working, 'update' command still needs elevated privileges
but all other commands can be run as normal user.
2020-10-08 20:07:51 -03:00

41 lines
1.2 KiB
Text

function Component()
{
}
Component.prototype.beginInstallation = function()
{
component.beginInstallation();
}
Component.prototype.createOperations = function()
{
component.createOperations();
let archs = ["x86", "x64"];
for (let i in archs) {
if (installer.isUninstaller()) {
let managerPath =
installer.value("TargetDir")
+ "/"
+ archs[i]
+ "/AkVCamManager.exe";
component.addOperation("Execute",
managerPath, "remove-devices");
component.addElevatedOperation("Execute",
managerPath, "update");
}
let assistantPath =
installer.value("TargetDir")
+ "/"
+ archs[i]
+ "/AkVCamAssistant.exe";
// Load assistant daemon.
if (installer.fileExists(assistantPath))
component.addElevatedOperation("Execute",
assistantPath, "--install",
"UNDOEXECUTE",
assistantPath, "--uninstall");
}
}