2

我的安装程序的许可协议页面上有一个小故障/错误。这个错误只发生在 Mac 上。我删除了所有非强制性页面。有人可以帮助我吗?

rem :它看起来像 TextZone 的错误选择/焦点。当我单击单选按钮或文本时,蓝色矩形消失

这是屏幕截图:安装程序许可证页面 gfx 错误屏幕截图

这是我的脚本:

function Component()
{
    installer.setDefaultPageVisible(QInstaller.Introduction, false); // needed to avoid double introduction page
    installer.setDefaultPageVisible(QInstaller.TargetDirectory, false);
    installer.setDefaultPageVisible(QInstaller.StartMenuSelection, false);
    installer.setDefaultPageVisible(QInstaller.ComponentSelection, false);
    //installer.setDefaultPageVisible(QInstaller.ReadyForInstallation, false); // commented cuz we have a non-informative error (E_FAIL) when the disk is already full
}

Component.prototype.createOperationsForArchive = function(archive)
{
    if (installer.value("os") === "mac")
    {
        component.addOperation("Extract", archive, "@ApplicationsDir@");
    }
    else
    {
        component.addOperation("Extract", archive, "@TargetDir@");
    }
}

Component.prototype.createOperations = function()
{
    try {
        // call the base create operations function
        component.createOperations();
    } catch (e) {
        console.log(e);
    }

    if (installer.value("os") === "win")
    {
        component.addOperation("CreateShortcut", "@TargetDir@/bin/game-launcher.exe", "@DesktopDir@/game.lnk");
    }
    if (installer.value("os") === "x11")
    {
        component.addOperation("CreateDesktopEntry", "/usr/share/applications/YourApp.desktop", "Version=1.0\nType=Application\nTerminal=false\nExec=@TargetDir@/YourApp.sh\nName=YourApp_name\nIcon=@TargetDir@YourApp_icon.png\nName[en_US]=YourApp_name");
        component.addElevatedOperation("Copy", "/usr/share/applications/YourApp.desktop", "@HomeDir@/Desktop/YourApp.desktop");
    }
}

Component.prototype.isDefault = function()
{
    // select the component by default
    return true;
}
4

0 回答 0