Fix compilation errors

Originally committed to SVN as r5601.
This commit is contained in:
Thomas Goyne 2011-09-15 06:03:13 +00:00
parent 683dd6c0a9
commit d70fb7fe2d
7 changed files with 15 additions and 3 deletions

View file

@ -93,7 +93,7 @@ namespace Aegisub {
/// ///
const char *GetName() { return "internal_error/invalid_margin_id"; } const char *GetName() { return "internal_error/invalid_margin_id"; }
}; };
}; }

View file

@ -1015,7 +1015,7 @@ namespace Automation4 {
description = wxString(lua_tostring(L, 1), wxConvUTF8); description = wxString(lua_tostring(L, 1), wxConvUTF8);
lua_pop(L, 1); lua_pop(L, 1);
} }
laf->ass->Commit(description); laf->ass->Commit(description, AssFile::COMMIT_NEW);
return 0; return 0;
} }

View file

@ -28,6 +28,7 @@
#ifndef AGI_PRE #ifndef AGI_PRE
#include <wx/checkbox.h> #include <wx/checkbox.h>
#include <wx/combobox.h> #include <wx/combobox.h>
#include <wx/msgdlg.h>
#include <wx/radiobox.h> #include <wx/radiobox.h>
#include <wx/radiobut.h> #include <wx/radiobut.h>
#include <wx/regex.h> #include <wx/regex.h>
@ -80,7 +81,7 @@ std::tr1::function<bool (wxString)> get_predicate(int mode, wxRegEx *re, bool ma
switch (mode) { switch (mode) {
case MODE_REGEXP: case MODE_REGEXP:
return bind(&wxRegEx::Matches, re, _1, 0); return bind(static_cast<bool (wxRegEx::*)(wxString const&,int) const>(&wxRegEx::Matches), re, _1, 0);
case MODE_EXACT: case MODE_EXACT:
if (match_case) if (match_case)
return bind(std::equal_to<wxString>(), match_text, _1); return bind(std::equal_to<wxString>(), match_text, _1);

View file

@ -34,6 +34,7 @@
#include <wx/listbox.h> #include <wx/listbox.h>
#include <wx/radiobox.h> #include <wx/radiobox.h>
#include <wx/radiobut.h> #include <wx/radiobut.h>
#include <wx/sizer.h>
#include <wx/textctrl.h> #include <wx/textctrl.h>
#endif #endif

View file

@ -27,6 +27,9 @@
#include <wx/combobox.h> #include <wx/combobox.h>
#include <wx/intl.h> #include <wx/intl.h>
#include <wx/listbox.h> #include <wx/listbox.h>
#include <wx/msgdlg.h>
#include <wx/sizer.h>
#include <wx/stattext.h>
#include <wx/textctrl.h> #include <wx/textctrl.h>
#endif #endif

View file

@ -26,8 +26,10 @@
namespace agi { struct Context; } namespace agi { struct Context; }
class wxFrame;
class wxMenu; class wxMenu;
class wxMenuBar; class wxMenuBar;
class wxWindow;
namespace menu { namespace menu {
DEFINE_BASE_EXCEPTION_NOINNER(Error, agi::Exception) DEFINE_BASE_EXCEPTION_NOINNER(Error, agi::Exception)

View file

@ -39,6 +39,9 @@
#include <vector> #include <vector>
#include <wx/app.h> #include <wx/app.h>
#include <wx/filename.h>
#include <wx/frame.h>
#include <wx/menu.h>
#include <wx/menuitem.h> #include <wx/menuitem.h>
#endif #endif
@ -301,6 +304,8 @@ void process_menu_item(wxMenu *parent, agi::Context *c, json::Object const& ele,
else if (special == "options") else if (special == "options")
wxApp::s_macPreferencesMenuItemId = id; wxApp::s_macPreferencesMenuItemId = id;
} }
#else
(void)id;
#endif #endif
} }
catch (agi::Exception const& e) { catch (agi::Exception const& e) {