Diffstat (limited to 'core/settings/citytime/citytime.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | core/settings/citytime/citytime.cpp | 5 |
1 files changed, 0 insertions, 5 deletions
diff --git a/core/settings/citytime/citytime.cpp b/core/settings/citytime/citytime.cpp index b359ae1..e7f0c46 100644 --- a/core/settings/citytime/citytime.cpp +++ b/core/settings/citytime/citytime.cpp | |||
@@ -1,71 +1,66 @@ | |||
1 | /********************************************************************** | 1 | /********************************************************************** |
2 | ** Copyright (C) 2000 Trolltech AS. All rights reserved. | 2 | ** Copyright (C) 2000 Trolltech AS. All rights reserved. |
3 | ** | 3 | ** |
4 | ** This file is part of Qtopia Environment. | 4 | ** This file is part of Qtopia Environment. |
5 | ** | 5 | ** |
6 | ** This file may be distributed and/or modified under the terms of the | 6 | ** This file may be distributed and/or modified under the terms of the |
7 | ** GNU General Public License version 2 as published by the Free Software | 7 | ** GNU General Public License version 2 as published by the Free Software |
8 | ** Foundation and appearing in the file LICENSE.GPL included in the | 8 | ** Foundation and appearing in the file LICENSE.GPL included in the |
9 | ** packaging of this file. | 9 | ** packaging of this file. |
10 | ** | 10 | ** |
11 | ** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE | 11 | ** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE |
12 | ** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. | 12 | ** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. |
13 | ** | 13 | ** |
14 | ** See http://www.trolltech.com/gpl/ for GPL licensing information. | 14 | ** See http://www.trolltech.com/gpl/ for GPL licensing information. |
15 | ** | 15 | ** |
16 | ** Contact info@trolltech.com if any conditions of this licensing are | 16 | ** Contact info@trolltech.com if any conditions of this licensing are |
17 | ** not clear to you. | 17 | ** not clear to you. |
18 | ** | 18 | ** |
19 | **********************************************************************/ | 19 | **********************************************************************/ |
20 | 20 | ||
21 | // changes by Maximilian Reiss <harlekin@handhelds.org> | 21 | // changes by Maximilian Reiss <harlekin@handhelds.org> |
22 | 22 | ||
23 | #include "zonemap.h" | 23 | #include "zonemap.h" |
24 | #include "citytime.h" | 24 | #include "citytime.h" |
25 | 25 | ||
26 | #include <qpe/qpeapplication.h> | 26 | #include <qpe/qpeapplication.h> |
27 | #include <qpe/config.h> | 27 | #include <qpe/config.h> |
28 | #include <qpe/timestring.h> | ||
29 | #include <qpe/tzselect.h> | 28 | #include <qpe/tzselect.h> |
30 | #if !defined(QT_NO_COP) | 29 | #if !defined(QT_NO_COP) |
31 | #include <qpe/qcopenvelope_qws.h> | 30 | #include <qpe/qcopenvelope_qws.h> |
32 | #endif | 31 | #endif |
33 | 32 | ||
34 | #include <qdir.h> | ||
35 | #include <qfile.h> | ||
36 | #include <qlabel.h> | 33 | #include <qlabel.h> |
37 | #include <qmessagebox.h> | 34 | #include <qmessagebox.h> |
38 | #include <qregexp.h> | ||
39 | #include <qtextstream.h> | ||
40 | #include <qtoolbutton.h> | 35 | #include <qtoolbutton.h> |
41 | #include <qlayout.h> | 36 | #include <qlayout.h> |
42 | 37 | ||
43 | #include <stdlib.h> | 38 | #include <stdlib.h> |
44 | 39 | ||
45 | CityTime::CityTime( QWidget *parent, const char* name, | 40 | CityTime::CityTime( QWidget *parent, const char* name, |
46 | WFlags fl ) | 41 | WFlags fl ) |
47 | : CityTimeBase( parent, name, fl ), | 42 | : CityTimeBase( parent, name, fl ), |
48 | strRealTz(0), | 43 | strRealTz(0), |
49 | bAdded(false) | 44 | bAdded(false) |
50 | { | 45 | { |
51 | Config config( "qpe" ); | 46 | Config config( "qpe" ); |
52 | config.setGroup( "Time" ); | 47 | config.setGroup( "Time" ); |
53 | bWhichClock = config.readBoolEntry( "AMPM", TRUE ); | 48 | bWhichClock = config.readBoolEntry( "AMPM", TRUE ); |
54 | qDebug( QString("%1").arg(bWhichClock) ); | 49 | qDebug( QString("%1").arg(bWhichClock) ); |
55 | frmMap->changeClock( bWhichClock ); | 50 | frmMap->changeClock( bWhichClock ); |
56 | 51 | ||
57 | char *pEnv; | 52 | char *pEnv; |
58 | pEnv = NULL; | 53 | pEnv = NULL; |
59 | pEnv = getenv("TZ"); | 54 | pEnv = getenv("TZ"); |
60 | if ( pEnv ) | 55 | if ( pEnv ) |
61 | strRealTz = pEnv; | 56 | strRealTz = pEnv; |
62 | pEnv = NULL; | 57 | pEnv = NULL; |
63 | pEnv = getenv("HOME"); | 58 | pEnv = getenv("HOME"); |
64 | if ( pEnv ) | 59 | if ( pEnv ) |
65 | strHome = pEnv; | 60 | strHome = pEnv; |
66 | // append the labels to their respective lists... | 61 | // append the labels to their respective lists... |
67 | listCities.setAutoDelete( true ); | 62 | listCities.setAutoDelete( true ); |
68 | listTimes.setAutoDelete( true ); | 63 | listTimes.setAutoDelete( true ); |
69 | 64 | ||
70 | listCities.append( cmdCity1 ); | 65 | listCities.append( cmdCity1 ); |
71 | listCities.append( cmdCity2 ); | 66 | listCities.append( cmdCity2 ); |