Преглед на файлове

Fix serialization with hidden series

Neal Wilson преди 11 години
родител
ревизия
62de5f9b88
променени са 1 файла, в които са добавени 21 реда и са изтрити 11 реда
  1. 21
    11
      config/Windows/productionroaster.xml

+ 21
- 11
config/Windows/productionroaster.xml Целия файл

@@ -719,15 +719,20 @@
719 719
                 var durfield = findChildObject(currentBatchInfo, 'duration');
720 720
                 durfield.text = duration;
721 721
                 log.clearOutputColumns();
722
+				channelSkip = 0;
722 723
 				for(var i = 0; i < channels.length; i++) {
723
-					if(channelType[i] == "T") {
724
-						log.addOutputTemperatureColumn(lc + i);
725
-					}
726
-					else {
727
-						log.addOutputControlColumn(lc + i);
724
+					if(channelVisibility[i]) {
725
+						if(channelType[i] == "T") {
726
+							log.addOutputTemperatureColumn(lc + i - channelSkip);
727
+						}
728
+						else {
729
+							log.addOutputControlColumn(lc + i - channelSkip);
730
+						}
731
+					} else {
732
+						channelSkip++;
728 733
 					}
729 734
 				}
730
-				log.addOutputAnnotationColumn(lc + channels.length);
735
+				log.addOutputAnnotationColumn(lc + channels.length - channelSkip);
731 736
                 var filename = log.saveTemporary();
732 737
                 currentBatchInfo.tempData = filename;
733 738
                 currentBatchInfo.raise();
@@ -893,13 +898,18 @@
893 898
                 var lc = Number(QSettings.value("liveColumn"));
894 899
                 var file = new QFile(filename);
895 900
                 log.clearOutputColumns();
901
+				channelSkip = 0;
896 902
 				for(var i = 0; i < columnNames.length - channelSkip; i++)
897 903
 				{
898
-					if(channelType[i] == "T") {
899
-						log.addOutputTemperatureColumn(lc + i);
900
-					}
901
-					else {
902
-						log.addOutputControlColumn(lc + i);
904
+					if(channelVisibility[i]) {
905
+						if(channelType[i] == "T") {
906
+							log.addOutputTemperatureColumn(lc + i - channelSkip);
907
+						}
908
+						else {
909
+							log.addOutputControlColumn(lc + i - channelSkip);
910
+						}
911
+					} else {
912
+						channelSkip++;
903 913
 					}
904 914
 				}
905 915
 				log.addOutputAnnotationColumn(lc + columnNames.length - channelSkip);

Loading…
Отказ
Запис