home *** CD-ROM | disk | FTP | other *** search
/ T-Online 6 / T-Online.iso / Animation / content / intro / intro.swf / scripts / __Packages / application / strategies / ContentStrategie.as
Encoding:
Text File  |  2005-10-20  |  2.7 KB  |  67 lines

  1. class application.strategies.ContentStrategie
  2. {
  3.    var instCounter;
  4.    var home;
  5.    var normalProductContent;
  6.    var benefitContent;
  7.    var tonlineSoftwareContent;
  8.    var clientContent;
  9.    var installerSelectionContent;
  10.    var softwareListContent;
  11.    var helpContent;
  12.    var imprintContent;
  13.    var coBrandContent;
  14.    function ContentStrategie()
  15.    {
  16.       this.instCounter = 0;
  17.       this.home = new application.contents.HomeContent();
  18.       this.normalProductContent = new application.contents.NormalProductContent();
  19.       this.benefitContent = new application.contents.BenefitContent();
  20.       this.tonlineSoftwareContent = new application.contents.TonlineSoftwareContent();
  21.       this.clientContent = new application.contents.ClientContent();
  22.       this.installerSelectionContent = new application.contents.InstallerSelectionContent();
  23.       this.softwareListContent = new application.contents.SoftwareListContent();
  24.       this.helpContent = new application.contents.HelpContent();
  25.       this.imprintContent = new application.contents.InprintContent();
  26.       this.coBrandContent = new application.contents.CoBrandContent();
  27.    }
  28.    function getStrategy(content)
  29.    {
  30.       this.instCounter = this.instCounter + 1;
  31.       switch(content)
  32.       {
  33.          case "home":
  34.             this.home.instCounter = this.instCounter;
  35.             return this.home;
  36.          case "normalProductContent":
  37.             this.normalProductContent.instCounter = this.instCounter;
  38.             return this.normalProductContent;
  39.          case "benefitContent":
  40.             this.benefitContent.instCounter = this.instCounter;
  41.             return this.benefitContent;
  42.          case "tonlineSoftwareContent":
  43.             this.tonlineSoftwareContent.instCounter = this.instCounter;
  44.             return this.tonlineSoftwareContent;
  45.          case "clientContent":
  46.             this.clientContent.instCounter = this.instCounter;
  47.             return this.clientContent;
  48.          case "installerSelectionContent":
  49.             this.installerSelectionContent.instCounter = this.instCounter;
  50.             return this.installerSelectionContent;
  51.          case "softwareListContent":
  52.             this.softwareListContent.instCounter = this.instCounter;
  53.             return this.softwareListContent;
  54.          case "helpContent":
  55.             this.helpContent.instCounter = this.instCounter;
  56.             return this.helpContent;
  57.          case "imprintContent":
  58.             this.imprintContent.instCounter = this.instCounter;
  59.             return this.imprintContent;
  60.          case "coBrandContent":
  61.             this.coBrandContent.instCounter = this.instCounter;
  62.             return this.coBrandContent;
  63.          default:
  64.       }
  65.    }
  66. }
  67.