Update of /cvsroot/audacity/audacity-src/src In directory sc8-pr-cvs11.sourceforge.net:/tmp/cvs-serv15156/src
Modified Files: Project.cpp Menus.cpp Menus.h Project.h Log Message: Logger. Use wxLogMessage() to log, use "Help->Show log..." to show the log window. Index: Project.h =================================================================== RCS file: /cvsroot/audacity/audacity-src/src/Project.h,v retrieving revision 1.130 retrieving revision 1.131 diff -u -d -r1.130 -r1.131 --- Project.h 1 Jun 2008 06:57:29 -0000 1.130 +++ Project.h 2 Jun 2008 14:47:43 -0000 1.131 @@ -107,6 +107,8 @@ virtual ~ AudacityProject(); + wxLogWindow *mLogger; + TrackList *GetTracks() { return mTracks; }; UndoManager *GetUndoManager() { return &mUndoManager; } Index: Menus.h =================================================================== RCS file: /cvsroot/audacity/audacity-src/src/Menus.h,v retrieving revision 1.118 retrieving revision 1.119 diff -u -d -r1.118 -r1.119 --- Menus.h 29 Mar 2008 20:33:12 -0000 1.118 +++ Menus.h 2 Jun 2008 14:47:43 -0000 1.119 @@ -288,6 +288,7 @@ void OnAbout(); void OnHelp(); +void OnLog(); void OnHelpWelcome(); void OnBenchmark(); void OnScreenshot(); Index: Menus.cpp =================================================================== RCS file: /cvsroot/audacity/audacity-src/src/Menus.cpp,v retrieving revision 1.371 retrieving revision 1.372 diff -u -d -r1.371 -r1.372 --- Menus.cpp 1 Jun 2008 06:57:29 -0000 1.371 +++ Menus.cpp 2 Jun 2008 14:47:41 -0000 1.372 @@ -744,6 +744,7 @@ c->AddItem(wxT("Welcome"), _("&Show Welcome Message..."), FN(OnHelpWelcome)); c->AddItem(wxT("Help"), _("&Index..."), FN(OnHelp)); + c->AddItem(wxT("Log"), _("Show &log..."), FN(OnLog)); #if 1 // Debugging tools are enabled in unstable builds @@ -4373,6 +4374,11 @@ //wxT("http://audacity.sourceforge.net/help/documentation" )); } +void AudacityProject::OnLog() +{ + if (mLogger) mLogger->Show(); +} + void AudacityProject::OnBenchmark() { ::RunBenchmark(this); Index: Project.cpp =================================================================== RCS file: /cvsroot/audacity/audacity-src/src/Project.cpp,v retrieving revision 1.354 retrieving revision 1.355 diff -u -d -r1.354 -r1.355 --- Project.cpp 1 Jun 2008 06:57:29 -0000 1.354 +++ Project.cpp 2 Jun 2008 14:47:41 -0000 1.355 @@ -534,6 +534,12 @@ mRecordingRecoveryHandler(NULL), mImportedDependencies(false) { + mLogger = new wxLogWindow(NULL,wxT("Debug log"), false, false); + mLogger->SetActiveTarget(mLogger); + mLogger->EnableLogging(true); + mLogger->SetLogLevel(wxLOG_Max); + + int widths[] = {-1, 130}; mStatusBar = CreateStatusBar(2); mStatusBar->SetStatusWidths(2, widths); @@ -1625,6 +1631,14 @@ } } + if (mLogger) + { + mLogger->SetLogLevel(0); + mLogger->EnableLogging(false); + mLogger->SetActiveTarget(NULL); + delete mLogger; + } + Destroy(); } ------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2008. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ _______________________________________________ Audacity-cvs mailing list Audacity-cvs@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/audacity-cvs