Audacity 3.2.0
Public Member Functions | Public Attributes | List of all members
MusicalInstrument Class Reference

#include <MixerBoard.h>

Collaboration diagram for MusicalInstrument:
[legend]

Public Member Functions

 MusicalInstrument (std::unique_ptr< wxBitmap > &&pBitmap, const wxString &strXPMfilename)
 
virtual ~MusicalInstrument ()
 

Public Attributes

std::unique_ptr< wxBitmap > mBitmap
 
wxArrayString mKeywords
 

Detailed Description

Definition at line 158 of file MixerBoard.h.

Constructor & Destructor Documentation

◆ MusicalInstrument()

MusicalInstrument::MusicalInstrument ( std::unique_ptr< wxBitmap > &&  pBitmap,
const wxString &  strXPMfilename 
)

Definition at line 818 of file MixerBoard.cpp.

819{
820 mBitmap = std::move(pBitmap);
821
822 int nUnderscoreIndex;
823 wxString strFilename = strXPMfilename;
824 strFilename.MakeLower(); // Make sure, so we don't have to do case insensitive comparison.
825 wxString strKeyword;
826 while ((nUnderscoreIndex = strFilename.Find(wxT('_'))) != -1)
827 {
828 strKeyword = strFilename.Left(nUnderscoreIndex);
829 mKeywords.push_back(strKeyword);
830 strFilename = strFilename.Mid(nUnderscoreIndex + 1);
831 }
832 if (!strFilename.empty()) // Skip trailing underscores.
833 mKeywords.push_back(strFilename); // Add the last one.
834}
wxT("CloseDown"))
std::unique_ptr< wxBitmap > mBitmap
Definition: MixerBoard.h:164
wxArrayString mKeywords
Definition: MixerBoard.h:165

References mBitmap, mKeywords, and wxT().

Here is the call graph for this function:

◆ ~MusicalInstrument()

MusicalInstrument::~MusicalInstrument ( )
virtual

Definition at line 836 of file MixerBoard.cpp.

837{
838 mKeywords.clear();
839}

References mKeywords.

Member Data Documentation

◆ mBitmap

std::unique_ptr<wxBitmap> MusicalInstrument::mBitmap

Definition at line 164 of file MixerBoard.h.

Referenced by MusicalInstrument().

◆ mKeywords

wxArrayString MusicalInstrument::mKeywords

Definition at line 165 of file MixerBoard.h.

Referenced by MusicalInstrument(), and ~MusicalInstrument().


The documentation for this class was generated from the following files: