From 8c5fc3a01fa611033207fe11df875d3c894334a8 Mon Sep 17 00:00:00 2001 From: Andre Bernet Date: Mon, 14 Apr 2014 23:15:52 +0200 Subject: [PATCH] Fix "Move up a mix will not move higher than the current topmost line entry" --- companion/src/modeledit/mixes.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/companion/src/modeledit/mixes.cpp b/companion/src/modeledit/mixes.cpp index 1cd47484f..49dd373e9 100644 --- a/companion/src/modeledit/mixes.cpp +++ b/companion/src/modeledit/mixes.cpp @@ -443,11 +443,14 @@ void MixesPanel::mixerlistWidget_KeyPress(QKeyEvent *event) int MixesPanel::gm_moveMix(int idx, bool dir) //true=inc=down false=dec=up { - if(idx>GetEepromInterface()->getCapability(Mixes) || (idx==0 && !dir) || (idx==GetEepromInterface()->getCapability(Mixes) && dir)) return idx; + if(idx>GetEepromInterface()->getCapability(Mixes) || (idx==GetEepromInterface()->getCapability(Mixes) && dir)) return idx; int tdx = dir ? idx+1 : idx-1; MixData &src=model.mixData[idx]; MixData &tgt=model.mixData[tdx]; + + if (src.destCh == 1 && !dir) + return idx; unsigned int outputs = GetEepromInterface()->getCapability(Outputs); if((src.destCh==0) || (src.destCh>outputs) || (tgt.destCh>outputs)) return idx;