<?xml version="1.0" encoding="UTF-8"?>
<installer-gui-script minSpecVersion='1'>
    <!-- Automatically generated by update2dist -->
    <!-- Installer meta-data -->
    <choices-outline>
        <line choice='manual'/>
    </choices-outline>
    <title>QuickTime</title>
    <choice id='manual' title="QuickTime">
        <pkg-ref id='manual' auth='Root' onConclusion='RequireRestart'>.</pkg-ref>
    </choice>
    <choice id='manual' title='MANUAL_TITLE'/>
    <choice id='manual' versStr='SU_VERS'/>
    <welcome file="Welcome.rtf"/>
    <readme file="ReadMe.rtfd"/>
    <license file="License.rtf"/>
    <options customize='never'/>
    <background file="background.tif" scaling="none" alignment="bottomleft"></background>
    <!-- Software Update meta-data -->
    <choices-outline ui='SoftwareUpdate'>
        <line choice='su'/>
    </choices-outline>
    <choice id='su' suDisabledGroupID='QuickTime'>
        <pkg-ref id='auto' onConclusion='RequireRestart'>QuickTime764_Tiger.pkg</pkg-ref>
    </choice>
    <choice id='su' visible='VisibleCheck()'/>
    <choice id='su' title='SU_TITLE' versStr='SU_VERS'/>
    <choice id='su' description='SU_DESCRIPTION' description-mime-type='text/html'/>
    <installation-check script="InstallationCheck()"/>
    <volume-check script="VolumeCheck()"/>
    <options hostArchitectures='ppc,i386'/>
    <platforms>
        <client arch="ppc,intel"/>
        <server arch="ppc,intel"/>
    </platforms>
    <script>
    function InstallationCheck()
    {
        // note: my.target isn't defined under installation-check
        if (true)
            return true;

        if (my.result)
        {
            //my.result.message = 'message';    // XXX
            my.result.type = 'Fatal';
        }
        return false;
    }

    function VolumeCheck()
    {
        
        if(my.target.mountpoint != '/'){
            my.result.message = system.localizedString('BOOT_VOLUME_ERR');
            my.result.type = 'Fatal';
            return false;
        }
        if(system.compareVersions(my.target.systemVersion.ProductVersion, '10.4.11') == -1) {
            my.result.message = system.localizedString('OS_VER_ERR');
            my.result.type = 'Fatal';
            return false;
        }
		
		if(system.compareVersions(my.target.systemVersion.ProductVersion, '10.6.0') != -1) {
            my.result.message = system.localizedString('OS_SL_HIGH_ERR');
            my.result.type = 'Fatal';
            return false;
        }
		
        if(system.compareVersions(my.target.systemVersion.ProductVersion, '10.5.0') != -1) {
            my.result.message = system.localizedString('OS_HIGH_ERR');
            my.result.type = 'Fatal';
            return false;
        }
        if (newerQuickTimePresent()) {
            my.result.type = 'Fatal';
            my.result.message = system.localizedStringWithFormat('isDowngrade');
            return false;            
        }
        if (!noAppleTier3Language()) {
            my.result.type = 'Fatal';
            my.result.message = system.localizedStringWithFormat('volumeHasTier3');
            return false;            
        }
        return true;
    }


    function VisibleCheck()
    {
        return(noAppleTier3Language() &amp;&amp; notAlreadyInstalled());
    }



function noAppleTier3Language()
{

    var path = my.target.mountpoint + "/var/db/.AppleTier3Language";
    if (!system.files.fileExistsAtPath(path))
        return true;
    
    return false;
}

function newerQuickTimePresent()
{
    var path = my.target.mountpoint + "/System/Library/Frameworks/QuickTime.framework";
    var bundle = system.files.bundleAtPath(path);
    var version = BundleGetCompositeVersion5(bundle);
    if (version &amp;&amp; (system.compareVersions(version, "7.6.4.999999999.999999999") &lt; 1)) {
        return false;
    }
    return true;
}
function notAlreadyInstalled()
{
    var path = my.target.mountpoint + "/System/Library/Frameworks/QuickTime.framework";
    var bundle = system.files.bundleAtPath(path);
    var version = BundleGetCompositeVersion5(bundle);
    if (version &amp;&amp; (system.compareVersions(version, "7.6.4.0.0") &lt; 1)) {
        return true;
    }
    return false;
}
    
    </script>
    <!-- Common include -->
    <script>
    function _PadVersionString(version, tupleCount)
    {
        if (version == null)
            version = "0";
        var components = version.split(".");
        if (components.length > tupleCount)
            components = components.slice(0, tupleCount);
        else
            for (; components.length&lt;tupleCount; )
                components.push("0");
        return components.join(".");
    }

    function BundleGetCompositeVersion5(bundle)
    {
        if (bundle == null)
            return null;
        var shortVers = bundle.CFBundleShortVersionString;
        shortVers = _PadVersionString(shortVers, 3);
        var sourceVers = bundle.SourceVersion;
        sourceVers = _PadVersionString(sourceVers, 1);
        var buildVers = bundle.BuildVersion;
        buildVers = _PadVersionString(buildVers, 1);
        var fiveTupleVers = shortVers + "." + sourceVers + "." + buildVers;
        return fiveTupleVers;
    }

    </script>
    <localization>
        <strings language="pl"><![CDATA["SU_TITLE" = "QuickTime";
"SU_VERS" = "7.6.4";
"SU_SERVERCOMMENT" = "Dla komputerów klienckich oraz serwerów";

"SU_DESCRIPTION"='<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html>
<head>
  <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
  <meta http-equiv="Content-Style-Type" content="text/css">
  <title></title>
  <meta name="Generator" content="Cocoa HTML Writer">
  <meta name="CocoaVersion" content="824.41">
  <style type="text/css">
    p.p1 {margin: 0.0px 0.0px 12.0px 0.0px; font: 11.0px Lucida Grande}
  </style>
</head>
<body>
<p class="p1">
QuickTime 7.6.4 zawiera zmiany zwiększające niezawodność, poprawiające zgodność oraz bezpieczeństwo. To uaktualnienie jest zalecane dla wszystkich użytkowników QuickTime 7.
<br>
<br>
Ze szczegółowymi informacjami dotyczącymi tego uaktualnienia można zapoznać się pod adresem: <a href="http://support.apple.com/kb/HT3661?viewlocale=pl_PL"><span class="s1">http://support.apple.com/kb/HT3661?viewlocale=pl_PL.</span></a>
<br>
<br>
Ze szczegółowymi informacjami dotyczącymi zabezpieczeń w tym uaktualnieniu można zapoznać się pod adresem: <a href="http://support.apple.com/kb/HT1222?viewlocale=pl_PL"><span class="s1">http://support.apple.com/kb/HT1222?viewlocale=pl_PL.</span></a>
</p>
</body>
</html>
';
]]></strings>
    </localization>
</installer-gui-script>