summaryrefslogtreecommitdiff
path: root/library/tzselect.h
Unidiff
Diffstat (limited to 'library/tzselect.h') (more/less context) (show whitespace changes)
-rw-r--r--library/tzselect.h14
1 files changed, 12 insertions, 2 deletions
diff --git a/library/tzselect.h b/library/tzselect.h
index 9898d84..55e45a3 100644
--- a/library/tzselect.h
+++ b/library/tzselect.h
@@ -1,74 +1,84 @@
1/********************************************************************** 1/**********************************************************************
2** Copyright (C) 2000 Trolltech AS. All rights reserved. 2** Copyright (C) 2000-2002 Trolltech AS. All rights reserved.
3** 3**
4** This file is part of Qtopia Environment. 4** This file is part of the 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#ifndef TZSELECT_H 20#ifndef TZSELECT_H
21#define TZSELECT_H 21#define TZSELECT_H
22 22
23#include <qhbox.h> 23#include <qhbox.h>
24#include <qcombobox.h> 24#include <qcombobox.h>
25#include <qstringlist.h> 25#include <qstringlist.h>
26 26
27class QToolButton; 27class QToolButton;
28class TimeZoneSelector;
28 29
29// a function to load defaults in case there is no file 30// a function to load defaults in case there is no file
30QStringList timezoneDefaults( void ); 31QStringList timezoneDefaults( void );
31 32
32class TZCombo : public QComboBox 33class TZCombo : public QComboBox
33{ 34{
34 Q_OBJECT 35 Q_OBJECT
35public: 36public:
36 TZCombo( QWidget* parent, const char* name = 0 ); 37 TZCombo( QWidget* parent, const char* name = 0 );
37 ~TZCombo(); 38 ~TZCombo();
38 39
39 QString currZone() const; 40 QString currZone() const;
40 void setCurrZone( const QString& id ); 41 void setCurrZone( const QString& id );
41 42
42protected: 43protected:
44 friend class TimeZoneSelector;
43 void keyPressEvent( QKeyEvent *e ); 45 void keyPressEvent( QKeyEvent *e );
44 void mousePressEvent(QMouseEvent*e); 46 void mousePressEvent(QMouseEvent*e);
45 void updateZones(); 47 void updateZones();
46 48
47private slots: 49private slots:
48 void handleSystemChannel(const QCString&, const QByteArray&); 50 void handleSystemChannel(const QCString&, const QByteArray&);
49 51
50private: 52private:
51 QStringList identifiers; 53 QStringList identifiers;
52 QStringList extras; 54 QStringList extras;
53}; 55};
54 56
55class TimeZoneSelectorPrivate; 57class TimeZoneSelectorPrivate;
56class TimeZoneSelector : public QHBox 58class TimeZoneSelector : public QHBox
57{ 59{
58 Q_OBJECT 60 Q_OBJECT
59public: 61public:
60 TimeZoneSelector( QWidget* parent = 0, const char* name=0 ); 62 TimeZoneSelector( QWidget* parent = 0, const char* name=0 );
61 ~TimeZoneSelector(); 63 ~TimeZoneSelector();
62 64
65#ifdef QTOPIA_INTERNAL_TZSELECT_INC_LOCAL
66 // badly named.. not to be used outside of qtopia (not forward compatable)
67 // basically allows the "No Timezone" or "None" option.
68 void setLocalIncluded(bool);
69 bool localIncluded() const;
70#endif
71
72
63 QString currentZone() const; 73 QString currentZone() const;
64 void setCurrentZone( const QString& id ); 74 void setCurrentZone( const QString& id );
65 75
66signals: 76signals:
67 void signalNewTz( const QString& id ); 77 void signalNewTz( const QString& id );
68 78
69private slots: 79private slots:
70 void slotTzActive( int index ); 80 void slotTzActive( int index );
71 void slotExecute( void ); 81 void slotExecute( void );
72 82
73private: 83private:
74 TZCombo *cmbTz; 84 TZCombo *cmbTz;