[Kst] extragear/graphics/kst/kst
George Staikos
staikos at kde.org
Thu Nov 17 17:27:15 CET 2005
SVN commit 481040 by staikos:
add a timezone changed signal
M +4 -0 kst.cpp
M +3 -0 kst.h
M +1 -0 kstsettingsdlg.ui
M +6 -1 kstsettingsdlg.ui.h
--- trunk/extragear/graphics/kst/kst/kst.cpp #481039:481040
@@ -2555,5 +2555,9 @@
}
+void KstApp::emitTimezoneChanged(const QString& tz, int utcOffset) {
+ emit timezoneChanged(tz, utcOffset);
+}
+
#include "kst.moc"
// vim: ts=2 sw=2 et
--- trunk/extragear/graphics/kst/kst/kst.h #481039:481040
@@ -377,7 +377,10 @@
void createDebugNotifier();
void destroyDebugNotifier();
+ void emitTimezoneChanged(const QString& tz, int utcOffset);
+
signals:
+ void timezoneChanged(const QString& tz, int utcOffset);
void settingsChanged();
void ELOGConfigure();
void ELOGSubmitEntry(const QString& strMessage);
--- trunk/extragear/graphics/kst/kst/kstsettingsdlg.ui #481039:481040
@@ -1254,6 +1254,7 @@
<include location="local" impldecl="in implementation">kstdatasource.h</include>
<include location="local" impldecl="in declaration">kstplotdefines.h</include>
<include location="local" impldecl="in declaration">ktimezonecombo.h</include>
+ <include location="local" impldecl="in implementation">kst.h</include>
<include location="local" impldecl="in implementation">kstsettingsdlg.ui.h</include>
</includes>
<signals>
--- trunk/extragear/graphics/kst/kst/kstsettingsdlg.ui.h #481039:481040
@@ -133,7 +133,9 @@
s.emailSMTPPort = _kIntSpinBoxEMailPort->value();
s.emailRequiresAuthentication = _checkBoxAuthentication->isChecked();
- s.timezone = _tz->tzName();
+ QString tzName = _tz->tzName();
+ bool emitTZChanged = tzName != KstSettings::globalSettings()->timezone;
+ s.timezone = tzName;
int value = _buttonGroupEncryption->id(_buttonGroupEncryption->selected());
if (value >= 0 && value < EMailEncryptionMAXIMUM) {
@@ -152,6 +154,9 @@
KstSettings::setGlobalSettings(&s);
KstSettings::globalSettings()->save();
emit settingsChanged();
+ if (emitTZChanged) {
+ KstApp::inst()->emitTimezoneChanged(tzName, s.utcOffset());
+ }
}
More information about the Kst
mailing list