[5692] | 1 | // Part of BNC, a utility for retrieving decoding and
|
---|
| 2 | // converting GNSS data streams from NTRIP broadcasters.
|
---|
| 3 | //
|
---|
| 4 | // Copyright (C) 2007
|
---|
| 5 | // German Federal Agency for Cartography and Geodesy (BKG)
|
---|
| 6 | // http://www.bkg.bund.de
|
---|
| 7 | // Czech Technical University Prague, Department of Geodesy
|
---|
| 8 | // http://www.fsv.cvut.cz
|
---|
| 9 | //
|
---|
| 10 | // Email: euref-ip@bkg.bund.de
|
---|
| 11 | //
|
---|
| 12 | // This program is free software; you can redistribute it and/or
|
---|
| 13 | // modify it under the terms of the GNU General Public License
|
---|
| 14 | // as published by the Free Software Foundation, version 2.
|
---|
| 15 | //
|
---|
| 16 | // This program is distributed in the hope that it will be useful,
|
---|
| 17 | // but WITHOUT ANY WARRANTY; without even the implied warranty of
|
---|
| 18 | // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
---|
| 19 | // GNU General Public License for more details.
|
---|
| 20 | //
|
---|
| 21 | // You should have received a copy of the GNU General Public License
|
---|
| 22 | // along with this program; if not, write to the Free Software
|
---|
| 23 | // Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
---|
| 24 |
|
---|
| 25 | /* -------------------------------------------------------------------------
|
---|
| 26 | * BKG NTRIP Client
|
---|
| 27 | * -------------------------------------------------------------------------
|
---|
| 28 | *
|
---|
| 29 | * Class: t_pppWidgets
|
---|
| 30 | *
|
---|
| 31 | * Purpose: This class stores widgets for PPP options
|
---|
| 32 | *
|
---|
| 33 | * Author: L. Mervart
|
---|
| 34 | *
|
---|
| 35 | * Created: 29-Jul-2014
|
---|
| 36 | *
|
---|
[7488] | 37 | * Changes:
|
---|
[5692] | 38 | *
|
---|
| 39 | * -----------------------------------------------------------------------*/
|
---|
| 40 |
|
---|
| 41 | #include <iostream>
|
---|
| 42 |
|
---|
[8252] | 43 | #include <QCheckBox>
|
---|
| 44 | #include <QComboBox>
|
---|
| 45 | #include <QHeaderView>
|
---|
| 46 | #include <QLineEdit>
|
---|
| 47 | #include <QPushButton>
|
---|
| 48 | #include <QRadioButton>
|
---|
| 49 | #include <QSpinBox>
|
---|
| 50 | #include <QTableWidget>
|
---|
| 51 |
|
---|
[6045] | 52 | #include "pppWidgets.h"
|
---|
[5692] | 53 | #include "qtfilechooser.h"
|
---|
[5694] | 54 | #include "bncsettings.h"
|
---|
[5950] | 55 | #include "bnccore.h"
|
---|
[5692] | 56 |
|
---|
| 57 | using namespace std;
|
---|
| 58 |
|
---|
| 59 | // Constructor
|
---|
| 60 | ////////////////////////////////////////////////////////////////////////////
|
---|
| 61 | t_pppWidgets::t_pppWidgets() {
|
---|
[5699] | 62 |
|
---|
[7488] | 63 | _dataSource = new QComboBox(); _dataSource ->setObjectName("PPP/dataSource"); _widgets << _dataSource;
|
---|
| 64 | _rinexObs = new qtFileChooser(); _rinexObs ->setObjectName("PPP/rinexObs"); _widgets << _rinexObs;
|
---|
| 65 | _rinexNav = new qtFileChooser(); _rinexNav ->setObjectName("PPP/rinexNav"); _widgets << _rinexNav;
|
---|
[5701] | 66 | _corrMount = new QLineEdit(); _corrMount ->setObjectName("PPP/corrMount"); _widgets << _corrMount;
|
---|
[9599] | 67 | _ionoMount = new QLineEdit(); _ionoMount ->setObjectName("PPP/ionoMount"); _widgets << _ionoMount;
|
---|
[7488] | 68 | _corrFile = new qtFileChooser(); _corrFile ->setObjectName("PPP/corrFile"); _widgets << _corrFile;
|
---|
[9599] | 69 | _ionoFile = new qtFileChooser(); _ionoFile ->setObjectName("PPP/ionoFile"); _widgets << _ionoFile;
|
---|
[7488] | 70 | _crdFile = new qtFileChooser(); _crdFile ->setObjectName("PPP/crdFile"); _widgets << _crdFile;
|
---|
| 71 | _antexFile = new qtFileChooser(); _antexFile ->setObjectName("PPP/antexFile"); _widgets << _antexFile;
|
---|
[7961] | 72 | _blqFile = new qtFileChooser(); _blqFile ->setObjectName("PPP/blqFile"); _widgets << _blqFile;
|
---|
[7506] | 73 | _logPath = new QLineEdit(); _logPath ->setObjectName("PPP/logPath"); _widgets << _logPath;
|
---|
| 74 | _nmeaPath = new QLineEdit(); _nmeaPath ->setObjectName("PPP/nmeaPath"); _widgets << _nmeaPath;
|
---|
| 75 | _snxtroPath = new QLineEdit(); _snxtroPath ->setObjectName("PPP/snxtroPath"); _widgets << _snxtroPath;
|
---|
[8403] | 76 | _snxtroSampl = new QComboBox(); _snxtroSampl->setObjectName("PPP/snxtroSampl"); _widgets << _snxtroSampl;
|
---|
[7500] | 77 | _snxtroIntr = new QComboBox(); _snxtroIntr ->setObjectName("PPP/snxtroIntr"); _widgets << _snxtroIntr;
|
---|
[7764] | 78 | _snxtroAc = new QLineEdit(); _snxtroAc ->setObjectName("PPP/snxtroAc"); _widgets << _snxtroAc;
|
---|
| 79 | _snxtroSol = new QLineEdit(); _snxtroSol ->setObjectName("PPP/snxtroSol"); _widgets << _snxtroSol;
|
---|
[9158] | 80 | _v2filenames = new QCheckBox(); _v2filenames ->setObjectName("PPP/v2filenames"); _widgets << _v2filenames;
|
---|
[7488] | 81 | _staTable = new QTableWidget(); _staTable ->setObjectName("PPP/staTable"); _widgets << _staTable;
|
---|
| 82 | _lcGPS = new QComboBox(); _lcGPS ->setObjectName("PPP/lcGPS"); _widgets << _lcGPS;
|
---|
| 83 | _lcGLONASS = new QComboBox(); _lcGLONASS ->setObjectName("PPP/lcGLONASS"); _widgets << _lcGLONASS;
|
---|
| 84 | _lcGalileo = new QComboBox(); _lcGalileo ->setObjectName("PPP/lcGalileo"); _widgets << _lcGalileo;
|
---|
[6883] | 85 | _lcBDS = new QComboBox(); _lcBDS ->setObjectName("PPP/lcBDS"); _widgets << _lcBDS;
|
---|
[8905] | 86 | _modelObs = new QComboBox(); _modelObs ->setObjectName("PPP/modelObs"); _widgets << _modelObs;
|
---|
| 87 | _pseudoObs = new QComboBox(); _pseudoObs ->setObjectName("PPP/pseudoObs"); _widgets << _pseudoObs;
|
---|
[7488] | 88 | _sigmaC1 = new QLineEdit(); _sigmaC1 ->setObjectName("PPP/sigmaC1"); _widgets << _sigmaC1;
|
---|
| 89 | _sigmaL1 = new QLineEdit(); _sigmaL1 ->setObjectName("PPP/sigmaL1"); _widgets << _sigmaL1;
|
---|
[9302] | 90 | _sigmaGIM = new QLineEdit(); _sigmaGIM ->setObjectName("PPP/sigmaGIM"); _widgets << _sigmaGIM;
|
---|
[7488] | 91 | _maxResC1 = new QLineEdit(); _maxResC1 ->setObjectName("PPP/maxResC1"); _widgets << _maxResC1;
|
---|
| 92 | _maxResL1 = new QLineEdit(); _maxResL1 ->setObjectName("PPP/maxResL1"); _widgets << _maxResL1;
|
---|
[9552] | 93 | _maxResGIM = new QLineEdit(); _maxResGIM ->setObjectName("PPP/maxResGIM"); _widgets << _maxResGIM;
|
---|
[5961] | 94 | _minObs = new QSpinBox(); _minObs ->setObjectName("PPP/minObs"); _widgets << _minObs;
|
---|
| 95 | _minEle = new QSpinBox(); _minEle ->setObjectName("PPP/minEle"); _widgets << _minEle;
|
---|
| 96 | _eleWgtCode = new QCheckBox(); _eleWgtCode ->setObjectName("PPP/eleWgtCode"); _widgets << _eleWgtCode;
|
---|
| 97 | _eleWgtPhase = new QCheckBox(); _eleWgtPhase ->setObjectName("PPP/eleWgtPhase"); _widgets << _eleWgtPhase;
|
---|
| 98 | _seedingTime = new QLineEdit(); _seedingTime ->setObjectName("PPP/seedingTime"); _widgets << _seedingTime;
|
---|
[5699] | 99 | _corrWaitTime = new QSpinBox(); _corrWaitTime->setObjectName("PPP/corrWaitTime"); _widgets << _corrWaitTime;
|
---|
[5961] | 100 |
|
---|
| 101 | _addStaButton = new QPushButton("Add Station"); _widgets << _addStaButton;
|
---|
| 102 | _delStaButton = new QPushButton("Delete Station"); _widgets << _delStaButton;
|
---|
| 103 |
|
---|
[6718] | 104 | _addStaButton->setWhatsThis(tr("<p>Hit the 'Add Station' button to add a new line to the Station table.</p>"));
|
---|
| 105 | _delStaButton->setWhatsThis(tr("<p>Hit the 'Delete Station' button to delete a highlighted row from the Station table.</p>"));
|
---|
| 106 |
|
---|
[5955] | 107 | _plotCoordinates = new QLineEdit; _plotCoordinates ->setObjectName("PPP/plotCoordinates"); _widgets << _plotCoordinates;
|
---|
| 108 | _mapWinButton = new QPushButton; _mapWinButton ->setObjectName("PPP/mapWinButton"); _widgets << _mapWinButton;
|
---|
[6729] | 109 | _audioResponse = new QLineEdit; _audioResponse ->setObjectName("PPP/audioResponse"); _widgets << _audioResponse;
|
---|
[5955] | 110 | _mapWinDotSize = new QLineEdit; _mapWinDotSize ->setObjectName("PPP/mapWinDotSize"); _widgets << _mapWinDotSize;
|
---|
| 111 | _mapWinDotColor = new QComboBox; _mapWinDotColor ->setObjectName("PPP/mapWinDotColor"); _widgets << _mapWinDotColor;
|
---|
| 112 | _mapSpeedSlider = new QSlider; _mapSpeedSlider ->setObjectName("PPP/mapSpeedSlider"); _widgets << _mapSpeedSlider;
|
---|
[5893] | 113 |
|
---|
[5697] | 114 | _dataSource->setEditable(false);
|
---|
[6710] | 115 | _dataSource->addItems(QString(",Real-Time Streams,RINEX Files").split(","));
|
---|
[5699] | 116 | connect(_dataSource, SIGNAL(currentIndexChanged(const QString&)), this, SLOT(slotEnableWidgets()));
|
---|
[8905] | 117 | connect(_modelObs, SIGNAL(currentIndexChanged(const QString&)), this, SLOT(slotEnableWidgets()));
|
---|
| 118 | connect(_snxtroPath, SIGNAL(textChanged(const QString &)), this, SLOT(slotPPPTextChanged()));
|
---|
| 119 | connect(_snxtroAc, SIGNAL(textChanged(const QString &)), this, SLOT(slotPPPTextChanged()));
|
---|
| 120 | connect(_snxtroSol, SIGNAL(textChanged(const QString &)), this, SLOT(slotPPPTextChanged()));
|
---|
[5697] | 121 |
|
---|
[6659] | 122 | slotEnableWidgets();
|
---|
[6656] | 123 |
|
---|
[5697] | 124 | _lcGPS->setEditable(false);
|
---|
[7239] | 125 | #ifdef USE_PPP_SSR_I
|
---|
[7207] | 126 | _lcGPS->addItems(QString("P3,P3&L3").split(","));
|
---|
[7049] | 127 | #else
|
---|
[9494] | 128 | _lcGPS->addItems(QString("no,Pi,Li,Pi&Li").split(","));
|
---|
[7049] | 129 | #endif
|
---|
[5697] | 130 |
|
---|
| 131 | _lcGLONASS->setEditable(false);
|
---|
[7261] | 132 | #ifdef USE_PPP_SSR_I
|
---|
| 133 | _lcGLONASS->addItems(QString("no,P3,L3,P3&L3").split(","));
|
---|
| 134 | #else
|
---|
[9494] | 135 | _lcGLONASS->addItems(QString("no,Pi,Li,Pi&Li").split(","));
|
---|
[7261] | 136 | #endif
|
---|
[5697] | 137 |
|
---|
| 138 | _lcGalileo->setEditable(false);
|
---|
[7261] | 139 | #ifdef USE_PPP_SSR_I
|
---|
[5699] | 140 | _lcGalileo->addItems(QString("no,P3,L3,P3&L3").split(","));
|
---|
[7261] | 141 | #else
|
---|
[9494] | 142 | _lcGalileo->addItems(QString("no,Pi,Li,Pi&Li").split(","));
|
---|
[7261] | 143 | #endif
|
---|
[5697] | 144 |
|
---|
[6883] | 145 | _lcBDS->setEditable(false);
|
---|
[7261] | 146 | #ifdef USE_PPP_SSR_I
|
---|
[6883] | 147 | _lcBDS->addItems(QString("no,P3,L3,P3&L3").split(","));
|
---|
[7261] | 148 | #else
|
---|
[9494] | 149 | _lcBDS->addItems(QString("no,Pi,Li,Pi&Li").split(","));
|
---|
[7261] | 150 | #endif
|
---|
[6883] | 151 |
|
---|
[8905] | 152 | _modelObs->setEditable(false);
|
---|
| 153 | _pseudoObs->setEditable(false);
|
---|
| 154 | #ifdef USE_PPP_SSR_I
|
---|
| 155 | _modelObs->addItems(QString("Ionosphere-free PPP").split(","));
|
---|
| 156 | _pseudoObs->addItems(QString("no").split(","));
|
---|
| 157 | #else
|
---|
[9573] | 158 | //_modelObs->addItems(QString("Ionosphere-free PPP,Uncombined PPP,PPP-RTK,DCM with Code Biases,DCM with Phase Biases").split(","));
|
---|
| 159 | _modelObs->addItems(QString("Ionosphere-free PPP,Uncombined PPP,DCM with Code Biases,DCM with Phase Biases").split(","));
|
---|
[9538] | 160 | _pseudoObs->addItems(QString("no,Ionosphere").split(","));
|
---|
[8905] | 161 | #endif
|
---|
| 162 |
|
---|
[8403] | 163 | _snxtroSampl->setEditable(false);
|
---|
| 164 | _snxtroSampl->addItems(QString("1 sec,5 sec,10 sec,30 sec,60 sec,300 sec").split(","));
|
---|
[6607] | 165 |
|
---|
[7488] | 166 | _snxtroIntr->setEditable(false);
|
---|
| 167 | _snxtroIntr->addItems(QString("1 min,2 min,5 min,10 min,15 min,30 min,1 hour,1 day").split(","));
|
---|
[7495] | 168 | _snxtroIntr->setCurrentIndex(6);
|
---|
[7488] | 169 |
|
---|
[9386] | 170 | _minObs->setMinimum(5);
|
---|
[5962] | 171 | _minObs->setMaximum(6);
|
---|
| 172 | _minObs->setSingleStep(1);
|
---|
| 173 |
|
---|
| 174 | _minEle->setMinimum(0);
|
---|
| 175 | _minEle->setMaximum(20);
|
---|
| 176 | _minEle->setSingleStep(1);
|
---|
| 177 | _minEle->setSuffix(" deg");
|
---|
| 178 |
|
---|
[5698] | 179 | _corrWaitTime->setMinimum(0);
|
---|
| 180 | _corrWaitTime->setMaximum(20);
|
---|
| 181 | _corrWaitTime->setSingleStep(1);
|
---|
| 182 | _corrWaitTime->setSuffix(" sec");
|
---|
| 183 |
|
---|
[9559] | 184 | _staTable->setColumnCount(10);
|
---|
[5703] | 185 | _staTable->setRowCount(0);
|
---|
[5702] | 186 | _staTable->setHorizontalHeaderLabels(
|
---|
[9559] | 187 | QString("Station,Sigma N,Sigma E,Sigma H,Noise N,Noise E,Noise H,Tropo Sigma,Tropo Noise, NMEA Port").split(","));
|
---|
[5703] | 188 | _staTable->setSelectionMode(QAbstractItemView::ExtendedSelection);
|
---|
| 189 | _staTable->setSelectionBehavior(QAbstractItemView::SelectRows);
|
---|
[8252] | 190 | #if QT_VERSION >= 0x050000
|
---|
[8231] | 191 | _staTable->horizontalHeader()->setSectionResizeMode(QHeaderView::Interactive);
|
---|
[8252] | 192 | #endif
|
---|
[5703] | 193 | _staTable->horizontalHeader()->setDefaultAlignment(Qt::AlignLeft);
|
---|
[7488] | 194 |
|
---|
[5703] | 195 | connect(_addStaButton, SIGNAL(clicked()), this, SLOT(slotAddStation()));
|
---|
| 196 | connect(_delStaButton, SIGNAL(clicked()), this, SLOT(slotDelStation()));
|
---|
[5702] | 197 |
|
---|
[5893] | 198 | _mapWinButton->setText("Open Map");
|
---|
| 199 |
|
---|
[5955] | 200 | _mapWinDotColor->setEditable(false);
|
---|
| 201 | _mapWinDotColor->addItems(QString("red,yellow").split(","));
|
---|
[5893] | 202 |
|
---|
| 203 | _mapSpeedSlider->setOrientation(Qt::Horizontal);
|
---|
| 204 | _mapSpeedSlider->setRange(1, 100);
|
---|
| 205 | _mapSpeedSlider->setTickPosition(QSlider::TicksBelow);
|
---|
| 206 | _mapSpeedSlider->setTickInterval(10);
|
---|
[5950] | 207 | connect(_mapSpeedSlider, SIGNAL(valueChanged(int)), BNC_CORE, SIGNAL(mapSpeedSliderChanged(int)));
|
---|
| 208 |
|
---|
[7658] | 209 | // WhatsThis, PPP (2)
|
---|
| 210 | // ------------------
|
---|
[9559] | 211 | _staTable->setWhatsThis(tr("<p>Specify values for Sigma and white Noise of the Stations North, East and Height coordinate components in meters. Specify also a Sigma in meters for a priori model based Tropospheric delays and a Sigma in meters per second for the delay's Noise.</p><p>Specifying one record per Station is mandatory. BNC will only process data for stations which are listed here. To define a station, specify the 'Mountpoint' when in 'Real-Time Streams' mode or the 4-character station ID when in 'RINEX Files' mode.</p><p>'Sigma' is meant to describe the uncertainty of a single coordinate or tropospheric delay estimated for one epoch. 'Noise' is meant to describe the variation of estimates from epoch to epoch.</p><p><ul><li>A Sigma of 100.0 meters may be an appropriate choice e.g. for the initial N/E/H coordinates. However, this value may be significantly smaller (i.e. 0.01) for stations with well-known a priori coordinates.</li><li>A Noise of 100.0 meters for the estimated N/E/H coordinates may also be appropriate considering the potential movement of a rover position.</li><li>A value of 0.1 meters may be an appropriate Sigma for the a priori model based Tropospheric delay estimation.</li><li>Specify a Noise to describe the expected variation of the tropospheric effect over time. Supposing 1Hz observation data, specifying a value of 3e-6 would mean that the tropospheric effect may vary 3600 * 3e-6 = 0.01 meters per hour.</li></ul></p><p>You can also specify a 'NMEA Port' to output coordinates in NMEA format through an IP port of your local host. <i>[key: PPP/staTable]</i></p>"));
|
---|
[6715] | 212 |
|
---|
[7658] | 213 | // WhatsThis, PPP (3)
|
---|
| 214 | // ------------------
|
---|
[8010] | 215 | _corrWaitTime->setWhatsThis(tr("<p>Zero value means that BNC processes each epoch of data immediately after its arrival using satellite clock corrections available at that time.</p><p> Specifying a non-zero value (i.e. 5 sec) means that the epochs of data are buffered and the processing of each epoch is postponed till the satellite clock corrections not older than '5 sec' (example) become available. <i>[key: PPP/corrWaitTime]</i><p>"));
|
---|
| 216 | _seedingTime->setWhatsThis(tr("<p>Enter the length of a startup period in seconds for which you want to fix the PPP solutions to known a priori coordinates as introduced through option 'Coordinates file'. Adjust 'Sigma N/E/H' in the PPP Stations table according to the coordinate's precision. Fixing a priori coordinates is done in BNC through setting 'Sigma N/E/H' temporarily to zero.</p><p>This option allows the PPP solution to rapidly converge. It requires that the antenna remains unmoved on the a priori known position throughout the startup period.</p><p>A value of 60 is likely to be an appropriate choice.</p><p>Default is an empty option field, meaning that you don't want BNC to fix PPP solutions during startup to an a priori coordinate. <i>[key: PPP/seedingTime]</i></p>"));
|
---|
[6720] | 217 |
|
---|
[7663] | 218 | // WhatsThis, PPP (4)
|
---|
| 219 | // ------------------
|
---|
[8010] | 220 | _plotCoordinates->setWhatsThis(tr("<p>For one of your PPP Stations BNC can produce a time series plot of coordinate displacements in the 'PPP Plot' tab below. Specify a 'Mountpoint' (when in 'Real-Time Streams' mode) or the 4-character station ID (when in 'RINEX Files' mode) to define the station whose coordinate displacements you would like to see plotted.</p><p>Note that this option makes only sense for a stationary receiver with known a priori marker coordinates as specified through PPP option 'Coordinates file'.</p><p>Default is an empty option field, meaning that BNC shall not produce a time series plot of PPP coordinate displacements. <i>[key: PPP/plotCoordinates]</i></p>"));
|
---|
| 221 | _audioResponse->setWhatsThis(tr("<p>Specify an 'Audio response' threshold in meters. A beep is produced by BNC whenever a horizontal PPP coordinate component differs by more than the threshold value from the a priori marker coordinate.</p><p>Default is an empty option field, meaning that you don't want BNC to produce alarm signals. <i>[key: PPP/audioResponse]</i></p>"));
|
---|
[7677] | 222 | _mapWinButton->setWhatsThis(tr("<p>You may like to track your rover position using Google Maps or Open Street Map as a background map. A 'Track map' can be produced with BNC in 'Real-Time Streams' or 'RINEX files' PPP mode.</p><p>The 'Open Map' button opens a windows showing a map according to specified options.</p><p>Even in 'RINEX files' post processing mode you should not forget to specify a proxy under the 'Network' tab if that is operated in front of BNC because the program needs to download the map data.</p>"));
|
---|
[8010] | 223 | _mapWinDotSize->setWhatsThis(tr("<p>Specify the size of dots showing rover positions on the track map.</p><p>A dot size of '3' may be appropriate. The maximum possible dot size is '10'. An empty option field or a size of '0' would mean that you don't want BNC to show the rover's track on the map. <i>[key: PPP/mapWinDotSize]</i></p>"));
|
---|
| 224 | _mapWinDotColor->setWhatsThis(tr("<p>Specify the color of dots showing the rover track on the map. <i>[key: PPP/mapWinDotColor]</i></p>"));
|
---|
| 225 | _mapSpeedSlider->setWhatsThis(tr("<p>With BNC in 'RINEX files' PPP post processing mode you can specify the speed of computations as appropriate for 'Track map' visualization.</p><p>Note that you can adjust 'Post-processing speed' on-the-fly while BNC is already processing your observations. <i>[key: PPP/mapSpeedSlider]</i></p>"));
|
---|
[6729] | 226 |
|
---|
[5696] | 227 | readOptions();
|
---|
[5692] | 228 | }
|
---|
| 229 |
|
---|
[7488] | 230 | //
|
---|
[5694] | 231 | ////////////////////////////////////////////////////////////////////////////
|
---|
[7640] | 232 | t_pppWidgets::~t_pppWidgets() {
|
---|
| 233 | delete _dataSource;
|
---|
| 234 | delete _rinexObs;
|
---|
| 235 | delete _rinexNav;
|
---|
| 236 | delete _corrMount;
|
---|
[9599] | 237 | delete _ionoMount;
|
---|
[7640] | 238 | delete _corrFile;
|
---|
[9599] | 239 | delete _ionoFile;
|
---|
[7640] | 240 | delete _crdFile;
|
---|
| 241 | delete _antexFile;
|
---|
[7961] | 242 | delete _blqFile;
|
---|
[7640] | 243 | delete _logPath;
|
---|
| 244 | delete _nmeaPath;
|
---|
| 245 | delete _snxtroPath;
|
---|
| 246 | delete _snxtroSampl;
|
---|
| 247 | delete _snxtroIntr;
|
---|
[7764] | 248 | delete _snxtroAc;
|
---|
| 249 | delete _snxtroSol;
|
---|
[9158] | 250 | delete _v2filenames;
|
---|
[7640] | 251 | for (int iRow = _staTable->rowCount()-1; iRow >=0; iRow--) {
|
---|
| 252 | _staTable->removeRow(iRow);
|
---|
| 253 | }
|
---|
| 254 | delete _staTable;
|
---|
| 255 | delete _lcGPS;
|
---|
| 256 | delete _lcGLONASS;
|
---|
| 257 | delete _lcGalileo;
|
---|
| 258 | delete _lcBDS;
|
---|
[8905] | 259 | delete _modelObs;
|
---|
| 260 | delete _pseudoObs;
|
---|
[7640] | 261 | delete _sigmaC1;
|
---|
| 262 | delete _sigmaL1;
|
---|
[9302] | 263 | delete _sigmaGIM;
|
---|
[7640] | 264 | delete _maxResC1;
|
---|
| 265 | delete _maxResL1;
|
---|
[9552] | 266 | delete _maxResGIM;
|
---|
[7640] | 267 | delete _minObs;
|
---|
| 268 | delete _minEle;
|
---|
| 269 | delete _eleWgtCode;
|
---|
| 270 | delete _eleWgtPhase;
|
---|
| 271 | delete _seedingTime;
|
---|
| 272 | delete _corrWaitTime;
|
---|
| 273 | delete _addStaButton;
|
---|
| 274 | delete _delStaButton;
|
---|
| 275 | delete _plotCoordinates;
|
---|
| 276 | delete _mapWinButton;
|
---|
| 277 | delete _audioResponse;
|
---|
| 278 | delete _mapWinDotSize;
|
---|
| 279 | delete _mapWinDotColor;
|
---|
| 280 | delete _mapSpeedSlider;
|
---|
| 281 | }
|
---|
| 282 |
|
---|
| 283 | //
|
---|
| 284 | ////////////////////////////////////////////////////////////////////////////
|
---|
[5696] | 285 | void t_pppWidgets::readOptions() {
|
---|
| 286 |
|
---|
| 287 | bncSettings settings;
|
---|
| 288 |
|
---|
[5707] | 289 | // ComboBoxes
|
---|
| 290 | // ----------
|
---|
[5696] | 291 | int ii = _dataSource->findText(settings.value(_dataSource->objectName()).toString());
|
---|
| 292 | if (ii != -1) {
|
---|
| 293 | _dataSource->setCurrentIndex(ii);
|
---|
| 294 | }
|
---|
| 295 | ii = _lcGPS->findText(settings.value(_lcGPS->objectName()).toString());
|
---|
| 296 | if (ii != -1) {
|
---|
| 297 | _lcGPS->setCurrentIndex(ii);
|
---|
| 298 | }
|
---|
| 299 | ii = _lcGLONASS->findText(settings.value(_lcGLONASS->objectName()).toString());
|
---|
| 300 | if (ii != -1) {
|
---|
| 301 | _lcGLONASS->setCurrentIndex(ii);
|
---|
| 302 | }
|
---|
| 303 | ii = _lcGalileo->findText(settings.value(_lcGalileo->objectName()).toString());
|
---|
| 304 | if (ii != -1) {
|
---|
| 305 | _lcGalileo->setCurrentIndex(ii);
|
---|
| 306 | }
|
---|
[6883] | 307 | ii = _lcBDS->findText(settings.value(_lcBDS->objectName()).toString());
|
---|
| 308 | if (ii != -1) {
|
---|
| 309 | _lcBDS->setCurrentIndex(ii);
|
---|
| 310 | }
|
---|
[8905] | 311 | ii = _modelObs->findText(settings.value(_modelObs->objectName()).toString());
|
---|
| 312 | if (ii != -1) {
|
---|
| 313 | _modelObs->setCurrentIndex(ii);
|
---|
| 314 | }
|
---|
| 315 | ii = _pseudoObs->findText(settings.value(_pseudoObs->objectName()).toString());
|
---|
| 316 | if (ii != -1) {
|
---|
| 317 | _pseudoObs->setCurrentIndex(ii);
|
---|
| 318 | }
|
---|
[7488] | 319 | ii = _snxtroIntr->findText(settings.value(_snxtroIntr->objectName()).toString());
|
---|
| 320 | if (ii != -1) {
|
---|
| 321 | _snxtroIntr->setCurrentIndex(ii);
|
---|
| 322 | }
|
---|
[5696] | 323 |
|
---|
[5707] | 324 | // FileChoosers
|
---|
| 325 | // ------------
|
---|
[5696] | 326 | _rinexObs ->setFileName(settings.value(_rinexObs ->objectName()).toString());
|
---|
| 327 | _rinexNav ->setFileName(settings.value(_rinexNav ->objectName()).toString());
|
---|
| 328 | _corrFile ->setFileName(settings.value(_corrFile ->objectName()).toString());
|
---|
| 329 | _crdFile ->setFileName(settings.value(_crdFile ->objectName()).toString());
|
---|
| 330 | _antexFile->setFileName(settings.value(_antexFile->objectName()).toString());
|
---|
[7966] | 331 | _blqFile->setFileName(settings.value(_blqFile->objectName()).toString());
|
---|
[5696] | 332 |
|
---|
[5707] | 333 | // LineEdits
|
---|
| 334 | // ---------
|
---|
[5969] | 335 | _corrMount ->setText(settings.value(_corrMount ->objectName()).toString());
|
---|
[9599] | 336 | _ionoMount ->setText(settings.value(_ionoMount ->objectName()).toString());
|
---|
[7506] | 337 | _logPath ->setText(settings.value(_logPath ->objectName()).toString());
|
---|
| 338 | _nmeaPath ->setText(settings.value(_nmeaPath ->objectName()).toString());
|
---|
| 339 | _snxtroPath ->setText(settings.value(_snxtroPath ->objectName()).toString());
|
---|
[7764] | 340 | _snxtroAc ->setText(settings.value(_snxtroAc ->objectName()).toString());
|
---|
| 341 | _snxtroSol ->setText(settings.value(_snxtroSol ->objectName()).toString());
|
---|
[5696] | 342 |
|
---|
[7047] | 343 | if (!settings.value(_sigmaC1->objectName()).toString().isEmpty()) {
|
---|
| 344 | _sigmaC1->setText(settings.value(_sigmaC1->objectName()).toString());
|
---|
| 345 | }
|
---|
| 346 | else {
|
---|
| 347 | _sigmaC1->setText("2.0");
|
---|
| 348 | }
|
---|
| 349 |
|
---|
| 350 | if (!settings.value(_sigmaL1->objectName()).toString().isEmpty()) {
|
---|
| 351 | _sigmaL1->setText(settings.value(_sigmaL1->objectName()).toString());
|
---|
| 352 | }
|
---|
| 353 | else {
|
---|
[9565] | 354 | _sigmaL1->setText("0.02");
|
---|
[7047] | 355 | }
|
---|
| 356 |
|
---|
[9302] | 357 | if (!settings.value(_sigmaGIM->objectName()).toString().isEmpty()) {
|
---|
| 358 | _sigmaGIM->setText(settings.value(_sigmaGIM->objectName()).toString());
|
---|
| 359 | }
|
---|
| 360 | else {
|
---|
[9565] | 361 | _sigmaGIM->setText("5.0");
|
---|
[9302] | 362 | }
|
---|
| 363 |
|
---|
[7047] | 364 | if (!settings.value(_maxResC1->objectName()).toString().isEmpty()) {
|
---|
| 365 | _maxResC1->setText(settings.value(_maxResC1->objectName()).toString());
|
---|
| 366 | }
|
---|
| 367 | else {
|
---|
[9386] | 368 | _maxResC1->setText("3.0");
|
---|
[7047] | 369 | }
|
---|
| 370 |
|
---|
| 371 | if (!settings.value(_maxResL1->objectName()).toString().isEmpty()) {
|
---|
| 372 | _maxResL1->setText(settings.value(_maxResL1->objectName()).toString());
|
---|
| 373 | }
|
---|
[7488] | 374 | else {
|
---|
[7047] | 375 | _maxResL1->setText("0.03");
|
---|
| 376 | }
|
---|
| 377 |
|
---|
[9552] | 378 | if (!settings.value(_maxResGIM->objectName()).toString().isEmpty()) {
|
---|
| 379 | _maxResGIM->setText(settings.value(_maxResGIM->objectName()).toString());
|
---|
| 380 | }
|
---|
| 381 | else {
|
---|
[9565] | 382 | _maxResGIM->setText("3.0");
|
---|
[9552] | 383 | }
|
---|
| 384 |
|
---|
| 385 |
|
---|
[7069] | 386 | if (!settings.value(_seedingTime->objectName()).toString().isEmpty()) {
|
---|
| 387 | _seedingTime->setText(settings.value(_seedingTime->objectName()).toString());
|
---|
| 388 | }
|
---|
| 389 | else {
|
---|
[7076] | 390 | _seedingTime->setText("0");
|
---|
[7069] | 391 | }
|
---|
| 392 |
|
---|
[5969] | 393 | // CheckBoxes
|
---|
| 394 | // ----------
|
---|
| 395 | _eleWgtCode ->setCheckState(Qt::CheckState(settings.value(_eleWgtCode ->objectName()).toInt()));
|
---|
| 396 | _eleWgtPhase->setCheckState(Qt::CheckState(settings.value(_eleWgtPhase->objectName()).toInt()));
|
---|
[9158] | 397 | _v2filenames->setCheckState(Qt::CheckState(settings.value(_v2filenames->objectName()).toInt()));
|
---|
[5969] | 398 |
|
---|
| 399 | // SpinBoxex
|
---|
| 400 | // ---------
|
---|
| 401 | _minObs->setValue(settings.value(_minObs->objectName()).toInt());
|
---|
| 402 | _minEle->setValue(settings.value(_minEle->objectName()).toInt());
|
---|
[5696] | 403 | _corrWaitTime->setValue(settings.value(_corrWaitTime->objectName()).toInt());
|
---|
[5707] | 404 |
|
---|
[8403] | 405 |
|
---|
| 406 | ii = _snxtroSampl->findText(settings.value(_snxtroSampl->objectName()).toString());
|
---|
| 407 | if (ii != -1) {
|
---|
| 408 | _snxtroSampl->setCurrentIndex(ii);
|
---|
| 409 | }
|
---|
| 410 |
|
---|
[5707] | 411 | // Table with stations
|
---|
| 412 | // -------------------
|
---|
| 413 | for (int iRow = _staTable->rowCount()-1; iRow >=0; iRow--) {
|
---|
| 414 | _staTable->removeRow(iRow);
|
---|
| 415 | }
|
---|
| 416 | int iRow = -1;
|
---|
| 417 | QListIterator<QString> it(settings.value(_staTable->objectName()).toStringList());
|
---|
| 418 | while (it.hasNext()) {
|
---|
| 419 | QStringList hlp = it.next().split(",");
|
---|
| 420 | ++iRow;
|
---|
| 421 | _staTable->insertRow(iRow);
|
---|
| 422 | for (int iCol = 0; iCol < hlp.size(); iCol++) {
|
---|
| 423 | _staTable->setItem(iRow, iCol, new QTableWidgetItem(hlp[iCol]));
|
---|
| 424 | }
|
---|
| 425 | }
|
---|
[5893] | 426 |
|
---|
| 427 | // Plots and Maps
|
---|
| 428 | // --------------
|
---|
[5955] | 429 | _plotCoordinates ->setText(settings.value(_plotCoordinates->objectName()).toString());
|
---|
[6729] | 430 | _audioResponse ->setText(settings.value(_audioResponse->objectName()).toString());
|
---|
[5955] | 431 | _mapWinDotSize ->setText(settings.value(_mapWinDotSize->objectName()).toString());
|
---|
[5893] | 432 |
|
---|
[5955] | 433 | ii = _mapWinDotColor->findText(settings.value(_mapWinDotColor->objectName()).toString());
|
---|
[5893] | 434 | if (ii != -1) {
|
---|
[5955] | 435 | _mapWinDotColor->setCurrentIndex(ii);
|
---|
[5893] | 436 | }
|
---|
| 437 |
|
---|
| 438 | int speed = settings.value(_mapSpeedSlider->objectName()).toInt();
|
---|
| 439 | if (speed == 0) speed = _mapSpeedSlider->maximum();
|
---|
| 440 | _mapSpeedSlider->setSliderPosition(speed);
|
---|
[5696] | 441 | }
|
---|
| 442 |
|
---|
[7488] | 443 | //
|
---|
[5696] | 444 | ////////////////////////////////////////////////////////////////////////////
|
---|
[5694] | 445 | void t_pppWidgets::saveOptions() {
|
---|
| 446 |
|
---|
| 447 | bncSettings settings;
|
---|
| 448 |
|
---|
[5695] | 449 | settings.setValue(_dataSource ->objectName(), _dataSource ->currentText());
|
---|
| 450 | settings.setValue(_rinexObs ->objectName(), _rinexObs ->fileName());
|
---|
| 451 | settings.setValue(_rinexNav ->objectName(), _rinexNav ->fileName());
|
---|
[5701] | 452 | settings.setValue(_corrMount ->objectName(), _corrMount ->text());
|
---|
[9599] | 453 | settings.setValue(_ionoMount ->objectName(), _ionoMount ->text());
|
---|
[5695] | 454 | settings.setValue(_corrFile ->objectName(), _corrFile ->fileName());
|
---|
[9599] | 455 | settings.setValue(_ionoFile ->objectName(), _ionoFile ->fileName());
|
---|
[5695] | 456 | settings.setValue(_crdFile ->objectName(), _crdFile ->fileName());
|
---|
| 457 | settings.setValue(_antexFile ->objectName(), _antexFile ->fileName());
|
---|
[7966] | 458 | settings.setValue(_blqFile ->objectName(), _blqFile ->fileName());
|
---|
[7506] | 459 | settings.setValue(_logPath ->objectName(), _logPath ->text());
|
---|
| 460 | settings.setValue(_nmeaPath ->objectName(), _nmeaPath ->text());
|
---|
| 461 | settings.setValue(_snxtroPath ->objectName(), _snxtroPath ->text());
|
---|
[8403] | 462 | settings.setValue(_snxtroSampl ->objectName(), _snxtroSampl ->currentText());
|
---|
[7764] | 463 | settings.setValue(_snxtroIntr ->objectName(), _snxtroIntr ->currentText());
|
---|
| 464 | settings.setValue(_snxtroAc ->objectName(), _snxtroAc ->text());
|
---|
| 465 | settings.setValue(_snxtroSol ->objectName(), _snxtroSol ->text());
|
---|
[9158] | 466 | settings.setValue(_v2filenames ->objectName(), _v2filenames ->checkState());
|
---|
[5695] | 467 | settings.setValue(_lcGPS ->objectName(), _lcGPS ->currentText());
|
---|
| 468 | settings.setValue(_lcGLONASS ->objectName(), _lcGLONASS ->currentText());
|
---|
| 469 | settings.setValue(_lcGalileo ->objectName(), _lcGalileo ->currentText());
|
---|
[6883] | 470 | settings.setValue(_lcBDS ->objectName(), _lcBDS ->currentText());
|
---|
[8905] | 471 | settings.setValue(_modelObs ->objectName(), _modelObs ->currentText());
|
---|
| 472 | settings.setValue(_pseudoObs ->objectName(), _pseudoObs ->currentText());
|
---|
[5695] | 473 | settings.setValue(_sigmaC1 ->objectName(), _sigmaC1 ->text());
|
---|
| 474 | settings.setValue(_sigmaL1 ->objectName(), _sigmaL1 ->text());
|
---|
[9302] | 475 | settings.setValue(_sigmaGIM ->objectName(), _sigmaGIM ->text());
|
---|
[5695] | 476 | settings.setValue(_corrWaitTime->objectName(), _corrWaitTime->value());
|
---|
[5969] | 477 | settings.setValue(_maxResC1 ->objectName(), _maxResC1 ->text());
|
---|
| 478 | settings.setValue(_maxResL1 ->objectName(), _maxResL1 ->text());
|
---|
[9552] | 479 | settings.setValue(_maxResGIM ->objectName(), _maxResGIM ->text());
|
---|
[5969] | 480 | settings.setValue(_seedingTime ->objectName(), _seedingTime ->text());
|
---|
| 481 | settings.setValue(_minObs ->objectName(), _minObs ->value());
|
---|
| 482 | settings.setValue(_minEle ->objectName(), _minEle ->value());
|
---|
| 483 | settings.setValue(_eleWgtCode ->objectName(), _eleWgtCode ->checkState());
|
---|
| 484 | settings.setValue(_eleWgtPhase ->objectName(), _eleWgtPhase ->checkState());
|
---|
[5694] | 485 |
|
---|
[5707] | 486 | QStringList staList;
|
---|
| 487 | for (int iRow = 0; iRow < _staTable->rowCount(); iRow++) {
|
---|
| 488 | QString hlp;
|
---|
| 489 | for (int iCol = 0; iCol < _staTable->columnCount(); iCol++) {
|
---|
| 490 | if (_staTable->item(iRow, iCol)) {
|
---|
| 491 | hlp += _staTable->item(iRow, iCol)->text() + ",";
|
---|
| 492 | }
|
---|
| 493 | }
|
---|
| 494 | if (!hlp.isEmpty()) {
|
---|
| 495 | staList << hlp;
|
---|
| 496 | }
|
---|
| 497 | }
|
---|
| 498 | settings.setValue(_staTable->objectName(), staList);
|
---|
[5894] | 499 |
|
---|
[5955] | 500 | settings.setValue(_plotCoordinates ->objectName(), _plotCoordinates ->text());
|
---|
[6729] | 501 | settings.setValue(_audioResponse ->objectName(), _audioResponse ->text());
|
---|
[5955] | 502 | settings.setValue(_mapWinDotSize ->objectName(), _mapWinDotSize ->text());
|
---|
| 503 | settings.setValue(_mapWinDotColor ->objectName(), _mapWinDotColor ->currentText());
|
---|
| 504 | settings.setValue(_mapSpeedSlider ->objectName(), _mapSpeedSlider ->value());
|
---|
[5694] | 505 | }
|
---|
[5699] | 506 |
|
---|
[7488] | 507 | //
|
---|
[5699] | 508 | ////////////////////////////////////////////////////////////////////////////
|
---|
| 509 | void t_pppWidgets::slotEnableWidgets() {
|
---|
| 510 |
|
---|
| 511 | const static QPalette paletteWhite(QColor(255, 255, 255));
|
---|
| 512 | const static QPalette paletteGray(QColor(230, 230, 230));
|
---|
| 513 |
|
---|
[6710] | 514 | bool allDisabled = _dataSource->currentText() == "";
|
---|
[5699] | 515 | bool realTime = _dataSource->currentText() == "Real-Time Streams";
|
---|
[5701] | 516 | bool rinexFiles = _dataSource->currentText() == "RINEX Files";
|
---|
[8905] | 517 | bool enablePseudoObs;
|
---|
| 518 | if (_modelObs->currentText() == "PPP-RTK" ||
|
---|
[9386] | 519 | _modelObs->currentText() == "Ionosphere-free PPP") {
|
---|
[8905] | 520 | enablePseudoObs = false;
|
---|
| 521 | }
|
---|
| 522 | else {
|
---|
| 523 | enablePseudoObs = true;
|
---|
| 524 | }
|
---|
[5699] | 525 |
|
---|
| 526 | QListIterator<QWidget*> it(_widgets);
|
---|
| 527 | while (it.hasNext()) {
|
---|
[5700] | 528 | QWidget* widget = it.next();
|
---|
| 529 | widget->setEnabled(!allDisabled);
|
---|
[5699] | 530 | }
|
---|
| 531 |
|
---|
[5701] | 532 | if (realTime) {
|
---|
[7488] | 533 | _rinexObs->setEnabled(false);
|
---|
| 534 | _rinexNav->setEnabled(false);
|
---|
| 535 | _corrFile->setEnabled(false);
|
---|
[9599] | 536 | _ionoFile->setEnabled(false);
|
---|
[5701] | 537 | }
|
---|
| 538 | else if (rinexFiles) {
|
---|
[8905] | 539 | _corrMount ->setEnabled(false);
|
---|
[9599] | 540 | _ionoMount ->setEnabled(false);
|
---|
[8905] | 541 | _audioResponse->setEnabled(false);
|
---|
[5701] | 542 | }
|
---|
| 543 |
|
---|
[7506] | 544 | if ( _snxtroPath->text() != "" && !allDisabled) {
|
---|
[7488] | 545 | _snxtroSampl->setEnabled(true);
|
---|
| 546 | _snxtroIntr ->setEnabled(true);
|
---|
[7764] | 547 | _snxtroAc ->setEnabled(true);
|
---|
| 548 | _snxtroSol ->setEnabled(true);
|
---|
[6748] | 549 | }
|
---|
| 550 | else {
|
---|
[7488] | 551 | _snxtroSampl->setEnabled(false);
|
---|
| 552 | _snxtroIntr ->setEnabled(false);
|
---|
[7764] | 553 | _snxtroAc ->setEnabled(false);
|
---|
| 554 | _snxtroSol ->setEnabled(false);
|
---|
[6748] | 555 | }
|
---|
| 556 |
|
---|
[8905] | 557 | if (enablePseudoObs) {
|
---|
| 558 | _pseudoObs->setEnabled(true);
|
---|
[9302] | 559 | _sigmaGIM->setEnabled(true);
|
---|
[9599] | 560 | _maxResGIM->setEnabled(true);
|
---|
[8905] | 561 | } else {
|
---|
| 562 | _pseudoObs->setEnabled(false);
|
---|
[9302] | 563 | _sigmaGIM->setEnabled(false);
|
---|
[9599] | 564 | _maxResGIM->setEnabled(false);
|
---|
[8905] | 565 | }
|
---|
| 566 |
|
---|
[5699] | 567 | _dataSource->setEnabled(true);
|
---|
[5700] | 568 |
|
---|
| 569 | it.toFront();
|
---|
| 570 | while (it.hasNext()) {
|
---|
| 571 | QWidget* widget = it.next();
|
---|
| 572 | if (widget->isEnabled()) {
|
---|
| 573 | widget->setPalette(paletteWhite);
|
---|
| 574 | }
|
---|
| 575 | else {
|
---|
| 576 | widget->setPalette(paletteGray);
|
---|
| 577 | }
|
---|
| 578 | }
|
---|
[5699] | 579 | }
|
---|
[5703] | 580 |
|
---|
[7488] | 581 | //
|
---|
[5703] | 582 | ////////////////////////////////////////////////////////////////////////////
|
---|
| 583 | void t_pppWidgets::slotAddStation() {
|
---|
[5706] | 584 | int iRow = _staTable->rowCount();
|
---|
| 585 | _staTable->insertRow(iRow);
|
---|
| 586 | for (int iCol = 0; iCol < _staTable->columnCount(); iCol++) {
|
---|
[7045] | 587 | if (iCol == 0) _staTable->setItem(iRow, iCol, new QTableWidgetItem(""));
|
---|
| 588 | if (iCol == 1) _staTable->setItem(iRow, iCol, new QTableWidgetItem("100.0"));
|
---|
| 589 | if (iCol == 2) _staTable->setItem(iRow, iCol, new QTableWidgetItem("100.0"));
|
---|
| 590 | if (iCol == 3) _staTable->setItem(iRow, iCol, new QTableWidgetItem("100.0"));
|
---|
| 591 | if (iCol == 4) _staTable->setItem(iRow, iCol, new QTableWidgetItem("100.0"));
|
---|
| 592 | if (iCol == 5) _staTable->setItem(iRow, iCol, new QTableWidgetItem("100.0"));
|
---|
| 593 | if (iCol == 6) _staTable->setItem(iRow, iCol, new QTableWidgetItem("100.0"));
|
---|
[9580] | 594 | if (iCol == 7) _staTable->setItem(iRow, iCol, new QTableWidgetItem("0.1"));
|
---|
| 595 | if (iCol == 8) _staTable->setItem(iRow, iCol, new QTableWidgetItem("1e-6"));
|
---|
| 596 | if (iCol == 9) _staTable->setItem(iRow, iCol, new QTableWidgetItem("0"));
|
---|
[5706] | 597 | }
|
---|
[5703] | 598 | }
|
---|
| 599 |
|
---|
[7488] | 600 | //
|
---|
[5703] | 601 | ////////////////////////////////////////////////////////////////////////////
|
---|
| 602 | void t_pppWidgets::slotDelStation() {
|
---|
[5706] | 603 | int nRows = _staTable->rowCount();
|
---|
| 604 | bool flg[nRows];
|
---|
| 605 | for (int iRow = 0; iRow < nRows; iRow++) {
|
---|
| 606 | if (_staTable->isItemSelected(_staTable->item(iRow,1))) {
|
---|
| 607 | flg[iRow] = true;
|
---|
| 608 | }
|
---|
| 609 | else {
|
---|
| 610 | flg[iRow] = false;
|
---|
| 611 | }
|
---|
| 612 | }
|
---|
| 613 | for (int iRow = nRows-1; iRow >= 0; iRow--) {
|
---|
| 614 | if (flg[iRow]) {
|
---|
| 615 | _staTable->removeRow(iRow);
|
---|
| 616 | }
|
---|
| 617 | }
|
---|
[5703] | 618 | }
|
---|
[5707] | 619 |
|
---|
[6748] | 620 | // PPP Text
|
---|
| 621 | ////////////////////////////////////////////////////////////////////////////
|
---|
| 622 | void t_pppWidgets::slotPPPTextChanged(){
|
---|
| 623 |
|
---|
| 624 | const static QPalette paletteWhite(QColor(255, 255, 255));
|
---|
| 625 | const static QPalette paletteGray(QColor(230, 230, 230));
|
---|
| 626 |
|
---|
| 627 | // SNX TRO file sampling
|
---|
| 628 | // ---------------------
|
---|
[7506] | 629 | if (sender() == 0 || sender() == _snxtroPath) {
|
---|
| 630 | if ( _snxtroPath->text() != "" ) {
|
---|
[7488] | 631 | _snxtroSampl->setEnabled(true);
|
---|
[7764] | 632 | _snxtroIntr ->setEnabled(true);
|
---|
| 633 | _snxtroAc ->setEnabled(true);
|
---|
| 634 | _snxtroSol ->setEnabled(true);
|
---|
[6748] | 635 | _snxtroSampl->setPalette(paletteWhite);
|
---|
[7764] | 636 | _snxtroIntr ->setPalette(paletteWhite);
|
---|
| 637 | _snxtroAc ->setPalette(paletteWhite);
|
---|
| 638 | _snxtroSol ->setPalette(paletteWhite);
|
---|
[6748] | 639 | }
|
---|
| 640 | else {
|
---|
[7488] | 641 | _snxtroSampl->setEnabled(false);
|
---|
[7764] | 642 | _snxtroIntr ->setEnabled(false);
|
---|
| 643 | _snxtroAc ->setEnabled(false);
|
---|
| 644 | _snxtroSol ->setEnabled(false);
|
---|
[6748] | 645 | _snxtroSampl->setPalette(paletteGray);
|
---|
[7764] | 646 | _snxtroIntr ->setPalette(paletteGray);
|
---|
| 647 | _snxtroAc ->setPalette(paletteGray);
|
---|
| 648 | _snxtroSol ->setPalette(paletteGray);
|
---|
[6748] | 649 | }
|
---|
| 650 | }
|
---|
[8905] | 651 |
|
---|
| 652 |
|
---|
[6748] | 653 | }
|
---|