Rev 674 | Only display areas with differences | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 674 | Rev 750 | ||
---|---|---|---|
1 | /*************************************************************************** |
1 | /*************************************************************************** |
2 | * Copyright (C) 2009 by Manuel Schrape * |
2 | * Copyright (C) 2009 by Manuel Schrape * |
3 | * manuel.schrape@gmx.de * |
3 | * manuel.schrape@gmx.de * |
4 | * * |
4 | * * |
5 | * This program is free software; you can redistribute it and/or modify * |
5 | * This program is free software; you can redistribute it and/or modify * |
6 | * it under the terms of the GNU General Public License as published by * |
6 | * it under the terms of the GNU General Public License as published by * |
7 | * the Free Software Foundation; either version 2 of the License. * |
7 | * the Free Software Foundation; either version 2 of the License. * |
8 | * * |
8 | * * |
9 | * This program is distributed in the hope that it will be useful, * |
9 | * This program is distributed in the hope that it will be useful, * |
10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of * |
10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of * |
11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * |
11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * |
12 | * GNU General Public License for more details. * |
12 | * GNU General Public License for more details. * |
13 | * * |
13 | * * |
14 | * You should have received a copy of the GNU General Public License * |
14 | * You should have received a copy of the GNU General Public License * |
15 | * along with this program; if not, write to the * |
15 | * along with this program; if not, write to the * |
16 | * Free Software Foundation, Inc., * |
16 | * Free Software Foundation, Inc., * |
17 | * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. * |
17 | * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. * |
18 | ***************************************************************************/ |
18 | ***************************************************************************/ |
19 | #include "dlg_Preferences.h" |
19 | #include "dlg_Preferences.h" |
20 | 20 | ||
21 | dlg_Preferences::dlg_Preferences(QWidget *parent) : QDialog(parent) |
21 | dlg_Preferences::dlg_Preferences(QWidget *parent) : QDialog(parent) |
22 | { |
22 | { |
23 | setupUi(this); |
23 | setupUi(this); |
24 | } |
24 | } |
25 | 25 | ||
26 | void dlg_Preferences::set_Settings(cSettings *t_Settings) |
26 | void dlg_Preferences::set_Settings(cSettings *t_Settings) |
27 | { |
27 | { |
28 | o_Settings = t_Settings; |
28 | o_Settings = t_Settings; |
29 | 29 | ||
30 | le_TCP_Port->setText(QString("%1").arg(o_Settings->SERVER.TCP_PORT)); |
30 | le_TCP_Port->setText(QString("%1").arg(o_Settings->SERVER.TCP_PORT)); |
31 | le_UDP_Port->setText(QString("%1").arg(o_Settings->SERVER.UDP_PORT)); |
31 | le_UDP_Port->setText(QString("%1").arg(o_Settings->SERVER.UDP_PORT)); |
32 | le_Password->setText(o_Settings->SERVER.Password); |
32 | le_Password->setText(o_Settings->SERVER.Password); |
- | 33 | ||
- | 34 | le_LiveServer->setText(o_Settings->LIVEDATA.Server); |
|
- | 35 | le_LivePort->setText(o_Settings->LIVEDATA.Port); |
|
- | 36 | le_LiveUser->setText(o_Settings->LIVEDATA.User); |
|
- | 37 | le_LivePassword->setText(o_Settings->LIVEDATA.Password); |
|
33 | } |
38 | } |
34 | 39 | ||
35 | cSettings *dlg_Preferences::get_Settings() |
40 | cSettings *dlg_Preferences::get_Settings() |
36 | { |
41 | { |
37 | o_Settings->SERVER.Password = le_Password->text(); |
42 | o_Settings->SERVER.Password = le_Password->text(); |
38 | o_Settings->SERVER.TCP_PORT = le_TCP_Port->text().toInt(); |
43 | o_Settings->SERVER.TCP_PORT = le_TCP_Port->text().toInt(); |
39 | o_Settings->SERVER.UDP_PORT = le_UDP_Port->text().toInt(); |
44 | o_Settings->SERVER.UDP_PORT = le_UDP_Port->text().toInt(); |
- | 45 | ||
- | 46 | o_Settings->LIVEDATA.Server = le_LiveServer->text(); |
|
- | 47 | o_Settings->LIVEDATA.Port = le_LivePort->text(); |
|
- | 48 | o_Settings->LIVEDATA.User = le_LiveUser->text(); |
|
- | 49 | o_Settings->LIVEDATA.Password = le_LivePassword->text(); |
|
40 | 50 | ||
41 | return o_Settings; |
51 | return o_Settings; |
42 | } |
52 | } |
43 | 53 |