-rw-r--r-- | ChangeLog | 1 | ||||
-rw-r--r-- | noncore/settings/netsystemtime/mainwindow.cpp | 16 |
2 files changed, 14 insertions, 3 deletions
@@ -1,315 +1,316 @@ | |||
1 | 2005-??-??Opie 1.2.1 | 1 | 2005-??-??Opie 1.2.1 |
2 | 2 | ||
3 | 3 | ||
4 | New Features | 4 | New Features |
5 | ------------ | 5 | ------------ |
6 | * OpieStumbler: Scans WiFi networks using the wireless extension scanning (skyhusker) | 6 | * OpieStumbler: Scans WiFi networks using the wireless extension scanning (skyhusker) |
7 | * Opie-Reader: Support for document formats ArriereGo and Reb, add flite output (tim,pohly) | 7 | * Opie-Reader: Support for document formats ArriereGo and Reb, add flite output (tim,pohly) |
8 | * Opie-Networksettings: Add support for wlan-ng devices and improve WEP handling (Dirk Opfer) | 8 | * Opie-Networksettings: Add support for wlan-ng devices and improve WEP handling (Dirk Opfer) |
9 | * Wellenreiter: Remove Joining networks - use OpieStumbler for that (mickeyl) | 9 | * Wellenreiter: Remove Joining networks - use OpieStumbler for that (mickeyl) |
10 | * Opie-Mobilemsg has gone unsupported - it never really worked and there will be a replacement (mickeyl) | 10 | * Opie-Mobilemsg has gone unsupported - it never really worked and there will be a replacement (mickeyl) |
11 | * Opie-Tabmanager has gone unsupported - it barely works and there is not much of a use of it anyway (mickeyl) | 11 | * Opie-Tabmanager has gone unsupported - it barely works and there is not much of a use of it anyway (mickeyl) |
12 | * Checkbook: Added configuration option to use smaller font for checkbook transaction tab (hrw) | 12 | * Checkbook: Added configuration option to use smaller font for checkbook transaction tab (hrw) |
13 | * ZSafe: Made UI conform to Opie standards (drw) | 13 | * ZSafe: Made UI conform to Opie standards (drw) |
14 | * Today Addressbook plugin: Fixed configuration to show/not show birthdays, use checkboxes for selection (hrw) | 14 | * Today Addressbook plugin: Fixed configuration to show/not show birthdays, use checkboxes for selection (hrw) |
15 | * Opie-Console: Read initial fixed font configuration from qpe.conf (mickeyl) | 15 | * Opie-Console: Read initial fixed font configuration from qpe.conf (mickeyl) |
16 | * Opie-PcmciaApplet: Configure insert/resume actions and bind unsupported cards (mickeyl) | 16 | * Opie-PcmciaApplet: Configure insert/resume actions and bind unsupported cards (mickeyl) |
17 | * SysInfo: Remove CPU tab and add Devices tab instead (mickeyl) | 17 | * SysInfo: Remove CPU tab and add Devices tab instead (mickeyl) |
18 | 18 | ||
19 | Fixed Bugs | 19 | Fixed Bugs |
20 | ---------- | 20 | ---------- |
21 | * #1377 - Suspend Powermanagement when switched to another VT (mickeyl) | 21 | * #1377 - Suspend Powermanagement when switched to another VT (mickeyl) |
22 | - We actually suspend the complete Opie now in that case. | 22 | - We actually suspend the complete Opie now in that case. |
23 | * #1384 - Battery status updated improperly when charging (skyhusker) | 23 | * #1384 - Battery status updated improperly when charging (skyhusker) |
24 | * #1476 - Wrong order of application entries in the O-menu (skyhusker) | 24 | * #1476 - Wrong order of application entries in the O-menu (skyhusker) |
25 | * #1514 - Remove usage of cardmon/pcmcia picture in applications. pcmcia is now an inline picture (mickeyl) | 25 | * #1514 - Remove usage of cardmon/pcmcia picture in applications. pcmcia is now an inline picture (mickeyl) |
26 | * #1535- Missing line break and unnecessary location shown with Today-Calendar plugin (deller) | 26 | * #1535- Missing line break and unnecessary location shown with Today-Calendar plugin (deller) |
27 | * #1543 - Time Settings: "predict" tab is displayed twice after reopen (hrw) | ||
27 | * #1546 - Battery applet popup is not always large enough to show jacket remaining info (skyhusker) | 28 | * #1546 - Battery applet popup is not always large enough to show jacket remaining info (skyhusker) |
28 | * #1557 - Light&Power-Settings don't store warning intervall and warning levels (skyhusker) | 29 | * #1557 - Light&Power-Settings don't store warning intervall and warning levels (skyhusker) |
29 | * #1565 - crash-fix in odevice.cpp while scanning the distribution table (deller) | 30 | * #1565 - crash-fix in odevice.cpp while scanning the distribution table (deller) |
30 | * #1614 - Make Opie-console start in $HOME instead of / (skyhusker) | 31 | * #1614 - Make Opie-console start in $HOME instead of / (skyhusker) |
31 | * #1635 - opie-today, datebook-plugin does not show notes (skyhusker) | 32 | * #1635 - opie-today, datebook-plugin does not show notes (skyhusker) |
32 | * #1665 - Opie-IRC displays the host prepended to the message when peer is using and ipv6 address (skyhusker) | 33 | * #1665 - Opie-IRC displays the host prepended to the message when peer is using and ipv6 address (skyhusker) |
33 | * #1666 - Opie-IRC does not allow to add !channels in config asautojoin ones (skyhusker) | 34 | * #1666 - Opie-IRC does not allow to add !channels in config asautojoin ones (skyhusker) |
34 | * #1667 - Opie-IRC does not show messages from !channel (skyhusker) | 35 | * #1667 - Opie-IRC does not show messages from !channel (skyhusker) |
35 | * #1679 - Security PIN plugin is QVGA sized (hrw) | 36 | * #1679 - Security PIN plugin is QVGA sized (hrw) |
36 | * n.a.- always show volume and wireless applet popups inside visible screen (deller) | 37 | * n.a.- always show volume and wireless applet popups inside visible screen (deller) |
37 | * n.a. - scale O-Menu-Applets appropriately (mickeyl) | 38 | * n.a. - scale O-Menu-Applets appropriately (mickeyl) |
38 | * n.a.- libopienet: fix bugs in wireless scanning and setting SSID (skyhusker) | 39 | * n.a.- libopienet: fix bugs in wireless scanning and setting SSID (skyhusker) |
39 | * n.a.- Wellenreiter: relax WE version matching test a bit (mickeyl) | 40 | * n.a.- Wellenreiter: relax WE version matching test a bit (mickeyl) |
40 | * n.a.- scale BluezApplet appropriately and use larger icons (mickeyl) | 41 | * n.a.- scale BluezApplet appropriately and use larger icons (mickeyl) |
41 | * n.a.- memoryapplet: fix crash in memoryapplet on kernels without swap support (seneca cunningham) | 42 | * n.a.- memoryapplet: fix crash in memoryapplet on kernels without swap support (seneca cunningham) |
42 | * n.a. - networksettings: ignore hostap control interfaces wifi* (mickeyl) | 43 | * n.a. - networksettings: ignore hostap control interfaces wifi* (mickeyl) |
43 | * n.a. - Today Addressbook plugin fix configuration to show/not show birthdays, use checkboxes for selection (hrw) | 44 | * n.a. - Today Addressbook plugin fix configuration to show/not show birthdays, use checkboxes for selection (hrw) |
44 | * n.a. - remove hardcoded font size from netsystemtime (hrw) | 45 | * n.a. - remove hardcoded font size from netsystemtime (hrw) |
45 | * n.a. - remove hardcoded font size from checkbook graphs (hrw) | 46 | * n.a. - remove hardcoded font size from checkbook graphs (hrw) |
46 | 47 | ||
47 | Internal | 48 | Internal |
48 | -------- | 49 | -------- |
49 | * Make BluezApplet use OTaskbarApplet (mickeyl) | 50 | * Make BluezApplet use OTaskbarApplet (mickeyl) |
50 | * libopiecore: rewrite OFileNotification to use the Linux 2.6 inotify interface (mickeyl) | 51 | * libopiecore: rewrite OFileNotification to use the Linux 2.6 inotify interface (mickeyl) |
51 | * libopiecore: add ODirNotification - recursive directory notifications (mickeyl) | 52 | * libopiecore: add ODirNotification - recursive directory notifications (mickeyl) |
52 | * libopienet: Skip hostap control interfaces 'wifi' and improve robustness in ONetworkInterface (mickeyl) | 53 | * libopienet: Skip hostap control interfaces 'wifi' and improve robustness in ONetworkInterface (mickeyl) |
53 | * libopieui: Remove OVersatileView and OVersatileViewItem (mickeyl) | 54 | * libopieui: Remove OVersatileView and OVersatileViewItem (mickeyl) |
54 | * libopienet: Miscellaneous API cleanups (mickeyl) | 55 | * libopienet: Miscellaneous API cleanups (mickeyl) |
55 | * libopiecore: Add linux pcmcia system abstraction classes (mickeyl) | 56 | * libopiecore: Add linux pcmcia system abstraction classes (mickeyl) |
56 | * libopiecore: ODevice now knows the default gfx driver to use (mteira,mickeyl) | 57 | * libopiecore: ODevice now knows the default gfx driver to use (mteira,mickeyl) |
57 | * Remove assumptions about default gfx driver ("Transformed") all over the place (mteira,mickeyl) | 58 | * Remove assumptions about default gfx driver ("Transformed") all over the place (mteira,mickeyl) |
58 | 59 | ||
59 | 2005-03-25Opie 1.2.0 | 60 | 2005-03-25Opie 1.2.0 |
60 | 61 | ||
61 | Fixed Bugs | 62 | Fixed Bugs |
62 | ---------- | 63 | ---------- |
63 | * #1613 - AdvancedFM - scale toolbar icons appropriately (drw) | 64 | * #1613 - AdvancedFM - scale toolbar icons appropriately (drw) |
64 | * #1620 - OFileSelector - show the button on press and not on press on hold (alwin) | 65 | * #1620 - OFileSelector - show the button on press and not on press on hold (alwin) |
65 | * #1473 - Opie-Eye - Same as #1620 but we lack a common FileSystem Button class (zecke) | 66 | * #1473 - Opie-Eye - Same as #1620 but we lack a common FileSystem Button class (zecke) |
66 | * n.a. - PackageManager - fix bug where messages show up multiple times in install dialog (drw) | 67 | * n.a. - PackageManager - fix bug where messages show up multiple times in install dialog (drw) |
67 | * n.a.- make qpeglobal.h include qglobal.h (zecke) | 68 | * n.a.- make qpeglobal.h include qglobal.h (zecke) |
68 | 69 | ||
69 | 2005-03-20Opie 1.2.0-rc1 | 70 | 2005-03-20Opie 1.2.0-rc1 |
70 | 71 | ||
71 | 72 | ||
72 | New Features | 73 | New Features |
73 | ------------ | 74 | ------------ |
74 | * Launcher: Support a static background pixmap (mickeyl) | 75 | * Launcher: Support a static background pixmap (mickeyl) |
75 | * LauncherSettings: Choose whether to have a static background pixmap (mickeyl) | 76 | * LauncherSettings: Choose whether to have a static background pixmap (mickeyl) |
76 | * PackageManager supports the 'lists_dir' ipkg configuration option (drw) | 77 | * PackageManager supports the 'lists_dir' ipkg configuration option (drw) |
77 | * Added hi-res inline images for large resolution devices (drw) | 78 | * Added hi-res inline images for large resolution devices (drw) |
78 | * Improved launcher icons for consistency (ar) | 79 | * Improved launcher icons for consistency (ar) |
79 | * Datebook: Added plugin system to datebook so holidays and birthdays from contacts may displayed in datebook (alwin) | 80 | * Datebook: Added plugin system to datebook so holidays and birthdays from contacts may displayed in datebook (alwin) |
80 | 81 | ||
81 | Fixed Bugs | 82 | Fixed Bugs |
82 | ---------- | 83 | ---------- |
83 | * #1236 - VCards contained empty home and work address entries causing Palms to crash (eilers) | 84 | * #1236 - VCards contained empty home and work address entries causing Palms to crash (eilers) |
84 | * #1412 - Launcher Settings - fixed default settings for background in Edit tab dialog (drw) | 85 | * #1412 - Launcher Settings - fixed default settings for background in Edit tab dialog (drw) |
85 | * #1472 - Opie textedit now check for unsaved changes on ESC key (ljp) | 86 | * #1472 - Opie textedit now check for unsaved changes on ESC key (ljp) |
86 | * #1474 - Implement GUI for Scrollbars on the Left in Appearance (zecke) | 87 | * #1474 - Implement GUI for Scrollbars on the Left in Appearance (zecke) |
87 | * #1482 - Fix double '/' in paths (zecke) | 88 | * #1482 - Fix double '/' in paths (zecke) |
88 | * #1536 - Autosave of custom locations in opie backup (ar) | 89 | * #1536 - Autosave of custom locations in opie backup (ar) |
89 | * #1539 - Fixed displaying too long path in the delete dialog in opie-eye (zecke) | 90 | * #1539 - Fixed displaying too long path in the delete dialog in opie-eye (zecke) |
90 | * #1540 - Implemented deletion of DocLnks in opie-eye (zecke) | 91 | * #1540 - Implemented deletion of DocLnks in opie-eye (zecke) |
91 | * #1542 - Fixed Todo crash when priority < 1 or > 5 (drw) | 92 | * #1542 - Fixed Todo crash when priority < 1 or > 5 (drw) |
92 | * #1550 - Browse for alarm sound start in QPEDIR/sounds/ (zecke) | 93 | * #1550 - Browse for alarm sound start in QPEDIR/sounds/ (zecke) |
93 | * #1554 - Fixed Opie-Console name in .desktop file (mickeyl) | 94 | * #1554 - Fixed Opie-Console name in .desktop file (mickeyl) |
94 | * #1556 - Start to look for sound files in /opt/QtPalmtop/sounds (zecke) | 95 | * #1556 - Start to look for sound files in /opt/QtPalmtop/sounds (zecke) |
95 | * #1558 - Fixed opie-login breaking opie startup (mickeyl) | 96 | * #1558 - Fixed opie-login breaking opie startup (mickeyl) |
96 | * #1560 - Fixed Opie-Console picking up the wrong shell (bluelightning) | 97 | * #1560 - Fixed Opie-Console picking up the wrong shell (bluelightning) |
97 | * #1570 - Confirmation needed befor Restore a backup and overwrite local data (ar) | 98 | * #1570 - Confirmation needed befor Restore a backup and overwrite local data (ar) |
98 | * #1591 - Addressbook sortorder changed by clicking on column 0 (eilers) | 99 | * #1591 - Addressbook sortorder changed by clicking on column 0 (eilers) |
99 | * #1599 - Security - change recommendation for opie-multiauth to opie-securityplugin (gints) | 100 | * #1599 - Security - change recommendation for opie-multiauth to opie-securityplugin (gints) |
100 | * #1604 - Checkbook crashed on startup (drw) | 101 | * #1604 - Checkbook crashed on startup (drw) |
101 | * #1608 - Addressbook crashed after search, which may caused by not initialzed member variable (eilers) | 102 | * #1608 - Addressbook crashed after search, which may caused by not initialzed member variable (eilers) |
102 | * #1608 - QueryByExampe-Datediff on SQL database did not worked properly (eilers) | 103 | * #1608 - QueryByExampe-Datediff on SQL database did not worked properly (eilers) |
103 | * n.a. - Netsystemtime - fixed UI to prevent error dialog from displaying when it shouldn't, get rid of some compiler warnings (drw) | 104 | * n.a. - Netsystemtime - fixed UI to prevent error dialog from displaying when it shouldn't, get rid of some compiler warnings (drw) |
104 | * n.a. - PackageManager - fixed where last package in status file was not shown as installed when it should be (drw) | 105 | * n.a. - PackageManager - fixed where last package in status file was not shown as installed when it should be (drw) |
105 | * n.a. - PackageManager - fixed bug where lists_dir was not being honored at startup (drw) | 106 | * n.a. - PackageManager - fixed bug where lists_dir was not being honored at startup (drw) |
106 | * n.a. - PackageManager - provided default value for lists_dir when none is entered in configuration dialog (drw) | 107 | * n.a. - PackageManager - provided default value for lists_dir when none is entered in configuration dialog (drw) |
107 | * n.a. - OTabWidget - fixed scroll buttons, fix display position of tabs (drw) | 108 | * n.a. - OTabWidget - fixed scroll buttons, fix display position of tabs (drw) |
108 | * n.a. - AddressBook - fixed sorting by 'File As' name (drw) | 109 | * n.a. - AddressBook - fixed sorting by 'File As' name (drw) |
109 | * n.a. - AddressBook - fixed category handling for 'All' and 'Unfiled' (eilers) | 110 | * n.a. - AddressBook - fixed category handling for 'All' and 'Unfiled' (eilers) |
110 | * n.a. - AddressBook - fixed letter picker record selection and sort records afterwards (drw) | 111 | * n.a. - AddressBook - fixed letter picker record selection and sort records afterwards (drw) |
111 | 112 | ||
112 | Internal | 113 | Internal |
113 | -------- | 114 | -------- |
114 | * Worked around bug in Qt/Embedded 2.3.10: qt_version() returns 231 (mickeyl) | 115 | * Worked around bug in Qt/Embedded 2.3.10: qt_version() returns 231 (mickeyl) |
115 | * Killed the need for weak symbols in QtE (zecke) | 116 | * Killed the need for weak symbols in QtE (zecke) |
116 | * Added optional building libqpe without inline images (mickeyl) | 117 | * Added optional building libqpe without inline images (mickeyl) |
117 | * OColorButton - fixed so does not emit a colorSelected signal inside of resizeEvent (drw) | 118 | * OColorButton - fixed so does not emit a colorSelected signal inside of resizeEvent (drw) |
118 | 119 | ||
119 | 2005-02-03Opie 1.1.9 | 120 | 2005-02-03Opie 1.1.9 |
120 | 121 | ||
121 | New Features | 122 | New Features |
122 | ------------ | 123 | ------------ |
123 | * Number of icon columns in Launcher is customizable through Launcher.conf (hrw,zecke,mickeyl) | 124 | * Number of icon columns in Launcher is customizable through Launcher.conf (hrw,zecke,mickeyl) |
124 | * Number of icon columns in Launcher is customizable through LauncherSettings (mickeyl) | 125 | * Number of icon columns in Launcher is customizable through LauncherSettings (mickeyl) |
125 | * Usability enhancements in OpieIRC (skyhusker) | 126 | * Usability enhancements in OpieIRC (skyhusker) |
126 | 127 | ||
127 | Fixed Bugs | 128 | Fixed Bugs |
128 | ---------- | 129 | ---------- |
129 | * #1501 - Fixed bug in todo sql backend (eilers) | 130 | * #1501 - Fixed bug in todo sql backend (eilers) |
130 | * #1505 - Added more Swap sizes in memoryapplet (mickeyl) | 131 | * #1505 - Added more Swap sizes in memoryapplet (mickeyl) |
131 | * #1525 - Hopefully fixed double alarms and not removing alarms set with the Clock application (zecke) | 132 | * #1525 - Hopefully fixed double alarms and not removing alarms set with the Clock application (zecke) |
132 | * #1533 - Security Owner Dialog (shown in case of unsuccessfull authentiacation) wasn't able to display information in non latin1 encoding (zecke) | 133 | * #1533 - Security Owner Dialog (shown in case of unsuccessfull authentiacation) wasn't able to display information in non latin1 encoding (zecke) |
133 | * n.a. - Removed hard coded font sizes in a couple of inputmethods (mickeyl) | 134 | * n.a. - Removed hard coded font sizes in a couple of inputmethods (mickeyl) |
134 | * n.a. - Removed MediumDlg appearing prior to FirstUsage wizard (i.e. calibration) (mickeyl) | 135 | * n.a. - Removed MediumDlg appearing prior to FirstUsage wizard (i.e. calibration) (mickeyl) |
135 | * n.a. - Fixed numerous buglets in OpieIRC (skyhusker) | 136 | * n.a. - Fixed numerous buglets in OpieIRC (skyhusker) |
136 | 137 | ||
137 | Internal | 138 | Internal |
138 | -------- | 139 | -------- |
139 | * Added the Qtopia 1.7 SDK macros for quick-apps to easa compilation of 3rd party apps against our headers (mickeyl) | 140 | * Added the Qtopia 1.7 SDK macros for quick-apps to easa compilation of 3rd party apps against our headers (mickeyl) |
140 | * You can now use the Opie build system in combination with a OpenEmbedded staging area which makes a nice cross development environment (mickeyl) | 141 | * You can now use the Opie build system in combination with a OpenEmbedded staging area which makes a nice cross development environment (mickeyl) |
141 | * Made Opie compilable with Qt/Embedded 2.3.10 (ar) | 142 | * Made Opie compilable with Qt/Embedded 2.3.10 (ar) |
142 | * Changed Launcher to get default orientation from ODevice w/ QWS_DISPLAY overriding (mickeyl) | 143 | * Changed Launcher to get default orientation from ODevice w/ QWS_DISPLAY overriding (mickeyl) |
143 | * Build tree cleanups (mickeyl) | 144 | * Build tree cleanups (mickeyl) |
144 | 145 | ||
145 | 2004-11-26Opie 1.1.8 | 146 | 2004-11-26Opie 1.1.8 |
146 | 147 | ||
147 | New Features | 148 | New Features |
148 | ------------ | 149 | ------------ |
149 | * PackageManager supports installation of local ipkg files (drw) | 150 | * PackageManager supports installation of local ipkg files (drw) |
150 | * PackageManager supports linking of applications to root (drw) | 151 | * PackageManager supports linking of applications to root (drw) |
151 | * PackageManager supports src/gz feeds (drw,wimpie) | 152 | * PackageManager supports src/gz feeds (drw,wimpie) |
152 | * Added a syslog information tab to sysinfo (mickeyl) | 153 | * Added a syslog information tab to sysinfo (mickeyl) |
153 | * Added new, more consistent, PIM icons + a GIMP teplate (ar) | 154 | * Added new, more consistent, PIM icons + a GIMP teplate (ar) |
154 | 155 | ||
155 | Fixed Bugs | 156 | Fixed Bugs |
156 | ---------- | 157 | ---------- |
157 | * #1017 - Tetrix doesn't display correctly for high resolution screens (drw) | 158 | * #1017 - Tetrix doesn't display correctly for high resolution screens (drw) |
158 | * #1269 - VCards were imported into personal area if it was activated (eilers) | 159 | * #1269 - VCards were imported into personal area if it was activated (eilers) |
159 | * #1464 - Packagemanager dont set active filter after install a package (drw) | 160 | * #1464 - Packagemanager dont set active filter after install a package (drw) |
160 | * #1479 - Improved VCard-Parser to import VCards created by Evolution 2 and Apple Addressbook (eilers) | 161 | * #1479 - Improved VCard-Parser to import VCards created by Evolution 2 and Apple Addressbook (eilers) |
161 | * #1493 - Fixed one column layout bug of the launcher (hrw) | 162 | * #1493 - Fixed one column layout bug of the launcher (hrw) |
162 | * n.a. - PackageManager - (Minor UI tweak) in filter dialog, when option is enabled, set focus to widget that corresponds to that option (drw) | 163 | * n.a. - PackageManager - (Minor UI tweak) in filter dialog, when option is enabled, set focus to widget that corresponds to that option (drw) |
163 | * n.a. - PackageManager - (Minor UI tweak) fix double entry in source feed configuration when adding a new feed (drw) | 164 | * n.a. - PackageManager - (Minor UI tweak) fix double entry in source feed configuration when adding a new feed (drw) |
164 | * n.a. - Battery Applet - fix sizing of battery info popup (drw,mickeyl) | 165 | * n.a. - Battery Applet - fix sizing of battery info popup (drw,mickeyl) |
165 | 166 | ||
166 | Internal | 167 | Internal |
167 | -------- | 168 | -------- |
168 | * Moved libopie1 to unsupported (mickeyl) | 169 | * Moved libopie1 to unsupported (mickeyl) |
169 | * Implemented generic queryByExample() with incremental searching. A lot of internal changes of the Pim2-library (eilers) | 170 | * Implemented generic queryByExample() with incremental searching. A lot of internal changes of the Pim2-library (eilers) |
170 | * Added fast and full featured and incremental sorted() for SQL addressbook backend (eilers) | 171 | * Added fast and full featured and incremental sorted() for SQL addressbook backend (eilers) |
171 | 172 | ||
172 | 2004-11-14Opie 1.1.7 | 173 | 2004-11-14Opie 1.1.7 |
173 | 174 | ||
174 | New Features | 175 | New Features |
175 | ------------ | 176 | ------------ |
176 | * libOpieDB now uses SQLite V3 instead V2. Remember to upgrade your database files! (eilers) | 177 | * libOpieDB now uses SQLite V3 instead V2. Remember to upgrade your database files! (eilers) |
177 | * Backup now uses the busy indicator when backing up and restore (ar) | 178 | * Backup now uses the busy indicator when backing up and restore (ar) |
178 | * OpiePlayer2 gained adding of Directories to the playlist (zecke) | 179 | * OpiePlayer2 gained adding of Directories to the playlist (zecke) |
179 | * OpiePlayer2 better error handling (zecke) | 180 | * OpiePlayer2 better error handling (zecke) |
180 | * OpiePlayer2 progress indication while streaming (zecke) | 181 | * OpiePlayer2 progress indication while streaming (zecke) |
181 | * OpiePlayer2 ported to use libxine 1.0.0-rc6a (brad,zecke) | 182 | * OpiePlayer2 ported to use libxine 1.0.0-rc6a (brad,zecke) |
182 | * Ported brightnessapplet from Qtopia 1.7 (mickeyl) | 183 | * Ported brightnessapplet from Qtopia 1.7 (mickeyl) |
183 | * Opie-Eye got a Digital Camera File Backend (alwin,zecke) | 184 | * Opie-Eye got a Digital Camera File Backend (alwin,zecke) |
184 | * Support for Tuxpad1 of Tradesquare.NL (mickeyl,zecke) | 185 | * Support for Tuxpad1 of Tradesquare.NL (mickeyl,zecke) |
185 | * Opie-Console use Custom Font and Size in a Profile (harlekin) | 186 | * Opie-Console use Custom Font and Size in a Profile (harlekin) |
186 | * Opie-Console transparently log the Output and Input to a file (harlekin) | 187 | * Opie-Console transparently log the Output and Input to a file (harlekin) |
187 | * Added new O-menu icon to lock the PDA immediately: opie-lockapplet (clem) | 188 | * Added new O-menu icon to lock the PDA immediately: opie-lockapplet (clem) |
188 | * Opie-Security now hides the plugin-based authentication tabs if no auth. plugin package is installed (clem) | 189 | * Opie-Security now hides the plugin-based authentication tabs if no auth. plugin package is installed (clem) |
189 | * Opie-Security gained a 'test authentication' button (clem) | 190 | * Opie-Security gained a 'test authentication' button (clem) |
190 | * Opie-Eye got a more unique layout (menubar), a slideshow, user can setup some defaults | 191 | * Opie-Eye got a more unique layout (menubar), a slideshow, user can setup some defaults |
191 | * Opie-Mail improve the handling of POP mail boxes (alwin) | 192 | * Opie-Mail improve the handling of POP mail boxes (alwin) |
192 | * Both Opie-Eye and Opie-Mail were greatly improved due the hard work of Rajko Albrecht(alwin) | 193 | * Both Opie-Eye and Opie-Mail were greatly improved due the hard work of Rajko Albrecht(alwin) |
193 | * Opie IRC - backports of the 'NeIRC fork' (zecke) | 194 | * Opie IRC - backports of the 'NeIRC fork' (zecke) |
194 | 195 | ||
195 | Fixed Bugs | 196 | Fixed Bugs |
196 | ---------- | 197 | ---------- |
197 | * #501 - Pickboard is able to show 'Umlaute' (TT,zecke) | 198 | * #501 - Pickboard is able to show 'Umlaute' (TT,zecke) |
198 | * #608 - Make Opie usable for left handed users (zecke) | 199 | * #608 - Make Opie usable for left handed users (zecke) |
199 | * #957 - Import of VCards/VTodos/VEvents with BASE64 encoding (ljp,zecke) | 200 | * #957 - Import of VCards/VTodos/VEvents with BASE64 encoding (ljp,zecke) |
200 | * #1245 - Opie-Go 'paused' (zecke) | 201 | * #1245 - Opie-Go 'paused' (zecke) |
201 | * #1358 - DocTab didn't show any MimeTypes (was fixed earlier) (zecke) | 202 | * #1358 - DocTab didn't show any MimeTypes (was fixed earlier) (zecke) |
202 | * #1380 - QDateBookAccess::remove() doesn't remove entries (eilers, zecke) | 203 | * #1380 - QDateBookAccess::remove() doesn't remove entries (eilers, zecke) |
203 | * #1395 - Build VNC Backend with gcc3.4 | 204 | * #1395 - Build VNC Backend with gcc3.4 |
204 | * #1440 - The icon of opie-mobilemsg is missing (CoreDump) | 205 | * #1440 - The icon of opie-mobilemsg is missing (CoreDump) |
205 | * #1426 - Add missing opie-bartender Icon (CoreDump) | 206 | * #1426 - Add missing opie-bartender Icon (CoreDump) |
206 | * #1445 - Opie-Sheet Has No Icon (CoreDump) | 207 | * #1445 - Opie-Sheet Has No Icon (CoreDump) |
207 | * #1448 - Brightness Applet added (mickeyl) | 208 | * #1448 - Brightness Applet added (mickeyl) |
208 | * #1450 - ZSame didn't clear the bonus item after winning a game (zecke) | 209 | * #1450 - ZSame didn't clear the bonus item after winning a game (zecke) |
209 | * #1482 - Fix OFileSelector to be able to sort by size (zecke) | 210 | * #1482 - Fix OFileSelector to be able to sort by size (zecke) |
210 | * n.a. - Opie-mail: fixed some crasher, some layout-problems | 211 | * n.a. - Opie-mail: fixed some crasher, some layout-problems |
211 | * n.a. - Converted applications to not hardcode /opt/QtPalmtop but to use QPEApplication::qpeDir (zecke) | 212 | * n.a. - Converted applications to not hardcode /opt/QtPalmtop but to use QPEApplication::qpeDir (zecke) |
212 | * n.a. - Converted usage of qpeDir() not to include a '/' as first charachter of the string (zecke) | 213 | * n.a. - Converted usage of qpeDir() not to include a '/' as first charachter of the string (zecke) |
213 | * n.a. - Build system: Enable distcc and ccache when crosscompiling too, and use them everywhere we can (clem) | 214 | * n.a. - Build system: Enable distcc and ccache when crosscompiling too, and use them everywhere we can (clem) |
214 | * n.a. - Build system: Fix deps in several config.in (and fix scripts/deps.pl too) to stop breaking builds, especially with make -j highNumber (clem) | 215 | * n.a. - Build system: Fix deps in several config.in (and fix scripts/deps.pl too) to stop breaking builds, especially with make -j highNumber (clem) |
215 | * n.a. - Removed hardcoded icon size in a couple of applets (mickeyl) | 216 | * n.a. - Removed hardcoded icon size in a couple of applets (mickeyl) |
216 | 217 | ||
217 | Internal | 218 | Internal |
218 | -------- | 219 | -------- |
219 | * Opie-Qashmoney has been moved to unsupported (mickeyl) | 220 | * Opie-Qashmoney has been moved to unsupported (mickeyl) |
220 | * Opie-Ubrowser has been moved to unsupported (mickeyl) | 221 | * Opie-Ubrowser has been moved to unsupported (mickeyl) |
221 | 222 | ||
222 | 2004-09-17Opie 1.1.6 | 223 | 2004-09-17Opie 1.1.6 |
223 | 224 | ||
224 | New Features | 225 | New Features |
225 | ------------ | 226 | ------------ |
226 | * Fifteen gained configurable number of items (zecke) | 227 | * Fifteen gained configurable number of items (zecke) |
227 | * Fifteen can have custom background images (zecke) | 228 | * Fifteen can have custom background images (zecke) |
228 | * Added daemonizing capabilities to QWS Server [via Qt/Embedded] (mickeyl) | 229 | * Added daemonizing capabilities to QWS Server [via Qt/Embedded] (mickeyl) |
229 | * Integrated the new security framework into libopie2 (zecke,clem) | 230 | * Integrated the new security framework into libopie2 (zecke,clem) |
230 | * Converted the launcher to use the new security framework (zecke) | 231 | * Converted the launcher to use the new security framework (zecke) |
231 | * Backup can now handle custom locations for backup and restore (ar) | 232 | * Backup can now handle custom locations for backup and restore (ar) |
232 | * Implemented right-on-hold feedback (wimpie,zecke) | 233 | * Implemented right-on-hold feedback (wimpie,zecke) |
233 | * Lots of new features in opie-reader (tim,pohly) | 234 | * Lots of new features in opie-reader (tim,pohly) |
234 | * Build system cleanups (schurig) | 235 | * Build system cleanups (schurig) |
235 | 236 | ||
236 | Fixed Bugs | 237 | Fixed Bugs |
237 | -------- | 238 | -------- |
238 | * #1005 - Fixed backup to CompactFlash (ar) | 239 | * #1005 - Fixed backup to CompactFlash (ar) |
239 | * #1167 - Fixed Opie write crashing on more text than one page (ar) | 240 | * #1167 - Fixed Opie write crashing on more text than one page (ar) |
240 | * #1225 - Fixed repeated light flashing on Zaurus with keyz (mickeyl) | 241 | * #1225 - Fixed repeated light flashing on Zaurus with keyz (mickeyl) |
241 | * #1359 - Fixed bookmarks in Gutenbrowser (ljp) | 242 | * #1359 - Fixed bookmarks in Gutenbrowser (ljp) |
242 | * #1361 - Fixed auto upercase in Opie-Addressbook (eilers) | 243 | * #1361 - Fixed auto upercase in Opie-Addressbook (eilers) |
243 | * #1370 - Pimconverter now reacts on cancel key (eilers) | 244 | * #1370 - Pimconverter now reacts on cancel key (eilers) |
244 | * #1376 - Bring back the capslock/numlock display (zecke) | 245 | * #1376 - Bring back the capslock/numlock display (zecke) |
245 | * #1383 - Language settings now warns about losing open apps (Markus Litz) | 246 | * #1383 - Language settings now warns about losing open apps (Markus Litz) |
246 | * #1393 - Fixed line wrap issues in opie-console for the default profile (mickeyl) | 247 | * #1393 - Fixed line wrap issues in opie-console for the default profile (mickeyl) |
247 | * #1394 - Fixed oversized headline in opie-login (coredump) | 248 | * #1394 - Fixed oversized headline in opie-login (coredump) |
248 | * #1396 - Opie-console captures the escape key and vim is working (zecke) | 249 | * #1396 - Opie-console captures the escape key and vim is working (zecke) |
249 | * #1401 - Scrollbar is now only visible if necessary in DocTab (mickeyl) | 250 | * #1401 - Scrollbar is now only visible if necessary in DocTab (mickeyl) |
250 | 251 | ||
251 | 2004-07-06Opie 1.1.4 | 252 | 2004-07-06Opie 1.1.4 |
252 | 253 | ||
253 | New Features | 254 | New Features |
254 | ------------ | 255 | ------------ |
255 | * Added four themes courtesy Robert Griebl (http://www.softforge.de/zstyle) | 256 | * Added four themes courtesy Robert Griebl (http://www.softforge.de/zstyle) |
256 | * Added Conversion tool for pim-data (eilers) | 257 | * Added Conversion tool for pim-data (eilers) |
257 | * Introduced new OPimAccessFactory and OBackendFactory which simplyfies database access (eilers) | 258 | * Introduced new OPimAccessFactory and OBackendFactory which simplyfies database access (eilers) |
258 | * Modified the PIM API for providing generic use of OPimRecords (eilers) | 259 | * Modified the PIM API for providing generic use of OPimRecords (eilers) |
259 | * Clicking on the application symbol now iterates over the application's top level widgets if already raised (zecke) | 260 | * Clicking on the application symbol now iterates over the application's top level widgets if already raised (zecke) |
260 | 261 | ||
261 | Fixed Bugs | 262 | Fixed Bugs |
262 | -------- | 263 | -------- |
263 | * #1068 - Country Drop Down Box Off Screen | 264 | * #1068 - Country Drop Down Box Off Screen |
264 | * #1291 - Opie tinykate does not open .desktop files (ar) | 265 | * #1291 - Opie tinykate does not open .desktop files (ar) |
265 | * #1291 - Opie sheet not saving correctly (ar) | 266 | * #1291 - Opie sheet not saving correctly (ar) |
266 | * #1294 - Opie does not know about British Summer Time | 267 | * #1294 - Opie does not know about British Summer Time |
267 | * #1314 - Drawpad initialization (mickeyl) | 268 | * #1314 - Drawpad initialization (mickeyl) |
268 | * #1317 - Packagemanager crashes on hold-down or install (chicken) | 269 | * #1317 - Packagemanager crashes on hold-down or install (chicken) |
269 | * #1321 - Batteryapplet graphic glitch (harlekin) | 270 | * #1321 - Batteryapplet graphic glitch (harlekin) |
270 | * #1324 - ZSafe not starting up (mickeyl) | 271 | * #1324 - ZSafe not starting up (mickeyl) |
271 | * #1328 - Personal Home Address fields is trimmed to 1char (eilers) | 272 | * #1328 - Personal Home Address fields is trimmed to 1char (eilers) |
272 | * #1327 - Opie-mail ipk does not depend on libopiedb2 (chicken) | 273 | * #1327 - Opie-mail ipk does not depend on libopiedb2 (chicken) |
273 | * #1345 - Networksettingsplugin wlan plugin dependency on libpcap0 (mickeyl) | 274 | * #1345 - Networksettingsplugin wlan plugin dependency on libpcap0 (mickeyl) |
274 | * #1348 - Datebook dependency on libopiedb2 (chicken) | 275 | * #1348 - Datebook dependency on libopiedb2 (chicken) |
275 | * #1328 - Switched SQLDatabase and VCards char encoding from latin1 to unicode (eilers) | 276 | * #1328 - Switched SQLDatabase and VCards char encoding from latin1 to unicode (eilers) |
276 | 277 | ||
277 | 2004-04-25Opie 1.1.3 | 278 | 2004-04-25Opie 1.1.3 |
278 | 279 | ||
279 | * Introduced first implementation of SQL-Support using SQLite (eilers) | 280 | * Introduced first implementation of SQL-Support using SQLite (eilers) |
280 | * Added a new Gutenberg Project reader app - opie-gutenbrowser (ljp) | 281 | * Added a new Gutenberg Project reader app - opie-gutenbrowser (ljp) |
281 | * Added a real system graffiti character set (brad) | 282 | * Added a real system graffiti character set (brad) |
282 | * Added Generic Keyconfig Widget (zecke) | 283 | * Added Generic Keyconfig Widget (zecke) |
283 | * Improved Screenshotapplet and Drawpad integration. You can now open a screenshot in drawpad and take notes (zecke) | 284 | * Improved Screenshotapplet and Drawpad integration. You can now open a screenshot in drawpad and take notes (zecke) |
284 | * Added new Bible reader app - opie-dagger (drw) | 285 | * Added new Bible reader app - opie-dagger (drw) |
285 | * Added a new Image Viewer. Work is ongoing (zecke,alwin) | 286 | * Added a new Image Viewer. Work is ongoing (zecke,alwin) |
286 | * Added namespace usage in libopie2 and everywhere (zecke,alwin) | 287 | * Added namespace usage in libopie2 and everywhere (zecke,alwin) |
287 | * Enabled the possibility to pass command line arguments to applications (mickeyl) | 288 | * Enabled the possibility to pass command line arguments to applications (mickeyl) |
288 | * Added an about applet showing some credits and information about Opie (mickeyl) | 289 | * Added an about applet showing some credits and information about Opie (mickeyl) |
289 | * Added benchmarking functionality to sysinfo (mickeyl) | 290 | * Added benchmarking functionality to sysinfo (mickeyl) |
290 | * Added applet and configuration application for switching hardware keyboard layouts (alwin) | 291 | * Added applet and configuration application for switching hardware keyboard layouts (alwin) |
291 | * Ported applications from libopie1 to libopie2* (drw,ar,alwin) | 292 | * Ported applications from libopie1 to libopie2* (drw,ar,alwin) |
292 | * Imported fullscreen and font improvements from the Qkonsole fork to embeddedkonsole (waspe) | 293 | * Imported fullscreen and font improvements from the Qkonsole fork to embeddedkonsole (waspe) |
293 | * Clean-up of package information in control files (drw) | 294 | * Clean-up of package information in control files (drw) |
294 | * Repaired mediummount which was broken since integrating the quicklauncher (alwin) | 295 | * Repaired mediummount which was broken since integrating the quicklauncher (alwin) |
295 | * Improved big-screen support (zecke,ar) | 296 | * Improved big-screen support (zecke,ar) |
296 | * Improved multikeyboard support, added keyboard layout switching applet (mouse) | 297 | * Improved multikeyboard support, added keyboard layout switching applet (mouse) |
297 | * Added a new mail client based on libetpan (harlekin,alwin,jgf) | 298 | * Added a new mail client based on libetpan (harlekin,alwin,jgf) |
298 | * Added new package manager - opie-packagemanager (drw) | 299 | * Added new package manager - opie-packagemanager (drw) |
299 | * Improved light-n-power for C7x0 (mickeyl) | 300 | * Improved light-n-power for C7x0 (mickeyl) |
300 | * Added automatic rotation support for C7x0 (treke) | 301 | * Added automatic rotation support for C7x0 (treke) |
301 | * Split libopie1 up into a set of smaller - functionally grouped - libraries (mickeyl) | 302 | * Split libopie1 up into a set of smaller - functionally grouped - libraries (mickeyl) |
302 | * Added scanning the wireless network neighbourhood to networksettings (mickeyl) | 303 | * Added scanning the wireless network neighbourhood to networksettings (mickeyl) |
303 | 304 | ||
304 | 2003-11-29Opie 1.0.3 | 305 | 2003-11-29Opie 1.0.3 |
305 | 306 | ||
306 | * Released as Version 1.0.3 | 307 | * Released as Version 1.0.3 |
307 | * Improved i18n (various contributors) | 308 | * Improved i18n (various contributors) |
308 | * Reduced application startup time by integrating the TT quicklauncher (zecke,harlekin) | 309 | * Reduced application startup time by integrating the TT quicklauncher (zecke,harlekin) |
309 | * Made the Documents Tab optional (mickeyl) | 310 | * Made the Documents Tab optional (mickeyl) |
310 | * Integrated basic support for HP iPAQ 54xx and the Jornada 5xx (chicken) | 311 | * Integrated basic support for HP iPAQ 54xx and the Jornada 5xx (chicken) |
311 | 312 | ||
312 | 2003-08-04Opie 1.0.0 | 313 | 2003-08-04Opie 1.0.0 |
313 | 314 | ||
314 | * Released as Version 1.0.0 | 315 | * Released as Version 1.0.0 |
315 | * Including a PPP module for easy dial up (tille,harlekin,zecke) | 316 | * Including a PPP module for easy dial up (tille,harlekin,zecke) |
diff --git a/noncore/settings/netsystemtime/mainwindow.cpp b/noncore/settings/netsystemtime/mainwindow.cpp index 35d4105..c1cd796 100644 --- a/noncore/settings/netsystemtime/mainwindow.cpp +++ b/noncore/settings/netsystemtime/mainwindow.cpp | |||
@@ -1,418 +1,428 @@ | |||
1 | /* | 1 | /* |
2 | This file is part of the Opie Project | 2 | This file is part of the Opie Project |
3 | 3 | ||
4 | Copyright (C) Opie Team <opie-devel@handhelds.org> | 4 | Copyright (C) Opie Team <opie-devel@handhelds.org> |
5 | =. | 5 | =. |
6 | .=l. | 6 | .=l. |
7 | .>+-= | 7 | .>+-= |
8 | _;:, .> :=|. This program is free software; you can | 8 | _;:, .> :=|. This program is free software; you can |
9 | .> <`_, > . <= redistribute it and/or modify it under | 9 | .> <`_, > . <= redistribute it and/or modify it under |
10 | :`=1 )Y*s>-.-- : the terms of the GNU Library General Public | 10 | :`=1 )Y*s>-.-- : the terms of the GNU Library General Public |
11 | .="- .-=="i, .._ License as published by the Free Software | 11 | .="- .-=="i, .._ License as published by the Free Software |
12 | - . .-<_> .<> Foundation; either version 2 of the License, | 12 | - . .-<_> .<> Foundation; either version 2 of the License, |
13 | ._= =} : or (at your option) any later version. | 13 | ._= =} : or (at your option) any later version. |
14 | .%`+i> _;_. | 14 | .%`+i> _;_. |
15 | .i_,=:_. -<s. This program is distributed in the hope that | 15 | .i_,=:_. -<s. This program is distributed in the hope that |
16 | + . -:. = it will be useful, but WITHOUT ANY WARRANTY; | 16 | + . -:. = it will be useful, but WITHOUT ANY WARRANTY; |
17 | : .. .:, . . . without even the implied warranty of | 17 | : .. .:, . . . without even the implied warranty of |
18 | =_ + =;=|` MERCHANTABILITY or FITNESS FOR A | 18 | =_ + =;=|` MERCHANTABILITY or FITNESS FOR A |
19 | _.=:. : :=>`: PARTICULAR PURPOSE. See the GNU | 19 | _.=:. : :=>`: PARTICULAR PURPOSE. See the GNU |
20 | ..}^=.= = ; Library General Public License for more | 20 | ..}^=.= = ; Library General Public License for more |
21 | ++= -. .` .: details. | 21 | ++= -. .` .: details. |
22 | : = ...= . :.=- | 22 | : = ...= . :.=- |
23 | -. .:....=;==+<; You should have received a copy of the GNU | 23 | -. .:....=;==+<; You should have received a copy of the GNU |
24 | -_. . . )=. = Library General Public License along with | 24 | -_. . . )=. = Library General Public License along with |
25 | -- :-=` this library; see the file COPYING.LIB. | 25 | -- :-=` this library; see the file COPYING.LIB. |
26 | If not, write to the Free Software Foundation, | 26 | If not, write to the Free Software Foundation, |
27 | Inc., 59 Temple Place - Suite 330, | 27 | Inc., 59 Temple Place - Suite 330, |
28 | Boston, MA 02111-1307, USA. | 28 | Boston, MA 02111-1307, USA. |
29 | */ | 29 | */ |
30 | 30 | ||
31 | #include "mainwindow.h" | 31 | #include "mainwindow.h" |
32 | #include "timetabwidget.h" | 32 | #include "timetabwidget.h" |
33 | #include "formattabwidget.h" | 33 | #include "formattabwidget.h" |
34 | #include "settingstabwidget.h" | 34 | #include "settingstabwidget.h" |
35 | #include "ntptabwidget.h" | 35 | #include "ntptabwidget.h" |
36 | #include "predicttabwidget.h" | 36 | #include "predicttabwidget.h" |
37 | 37 | ||
38 | #include <qpe/config.h> | 38 | #include <qpe/config.h> |
39 | #include <qpe/datebookdb.h> | 39 | #include <qpe/datebookdb.h> |
40 | #include <qpe/qpeapplication.h> | 40 | #include <qpe/qpeapplication.h> |
41 | #include <qpe/qpedialog.h> | 41 | #include <qpe/qpedialog.h> |
42 | 42 | ||
43 | #if ( defined Q_WS_QWS || defined(_WS_QWS_) ) && !defined(QT_NO_COP) | 43 | #if ( defined Q_WS_QWS || defined(_WS_QWS_) ) && !defined(QT_NO_COP) |
44 | #include <qpe/qcopenvelope_qws.h> | 44 | #include <qpe/qcopenvelope_qws.h> |
45 | #endif | 45 | #endif |
46 | 46 | ||
47 | #include <qlayout.h> | 47 | #include <qlayout.h> |
48 | #include <qmessagebox.h> | 48 | #include <qmessagebox.h> |
49 | #include <qsocket.h> | 49 | #include <qsocket.h> |
50 | #include <qstring.h> | 50 | #include <qstring.h> |
51 | #include <qtimer.h> | 51 | #include <qtimer.h> |
52 | 52 | ||
53 | using namespace Opie::Ui; | 53 | using namespace Opie::Ui; |
54 | using namespace Opie::Core; | 54 | using namespace Opie::Core; |
55 | MainWindow::MainWindow( QWidget *parent , const char *name, bool modal, WFlags f ) | 55 | MainWindow::MainWindow( QWidget *parent , const char *name, bool modal, WFlags f ) |
56 | : QDialog( parent, name, modal, f ) | 56 | : QDialog( parent, name, modal, f ) |
57 | { | 57 | { |
58 | setCaption( tr( "SystemTime" ) ); | 58 | setCaption( tr( "SystemTime" ) ); |
59 | 59 | ||
60 | QVBoxLayout *layout = new QVBoxLayout( this ); | 60 | QVBoxLayout *layout = new QVBoxLayout( this ); |
61 | layout->setMargin( 2 ); | 61 | layout->setMargin( 2 ); |
62 | layout->setSpacing( 4 ); | 62 | layout->setSpacing( 4 ); |
63 | 63 | ||
64 | // Create main tabbed control | 64 | // Create main tabbed control |
65 | mainWidget = new OTabWidget( this ); | 65 | mainWidget = new OTabWidget( this ); |
66 | 66 | ||
67 | // Default object pointers to null | 67 | // Default object pointers to null |
68 | ntpProcess = 0x0; | 68 | ntpProcess = 0x0; |
69 | ntpTab = 0x0; | 69 | ntpTab = 0x0; |
70 | predictTab = 0x0; | ||
70 | 71 | ||
71 | // Add tab widgets | 72 | // Add tab widgets |
72 | mainWidget->addTab( timeTab = new TimeTabWidget( mainWidget ), "netsystemtime/DateTime", tr( "Time" ) ); | 73 | mainWidget->addTab( timeTab = new TimeTabWidget( mainWidget ), "netsystemtime/DateTime", tr( "Time" ) ); |
73 | mainWidget->addTab( formatTab = new FormatTabWidget( mainWidget ), "netsystemtime/formattab", tr( "Format" ) ); | 74 | mainWidget->addTab( formatTab = new FormatTabWidget( mainWidget ), "netsystemtime/formattab", tr( "Format" ) ); |
74 | mainWidget->addTab( settingsTab = new SettingsTabWidget( mainWidget ), "SettingsIcon", tr( "Settings" ) ); | 75 | mainWidget->addTab( settingsTab = new SettingsTabWidget( mainWidget ), "SettingsIcon", tr( "Settings" ) ); |
75 | mainWidget->addTab( predictTab = new PredictTabWidget( mainWidget ), "netsystemtime/predicttab", tr( "Predict" ) ); | ||
76 | Config config( "ntp" ); | 76 | Config config( "ntp" ); |
77 | config.setGroup( "settings" ); | 77 | config.setGroup( "settings" ); |
78 | slotDisplayNTPTab( config.readBoolEntry( "displayNtpTab", false ) ); | 78 | slotDisplayNTPTab( config.readBoolEntry( "displayNtpTab", false ) ); |
79 | slotDisplayPredictTab( config.readBoolEntry( "displayPredictTab", false ) ); | 79 | slotDisplayPredictTab( config.readBoolEntry( "displayPredictTab", false ) ); |
80 | 80 | ||
81 | mainWidget->setCurrentTab( tr( "Time" ) ); | 81 | mainWidget->setCurrentTab( tr( "Time" ) ); |
82 | layout->addWidget( mainWidget ); | 82 | layout->addWidget( mainWidget ); |
83 | 83 | ||
84 | connect( qApp, SIGNAL(appMessage(const QCString&,const QByteArray&)), | 84 | connect( qApp, SIGNAL(appMessage(const QCString&,const QByteArray&)), |
85 | this, SLOT(slotQCopReceive(const QCString&,const QByteArray&)) ); | 85 | this, SLOT(slotQCopReceive(const QCString&,const QByteArray&)) ); |
86 | 86 | ||
87 | 87 | ||
88 | // Create NTP socket | 88 | // Create NTP socket |
89 | ntpSock = new QSocket( this ); | 89 | ntpSock = new QSocket( this ); |
90 | connect( ntpSock, SIGNAL(error(int)),SLOT(slotCheckNtp(int)) ); | 90 | connect( ntpSock, SIGNAL(error(int)),SLOT(slotCheckNtp(int)) ); |
91 | slotProbeNTPServer(); | 91 | slotProbeNTPServer(); |
92 | 92 | ||
93 | // Create timer for automatic time lookups | 93 | // Create timer for automatic time lookups |
94 | ntpTimer = new QTimer( this ); | 94 | ntpTimer = new QTimer( this ); |
95 | 95 | ||
96 | // Connect everything together | 96 | // Connect everything together |
97 | connect( timeTab, SIGNAL(getNTPTime()), this, SLOT(slotGetNTPTime()) ); | 97 | connect( timeTab, SIGNAL(getNTPTime()), this, SLOT(slotGetNTPTime()) ); |
98 | connect( timeTab, SIGNAL(tzChanged(const QString&)), predictTab, SLOT(slotTZChanged(const QString&)) ); | 98 | connect( timeTab, SIGNAL(tzChanged(const QString&)), predictTab, SLOT(slotTZChanged(const QString&)) ); |
99 | connect( timeTab, SIGNAL(getPredictedTime()), predictTab, SLOT(slotSetPredictedTime()) ); | 99 | connect( timeTab, SIGNAL(getPredictedTime()), predictTab, SLOT(slotSetPredictedTime()) ); |
100 | connect( formatTab, SIGNAL(show12HourTime(int)), timeTab, SLOT(slotUse12HourTime(int)) ); | 100 | connect( formatTab, SIGNAL(show12HourTime(int)), timeTab, SLOT(slotUse12HourTime(int)) ); |
101 | connect( formatTab, SIGNAL(dateFormatChanged(const DateFormat&)), | 101 | connect( formatTab, SIGNAL(dateFormatChanged(const DateFormat&)), |
102 | timeTab, SLOT(slotDateFormatChanged(const DateFormat&)) ); | 102 | timeTab, SLOT(slotDateFormatChanged(const DateFormat&)) ); |
103 | connect( formatTab, SIGNAL(weekStartChanged(int)), timeTab, SLOT(slotWeekStartChanged(int)) ); | 103 | connect( formatTab, SIGNAL(weekStartChanged(int)), timeTab, SLOT(slotWeekStartChanged(int)) ); |
104 | connect( settingsTab, SIGNAL(ntpDelayChanged(int)), this, SLOT(slotNTPDelayChanged(int)) ); | 104 | connect( settingsTab, SIGNAL(ntpDelayChanged(int)), this, SLOT(slotNTPDelayChanged(int)) ); |
105 | connect( settingsTab, SIGNAL(displayNTPTab(bool)), this, SLOT(slotDisplayNTPTab(bool)) ); | 105 | connect( settingsTab, SIGNAL(displayNTPTab(bool)), this, SLOT(slotDisplayNTPTab(bool)) ); |
106 | connect( settingsTab, SIGNAL(displayPredictTab(bool)), this, SLOT(slotDisplayPredictTab(bool)) ); | 106 | connect( settingsTab, SIGNAL(displayPredictTab(bool)), this, SLOT(slotDisplayPredictTab(bool)) ); |
107 | connect( predictTab, SIGNAL(setTime(const QDateTime&)), this, SLOT(slotSetTime(const QDateTime&)) ); | 107 | connect( predictTab, SIGNAL(setTime(const QDateTime&)), this, SLOT(slotSetTime(const QDateTime&)) ); |
108 | 108 | ||
109 | // Do initial time server check | 109 | // Do initial time server check |
110 | slotNTPDelayChanged( config.readNumEntry( "ntpRefreshFreq", 1440 ) ); | 110 | slotNTPDelayChanged( config.readNumEntry( "ntpRefreshFreq", 1440 ) ); |
111 | slotCheckNtp( -1 ); | 111 | slotCheckNtp( -1 ); |
112 | 112 | ||
113 | // Display app | 113 | // Display app |
114 | //showMaximized(); | 114 | //showMaximized(); |
115 | (void)new QPEDialogListener(this); | 115 | (void)new QPEDialogListener(this); |
116 | } | 116 | } |
117 | 117 | ||
118 | MainWindow::~MainWindow() | 118 | MainWindow::~MainWindow() |
119 | { | 119 | { |
120 | if ( ntpProcess ) | 120 | if ( ntpProcess ) |
121 | delete ntpProcess; | 121 | delete ntpProcess; |
122 | } | 122 | } |
123 | 123 | ||
124 | void MainWindow::accept() | 124 | void MainWindow::accept() |
125 | { | 125 | { |
126 | // Turn off the screensaver (Note: needs to be encased in { } so that it deconstructs and sends) | 126 | // Turn off the screensaver (Note: needs to be encased in { } so that it deconstructs and sends) |
127 | { | 127 | { |
128 | QCopEnvelope disableScreenSaver( "QPE/System", "setScreenSaverIntervals(int,int,int)" ); | 128 | QCopEnvelope disableScreenSaver( "QPE/System", "setScreenSaverIntervals(int,int,int)" ); |
129 | disableScreenSaver << 0 << 0 << 0; | 129 | disableScreenSaver << 0 << 0 << 0; |
130 | } | 130 | } |
131 | 131 | ||
132 | // Update the systemtime | 132 | // Update the systemtime |
133 | timeTab->saveSettings( true ); | 133 | timeTab->saveSettings( true ); |
134 | 134 | ||
135 | // Save format options | 135 | // Save format options |
136 | formatTab->saveSettings( true ); | 136 | formatTab->saveSettings( true ); |
137 | 137 | ||
138 | // Save settings options | 138 | // Save settings options |
139 | settingsTab->saveSettings(); | 139 | settingsTab->saveSettings(); |
140 | 140 | ||
141 | // Since time has changed quickly load in the DateBookDB to allow the alarm server to get a better | 141 | // Since time has changed quickly load in the DateBookDB to allow the alarm server to get a better |
142 | // grip on itself (example re-trigger alarms for when we travel back in time). | 142 | // grip on itself (example re-trigger alarms for when we travel back in time). |
143 | DateBookDB db; | 143 | DateBookDB db; |
144 | 144 | ||
145 | // Turn back on the screensaver | 145 | // Turn back on the screensaver |
146 | QCopEnvelope enableScreenSaver( "QPE/System", "setScreenSaverIntervals(int,int,int)" ); | 146 | QCopEnvelope enableScreenSaver( "QPE/System", "setScreenSaverIntervals(int,int,int)" ); |
147 | enableScreenSaver << -1 << -1 << -1; | 147 | enableScreenSaver << -1 << -1 << -1; |
148 | 148 | ||
149 | // Exit app | 149 | // Exit app |
150 | qApp->quit(); | 150 | qApp->quit(); |
151 | } | 151 | } |
152 | 152 | ||
153 | void MainWindow::reject() | 153 | void MainWindow::reject() |
154 | { | 154 | { |
155 | // Reset time settings | 155 | // Reset time settings |
156 | timeTab->saveSettings( false ); | 156 | timeTab->saveSettings( false ); |
157 | 157 | ||
158 | // Send notifications but do not save settings | 158 | // Send notifications but do not save settings |
159 | formatTab->saveSettings( false ); | 159 | formatTab->saveSettings( false ); |
160 | 160 | ||
161 | // Exit app | 161 | // Exit app |
162 | qApp->quit(); | 162 | qApp->quit(); |
163 | } | 163 | } |
164 | 164 | ||
165 | void MainWindow::runNTP() | 165 | void MainWindow::runNTP() |
166 | { | 166 | { |
167 | if ( !ntpDelayElapsed() && ntpInteractive ) | 167 | if ( !ntpDelayElapsed() && ntpInteractive ) |
168 | { | 168 | { |
169 | QString msg = tr( "You asked for a delay of %1 minutes, but only %2 minutes elapsed since last lookup.<br>Continue?" ).arg( QString::number( ntpDelay ) ).arg( QString::number( _lookupDiff / 60 ) ); | 169 | QString msg = tr( "You asked for a delay of %1 minutes, but only %2 minutes elapsed since last lookup.<br>Continue?" ).arg( QString::number( ntpDelay ) ).arg( QString::number( _lookupDiff / 60 ) ); |
170 | 170 | ||
171 | switch ( | 171 | switch ( |
172 | QMessageBox::warning( this, tr( "Continue?" ), msg, QMessageBox::Yes, QMessageBox::No ) | 172 | QMessageBox::warning( this, tr( "Continue?" ), msg, QMessageBox::Yes, QMessageBox::No ) |
173 | ) | 173 | ) |
174 | { | 174 | { |
175 | case QMessageBox::Yes: break; | 175 | case QMessageBox::Yes: break; |
176 | case QMessageBox::No: return; | 176 | case QMessageBox::No: return; |
177 | default: return; | 177 | default: return; |
178 | } | 178 | } |
179 | } | 179 | } |
180 | 180 | ||
181 | QString srv = settingsTab->ntpServer(); | 181 | QString srv = settingsTab->ntpServer(); |
182 | 182 | ||
183 | // Send information to time server tab if enabled | 183 | // Send information to time server tab if enabled |
184 | if ( ntpTabEnabled ) | 184 | if ( ntpTabEnabled ) |
185 | { | 185 | { |
186 | ntpTab->setStartTime( QDateTime::currentDateTime().toString() ); | 186 | ntpTab->setStartTime( QDateTime::currentDateTime().toString() ); |
187 | QString output = tr( "Running:\nntpdate " ); | 187 | QString output = tr( "Running:\nntpdate " ); |
188 | output.append( srv ); | 188 | output.append( srv ); |
189 | ntpTab->addNtpOutput( output ); | 189 | ntpTab->addNtpOutput( output ); |
190 | ntpTab->setNTPBtnEnabled( false ); | 190 | ntpTab->setNTPBtnEnabled( false ); |
191 | } | 191 | } |
192 | 192 | ||
193 | // Disable set time buttons & change app caption to indicate time update is happening | 193 | // Disable set time buttons & change app caption to indicate time update is happening |
194 | timeTab->setNTPBtnEnabled( false ); | 194 | timeTab->setNTPBtnEnabled( false ); |
195 | setCaption( tr( "Retrieving time from network..." ) ); | 195 | setCaption( tr( "Retrieving time from network..." ) ); |
196 | 196 | ||
197 | if ( !ntpProcess ) | 197 | if ( !ntpProcess ) |
198 | { | 198 | { |
199 | ntpProcess = new OProcess(); | 199 | ntpProcess = new OProcess(); |
200 | connect( ntpProcess, SIGNAL(receivedStdout(Opie::Core::OProcess*,char*,int)), | 200 | connect( ntpProcess, SIGNAL(receivedStdout(Opie::Core::OProcess*,char*,int)), |
201 | this, SLOT(slotNtpOutput(Opie::Core::OProcess*,char*,int)) ); | 201 | this, SLOT(slotNtpOutput(Opie::Core::OProcess*,char*,int)) ); |
202 | connect( ntpProcess, SIGNAL(processExited(Opie::Core::OProcess*)), | 202 | connect( ntpProcess, SIGNAL(processExited(Opie::Core::OProcess*)), |
203 | this, SLOT(slotNtpFinished(Opie::Core::OProcess*)) ); | 203 | this, SLOT(slotNtpFinished(Opie::Core::OProcess*)) ); |
204 | } | 204 | } |
205 | 205 | ||
206 | else | 206 | else |
207 | ntpProcess->clearArguments(); | 207 | ntpProcess->clearArguments(); |
208 | 208 | ||
209 | *ntpProcess << "ntpdate" << srv; | 209 | *ntpProcess << "ntpdate" << srv; |
210 | bool ret = ntpProcess->start( OProcess::NotifyOnExit, OProcess::AllOutput ); | 210 | bool ret = ntpProcess->start( OProcess::NotifyOnExit, OProcess::AllOutput ); |
211 | if ( !ret ) | 211 | if ( !ret ) |
212 | { | 212 | { |
213 | QMessageBox::critical( this, tr( "Error" ), tr( "Error while getting time from network." ) ); | 213 | QMessageBox::critical( this, tr( "Error" ), tr( "Error while getting time from network." ) ); |
214 | if ( ntpTabEnabled ) | 214 | if ( ntpTabEnabled ) |
215 | { | 215 | { |
216 | ntpTab->addNtpOutput( tr( "Error while executing ntpdate" ) ); | 216 | ntpTab->addNtpOutput( tr( "Error while executing ntpdate" ) ); |
217 | ntpTab->setNTPBtnEnabled( true ); | 217 | ntpTab->setNTPBtnEnabled( true ); |
218 | } | 218 | } |
219 | 219 | ||
220 | // Re-enable set time buttons & change app caption to indicate time update is happening | 220 | // Re-enable set time buttons & change app caption to indicate time update is happening |
221 | timeTab->setNTPBtnEnabled( true ); | 221 | timeTab->setNTPBtnEnabled( true ); |
222 | setCaption( tr( "SystemTime" ) ); | 222 | setCaption( tr( "SystemTime" ) ); |
223 | } | 223 | } |
224 | } | 224 | } |
225 | 225 | ||
226 | bool MainWindow::ntpDelayElapsed() | 226 | bool MainWindow::ntpDelayElapsed() |
227 | { | 227 | { |
228 | // Determine if time elapsed is greater than time delay | 228 | // Determine if time elapsed is greater than time delay |
229 | Config config( "ntp" ); | 229 | Config config( "ntp" ); |
230 | config.setGroup( "lookups" ); | 230 | config.setGroup( "lookups" ); |
231 | _lookupDiff = TimeConversion::toUTC( QDateTime::currentDateTime() ) - config.readNumEntry( "time", 0 ); | 231 | _lookupDiff = TimeConversion::toUTC( QDateTime::currentDateTime() ) - config.readNumEntry( "time", 0 ); |
232 | if ( _lookupDiff < 0 ) | 232 | if ( _lookupDiff < 0 ) |
233 | return true; | 233 | return true; |
234 | return ( _lookupDiff - ( ntpDelay * 60) ) > 0; | 234 | return ( _lookupDiff - ( ntpDelay * 60) ) > 0; |
235 | } | 235 | } |
236 | 236 | ||
237 | void MainWindow::slotSetTime( const QDateTime &dt ) | 237 | void MainWindow::slotSetTime( const QDateTime &dt ) |
238 | { | 238 | { |
239 | timeTab->setDateTime( dt ); | 239 | timeTab->setDateTime( dt ); |
240 | } | 240 | } |
241 | 241 | ||
242 | void MainWindow::slotQCopReceive( const QCString &msg, const QByteArray & ) | 242 | void MainWindow::slotQCopReceive( const QCString &msg, const QByteArray & ) |
243 | { | 243 | { |
244 | if ( msg == "ntpLookup(QString)" ) | 244 | if ( msg == "ntpLookup(QString)" ) |
245 | { | 245 | { |
246 | ntpInteractive = false; | 246 | ntpInteractive = false; |
247 | runNTP(); | 247 | runNTP(); |
248 | } | 248 | } |
249 | if ( msg == "setPredictedTime(QString)" ) | 249 | if ( msg == "setPredictedTime(QString)" ) |
250 | { | 250 | { |
251 | //setPredictTime(); | 251 | //setPredictTime(); |
252 | } | 252 | } |
253 | } | 253 | } |
254 | 254 | ||
255 | void MainWindow::slotDisplayNTPTab( bool display ) | 255 | void MainWindow::slotDisplayNTPTab( bool display ) |
256 | { | 256 | { |
257 | ntpTabEnabled = display; | 257 | ntpTabEnabled = display; |
258 | 258 | ||
259 | // Create widget if it hasn't needed | 259 | // Create widget if it hasn't needed |
260 | if ( display && !ntpTab ) | 260 | if ( display && !ntpTab ) |
261 | { | 261 | { |
262 | ntpTab = new NTPTabWidget( mainWidget ); | 262 | ntpTab = new NTPTabWidget( mainWidget ); |
263 | connect( ntpTab, SIGNAL(getNTPTime()), this, SLOT(slotGetNTPTime()) ); | 263 | connect( ntpTab, SIGNAL(getNTPTime()), this, SLOT(slotGetNTPTime()) ); |
264 | } | 264 | } |
265 | 265 | ||
266 | // Display/hide tab | 266 | // Display/hide tab |
267 | display ? mainWidget->addTab( ntpTab, "netsystemtime/ntptab", tr( "Time Server" ) ) | 267 | display ? mainWidget->addTab( ntpTab, "netsystemtime/ntptab", tr( "Time Server" ) ) |
268 | : mainWidget->removePage( ntpTab ); | 268 | : mainWidget->removePage( ntpTab ); |
269 | } | 269 | } |
270 | 270 | ||
271 | void MainWindow::slotDisplayPredictTab( bool display ) | 271 | void MainWindow::slotDisplayPredictTab( bool display ) |
272 | { | 272 | { |
273 | predictTabEnabled = display; | 273 | predictTabEnabled = display; |
274 | 274 | ||
275 | // Create widget if it hasn't needed | 275 | // Create widget if it hasn't needed |
276 | if ( display && !predictTab ) | 276 | if ( display && !predictTab ) |
277 | { | 277 | { |
278 | predictTab = new PredictTabWidget( mainWidget ); | ||
278 | } | 279 | } |
279 | // Display/hide tab | 280 | // Display/hide tab |
280 | display ? mainWidget->addTab( predictTab, "netsystemtime/predicttab", tr( "Predict" ) ) | 281 | display ? mainWidget->addTab( predictTab, "netsystemtime/predicttab", tr( "Predict" ) ) |
281 | : mainWidget->removePage( predictTab ); | 282 | : mainWidget->removePage( predictTab ); |
282 | } | 283 | } |
283 | 284 | ||
284 | void MainWindow::slotGetNTPTime() | 285 | void MainWindow::slotGetNTPTime() |
285 | { | 286 | { |
286 | ntpInteractive = true; | 287 | ntpInteractive = true; |
287 | runNTP(); | 288 | runNTP(); |
288 | } | 289 | } |
289 | 290 | ||
290 | void MainWindow::slotTimerGetNTPTime() | 291 | void MainWindow::slotTimerGetNTPTime() |
291 | { | 292 | { |
292 | ntpInteractive = false; | 293 | ntpInteractive = false; |
293 | runNTP(); | 294 | runNTP(); |
294 | } | 295 | } |
295 | 296 | ||
296 | void MainWindow::slotProbeNTPServer() | 297 | void MainWindow::slotProbeNTPServer() |
297 | { | 298 | { |
298 | ntpSock->connectToHost( settingsTab->ntpServer(), 123 ); | 299 | ntpSock->connectToHost( settingsTab->ntpServer(), 123 ); |
299 | } | 300 | } |
300 | 301 | ||
301 | void MainWindow::slotNtpOutput( OProcess *, char *buffer, int buflen ) | 302 | void MainWindow::slotNtpOutput( OProcess *, char *buffer, int buflen ) |
302 | { | 303 | { |
303 | QString output = QString( buffer ).left( buflen ); | 304 | QString output = QString( buffer ).left( buflen ); |
304 | ntpOutput.append( output ); | 305 | ntpOutput.append( output ); |
305 | 306 | ||
306 | if ( ntpTabEnabled ) | 307 | if ( ntpTabEnabled ) |
307 | ntpTab->addNtpOutput( output ); | 308 | ntpTab->addNtpOutput( output ); |
308 | } | 309 | } |
309 | 310 | ||
310 | void MainWindow::slotNtpFinished( OProcess *p ) | 311 | void MainWindow::slotNtpFinished( OProcess *p ) |
311 | { | 312 | { |
312 | QString output; | 313 | QString output; |
313 | QDateTime dt = QDateTime::currentDateTime(); | 314 | QDateTime dt = QDateTime::currentDateTime(); |
314 | 315 | ||
315 | // Re-enable set time buttons & change app caption to indicate time update is happening | 316 | // Re-enable set time buttons & change app caption to indicate time update is happening |
316 | if ( ntpTabEnabled ) | 317 | if ( ntpTabEnabled ) |
317 | ntpTab->setNTPBtnEnabled( true ); | 318 | ntpTab->setNTPBtnEnabled( true ); |
318 | timeTab->setNTPBtnEnabled( true ); | 319 | timeTab->setNTPBtnEnabled( true ); |
319 | setCaption( tr( "SystemTime" ) ); | 320 | setCaption( tr( "SystemTime" ) ); |
320 | 321 | ||
321 | // Verify run was successful | 322 | // Verify run was successful |
322 | if ( p->exitStatus() != 0 ) | 323 | if ( p->exitStatus() != 0 ) |
323 | { | 324 | { |
324 | if ( isVisible() && ntpInteractive ) | 325 | if ( isVisible() && ntpInteractive ) |
325 | { | 326 | { |
326 | output = tr( "Error while getting time from\n server: " ); | 327 | output = tr( "Error while getting time from\n server: " ); |
327 | output.append( settingsTab->ntpServer() ); | 328 | output.append( settingsTab->ntpServer() ); |
328 | QMessageBox::critical(this, tr( "Error" ), output ); | 329 | QMessageBox::critical(this, tr( "Error" ), output ); |
329 | } | 330 | } |
330 | // slotCheckNtp(-1); | 331 | // slotCheckNtp(-1); |
331 | return; | 332 | return; |
332 | } | 333 | } |
333 | 334 | ||
334 | // Set controls on time tab to new time value | 335 | // Set controls on time tab to new time value |
335 | timeTab->setDateTime( dt ); | 336 | timeTab->setDateTime( dt ); |
336 | 337 | ||
337 | // Write out lookup information | 338 | // Write out lookup information |
338 | Config config( "ntp" ); | 339 | Config config( "ntp" ); |
339 | config.setGroup( "lookups" ); | 340 | config.setGroup( "lookups" ); |
340 | int lastLookup = config.readNumEntry( "time", 0 ); | 341 | int lastLookup = config.readNumEntry( "time", 0 ); |
341 | int lookupCount = config.readNumEntry( "count", 0 ); | 342 | int lookupCount = config.readNumEntry( "count", 0 ); |
342 | bool lastNtp = config.readBoolEntry( "lastNtp", false ); | 343 | bool lastNtp = config.readBoolEntry( "lastNtp", false ); |
343 | int time = TimeConversion::toUTC( QDateTime::currentDateTime() ); | 344 | int time = TimeConversion::toUTC( QDateTime::currentDateTime() ); |
344 | config.writeEntry( "time", time ); | 345 | config.writeEntry( "time", time ); |
345 | 346 | ||
346 | // Calculate new time/time shift | 347 | // Calculate new time/time shift |
347 | QString _offset = "offset"; | 348 | QString _offset = "offset"; |
348 | QString _sec = "sec"; | 349 | QString _sec = "sec"; |
349 | QRegExp _reOffset = QRegExp( _offset ); | 350 | QRegExp _reOffset = QRegExp( _offset ); |
350 | QRegExp _reEndOffset = QRegExp( _sec ); | 351 | QRegExp _reEndOffset = QRegExp( _sec ); |
351 | int posOffset = _reOffset.match( ntpOutput ); | 352 | int posOffset = _reOffset.match( ntpOutput ); |
352 | int posEndOffset = _reEndOffset.match( ntpOutput, posOffset ); | 353 | int posEndOffset = _reEndOffset.match( ntpOutput, posOffset ); |
353 | posOffset += _offset.length() + 1; | 354 | posOffset += _offset.length() + 1; |
354 | QString diff = ntpOutput.mid( posOffset, posEndOffset - posOffset - 1 ); | 355 | QString diff = ntpOutput.mid( posOffset, posEndOffset - posOffset - 1 ); |
355 | 356 | ||
356 | float timeShift = diff.toFloat(); | 357 | float timeShift = diff.toFloat(); |
357 | if ( timeShift == 0.0 ) | 358 | if ( timeShift == 0.0 ) |
358 | return; | 359 | return; |
359 | int secsSinceLast = time - lastLookup; | 360 | int secsSinceLast = time - lastLookup; |
360 | output = tr( "%1 seconds").arg(QString::number( timeShift )); | 361 | output = tr( "%1 seconds").arg(QString::number( timeShift )); |
361 | 362 | ||
362 | // Display information on time server tab | 363 | // Display information on time server tab |
363 | if ( ntpTabEnabled ) | 364 | if ( ntpTabEnabled ) |
364 | { | 365 | { |
365 | ntpTab->setTimeShift( output ); | 366 | ntpTab->setTimeShift( output ); |
366 | ntpTab->setNewTime( dt.toString() ); | 367 | ntpTab->setNewTime( dt.toString() ); |
367 | } | 368 | } |
368 | 369 | ||
369 | if ( lastNtp && lastLookup > 0 && secsSinceLast > 60 * ntpDelay ) | 370 | if ( lastNtp && lastLookup > 0 && secsSinceLast > 60 * ntpDelay ) |
370 | { | 371 | { |
371 | QString grpname = QString( "lookup_" ).append( QString::number( lookupCount ) ); | 372 | QString grpname = QString( "lookup_" ).append( QString::number( lookupCount ) ); |
372 | config.setGroup( grpname ); | 373 | config.setGroup( grpname ); |
373 | lookupCount++; | 374 | lookupCount++; |
374 | predictTab->setShiftPerSec( (int)(timeShift / secsSinceLast) ); | 375 | |
376 | if(predictTab) | ||
377 | { | ||
378 | predictTab->setShiftPerSec( (int)(timeShift / secsSinceLast) ); | ||
379 | } | ||
380 | |||
375 | config.writeEntry( "secsSinceLast", secsSinceLast ); | 381 | config.writeEntry( "secsSinceLast", secsSinceLast ); |
376 | config.writeEntry( "timeShift", QString::number( timeShift ) ); | 382 | config.writeEntry( "timeShift", QString::number( timeShift ) ); |
377 | config.setGroup( "lookups" ); | 383 | config.setGroup( "lookups" ); |
378 | config.writeEntry( "count", lookupCount ); | 384 | config.writeEntry( "count", lookupCount ); |
379 | config.writeEntry( "lastNtp", true ); | 385 | config.writeEntry( "lastNtp", true ); |
380 | } | 386 | } |
381 | } | 387 | } |
382 | 388 | ||
383 | void MainWindow::slotNTPDelayChanged( int delay ) | 389 | void MainWindow::slotNTPDelayChanged( int delay ) |
384 | { | 390 | { |
385 | ntpTimer->changeInterval( delay * 1000 * 60 ); | 391 | ntpTimer->changeInterval( delay * 1000 * 60 ); |
386 | ntpDelay = delay; | 392 | ntpDelay = delay; |
387 | } | 393 | } |
388 | 394 | ||
389 | void MainWindow::slotCheckNtp( int i ) | 395 | void MainWindow::slotCheckNtp( int i ) |
390 | { | 396 | { |
391 | if ( i == 0 ) | 397 | if ( i == 0 ) |
392 | { | 398 | { |
393 | if ( ntpDelayElapsed() ) | 399 | if ( ntpDelayElapsed() ) |
394 | { | 400 | { |
395 | runNTP(); | 401 | runNTP(); |
396 | disconnect( ntpTimer, SIGNAL(timeout()), this, SLOT(slotProbeNTPServer()) ); | 402 | disconnect( ntpTimer, SIGNAL(timeout()), this, SLOT(slotProbeNTPServer()) ); |
397 | connect( ntpTimer, SIGNAL(timeout()), SLOT(slotTimerGetNTPTime()) ); | 403 | connect( ntpTimer, SIGNAL(timeout()), SLOT(slotTimerGetNTPTime()) ); |
398 | } | 404 | } |
399 | else | 405 | else |
400 | { | 406 | { |
401 | disconnect(ntpTimer, SIGNAL(timeout()), this, SLOT(slotTimerGetNTPTime()) ); | 407 | disconnect(ntpTimer, SIGNAL(timeout()), this, SLOT(slotTimerGetNTPTime()) ); |
402 | connect(ntpTimer, SIGNAL(timeout()), SLOT(slotProbeNTPServer()) ); | 408 | connect(ntpTimer, SIGNAL(timeout()), SLOT(slotProbeNTPServer()) ); |
403 | } | 409 | } |
404 | } | 410 | } |
405 | else | 411 | else |
406 | { | 412 | { |
407 | predictTab->slotPredictTime(); | 413 | if(predictTab) |
414 | { | ||
415 | predictTab->slotPredictTime(); | ||
416 | } | ||
417 | |||
408 | if ( i > 0 ) | 418 | if ( i > 0 ) |
409 | { | 419 | { |
410 | QString output = tr( "Could not connect to server " ); | 420 | QString output = tr( "Could not connect to server " ); |
411 | output.append( settingsTab->ntpServer() ); | 421 | output.append( settingsTab->ntpServer() ); |
412 | ntpOutput.append( output ); | 422 | ntpOutput.append( output ); |
413 | if ( ntpTabEnabled ) | 423 | if ( ntpTabEnabled ) |
414 | ntpTab->addNtpOutput( output ); | 424 | ntpTab->addNtpOutput( output ); |
415 | } | 425 | } |
416 | connect( ntpTimer, SIGNAL(timeout()), SLOT(slotProbeNTPServer()) ); | 426 | connect( ntpTimer, SIGNAL(timeout()), SLOT(slotProbeNTPServer()) ); |
417 | } | 427 | } |
418 | } | 428 | } |