Globally replace _T() with wxT().

Standardize on using a single macro across all wxWidgets sources and solve the name clash with Sun CC standard headers (see #10660).

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@61508 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin
2009-07-23 20:30:22 +00:00
parent 32cdc45397
commit 9a83f86094
798 changed files with 10370 additions and 10349 deletions

View File

@@ -40,7 +40,7 @@
#include "../sample.xpm"
#endif
#define WAV_FILE _T("doggrowl.wav")
#define WAV_FILE wxT("doggrowl.wav")
// ----------------------------------------------------------------------------
// private classes
@@ -166,7 +166,7 @@ bool MyApp::OnInit()
return false;
// create the main application window
MyFrame *frame = new MyFrame(_T("wxWidgets Sound Sample"));
MyFrame *frame = new MyFrame(wxT("wxWidgets Sound Sample"));
// and show it (the frames, unlike simple controls, are not shown when
// created initially)
@@ -194,32 +194,32 @@ MyFrame::MyFrame(const wxString& title)
SetIcon(wxICON(sample));
wxMenu *menuFile = new wxMenu;
menuFile->Append(Sound_SelectFile, _T("Select WAV &file...\tCtrl-O"), _T("Select a new wav file to play"));
menuFile->Append(Sound_SelectFile, wxT("Select WAV &file...\tCtrl-O"), wxT("Select a new wav file to play"));
#ifdef __WXMSW__
menuFile->Append(Sound_SelectResource, _T("Select WAV &resource...\tCtrl-R"), _T("Select a new resource to play"));
menuFile->Append(Sound_SelectMemory, _T("Select WAV &data\tCtrl-M"), _T("Choose to play from memory buffer"));
menuFile->Append(Sound_SelectResource, wxT("Select WAV &resource...\tCtrl-R"), wxT("Select a new resource to play"));
menuFile->Append(Sound_SelectMemory, wxT("Select WAV &data\tCtrl-M"), wxT("Choose to play from memory buffer"));
#endif // __WXMSW__
menuFile->Append(Sound_Quit, _T("E&xit\tAlt-X"), _T("Quit this program"));
menuFile->Append(Sound_Quit, wxT("E&xit\tAlt-X"), wxT("Quit this program"));
wxMenu *playMenu = new wxMenu;
playMenu->Append(Sound_PlaySync, _T("Play sound &synchronously\tCtrl-S"));
playMenu->Append(Sound_PlayAsync, _T("Play sound &asynchronously\tCtrl-A"));
playMenu->Append(Sound_PlayAsyncOnStack, _T("Play sound asynchronously (&object on stack)\tCtrl-K"));
playMenu->Append(Sound_PlayLoop, _T("&Loop sound\tCtrl-L"));
playMenu->Append(Sound_PlaySync, wxT("Play sound &synchronously\tCtrl-S"));
playMenu->Append(Sound_PlayAsync, wxT("Play sound &asynchronously\tCtrl-A"));
playMenu->Append(Sound_PlayAsyncOnStack, wxT("Play sound asynchronously (&object on stack)\tCtrl-K"));
playMenu->Append(Sound_PlayLoop, wxT("&Loop sound\tCtrl-L"));
playMenu->AppendSeparator();
playMenu->Append(Sound_Stop, _T("&Stop playing\tCtrl-T"));
playMenu->Append(Sound_Stop, wxT("&Stop playing\tCtrl-T"));
playMenu->AppendSeparator();
playMenu->Append(Sound_PlayBell, _T("Play system bell"));
playMenu->Append(Sound_PlayBell, wxT("Play system bell"));
wxMenu *helpMenu = new wxMenu;
helpMenu->Append(Sound_About, _T("&About...\tF1"), _T("Show about dialog"));
helpMenu->Append(Sound_About, wxT("&About...\tF1"), wxT("Show about dialog"));
// now append the freshly created menu to the menu bar...
wxMenuBar *menuBar = new wxMenuBar();
menuBar->Append(menuFile, _T("&File"));
menuBar->Append(playMenu, _T("&Play"));
menuBar->Append(helpMenu, _T("&Help"));
menuBar->Append(menuFile, wxT("&File"));
menuBar->Append(playMenu, wxT("&Play"));
menuBar->Append(helpMenu, wxT("&Help"));
// ... and attach this menu bar to the frame
SetMenuBar(menuBar);
@@ -980,7 +980,7 @@ bool MyFrame::CreateSound(wxSound& snd) const
void MyFrame::NotifyUsingFile(const wxString& name)
{
wxString msg;
msg << _T("Using sound file: ") << name << _T("\n");
msg << wxT("Using sound file: ") << name << wxT("\n");
m_tc->AppendText(msg);
}
@@ -991,9 +991,9 @@ void MyFrame::NotifyUsingFile(const wxString& name)
void MyFrame::OnSelectFile(wxCommandEvent& WXUNUSED(event))
{
#if wxUSE_FILEDLG
wxFileDialog dlg(this, _T("Choose a sound file"),
wxFileDialog dlg(this, wxT("Choose a sound file"),
wxEmptyString, wxEmptyString,
_T("WAV files (*.wav)|*.wav"), wxFD_OPEN|wxFD_CHANGE_DIR);
wxT("WAV files (*.wav)|*.wav"), wxFD_OPEN|wxFD_CHANGE_DIR);
if ( dlg.ShowModal() == wxID_OK )
{
m_soundFile = dlg.GetPath();
@@ -1015,9 +1015,9 @@ void MyFrame::OnSelectResource(wxCommandEvent& WXUNUSED(event))
{
m_soundRes = wxGetTextFromUser
(
_T("Enter resource name:"),
_T("wxWidgets Sound Sample"),
_T("FromResource"),
wxT("Enter resource name:"),
wxT("wxWidgets Sound Sample"),
wxT("FromResource"),
this
);
if ( m_soundRes.empty() )
@@ -1029,7 +1029,7 @@ void MyFrame::OnSelectResource(wxCommandEvent& WXUNUSED(event))
delete m_sound;
m_sound = NULL;
NotifyUsingFile(_T("Windows WAV resource"));
NotifyUsingFile(wxT("Windows WAV resource"));
}
#endif // __WXMSW__
@@ -1038,7 +1038,7 @@ void MyFrame::OnSelectMemory(wxCommandEvent& WXUNUSED(event))
{
m_useMemory = true;
NotifyUsingFile(_T("embedded sound fragment"));
NotifyUsingFile(wxT("embedded sound fragment"));
}
void MyFrame::OnQuit(wxCommandEvent& WXUNUSED(event))
@@ -1103,10 +1103,10 @@ void MyFrame::OnPlayBell(wxCommandEvent& WXUNUSED(event))
void MyFrame::OnAbout(wxCommandEvent& WXUNUSED(event))
{
wxString msg;
msg.Printf( _T("This is the About dialog of the sound sample.\n")
_T("Welcome to %s"), wxVERSION_STRING);
msg.Printf( wxT("This is the About dialog of the sound sample.\n")
wxT("Welcome to %s"), wxVERSION_STRING);
wxMessageBox(msg, _T("About"), wxOK | wxICON_INFORMATION, this);
wxMessageBox(msg, wxT("About"), wxOK | wxICON_INFORMATION, this);
}
void MyFrame::OnStop(wxCommandEvent& WXUNUSED(event))