DeviceFrame::DeviceFrame(audiere::AudioDevicePtr device) : wxMDIParentFrame(0, -1, wxT("Audio Device - " + CStr2wxString( device->getName() )), wxDefaultPosition, wxSize(400, 500)) { m_device = device; wxMenu* deviceMenu = new wxMenu(); deviceMenu->Append(DEVICE_NEW_DEVICE, wxT("&New Device...")); deviceMenu->Append(DEVICE_NEW_CDDEVICE, wxT("New C&D Device...")); deviceMenu->Append(DEVICE_NEW_MIDIDEVICE, wxT("New &MIDI Device...")); deviceMenu->AppendSeparator(); deviceMenu->Append(DEVICE_OPEN_STREAM, wxT("&Open Stream...")); deviceMenu->Append(DEVICE_OPEN_SOUND, wxT("Open &Sound...")); deviceMenu->AppendSeparator(); deviceMenu->Append(DEVICE_CREATE_TONE, wxT("Create &Tone...")); deviceMenu->Append(DEVICE_CREATE_SQUARE_WAVE, wxT("Create S&quare Wave...")); deviceMenu->Append(DEVICE_CREATE_WHITE_NOISE, wxT("Create &White Noise")); deviceMenu->Append(DEVICE_CREATE_PINK_NOISE, wxT("Create &Pink Noise")); deviceMenu->AppendSeparator(); deviceMenu->Append(DEVICE_OPEN_SINGLE_EFFECT, wxT("Open &Effect (Single)...")); deviceMenu->Append(DEVICE_OPEN_MULTIPLE_EFFECT, wxT("Open Effect (&Multiple)...")); deviceMenu->AppendSeparator(); deviceMenu->Append(DEVICE_CLOSE_WINDOW, wxT("Close C&urrent Window")); deviceMenu->Append(DEVICE_CLOSE, wxT("&Close Device")); wxMenu* helpMenu = new wxMenu(); helpMenu->Append(HELP_ABOUT, wxT("&About...")); wxMenuBar* menuBar = new wxMenuBar(); menuBar->Append(deviceMenu, wxT("&Device")); menuBar->Append(helpMenu, wxT("&Help")); SetMenuBar(menuBar); SetFocus(); }
void MainWindow::on_actionAbout_audiere_triggered() { QString content = tr("Audiere is a high-level audio engine <br/>"); QString address = "http://audiere.sourceforge.net/"; content.append(tr("Official site: <a href='%1'>%1</a> <br/>").arg(address)); content.append(tr("Current version %1 <br/>").arg(audiere::GetVersion())); content.append(tr("Device name: %1 <br/>").arg(Device->getName())); QMessageBox::about(this, tr("About audiere"), content); }