1
0
mirror of https://github.com/cookiengineer/audacity synced 2026-03-21 05:35:45 +01:00

Translate "Message" as default title of message box...

... This required a sweeping change of all calls to wxMessageBox!  But it seems
safe to me, despite the great number of touched files.
This commit is contained in:
Paul Licameli
2017-09-06 17:39:33 -04:00
parent 378c96fda1
commit ccb4bbac33
94 changed files with 369 additions and 344 deletions

View File

@@ -12,7 +12,6 @@
#include "ImportMIDI.h"
#include <wx/defs.h>
#include <wx/msgdlg.h>
#include <wx/ffile.h>
#include <wx/intl.h>
@@ -24,11 +23,14 @@
#include "../Internat.h"
#include "../NoteTrack.h"
#include "../widgets/ErrorDialog.h"
bool ImportMIDI(const wxString &fName, NoteTrack * dest)
{
if (fName.Length() <= 4){
wxMessageBox( _("Could not open file ") + fName + _(": Filename too short."));
AudacityMessageBox(
_("Could not open file ") + fName + _(": Filename too short.")
);
return false;
}
@@ -36,13 +38,17 @@ bool ImportMIDI(const wxString &fName, NoteTrack * dest)
if (fName.Right(4).CmpNoCase(wxT(".mid")) == 0 || fName.Right(5).CmpNoCase(wxT(".midi")) == 0)
is_midi = true;
else if(fName.Right(4).CmpNoCase(wxT(".gro")) != 0) {
wxMessageBox( _("Could not open file ") + fName + _(": Incorrect filetype."));
AudacityMessageBox(
_("Could not open file ") + fName + _(": Incorrect filetype.")
);
return false;
}
wxFFile mf(fName, wxT("rb"));
if (!mf.IsOpened()) {
wxMessageBox( _("Could not open file ") + fName + wxT("."));
AudacityMessageBox(
_("Could not open file ") + fName + wxT(".")
);
return false;
}
@@ -51,7 +57,9 @@ bool ImportMIDI(const wxString &fName, NoteTrack * dest)
//Should we also check if(seq->tracks() == 0) ?
if(new_seq->get_read_error() == alg_error_open){
wxMessageBox( _("Could not open file ") + fName + wxT("."));
AudacityMessageBox(
_("Could not open file ") + fName + wxT(".")
);
mf.Close();
return false;
}