1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-07-18 17:47:41 +02:00
audacity/src/AudacityLogger.h
Paul Licameli 990080ae7d Replace virtual with override wherever possible; eliminate needless virtual...
... for functions in final classes.

override is like const -- it's not necessary, but it helps the compiler to
catch mistakes.

There may be some overriding functions not explicitly declared virtual and I did
not identify such cases, in which I might also add override.
2016-02-26 12:35:38 -05:00

56 lines
1.1 KiB
C++

/**********************************************************************
Audacity: A Digital Audio Editor
AudacityLogger.h
Dominic Mazzoni
This is the main source file for Audacity which handles
initialization and termination by subclassing wxApp.
**********************************************************************/
#ifndef __AUDACITY_LOGGER__
#define __AUDACITY_LOGGER__
#include "Audacity.h"
#include <wx/event.h>
#include <wx/log.h>
#include <wx/frame.h>
#include <wx/textctrl.h>
#include <wx/string.h>
#include "Experimental.h"
class AudacityLogger final : public wxEvtHandler, public wxLog {
public:
AudacityLogger();
virtual ~AudacityLogger();
void Show(bool show = true);
void Destroy();
#if defined(EXPERIMENTAL_CRASH_REPORT)
wxString GetLog();
#endif
protected:
void Flush() override;
void DoLogText(const wxString & msg) override;
private:
void OnCloseWindow(wxCloseEvent & e);
void OnClose(wxCommandEvent & e);
void OnClear(wxCommandEvent & e);
void OnSave(wxCommandEvent & e);
wxFrame *mFrame;
wxTextCtrl *mText;
wxString mBuffer;
bool mUpdated;
};
#endif