From: <nor...@us...> - 2007-06-12 23:14:43
|
Revision: 531 http://mp-plugins.svn.sourceforge.net/mp-plugins/?rev=531&view=rev Author: northern_sky Date: 2007-06-12 16:14:40 -0700 (Tue, 12 Jun 2007) Log Message: ----------- added gameurl Modified Paths: -------------- trunk/plugins/myGUIProgramsAlt/GUIProgramsAlt/FileItems/FileItem.cs Modified: trunk/plugins/myGUIProgramsAlt/GUIProgramsAlt/FileItems/FileItem.cs =================================================================== --- trunk/plugins/myGUIProgramsAlt/GUIProgramsAlt/FileItems/FileItem.cs 2007-06-12 23:09:40 UTC (rev 530) +++ trunk/plugins/myGUIProgramsAlt/GUIProgramsAlt/FileItems/FileItem.cs 2007-06-12 23:14:40 UTC (rev 531) @@ -64,6 +64,9 @@ string tagData; string categoryData; bool isFolder; + string gameInfoURL; + + List<FileItemInfo> fileItemInfoList = null; FileItemInfo fileItemInfoFavourite = null; @@ -99,6 +102,7 @@ extFileID = -1; tagData = ""; categoryData = ""; + gameInfoURL = string.Empty; } private string GetYearManu() @@ -775,7 +779,7 @@ try { string strSQL = String.Format( - "UPDATE tblFileItem SET title = '{1}', filename = '{2}', filepath = '{3}', imagefile = '{4}', mainGenre = '{5}', subGenre = '{6}', country = '{7}', manufacturer = '{8}', year = '{9}', rating = '{10}', overview = '{11}', system = '{12}', uppertitle = '{13}', tagdata = '{14}', categorydata = '{15}' where fileid = {0}", FileID, ProgramUtils.Encode(Title), ProgramUtils.Encode(Filename), ProgramUtils.Encode(Filepath), ProgramUtils.Encode(Imagefile), ProgramUtils.Encode(MainGenre), ProgramUtils.Encode(SubGenre), ProgramUtils.Encode(Country), ProgramUtils.Encode(Manufacturer), strYear, Rating, ProgramUtils.Encode(Overview), ProgramUtils.Encode(System_), ProgramUtils.Encode(Title.ToUpper()), ProgramUtils.Encode(TagData), ProgramUtils.Encode(CategoryData)); + "UPDATE tblFileItem SET title = '{1}', filename = '{2}', filepath = '{3}', imagefile = '{4}', mainGenre = '{5}', subGenre = '{6}', country = '{7}', manufacturer = '{8}', year = '{9}', rating = '{10}', overview = '{11}', system = '{12}', uppertitle = '{13}', tagdata = '{14}', categorydata = '{15}', gameInfoURL = '" + ProgramUtils.Encode(GameInfoURL) +"' where fileid = {0}", FileID, ProgramUtils.Encode(Title), ProgramUtils.Encode(Filename), ProgramUtils.Encode(Filepath), ProgramUtils.Encode(Imagefile), ProgramUtils.Encode(MainGenre), ProgramUtils.Encode(SubGenre), ProgramUtils.Encode(Country), ProgramUtils.Encode(Manufacturer), strYear, Rating, ProgramUtils.Encode(Overview), ProgramUtils.Encode(System_), ProgramUtils.Encode(Title.ToUpper()), ProgramUtils.Encode(TagData), ProgramUtils.Encode(CategoryData)); sqlDB.Execute(strSQL); } catch (SQLiteException ex) @@ -847,6 +851,13 @@ } } + public string GameInfoURL + { + get { return gameInfoURL; } + set { gameInfoURL = value; } + } + + public bool FindFileInfo(ScraperType ScraperType) { int iRetries = 0; @@ -926,6 +937,7 @@ this.Overview = FileInfoFavourite.Overview; this.Rating = FileInfoFavourite.RatingNorm; this.System_ = FileInfoFavourite.Platform; + this.GameInfoURL = FileInfoFavourite.GameURL; this.Write(); } } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <nor...@us...> - 2007-06-13 21:01:11
|
Revision: 534 http://mp-plugins.svn.sourceforge.net/mp-plugins/?rev=534&view=rev Author: northern_sky Date: 2007-06-13 14:01:09 -0700 (Wed, 13 Jun 2007) Log Message: ----------- removed old method Modified Paths: -------------- trunk/plugins/myGUIProgramsAlt/GUIProgramsAlt/FileItems/FileItem.cs Modified: trunk/plugins/myGUIProgramsAlt/GUIProgramsAlt/FileItems/FileItem.cs =================================================================== --- trunk/plugins/myGUIProgramsAlt/GUIProgramsAlt/FileItems/FileItem.cs 2007-06-13 20:59:32 UTC (rev 533) +++ trunk/plugins/myGUIProgramsAlt/GUIProgramsAlt/FileItems/FileItem.cs 2007-06-13 21:01:09 UTC (rev 534) @@ -942,54 +942,6 @@ } } - /* public string GetNewImageFile(ApplicationItem curApp, string strExtension) - { - if (curApp == null) - return ""; - if (curApp.imageDirs == null) - return ""; - if (curApp.imageDirs.Length == 0) - return ""; - if ((this.Imagefile == "") && (this.Filename == "")) - return ""; - - string strFolder = ""; - string strFileName = ""; - string strCand = ""; - int iImgIndex = -1; - bool bFound = false; - - strFolder = curApp.imageDirs[0]; - - if (Imagefile != "") - { - strFileName = Imagefile.TrimEnd('\"'); - strFileName = strFileName.TrimStart('\"'); - strFileName = Path.GetFileName(strFileName); - } - else - { - strFileName = Filename.TrimEnd('\"'); - strFileName = strFileName.TrimStart('\"'); - strFileName = Path.GetFileName(strFileName); - } - strFileName = Path.ChangeExtension(strFileName, null); - - while (!bFound) - { - iImgIndex++; - if (iImgIndex == 0) - { - strCand = String.Format("{0}\\{1}{2}", strFolder, strFileName, strExtension); - } - else - { - strCand = String.Format("{0}\\{1}_{2}{3}", strFolder, strFileName, iImgIndex, strExtension); - } - bFound = !File.Exists(strCand); - } - return strCand; - }*/ public string GetNewValidImageFile(ApplicationItem curApp, string strExtension) { if (curApp == null) This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <che...@us...> - 2007-06-14 11:30:59
|
Revision: 542 http://mp-plugins.svn.sourceforge.net/mp-plugins/?rev=542&view=rev Author: chef_koch Date: 2007-06-14 04:30:58 -0700 (Thu, 14 Jun 2007) Log Message: ----------- fixed: after starting the search a second time, no match was selected automatically Modified Paths: -------------- trunk/plugins/myGUIProgramsAlt/GUIProgramsAlt/FileItems/FileItem.cs Modified: trunk/plugins/myGUIProgramsAlt/GUIProgramsAlt/FileItems/FileItem.cs =================================================================== --- trunk/plugins/myGUIProgramsAlt/GUIProgramsAlt/FileItems/FileItem.cs 2007-06-13 23:25:00 UTC (rev 541) +++ trunk/plugins/myGUIProgramsAlt/GUIProgramsAlt/FileItems/FileItem.cs 2007-06-14 11:30:58 UTC (rev 542) @@ -879,6 +879,7 @@ } } fileItemInfoList = scraper.GameList; + fileItemInfoFavourite = null; } break; } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <nor...@us...> - 2007-06-14 16:34:41
|
Revision: 549 http://mp-plugins.svn.sourceforge.net/mp-plugins/?rev=549&view=rev Author: northern_sky Date: 2007-06-14 09:34:39 -0700 (Thu, 14 Jun 2007) Log Message: ----------- small cleanup + fixed gameurl for new items too Modified Paths: -------------- trunk/plugins/myGUIProgramsAlt/GUIProgramsAlt/FileItems/FileItem.cs Modified: trunk/plugins/myGUIProgramsAlt/GUIProgramsAlt/FileItems/FileItem.cs =================================================================== --- trunk/plugins/myGUIProgramsAlt/GUIProgramsAlt/FileItems/FileItem.cs 2007-06-14 13:04:07 UTC (rev 548) +++ trunk/plugins/myGUIProgramsAlt/GUIProgramsAlt/FileItems/FileItem.cs 2007-06-14 16:34:39 UTC (rev 549) @@ -577,76 +577,59 @@ string strSQL = String.Format( @" INSERT INTO - tblFileItem ( - fileid, - appid, - title, - filename, - filepath, - imagefile, - mainGenre, - subGenre, - country, - manufacturer, - year, - rating, - overview, - system, - manualfilename, - lastTimeLaunched, - launchcount, - isfolder, - external_id, - uppertitle, - tagdata, - categorydata - ) + tblFileItem + ( + fileid, + appid, + title, + filename, + filepath, + imagefile, + mainGenre, + subGenre, + country, + manufacturer, + year, + rating, + overview, + system, + manualfilename, + lastTimeLaunched, + launchcount, + isfolder, + external_id, + uppertitle, + tagdata, + categorydata, + gameInfoUrl + ) - VALUES ( - null, - '{0}', - '{1}', - '{2}', - '{3}', - '{4}', - '{5}', - '{6}', - '{7}', - '{8}', - '{9}', - '{10}', - '{11}', - '{12}', - '{13}', - '{14}', - '{15}', - '{16}', - '{17}', - '{18}', - '{19}', - '{20}' - )", - AppID, - ProgramUtils.Encode(Title), - ProgramUtils.Encode(Filename), - ProgramUtils.Encode(Filepath), - ProgramUtils.Encode(Imagefile), - ProgramUtils.Encode(MainGenre), - ProgramUtils.Encode(SubGenre), - Country, - ProgramUtils.Encode(Manufacturer), - strYear, - Rating, - ProgramUtils.Encode(Overview), - ProgramUtils.Encode(System_), - ProgramUtils.Encode(ManualFilename), - strLastLaunch, - strLaunchCount, - ProgramUtils.BooleanToStr(IsFolder), - ExtFileID, - ProgramUtils.Encode(Title.ToUpper()), - ProgramUtils.Encode(TagData), - ProgramUtils.Encode(CategoryData)); + VALUES + ( + null, + '" + AppID + @"', + '" + ProgramUtils.Encode(Title)+ @"', + '" + ProgramUtils.Encode(Filename)+ @"', + '" + ProgramUtils.Encode(Filepath)+ @"', + '" + ProgramUtils.Encode(Imagefile)+ @"', + '" + ProgramUtils.Encode(MainGenre)+ @"', + '" + ProgramUtils.Encode(SubGenre)+ @"', + '" + Country+ @"', + '" + ProgramUtils.Encode(Manufacturer)+ @"', + '" + strYear+ @"', + '" + Rating+ @"', + '" + ProgramUtils.Encode(Overview)+ @"', + '" + ProgramUtils.Encode(System_)+ @"', + '" + ProgramUtils.Encode(ManualFilename)+ @"', + '" + strLastLaunch+ @"', + '" + strLaunchCount+ @"', + '" + ProgramUtils.BooleanToStr(IsFolder)+ @"', + '" + ExtFileID+ @"', + '" + ProgramUtils.Encode(Title.ToUpper())+ @"', + '" + ProgramUtils.Encode(TagData)+ @"', + '" + ProgramUtils.Encode(CategoryData))+ @"', + '" + ProgramUtils.Encode(GameInfoURL)+ @"' + )"; // Log.Info("dw sql\n{0}", strSQL); sqlDB.Execute(strSQL); } @@ -656,118 +639,7 @@ } } - /* private void Insert() - { - string strLastLaunch = ""; - string strLaunchCount = ""; - string strYear = ""; - if (LastTimeLaunched != DateTime.MinValue) - { - strLastLaunch = String.Format("{0}", LastTimeLaunched); - } - if (LaunchCount > 0) - { - strLaunchCount = String.Format("{0}", LaunchCount); // poor man's inttostr :-) - } - if (Year > 0) - { - strYear = String.Format("{0}", Year); - } - - try - { - string strSQL = String.Format( - @" - INSERT INTO - tblFileItem ( - fileid, - appid, - title, - filename, - filepath, - imagefile, - genre, - genre2, - genre3, - genre4, - genre5, - country, - manufacturer, - year, - rating, - overview, - system, - manualfilename, - lastTimeLaunched, - launchcount, - isfolder, - external_id, - uppertitle, - tagdata, - categorydata - ) - - VALUES ( - null, - '{0}', - '{1}', - '{2}', - '{3}', - '{4}', - '{5}', - '{6}', - '{7}', - '{8}', - '{9}', - '{10}', - '{11}', - '{12}', - '{13}', - '{14}', - '{15}', - '{16}', - '{17}', - '{18}', - '{19}', - '{20}', - '{21}', - '{22}', - '{23}' - )", - AppID, - ProgramUtils.Encode(Title), - ProgramUtils.Encode(Filename), - ProgramUtils.Encode(Filepath), - ProgramUtils.Encode(Imagefile), - ProgramUtils.Encode(Genre), - ProgramUtils.Encode(Genre2), - ProgramUtils.Encode(Genre3), - ProgramUtils.Encode(Genre4), - ProgramUtils.Encode(Genre5), - Country, - ProgramUtils.Encode(Manufacturer), - strYear, - Rating, - ProgramUtils.Encode(Overview), - ProgramUtils.Encode(System_), - ProgramUtils.Encode(ManualFilename), - strLastLaunch, - strLaunchCount, - ProgramUtils.BooleanToStr(IsFolder), - ExtFileID, - ProgramUtils.Encode(Title.ToUpper()), - ProgramUtils.Encode(TagData), - ProgramUtils.Encode(CategoryData)); - // Log.Info("dw sql\n{0}", strSQL); - sqlDB.Execute(strSQL); - } - catch (SQLiteException ex) - { - Log.Info("programdatabase exception err:{0} stack:{1}", ex.Message, ex.StackTrace); - } - } - - */ + private void Update() { string strYear = ""; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |