author | imm <imm> | 2002-09-01 14:34:26 (UTC) |
---|---|---|
committer | imm <imm> | 2002-09-01 14:34:26 (UTC) |
commit | 09c844dbf402d76f58b01397e850bd5c17c0535b (patch) (unidiff) | |
tree | c3f518bb7fd9a241f4b139146d0d2c89b2140b71 /noncore/comm/keypebble | |
parent | 90d1c76275ab950d96cda2a2f65dab1bbcc50a40 (diff) | |
download | opie-09c844dbf402d76f58b01397e850bd5c17c0535b.zip opie-09c844dbf402d76f58b01397e850bd5c17c0535b.tar.gz opie-09c844dbf402d76f58b01397e850bd5c17c0535b.tar.bz2 |
config fix
-rw-r--r-- | noncore/comm/keypebble/krfboptions.cpp | 48 | ||||
-rw-r--r-- | noncore/comm/keypebble/krfboptions.h | 4 | ||||
-rw-r--r-- | noncore/comm/keypebble/kvnc.cpp | 1 | ||||
-rw-r--r-- | noncore/comm/keypebble/kvncoptionsdlg.cpp | 1 | ||||
-rw-r--r-- | noncore/comm/keypebble/main.cpp | 1 |
5 files changed, 29 insertions, 26 deletions
diff --git a/noncore/comm/keypebble/krfboptions.cpp b/noncore/comm/keypebble/krfboptions.cpp index 9daf3f0..8c4320b 100644 --- a/noncore/comm/keypebble/krfboptions.cpp +++ b/noncore/comm/keypebble/krfboptions.cpp | |||
@@ -5,36 +5,40 @@ | |||
5 | KRFBOptions::KRFBOptions() | 5 | KRFBOptions::KRFBOptions() |
6 | { | 6 | { |
7 | Config config( "keypebble" ); | 7 | readSettings(); |
8 | readSettings( &config ); | ||
9 | } | 8 | } |
10 | 9 | ||
11 | KRFBOptions::~KRFBOptions() | 10 | KRFBOptions::~KRFBOptions() |
12 | { | 11 | { |
13 | Config config( "keypebble" ); | 12 | writeSettings(); |
14 | writeSettings( &config ); | ||
15 | } | 13 | } |
16 | 14 | ||
17 | void KRFBOptions::readSettings( Config *config ) | 15 | void KRFBOptions::readSettings() |
18 | { | 16 | { |
19 | hexTile = config->readBoolEntry( "HexTile" ); | 17 | Config config( "keypebble" ); |
20 | corre = config->readBoolEntry( "CORRE" ); | 18 | config.setGroup("Settings"); |
21 | rre = config->readBoolEntry( "RRE" ); | 19 | hexTile = config.readBoolEntry( "HexTile", 0 ); |
22 | copyrect = config->readBoolEntry( "CopyRect", true ); | 20 | corre = config.readBoolEntry( "CORRE", 0 ); |
23 | colors256 = config->readBoolEntry( "Colors256" ); | 21 | rre = config.readBoolEntry( "RRE", 0 ); |
24 | shared = config->readBoolEntry( "Shared" ); | 22 | copyrect = config.readBoolEntry( "CopyRect", 1 ); |
25 | readOnly = config->readBoolEntry( "ReadOnly" ); | 23 | colors256 = config.readBoolEntry( "Colors256", 0 ); |
26 | updateRate = config->readNumEntry( "UpdateRate", 50 ); | 24 | shared = config.readBoolEntry( "Shared", 0 ); |
25 | readOnly = config.readBoolEntry( "ReadOnly", 0 ); | ||
26 | updateRate = config.readNumEntry( "UpdateRate", 50 ); | ||
27 | deIconify = config.readBoolEntry( "DeIconify", 0 ); | ||
27 | } | 28 | } |
28 | 29 | ||
29 | void KRFBOptions::writeSettings( Config *config ) | 30 | void KRFBOptions::writeSettings() |
30 | { | 31 | { |
31 | config->writeEntry( "HexTile", hexTile ); | 32 | Config config( "keypebble" ); |
32 | config->writeEntry( "CORRE", corre ); | 33 | config.setGroup("Settings"); |
33 | config->writeEntry( "RRE", rre ); | 34 | config.writeEntry( "HexTile", hexTile ); |
34 | config->writeEntry( "CopyRect", copyrect ); | 35 | config.writeEntry( "CORRE", corre ); |
35 | config->writeEntry( "Colors256", colors256 ); | 36 | config.writeEntry( "RRE", rre ); |
36 | config->writeEntry( "Shared", shared ); | 37 | config.writeEntry( "CopyRect", copyrect ); |
37 | config->writeEntry( "ReadOnly", readOnly ); | 38 | config.writeEntry( "Colors256", colors256 ); |
38 | config->writeEntry( "UpdateRate", updateRate ); | 39 | config.writeEntry( "Shared", shared ); |
40 | config.writeEntry( "ReadOnly", readOnly ); | ||
41 | config.writeEntry( "UpdateRate", updateRate ); | ||
42 | config.writeEntry( "DeIconify", deIconify ); | ||
39 | } | 43 | } |
40 | 44 | ||
diff --git a/noncore/comm/keypebble/krfboptions.h b/noncore/comm/keypebble/krfboptions.h index 41cea35..fd2b65c 100644 --- a/noncore/comm/keypebble/krfboptions.h +++ b/noncore/comm/keypebble/krfboptions.h | |||
@@ -13,6 +13,6 @@ public: | |||
13 | 13 | ||
14 | int encodings(); | 14 | int encodings(); |
15 | void readSettings( Config *config ); | 15 | void readSettings(); |
16 | void writeSettings( Config *config ); | 16 | void writeSettings(); |
17 | 17 | ||
18 | bool hexTile; | 18 | bool hexTile; |
diff --git a/noncore/comm/keypebble/kvnc.cpp b/noncore/comm/keypebble/kvnc.cpp index bb18999..43cffc5 100644 --- a/noncore/comm/keypebble/kvnc.cpp +++ b/noncore/comm/keypebble/kvnc.cpp | |||
@@ -72,5 +72,4 @@ KVNC::KVNC( const char *name ) : QMainWindow( 0, name ) | |||
72 | KVNC::~KVNC() | 72 | KVNC::~KVNC() |
73 | { | 73 | { |
74 | |||
75 | } | 74 | } |
76 | 75 | ||
diff --git a/noncore/comm/keypebble/kvncoptionsdlg.cpp b/noncore/comm/keypebble/kvncoptionsdlg.cpp index b9f57d1..9d61c7b 100644 --- a/noncore/comm/keypebble/kvncoptionsdlg.cpp +++ b/noncore/comm/keypebble/kvncoptionsdlg.cpp | |||
@@ -48,4 +48,5 @@ void KVNCOptionsDlg::accept() | |||
48 | options->shared = shared->isChecked(); | 48 | options->shared = shared->isChecked(); |
49 | options->updateRate = timeBox->value(); | 49 | options->updateRate = timeBox->value(); |
50 | options->writeSettings(); | ||
50 | 51 | ||
51 | QDialog::accept(); | 52 | QDialog::accept(); |
diff --git a/noncore/comm/keypebble/main.cpp b/noncore/comm/keypebble/main.cpp index a32a368..ee3cd79 100644 --- a/noncore/comm/keypebble/main.cpp +++ b/noncore/comm/keypebble/main.cpp | |||
@@ -16,3 +16,2 @@ int main( int argc, char **argv ) | |||
16 | return app.exec(); | 16 | return app.exec(); |
17 | } | 17 | } |
18 | |||