| Line | |
|---|
| 1 |
|
|---|
| 2 | /* -------------------------------------------------------------------------
|
|---|
| 3 | * RTNet DlgConf
|
|---|
| 4 | * -------------------------------------------------------------------------
|
|---|
| 5 | *
|
|---|
| 6 | * Class: t_dlgConf
|
|---|
| 7 | *
|
|---|
| 8 | * Purpose: Set configuration
|
|---|
| 9 | *
|
|---|
| 10 | * Author: L. Mervart
|
|---|
| 11 | *
|
|---|
| 12 | * Created: 15-Sep-2013
|
|---|
| 13 | *
|
|---|
| 14 | * Changes:
|
|---|
| 15 | *
|
|---|
| 16 | * -----------------------------------------------------------------------*/
|
|---|
| 17 |
|
|---|
| 18 | #include "dlgconf.h"
|
|---|
| 19 | #include "settings.h"
|
|---|
| 20 | #include "const.h"
|
|---|
| 21 |
|
|---|
| 22 | using namespace std;
|
|---|
| 23 | using namespace GnssCenter;
|
|---|
| 24 |
|
|---|
| 25 | // Constructor
|
|---|
| 26 | /////////////////////////////////////////////////////////////////////////////
|
|---|
| 27 | t_dlgConf::t_dlgConf(QWidget* parent) : QDialog(parent) {
|
|---|
| 28 |
|
|---|
| 29 | _hostLineEdit = new QLineEdit;
|
|---|
| 30 | _portLineEdit = new QLineEdit;
|
|---|
| 31 |
|
|---|
| 32 | QVBoxLayout* mainLayout = new QVBoxLayout;
|
|---|
| 33 |
|
|---|
| 34 | QFormLayout* formLayout = new QFormLayout;
|
|---|
| 35 | formLayout->addRow("Host:", _hostLineEdit);
|
|---|
| 36 | formLayout->addRow("Port:", _portLineEdit);
|
|---|
| 37 | mainLayout->addLayout(formLayout);
|
|---|
| 38 |
|
|---|
| 39 | QPushButton* okButton = new QPushButton("OK", this);
|
|---|
| 40 | mainLayout->addWidget(okButton);
|
|---|
| 41 |
|
|---|
| 42 | setLayout(mainLayout);
|
|---|
| 43 |
|
|---|
| 44 | t_settings settings(pluginName);
|
|---|
| 45 | settings.setValue("host", "rtnet.rtcm-ntrip.org");
|
|---|
| 46 | settings.setValue("port", 7777);
|
|---|
| 47 | settings.sync();
|
|---|
| 48 |
|
|---|
| 49 | }
|
|---|
| 50 |
|
|---|
| 51 | // Destructor
|
|---|
| 52 | /////////////////////////////////////////////////////////////////////////////
|
|---|
| 53 | t_dlgConf::~t_dlgConf() {
|
|---|
| 54 | }
|
|---|
| 55 |
|
|---|
Note:
See
TracBrowser
for help on using the repository browser.