From ee9715392a67c92a3c199a47e23743f80a0ba7b8 Mon Sep 17 00:00:00 2001 From: Steve Brokenshire Date: Sun, 13 Mar 2016 11:26:44 +0000 Subject: [PATCH] Added comments to describe functions in contacteditor/frmContactEditor-Sound.cpp --- source/contacteditor/frmContactEditor-Sound.cpp | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/source/contacteditor/frmContactEditor-Sound.cpp b/source/contacteditor/frmContactEditor-Sound.cpp index 6138d97..45305b5 100644 --- a/source/contacteditor/frmContactEditor-Sound.cpp +++ b/source/contacteditor/frmContactEditor-Sound.cpp @@ -25,6 +25,8 @@ void frmContactEditor::AddSound( wxCommandEvent& event ) { + // Bring up a form to add sound. + int intResult = 0; frmContactEditorSound *frameCESound = new frmContactEditorSound ( this ); @@ -50,6 +52,8 @@ void frmContactEditor::AddSound( wxCommandEvent& event ) void frmContactEditor::ModifySound( wxCommandEvent& event ) { + // Bring up a form to modify sound. + long longSelected = -1; int intSelectedData = 0; @@ -81,6 +85,8 @@ void frmContactEditor::ModifySound( wxCommandEvent& event ) void frmContactEditor::DeleteSound( wxCommandEvent& event ) { + // Bring up a form to delete sound. + long longSelected = -1; int intSelectedData = 0; @@ -102,6 +108,8 @@ void frmContactEditor::DeleteSound( wxCommandEvent& event ) void frmContactEditor::PlaySoundDetach() { + // Play the sound and detach. + if (!AudioStreamPlayback.openFromMemory(base64dec.c_str(), base64declen)){ // Can't load file. We must flee... @@ -139,6 +147,8 @@ void frmContactEditor::PlaySoundDetach() void frmContactEditor::PlaySound( wxCommandEvent& event ) { + // Play the sound. + //sf::Music *AudioPlayback = new sf::Music; //AudioStream *AudioStreamPlayback = new AudioStream; //sf::SoundBuffer *AudioBuffer = new sf::SoundBuffer; @@ -190,6 +200,8 @@ void frmContactEditor::PlaySound( wxCommandEvent& event ) void frmContactEditor::StopSound( wxCommandEvent& event ) { + + // Stop the sound. if (AudioStreamPlayback.getStatus() == sf::SoundSource::Playing){ @@ -206,6 +218,8 @@ void frmContactEditor::StopSound( wxCommandEvent& event ) void frmContactEditor::SaveSound( wxCommandEvent &event ) { + // Save the sound. + long longSelected = -1; int intSelectedData = 0; -- 2.39.5