Disable Ubuntu's global menu bar for Aegisub

wxWidgets currently doesn't generate menu open or update events for the
Ubuntu menubar (since GTK doesn't send the relevant signals to the
application), which we rely on.

Updates #1531.
This commit is contained in:
Thomas Goyne 2012-10-25 09:54:59 -07:00
parent 67c01d11f6
commit 78b70e987e
2 changed files with 6 additions and 1 deletions

View file

@ -131,6 +131,11 @@ void AegisubApp::OnAssertFailure(const wxChar *file, int line, const wxChar *fun
wxApp::OnAssertFailure(file, line, func, cond, msg); wxApp::OnAssertFailure(file, line, func, cond, msg);
} }
AegisubApp::AegisubApp() {
// http://trac.wxwidgets.org/ticket/14302
wxSetEnv("UBUNTU_MENUPROXY", "0");
}
/// @brief Gets called when application starts. /// @brief Gets called when application starts.
/// @return bool /// @return bool
bool AegisubApp::OnInit() { bool AegisubApp::OnInit() {

View file

@ -34,7 +34,6 @@
/// @ingroup main /// @ingroup main
/// ///
#ifndef AGI_PRE #ifndef AGI_PRE
#include <wx/app.h> #include <wx/app.h>
#include <wx/file.h> #include <wx/file.h>
@ -93,6 +92,7 @@ class AegisubApp: public wxApp {
void HandleEvent(wxEvtHandler *handler, wxEventFunction func, wxEvent& event) const; void HandleEvent(wxEvtHandler *handler, wxEventFunction func, wxEvent& event) const;
public: public:
AegisubApp();
AegisubLocale locale; AegisubLocale locale;
FrameMain *frame; FrameMain *frame;
Automation4::AutoloadScriptManager *global_scripts; Automation4::AutoloadScriptManager *global_scripts;