ViewVC Help
View File | Revision Log | View Changeset | Root Listing
root/Oni2/AE/Installer/trunk/source/installer.cpp
(Generate patch)

Comparing AE/Installer/trunk/source/installer.cpp (file contents):
Revision 501 by iritscen, Sun Mar 14 23:31:14 2010 UTC vs.
Revision 502 by iritscen, Mon Mar 22 16:51:50 2010 UTC

# Line 342 | Line 342 | vector<ModPackage> getPackages(string pa
342                          {
343                                  package = fileToModPackage(file);
344                                  if (package.installerVersion.compare(INSTALLER_VERSION) < 1)  // if mod requires newer version of the Installer, we won't add it to the list
345 <                                        packages.push_back(package);
345 >                                {
346 > #ifdef WIN32
347 >                                        if (!package.platform.compare("Windows") || !package.platform.compare("Both")) // don't show package if it's not for the right OS
348 > #else
349 >                                        if (!package.platform.compare("Macintosh") || !package.platform.compare("Both"))
350 > #endif
351 >                                                packages.push_back(package);
352 >                                }
353                          }      
354                          file.close();
355                          file.clear();
# Line 373 | Line 380 | ModPackage fileToModPackage(fstream &fil
380          static string NameOfMod = "NameOfMod";
381          static string ARROW = "->";
382          static string ModString = "ModString";
383 +        static string Platform = "Platform";
384          static string HasOnis = "HasOnis";
385          static string HasDeltas = "HasDeltas";
386          static string HasBSL = "HasBSL";
# Line 412 | Line 420 | ModPackage fileToModPackage(fstream &fil
420                                  iter++;
421                                  package.modStringVersion = atoi((*iter).c_str());
422                          }
423 +                        else if (!Platform.compare(*iter))
424 +                        {
425 +                                iter++; iter++;
426 +                                package.platform = *iter;
427 +                        }
428                          else if (!HasOnis.compare(*iter))
429                          {
430                                  iter++; iter++;  
# Line 1613 | Line 1626 | ModPackage::ModPackage()
1626          name = "";
1627          modStringName = "";
1628          modStringVersion = 0;
1629 +        platform = "Both";
1630          hasOnis = false;
1631          hasDeltas = false;
1632          hasBSL = false;

Diff Legend

Removed lines
+ Added lines
< Changed lines (old)
> Changed lines (new)