-rw-r--r-- | library/tzselect.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/library/tzselect.cpp b/library/tzselect.cpp index f28100b..848dfb7 100644 --- a/library/tzselect.cpp +++ b/library/tzselect.cpp | |||
@@ -64,34 +64,34 @@ TZCombo::TZCombo( QWidget *p, const char* n ) | |||
64 | for ( QStringList::Iterator it=identifiers.begin(); | 64 | for ( QStringList::Iterator it=identifiers.begin(); |
65 | it!=identifiers.end(); ++it) { | 65 | it!=identifiers.end(); ++it) { |
66 | if ( *it == tz ) | 66 | if ( *it == tz ) |
67 | index = n; | 67 | index = n; |
68 | n++; | 68 | n++; |
69 | } | 69 | } |
70 | setCurrentItem(index); | 70 | setCurrentItem(index); |
71 | } else { | 71 | } else { |
72 | setCurrentItem(0); | 72 | setCurrentItem(0); |
73 | } | 73 | } |
74 | 74 | ||
75 | 75 | ||
76 | 76 | ||
77 | // listen on QPE/System | 77 | // listen on QPE/System |
78 | #if !defined(QT_NO_COP) | 78 | #if !defined(QT_NO_COP) |
79 | QCopChannel *channel = new QCopChannel( "QPE/System", this ); | 79 | QCopChannel *channel = new QCopChannel( "QPE/System", this ); |
80 | connect( channel, SIGNAL(received(const QCString&, const QByteArray&)), | 80 | connect( channel, SIGNAL(received(const QCString&,const QByteArray&)), |
81 | this, SLOT(handleSystemChannel(const QCString&, const QByteArray&)) ); | 81 | this, SLOT(handleSystemChannel(const QCString&,const QByteArray&)) ); |
82 | #endif | 82 | #endif |
83 | 83 | ||
84 | 84 | ||
85 | } | 85 | } |
86 | 86 | ||
87 | TZCombo::~TZCombo() | 87 | TZCombo::~TZCombo() |
88 | { | 88 | { |
89 | } | 89 | } |
90 | 90 | ||
91 | void TZCombo::updateZones() | 91 | void TZCombo::updateZones() |
92 | { | 92 | { |
93 | QString cur = currentText(); | 93 | QString cur = currentText(); |
94 | clear(); | 94 | clear(); |
95 | identifiers.clear(); | 95 | identifiers.clear(); |
96 | int curix=0; | 96 | int curix=0; |
97 | QString tz = getenv("TZ"); | 97 | QString tz = getenv("TZ"); |
@@ -205,34 +205,34 @@ void TZCombo::handleSystemChannel(const QCString&msg, const QByteArray&) | |||
205 | populated with the available timezones. | 205 | populated with the available timezones. |
206 | */ | 206 | */ |
207 | 207 | ||
208 | TimeZoneSelector::TimeZoneSelector(QWidget* p, const char* n) : | 208 | TimeZoneSelector::TimeZoneSelector(QWidget* p, const char* n) : |
209 | QHBox(p,n) | 209 | QHBox(p,n) |
210 | { | 210 | { |
211 | d = new TimeZoneSelectorPrivate(); | 211 | d = new TimeZoneSelectorPrivate(); |
212 | // build the combobox before we do any updates... | 212 | // build the combobox before we do any updates... |
213 | cmbTz = new TZCombo( this, "timezone combo" ); | 213 | cmbTz = new TZCombo( this, "timezone combo" ); |
214 | 214 | ||
215 | cmdTz = new QToolButton( this, "timezone button" ); | 215 | cmdTz = new QToolButton( this, "timezone button" ); |
216 | cmdTz->setIconSet( Resource::loadIconSet( "citytime_icon" ) ); | 216 | cmdTz->setIconSet( Resource::loadIconSet( "citytime_icon" ) ); |
217 | cmdTz->setMaximumSize( cmdTz->sizeHint() ); | 217 | cmdTz->setMaximumSize( cmdTz->sizeHint() ); |
218 | 218 | ||
219 | // set up a connection to catch a newly selected item and throw our | 219 | // set up a connection to catch a newly selected item and throw our |
220 | // signal | 220 | // signal |
221 | QObject::connect( cmbTz, SIGNAL( activated( int ) ), | 221 | QObject::connect( cmbTz, SIGNAL( activated(int) ), |
222 | this, SLOT( slotTzActive( int ) ) ); | 222 | this, SLOT( slotTzActive(int) ) ); |
223 | QObject::connect( cmdTz, SIGNAL( clicked() ), | 223 | QObject::connect( cmdTz, SIGNAL( clicked() ), |
224 | this, SLOT( slotExecute() ) ); | 224 | this, SLOT( slotExecute() ) ); |
225 | } | 225 | } |
226 | 226 | ||
227 | /*! | 227 | /*! |
228 | Destroys a TimeZoneSelector. | 228 | Destroys a TimeZoneSelector. |
229 | */ | 229 | */ |
230 | TimeZoneSelector::~TimeZoneSelector() | 230 | TimeZoneSelector::~TimeZoneSelector() |
231 | { | 231 | { |
232 | } | 232 | } |
233 | 233 | ||
234 | void TimeZoneSelector::setLocalIncluded(bool b) | 234 | void TimeZoneSelector::setLocalIncluded(bool b) |
235 | { | 235 | { |
236 | d->includeLocal = b; | 236 | d->includeLocal = b; |
237 | cmbTz->updateZones(); | 237 | cmbTz->updateZones(); |
238 | } | 238 | } |