Subversion Repositories spk

Rev

Rev 2 | Rev 19 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 2 Rev 9
Line 1474... Line 1474...
1474
				if ( display )
1474
				if ( display )
1475
					MessageBox::Show(this, "Package file is created with a newer version, unable to open", "Load Error", MessageBoxButtons::OK, MessageBoxIcon::Error);
1475
					MessageBox::Show(this, "Package file is created with a newer version, unable to open", "Load Error", MessageBoxButtons::OK, MessageBoxIcon::Error);
1476
				return;
1476
				return;
1477
			}
1477
			}
1478
 
1478
 
1479
			if ( fileType == SPKFILE_INVALID )
1479
			if ( fileType == SPKFILE_INVALID || fileType == SPKFILE_OLD )
1480
			{
1480
			{
1481
				bool loaded = false;
1481
				bool loaded = false;
1482
				if ( String::Compare(IO::FileInfo(file).Extension, ".xsp") == 0 )
1482
				if ( String::Compare(IO::FileInfo(file).Extension, ".xsp") == 0 )
1483
				{
1483
				{
1484
					CXspFile *shipFile = new CXspFile;
1484
					CXspFile *shipFile = new CXspFile;
Line 1489... Line 1489...
1489
						shipFile->SetFilename(CyStringFromSystemString(file));
1489
						shipFile->SetFilename(CyStringFromSystemString(file));
1490
						convertFile = shipFile;
1490
						convertFile = shipFile;
1491
					}
1491
					}
1492
					else 
1492
					else 
1493
						delete shipFile;
1493
						delete shipFile;
-
 
1494
				}
-
 
1495
				else if ( String::Compare(IO::FileInfo(file).Extension, ".spk") == 0 )
-
 
1496
				{
-
 
1497
					CSpkFile *spkFile = CSpkFile::convertFromOld(CyStringFromSystemString(file).ToString());
-
 
1498
					if ( spkFile ) {
-
 
1499
						loaded = true;
-
 
1500
						spkFile->SetChanged(true);
-
 
1501
						spkFile->SetFilename(CyStringFromSystemString(file));
-
 
1502
						convertFile = spkFile;
-
 
1503
					}
1494
				}
1504
				}
1495
 
1505
 
1496
				if ( !loaded )
1506
				if ( !loaded )
1497
				{
1507
				{
1498
					if ( display )
1508
					if ( display )