From: werner s. <wsc...@us...> - 2005-04-25 12:57:19
|
Update of /cvsroot/lmuse/muse/muse/mixer In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv8339/muse/mixer Modified Files: amixer.cpp amixer.h mstrip.cpp Log Message: update Index: mstrip.cpp =================================================================== RCS file: /cvsroot/lmuse/muse/muse/mixer/mstrip.cpp,v retrieving revision 1.29 retrieving revision 1.30 diff -C2 -d -r1.29 -r1.30 *** mstrip.cpp 22 Jan 2005 22:21:41 -0000 1.29 --- mstrip.cpp 25 Apr 2005 12:56:23 -0000 1.30 *************** *** 490,494 **** bool ec = !ar || (ar && aw); ! for (int i = 0; i < sizeof(controller)/sizeof(*controller); ++i) { controller[i].knob->setEnabled(ec); controller[i].dl->setEnabled(ec); --- 490,494 ---- bool ec = !ar || (ar && aw); ! for (unsigned i = 0; i < sizeof(controller)/sizeof(*controller); ++i) { controller[i].knob->setEnabled(ec); controller[i].dl->setEnabled(ec); Index: amixer.cpp =================================================================== RCS file: /cvsroot/lmuse/muse/muse/mixer/amixer.cpp,v retrieving revision 1.54 retrieving revision 1.55 diff -C2 -d -r1.54 -r1.55 *** amixer.cpp 13 Jan 2005 21:16:06 -0000 1.54 --- amixer.cpp 25 Apr 2005 12:56:23 -0000 1.55 *************** *** 129,140 **** //--------------------------------------------------------- ! void AudioMixerApp::updateMixer(UpdateAction action) { int auxsSize = song->auxs()->size(); ! if ((action == UPDATE_ALL) || (auxsSize != oldAuxsSize)) { ! clear(); ! oldAuxsSize = auxsSize; ! } ! else if (action == STRIP_REMOVED) { StripList::iterator si = stripList.begin(); for (; si != stripList.end();) { --- 129,136 ---- //--------------------------------------------------------- ! void AudioMixerApp::updateMixer(int action) { int auxsSize = song->auxs()->size(); ! if (action == STRIP_REMOVED && auxsSize == oldAuxsSize) { StripList::iterator si = stripList.begin(); for (; si != stripList.end();) { *************** *** 158,161 **** --- 154,160 ---- } + clear(); + oldAuxsSize = auxsSize; + int idx = 0; //--------------------------------------------------- *************** *** 249,261 **** void AudioMixerApp::songChanged(int flags) { ! // printf(" =======AudioMixer::songChanged %x\n", flags); ! UpdateAction action = NO_UPDATE; ! // if (flags == -1 || (flags & SC_CHANNELS)) if (flags == -1) action = UPDATE_ALL; ! else if (flags & SC_TRACK_REMOVED) ! action = STRIP_REMOVED; ! else if (flags & SC_TRACK_INSERTED) ! action = STRIP_INSERTED; if (action != NO_UPDATE) updateMixer(action); --- 248,260 ---- void AudioMixerApp::songChanged(int flags) { ! int action = NO_UPDATE; if (flags == -1) action = UPDATE_ALL; ! else { ! if (flags & SC_TRACK_REMOVED) ! action |= STRIP_REMOVED; ! if (flags & SC_TRACK_INSERTED) ! action |= STRIP_INSERTED; ! } if (action != NO_UPDATE) updateMixer(action); Index: amixer.h =================================================================== RCS file: /cvsroot/lmuse/muse/muse/mixer/amixer.h,v retrieving revision 1.28 retrieving revision 1.29 diff -C2 -d -r1.28 -r1.29 *** amixer.h 30 Aug 2004 18:19:06 -0000 1.28 --- amixer.h 25 Apr 2005 12:56:23 -0000 1.29 *************** *** 69,76 **** void showRouteDialog(bool); ! enum UpdateAction { ! NO_UPDATE, UPDATE_ALL, STRIP_INSERTED, STRIP_REMOVED }; ! void updateMixer(UpdateAction); signals: --- 69,79 ---- void showRouteDialog(bool); ! enum { ! NO_UPDATE = 0, ! STRIP_INSERTED = 1, ! STRIP_REMOVED = 2, ! UPDATE_ALL = 4 }; ! void updateMixer(int); signals: |