Index: pcsx2.snapshot-3185/plugins/CDVDnull/Linux/Config.cpp =================================================================== --- pcsx2.snapshot-3185.orig/plugins/CDVDnull/Linux/Config.cpp 2010-06-10 15:41:19.391525024 +0200 +++ pcsx2.snapshot-3185/plugins/CDVDnull/Linux/Config.cpp 2010-06-10 15:45:25.552686133 +0200 @@ -24,6 +24,8 @@ #include GtkWidget *MsgDlg; +extern string s_strIniPath; +PluginConf Ini; void OnMsg_Ok() { @@ -73,6 +75,38 @@ gtk_main(); } +void CDVDconfigure() +{ + LoadConfig(); + PluginNullConfigure("Since this is a null plugin, all that is really configurable is logging.", conf.Log); + SaveConfig(); +} + void LoadConfig() { + const std::string iniFile(s_strIniPath + "/CDVDNull.ini"); + + if (!Ini.Open(iniFile, READ_FILE)) + { + printf("failed to open %s\n", iniFile.c_str()); + SaveConfig();//save and return + return; + } + + conf.Log = Ini.ReadInt("logging", 0); + Ini.Close(); +} + +void SaveConfig() +{ + const std::string iniFile(s_strIniPath + "/CDVDNull.ini"); + + if (!Ini.Open(iniFile, WRITE_FILE)) + { + printf("failed to open %s\n", iniFile.c_str()); + return; + } + + Ini.WriteInt("logging", conf.Log); + Ini.Close(); } Index: pcsx2.snapshot-3185/plugins/CDVDnull/CDVD.h =================================================================== --- pcsx2.snapshot-3185.orig/plugins/CDVDnull/CDVD.h 2010-06-10 15:41:15.267525668 +0200 +++ pcsx2.snapshot-3185/plugins/CDVDnull/CDVD.h 2010-06-10 15:51:09.344566061 +0200 @@ -23,6 +23,7 @@ #define CDVDdefs #include "PS2Edefs.h" +#include "PS2Eext.h" #ifdef __LINUX__ #include