You can subscribe to this list here.
2008 |
Jan
|
Feb
|
Mar
(58) |
Apr
(100) |
May
(92) |
Jun
(12) |
Jul
|
Aug
|
Sep
(5) |
Oct
(1) |
Nov
(26) |
Dec
(29) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2009 |
Jan
(31) |
Feb
(20) |
Mar
(1) |
Apr
|
May
(5) |
Jun
(10) |
Jul
|
Aug
(2) |
Sep
|
Oct
(2) |
Nov
|
Dec
(1) |
2010 |
Jan
(1) |
Feb
(1) |
Mar
|
Apr
(36) |
May
(10) |
Jun
|
Jul
(38) |
Aug
(2) |
Sep
|
Oct
|
Nov
|
Dec
|
2011 |
Jan
|
Feb
(6) |
Mar
(8) |
Apr
|
May
|
Jun
|
Jul
(14) |
Aug
(56) |
Sep
|
Oct
|
Nov
|
Dec
|
2012 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(1) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
(13) |
Dec
(2) |
2013 |
Jan
(30) |
Feb
|
Mar
(43) |
Apr
(28) |
May
|
Jun
|
Jul
(2) |
Aug
|
Sep
|
Oct
(10) |
Nov
(2) |
Dec
|
2014 |
Jan
|
Feb
(2) |
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: <pst...@us...> - 2009-01-01 03:13:13
|
Revision: 668 http://jazzplusplus.svn.sourceforge.net/jazzplusplus/?rev=668&view=rev Author: pstieber Date: 2009-01-01 03:13:07 +0000 (Thu, 01 Jan 2009) Log Message: ----------- Added the new source modules to the Linux build. Modified Paths: -------------- trunk/jazz/src/Makefile.am Modified: trunk/jazz/src/Makefile.am =================================================================== --- trunk/jazz/src/Makefile.am 2009-01-01 03:12:31 UTC (rev 667) +++ trunk/jazz/src/Makefile.am 2009-01-01 03:13:07 UTC (rev 668) @@ -22,6 +22,8 @@ DeprecatedWx/prop.cpp \ DeprecatedWx/propform.cpp \ DeprecatedWx/proplist.cpp \ +Dialogs/FilterDialog.cpp \ +Dialogs/IntegerEdit.cpp \ Dialogs/KeyOnDialog.cpp \ Dialogs/MetronomeSettingsDialog.cpp \ Dialogs/SynthesizerSettingsDialog.cpp \ @@ -99,6 +101,8 @@ DeprecatedWx/prop.cpp \ DeprecatedWx/propform.cpp \ DeprecatedWx/proplist.cpp \ +Dialogs/FilterDialog.cpp \ +Dialogs/IntegerEdit.cpp \ Dialogs/KeyOnDialog.cpp \ Dialogs/MetronomeSettingsDialog.cpp \ Dialogs/SynthesizerSettingsDialog.cpp \ @@ -181,6 +185,8 @@ DeprecatedWx/propform.h \ DeprecatedWx/proplist.h \ DeprecatedStringUtils.h \ +Dialogs/FilterDialog.h \ +Dialogs/IntegerEdit.h \ Dialogs/KeyOnDialog.h \ Dialogs/MetronomeSettingsDialog.h \ Dialogs/SynthesizerSettingsDialog.h \ This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <pst...@us...> - 2009-01-01 03:12:34
|
Revision: 667 http://jazzplusplus.svn.sourceforge.net/jazzplusplus/?rev=667&view=rev Author: pstieber Date: 2009-01-01 03:12:31 +0000 (Thu, 01 Jan 2009) Log Message: ----------- Added a new integer edit control class and a new filter dialog class. Added Paths: ----------- trunk/jazz/src/Dialogs/FilterDialog.cpp trunk/jazz/src/Dialogs/FilterDialog.h trunk/jazz/src/Dialogs/IntegerEdit.cpp trunk/jazz/src/Dialogs/IntegerEdit.h Added: trunk/jazz/src/Dialogs/FilterDialog.cpp =================================================================== --- trunk/jazz/src/Dialogs/FilterDialog.cpp (rev 0) +++ trunk/jazz/src/Dialogs/FilterDialog.cpp 2009-01-01 03:12:31 UTC (rev 667) @@ -0,0 +1,537 @@ +//***************************************************************************** +// The JAZZ++ Midi Sequencer +// +// Copyright (C) 2008 Peter J. Stieber, all rights reserved. +// +// This program is free software; you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation; either version 2 of the License, or +// (at your option) any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program; if not, write to the Free Software +// Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. +//***************************************************************************** + +#include "FilterDialog.h" + +#include "../Filter.h" +#include "IntegerEdit.h" + +#include <wx/button.h> +#include <wx/checkbox.h> +#include <wx/msgdlg.h> +#include <wx/sizer.h> +#include <wx/stattext.h> +#include <wx/textctrl.h> + +#include <string> + +using namespace std; + +//***************************************************************************** +//***************************************************************************** +//----------------------------------------------------------------------------- +//----------------------------------------------------------------------------- +BEGIN_EVENT_TABLE(JZFilterDialog, wxDialog) + + EVT_BUTTON(wxID_HELP, JZFilterDialog::OnHelp) + +END_EVENT_TABLE() + +//----------------------------------------------------------------------------- +//----------------------------------------------------------------------------- +JZFilterDialog::JZFilterDialog(JZFilter& Filter, wxWindow* pParent) + : wxDialog(pParent, wxID_ANY, wxString("Event Filter")), + mFilter(Filter), + mpFromTimeEdit(0), + mpToTimeEdit(0), + mpFromTrackEdit(0), + mpToTrackEdit(0), + mpNoteCheckBox(0), + mpNoteMinEdit(0), + mpNoteMaxEdit(0), + mpPolyAftertouchCheckBox(0), + mpPolyAftertouchMinEdit(0), + mpPolyAftertouchMaxEdit(0), + mpControllerCheckBox(0), + mpControllerMinEdit(0), + mpControllerMaxEdit(0), + mpPatchCheckBox(0), + mpPatchMinEdit(0), + mpPatchMaxEdit(0), + mpPitchCheckBox(0), + mpPitchMinEdit(0), + mpPitchMaxEdit(0), + mpMeterCheckBox(0), + mpChannelAftertouchCheckBox(0), + mpSysExCheckBox(0), + mpOtherBox(0) +{ + mpFromTimeEdit = new wxTextCtrl(this, wxID_ANY); + mpToTimeEdit = new wxTextCtrl(this, wxID_ANY); + + mpFromTrackEdit = new JZIntegerEdit(this, wxID_ANY); + mpFromTrackEdit->SetValueName("FromTrack"); + mpFromTrackEdit->SetMinAndMax(1, 127); + mpToTrackEdit = new JZIntegerEdit(this, wxID_ANY); + mpToTrackEdit->SetValueName("To Track"); + mpToTrackEdit->SetMinAndMax(1, 127); + + mpNoteCheckBox = new wxCheckBox(this, wxID_ANY, "Note"); + mpNoteMinEdit = new JZIntegerEdit(this, wxID_ANY); + mpNoteMinEdit->SetValueName("Note Minimum"); + mpNoteMinEdit->SetMinAndMax(0, 127); + mpNoteMaxEdit = new JZIntegerEdit(this, wxID_ANY); + mpNoteMaxEdit->SetValueName("Note Maximum"); + mpNoteMaxEdit->SetMinAndMax(0, 127); + + mpPolyAftertouchCheckBox = new wxCheckBox(this, wxID_ANY, "Poly Aftertouch"); + mpPolyAftertouchMinEdit = new JZIntegerEdit(this, wxID_ANY); + mpPolyAftertouchMinEdit->SetValueName("Poly Aftertouch Minimum"); + mpPolyAftertouchMinEdit->SetMinAndMax(0, 127); + mpPolyAftertouchMaxEdit = new JZIntegerEdit(this, wxID_ANY); + mpPolyAftertouchMaxEdit->SetValueName("Poly Aftertouch Maximum"); + mpPolyAftertouchMaxEdit->SetMinAndMax(0, 127); + + mpControllerCheckBox = new wxCheckBox(this, wxID_ANY, "Controller"); + mpControllerMinEdit = new JZIntegerEdit(this, wxID_ANY); + mpControllerMinEdit->SetValueName("Controller Minimum"); + mpControllerMinEdit->SetMinAndMax(0, 127); + mpControllerMaxEdit = new JZIntegerEdit(this, wxID_ANY); + mpControllerMaxEdit->SetValueName("Controller Maximum"); + mpControllerMaxEdit->SetMinAndMax(0, 127); + + mpPatchCheckBox = new wxCheckBox(this, wxID_ANY, "Patch"); + mpPatchMinEdit = new JZIntegerEdit(this, wxID_ANY); + mpPatchMinEdit->SetValueName("Patch Minimum"); + mpPatchMinEdit->SetMinAndMax(0, 127); + mpPatchMaxEdit = new JZIntegerEdit(this, wxID_ANY); + mpPatchMaxEdit->SetValueName("Patch Maximum"); + mpPatchMaxEdit->SetMinAndMax(0, 127); + + mpPitchCheckBox = new wxCheckBox(this, wxID_ANY, "Pitch"); + mpPitchMinEdit = new JZIntegerEdit(this, wxID_ANY); + mpPitchMinEdit->SetValueName("Pitch Minimum"); + mpPitchMinEdit->SetMinAndMax(-8192, 8192); + mpPitchMaxEdit = new JZIntegerEdit(this, wxID_ANY); + mpPitchMaxEdit->SetValueName("Pitch Maximum"); + mpPitchMaxEdit->SetMinAndMax(-8192, 8192); + + mpMeterCheckBox = new wxCheckBox(this, wxID_ANY, "Meter"); + + mpChannelAftertouchCheckBox = + new wxCheckBox(this, wxID_ANY, "Channel Aftertouch"); + + mpSysExCheckBox = new wxCheckBox(this, wxID_ANY, "SysEx"); + + mpOtherBox = new wxCheckBox(this, wxID_ANY, "Other"); + + wxButton* pOkButton = new wxButton(this, wxID_OK, "&OK"); + wxButton* pCancelButton = new wxButton(this, wxID_CANCEL, "Cancel"); + wxButton* pHelpButton = new wxButton(this, wxID_HELP, "Help"); + pOkButton->SetDefault(); + + wxBoxSizer* pTopSizer = new wxBoxSizer(wxVERTICAL); + + wxFlexGridSizer* pFlexGridSizer; + + pFlexGridSizer = new wxFlexGridSizer(2, 4, 4, 2); + + pFlexGridSizer->Add( + new wxStaticText(this, wxID_ANY, "From Time:"), + 0, + wxALIGN_CENTER_VERTICAL); + pFlexGridSizer->Add( + mpFromTimeEdit, + 0, + wxALIGN_CENTER_VERTICAL); + pFlexGridSizer->Add( + new wxStaticText(this, wxID_ANY, "To Time:"), + 0, + wxALIGN_CENTER_VERTICAL); + pFlexGridSizer->Add( + mpToTimeEdit, + 0, + wxALIGN_CENTER_VERTICAL); + + pFlexGridSizer->Add( + new wxStaticText(this, wxID_ANY, "From Track:"), + 0, + wxALIGN_CENTER_VERTICAL); + pFlexGridSizer->Add( + mpFromTrackEdit, + 0, + wxALIGN_CENTER_VERTICAL); + pFlexGridSizer->Add( + new wxStaticText(this, wxID_ANY, "To Track:"), + 0, + wxALIGN_CENTER_VERTICAL); + pFlexGridSizer->Add( + mpToTrackEdit, + 0, + wxALIGN_CENTER_VERTICAL); + + pTopSizer->Add(pFlexGridSizer, 0, wxCENTER | wxALL, 10); + + pFlexGridSizer = new wxFlexGridSizer(5, 5, 4, 2); + + pFlexGridSizer->Add( + mpNoteCheckBox, + 0, + wxALIGN_CENTER_VERTICAL); + pFlexGridSizer->Add( + new wxStaticText(this, wxID_ANY, "Min:"), + 0, + wxALIGN_CENTER_VERTICAL); + pFlexGridSizer->Add( + mpNoteMinEdit, + 0, + wxALIGN_CENTER_VERTICAL); + pFlexGridSizer->Add( + new wxStaticText(this, wxID_ANY, "Max:"), + 0, + wxALIGN_CENTER_VERTICAL); + pFlexGridSizer->Add( + mpNoteMaxEdit, + 0, + wxALIGN_CENTER_VERTICAL); + + pFlexGridSizer->Add( + mpPolyAftertouchCheckBox, + 0, + wxALIGN_CENTER_VERTICAL); + pFlexGridSizer->Add( + new wxStaticText(this, wxID_ANY, "Min:"), + 0, + wxALIGN_CENTER_VERTICAL); + pFlexGridSizer->Add( + mpPolyAftertouchMinEdit, + 0, + wxALIGN_CENTER_VERTICAL); + pFlexGridSizer->Add( + new wxStaticText(this, wxID_ANY, "Max:"), + 0, + wxALIGN_CENTER_VERTICAL); + pFlexGridSizer->Add( + mpPolyAftertouchMaxEdit, + 0, + wxALIGN_CENTER_VERTICAL); + + pFlexGridSizer->Add( + mpControllerCheckBox, + 0, + wxALIGN_CENTER_VERTICAL); + pFlexGridSizer->Add( + new wxStaticText(this, wxID_ANY, "Min:"), + 0, + wxALIGN_CENTER_VERTICAL); + pFlexGridSizer->Add( + mpControllerMinEdit, + 0, + wxALIGN_CENTER_VERTICAL); + pFlexGridSizer->Add( + new wxStaticText(this, wxID_ANY, "Max:"), + 0, + wxALIGN_CENTER_VERTICAL); + pFlexGridSizer->Add( + mpControllerMaxEdit, + 0, + wxALIGN_CENTER_VERTICAL); + + pFlexGridSizer->Add( + mpPatchCheckBox, + 0, + wxALIGN_CENTER_VERTICAL); + pFlexGridSizer->Add( + new wxStaticText(this, wxID_ANY, "Min:"), + 0, + wxALIGN_CENTER_VERTICAL); + pFlexGridSizer->Add( + mpPatchMinEdit, + 0, + wxALIGN_CENTER_VERTICAL); + pFlexGridSizer->Add( + new wxStaticText(this, wxID_ANY, "Max:"), + 0, + wxALIGN_CENTER_VERTICAL); + pFlexGridSizer->Add( + mpPatchMaxEdit, + 0, + wxALIGN_CENTER_VERTICAL); + + pFlexGridSizer->Add( + mpPitchCheckBox, + 0, + wxALIGN_CENTER_VERTICAL); + pFlexGridSizer->Add( + new wxStaticText(this, wxID_ANY, "Min:"), + 0, + wxALIGN_CENTER_VERTICAL); + pFlexGridSizer->Add( + mpPitchMinEdit, + 0, + wxALIGN_CENTER_VERTICAL); + pFlexGridSizer->Add( + new wxStaticText(this, wxID_ANY, "Max:"), + 0, + wxALIGN_CENTER_VERTICAL); + pFlexGridSizer->Add( + mpPitchMaxEdit, + 0, + wxALIGN_CENTER_VERTICAL); + + pTopSizer->Add(pFlexGridSizer, 0, wxCENTER | wxALL, 10); + + wxBoxSizer* pCheckBoxSizer = new wxBoxSizer(wxHORIZONTAL); + + pCheckBoxSizer->Add(mpMeterCheckBox, 0, wxALL, 5); + + pCheckBoxSizer->Add(mpChannelAftertouchCheckBox, 0, wxALL, 5); + + pCheckBoxSizer->Add(mpSysExCheckBox, 0, wxALL, 5); + + pCheckBoxSizer->Add(mpOtherBox, 0, wxALL, 5); + + pTopSizer->Add(pCheckBoxSizer, 0, wxCENTER | wxALL, 5); + + wxBoxSizer* pButtonSizer = new wxBoxSizer(wxHORIZONTAL); + pButtonSizer->Add(pOkButton, 0, wxALL, 5); + pButtonSizer->Add(pCancelButton, 0, wxALL, 5); + pButtonSizer->Add(pHelpButton, 0, wxALL, 5); + + pTopSizer->Add(pButtonSizer, 0, wxALIGN_CENTER | wxBOTTOM, 6); + + SetAutoLayout(true); + SetSizer(pTopSizer); + + pTopSizer->SetSizeHints(this); + pTopSizer->Fit(this); +} + +//----------------------------------------------------------------------------- +//----------------------------------------------------------------------------- +bool JZFilterDialog::TransferDataToWindow() +{ + string TimeString; + + mFilter.GenerateFromTimeString(TimeString); + mpFromTimeEdit->ChangeValue(TimeString); + + mFilter.GenerateToTimeString(TimeString); + mpToTimeEdit->ChangeValue(TimeString); + + mpFromTrackEdit->SetNumber(mFilter.GetFromTrack()); + mpToTrackEdit->SetNumber(mFilter.GetToTrack()); + + bool Selected; + int FromValue, ToValue; + + mFilter.GetFilterEvent(eFilterKeyOn, Selected, FromValue, ToValue); + mpNoteCheckBox->SetValue(Selected); + mpNoteMinEdit->SetNumber(FromValue); + mpNoteMaxEdit->SetNumber(ToValue); + + mFilter.GetFilterEvent(eFilterKeyPressure, Selected, FromValue, ToValue); + mpPolyAftertouchCheckBox->SetValue(Selected); + mpPolyAftertouchMinEdit->SetNumber(FromValue); + mpPolyAftertouchMaxEdit->SetNumber(ToValue); + + mFilter.GetFilterEvent(eFilterControl, Selected, FromValue, ToValue); + mpControllerCheckBox->SetValue(Selected); + mpControllerMinEdit->SetNumber(FromValue); + mpControllerMaxEdit->SetNumber(ToValue); + + mFilter.GetFilterEvent(eFilterProgram, Selected, FromValue, ToValue); + mpPatchCheckBox->SetValue(Selected); + mpPatchMinEdit->SetNumber(FromValue); + mpPatchMaxEdit->SetNumber(ToValue); + + mFilter.GetFilterEvent(eFilterPitch, Selected, FromValue, ToValue); + mpPitchCheckBox->SetValue(Selected); + mpPitchMinEdit->SetNumber(FromValue); + mpPitchMaxEdit->SetNumber(ToValue); + + mpMeterCheckBox->SetValue(mFilter.GetFilterMeter()); + + mpChannelAftertouchCheckBox->SetValue(mFilter.GetFilterChannelAftertouch()); + + mpSysExCheckBox->SetValue(mFilter.GetFilterSysEx()); + + mpOtherBox->SetValue(mFilter.GetFilterOther()); + + return true; +} + +//----------------------------------------------------------------------------- +//----------------------------------------------------------------------------- +bool JZFilterDialog::TransferDataFromWindow() +{ + int FromTrack, ToTrack; + int NoteMin, NoteMax; + int PolyAftertouchMin, PolyAftertouchMax; + int ControllerMin, ControllerMax; + int PatchMin, PatchMax; + int PitchMin, PitchMax; + + if ( + mpFromTrackEdit->GetNumber(FromTrack) && + mpToTrackEdit->GetNumber(ToTrack) && + mpNoteMinEdit->GetNumber(NoteMin) && + mpNoteMaxEdit->GetNumber(NoteMax) && + mpPolyAftertouchMinEdit->GetNumber(PolyAftertouchMin) && + mpPolyAftertouchMaxEdit->GetNumber(PolyAftertouchMax) && + mpControllerMinEdit->GetNumber(ControllerMin) && + mpControllerMaxEdit->GetNumber(ControllerMax) && + mpPatchMinEdit->GetNumber(PatchMin) && + mpPatchMaxEdit->GetNumber(PatchMax) && + mpPitchMinEdit->GetNumber(PitchMin) && + mpPitchMaxEdit->GetNumber(PitchMax)) + { + if (FromTrack > ToTrack) + { + ::wxMessageBox( + "The From Track must be less than or equal to the To Track", + "Invalid Track Values", + wxOK | wxICON_EXCLAMATION, + this); + + mpFromTrackEdit->SetFocus(); + + return false; + } + + if (NoteMin > NoteMax) + { + ::wxMessageBox( + "The Minimum Note must be less than or equal to the Maximum Note", + "Invalid Note Values", + wxOK | wxICON_EXCLAMATION, + this); + + mpNoteMinEdit->SetFocus(); + + return false; + } + + if (PolyAftertouchMin > PolyAftertouchMax) + { + ::wxMessageBox( + "The Minimum Poly Aftertouch must be less than or equal to the Maximum" + " Poly Aftertouch", + "Invalid Poly Aftertouch Values", + wxOK | wxICON_EXCLAMATION, + this); + + mpPolyAftertouchMinEdit->SetFocus(); + + return false; + } + + if (ControllerMin > ControllerMax) + { + ::wxMessageBox( + "The Minimum Controller must be less than or equal to the Maximum" + " Controller", + "Invalid Controller Values", + wxOK | wxICON_EXCLAMATION, + this); + + mpControllerMinEdit->SetFocus(); + + return false; + } + + if (PatchMin > PatchMax) + { + ::wxMessageBox( + "The Minimum Patch must be less than or equal to the Maximum Patch", + "Invalid Patch Values", + wxOK | wxICON_EXCLAMATION, + this); + + mpPatchMinEdit->SetFocus(); + + return false; + } + + if (PitchMin > PitchMax) + { + ::wxMessageBox( + "The Minimum Pitch must be less than or equal to the Maximum Pitch", + "Invalid Pitch Values", + wxOK | wxICON_EXCLAMATION, + this); + + mpPitchMinEdit->SetFocus(); + + return false; + } + + string TimeString; + + TimeString = mpFromTimeEdit->GetValue(); + mFilter.SetFromTime(TimeString); + + TimeString = mpToTimeEdit->GetValue(); + mFilter.SetToTime(TimeString); + + mFilter.SetFromTrack(FromTrack); + mFilter.SetToTrack(ToTrack); + + mFilter.SetFilterEvent( + eFilterKeyOn, + mpNoteCheckBox->GetValue(), + NoteMin, + NoteMax); + + mFilter.SetFilterEvent( + eFilterKeyPressure, + mpPolyAftertouchCheckBox->GetValue(), + PolyAftertouchMin, + PolyAftertouchMax); + + mFilter.SetFilterEvent( + eFilterControl, + mpControllerCheckBox->GetValue(), + ControllerMin, + ControllerMax); + + mFilter.SetFilterEvent( + eFilterProgram, + mpPatchCheckBox->GetValue(), + PatchMin, + PatchMax); + + mFilter.SetFilterEvent( + eFilterPitch, + mpPitchCheckBox->GetValue(), + PitchMin, + PitchMax); + + mFilter.SetFilterMeter(mpMeterCheckBox->GetValue()); + + mFilter.SetFilterChannelAftertouch( + mpChannelAftertouchCheckBox->GetValue()); + + mFilter.SetFilterSysEx(mpSysExCheckBox->GetValue()); + + mFilter.SetFilterOther(mpOtherBox->GetValue()); + + return true; + } + + return false; +} + +//----------------------------------------------------------------------------- +//----------------------------------------------------------------------------- +void JZFilterDialog::OnHelp(wxCommandEvent& Event) +{ +// gpHelpInstance->ShowTopic("Filter Dialog"); +} Property changes on: trunk/jazz/src/Dialogs/FilterDialog.cpp ___________________________________________________________________ Added: svn:eol-style + native Added: trunk/jazz/src/Dialogs/FilterDialog.h =================================================================== --- trunk/jazz/src/Dialogs/FilterDialog.h (rev 0) +++ trunk/jazz/src/Dialogs/FilterDialog.h 2009-01-01 03:12:31 UTC (rev 667) @@ -0,0 +1,89 @@ +//***************************************************************************** +// The JAZZ++ Midi Sequencer +// +// Copyright (C) 2008 Peter J. Stieber, all rights reserved. +// +// This program is free software; you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation; either version 2 of the License, or +// (at your option) any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program; if not, write to the Free Software +// Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. +//***************************************************************************** + +#ifndef JZ_FILTERDIALOG_H +#define JZ_FILTERDIALOG_H + +#include <wx/dialog.h> + +class JZFilter; +class JZIntegerEdit; +class wxCheckBox; +class wxTextCtrl; + +//***************************************************************************** +//***************************************************************************** +class JZFilterDialog : public wxDialog +{ + public: + + JZFilterDialog(JZFilter& Filter, wxWindow* pParent); + + private: + + virtual bool TransferDataToWindow(); + + virtual bool TransferDataFromWindow(); + + void OnHelp(wxCommandEvent& Event); + + private: + + JZFilter& mFilter; + + wxTextCtrl* mpFromTimeEdit; + wxTextCtrl* mpToTimeEdit; + + JZIntegerEdit* mpFromTrackEdit; + JZIntegerEdit* mpToTrackEdit; + + wxCheckBox* mpNoteCheckBox; + JZIntegerEdit* mpNoteMinEdit; + JZIntegerEdit* mpNoteMaxEdit; + + wxCheckBox* mpPolyAftertouchCheckBox; + JZIntegerEdit* mpPolyAftertouchMinEdit; + JZIntegerEdit* mpPolyAftertouchMaxEdit; + + wxCheckBox* mpControllerCheckBox; + JZIntegerEdit* mpControllerMinEdit; + JZIntegerEdit* mpControllerMaxEdit; + + wxCheckBox* mpPatchCheckBox; + JZIntegerEdit* mpPatchMinEdit; + JZIntegerEdit* mpPatchMaxEdit; + + wxCheckBox* mpPitchCheckBox; + JZIntegerEdit* mpPitchMinEdit; + JZIntegerEdit* mpPitchMaxEdit; + + wxCheckBox* mpMeterCheckBox; + + wxCheckBox* mpChannelAftertouchCheckBox; + + wxCheckBox* mpSysExCheckBox; + + wxCheckBox* mpOtherBox; + + DECLARE_EVENT_TABLE(); +}; + + +#endif // !defined(JZ_FILTERDIALOG_H) Property changes on: trunk/jazz/src/Dialogs/FilterDialog.h ___________________________________________________________________ Added: svn:eol-style + native Added: trunk/jazz/src/Dialogs/IntegerEdit.cpp =================================================================== --- trunk/jazz/src/Dialogs/IntegerEdit.cpp (rev 0) +++ trunk/jazz/src/Dialogs/IntegerEdit.cpp 2009-01-01 03:12:31 UTC (rev 667) @@ -0,0 +1,289 @@ +//***************************************************************************** +// The JAZZ++ Midi Sequencer +// +// Copyright (C) 2008 Peter J. Stieber, all rights reserved. +// +// This program is free software; you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation; either version 2 of the License, or +// (at your option) any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program; if not, write to the Free Software +// Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. +//***************************************************************************** + +#include "IntegerEdit.h" + +#include <wx/msgdlg.h> + +#include <cstdlib> +#include <limits> +#include <sstream> + +using namespace std; + +//***************************************************************************** +// Description: +// This is the integer field edit class definition. +//***************************************************************************** +//----------------------------------------------------------------------------- +//----------------------------------------------------------------------------- +BEGIN_EVENT_TABLE(JZIntegerEdit, wxTextCtrl) + EVT_CHAR(JZIntegerEdit::OnChar) +END_EVENT_TABLE() + +//----------------------------------------------------------------------------- +//----------------------------------------------------------------------------- +JZIntegerEdit::JZIntegerEdit( + wxWindow* pParent, + wxWindowID Id, + const wxPoint& Position, + const wxSize& Size, + long WindowStyle, + const wxValidator& Validator, + const wxString& Name) + : wxTextCtrl( + pParent, + Id, + wxEmptyString, + Position, + Size, + WindowStyle, + Validator, + Name), + mMin(numeric_limits<int>::min()), + mMax(numeric_limits<int>::max()), + mValueName() +{ +} + +//----------------------------------------------------------------------------- +//----------------------------------------------------------------------------- +void JZIntegerEdit::SetMinAndMax(int Min, int Max) +{ + if (Min <= Max) + { + mMin = Min; + mMax = Max; + } +} + +//----------------------------------------------------------------------------- +//----------------------------------------------------------------------------- +void JZIntegerEdit::SetValueName(const string& ValueName) +{ + mValueName = ValueName; +} + +//----------------------------------------------------------------------------- +//----------------------------------------------------------------------------- +bool JZIntegerEdit::GetNumber(int& Value) +{ + int TestValue; + bool Status = UnlimitedGetNumber(TestValue); + + ostringstream Oss; + if (mValueName.empty()) + { + Oss << "Value"; + } + else + { + Oss << mValueName; + } + + if (!Status) + { + Oss << " is not a valid number"; + } + else if (TestValue < mMin) + { + Oss << " must be greater than or equal to " << mMin; + Status = false; + } + else if (TestValue > mMax) + { + Oss << " must be less than or equal to " << mMax; + Status = false; + } + + if (!Status) + { + Oss << '.'; + ::wxMessageBox( + Oss.str().c_str(), + "Invalid Integer Value", + wxOK | wxICON_EXCLAMATION, + this); + SetFocus(); + SetSelection(0, GetLastPosition()); + } + else + { + Value = TestValue; + } + + return Status; +} + +//----------------------------------------------------------------------------- +//----------------------------------------------------------------------------- +bool JZIntegerEdit::IsValueValid(bool DisplayErrorMessage) +{ + int TestValue; + if (DisplayErrorMessage) + { + bool Status = UnlimitedGetNumber(TestValue); + // Prepare the initial portion of the error message. + ostringstream Oss; + if (mValueName.empty()) + { + Oss << "Value"; + } + else + { + Oss << mValueName; + } + if (!Status) + { + Oss << " is not a valid number"; + } + else if (TestValue < mMin) + { + Oss << " must be greater than or equal to " << mMin; + Status = false; + } + else if (TestValue > mMax) + { + Oss << " must be less than or equal to " << mMax; + Status = false; + } + if (!Status) + { + Oss << '.'; + ::wxMessageBox( + Oss.str().c_str(), + "Invalid Integer Value", + wxOK | wxICON_EXCLAMATION, + this); + SetFocus(); + SetSelection(0, GetLastPosition()); + } + return Status; + } + bool Status = UnlimitedGetNumber(TestValue); + if (!Status) + { + return false; + } + if (TestValue < mMin) + { + return false; + } + if (TestValue > mMax) + { + return false; + } + return true; +} + +//----------------------------------------------------------------------------- +//----------------------------------------------------------------------------- +bool JZIntegerEdit::UnlimitedGetNumber(int& Value) +{ + bool Status = true; + wxString ValueString = GetValue(); + long Test; + if (!ValueString.ToLong(&Test)) + { + Status = false; + Value = 0; + } + else + { + Value = static_cast<int>(Test); + } + return Status; +} + +//----------------------------------------------------------------------------- +//----------------------------------------------------------------------------- +void JZIntegerEdit::SetNumber(int Value) +{ + if (Value < mMin) + { + Value = mMin; + } + if (Value > mMax) + { + Value = mMax; + } + ostringstream Oss; + Oss << Value; + wxString ValueString(Oss.str().c_str()); + + // Quickly check to see if the text is really going to change. + // This reduces flicker in the control and prevents false modification + // messages from being sent. + int NewLength = ValueString.Length(); + wxString OldString = GetValue(); + int OldLength = OldString.Length(); + if ( + NewLength > eStringLength || + OldLength != NewLength || + OldString != ValueString) + { + // Go ahead and change the text without sending a wxWidgets text changing + // event. + ChangeValue(ValueString); + } +} + +//----------------------------------------------------------------------------- +// Filter the keys processed by the control. +//----------------------------------------------------------------------------- +void JZIntegerEdit::OnChar(wxKeyEvent& Event) +{ + //------------------------------------- + // Check for non character adding keys. + // WARNING: Paste Ctrl-V is a problem! + // Should check the content and length + // of the paste, but don't know how! + //------------------------------------- + // The (Key >= 1 && Key <= 26) logic was added to to allow control keys + // through for cut an paste operations inside the control. The control + // key/operation pairs include + // 3 Ctrl-C for copy. + // 22 Ctrl-V for paste. + // 24 Ctrl-X for cut. + int Key = Event.GetKeyCode(); + if ( + (Key == WXK_BACK) || (Key == WXK_DELETE) || + (Key == WXK_LEFT) || (Key == WXK_RIGHT) || + (Key == WXK_UP) || (Key == WXK_DOWN) || + (Key == WXK_HOME) || (Key == WXK_END) || + (Key == WXK_INSERT) || + (Key >= 1 && Key <= 26)) + { + wxTextCtrl::OnChar(Event); + } + + // Limit the number of characters allowed. + wxString ValueString = GetValue(); + if (ValueString.Length() >= eStringLength) + { + return; + } + + // Only allow certain keys. + if ((Key >= '0' && Key <= '9') || Key == '-') + { + wxTextCtrl::OnChar(Event); + } +} Property changes on: trunk/jazz/src/Dialogs/IntegerEdit.cpp ___________________________________________________________________ Added: svn:eol-style + native Added: trunk/jazz/src/Dialogs/IntegerEdit.h =================================================================== --- trunk/jazz/src/Dialogs/IntegerEdit.h (rev 0) +++ trunk/jazz/src/Dialogs/IntegerEdit.h 2009-01-01 03:12:31 UTC (rev 667) @@ -0,0 +1,79 @@ +//***************************************************************************** +// The JAZZ++ Midi Sequencer +// +// Copyright (C) 2008 Peter J. Stieber, all rights reserved. +// +// This program is free software; you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation; either version 2 of the License, or +// (at your option) any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program; if not, write to the Free Software +// Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. +//***************************************************************************** + +#ifndef TRC_INTEGEREDIT_H +#define TRC_INTEGEREDIT_H + +#include <wx/textctrl.h> + +#include <string> + +//***************************************************************************** +// Description: +// This is the integer edit class declaration. This is a control class +// that is used to edit integer values with minimum and maximum value +// checking. +//***************************************************************************** +class JZIntegerEdit : public wxTextCtrl +{ + public: + + enum TEConstants + { + eStringLength = 11 + }; + + JZIntegerEdit( + wxWindow* pParent, + wxWindowID Id, + const wxPoint& Position = wxDefaultPosition, + const wxSize& Size = wxDefaultSize, + long WindowStyle = 0, + const wxValidator& Validator = wxDefaultValidator, + const wxString& Name = wxTextCtrlNameStr); + + void SetMinAndMax(int Min, int Max); + + void SetValueName(const std::string& ValueName); + + virtual bool GetNumber(int& Value); + + virtual void SetNumber(int Value); + + virtual bool IsValueValid(bool DisplayErrorMessage = true); + + protected: + + void OnChar(wxKeyEvent& Event); + + bool UnlimitedGetNumber(int& Value); + + protected: + + int mMin; + + int mMax; + + std::string mValueName; + + DECLARE_EVENT_TABLE() +}; + +#endif // !defined(TRC_INTEGEREDIT_H) Property changes on: trunk/jazz/src/Dialogs/IntegerEdit.h ___________________________________________________________________ Added: svn:eol-style + native This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <pst...@us...> - 2008-12-31 03:34:14
|
Revision: 666 http://jazzplusplus.svn.sourceforge.net/jazzplusplus/?rev=666&view=rev Author: pstieber Date: 2008-12-31 03:34:11 +0000 (Wed, 31 Dec 2008) Log Message: ----------- Added a line indicating this version is used by developers to convert the code a more modern UI. Modified Paths: -------------- branches/jazz-4.1.3/src/about.cpp Modified: branches/jazz-4.1.3/src/about.cpp =================================================================== --- branches/jazz-4.1.3/src/about.cpp 2008-12-31 02:46:38 UTC (rev 665) +++ branches/jazz-4.1.3/src/about.cpp 2008-12-31 03:34:11 UTC (rev 666) @@ -30,6 +30,7 @@ Modifications Copyright (C) 2004 Patrick Earl\n\ Modifications Copyright (C) 2008 Peter J. Stieber\n\ \n\ +This version is used by developers to convert the code a more modern UI.\n\ See http://jazzplusplus.sourceforge.net for latest information.\n"; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <pst...@us...> - 2008-12-31 02:46:46
|
Revision: 665 http://jazzplusplus.svn.sourceforge.net/jazzplusplus/?rev=665&view=rev Author: pstieber Date: 2008-12-31 02:46:38 +0000 (Wed, 31 Dec 2008) Log Message: ----------- Fixed a typo in a comment. Modified Paths: -------------- branches/jazz-4.1.3/Jazz-4.1.3.nsi Modified: branches/jazz-4.1.3/Jazz-4.1.3.nsi =================================================================== --- branches/jazz-4.1.3/Jazz-4.1.3.nsi 2008-12-31 02:42:43 UTC (rev 664) +++ branches/jazz-4.1.3/Jazz-4.1.3.nsi 2008-12-31 02:46:38 UTC (rev 665) @@ -1,6 +1,6 @@ ; Jazz-4.1.3.nsi ; -; This script simnply places an old version of Jazz++ in a directory on +; This script simply places an old version of Jazz++ in a directory on ; the user's desktop. ;-------------------------------- @@ -11,10 +11,10 @@ ; The file to write. OutFile "Jazz-4.1.3-Installer.exe" -; The default installation directory +; The default installation directory. InstallDir $DESKTOP\Jazz-4.1.3 -; Request application privileges for Windows Vista +; Request application privileges for Windows Vista. RequestExecutionLevel user ;-------------------------------- This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <pst...@us...> - 2008-12-31 02:42:46
|
Revision: 664 http://jazzplusplus.svn.sourceforge.net/jazzplusplus/?rev=664&view=rev Author: pstieber Date: 2008-12-31 02:42:43 +0000 (Wed, 31 Dec 2008) Log Message: ----------- Added a very simple nullsoft installation script. Added Paths: ----------- branches/jazz-4.1.3/Jazz-4.1.3.nsi Added: branches/jazz-4.1.3/Jazz-4.1.3.nsi =================================================================== --- branches/jazz-4.1.3/Jazz-4.1.3.nsi (rev 0) +++ branches/jazz-4.1.3/Jazz-4.1.3.nsi 2008-12-31 02:42:43 UTC (rev 664) @@ -0,0 +1,61 @@ +; Jazz-4.1.3.nsi +; +; This script simnply places an old version of Jazz++ in a directory on +; the user's desktop. + +;-------------------------------- + +; The name of the installer. +Name "Jazz++ 4.1.3" + +; The file to write. +OutFile "Jazz-4.1.3-Installer.exe" + +; The default installation directory +InstallDir $DESKTOP\Jazz-4.1.3 + +; Request application privileges for Windows Vista +RequestExecutionLevel user + +;-------------------------------- + +; Pages + +Page directory +Page instfiles + +;-------------------------------- + +; The stuff to install +Section "" ; There is no components page, so the name is not important. + + ; Set output path to the installation directory and put the executable + ; in this directory. + SetOutPath $INSTDIR + File .\vc6\jazz32\release\jazz32.exe + + ; Now put the configuration files in a subdirectory. + SetOutPath "$INSTDIR\conf" + File .\jazz.cfg + File .\src\jazz.mid + File .\conf\ctrlnam.jzi + File .\conf\e26.jzi + File .\conf\e26voice.jzi + File .\conf\gm.jzi + File .\conf\gmdrmnam.jzi + File .\conf\gmdrmset.jzi + File .\conf\gmvoices.jzi + File .\conf\gs.jzi + File .\conf\gsdrmset.jzi + File .\conf\gsvoices.jzi + File .\conf\jv1000.jzi + File .\conf\README + File .\conf\sc88pdrm.jzi + File .\conf\sc88pro.jzi + File .\conf\sc88pvoi.jzi + File .\conf\xg.jzi + File .\conf\xgdrmnam.jzi + File .\conf\xgdrmset.jzi + File .\conf\xgvoices.jzi + +SectionEnd Property changes on: branches/jazz-4.1.3/Jazz-4.1.3.nsi ___________________________________________________________________ Added: svn:eol-style + native This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <pst...@us...> - 2008-12-30 22:55:14
|
Revision: 663 http://jazzplusplus.svn.sourceforge.net/jazzplusplus/?rev=663&view=rev Author: pstieber Date: 2008-12-30 22:55:10 +0000 (Tue, 30 Dec 2008) Log Message: ----------- Made a cosmetic change in a comment. Modified Paths: -------------- trunk/jazz/src/mswin/WindowsPlayer.cpp Modified: trunk/jazz/src/mswin/WindowsPlayer.cpp =================================================================== --- trunk/jazz/src/mswin/WindowsPlayer.cpp 2008-12-30 22:54:27 UTC (rev 662) +++ trunk/jazz/src/mswin/WindowsPlayer.cpp 2008-12-30 22:55:10 UTC (rev 663) @@ -1001,7 +1001,11 @@ { vector<pair<string, int> > MidiDevices; - // select input device + //========================= + // Select the input device. + //========================= + + // Get a list of the available input devices. UINT i; UINT InputMidiDeviceCount = midiInGetNumDevs(); for (i = 0; i < InputMidiDeviceCount; ++i) This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <pst...@us...> - 2008-12-30 22:54:31
|
Revision: 662 http://jazzplusplus.svn.sourceforge.net/jazzplusplus/?rev=662&view=rev Author: pstieber Date: 2008-12-30 22:54:27 +0000 (Tue, 30 Dec 2008) Log Message: ----------- Set the initial selection in the MIDI device list box based on the passed data. Modified Paths: -------------- trunk/jazz/src/MidiDeviceDialog.cpp Modified: trunk/jazz/src/MidiDeviceDialog.cpp =================================================================== --- trunk/jazz/src/MidiDeviceDialog.cpp 2008-12-30 22:53:35 UTC (rev 661) +++ trunk/jazz/src/MidiDeviceDialog.cpp 2008-12-30 22:54:27 UTC (rev 662) @@ -60,8 +60,16 @@ const string& MidiDeviceName = iMidiDevice->first; mpMidiDeviceListBox->Append(MidiDeviceName.c_str()); } - mpMidiDeviceListBox->SetSelection(0); + if (mDeviceIndex < static_cast<int>(mpMidiDeviceListBox->GetCount())) + { + mpMidiDeviceListBox->SetSelection(mDeviceIndex); + } + else + { + mpMidiDeviceListBox->SetSelection(0); + } + wxButton* pOkButton = new wxButton(this, wxID_OK, "&OK"); wxButton* pCancelButton = new wxButton(this, wxID_CANCEL, "Cancel"); wxButton* pHelpButton = new wxButton(this, wxID_HELP, "Help"); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <pst...@us...> - 2008-12-30 22:53:39
|
Revision: 661 http://jazzplusplus.svn.sourceforge.net/jazzplusplus/?rev=661&view=rev Author: pstieber Date: 2008-12-30 22:53:35 +0000 (Tue, 30 Dec 2008) Log Message: ----------- 1. Added some pointers to the initializer list. 2. Put the code that initializes the patch list in a separate member function called SetPatchListEntries. 3. Added code to determine if the track is changing from or to a drum channel and update the patch list if this changes. Modified Paths: -------------- trunk/jazz/src/Dialogs/TrackDialog.cpp trunk/jazz/src/Dialogs/TrackDialog.h Modified: trunk/jazz/src/Dialogs/TrackDialog.cpp =================================================================== --- trunk/jazz/src/Dialogs/TrackDialog.cpp 2008-12-27 18:49:04 UTC (rev 660) +++ trunk/jazz/src/Dialogs/TrackDialog.cpp 2008-12-30 22:53:35 UTC (rev 661) @@ -53,47 +53,17 @@ JZTrackDialog::JZTrackDialog(JZTrack& Track, wxWindow* pParent) : wxDialog(pParent, wxID_ANY, wxString("Track Settings")), mTrack(Track), + mLastTrackChannelWasDrums(Track.IsDrumTrack()), mpTrackNameEdit(0), - mpPatchListBox(0) + mpPatchListBox(0), + mpChannelValue(0), + mpChannelKnob(0) { mpTrackNameEdit = new wxTextCtrl(this, wxID_ANY); mpPatchListBox = new wxListBox(this, wxID_ANY); - if (mTrack.IsDrumTrack()) - { - const vector<pair<string, int> >& DrumSets = gpConfig->GetDrumSets(); - for ( - vector<pair<string, int> >::const_iterator iDrumSet = - DrumSets.begin(); - iDrumSet != DrumSets.end(); - ++iDrumSet) - { - const string& DrumSet = iDrumSet->first; + SetPatchListEntries(); - if (!DrumSet.empty()) - { - mpPatchListBox->Append(DrumSet.c_str()); - } - } - } - else - { - const vector<pair<string, int> >& VoiceNames = gpConfig->GetVoiceNames(); - for ( - vector<pair<string, int> >::const_iterator iVoiceName = - VoiceNames.begin(); - iVoiceName != VoiceNames.end(); - ++iVoiceName) - { - const string& VoiceName = iVoiceName->first; - - if (!VoiceName.empty()) - { - mpPatchListBox->Append(VoiceName.c_str()); - } - } - } - mpChannelValue = new wxStaticText(this, wxID_ANY, "00"); mpChannelKnob = new JZKnob(this, IDC_KB_CHANNEL, 0, 1, 16); @@ -150,6 +120,48 @@ //----------------------------------------------------------------------------- //----------------------------------------------------------------------------- +void JZTrackDialog::SetPatchListEntries() +{ + mpPatchListBox->Clear(); + + if (mTrack.IsDrumTrack()) + { + const vector<pair<string, int> >& DrumSets = gpConfig->GetDrumSets(); + for ( + vector<pair<string, int> >::const_iterator iDrumSet = + DrumSets.begin(); + iDrumSet != DrumSets.end(); + ++iDrumSet) + { + const string& DrumSet = iDrumSet->first; + + if (!DrumSet.empty()) + { + mpPatchListBox->Append(DrumSet.c_str()); + } + } + } + else + { + const vector<pair<string, int> >& VoiceNames = gpConfig->GetVoiceNames(); + for ( + vector<pair<string, int> >::const_iterator iVoiceName = + VoiceNames.begin(); + iVoiceName != VoiceNames.end(); + ++iVoiceName) + { + const string& VoiceName = iVoiceName->first; + + if (!VoiceName.empty()) + { + mpPatchListBox->Append(VoiceName.c_str()); + } + } + } +} + +//----------------------------------------------------------------------------- +//----------------------------------------------------------------------------- bool JZTrackDialog::TransferDataToWindow() { mpTrackNameEdit->ChangeValue(mTrack.GetName()); @@ -195,6 +207,17 @@ ostringstream Oss; Oss << Value; mpChannelValue->SetLabel(Oss.str().c_str()); + mTrack.Channel = Value; + + // Test to determine if the track channel toggled in our out of drum mode. + if (mLastTrackChannelWasDrums != mTrack.IsDrumTrack()) + { + // If it did switch, update the patch list entries. + SetPatchListEntries(); + } + + // Record if the current value for the channel indicates drums. + mLastTrackChannelWasDrums = mTrack.IsDrumTrack(); } //----------------------------------------------------------------------------- Modified: trunk/jazz/src/Dialogs/TrackDialog.h =================================================================== --- trunk/jazz/src/Dialogs/TrackDialog.h 2008-12-27 18:49:04 UTC (rev 660) +++ trunk/jazz/src/Dialogs/TrackDialog.h 2008-12-30 22:53:35 UTC (rev 661) @@ -40,6 +40,8 @@ private: + void SetPatchListEntries(); + virtual bool TransferDataToWindow(); virtual bool TransferDataFromWindow(); @@ -52,6 +54,8 @@ JZTrack& mTrack; + bool mLastTrackChannelWasDrums; + wxTextCtrl* mpTrackNameEdit; wxListBox* mpPatchListBox; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <pst...@us...> - 2008-12-27 18:49:07
|
Revision: 660 http://jazzplusplus.svn.sourceforge.net/jazzplusplus/?rev=660&view=rev Author: pstieber Date: 2008-12-27 18:49:04 +0000 (Sat, 27 Dec 2008) Log Message: ----------- Updated the includes in the ALSA code. Modified Paths: -------------- trunk/jazz/src/AlsaDriver.cpp trunk/jazz/src/AlsaPlayer.cpp Modified: trunk/jazz/src/AlsaDriver.cpp =================================================================== --- trunk/jazz/src/AlsaDriver.cpp 2008-12-27 18:18:38 UTC (rev 659) +++ trunk/jazz/src/AlsaDriver.cpp 2008-12-27 18:49:04 UTC (rev 660) @@ -36,10 +36,11 @@ #include "Configuration.h" #include "Globals.h" +#include <cerrno> +#include <cstdlib> +#include <iostream> +#include <sys/ioctl.h> #include <unistd.h> -#include <stdlib.h> -#include <sys/ioctl.h> -#include <errno.h> using namespace std; Modified: trunk/jazz/src/AlsaPlayer.cpp =================================================================== --- trunk/jazz/src/AlsaPlayer.cpp 2008-12-27 18:18:38 UTC (rev 659) +++ trunk/jazz/src/AlsaPlayer.cpp 2008-12-27 18:49:04 UTC (rev 660) @@ -38,11 +38,12 @@ #include "TrackFrame.h" #include "TrackWindow.h" -#include <stdlib.h> -#include <errno.h> -#include <sys/ioctl.h> +#include <wx/choicdlg.h> +#include <cerrno> +#include <cstdlib> #include <iostream> +#include <sys/ioctl.h> using namespace std; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <pst...@us...> - 2008-12-27 18:18:42
|
Revision: 659 http://jazzplusplus.svn.sourceforge.net/jazzplusplus/?rev=659&view=rev Author: pstieber Date: 2008-12-27 18:18:38 +0000 (Sat, 27 Dec 2008) Log Message: ----------- Removed WxWidgets.h. Modified Paths: -------------- trunk/jazz/src/Makefile.am Modified: trunk/jazz/src/Makefile.am =================================================================== --- trunk/jazz/src/Makefile.am 2008-12-27 02:52:58 UTC (rev 658) +++ trunk/jazz/src/Makefile.am 2008-12-27 18:18:38 UTC (rev 659) @@ -245,8 +245,7 @@ ToolBar.h \ TrackFrame.h \ Track.h \ -TrackWindow.h \ -WxWidgets.h +TrackWindow.h if !USE_ALSA jazz_LDFLAGS = -framework CoreMIDI -framework CoreAudio This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <pst...@us...> - 2008-12-27 02:53:01
|
Revision: 658 http://jazzplusplus.svn.sourceforge.net/jazzplusplus/?rev=658&view=rev Author: pstieber Date: 2008-12-27 02:52:58 +0000 (Sat, 27 Dec 2008) Log Message: ----------- Added a forward declaration. This gets the build working. Modified Paths: -------------- trunk/jazz/src/Rhythm.h Modified: trunk/jazz/src/Rhythm.h =================================================================== --- trunk/jazz/src/Rhythm.h 2008-12-27 02:51:38 UTC (rev 657) +++ trunk/jazz/src/Rhythm.h 2008-12-27 02:52:58 UTC (rev 658) @@ -39,6 +39,7 @@ class wxCheckBox; class wxListBox; class wxPanel; +class wxSlider; #define MAX_GROUPS 5 #define MAX_KEYS 20 This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <pst...@us...> - 2008-12-27 02:51:41
|
Revision: 657 http://jazzplusplus.svn.sourceforge.net/jazzplusplus/?rev=657&view=rev Author: pstieber Date: 2008-12-27 02:51:38 +0000 (Sat, 27 Dec 2008) Log Message: ----------- Added an include for the Linux build. Modified Paths: -------------- trunk/jazz/src/Player.cpp Modified: trunk/jazz/src/Player.cpp =================================================================== --- trunk/jazz/src/Player.cpp 2008-12-27 02:14:07 UTC (rev 656) +++ trunk/jazz/src/Player.cpp 2008-12-27 02:51:38 UTC (rev 657) @@ -31,6 +31,7 @@ #include "Audio.h" #include "Globals.h" +#include <wx/choicdlg.h> #include <wx/msgdlg.h> //#include <unistd.h> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <pst...@us...> - 2008-12-27 02:14:15
|
Revision: 655 http://jazzplusplus.svn.sourceforge.net/jazzplusplus/?rev=655&view=rev Author: pstieber Date: 2008-12-27 02:03:27 +0000 (Sat, 27 Dec 2008) Log Message: ----------- Changed VC8 to VC9 in the configuration names. Modified Paths: -------------- trunk/jazz/portmidi/pm_win/portmidi-VC9.vcproj trunk/jazz/portmidi/porttime/porttime-VC9.vcproj Modified: trunk/jazz/portmidi/pm_win/portmidi-VC9.vcproj =================================================================== --- trunk/jazz/portmidi/pm_win/portmidi-VC9.vcproj 2008-12-26 21:37:56 UTC (rev 654) +++ trunk/jazz/portmidi/pm_win/portmidi-VC9.vcproj 2008-12-27 02:03:27 UTC (rev 655) @@ -4,6 +4,7 @@ Version="9.00" Name="portmidi" ProjectGUID="{33E3B196-B9F4-4D0A-85E1-31C7BBD4967A}" + RootNamespace="portmidi" TargetFrameworkVersion="131072" > <Platforms> @@ -15,7 +16,7 @@ </ToolFiles> <Configurations> <Configuration - Name="Debug VC8|Win32" + Name="Debug VC9|Win32" OutputDirectory="$(ConfigurationName)" IntermediateDirectory="$(ConfigurationName)" ConfigurationType="4" @@ -89,7 +90,7 @@ /> </Configuration> <Configuration - Name="Release VC8|Win32" + Name="Release VC9|Win32" OutputDirectory="$(ConfigurationName)" IntermediateDirectory="$(ConfigurationName)" ConfigurationType="4" Modified: trunk/jazz/portmidi/porttime/porttime-VC9.vcproj =================================================================== --- trunk/jazz/portmidi/porttime/porttime-VC9.vcproj 2008-12-26 21:37:56 UTC (rev 654) +++ trunk/jazz/portmidi/porttime/porttime-VC9.vcproj 2008-12-27 02:03:27 UTC (rev 655) @@ -15,7 +15,7 @@ </ToolFiles> <Configurations> <Configuration - Name="Release VC8|Win32" + Name="Release VC9|Win32" OutputDirectory="$(ConfigurationName)" IntermediateDirectory="$(ConfigurationName)" ConfigurationType="4" @@ -88,7 +88,7 @@ /> </Configuration> <Configuration - Name="Debug VC8|Win32" + Name="Debug VC9|Win32" OutputDirectory="$(ConfigurationName)" IntermediateDirectory="$(ConfigurationName)" ConfigurationType="4" This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <pst...@us...> - 2008-12-27 02:14:12
|
Revision: 656 http://jazzplusplus.svn.sourceforge.net/jazzplusplus/?rev=656&view=rev Author: pstieber Date: 2008-12-27 02:14:07 +0000 (Sat, 27 Dec 2008) Log Message: ----------- Removed the use of WxWidgets.h and the file itself. This will break the Linux build for a short time, but I'm going to start working on it soon. Now I'm only using the minimal amount of wxWidgets includes necessary in each file and trying to make sure the header files are self contained. Modified Paths: -------------- trunk/jazz/src/AboutDialog.cpp trunk/jazz/src/AboutDialog.h trunk/jazz/src/AlsaDriver.cpp trunk/jazz/src/AlsaPlayer.cpp trunk/jazz/src/AlsaThru.cpp trunk/jazz/src/AsciiMidiFile.cpp trunk/jazz/src/Audio.cpp trunk/jazz/src/Audio.h trunk/jazz/src/AudioDriver.cpp trunk/jazz/src/ClockDialog.cpp trunk/jazz/src/Command.cpp trunk/jazz/src/Configuration.cpp trunk/jazz/src/Configuration.h trunk/jazz/src/ControlEdit.cpp trunk/jazz/src/ControlEdit.h trunk/jazz/src/Dialogs/KeyOnDialog.cpp trunk/jazz/src/Dialogs/KeyOnDialog.h trunk/jazz/src/Dialogs/MetronomeSettingsDialog.cpp trunk/jazz/src/Dialogs/MetronomeSettingsDialog.h trunk/jazz/src/Dialogs/SynthesizerSettingsDialog.cpp trunk/jazz/src/Dialogs/SynthesizerSettingsDialog.h trunk/jazz/src/Dialogs/TrackDialog.cpp trunk/jazz/src/Dialogs/TrackDialog.h trunk/jazz/src/Dialogs.cpp trunk/jazz/src/ErrorMessage.cpp trunk/jazz/src/EventWindow.cpp trunk/jazz/src/EventWindow.h trunk/jazz/src/Events.cpp trunk/jazz/src/Events.h trunk/jazz/src/FileSelector.cpp trunk/jazz/src/Filter.cpp trunk/jazz/src/Filter.h trunk/jazz/src/FindFile.cpp trunk/jazz/src/GetOptionIndex.cpp trunk/jazz/src/Globals.cpp trunk/jazz/src/GuitarFrame.cpp trunk/jazz/src/GuitarFrame.h trunk/jazz/src/GuitarSettingsDialog.cpp trunk/jazz/src/GuitarSettingsDialog.h trunk/jazz/src/GuitarWindow.cpp trunk/jazz/src/GuitarWindow.h trunk/jazz/src/Harmony.cpp trunk/jazz/src/Harmony.h trunk/jazz/src/HarmonyBrowserAnalyzer.cpp trunk/jazz/src/Help.cpp trunk/jazz/src/Help.h trunk/jazz/src/JazzPlusPlusApplication.cpp trunk/jazz/src/JazzPlusPlusApplication.h trunk/jazz/src/KeyDialog.cpp trunk/jazz/src/Knob.cpp trunk/jazz/src/Knob.h trunk/jazz/src/MeasureChoice.cpp trunk/jazz/src/Metronome.cpp trunk/jazz/src/MidiDeviceDialog.cpp trunk/jazz/src/MidiDeviceDialog.h trunk/jazz/src/MouseAction.cpp trunk/jazz/src/NamedChoice.cpp trunk/jazz/src/NamedChoice.h trunk/jazz/src/NamedValue.cpp trunk/jazz/src/NamedValueChoice.cpp trunk/jazz/src/NamedValueChoice.h trunk/jazz/src/PianoFrame.cpp trunk/jazz/src/PianoFrame.h trunk/jazz/src/PianoWindow.cpp trunk/jazz/src/PianoWindow.h trunk/jazz/src/Player.cpp trunk/jazz/src/PortMidiPlayer.cpp trunk/jazz/src/Project.cpp trunk/jazz/src/ProjectManager.cpp trunk/jazz/src/PropertyListDialog.cpp trunk/jazz/src/Random.cpp trunk/jazz/src/Random.h trunk/jazz/src/Rectangle.cpp trunk/jazz/src/Rectangle.h trunk/jazz/src/ResourceDialog.cpp trunk/jazz/src/ResourceDialog.h trunk/jazz/src/Rhythm.cpp trunk/jazz/src/Rhythm.h trunk/jazz/src/Sample.cpp trunk/jazz/src/SampleCommand.cpp trunk/jazz/src/SampleDialog.cpp trunk/jazz/src/SampleDialog.h trunk/jazz/src/SampleWindow.cpp trunk/jazz/src/SampleWindow.h trunk/jazz/src/SelectControllerDialog.cpp trunk/jazz/src/Signal2.cpp trunk/jazz/src/SliderWindow.cpp trunk/jazz/src/SliderWindow.h trunk/jazz/src/Song.cpp trunk/jazz/src/StandardFile.cpp trunk/jazz/src/Synth.cpp trunk/jazz/src/ToolBar.cpp trunk/jazz/src/ToolBar.h trunk/jazz/src/Track.cpp trunk/jazz/src/Track.h trunk/jazz/src/TrackFrame.cpp trunk/jazz/src/TrackFrame.h trunk/jazz/src/TrackWindow.cpp trunk/jazz/src/commands/copyCommand.cpp trunk/jazz/src/mswin/WindowsAudioInterface.cpp trunk/jazz/src/mswin/WindowsMidiInterface.cpp trunk/jazz/src/mswin/WindowsPlayer.cpp trunk/jazz/vc8/JazzPlusPlus-VC8.vcproj trunk/jazz/vc9/JazzPlusPlus-VC9.sln trunk/jazz/vc9/JazzPlusPlus-VC9.vcproj Removed Paths: ------------- trunk/jazz/src/WxWidgets.h Modified: trunk/jazz/src/AboutDialog.cpp =================================================================== --- trunk/jazz/src/AboutDialog.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/AboutDialog.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -20,22 +20,23 @@ // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. //***************************************************************************** -#include "WxWidgets.h" +#include "AboutDialog.h" -#include <wx/version.h> -#include <wx/html/htmlwin.h> - +#include "JazzPlusPlusApplication.h" #include "Resources.h" -#include "AboutDialog.h" -#include "JazzPlusPlusApplication.h" +#include <wx/button.h> +#include <wx/html/htmlwin.h> +#include <wx/sizer.h> +#include <wx/statbmp.h> +#include <wx/version.h> -#include "Bitmaps/JazzLogo.xpm" - #include <sstream> using namespace std; +#include "Bitmaps/JazzLogo.xpm" + //***************************************************************************** // Description: // This is the Jazz++ application about dialog box definion. Modified: trunk/jazz/src/AboutDialog.h =================================================================== --- trunk/jazz/src/AboutDialog.h 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/AboutDialog.h 2008-12-27 02:14:07 UTC (rev 656) @@ -23,6 +23,11 @@ #ifndef JZ_ABOUTDIALOG_H #define JZ_ABOUTDIALOG_H +#include <wx/dialog.h> + +class wxBitmap; +class wxStaticBitmap; + //***************************************************************************** // Description: // This is the JAZZ++ about dialog declaration. Modified: trunk/jazz/src/AlsaDriver.cpp =================================================================== --- trunk/jazz/src/AlsaDriver.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/AlsaDriver.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -29,8 +29,6 @@ // Initial version: only playback is tested. //***************************************************************************** -#include "WxWidgets.h" - #include "AlsaDriver.h" #include "TrackFrame.h" Modified: trunk/jazz/src/AlsaPlayer.cpp =================================================================== --- trunk/jazz/src/AlsaPlayer.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/AlsaPlayer.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -29,15 +29,14 @@ // like OSS driver mode. //***************************************************************************** -#include "WxWidgets.h" - #include "AlsaPlayer.h" + +#include "Configuration.h" +#include "Dialogs.h" +#include "Globals.h" #include "ProjectManager.h" #include "TrackFrame.h" #include "TrackWindow.h" -#include "Dialogs.h" -#include "Configuration.h" -#include "Globals.h" #include <stdlib.h> #include <errno.h> Modified: trunk/jazz/src/AlsaThru.cpp =================================================================== --- trunk/jazz/src/AlsaThru.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/AlsaThru.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -35,20 +35,18 @@ // or a thread. //***************************************************************************** +#include "AlsaThru.h" -#include "WxWidgets.h" +#include "AlsaPlayer.h" -#include <stdlib.h> +#include <cstdlib> #include <errno.h> -#include <stdio.h> +#include <cstdio> #include <sys/wait.h> #include <unistd.h> #include <string.h> #include <signal.h> -#include "AlsaThru.h" -#include "AlsaPlayer.h" - /* ** midi thru for alsa. it creates a new process (because threads dont work ** with wxwin) that copies from input to output. Modified: trunk/jazz/src/AsciiMidiFile.cpp =================================================================== --- trunk/jazz/src/AsciiMidiFile.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/AsciiMidiFile.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -19,8 +19,6 @@ // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. //***************************************************************************** -#include "WxWidgets.h" - #include "AsciiMidiFile.h" //***************************************************************************** Modified: trunk/jazz/src/Audio.cpp =================================================================== --- trunk/jazz/src/Audio.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/Audio.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -20,10 +20,9 @@ // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. //***************************************************************************** -#include "WxWidgets.h" +#include "Audio.h" #include "Sample.h" -#include "Audio.h" #include "Events.h" #include "RecordingInfo.h" #include "Track.h" @@ -39,12 +38,16 @@ #include "Help.h" #include "Resources.h" -#include <iostream> -#include <fstream> +#include <wx/listbox.h> +#include <wx/msgdlg.h> +#include <wx/slider.h> + +#include <cassert> #include <cmath> #include <cstdlib> +#include <fstream> +#include <iostream> -#include <assert.h> #include <sys/stat.h> #include <string.h> Modified: trunk/jazz/src/Audio.h =================================================================== --- trunk/jazz/src/Audio.h 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/Audio.h 2008-12-27 02:14:07 UTC (rev 656) @@ -26,6 +26,9 @@ #include "DynamicArray.h" #include "Project.h" +#include <wx/app.h> +#include <wx/string.h> + class tEventArray; class JZTrack; struct tAudioBuffer; Modified: trunk/jazz/src/AudioDriver.cpp =================================================================== --- trunk/jazz/src/AudioDriver.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/AudioDriver.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -20,9 +20,8 @@ // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. //***************************************************************************** -#include "WxWidgets.h" - #include "AudioDriver.h" + #include "RecordingInfo.h" #include "Configuration.h" #include "Globals.h" Modified: trunk/jazz/src/ClockDialog.cpp =================================================================== --- trunk/jazz/src/ClockDialog.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/ClockDialog.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -20,8 +20,6 @@ // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. //***************************************************************************** -#include "WxWidgets.h" - #include "ClockDialog.h" #include "Song.h" Modified: trunk/jazz/src/Command.cpp =================================================================== --- trunk/jazz/src/Command.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/Command.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -20,14 +20,13 @@ // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. //***************************************************************************** -#include "WxWidgets.h" - #include "Command.h" + +#include "Filter.h" +#include "Globals.h" #include "Song.h" #include "Track.h" -#include "Filter.h" #include "Random.h" -#include "Globals.h" #include <cstdlib> #include <limits> Modified: trunk/jazz/src/Configuration.cpp =================================================================== --- trunk/jazz/src/Configuration.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/Configuration.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -20,22 +20,21 @@ // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. //***************************************************************************** -#include "WxWidgets.h" - -#include <wx/stdpaths.h> -#include <wx/filename.h> - #include "Configuration.h" -#include "Synth.h" #include "FindFile.h" #include "Globals.h" #include "StringUtilities.h" +#include "Synth.h" -#include <stack> +#include <wx/filename.h> +#include <wx/msgdlg.h> +#include <wx/stdpaths.h> + +#include <fstream> #include <iostream> #include <sstream> -#include <fstream> +#include <stack> using namespace std; Modified: trunk/jazz/src/Configuration.h =================================================================== --- trunk/jazz/src/Configuration.h 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/Configuration.h 2008-12-27 02:14:07 UTC (rev 656) @@ -26,6 +26,8 @@ #include <string> #include <vector> +#include <wx/string.h> + //***************************************************************************** //***************************************************************************** class JZDoubleCommand Modified: trunk/jazz/src/ControlEdit.cpp =================================================================== --- trunk/jazz/src/ControlEdit.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/ControlEdit.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -20,14 +20,16 @@ // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. //***************************************************************************** -#include "WxWidgets.h" +#include "ControlEdit.h" -#include "ControlEdit.h" +#include "EventWindow.h" #include "PianoWindow.h" -#include "EventWindow.h" #include "Song.h" #include "Track.h" +#include <wx/button.h> +#include <wx/sizer.h> + static const long wbar = 2; static int bars_state = 2; // from ArrayEdit Modified: trunk/jazz/src/ControlEdit.h =================================================================== --- trunk/jazz/src/ControlEdit.h 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/ControlEdit.h 2008-12-27 02:14:07 UTC (rev 656) @@ -25,10 +25,13 @@ #include "Random.h" +#include <wx/panel.h> + class JZPianoWindow; class JZTrack; class JZEvent; class tCtrlEditBase; +class wxButton; // to access tCtrlEditBase from Buttons etc @@ -125,8 +128,8 @@ void Create(JZPianoWindow* p, char const *label, int dx, int x, int y, int w, int h); - static void Apply(wxButton &but, wxCommandEvent& event); - static void Revert(wxButton &but, wxCommandEvent& event); + static void Apply(wxButton& but, wxCommandEvent& event); + static void Revert(wxButton& but, wxCommandEvent& event); // SN++ static void Edit(wxButton &but, wxCommandEvent& event); static void Bars(wxButton &but, wxCommandEvent& event); Modified: trunk/jazz/src/Dialogs/KeyOnDialog.cpp =================================================================== --- trunk/jazz/src/Dialogs/KeyOnDialog.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/Dialogs/KeyOnDialog.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -18,17 +18,20 @@ // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. //***************************************************************************** -#include "WxWidgets.h" - #include "KeyOnDialog.h" +#include "../Events.h" #include "../Globals.h" +#include "../KeyStringConverters.h" +#include "../Knob.h" #include "../Project.h" -#include "../Events.h" -#include "../Knob.h" -#include "../KeyStringConverters.h" #include "../Resources.h" +#include <wx/button.h> +#include <wx/sizer.h> +#include <wx/stattext.h> +#include <wx/textctrl.h> + #include <sstream> using namespace std; Modified: trunk/jazz/src/Dialogs/KeyOnDialog.h =================================================================== --- trunk/jazz/src/Dialogs/KeyOnDialog.h 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/Dialogs/KeyOnDialog.h 2008-12-27 02:14:07 UTC (rev 656) @@ -21,9 +21,13 @@ #ifndef JZ_KEYONDIALOG_H #define JZ_KEYONDIALOG_H +#include <wx/dialog.h> + +class JZKnob; +class JZKnobEvent; class tKeyOn; -class JZKnobEvent; -class JZKnob; +class wxStaticText; +class wxTextCtrl; //***************************************************************************** //***************************************************************************** Modified: trunk/jazz/src/Dialogs/MetronomeSettingsDialog.cpp =================================================================== --- trunk/jazz/src/Dialogs/MetronomeSettingsDialog.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/Dialogs/MetronomeSettingsDialog.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -18,16 +18,20 @@ // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. //***************************************************************************** -#include "WxWidgets.h" - #include "MetronomeSettingsDialog.h" -#include "../Metronome.h" #include "../Configuration.h" #include "../Globals.h" #include "../Knob.h" +#include "../Metronome.h" #include "../Resources.h" +#include <wx/button.h> +#include <wx/checkbox.h> +#include <wx/listbox.h> +#include <wx/sizer.h> +#include <wx/stattext.h> + #include <iostream> #include <sstream> Modified: trunk/jazz/src/Dialogs/MetronomeSettingsDialog.h =================================================================== --- trunk/jazz/src/Dialogs/MetronomeSettingsDialog.h 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/Dialogs/MetronomeSettingsDialog.h 2008-12-27 02:14:07 UTC (rev 656) @@ -21,14 +21,19 @@ #ifndef JZ_METRONOMESETTINGDIALOG_H #define JZ_METRONOMESETTINGDIALOG_H -class JZMetronomeInfo; +#include <wx/dialog.h> + +#include <map> +#include <string> +#include <vector> + class JZKnob; class JZKnobEvent; +class JZMetronomeInfo; +class wxCheckBox; +class wxListBox; +class wxStaticText; -#include <vector> -#include <string> -#include <map> - //***************************************************************************** //***************************************************************************** class JZMetronomeSettingsDialog : public wxDialog Modified: trunk/jazz/src/Dialogs/SynthesizerSettingsDialog.cpp =================================================================== --- trunk/jazz/src/Dialogs/SynthesizerSettingsDialog.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/Dialogs/SynthesizerSettingsDialog.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -18,12 +18,17 @@ // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. //***************************************************************************** -#include "WxWidgets.h" +#include "SynthesizerSettingsDialog.h" -#include "SynthesizerSettingsDialog.h" #include "../Configuration.h" #include "../Globals.h" +#include <wx/button.h> +#include <wx/listbox.h> +#include <wx/msgdlg.h> +#include <wx/sizer.h> +#include <wx/stattext.h> + using namespace std; //***************************************************************************** Modified: trunk/jazz/src/Dialogs/SynthesizerSettingsDialog.h =================================================================== --- trunk/jazz/src/Dialogs/SynthesizerSettingsDialog.h 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/Dialogs/SynthesizerSettingsDialog.h 2008-12-27 02:14:07 UTC (rev 656) @@ -21,8 +21,12 @@ #ifndef JZ_SYNTHESIZERSETTINGDIALOG_H #define JZ_SYNTHESIZERSETTINGDIALOG_H +#include <wx/dialog.h> + #include <string> +class wxListBox; + //***************************************************************************** //***************************************************************************** class JZSynthesizerDialog : public wxDialog Modified: trunk/jazz/src/Dialogs/TrackDialog.cpp =================================================================== --- trunk/jazz/src/Dialogs/TrackDialog.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/Dialogs/TrackDialog.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -18,15 +18,20 @@ // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. //***************************************************************************** -#include "WxWidgets.h" +#include "TrackDialog.h" -#include "TrackDialog.h" -#include "../Knob.h" -#include "../Track.h" #include "../Configuration.h" #include "../Globals.h" +#include "../Knob.h" #include "../Resources.h" +#include "../Track.h" +#include <wx/button.h> +#include <wx/listbox.h> +#include <wx/sizer.h> +#include <wx/stattext.h> +#include <wx/textctrl.h> + #include <sstream> using namespace std; Modified: trunk/jazz/src/Dialogs/TrackDialog.h =================================================================== --- trunk/jazz/src/Dialogs/TrackDialog.h 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/Dialogs/TrackDialog.h 2008-12-27 02:14:07 UTC (rev 656) @@ -21,11 +21,14 @@ #ifndef JZ_TRACKDIALOG_H #define JZ_TRACKDIALOG_H +#include <wx/dialog.h> + +class JZKnob; +class JZKnobEvent; class JZTrack; +class wxListBox; +class wxStaticText; class wxTextCtrl; -class wxStaticText; -class JZKnobEvent; -class JZKnob; //***************************************************************************** //***************************************************************************** Modified: trunk/jazz/src/Dialogs.cpp =================================================================== --- trunk/jazz/src/Dialogs.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/Dialogs.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -20,31 +20,31 @@ // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. //***************************************************************************** -#include "WxWidgets.h" +#include "Dialogs.h" -#include "Dialogs.h" -#include "Song.h" -#include "Synth.h" +#include "ClockDialog.h" #include "Command.h" +#include "DeprecatedWx/proplist.h" +#include "Dialogs/KeyOnDialog.h" +#include "Events.h" #include "EventWindow.h" -#include "ProjectManager.h" -#include "Track.h" -#include "Events.h" -#include "Player.h" +#include "Globals.h" +#include "Help.h" +#include "KeyDialog.h" +#include "NamedChoice.h" #include "PianoFrame.h" #include "PianoWindow.h" -#include "ClockDialog.h" -#include "KeyDialog.h" +#include "Player.h" +#include "ProjectManager.h" #include "PropertyListDialog.h" -#include "Globals.h" -#include "NamedChoice.h" -#include "Help.h" -#include "DeprecatedWx/proplist.h" +#include "Song.h" +#include "Synth.h" +#include "Track.h" -#include "Dialogs/KeyOnDialog.h" +#include <wx/choicdlg.h> +#include <iomanip> #include <sstream> -#include <iomanip> using namespace std; Modified: trunk/jazz/src/ErrorMessage.cpp =================================================================== --- trunk/jazz/src/ErrorMessage.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/ErrorMessage.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -20,7 +20,7 @@ // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. //***************************************************************************** -#include "WxWidgets.h" +#include <wx/msgdlg.h> #include <string> Modified: trunk/jazz/src/EventWindow.cpp =================================================================== --- trunk/jazz/src/EventWindow.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/EventWindow.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -20,9 +20,8 @@ // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. //***************************************************************************** -#include "WxWidgets.h" +#include "EventWindow.h" -#include "EventWindow.h" #include "PianoFrame.h" #include "Song.h" #include "Command.h" @@ -31,6 +30,10 @@ #include "ToolBar.h" #include "PropertyListDialog.h" +#include <wx/brush.h> +#include <wx/dc.h> +#include <wx/msgdlg.h> + using namespace std; //***************************************************************************** Modified: trunk/jazz/src/EventWindow.h =================================================================== --- trunk/jazz/src/EventWindow.h 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/EventWindow.h 2008-12-27 02:14:07 UTC (rev 656) @@ -26,6 +26,8 @@ #include "Filter.h" #include "MouseAction.h" +#include <wx/frame.h> + class JZEventFrame; class JZSong; class JZToolBar; Modified: trunk/jazz/src/Events.cpp =================================================================== --- trunk/jazz/src/Events.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/Events.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -20,19 +20,17 @@ // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. //***************************************************************************** -#include "WxWidgets.h" - #include "Events.h" -#include "Synth.h" + +#include "ErrorMessage.h" #include "Globals.h" #include "JazzPlusPlusApplication.h" -#include "ErrorMessage.h" +#include "Synth.h" -#include <stdio.h> -#include <stdlib.h> -#include <assert.h> -#include <stdarg.h> - +#include <cassert> +#include <cstdarg> +#include <cstdio> +#include <cstdlib> #include <sstream> using namespace std; Modified: trunk/jazz/src/Events.h =================================================================== --- trunk/jazz/src/Events.h 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/Events.h 2008-12-27 02:14:07 UTC (rev 656) @@ -23,10 +23,12 @@ #ifndef JZ_EVENTS_H #define JZ_EVENTS_H +#include <cstdio> + +#include <wx/pen.h> + class JZEvent; -#include <cstdio> - //***************************************************************************** // Output device, can be // - Midi-Standard-File Modified: trunk/jazz/src/FileSelector.cpp =================================================================== --- trunk/jazz/src/FileSelector.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/FileSelector.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -20,7 +20,9 @@ // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. //***************************************************************************** -#include "WxWidgets.h" +#include <wx/filedlg.h> +#include <wx/msgdlg.h> +#include <wx/string.h> //***************************************************************************** // Description: Modified: trunk/jazz/src/Filter.cpp =================================================================== --- trunk/jazz/src/Filter.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/Filter.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -20,15 +20,13 @@ // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. //***************************************************************************** -#include "WxWidgets.h" - -#include "PropertyListDialog.h" - #include "Filter.h" -#include "Events.h" + #include "ClockDialog.h" -#include "Song.h" +#include "Events.h" #include "Help.h" +#include "PropertyListDialog.h" +#include "Song.h" #include <cstdlib> @@ -191,12 +189,12 @@ void JZFilter::Dialog(wxFrame *parent, int ShowEventStats) { tFilterDlg *dlg; - // DialogBox = new wxDialogBox(parent, "Event Filter", FALSE ); + // mpDialogBox = new wxDialogBox(parent, "Event Filter", FALSE ); dlg = new tFilterDlg(this, mpSong, ShowEventStats); dlg->Create(); -// dlg->EditForm(DialogBox, ShowEventStats); -// DialogBox->Fit(); -// DialogBox->Show(TRUE); +// dlg->EditForm(mpDialogBox, ShowEventStats); +// mpDialogBox->Fit(); +// mpDialogBox->Show(TRUE); } Modified: trunk/jazz/src/Filter.h =================================================================== --- trunk/jazz/src/Filter.h 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/Filter.h 2008-12-27 02:14:07 UTC (rev 656) @@ -27,8 +27,9 @@ class JZSong; class JZTrack; +class wxDialog; +class wxFrame; - #define FltKeyOn 0 #define FltKeyPressure 1 // SN++ PolyAftertouch gehoert to KeyOn Events! #define FltControl 2 @@ -57,7 +58,7 @@ class JZFilter : public wxObject { friend class tFilterDlg; - wxDialog* DialogBox; + wxDialog* mpDialogBox; void copy(const JZFilter& Other); public: @@ -71,7 +72,7 @@ int FromTrack, ToTrack; // 1..n einschl .. einschl - void Dialog(wxFrame *parent, int ShowEventStats = 1); + void Dialog(wxFrame* parent, int ShowEventStats = 1); JZFilter(JZSong* pSong); JZFilter(JZFilter* pOtherFilter); Modified: trunk/jazz/src/FindFile.cpp =================================================================== --- trunk/jazz/src/FindFile.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/FindFile.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -20,7 +20,7 @@ // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. //***************************************************************************** -#include "WxWidgets.h" +#include <wx/app.h> #include <wx/filename.h> #include <iostream> Modified: trunk/jazz/src/GetOptionIndex.cpp =================================================================== --- trunk/jazz/src/GetOptionIndex.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/GetOptionIndex.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -1,5 +1,3 @@ -#include "WxWidgets.h" - #include "JazzPlusPlusApplication.h" int GetOptionIndex(const wxString& Option) Modified: trunk/jazz/src/Globals.cpp =================================================================== --- trunk/jazz/src/Globals.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/Globals.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -20,14 +20,14 @@ // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. //***************************************************************************** -#include "WxWidgets.h" #include "Globals.h" -#include "Song.h" -#include "Synth.h" -#include "Player.h" + #include "Help.h" #include "NamedValue.h" +#include "Player.h" #include "Project.h" +#include "Song.h" +#include "Synth.h" using namespace std; Modified: trunk/jazz/src/GuitarFrame.cpp =================================================================== --- trunk/jazz/src/GuitarFrame.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/GuitarFrame.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -20,15 +20,15 @@ // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. //***************************************************************************** -#include "WxWidgets.h" +#include "GuitarFrame.h" -#include "Resources.h" - -#include "GuitarFrame.h" #include "GuitarWindow.h" #include "GuitarSettingsDialog.h" #include "ProjectManager.h" +#include "Resources.h" +#include <wx/menu.h> + //***************************************************************************** // Description: // This is the guitar frame class definition. Modified: trunk/jazz/src/GuitarFrame.h =================================================================== --- trunk/jazz/src/GuitarFrame.h 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/GuitarFrame.h 2008-12-27 02:14:07 UTC (rev 656) @@ -23,6 +23,8 @@ #ifndef JZ_GUITARFRAME_H #define JZ_GUITARFRAME_H +#include <wx/frame.h> + class JZGuitarWindow; //***************************************************************************** Modified: trunk/jazz/src/GuitarSettingsDialog.cpp =================================================================== --- trunk/jazz/src/GuitarSettingsDialog.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/GuitarSettingsDialog.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -20,10 +20,12 @@ // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. //***************************************************************************** -#include "WxWidgets.h" - #include "GuitarSettingsDialog.h" +#include <wx/button.h> +#include <wx/checkbox.h> +#include <wx/sizer.h> + //----------------------------------------------------------------------------- //----------------------------------------------------------------------------- BEGIN_EVENT_TABLE(JZGuitarSettingsDialog, wxDialog) Modified: trunk/jazz/src/GuitarSettingsDialog.h =================================================================== --- trunk/jazz/src/GuitarSettingsDialog.h 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/GuitarSettingsDialog.h 2008-12-27 02:14:07 UTC (rev 656) @@ -23,6 +23,10 @@ #ifndef JZ_GUITARSETTINGSDIALOG_H #define JZ_GUITARSETTINGSDIALOG_H +#include <wx/dialog.h> + +class wxCheckBox; + class JZGuitarSettingsDialog : public wxDialog { public: Modified: trunk/jazz/src/GuitarWindow.cpp =================================================================== --- trunk/jazz/src/GuitarWindow.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/GuitarWindow.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -20,11 +20,12 @@ // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. //***************************************************************************** -#include "WxWidgets.h" +#include "GuitarWindow.h" -#include "GuitarWindow.h" #include "GuitarFrame.h" +#include <wx/dcclient.h> + #include <string> using namespace std; Modified: trunk/jazz/src/GuitarWindow.h =================================================================== --- trunk/jazz/src/GuitarWindow.h 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/GuitarWindow.h 2008-12-27 02:14:07 UTC (rev 656) @@ -23,6 +23,8 @@ #ifndef JZ_GUITARWINDOW_H #define JZ_GUITARWINDOW_H +#include <wx/scrolwin.h> + class JZGuitarFrame; //***************************************************************************** Modified: trunk/jazz/src/Harmony.cpp =================================================================== --- trunk/jazz/src/Harmony.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/Harmony.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -20,9 +20,8 @@ // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. //***************************************************************************** -#include "WxWidgets.h" +#include "Harmony.h" -#include "Harmony.h" #include "HarmonyP.h" #include "ProjectManager.h" #include "Player.h" @@ -40,6 +39,16 @@ #include "Globals.h" #include "Help.h" +#include <wx/button.h> +#include <wx/checkbox.h> +#include <wx/dcclient.h> +#include <wx/listbox.h> +#include <wx/menu.h> +#include <wx/msgdlg.h> +#include <wx/scrolwin.h> +#include <wx/stattext.h> +#include <wx/toolbar.h> + #include <iostream> #include <fstream> @@ -1612,12 +1621,12 @@ private: - HBCanvas* mpHbWindow; - wxCheckBox *chord_chk[12]; - wxCheckBox *scale_chk[12]; - wxListBox *chord_lst; - wxListBox *scale_lst; - wxStaticText *chord_msg; + HBCanvas* mpHbWindow; + wxCheckBox* chord_chk[12]; + wxCheckBox* scale_chk[12]; + wxListBox* chord_lst; + wxListBox* scale_lst; + wxStaticText* chord_msg; wxButton *ok_but; wxButton *cancel_but; Modified: trunk/jazz/src/Harmony.h =================================================================== --- trunk/jazz/src/Harmony.h 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/Harmony.h 2008-12-27 02:14:07 UTC (rev 656) @@ -25,6 +25,8 @@ #include "ToolBar.h" +#include <wx/frame.h> + class wxObject; class HBAnalyzer; class HBCanvas; Modified: trunk/jazz/src/HarmonyBrowserAnalyzer.cpp =================================================================== --- trunk/jazz/src/HarmonyBrowserAnalyzer.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/HarmonyBrowserAnalyzer.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -20,9 +20,8 @@ // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. //***************************************************************************** -#include "WxWidgets.h" - #include "HarmonyBrowserAnalyzer.h" + #include "EventWindow.h" #include "Command.h" #include "HarmonyP.h" Modified: trunk/jazz/src/Help.cpp =================================================================== --- trunk/jazz/src/Help.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/Help.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -20,13 +20,10 @@ // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. //***************************************************************************** -#include "WxWidgets.h" - -#include "wx/html/helpctrl.h" - #include "Help.h" -#include "Globals.h" +#include <wx/html/helpctrl.h> + #include <iostream> using namespace std; Modified: trunk/jazz/src/Help.h =================================================================== --- trunk/jazz/src/Help.h 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/Help.h 2008-12-27 02:14:07 UTC (rev 656) @@ -23,6 +23,8 @@ #ifndef JZ_HELP_H #define JZ_HELP_H +#include <wx/string.h> + class wxHtmlHelpController; //***************************************************************************** Modified: trunk/jazz/src/JazzPlusPlusApplication.cpp =================================================================== --- trunk/jazz/src/JazzPlusPlusApplication.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/JazzPlusPlusApplication.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -20,16 +20,12 @@ // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. //***************************************************************************** -#include "WxWidgets.h" +#include "JazzPlusPlusApplication.h" -#include <wx/stdpaths.h> -#include <wx/fileconf.h> - -#include "JazzPlusPlusApplication.h" -#include "TrackFrame.h" +#include "Globals.h" #include "Project.h" #include "ProjectManager.h" -#include "Globals.h" +#include "TrackFrame.h" #ifdef _MSC_VER @@ -51,6 +47,12 @@ #endif +#include <wx/stdpaths.h> +#include <wx/fileconf.h> +#include <wx/filedlg.h> +#include <wx/image.h> +#include <wx/msgdlg.h> + #include <fstream> #include <vector> Modified: trunk/jazz/src/JazzPlusPlusApplication.h =================================================================== --- trunk/jazz/src/JazzPlusPlusApplication.h 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/JazzPlusPlusApplication.h 2008-12-27 02:14:07 UTC (rev 656) @@ -23,6 +23,7 @@ #ifndef JZ_JAZZPLUSPLUSAPPLICATION_H #define JZ_JAZZPLUSPLUSAPPLICATION_H +#include <wx/app.h> #include <wx/html/helpctrl.h> class JZProject; Modified: trunk/jazz/src/KeyDialog.cpp =================================================================== --- trunk/jazz/src/KeyDialog.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/KeyDialog.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -20,9 +20,8 @@ // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. //***************************************************************************** -#include "WxWidgets.h" - #include "KeyDialog.h" + #include "KeyStringConverters.h" #include "DeprecatedStringUtils.h" #include "DeprecatedWx/proplist.h" Modified: trunk/jazz/src/Knob.cpp =================================================================== --- trunk/jazz/src/Knob.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/Knob.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -18,13 +18,13 @@ // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. //***************************************************************************** -#include "WxWidgets.h" +#include "Knob.h" +#include "Globals.h" + #include <wx/dcbuffer.h> +#include <wx/settings.h> -#include "Knob.h" -#include "Globals.h" - #include <cmath> //***************************************************************************** Modified: trunk/jazz/src/Knob.h =================================================================== --- trunk/jazz/src/Knob.h 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/Knob.h 2008-12-27 02:14:07 UTC (rev 656) @@ -21,6 +21,9 @@ #ifndef JZ_KNOB_H #define JZ_KNOB_H +#include <wx/bitmap.h> +#include <wx/control.h> + class JZKnobEvent; class JZKnob; Modified: trunk/jazz/src/MeasureChoice.cpp =================================================================== --- trunk/jazz/src/MeasureChoice.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/MeasureChoice.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -20,9 +20,8 @@ // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. //***************************************************************************** -#include "WxWidgets.h" - #include "MeasureChoice.h" + #include "Song.h" #include "Globals.h" Modified: trunk/jazz/src/Metronome.cpp =================================================================== --- trunk/jazz/src/Metronome.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/Metronome.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -20,9 +20,8 @@ // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. //***************************************************************************** -#include "WxWidgets.h" - #include "Metronome.h" + #include "Configuration.h" #include "Globals.h" #include "Events.h" Modified: trunk/jazz/src/MidiDeviceDialog.cpp =================================================================== --- trunk/jazz/src/MidiDeviceDialog.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/MidiDeviceDialog.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -20,10 +20,12 @@ // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. //***************************************************************************** -#include "WxWidgets.h" - #include "MidiDeviceDialog.h" +#include <wx/button.h> +#include <wx/listbox.h> +#include <wx/sizer.h> + using namespace std; //***************************************************************************** Modified: trunk/jazz/src/MidiDeviceDialog.h =================================================================== --- trunk/jazz/src/MidiDeviceDialog.h 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/MidiDeviceDialog.h 2008-12-27 02:14:07 UTC (rev 656) @@ -23,9 +23,13 @@ #ifndef JZ_MIDIDEVICEDIALOG_H #define JZ_MIDIDEVICEDIALOG_H +#include <wx/dialog.h> + #include <vector> #include <string> +class wxListBox; + //***************************************************************************** // Description: // This is the MIDI device selection dialog class declaration. Modified: trunk/jazz/src/MouseAction.cpp =================================================================== --- trunk/jazz/src/MouseAction.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/MouseAction.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -20,11 +20,13 @@ // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. //***************************************************************************** -#include "WxWidgets.h" +#include "MouseAction.h" -#include "MouseAction.h" #include "EventWindow.h" +#include <wx/dcclient.h> +#include <wx/brush.h> + using namespace std; // ----------------------------------------------------------------- Modified: trunk/jazz/src/NamedChoice.cpp =================================================================== --- trunk/jazz/src/NamedChoice.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/NamedChoice.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -20,9 +20,8 @@ // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. //***************************************************************************** -#include "WxWidgets.h" - #include "NamedChoice.h" + #include "NamedValue.h" #include "DeprecatedStringUtils.h" #include "DeprecatedWx/proplist.h" Modified: trunk/jazz/src/NamedChoice.h =================================================================== --- trunk/jazz/src/NamedChoice.h 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/NamedChoice.h 2008-12-27 02:14:07 UTC (rev 656) @@ -23,6 +23,8 @@ #ifndef JZ_NAMEDCHOICE_H #define JZ_NAMEDCHOICE_H +#include <wx/object.h> + #include <vector> #include <string> Modified: trunk/jazz/src/NamedValue.cpp =================================================================== --- trunk/jazz/src/NamedValue.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/NamedValue.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -20,8 +20,6 @@ // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. //***************************************************************************** -#include "WxWidgets.h" - #include "NamedValue.h" using namespace std; Modified: trunk/jazz/src/NamedValueChoice.cpp =================================================================== --- trunk/jazz/src/NamedValueChoice.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/NamedValueChoice.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -20,8 +20,6 @@ // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. //***************************************************************************** -#include "WxWidgets.h" - #include "NamedValueChoice.h" using namespace std; Modified: trunk/jazz/src/NamedValueChoice.h =================================================================== --- trunk/jazz/src/NamedValueChoice.h 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/NamedValueChoice.h 2008-12-27 02:14:07 UTC (rev 656) @@ -23,6 +23,8 @@ #ifndef JZ_NAMEDVALUECHOICE_H #define JZ_NAMEDVALUECHOICE_H +#include <wx/choice.h> + #include <vector> #include <string> Modified: trunk/jazz/src/PianoFrame.cpp =================================================================== --- trunk/jazz/src/PianoFrame.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/PianoFrame.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -20,29 +20,30 @@ // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. //***************************************************************************** -#include "WxWidgets.h" +#include "PianoFrame.h" -#include "Resources.h" - -#include "PianoFrame.h" +#include "Command.h" +#include "ControlEdit.h" +#include "Dialogs.h" +#include "Globals.h" +#include "Harmony.h" #include "PianoWindow.h" #include "ProjectManager.h" +#include "Resources.h" #include "Song.h" #include "Track.h" #include "Synth.h" #include "StandardFile.h" -#include "Dialogs.h" -#include "Harmony.h" -#include "Command.h" -#include "Globals.h" #include "Player.h" -#include "ControlEdit.h" #include "GuitarFrame.h" #include "ToolBar.h" #include "ResourceDialog.h" #include "Help.h" #include "Rectangle.h" +#include <wx/menu.h> +#include <wx/msgdlg.h> + #include <sstream> using namespace std; @@ -243,7 +244,7 @@ // CreateMenu(); - DialogBox = 0; + mpDialogBox = 0; MixerForm = 0; CreateMenu(); Modified: trunk/jazz/src/PianoFrame.h =================================================================== --- trunk/jazz/src/PianoFrame.h 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/PianoFrame.h 2008-12-27 02:14:07 UTC (rev 656) @@ -26,6 +26,8 @@ #include "MouseAction.h" #include "Song.h" +#include <wx/frame.h> + class JZGuitarFrame; class JZSong; class JZToolBar; @@ -132,7 +134,7 @@ int mClockTicsPerPixel; JZSong* mpSong; - wxDialog* DialogBox; + wxDialog* mpDialogBox; wxDialog* MixerForm; private: Modified: trunk/jazz/src/PianoWindow.cpp =================================================================== --- trunk/jazz/src/PianoWindow.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/PianoWindow.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -20,28 +20,30 @@ // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. //***************************************************************************** -#include "WxWidgets.h" +#include "PianoWindow.h" -#include "Resources.h" - -#include "PianoWindow.h" -#include "PianoFrame.h" -#include "ProjectManager.h" +#include "Command.h" #include "ControlEdit.h" -#include "Song.h" +#include "Dialogs.h" #include "Filter.h" +#include "GuitarFrame.h" +#include "Harmony.h" +#include "HarmonyBrowserAnalyzer.h" #include "HarmonyP.h" -#include "HarmonyBrowserAnalyzer.h" -#include "Harmony.h" +#include "Help.h" +#include "PianoFrame.h" #include "Player.h" +#include "ProjectManager.h" +#include "ResourceDialog.h" +#include "Resources.h" +#include "SelectControllerDialog.h" +#include "Song.h" #include "Synth.h" -#include "Command.h" -#include "GuitarFrame.h" -#include "Dialogs.h" -#include "SelectControllerDialog.h" -#include "ResourceDialog.h" -#include "Help.h" +#include <wx/dcclient.h> +#include <wx/dcmemory.h> +#include <wx/msgdlg.h> + #include <sstream> using namespace std; Modified: trunk/jazz/src/PianoWindow.h =================================================================== --- trunk/jazz/src/PianoWindow.h 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/PianoWindow.h 2008-12-27 02:14:07 UTC (rev 656) @@ -28,6 +28,8 @@ #include "Track.h" #include "Globals.h" +#include <wx/brush.h> + class JZPianoFrame; class JZSong; class JZTrack; Modified: trunk/jazz/src/Player.cpp =================================================================== --- trunk/jazz/src/Player.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/Player.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -20,9 +20,8 @@ // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. //***************************************************************************** -#include "WxWidgets.h" +#include "Player.h" -#include "Player.h" #include "ProjectManager.h" #include "Synth.h" #include "TrackFrame.h" @@ -32,10 +31,12 @@ #include "Audio.h" #include "Globals.h" +#include <wx/msgdlg.h> + //#include <unistd.h> +#include <cassert> #include <cstdlib> -#include <assert.h> #include <string.h> #include <errno.h> Modified: trunk/jazz/src/PortMidiPlayer.cpp =================================================================== --- trunk/jazz/src/PortMidiPlayer.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/PortMidiPlayer.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -1,6 +1,5 @@ -#include "WxWidgets.h" - #include "PortMidiPlayer.h" + #include "JazzPlusPlusApplication.h" #include "TrackFrame.h" #include "TrackWindow.h" Modified: trunk/jazz/src/Project.cpp =================================================================== --- trunk/jazz/src/Project.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/Project.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -20,22 +20,16 @@ // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. //***************************************************************************** -#include "WxWidgets.h" +#include "Project.h" -#include <wx/stdpaths.h> -#include <wx/config.h> -#include <wx/filename.h> -#include <wx/file.h> - -#include "Project.h" +#include "Filter.h" +#include "GetOptionIndex.h" +#include "Globals.h" +#include "Player.h" #include "RecordingInfo.h" #include "Synth.h" #include "Song.h" -#include "Globals.h" -#include "Filter.h" -#include "Player.h" #include "StandardFile.h" -#include "GetOptionIndex.h" #ifdef __WXMSW__ #include "WindowsPlayer.h" @@ -51,6 +45,12 @@ #include "AlsaDriver.h" #endif +#include <wx/stdpaths.h> +#include <wx/config.h> +#include <wx/file.h> +#include <wx/filedlg.h> +#include <wx/filename.h> + #include <fstream> #include <iostream> Modified: trunk/jazz/src/ProjectManager.cpp =================================================================== --- trunk/jazz/src/ProjectManager.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/ProjectManager.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -1,5 +1,3 @@ -#include "WxWidgets.h" - #include "ProjectManager.h" #include "PianoFrame.h" Modified: trunk/jazz/src/PropertyListDialog.cpp =================================================================== --- trunk/jazz/src/PropertyListDialog.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/PropertyListDialog.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -20,8 +20,6 @@ // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. //***************************************************************************** -#include "WxWidgets.h" - #include "PropertyListDialog.h" #include <cstdlib> Modified: trunk/jazz/src/Random.cpp =================================================================== --- trunk/jazz/src/Random.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/Random.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -20,15 +20,15 @@ // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. //***************************************************************************** -#include "WxWidgets.h" - -//#include "config.h" - #include "Random.h" #include "Mapper.h" -#include <assert.h> +#include <wx/dcclient.h> +#include <wx/frame.h> +#include <wx/scrolwin.h> + +#include <cassert> #include <cstdlib> using namespace std; @@ -261,7 +261,7 @@ #define TICK_LINE 0 tArrayEdit::tArrayEdit(wxFrame *frame, JZRndArray &ar, int xx, int yy, int ww, int hh, int sty) - : wxScrolledWindow(frame,-1, wxPoint(xx, yy), wxSize(ww, hh)), + : wxScrolledWindow(frame, wxID_ANY, wxPoint(xx, yy), wxSize(ww, hh)), mArray(ar), n(ar.n), min(ar.min), Modified: trunk/jazz/src/Random.h =================================================================== --- trunk/jazz/src/Random.h 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/Random.h 2008-12-27 02:14:07 UTC (rev 656) @@ -23,6 +23,8 @@ #ifndef JZ_RANDOM_H #define JZ_RANDOM_H +#include <wx/scrolwin.h> + #include <iostream> #include "DynamicArray.h" Modified: trunk/jazz/src/Rectangle.cpp =================================================================== --- trunk/jazz/src/Rectangle.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/Rectangle.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -20,8 +20,6 @@ // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. //***************************************************************************** -#include "WxWidgets.h" - #include "Rectangle.h" //***************************************************************************** Modified: trunk/jazz/src/Rectangle.h =================================================================== --- trunk/jazz/src/Rectangle.h 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/Rectangle.h 2008-12-27 02:14:07 UTC (rev 656) @@ -23,6 +23,8 @@ #ifndef JZ_RECTANGLE_H #define JZ_RECTANGLE_H +#include <wx/gdicmn.h> + //***************************************************************************** // Description: // This is the Jazz++ rectangle class delcaration. Modified: trunk/jazz/src/ResourceDialog.cpp =================================================================== --- trunk/jazz/src/ResourceDialog.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/ResourceDialog.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -16,14 +16,17 @@ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ -#include "WxWidgets.h" +#include "ResourceDialog.h" +#include <wx/checkbox.h> +#include <wx/choice.h> +#include <wx/dialog.h> #include <wx/fs_zip.h> +#include <wx/msgdlg.h> +#include <wx/slider.h> +#include <wx/textctrl.h> #include <wx/xrc/xmlres.h> -#include "ResourceDialog.h" - -#include <wx/listimpl.cpp> //WX_DEFINE_LIST(jppResourceElementList); using namespace std; Modified: trunk/jazz/src/ResourceDialog.h =================================================================== --- trunk/jazz/src/ResourceDialog.h 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/ResourceDialog.h 2008-12-27 02:14:07 UTC (rev 656) @@ -25,6 +25,12 @@ #include <list> +#include <wx/dynarray.h> +#include <wx/string.h> + +class wxDialog; +class wxWindow; + /// Used by jppResourceDialog to store "Attach" entries. /** This class links together a named resource and a pointer to a data item. @@ -225,7 +231,7 @@ std::list<jppResourceElement*> links; /// Reference to the dialog created from the XRC resource. - wxDialog *dialog; + wxDialog* dialog; /// The name of the dialog resource. Used in error reporting. wxString dialogName; Modified: trunk/jazz/src/Rhythm.cpp =================================================================== --- trunk/jazz/src/Rhythm.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/Rhythm.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -20,9 +20,8 @@ // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. //***************************************************************************** -#include "WxWidgets.h" +#include "Rhythm.h" -#include "Rhythm.h" #include "EventWindow.h" #include "Song.h" #include "Command.h" @@ -38,6 +37,14 @@ #include "SelectControllerDialog.h" #include "Help.h" +#include <wx/button.h> +#include <wx/checkbox.h> +#include <wx/choicdlg.h> +#include <wx/listbox.h> +#include <wx/msgdlg.h> +#include <wx/slider.h> +#include <wx/toolbar.h> + #include <fstream> #include <sstream> Modified: trunk/jazz/src/Rhythm.h =================================================================== --- trunk/jazz/src/Rhythm.h 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/Rhythm.h 2008-12-27 02:14:07 UTC (rev 656) @@ -27,12 +27,18 @@ #include "ToolBar.h" +#include <wx/frame.h> + #include <iostream> class JZTrack; class JZEventWindow; class JZSong; class JZBarInfo; +class wxButton; +class wxCheckBox; +class wxListBox; +class wxPanel; #define MAX_GROUPS 5 #define MAX_KEYS 20 Modified: trunk/jazz/src/Sample.cpp =================================================================== --- trunk/jazz/src/Sample.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/Sample.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -20,9 +20,8 @@ // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. //***************************************************************************** -#include "WxWidgets.h" - #include "Sample.h" + #include "Audio.h" #include "Random.h" #include "SampleCommand.h" Modified: trunk/jazz/src/SampleCommand.cpp =================================================================== --- trunk/jazz/src/SampleCommand.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/SampleCommand.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -20,13 +20,12 @@ // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. //***************************************************************************** -#include "WxWidgets.h" - -#include "Sample.h" #include "SampleCommand.h" + #include "Audio.h" -#include "SignalInterface.h" #include "Mapper.h" +#include "Sample.h" +#include "SignalInterface.h" //#include "util.h" #include <cmath> Modified: trunk/jazz/src/SampleDialog.cpp =================================================================== --- trunk/jazz/src/SampleDialog.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/SampleDialog.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -20,13 +20,10 @@ // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. //***************************************************************************** -#include "WxWidgets.h" +#include "SampleDialog.h" -//#include "config.h" -#include "SampleDialog.h" #include "Sample.h" #include "SampleWindow.h" -//#include "jazz.h" #include "Mapper.h" #include "Audio.h" #include "SignalInterface.h" @@ -36,6 +33,12 @@ #include "DeprecatedStringUtils.h" #include "Help.h" +#include <wx/checkbox.h> +#include <wx/choice.h> +#include <wx/msgdlg.h> +#include <wx/slider.h> +#include <wx/statbox.h> + #include <fstream> #include <cmath> Modified: trunk/jazz/src/SampleDialog.h =================================================================== --- trunk/jazz/src/SampleDialog.h 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/SampleDialog.h 2008-12-27 02:14:07 UTC (rev 656) @@ -28,9 +28,13 @@ #include "SampleCommand.h" #include "PropertyListDialog.h" +class tPaintableCommand; class tSampleWin; class tSigEqualizer; -class tPaintableCommand; +class wxButton; +class wxCheckBox; +class wxChoice; +class wxSlider; /** * controls a tPaintableCommand, that is shows the parameter arrays Modified: trunk/jazz/src/SampleWindow.cpp =================================================================== --- trunk/jazz/src/SampleWindow.cpp 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/SampleWindow.cpp 2008-12-27 02:14:07 UTC (rev 656) @@ -20,24 +20,28 @@ // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. //***************************************************************************** -#include "WxWidgets.h" +#include "SampleWindow.h" -#include "SampleWindow.h" -#include "SampleCommand.h" -#include "SampleDialog.h" -#include "ToolBar.h" -#include "Sample.h" #include "Audio.h" +#include "FileSelector.h" +#include "Globals.h" +#include "Help.h" +#include "Mapper.h" #include "MouseAction.h" -#include "Song.h" #include "Player.h" #include "Rhythm.h" +#include "Sample.h" +#include "SampleCommand.h" +#include "SampleDialog.h" +#include "Song.h" #include "SliderWindow.h" -#include "Mapper.h" -#include "FileSelector.h" -#include "Globals.h" -#include "Help.h" +#include "ToolBar.h" +#include <wx/dcclient.h> +#include <wx/menu.h> +#include <wx/msgdlg.h> +#include <wx/scrolbar.h> + #include <iostream> #define MEN_LOAD 1 Modified: trunk/jazz/src/SampleWindow.h =================================================================== --- trunk/jazz/src/SampleWindow.h 2008-12-27 02:03:27 UTC (rev 655) +++ trunk/jazz/src/SampleWindow.h 2008-12-27 02:14:07 UTC (rev 656) @@ -23,19 +23,22 @@ #ifndef samplwin_h #define samplwin_h -class tSample; -class tSampleCnvs; +#include "SampleCommand.h" + +#in... [truncated message content] |
From: <pst...@us...> - 2008-12-26 22:22:58
|
Revision: 652 http://jazzplusplus.svn.sourceforge.net/jazzplusplus/?rev=652&view=rev Author: pstieber Date: 2008-12-26 21:32:59 +0000 (Fri, 26 Dec 2008) Log Message: ----------- Changed *Pixel to *Position. Modified Paths: -------------- trunk/jazz/src/Harmony.cpp Modified: trunk/jazz/src/Harmony.cpp =================================================================== --- trunk/jazz/src/Harmony.cpp 2008-12-26 21:06:47 UTC (rev 651) +++ trunk/jazz/src/Harmony.cpp 2008-12-26 21:32:59 UTC (rev 652) @@ -2117,10 +2117,11 @@ //----------------------------------------------------------------------------- HBFrame::~HBFrame() { - int XPixel, YPixel; - GetPosition(&XPixel, &YPixel); - gpConfig->Put(C_HarmonyXpos, XPixel); - gpConfig->Put(C_HarmonyYpos, YPixel); + int XPosition, YPosition; + GetPosition(&XPosition, &YPosition); + gpConfig->Put(C_HarmonyXpos, XPosition); + gpConfig->Put(C_HarmonyYpos, YPosition); + delete mpToolBar; delete mpHbWindow; gpHarmonyBrowser = 0; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <pst...@us...> - 2008-12-26 22:22:55
|
Revision: 653 http://jazzplusplus.svn.sourceforge.net/jazzplusplus/?rev=653&view=rev Author: pstieber Date: 2008-12-26 21:35:52 +0000 (Fri, 26 Dec 2008) Log Message: ----------- Started using the position and size in the configuration files when creating the track and piano windows. Modified Paths: -------------- trunk/jazz/src/ProjectManager.cpp Modified: trunk/jazz/src/ProjectManager.cpp =================================================================== --- trunk/jazz/src/ProjectManager.cpp 2008-12-26 21:32:59 UTC (rev 652) +++ trunk/jazz/src/ProjectManager.cpp 2008-12-26 21:35:52 UTC (rev 653) @@ -53,13 +53,24 @@ { if (!mpTrackFrame) { + int XPosition(10), YPosition(10), Width(600), Height(400); + + gpConfig->Get(C_TrackWinXpos, XPosition); + gpConfig->Get(C_TrackWinYpos, YPosition); + gpConfig->Get(C_TrackWinWidth, Width); + gpConfig->Get(C_TrackWinHeight, Height); + + wxPoint Position(XPosition, YPosition); + + wxSize Size(Width, Height); + // Create the main application window. mpTrackFrame = new JZTrackFrame( 0, "Jazz++", gpSong, - wxPoint(10, 10), - wxSize(600, 400)); + Position, + Size); } mpTrackFrame->Show(true); @@ -73,12 +84,23 @@ { if (!mpPianoFrame) { + int XPosition(10), YPosition(10), Width(640), Height(480); + + gpConfig->Get(C_PianoWinXpos, XPosition); + gpConfig->Get(C_PianoWinYpos, YPosition); + gpConfig->Get(C_PianoWinWidth, Width); + gpConfig->Get(C_PianoWinHeight, Height); + + wxPoint Position(XPosition, YPosition); + + wxSize Size(Width, Height); + mpPianoFrame = new JZPianoFrame( mpTrackFrame, "Piano", gpSong, - wxDefaultPosition, - wxSize(640, 480)); + Position, + Size); } mpPianoFrame->Show(true); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <pst...@us...> - 2008-12-26 22:22:53
|
Revision: 654 http://jazzplusplus.svn.sourceforge.net/jazzplusplus/?rev=654&view=rev Author: pstieber Date: 2008-12-26 21:37:56 +0000 (Fri, 26 Dec 2008) Log Message: ----------- 1. Added a snap select stop function. 2. Started adding record capability. This is a WIP. Modified Paths: -------------- trunk/jazz/src/EventWindow.h trunk/jazz/src/TrackFrame.cpp trunk/jazz/src/TrackFrame.h trunk/jazz/src/TrackWindow.cpp trunk/jazz/src/TrackWindow.h Modified: trunk/jazz/src/EventWindow.h =================================================================== --- trunk/jazz/src/EventWindow.h 2008-12-26 21:35:52 UTC (rev 653) +++ trunk/jazz/src/EventWindow.h 2008-12-26 21:37:56 UTC (rev 654) @@ -78,6 +78,10 @@ protected: + virtual void SnapSelStop(wxMouseEvent& Event) + { + } + void DrawVerticalLine(wxDC& Dc, int XPosition) const; void DrawHorizontalLine(wxDC& Dc, int YPosition) const; Modified: trunk/jazz/src/TrackFrame.cpp =================================================================== --- trunk/jazz/src/TrackFrame.cpp 2008-12-26 21:35:52 UTC (rev 653) +++ trunk/jazz/src/TrackFrame.cpp 2008-12-26 21:37:56 UTC (rev 654) @@ -75,6 +75,8 @@ //----------------------------------------------------------------------------- BEGIN_EVENT_TABLE(JZTrackFrame, wxFrame) + EVT_MENU(wxID_NEW, JZTrackFrame::OnFileNew) + EVT_MENU(wxID_OPEN, JZTrackFrame::OnFileOpen) EVT_MENU(wxID_SAVEAS, JZTrackFrame::OnFileSaveAs) @@ -85,6 +87,8 @@ EVT_MENU(ID_PLAY_LOOP, JZTrackFrame::OnPlayLoop) + EVT_MENU(ID_RECORD, JZTrackFrame::OnRecord) + EVT_MENU(ID_PIANOWIN, JZTrackFrame::OnPianoWindow) EVT_MENU(ID_METRONOME_TOGGLE, JZTrackFrame::OnMetroOn) @@ -142,6 +146,16 @@ //----------------------------------------------------------------------------- JZTrackFrame::~JZTrackFrame() { + int XPosition, YPosition, Width, Height; + + GetPosition(&XPosition, &YPosition); + GetSize(&Width, &Height); + + gpConfig->Put(C_TrackWinXpos, XPosition); + gpConfig->Put(C_TrackWinYpos, YPosition); + gpConfig->Put(C_TrackWinWidth, Width); + gpConfig->Put(C_TrackWinHeight, Height); + delete mpToolBar; } @@ -433,6 +447,18 @@ //----------------------------------------------------------------------------- //----------------------------------------------------------------------------- +void JZTrackFrame::OnFileNew(wxCommandEvent& Event) +{ + if (wxMessageBox("Clear Song?", "Sure?", wxOK | wxCANCEL) == wxOK) + { + gpProject->Clear(); + mpTrackWindow->Refresh(false); +// NextWin->NewPosition(1, 0); + } +} + +//----------------------------------------------------------------------------- +//----------------------------------------------------------------------------- void JZTrackFrame::OnFileOpen(wxCommandEvent& Event) { // Use an open dialog to find the Jazz++ configuration file. @@ -509,6 +535,14 @@ //----------------------------------------------------------------------------- //----------------------------------------------------------------------------- +void JZTrackFrame::OnRecord(wxCommandEvent& Event) +{ + wxMouseEvent MouseEvent; + MousePlay(MouseEvent, eRecordButton); +} + +//----------------------------------------------------------------------------- +//----------------------------------------------------------------------------- void JZTrackFrame::OnPianoWindow(wxCommandEvent& Event) { JZProjectManager::Instance()->CreatePianoView(); @@ -629,169 +663,4 @@ void JZTrackFrame::MousePlay(wxMouseEvent& Event, TEMousePlayMode Mode) { mpTrackWindow->MousePlay(Event, Mode); - -/* - if (Mode == eMouse && !Event.ButtonDown()) - { - return; - } - - // This is a little hack to keep it working for now. - // All this stuff needs to be moved. - JZRecordingInfo* pRecInfo = gpProject->GetRecInfo(); - - if (!gpProject->IsPlaying()) - { - switch (Mode) - { - case eMouse: - int x, y; - Event.GetPosition(&x, &y); - gpProject->SetPlayPosition(x2BarClock((long)x)); - gpProject->Mute((Event.RightDown() != 0)); - if (mpSnapSel->Selected && (Event.ShiftDown() || Event.MiddleDown())) - { - gpProject->SetLoop(true); - } - else - { - gpProject->SetLoop(false); - mPreviouslyRecording = mpSnapSel->Selected; - } - break; - - case eSpaceBar: - break; - - case ePlayButton: - gpProject->SetLoop(false); - gpProject->SetRecord(false); - break; - - case ePlayLoopButton: - if (!EventsSelected("please select loop range first")) - { - return; - } - gpProject->SetLoop(true); - gpProject->SetRecord(false); - break; - - case eRecordButton: - if (!EventsSelected("please select record track/bar first")) - { - return; - } - JZBarInfo bi(gpProject); - - bi.SetClock(mpFilter->FromClock); - - if (bi.BarNr > 0) - { - bi.SetBar(bi.BarNr - 1); - } - gpProject->SetPlayPosition(bi.Clock); - gpProject->SetRecord(true); - gpProject->SetLoop(false); - break; - } - - // todo: Figure out if we should have getters for these instead - // and make them private jppProject members - bool loop = gpProject->mLoop; - bool muted = gpProject->mMuted; - bool record = gpProject->mRecord; - - // Is it possible to record? - if (record && mpSnapSel->Selected) - { - pRecInfo->mTrackIndex = mpFilter->FromTrack; - - pRecInfo->mpTrack = gpProject->GetTrack(pRecInfo->mTrackIndex); - - pRecInfo->mFromClock = mpFilter->FromClock; - pRecInfo->mToClock = mpFilter->ToClock; - - if (muted) - { - pRecInfo->mIsMuted = true; - pRecInfo->mpTrack->SetState(tsMute); -#ifdef OBSOLETE - LineText( - *pDc, - xState, - Line2y(pRecInfo.mTrackIndex), - wState, - pRecInfo.Track->GetStateChar()); -#endif - } - else - { - pRecInfo->mIsMuted = false; - } - } - else - { - pRecInfo->mpTrack = 0; - } - - // Is it possible to loop? - int loop_clock = 0; - if (loop && mpSnapSel->Selected) - { - mPreviousClock = mpFilter->FromClock; - loop_clock = mpFilter->ToClock; - } - - //if (pRecInfo->Track) // recording? - //gpProject->Midi->SetRecordInfo(pRecInfo); - //else - //gpProject->Midi->SetRecordInfo(0); - - gpProject->mStartTime = mPreviousClock; - gpProject->mStopTime = loop_clock; - gpProject->Play(); - - } //if(!Midi->Playing) - else - { - gpProject->Stop(); - if (pRecInfo->mpTrack) - { - if (pRecInfo->mIsMuted) - { -// wxDC* pDc = new wxClientDC(mpTrackWindow); - - pRecInfo->mpTrack->SetState(tsPlay); -// LineText( -// *pDc, -// xState, -// Line2y(pRecInfo->mTrackIndex), -// wState, -// pRecInfo->mpTrack->GetStateChar()); - -// delete pDc; - } - if ( - !pRecInfo->mpTrack->GetAudioMode() && - !gpProject->GetPlayer()->RecdBuffer.IsEmpty()) - { - //int choice = wxMessageBox("Keep recorded events?", "You played", wxOK | wxCANCEL); - //if (choice == wxOK) - { - wxBeginBusyCursor(); - gpProject->NewUndoBuffer(); - pRecInfo->mpTrack->MergeRange( - &gpProject->GetPlayer()->RecdBuffer, - pRecInfo->mFromClock, - pRecInfo->mToClock, - pRecInfo->mIsMuted); - wxEndBusyCursor(); - Refresh(); - NextWin->Refresh(); - } - } - } - } -*/ } Modified: trunk/jazz/src/TrackFrame.h =================================================================== --- trunk/jazz/src/TrackFrame.h 2008-12-26 21:35:52 UTC (rev 653) +++ trunk/jazz/src/TrackFrame.h 2008-12-26 21:37:56 UTC (rev 654) @@ -68,6 +68,8 @@ void CreateMenu(); + void OnFileNew(wxCommandEvent& Event); + void OnFileOpen(wxCommandEvent& Event); void OnFileSaveAs(wxCommandEvent& Event); @@ -82,6 +84,8 @@ void OnPlayLoop(wxCommandEvent& Event); + void OnRecord(wxCommandEvent& Event); + void OnPianoWindow(wxCommandEvent& Event); void OnToolsHarmonyBrowser(wxCommandEvent& Event); Modified: trunk/jazz/src/TrackWindow.cpp =================================================================== --- trunk/jazz/src/TrackWindow.cpp 2008-12-26 21:35:52 UTC (rev 653) +++ trunk/jazz/src/TrackWindow.cpp 2008-12-26 21:37:56 UTC (rev 654) @@ -266,7 +266,22 @@ { wxPoint Point = Event.GetPosition(); - if ( + if (Point.x < mNumberWidth && Point.y >= mTopInfoHeight) + { + JZRectangle Rectangle( + 0, + y2yLine(Point.y), + Clock2x(mpSong->GetMaxQuarters() * mpSong->GetTicksPerQuarter()), + mTrackHeight); + mpSnapSel->Select( + Rectangle, + mEventsX, + mEventsY, + mEventsWidth, + mEventsHeight); + SnapSelStop(Event); + } + else if ( Point.x >= mEventsX && Point.x < mEventsX + mEventsWidth && Point.y >= mEventsY && Point.y < mEventsY + mEventsHeight) { @@ -1314,10 +1329,10 @@ // and make them private jppProject members bool loop = gpProject->mLoop; bool muted = gpProject->mMuted; - bool record = gpProject->mRecord; + bool Record = gpProject->mRecord; // Is it possible to record? - if (record && mpSnapSel->IsSelected()) + if (Record && mpSnapSel->IsSelected()) { pRecInfo->mTrackIndex = mpFilter->FromTrack; @@ -1359,10 +1374,14 @@ // GO! - //if (pRecInfo->Track) // recording? - //gpProject->Midi->SetRecordInfo(pRecInfo); - //else - //gpProject->Midi->SetRecordInfo(0); + if (pRecInfo->mpTrack) // recording? + { + gpMidiPlayer->SetRecordInfo(pRecInfo); + } + else + { + gpMidiPlayer->SetRecordInfo(0); + } gpProject->mStartTime = mPreviousClock; gpProject->mStopTime = loop_clock; Modified: trunk/jazz/src/TrackWindow.h =================================================================== --- trunk/jazz/src/TrackWindow.h 2008-12-26 21:35:52 UTC (rev 653) +++ trunk/jazz/src/TrackWindow.h 2008-12-26 21:37:56 UTC (rev 654) @@ -83,6 +83,12 @@ void SetScrollRanges(); + protected: + + virtual void SnapSelStop(wxMouseEvent& Event) + { + } + private: void OnSize(wxSizeEvent& Event); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <pst...@us...> - 2008-12-26 21:06:50
|
Revision: 651 http://jazzplusplus.svn.sourceforge.net/jazzplusplus/?rev=651&view=rev Author: pstieber Date: 2008-12-26 21:06:47 +0000 (Fri, 26 Dec 2008) Log Message: ----------- Added code to store the window position and size in the configuration object when the destructor is called. Modified Paths: -------------- trunk/jazz/src/PianoFrame.cpp Modified: trunk/jazz/src/PianoFrame.cpp =================================================================== --- trunk/jazz/src/PianoFrame.cpp 2008-12-26 19:34:52 UTC (rev 650) +++ trunk/jazz/src/PianoFrame.cpp 2008-12-26 21:06:47 UTC (rev 651) @@ -262,6 +262,16 @@ //----------------------------------------------------------------------------- JZPianoFrame::~JZPianoFrame() { + int XPosition, YPosition, Width, Height; + + GetPosition(&XPosition, &YPosition); + GetSize(&Width, &Height); + + gpConfig->Put(C_PianoWinXpos, XPosition); + gpConfig->Put(C_PianoWinYpos, YPosition); + gpConfig->Put(C_PianoWinWidth, Width); + gpConfig->Put(C_PianoWinHeight, Height); + delete mpPianoWindow; delete MixerForm; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <pst...@us...> - 2008-12-26 19:34:55
|
Revision: 650 http://jazzplusplus.svn.sourceforge.net/jazzplusplus/?rev=650&view=rev Author: pstieber Date: 2008-12-26 19:34:52 +0000 (Fri, 26 Dec 2008) Log Message: ----------- 1. Updated an enumeration comment header. 2. Changed JZConfigurationEntry::SetStrValue to JZConfigurationEntry::SetStringValue. 3. Changed JZConfigurationEntry::mStrValue to JZConfigurationEntry::mStringValue. 4. Changed the argument to JZConfiguration::Load from char* to const std::string&. 5. Changed entry to Entry in Configuration.cpp. 6. Changed configuration file reading to use C++ streams and strings instead of C FILE* and char* values. Modified Paths: -------------- trunk/jazz/src/Configuration.cpp trunk/jazz/src/Configuration.h Modified: trunk/jazz/src/Configuration.cpp =================================================================== --- trunk/jazz/src/Configuration.cpp 2008-12-26 19:32:28 UTC (rev 649) +++ trunk/jazz/src/Configuration.cpp 2008-12-26 19:34:52 UTC (rev 650) @@ -26,9 +26,11 @@ #include <wx/filename.h> #include "Configuration.h" + #include "Synth.h" #include "FindFile.h" #include "Globals.h" +#include "StringUtilities.h" #include <stack> #include <iostream> @@ -49,7 +51,7 @@ : mType(eConfigEntryTypeInt), mName(), mValue(IntegerValue), - mStrValue() + mStringValue() { if (pName) { @@ -65,7 +67,7 @@ : mType(eConfigEntryTypeStr), mName(), mValue(0), - mStrValue() + mStringValue() { if (pName) { @@ -74,7 +76,7 @@ if (pStringValue) { - mStrValue = pStringValue; + mStringValue = pStringValue; } } @@ -89,7 +91,7 @@ mName = pName; } - mStrValue = StringValue; + mStringValue = StringValue; } //----------------------------------------------------------------------------- @@ -98,7 +100,7 @@ : mType(eConfigEntryTypeEmpty), mName(), mValue(0), - mStrValue() + mStringValue() { if (pName) { @@ -108,12 +110,9 @@ //----------------------------------------------------------------------------- //----------------------------------------------------------------------------- -void JZConfigurationEntry::SetStrValue(const char* pStringValue) +void JZConfigurationEntry::SetStringValue(const string& StringValue) { - if (pStringValue) - { - mStrValue = pStringValue; - } + mStringValue = StringValue; } //***************************************************************************** @@ -368,42 +367,42 @@ //----------------------------------------------------------------------------- //----------------------------------------------------------------------------- -const pair<string, int>& JZConfiguration::GetDrumName(unsigned entry) const +const pair<string, int>& JZConfiguration::GetDrumName(unsigned Entry) const { - assert((entry >= 0) && (entry < mDrumNames.size())); - return mDrumNames[entry]; + assert((Entry >= 0) && (Entry < mDrumNames.size())); + return mDrumNames[Entry]; } //----------------------------------------------------------------------------- //----------------------------------------------------------------------------- -const pair<string, int>& JZConfiguration::GetDrumSet(unsigned entry) const +const pair<string, int>& JZConfiguration::GetDrumSet(unsigned Entry) const { - assert((entry >= 0) && (entry < mDrumSets.size())); - return mDrumSets[entry]; + assert((Entry >= 0) && (Entry < mDrumSets.size())); + return mDrumSets[Entry]; } //----------------------------------------------------------------------------- //----------------------------------------------------------------------------- -const pair<string, int>& JZConfiguration::GetVoiceName(unsigned entry) const +const pair<string, int>& JZConfiguration::GetVoiceName(unsigned Entry) const { - assert((entry >= 0) && (entry < mVoiceNames.size())); - return mVoiceNames[entry]; + assert((Entry >= 0) && (Entry < mVoiceNames.size())); + return mVoiceNames[Entry]; } //----------------------------------------------------------------------------- //----------------------------------------------------------------------------- -const pair<string, int>& JZConfiguration::GetCtrlName(unsigned entry) const +const pair<string, int>& JZConfiguration::GetCtrlName(unsigned Entry) const { - assert((entry >= 0) && (entry < mCtrlNames.size())); - return mCtrlNames[entry]; + assert((Entry >= 0) && (Entry < mCtrlNames.size())); + return mCtrlNames[Entry]; } //----------------------------------------------------------------------------- //----------------------------------------------------------------------------- -JZDoubleCommand& JZConfiguration::BankEntry(unsigned entry) +JZDoubleCommand& JZConfiguration::BankEntry(unsigned Entry) { - assert((entry >= 0) && (entry < mBankTable.size())); - return mBankTable[entry]; + assert((Entry >= 0) && (Entry < mBankTable.size())); + return mBankTable[Entry]; } //----------------------------------------------------------------------------- @@ -466,60 +465,62 @@ //----------------------------------------------------------------------------- //----------------------------------------------------------------------------- -int JZConfiguration::Load(char* buf) +int JZConfiguration::Load(const string& InputLine) { - int entry = Check(buf); + int Entry = Check(InputLine); - if (entry < 0) + if (Entry < 0) { - return entry; + return Entry; } - char format[100]; - int result = 1; - if (mNames[entry]->GetType() == eConfigEntryTypeInt) + int Result = 1; + + switch (mNames[Entry]->GetType()) { - sprintf(format, "%s %%d", mNames[entry]->GetName().c_str()); - int Value; - result = sscanf(buf, format, &Value); - mNames[entry]->SetValue(Value); - } - else if (mNames[entry]->GetType() == eConfigEntryTypeStr) - { - // Allow whitespace inside entries like "C:\Program Files\JazzWare". - int ofs = mNames[entry]->GetName().length(); - while (buf[ofs] == ' ' || buf[ofs] == '\t') // not \n + case eConfigEntryTypeInt: { - ++ofs; + string Name; + int Value; + istringstream Iss(InputLine); + Iss >> Name >> Value; + if (Iss.fail()) + { + Result = -1; + } + mNames[Entry]->SetValue(Value); + break; } - int end = strlen(buf) - 1; - while (end > ofs) + case eConfigEntryTypeStr: { - if (!isspace(buf[end])) + string::size_type FindIndex = InputLine.find(mNames[Entry]->GetName()); + + if (FindIndex == string::npos) { + // Give up if the configuration entry name is not found. + Result = -1; break; } - --end; + + // Construct a string from the rest of the line and trim leading and + // trailing white space. + string StringValue = TNStringUtilities::TrimLeadingAndTrailingBlanks( + string(InputLine, FindIndex + mNames[Entry]->GetName().size())); + + mNames[Entry]->SetStringValue(StringValue); + + break; } - int size = end - ofs + 1; - - char* pStringValue = new char[size + 1]; - memcpy(pStringValue, buf + ofs, size); - pStringValue[size] = 0; - mNames[entry]->SetStrValue(pStringValue); - delete [] pStringValue; + case eConfigEntryTypeEmpty: + break; } - else - { - result = 1; - } - if (result <= 0) + if (Result <= 0) { return -1; } - return entry; + return Entry; } //----------------------------------------------------------------------------- @@ -543,9 +544,9 @@ //----------------------------------------------------------------------------- //----------------------------------------------------------------------------- -bool JZConfiguration::Get(int entry, char* value) +bool JZConfiguration::Get(int Entry, char* value) { - assert((entry >= 0) && (entry < NumConfigNames)); + assert((Entry >= 0) && (Entry < NumConfigNames)); wxString FileName = GetFileName(); if (FileName.IsEmpty()) @@ -554,7 +555,7 @@ } FILE *fd = fopen(FileName.c_str(), "r"); - const string& name = GetName(entry); + const string& name = GetName(Entry); int len = name.length(); char buf[1000]; @@ -582,10 +583,10 @@ //----------------------------------------------------------------------------- //----------------------------------------------------------------------------- -bool JZConfiguration::Get(int entry, int& value) +bool JZConfiguration::Get(int Entry, int& value) { char buf[512]; - if (Get(entry, buf)) + if (Get(Entry, buf)) { sscanf(buf, " %d ", &value); return true; @@ -695,26 +696,23 @@ wxString Path = FileNameObject.GetPath(); ::wxSetWorkingDirectory(Path); - char buf[1000]; int i, j; unsigned BankIndex = 0, VoiceIndex = 0, DrumsetIndex = 0; vector<pair<string, int> >* pVector = 0; -// stack<ifstream> InputFileStreams; - stack<FILE*> FileDescriptors; + stack<ifstream*> InputFileStreams; + string InputLine; cout << "JZConfiguration::LoadConfig:" << '\n' << " \"" << mFileName << '"' << endl; -// ifstream Is(mFileName.c_str()); -// InputFileStreams.push(Is); - FileDescriptors.push(fopen(mFileName.c_str(), "r")); + ifstream* pIs = new ifstream(mFileName.c_str()); + InputFileStreams.push(pIs); -// if (!InputFileStreams.top()) - if (FileDescriptors.top() == NULL) + if (!*InputFileStreams.top()) { wxString String; String @@ -734,17 +732,17 @@ { // Read a line from the current file. -// if (getline(InputFileStreams.top(), InputLine)) - if (fgets(buf, sizeof(buf), FileDescriptors.top()) == NULL) + getline(*InputFileStreams.top(), InputLine); + + // Check for an end-of-file condition. + if (InputFileStreams.top()->eof()) { -// InputFileStreams.top().close(); - fclose(FileDescriptors.top()); + InputFileStreams.top()->close(); + delete InputFileStreams.top(); + InputFileStreams.pop(); -// InputFileStreams.pop(); - FileDescriptors.pop(); - -// if (InputFileStreams.empty()) - if (FileDescriptors.empty()) + // Are there any open streams? + if (InputFileStreams.empty()) { // The code has reached the last line of the Jazz++ configuration file // (jazz.cfg or .jazz). @@ -757,12 +755,12 @@ } } - int entry; + int Entry; - // Read keyword lines - if ((entry = gpConfig->Load(buf)) >= 0) + // Read keyword lines. + if ((Entry = gpConfig->Load(InputLine)) >= 0) { - switch (entry) + switch (Entry) { case C_BankTable: @@ -806,7 +804,7 @@ case C_SynthConfig: case C_Include: { - if (entry == C_SynthConfig) + if (Entry == C_SynthConfig) { cout << "Include synthesizer configuration file \""; } @@ -814,33 +812,30 @@ { cout << "Include file \""; } - cout << GetStrValue(entry) << '"' << endl; + cout << GetStrValue(Entry) << '"' << endl; // Get the name of the include file. - wxString IncludeFileName = FindFile(GetStrValue(entry)); + wxString IncludeFileName = FindFile(GetStrValue(Entry)); if (IncludeFileName.empty()) { -// InputFileStreams - FileDescriptors.push(NULL); + InputFileStreams.push(0); } else { -// InputFileStreams - FileDescriptors.push(fopen(IncludeFileName, "r")); + pIs = new ifstream(IncludeFileName.c_str()); + InputFileStreams.push(pIs); } -// InputFileStreams - if (FileDescriptors.top() == NULL) + if (!InputFileStreams.top()) { wxString String; String << "Could not open configuration include file:" << '\n' - << '"' << buf << '"'; + << '"' << InputLine << '"'; ::wxMessageBox(String, "Warning", wxOK); -// InputFileStreams.pop(); - FileDescriptors.pop(); + InputFileStreams.pop(); } } break; @@ -849,17 +844,18 @@ break; } } + else if (pVector && isdigit(InputLine[0])) + { + // Read named value entries. - // Read named value entries - else if (pVector && isdigit(buf[0])) - { // Voice names if (pVector == &mVoiceNames) { if (VoiceIndex >= 0 && VoiceIndex < mVoiceNames.size()) { int Value; - sscanf(buf, " %d %n", &Value, &j); + istringstream Iss(InputLine); + Iss >> Value; if (gpConfig->GetValue(C_UseTwoCommandBankSelect)) { @@ -872,10 +868,10 @@ mVoiceNames[VoiceIndex + 1].second = Value + 1; - // Remove the \n. - buf[strlen(buf) - 1] = 0; + string VoiceName = + TNStringUtilities::TrimLeadingAndTrailingBlanks(Iss.str()); - mVoiceNames[VoiceIndex + 1].first = buf + j; + mVoiceNames[VoiceIndex + 1].first = VoiceName; ++VoiceIndex; } @@ -887,13 +883,16 @@ } } - // Drumset names else if (pVector == &mDrumSets) { + // Drumset names. + if (DrumsetIndex >= 0 && DrumsetIndex < 129) { int Value; - sscanf(buf, " %d %n", &Value, &j); + istringstream Iss(InputLine); + Iss >> Value; + if (gpConfig->GetValue(C_UseTwoCommandBankSelect)) { assert(0 <= Value && Value <= 65536); @@ -904,10 +903,10 @@ } mDrumSets[DrumsetIndex + 1].second = Value + 1; - // Remove the \n. - buf[strlen(buf) - 1] = 0; + string DrumSetName = + TNStringUtilities::TrimLeadingAndTrailingBlanks(Iss.str()); - mDrumSets[DrumsetIndex + 1].first = buf + j; + mDrumSets[DrumsetIndex + 1].first = DrumSetName; ++DrumsetIndex; } @@ -918,46 +917,48 @@ << endl; } } - - // Controller names. else if (pVector == &mCtrlNames) { - sscanf(buf, " %d %n", &i, &j); + // Controller names. + + istringstream Iss(InputLine); + Iss >> i; assert(0 <= i && i <= 127); - // Remove the \n. - buf[strlen(buf) - 1] = 0; + string ControllerName = + TNStringUtilities::TrimLeadingAndTrailingBlanks(Iss.str()); - mCtrlNames[i + 1].first = buf + j; + mCtrlNames[i + 1].first = ControllerName; } - - // Drum instrument names. else if (pVector == &mDrumNames) { - sscanf(buf, " %d %n", &i, &j); + // Drum instrument names. + + istringstream Iss(InputLine); + Iss >> i; assert(0 <= i && i <= 127); - // Remove the \n. - buf[strlen(buf) - 1] = 0; + string DrumName = + TNStringUtilities::TrimLeadingAndTrailingBlanks(Iss.str()); - mDrumNames[i + 1].first = buf + j; + mDrumNames[i + 1].first = DrumName; } else { wxString String; String << "LoadConfig: error reading line" << '\n' - << '"' << buf << '"'; + << '"' << InputLine << '"'; ::wxMessageBox(String, "Warning", wxOK); } } - - // Read bank table entries. - else if (pVector == 0 && !mBankTable.empty()&& isdigit(buf[0])) + else if (pVector == 0 && !mBankTable.empty()&& isdigit(InputLine[0])) { + // Read bank table entries. assert(0 <= BankIndex && BankIndex < mBankTable.size()); - sscanf(buf, " %d %d", &i, &j); + istringstream Iss(InputLine); + Iss >> i >> j; assert(0 <= i && i <= 255); assert(0 <= j && j <= 255); Modified: trunk/jazz/src/Configuration.h =================================================================== --- trunk/jazz/src/Configuration.h 2008-12-26 19:32:28 UTC (rev 649) +++ trunk/jazz/src/Configuration.h 2008-12-26 19:34:52 UTC (rev 650) @@ -117,7 +117,8 @@ }; //***************************************************************************** -// values for C_MidiDriver +// Description: +// These are the values associated with the C_MidiDriver entry. //***************************************************************************** enum TEMidiDriver { @@ -152,14 +153,14 @@ const std::string& GetStrValue() const; - void SetStrValue(const char* pStringValue); + void SetStringValue(const std::string& StringValue); private: TEConfigEntryType mType; std::string mName; int mValue; - std::string mStrValue; + std::string mStringValue; }; //***************************************************************************** @@ -203,7 +204,7 @@ inline const std::string& JZConfigurationEntry::GetStrValue() const { - return mStrValue; + return mStringValue; } //***************************************************************************** @@ -220,7 +221,7 @@ int Check(const std::string& Name) const; - int Load(char* buf); + int Load(const std::string& buf); const std::pair<std::string, int>& GetDrumName(unsigned Entry) const; const std::pair<std::string, int>& GetDrumSet(unsigned Entry) const; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <pst...@us...> - 2008-12-26 19:32:37
|
Revision: 649 http://jazzplusplus.svn.sourceforge.net/jazzplusplus/?rev=649&view=rev Author: pstieber Date: 2008-12-26 19:32:28 +0000 (Fri, 26 Dec 2008) Log Message: ----------- Added code to trim leading and trailing white space from a string. Modified Paths: -------------- trunk/jazz/src/StringUtilities.cpp trunk/jazz/src/StringUtilities.h Modified: trunk/jazz/src/StringUtilities.cpp =================================================================== --- trunk/jazz/src/StringUtilities.cpp 2008-12-24 01:18:18 UTC (rev 648) +++ trunk/jazz/src/StringUtilities.cpp 2008-12-26 19:32:28 UTC (rev 649) @@ -61,3 +61,20 @@ } return TokenIndex; } + +//----------------------------------------------------------------------------- +// Decsription: +// This function removes leading and trailing white space the input string. +//----------------------------------------------------------------------------- +string TNStringUtilities::TrimLeadingAndTrailingBlanks(const string& String) +{ + const string WhiteSpaceCharacters = " \t\n"; + + string::size_type Start = String.find_first_not_of(WhiteSpaceCharacters); + if (Start == string::npos) + { + return ""; + } + string::size_type Stop = String.find_last_not_of(WhiteSpaceCharacters); + return string(String, Start, Stop - Start + 1); +} Modified: trunk/jazz/src/StringUtilities.h =================================================================== --- trunk/jazz/src/StringUtilities.h 2008-12-24 01:18:18 UTC (rev 648) +++ trunk/jazz/src/StringUtilities.h 2008-12-26 19:32:28 UTC (rev 649) @@ -36,6 +36,12 @@ const std::string& InputString, std::vector<std::string>& Tokens); +//----------------------------------------------------------------------------- +// Decsription: +// This function removes leading and trailing white space the input string. +//----------------------------------------------------------------------------- +std::string TrimLeadingAndTrailingBlanks(const std::string& String); + }; #endif // !defined(TRC_STRINGUTILITIES_H) This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <pst...@us...> - 2008-12-24 01:18:24
|
Revision: 648 http://jazzplusplus.svn.sourceforge.net/jazzplusplus/?rev=648&view=rev Author: pstieber Date: 2008-12-24 01:18:18 +0000 (Wed, 24 Dec 2008) Log Message: ----------- Added checks to prevent crashes if all of the drum names are empty. Modified Paths: -------------- trunk/jazz/src/Dialogs/MetronomeSettingsDialog.cpp Modified: trunk/jazz/src/Dialogs/MetronomeSettingsDialog.cpp =================================================================== --- trunk/jazz/src/Dialogs/MetronomeSettingsDialog.cpp 2008-12-24 00:32:03 UTC (rev 647) +++ trunk/jazz/src/Dialogs/MetronomeSettingsDialog.cpp 2008-12-24 01:18:18 UTC (rev 648) @@ -81,11 +81,17 @@ } } - mKeyNormalName = - mIndexToName[mPitchToIndex[mMetronomeInfo.GetKeyNormal()]]; + if (mMetronomeInfo.GetKeyNormal() < mPitchToIndex.size()) + { + mKeyNormalName = + mIndexToName[mPitchToIndex[mMetronomeInfo.GetKeyNormal()]]; + } - mKeyAccentedName = - mIndexToName[mPitchToIndex[mMetronomeInfo.GetKeyAccented()]]; + if (mMetronomeInfo.GetKeyAccented() < mPitchToIndex.size()) + { + mKeyAccentedName = + mIndexToName[mPitchToIndex[mMetronomeInfo.GetKeyAccented()]]; + } mpVelocityKnob = new JZKnob(this, IDC_KB_VOLUME, 100, 0, 127); @@ -170,7 +176,7 @@ mpVelocityKnob->SetValueWithEvent(mMetronomeInfo.GetVelocity()); mpAccentedCheckBox->SetValue(mMetronomeInfo.IsAccented()); - int Selection, Index; + unsigned Selection, Index; Selection = 0; Index = 0; @@ -186,8 +192,12 @@ break; } } - mpNormalListbox->SetSelection(Selection); + if (Selection < mpNormalListbox->GetCount()) + { + mpNormalListbox->SetSelection(Selection); + } + Selection = 0; Index = 0; for ( @@ -202,8 +212,12 @@ break; } } - mpAccentedListbox->SetSelection(Selection); + if (Selection < mpAccentedListbox->GetCount()) + { + mpAccentedListbox->SetSelection(Selection); + } + return true; } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <pst...@us...> - 2008-12-24 00:32:08
|
Revision: 647 http://jazzplusplus.svn.sourceforge.net/jazzplusplus/?rev=647&view=rev Author: pstieber Date: 2008-12-24 00:32:03 +0000 (Wed, 24 Dec 2008) Log Message: ----------- 1. Changed the code to set the help path temporary directory only if the help file is found. 2. Changed a comment. Modified Paths: -------------- trunk/jazz/src/JazzPlusPlusApplication.cpp Modified: trunk/jazz/src/JazzPlusPlusApplication.cpp =================================================================== --- trunk/jazz/src/JazzPlusPlusApplication.cpp 2008-12-15 05:40:25 UTC (rev 646) +++ trunk/jazz/src/JazzPlusPlusApplication.cpp 2008-12-24 00:32:03 UTC (rev 647) @@ -213,15 +213,15 @@ HelpFileFound = true; } + // GetUserDataDir returns the directory for the user-dependent application + // data files. The value is $HOME/.appname on Linux, + // c:\Documents and Settings\username\Application Data\appname on + // Windows, and ~/Library/Application Support/appname on the Mac. + // The cached version of the help file will be placed in this location. + mHelp.SetTempDir(wxStandardPaths::Get().GetUserDataDir()); + if (HelpFileFound) { - // GetUserDataDir returns the directory for the user-dependent application - // data files. The value is $HOME/.appname on Linux, - // c:\Documents and Settings\username\Application Data\appname on - // Windows, and ~/Library/Application Support/appname on the Mac. - // The cached version of the help file will be placed in this location. - mHelp.SetTempDir(wxStandardPaths::Get().GetUserDataDir()); - // Add the IPVT help file the the help system. mHelp.AddBook(HelpFileNameAndPath); @@ -243,7 +243,7 @@ //----------------------------------------------------------------------------- void JZJazzPlusPlusApplication::InsureConfigurationFileExistence() const { - // Determine the expected location of the user's data dir for Jazz++. + // Determine the expected location of the user's data directory for Jazz++. wxString UserConfigDir = wxStandardPaths::Get().GetUserDataDir(); // Determine if the directory exists. This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <pst...@us...> - 2008-12-15 05:40:29
|
Revision: 646 http://jazzplusplus.svn.sourceforge.net/jazzplusplus/?rev=646&view=rev Author: pstieber Date: 2008-12-15 05:40:25 +0000 (Mon, 15 Dec 2008) Log Message: ----------- Removed white space from the ends of lines. Modified Paths: -------------- trunk/jazz/src/Harmony.cpp Modified: trunk/jazz/src/Harmony.cpp =================================================================== --- trunk/jazz/src/Harmony.cpp 2008-12-15 05:39:14 UTC (rev 645) +++ trunk/jazz/src/Harmony.cpp 2008-12-15 05:40:25 UTC (rev 646) @@ -1975,9 +1975,9 @@ EVT_MENU(MEN_HELP, HBFrame::OnHelp) -// EVT_MENU(MEN_ANALYZE, -// EVT_MENU(MEN_TRANSPOSE, -// EVT_MENU(MEN_SETTINGS, +// EVT_MENU(MEN_ANALYZE, +// EVT_MENU(MEN_TRANSPOSE, +// EVT_MENU(MEN_SETTINGS, END_EVENT_TABLE() This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <pst...@us...> - 2008-12-15 05:39:17
|
Revision: 645 http://jazzplusplus.svn.sourceforge.net/jazzplusplus/?rev=645&view=rev Author: pstieber Date: 2008-12-15 05:39:14 +0000 (Mon, 15 Dec 2008) Log Message: ----------- Removed white space from the end of a line. Modified Paths: -------------- trunk/jazz/src/Events.h Modified: trunk/jazz/src/Events.h =================================================================== --- trunk/jazz/src/Events.h 2008-12-15 05:37:46 UTC (rev 644) +++ trunk/jazz/src/Events.h 2008-12-15 05:39:14 UTC (rev 645) @@ -1427,7 +1427,7 @@ : tMetaEvent(Clock, StatPlayTrack, chardat, Length) { int* pData = (int *)chardat; - + // Fill in the fields from the data. track = 0; transpose = 0; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <pst...@us...> - 2008-12-15 05:37:50
|
Revision: 644 http://jazzplusplus.svn.sourceforge.net/jazzplusplus/?rev=644&view=rev Author: pstieber Date: 2008-12-15 05:37:46 +0000 (Mon, 15 Dec 2008) Log Message: ----------- Removed white space from the end of a line. Modified Paths: -------------- trunk/jazz/src/MouseAction.cpp Modified: trunk/jazz/src/MouseAction.cpp =================================================================== --- trunk/jazz/src/MouseAction.cpp 2008-12-15 05:36:52 UTC (rev 643) +++ trunk/jazz/src/MouseAction.cpp 2008-12-15 05:37:46 UTC (rev 644) @@ -309,7 +309,7 @@ mYCoordinates(), mXMin(0), mXMax(0), - mXStep(0), + mXStep(0), mYMin(0), mYMax(0), mYStep(0) This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |