This message is where the patches to get codesnippets plug-in to compile against wxWidgets 2.9 will be posted. Note, I have stopped updating this patch; no plans to update it till after 2.9.0 is released.
Index: src/plugins/contrib/codesnippets/editor/seditorcolourset.cpp
===================================================================
--- src/plugins/contrib/codesnippets/editor/seditorcolourset.cpp (revision 5270)
+++ src/plugins/contrib/codesnippets/editor/seditorcolourset.cpp (working copy)
@@ -112,7 +112,7 @@
wxString path = ConfigManager::GetFolder(sdDataUser) + _T("/lexers/");
if (dir.Open(path))
{
- Manager::Get()->GetLogManager()->Log(F(_("Scanning for lexers in %s..."), path.c_str()));
+ Manager::Get()->GetLogManager()->Log(F(_("Scanning for lexers in %s..."), path.wx_str()));
bool ok = dir.GetFirst(&filename, _T("lexer_*.xml"), wxDIR_FILES);
while(ok)
{
@@ -128,7 +128,7 @@
path = ConfigManager::GetFolder(sdDataGlobal) + _T("/lexers/");
if (dir.Open(path))
{
- Manager::Get()->GetLogManager()->Log(F(_("Scanning for lexers in %s..."), path.c_str()));
+ Manager::Get()->GetLogManager()->Log(F(_("Scanning for lexers in %s..."), path.wx_str()));
bool ok = dir.GetFirst(&filename, _T("lexer_*.xml"), wxDIR_FILES);
while(ok)
{
Index: src/plugins/contrib/codesnippets/codesnippetsapp.cpp
===================================================================
--- src/plugins/contrib/codesnippets/codesnippetsapp.cpp (revision 5207)
+++ src/plugins/contrib/codesnippets/codesnippetsapp.cpp (working copy)
@@ -58,6 +58,12 @@
//#include "../Utils/ToolBox/ToolBox.h" //debugging
+#if wxCHECK_VERSION(2,9,0)
+ #define CMDLINE_WXT(str) str
+#else
+ #define CMDLINE_WXT(str) wxT(str)
+#endif
+
#ifndef APP_PREFIX
#define APP_PREFIX ""
#endif
@@ -1396,11 +1402,11 @@
#if wxUSE_CMDLINE_PARSER
const wxCmdLineEntryDesc cmdLineDesc[] =
{
- { wxCMD_LINE_SWITCH, _T("h"), _T("help"), _T("show this help message"), wxCMD_LINE_VAL_NONE, wxCMD_LINE_OPTION_HELP },
- { wxCMD_LINE_OPTION, _T(""), _T("prefix"), _T("the shared data dir prefix"), wxCMD_LINE_VAL_STRING, wxCMD_LINE_NEEDS_SEPARATOR },
- { wxCMD_LINE_OPTION, _T("p"), _T("personality"), _T("the personality to use: \"ask\" or <personality-name>"), wxCMD_LINE_VAL_STRING, wxCMD_LINE_NEEDS_SEPARATOR },
- { wxCMD_LINE_OPTION, _T(""), _T("profile"), _T("synonym to personality"), wxCMD_LINE_VAL_STRING, wxCMD_LINE_NEEDS_SEPARATOR },
- { wxCMD_LINE_OPTION, _T(""), _T("KeepAlivePid"), _T("launchers pid"), wxCMD_LINE_VAL_STRING, wxCMD_LINE_NEEDS_SEPARATOR },
+ { wxCMD_LINE_SWITCH, CMDLINE_WXT("h"), CMDLINE_WXT("help"), CMDLINE_WXT("show this help message"), wxCMD_LINE_VAL_NONE, wxCMD_LINE_OPTION_HELP },
+ { wxCMD_LINE_OPTION, CMDLINE_WXT(""), CMDLINE_WXT("prefix"), CMDLINE_WXT("the shared data dir prefix"), wxCMD_LINE_VAL_STRING, wxCMD_LINE_NEEDS_SEPARATOR },
+ { wxCMD_LINE_OPTION, CMDLINE_WXT("p"), CMDLINE_WXT("personality"), CMDLINE_WXT("the personality to use: \"ask\" or <personality-name>"), wxCMD_LINE_VAL_STRING, wxCMD_LINE_NEEDS_SEPARATOR },
+ { wxCMD_LINE_OPTION, CMDLINE_WXT(""), CMDLINE_WXT("profile"), CMDLINE_WXT("synonym to personality"), wxCMD_LINE_VAL_STRING, wxCMD_LINE_NEEDS_SEPARATOR },
+ { wxCMD_LINE_OPTION, CMDLINE_WXT(""), CMDLINE_WXT("KeepAlivePid"), CMDLINE_WXT("launchers pid"), wxCMD_LINE_VAL_STRING, wxCMD_LINE_NEEDS_SEPARATOR },
{ wxCMD_LINE_NONE }
};
#endif // wxUSE_CMDLINE_PARSER
Index: src/plugins/contrib/codesnippets/snippetsconfig.cpp
===================================================================
--- src/plugins/contrib/codesnippets/snippetsconfig.cpp (revision 5211)
+++ src/plugins/contrib/codesnippets/snippetsconfig.cpp (working copy)
@@ -232,7 +232,7 @@
cfgFile.Write( wxT("SnippetFolder"), SettingsSnippetsFolder ) ;
cfgFile.Write( wxT("ViewSearchBox"), SettingsSearchBox ) ;
cfgFile.Write( wxT("casesensitive"), m_SearchConfig.caseSensitive ) ;
- cfgFile.Write( wxT("scope"), m_SearchConfig.scope );
+ cfgFile.Write( wxT("scope"), int(m_SearchConfig.scope) );
cfgFile.Write( wxT("EditorsStayOnTop"),SettingsEditorsStayOnTop );
if ( IsPlugin() )
{ // Write ExternalPersistent for plugin use only
Index: src/plugins/contrib/codesnippets/editor/seditorcolourset.cpp
===================================================================
--- src/plugins/contrib/codesnippets/editor/seditorcolourset.cpp (revision 5211)
+++ src/plugins/contrib/codesnippets/editor/seditorcolourset.cpp (working copy)
@@ -724,7 +724,7 @@
wxString tmp(_T(' '), keywords.length()); // faster than using Alloc()
const wxChar *src = keywords.c_str();
- wxChar *dst = (wxChar *) tmp.c_str();
+ wxChar *dst = (wxChar *)(const wxChar *) tmp.c_str(); //FIXME
wxChar c;
size_t len = 0;