author | zautrix <zautrix> | 2005-01-19 11:41:45 (UTC) |
---|---|---|
committer | zautrix <zautrix> | 2005-01-19 11:41:45 (UTC) |
commit | 0d878a0144644499ead17b2532cc94abb545bcdb (patch) (unidiff) | |
tree | 241010225cf2b26847750c5f511ff15a9ebef9e1 | |
parent | af56077eeeab7b46b98ad5159c6653114abf6602 (diff) | |
download | kdepimpi-0d878a0144644499ead17b2532cc94abb545bcdb.zip kdepimpi-0d878a0144644499ead17b2532cc94abb545bcdb.tar.gz kdepimpi-0d878a0144644499ead17b2532cc94abb545bcdb.tar.bz2 |
translation added
-rw-r--r-- | bin/kdepim/WhatsNew.txt | 6 | ||||
-rw-r--r-- | bin/kdepim/pwmanager/germantranslation.txt | 353 | ||||
-rw-r--r-- | korganizer/kolistview.cpp | 3 | ||||
-rw-r--r-- | pwmanager/pwmanager/main.cpp | 2 | ||||
-rw-r--r-- | pwmanager/pwmanager/pwminit.cpp | 5 |
5 files changed, 366 insertions, 3 deletions
diff --git a/bin/kdepim/WhatsNew.txt b/bin/kdepim/WhatsNew.txt index 23ff53c..5c36415 100644 --- a/bin/kdepim/WhatsNew.txt +++ b/bin/kdepim/WhatsNew.txt | |||
@@ -1,135 +1,141 @@ | |||
1 | Info about the changes in new versions of KDE-Pim/Pi | 1 | Info about the changes in new versions of KDE-Pim/Pi |
2 | 2 | ||
3 | ********** VERSION 1.9.19 ************ | 3 | ********** VERSION 1.9.19 ************ |
4 | 4 | ||
5 | Added a lot of missing translations to KA/Pi, | 5 | Added a lot of missing translations to KA/Pi, |
6 | added some missing translations to KO/Pi and OM/Pi. | 6 | added some missing translations to KO/Pi and OM/Pi. |
7 | 7 | ||
8 | Fixed some minor problems in KA/Pi + KO/Pi. | ||
9 | |||
10 | Fixed a crash when closing PwM/Pi. | ||
11 | Added German translation for PwM/Pi. | ||
12 | |||
13 | |||
8 | ********** VERSION 1.9.18 ************ | 14 | ********** VERSION 1.9.18 ************ |
9 | 15 | ||
10 | FYI: The VERSION 1.9.17 was a testing release only. | 16 | FYI: The VERSION 1.9.17 was a testing release only. |
11 | Please read the changelog of VERSION 1.9.17 as well. | 17 | Please read the changelog of VERSION 1.9.17 as well. |
12 | 18 | ||
13 | Cleaned up the syncing config dialog. | 19 | Cleaned up the syncing config dialog. |
14 | Added sync config options for date range for events. | 20 | Added sync config options for date range for events. |
15 | Added sync config options for filters on incoming data. | 21 | Added sync config options for filters on incoming data. |
16 | Added sync config options for filters on outgoing data. | 22 | Added sync config options for filters on outgoing data. |
17 | Please read the updated SyncHowTo about the new filter settings. | 23 | Please read the updated SyncHowTo about the new filter settings. |
18 | These filter settings make it now possible to sync with shared | 24 | These filter settings make it now possible to sync with shared |
19 | calendars without writing back private or confidential data | 25 | calendars without writing back private or confidential data |
20 | (via the outgoing filters). | 26 | (via the outgoing filters). |
21 | To sync only with particular parts of a shared calendar, | 27 | To sync only with particular parts of a shared calendar, |
22 | the incoming filter settings can be used. | 28 | the incoming filter settings can be used. |
23 | An example can be found in the SyncHowTo. | 29 | An example can be found in the SyncHowTo. |
24 | Same for shared addressbooks. | 30 | Same for shared addressbooks. |
25 | 31 | ||
26 | Added a setting for the global kdepim data storage. | 32 | Added a setting for the global kdepim data storage. |
27 | Usually the data is stored in (yourhomedir/kdepim). | 33 | Usually the data is stored in (yourhomedir/kdepim). |
28 | Now you can set in the Global config dialog TAB, subTAB "Data storage path" | 34 | Now you can set in the Global config dialog TAB, subTAB "Data storage path" |
29 | a directory where all the kdepim data is stored. | 35 | a directory where all the kdepim data is stored. |
30 | That makes it easy to save all kdepim data on a SD card on the Z, for example. | 36 | That makes it easy to save all kdepim data on a SD card on the Z, for example. |
31 | 37 | ||
32 | KO/Pi: | 38 | KO/Pi: |
33 | The timeedit input has a pulldown list for times. | 39 | The timeedit input has a pulldown list for times. |
34 | If opened, this pulldown list should now has the right time highlighted. | 40 | If opened, this pulldown list should now has the right time highlighted. |
35 | Added the possibility to exclude events/todos/journals in a filter. | 41 | Added the possibility to exclude events/todos/journals in a filter. |
36 | You should exclude journals, if you do not want them to sync with a public calendar. | 42 | You should exclude journals, if you do not want them to sync with a public calendar. |
37 | 43 | ||
38 | KA/Pi: | 44 | KA/Pi: |
39 | Added the possibility to in/exclude public/private/confidential contacts to a filter. | 45 | Added the possibility to in/exclude public/private/confidential contacts to a filter. |
40 | If you have already defined filterrules in KA/Pi you have to adjust them all by setting the "include public/private/confidential" property manually. Sorry for that ... | 46 | If you have already defined filterrules in KA/Pi you have to adjust them all by setting the "include public/private/confidential" property manually. Sorry for that ... |
41 | Added printing of card view and details view on desktop. | 47 | Added printing of card view and details view on desktop. |
42 | Printing of list view is not working... | 48 | Printing of list view is not working... |
43 | Added button for removing pictures in contact editor. | 49 | Added button for removing pictures in contact editor. |
44 | Parsing data fix of KA/Pi version 1.9.17. | 50 | Parsing data fix of KA/Pi version 1.9.17. |
45 | Fixed the "parse name automatically" problem of KA/Pi version 1.9.17. | 51 | Fixed the "parse name automatically" problem of KA/Pi version 1.9.17. |
46 | Fixed some syncing merging problems. | 52 | Fixed some syncing merging problems. |
47 | 53 | ||
48 | 54 | ||
49 | ********** VERSION 1.9.17 ************ | 55 | ********** VERSION 1.9.17 ************ |
50 | 56 | ||
51 | KO/Pi: | 57 | KO/Pi: |
52 | Fixed that tooltips were not updated after moving an item in agenda view. | 58 | Fixed that tooltips were not updated after moving an item in agenda view. |
53 | Fixed a bug in sorting start date for recurring events in list view. | 59 | Fixed a bug in sorting start date for recurring events in list view. |
54 | Changed the left button in todo viewer from "Agenda" to "Set completed". | 60 | Changed the left button in todo viewer from "Agenda" to "Set completed". |
55 | This makes it possible to change a todo in the What's Next View quickly to the completed state without leaving the What's Next View. | 61 | This makes it possible to change a todo in the What's Next View quickly to the completed state without leaving the What's Next View. |
56 | Added more info in the todo viewer: Startdate, parent/sub todos. | 62 | Added more info in the todo viewer: Startdate, parent/sub todos. |
57 | 63 | ||
58 | 64 | ||
59 | KA/Pi: | 65 | KA/Pi: |
60 | All fields search does now actually search all the (possible) fields, | 66 | All fields search does now actually search all the (possible) fields, |
61 | not only those listed in the contact list. | 67 | not only those listed in the contact list. |
62 | Made is possible to inline a picture in a vcard on the Z. | 68 | Made is possible to inline a picture in a vcard on the Z. |
63 | This was only possible on the desktop, now is it possible on the Z as well. | 69 | This was only possible on the desktop, now is it possible on the Z as well. |
64 | Fixed of missing save settings after filter configuration. | 70 | Fixed of missing save settings after filter configuration. |
65 | Made saving of addressbook much faster. | 71 | Made saving of addressbook much faster. |
66 | Fixed extension widget layout problem. | 72 | Fixed extension widget layout problem. |
67 | Fixed saving of default formatted name settings. | 73 | Fixed saving of default formatted name settings. |
68 | Fixed formatted name handling in edit dialog. | 74 | Fixed formatted name handling in edit dialog. |
69 | Added an option for changing formatted names of many contacts | 75 | Added an option for changing formatted names of many contacts |
70 | (menu: File - Change - Set formatted name). | 76 | (menu: File - Change - Set formatted name). |
71 | 77 | ||
72 | QWhatsThis was not working on the Z ( only black rectangle was shown). | 78 | QWhatsThis was not working on the Z ( only black rectangle was shown). |
73 | This is Fixed. | 79 | This is Fixed. |
74 | 80 | ||
75 | KDE-Sync: | 81 | KDE-Sync: |
76 | Now readonly KDE resources are synced as well. | 82 | Now readonly KDE resources are synced as well. |
77 | (They are not changed in KDE itself, of course). | 83 | (They are not changed in KDE itself, of course). |
78 | 84 | ||
79 | 85 | ||
80 | 86 | ||
81 | ********** VERSION 1.9.16 ************ | 87 | ********** VERSION 1.9.16 ************ |
82 | 88 | ||
83 | KO/Pi: | 89 | KO/Pi: |
84 | Fixed search dialog size on Z 6000 (480x640 display). | 90 | Fixed search dialog size on Z 6000 (480x640 display). |
85 | Added setting to hide/show time in agenda items. | 91 | Added setting to hide/show time in agenda items. |
86 | Added setting to hide not running todos in todo view. | 92 | Added setting to hide not running todos in todo view. |
87 | Added columns for start date/time in todo view. | 93 | Added columns for start date/time in todo view. |
88 | Replaced the solid half-hour lines in agenda view by dot lines. | 94 | Replaced the solid half-hour lines in agenda view by dot lines. |
89 | Added possibility of printing the What's Next View on the desktop | 95 | Added possibility of printing the What's Next View on the desktop |
90 | (i.e. Windows and Linux). | 96 | (i.e. Windows and Linux). |
91 | Fixed a crash in KO/Pi when starting KO/Pi with What's Next view. | 97 | Fixed a crash in KO/Pi when starting KO/Pi with What's Next view. |
92 | Added tooltips in month view.(Tooltips only available on desktop) | 98 | Added tooltips in month view.(Tooltips only available on desktop) |
93 | 99 | ||
94 | Fixed a strange problem in KO/Pi alarm applet. | 100 | Fixed a strange problem in KO/Pi alarm applet. |
95 | Did not find the actual problem, | 101 | Did not find the actual problem, |
96 | such that now Qtopia reboots again if deinstalling the alarm applet. | 102 | such that now Qtopia reboots again if deinstalling the alarm applet. |
97 | But the alarm applet should work again. | 103 | But the alarm applet should work again. |
98 | 104 | ||
99 | KA/Pi: | 105 | KA/Pi: |
100 | Fixed the problem, that internal pictures were not saved. | 106 | Fixed the problem, that internal pictures were not saved. |
101 | 107 | ||
102 | Fixed a problem in the pi-sync mode by increasing the timeout for data transfer from 20 seconds to 5 minutes. | 108 | Fixed a problem in the pi-sync mode by increasing the timeout for data transfer from 20 seconds to 5 minutes. |
103 | 109 | ||
104 | Fixed some minor problems. (Like word wrap in help text windows). | 110 | Fixed some minor problems. (Like word wrap in help text windows). |
105 | 111 | ||
106 | Fixed a compiling problem in microkde/kresources. | 112 | Fixed a compiling problem in microkde/kresources. |
107 | 113 | ||
108 | KO/Pi is using zdbat (renamed to db2file) for syncing with Sharp DTM. | 114 | KO/Pi is using zdbat (renamed to db2file) for syncing with Sharp DTM. |
109 | This version now includes zdbat 1.0.0 (old version was zdbat 0.2.9) | 115 | This version now includes zdbat 1.0.0 (old version was zdbat 0.2.9) |
110 | such that now syncing KO/Pi with Sharp DTM should work on the | 116 | such that now syncing KO/Pi with Sharp DTM should work on the |
111 | Zaurus C 3000 model. | 117 | Zaurus C 3000 model. |
112 | 118 | ||
113 | ********** VERSION 1.9.15 ************ | 119 | ********** VERSION 1.9.15 ************ |
114 | 120 | ||
115 | Usebilty enhancements in KO/Pi: | 121 | Usebilty enhancements in KO/Pi: |
116 | When clicking on the date in a month view cell, the day view is shown. | 122 | When clicking on the date in a month view cell, the day view is shown. |
117 | Old behaviour was, that the "new event" dialog popped up. | 123 | Old behaviour was, that the "new event" dialog popped up. |
118 | 124 | ||
119 | Added a one step "undo delete" in KO/Pi (Accessable in the "Action" menu). | 125 | Added a one step "undo delete" in KO/Pi (Accessable in the "Action" menu). |
120 | That means, you can restore the latest | 126 | That means, you can restore the latest |
121 | event/todo/journal you have deleted. | 127 | event/todo/journal you have deleted. |
122 | A journal is deleted, if you clear all the text of the journal. | 128 | A journal is deleted, if you clear all the text of the journal. |
123 | 129 | ||
124 | Fixed the bug of the editor dialogs in KO/Pi of version 1.9.14. | 130 | Fixed the bug of the editor dialogs in KO/Pi of version 1.9.14. |
125 | 131 | ||
126 | KA/Pi starting in 480x640 resolution: | 132 | KA/Pi starting in 480x640 resolution: |
127 | Hide the filter action in toolbar | 133 | Hide the filter action in toolbar |
128 | and added icons for undo/delete/redo in toolbar. | 134 | and added icons for undo/delete/redo in toolbar. |
129 | 135 | ||
130 | Change in OM/Pi ViewMail dialog: | 136 | Change in OM/Pi ViewMail dialog: |
131 | When clicking on the "delete" icon the mail is deleted after confirmation as usual. | 137 | When clicking on the "delete" icon the mail is deleted after confirmation as usual. |
132 | But the edit dialog is not closed as before, now the next mail in the folder is shown automatically (if there is any). | 138 | But the edit dialog is not closed as before, now the next mail in the folder is shown automatically (if there is any). |
133 | 139 | ||
134 | Fixed a crash when deleting mail-accounts in OM/Pi. | 140 | Fixed a crash when deleting mail-accounts in OM/Pi. |
135 | 141 | ||
diff --git a/bin/kdepim/pwmanager/germantranslation.txt b/bin/kdepim/pwmanager/germantranslation.txt new file mode 100644 index 0000000..5941c2a --- a/dev/null +++ b/bin/kdepim/pwmanager/germantranslation.txt | |||
@@ -0,0 +1,353 @@ | |||
1 | { " Local Time","Ortszeit" }, | ||
2 | { "Default","Voreinstellungen" }, | ||
3 | { "Configure...","Konfigurieren..." }, | ||
4 | { "Remove sync info","Entferne Sync Info" }, | ||
5 | { "For all profiles","Für alle Profile" }, | ||
6 | { "Enable Pi-Sync","Aktiviere Pi-Sync" }, | ||
7 | { "Multiple sync","Multi Sync" }, | ||
8 | { "&Save","&Speichern" }, | ||
9 | { "&Print...","Drucken..." }, | ||
10 | { "&File","Datei" }, | ||
11 | { "&Edit","Bearbeite" }, | ||
12 | { "&View","Ansichten" }, | ||
13 | { "&Help","Hilfe" }, | ||
14 | { "Description","Beschreibungen" }, | ||
15 | { "URL","URL" }, | ||
16 | { "Name:","Name:" }, | ||
17 | { "Documents","Dokumente" }, | ||
18 | { "Files","Dateien" }, | ||
19 | { "All Files","Alle Dateien" }, | ||
20 | { "Name","Name" }, | ||
21 | { "Size","Größe" }, | ||
22 | { "Date","Datum" }, | ||
23 | { "Mime Type","Mime Typ" }, | ||
24 | { "Ok","Ok" }, | ||
25 | { "Cancel","Abbrechen" }, | ||
26 | { "1","1" }, | ||
27 | { "Synchronization Preferences","Einstellungen der Synchronisationsprofile" }, | ||
28 | { "Local device name:","Name dieses Gerätes:" }, | ||
29 | { "New profile","Neues Profil" }, | ||
30 | { "Clone profile","Klone Profil" }, | ||
31 | { "Delete profile","Lösche Profil" }, | ||
32 | { "Profile:","Profil:" }, | ||
33 | { "Multiple Sync options","Multi Sync Optionen" }, | ||
34 | { "Include in multiple ","Beziehe in mehrfach " }, | ||
35 | { "calendar ","Kalender " }, | ||
36 | { "addressbook ","Adressbuch " }, | ||
37 | { "pwmanager","PWmanager" }, | ||
38 | { " sync"," Sync ein" }, | ||
39 | { "Sync algo options","Sync Ablauf Optionen" }, | ||
40 | { "Ask for preferences before sync","Frage nach Synchronisationseinstellungen vor dem Syncen" }, | ||
41 | { "Sync preferences","Synchronisations Einstellungen" }, | ||
42 | { "Take local entry on conflict","Nimm lokalen Eintrag beim Konflikt" }, | ||
43 | { "Take remote entry on conflict","Nimm fernen Eintrag beim Konflikt" }, | ||
44 | { "Take newest entry on conflict","Nimm neuesten Eintrag beim Konflikt" }, | ||
45 | { "Ask for every entry on conflict","Frage bei Konflikten nach" }, | ||
46 | { "Force: Take local entry always","Erzwinge: Nimm immer lokalen Eintrag" }, | ||
47 | { "Force: Take remote entry always","Erzwinge: Nimm immer fernen Eintrag" }, | ||
48 | { "Show summary after sync","Zeige Zusammenfassung nach dem Synchronisieren" }, | ||
49 | { "Apply filter when adding data to local:","Filter für das Hinzufügen von Daten zu Lokal:" }, | ||
50 | { "Incoming calendar filter:","Eingehender Kalender Filter:" }, | ||
51 | { "Incoming addressbook filter:","Eingehender Adressbuch Filter:" }, | ||
52 | { "Write back synced data","Schreibe gesyncte Daten zurück" }, | ||
53 | { "Write back options","Optionen zum Zurückschreiben" }, | ||
54 | { "Write back (on remote) existing entries only","Schreibe nur existierende (auf Entfernt) Einträge zurück" }, | ||
55 | { "Apply filter when adding data to remote:","Filter für das Hinzufügen von Daten zu Entfernt:" }, | ||
56 | { "Outgoing calendar filter:","Ausgehender Kalender Filter:" }, | ||
57 | { "Outgoing addressbook filter:","Ausgehender Adressbuch Filter:" }, | ||
58 | { "Write back (calendar) entries for time period only","Schreibe nur Kalender Einträge für Zeitspanne zurück" }, | ||
59 | { "Time period","Zeitspanne" }, | ||
60 | { "From ","Von " }, | ||
61 | { " weeks in the past to "," Wochen in der Vergangenheit bis zu " }, | ||
62 | { " weeks in the future "," Wochen in der Zukunft " }, | ||
63 | { "Profile kind","Profil Art" }, | ||
64 | { "Local file","Lokale Datei" }, | ||
65 | { "Pi-Sync ( direct Kx/Pi to Kx/Pi sync )","Pi-Sync ( direktes Kx/Pi zu Kx/Pi sync )" }, | ||
66 | { "Remote file (w down/upload command)","Entfernte Datei (via down/upload Kommando)" }, | ||
67 | { "Mobile device (cell phone)","Mobiles Gerät (Handy)" }, | ||
68 | { "Profile kind specific settings","Profil Art abhängige Einstellungen" }, | ||
69 | { "I/O device: ","I/O device: " }, | ||
70 | { "Help...","Hilfe..." }, | ||
71 | { "Connection: ","Connection: " }, | ||
72 | { "Model(opt.): ","Model(opt.): " }, | ||
73 | { "Local file Cal:","Lokale Datei Kal:" }, | ||
74 | { "Local file ABook:","Lokale Datei ABuch:" }, | ||
75 | { "Local file PWMgr:","Lokale Datei PWMgr:" }, | ||
76 | { "Choose...","Wähle..." }, | ||
77 | { "Addressbook file (*.vcf) is used by KA/Pi","Adressbuch Datei (*.vcf) wird von KA/Pi genutzt" }, | ||
78 | { "Calendar:","Kalender:" }, | ||
79 | { "AddressBook:","AdressBuch:" }, | ||
80 | { "PWManager:","PWManager:" }, | ||
81 | { "Pre sync (download) command:","Bevor Sync (download) Kommando:" }, | ||
82 | { "Local temp file:","Lokale temp Datei:" }, | ||
83 | { "Post sync (upload) command:","Nach Sync (upload) Kommando:" }, | ||
84 | { "Addressbook file is used by KA/Pi","Adressbuch Datei wird von KA/Pi genutzt" }, | ||
85 | { "Fill in default values for:","Setze Beispiel Werte ein für:" }, | ||
86 | { "ssh/scp","ssh/scp" }, | ||
87 | { "ftp","ftp" }, | ||
88 | { "Hint: Use $PWD$ for placeholder of password!","Hinweis: Benutze $PWD$ als Platzhalter für ein Passwort!" }, | ||
89 | { "Password for remote access: (could be the same for each)","Passwort für entfernten Zugriff: (kann dasselbe sein für alle)" }, | ||
90 | { "Remote IP address: (could be the same for each)","Entfernte IP Adresse: (kann dasselbe sein für alle)" }, | ||
91 | { "Remote port number: (should be different for each)","Entfernte Port Nummer: (Sollte für alle unterschiedlich sein)" }, | ||
92 | { "command for downloading remote file to local device","Kommando zum Download der entfernten Datei zum lokalen Gerät" }, | ||
93 | { "command for uploading local temp file to remote device","Kommando zum Upload der lokalen temp. Datei zum entfernten Gerät" }, | ||
94 | { "No Filter","Kein Filter" }, | ||
95 | { "KO/Pi config error","KO/Pi Konfig. Fehler" }, | ||
96 | { "Local device name undefined!\nPlease define device name!","Name dieses Gerätes undefiniert!\nBitte Namen angeben!" }, | ||
97 | { "Multiple profiles with same name!\nPlease use unique profile names!","Mehrere Profile mit demselben Namen!\nBitte verschiedene Namen benutzen!" }, | ||
98 | { "Configure","Konfiguriere" }, | ||
99 | { "Apply","Anwenden" }, | ||
100 | { "None","Kein" }, | ||
101 | { "Global","Allgemein" }, | ||
102 | { "Email","E-Mail" }, | ||
103 | { "Phone","Telefon" }, | ||
104 | { "SMS","SMS" }, | ||
105 | { "Fax","Fax" }, | ||
106 | { "Pager","Pager" }, | ||
107 | { "SIP","SIP" }, | ||
108 | { "Language:(needs restart)","Sprache:(Neustart)" }, | ||
109 | { "English","English" }, | ||
110 | { "German","Deutsch" }, | ||
111 | { "French","Französisch" }, | ||
112 | { "Italian","Italienisch" }, | ||
113 | { "User defined (usertranslation.txt)","Benutzerdef. (usertranslation.txt)" }, | ||
114 | { "Language","Sprache" }, | ||
115 | { "Time Format(nr):","Zeit Format(nr):" }, | ||
116 | { "24:00","24:00" }, | ||
117 | { "12:00am","12:00am" }, | ||
118 | { "Week starts on Sunday","Woche beginnt Sonntags" }, | ||
119 | { "Time Format","Zeit Format" }, | ||
120 | { "Date Format:","Datums Format:" }, | ||
121 | { "24.03.2004 (%d.%m.%Y|%A %d %B %Y)","24.03.2004 (%d.%m.%Y|%A %d %B %Y)" }, | ||
122 | { "03.24.2004 (%m.%d.%Y|%A %B %d %Y)","03.24.2004 (%m.%d.%Y|%A %B %d %Y)" }, | ||
123 | { "2004-03-24 (%Y-%m-%d|%A %Y %B %d)","2004-03-24 (%Y-%m-%d|%A %Y %B %d)" }, | ||
124 | { "User defined","Benutzerdefiniert" }, | ||
125 | { "User long date:","Format langes Datum:" }, | ||
126 | { "User short date:","Format kurzes Datum:" }, | ||
127 | { "Monday 19 April 2004: %A %d %B %Y","Monday 19 April 2004: %A %d %B %Y" }, | ||
128 | { "Mon 19.04.04: %a %d.%m.%y","Mon 19.04.04: %a %d.%m.%y" }, | ||
129 | { "Mon, 19.Apr.04: %a, %d.%b.%y","Mon, 19.Apr.04: %a, %d.%b.%y" }, | ||
130 | { "Date Format","Datums Format" }, | ||
131 | { "Timezone:","Zeitzone:" }, | ||
132 | { "Add 30 min to selected Timezone","Addiere 30 min zur Zeitzone" }, | ||
133 | { "Timezone has daylight saving","Zeitzone hat Sommerzeit" }, | ||
134 | { "Actual start and end is the\nsunday before this date.","Tatsächlicher Beginn/Ende ist der\nSonntag vor diesem Datum!" }, | ||
135 | { "The year in the date is ignored.","Das Jahr vom Datum wird ignoriert." }, | ||
136 | { "Daylight start:","Sommerzeit Beginn:" }, | ||
137 | { "Mon","Mo" }, | ||
138 | { "Tue","Di" }, | ||
139 | { "Wed","Mi" }, | ||
140 | { "Thu","Do" }, | ||
141 | { "Fri","Fr" }, | ||
142 | { "Sat","Sa" }, | ||
143 | { "Sun","So" }, | ||
144 | { "January","Januar" }, | ||
145 | { "February","Februar" }, | ||
146 | { "March","März" }, | ||
147 | { "April","April" }, | ||
148 | { "May","Mai" }, | ||
149 | { "June","Juni" }, | ||
150 | { "July","July" }, | ||
151 | { "August","August" }, | ||
152 | { "September","September" }, | ||
153 | { "October","October" }, | ||
154 | { "November","November" }, | ||
155 | { "December","Dezember" }, | ||
156 | { "tomorrow","Morgen" }, | ||
157 | { "today","Heute" }, | ||
158 | { "yesterday","Gestern" }, | ||
159 | { "Monday","Montag" }, | ||
160 | { "Tuesday","Dienstag" }, | ||
161 | { "Wednesday","Mittwoch" }, | ||
162 | { "Thursday","Donnerstag" }, | ||
163 | { "Friday","Freitag" }, | ||
164 | { "Saturday","Samstag" }, | ||
165 | { "Sunday","Sonntag" }, | ||
166 | { "Daylight end:","Sommerzeit Ende:" }, | ||
167 | { "Time Zone","Zeit Zone" }, | ||
168 | { "Used Mail Client","Benutzter Mail Client" }, | ||
169 | { "Channel:","Channel:" }, | ||
170 | { "Message:","Message:" }, | ||
171 | { "Parameters:","Parameter:" }, | ||
172 | { "HINT: Delimiter=; Name=%1,Email=%2","Hinweis: Begrenzer=; Name=%1,Email=%2" }, | ||
173 | { "extra Message:","extra Message:" }, | ||
174 | { "extra Parameters:","extra Parameter:" }, | ||
175 | { "HINT: Emails=%1,Attachments=%2","Hinweis: Emails=%1,Attachments=%2" }, | ||
176 | { "External Apps.","Externe Appl." }, | ||
177 | { "Your current storage dir is:\n%1\nYour mail is stored in:\n(storagedir)/apps/kopiemail/localmail","Ihr gerade genutztes Speicherverzeichnis ist:\n%1\nIhre Mail wird gespeichert in:\n(speicherverzeichnis)/apps/kopiemail/localmail" }, | ||
178 | { "<b>Set new data storage dir:</b>","<b>Setze neues Datenspeicherverzeichnis:</b>" }, | ||
179 | { "Not existing dirs are created automatically","Nicht existierende Verzeichnisse werden erstellt" }, | ||
180 | { "Save settings","Speichere Einstellungen" }, | ||
181 | { "Save standard","Speichere Standard" }, | ||
182 | { "<b>New settings are used\nafter a restart</b>","<b>Neue Einstellungen werden nach\neinem Neustart genutzt</b>" }, | ||
183 | { "The settings of the storage\ndir is saved in the file\n%1","Die Einstellungen des Speicherverzeichnisses\nwerden in folgender Datei gespeichert:\n%1" }, | ||
184 | { "Data storage path","Daten Speicherpfad" }, | ||
185 | { "Used %1 Client","Benutzer %1 Client" }, | ||
186 | { "No email client installed","Keine Email Client installiert" }, | ||
187 | { "Userdefined email client","Benutzerdef. Email Client" }, | ||
188 | { "OM/Pi email client","OM/Pi Email Client" }, | ||
189 | { "URL:","URL:" }, | ||
190 | { "No","Nein" }, | ||
191 | { "Yes","Ja" }, | ||
192 | { "Untitled","Unbenannt" }, | ||
193 | { "&New","&Neu" }, | ||
194 | { "&Open","&Öffne" }, | ||
195 | { "&Close","Schließen" }, | ||
196 | { "Save &as...","Speichere &als..." }, | ||
197 | { "&Text-file...","&Text-Datei..." }, | ||
198 | { "&Gpasman / Kpasman ...","&Gpasman / Kpasman ..." }, | ||
199 | { "&CSV (Comma Separated Value) ...","&CSV (Komma getrennte Werte) ..." }, | ||
200 | { "E&xport","E&xport" }, | ||
201 | { "I&mport","I&mport" }, | ||
202 | { "&Quit","Beenden" }, | ||
203 | { "&Add password","&Passwort hinzufügen" }, | ||
204 | { "&Delete","Lösche" }, | ||
205 | { "Change &Master Password","Ändere &Master Passwort" }, | ||
206 | { "&Manage","Verwalte" }, | ||
207 | { "&Find","&Finde" }, | ||
208 | { "&Lock all entries","Sperre alle Einträge" }, | ||
209 | { "&Deep-lock all entries","Sperre total alle Einträge" }, | ||
210 | { "&Unlock all entries","Entsperre alle Einträge" }, | ||
211 | { "&Configure...","Konfiguriere..." }, | ||
212 | { "&Options","&Optionen" }, | ||
213 | { "C&ategories...","K&ategorien..." }, | ||
214 | { "&Sync","&Sync" }, | ||
215 | { "&License","&Lizenz" }, | ||
216 | { "&Faq","&Faq" }, | ||
217 | { "&About PwManager","Über PwManager" }, | ||
218 | { "&Sync HowTo","&Sync HowTo" }, | ||
219 | { "&What's New","Was ist neu?" }, | ||
220 | { "New","Neu" }, | ||
221 | { "Open","Öffnen" }, | ||
222 | { "Save","Speichern" }, | ||
223 | { "Save as","Speichern als" }, | ||
224 | { "Print...","Drucke..." }, | ||
225 | { "Add password","Passwort hinzufügen" }, | ||
226 | { "Edit password","Passwort ändern" }, | ||
227 | { "Delete password","Passwort löschen" }, | ||
228 | { "Find entry","Finde Eintrag" }, | ||
229 | { "Lock all entries","Sperre alle Einträge" }, | ||
230 | { "Deep-Lock all entries","Sperre total alle Einträge" }, | ||
231 | { "Unlock all entries","Entsperre alle Einträge" }, | ||
232 | { "Categories:","Kategorien:" }, | ||
233 | { "&Rename","&Umbenennen" }, | ||
234 | { "Username","Benutzername" }, | ||
235 | { "Password","Passwort" }, | ||
236 | { "Launcher","Launcher" }, | ||
237 | { "copy password to clipboard","Kopiere Passwort ins Clipboard" }, | ||
238 | { "copy username to clipboard","Kopiere Benutzername ins Clipboard" }, | ||
239 | { "copy description to clipboard","Kopiere Beschreibung ins Clipboard" }, | ||
240 | { "copy url to clipboard","Kopiere URL ins Clipboard" }, | ||
241 | { "copy launcher to clipboard","Kopiere Launcher ins Clipboard" }, | ||
242 | { "copy comment to clipboard","Kopiere Kommentare ins Clipboard" }, | ||
243 | { "Execute "Launcher"",""Launcher" ausführen" }, | ||
244 | { "Go to "URL"","Gehe zu "URL"" }, | ||
245 | { "Ready.","Fertig." }, | ||
246 | { "password filename(*.pwm)","passwort dateiname(*.pwm)" }, | ||
247 | { "File error","Datei Fehler" }, | ||
248 | { "Could not read file!","Kann Datei nicht lesen!" }, | ||
249 | { "Master-password","Master-Passwort" }, | ||
250 | { "Please enter the master-password:","Bitter Master-Passwort eingeben:" }, | ||
251 | { "Wrong master-password!\nPlease try again.","Falsches Master-Passwort!\nBitte erneut versuchen." }, | ||
252 | { "password error","Passwort Fehler" }, | ||
253 | { "Successfully opened file.","Datei erfolgreich geöffnet." }, | ||
254 | { "DEEP-LOCKED","DEEP-LOCKED" }, | ||
255 | { "This file is DEEP-LOCKED!\nThat means all data has been encrypted\nand written out to the file. If you want\nto see the entries, please UNLOCK the file.\nWhile unlocking, you will be prompted for the\nmaster-password or the key-card.","This file is DEEP-LOCKED!\nThat means all data has been encrypted\nand written out to the file. If you want\nto see the entries, please UNLOCK the file.\nWhile unlocking, you will be prompted for the\nmaster-password or the key-card." }, | ||
256 | { "<LOCKED>","<GESPERRT>" }, | ||
257 | { "To unlock click the icon on the left.","Zum Entsperren klicke auf das linke Icon." }, | ||
258 | { "PwManager","PwManager" }, | ||
259 | { "Window-style:","Window-style:" }, | ||
260 | { "Category on top","Kategorien oben" }, | ||
261 | { "Category-list left/top","Kategorien links oben" }, | ||
262 | { "<b>Font for Password entries:</b>","<b>Schrift für Passwort Einträge:</b>" }, | ||
263 | { "Font:","Schriftart:" }, | ||
264 | { "Compression:","Kompression:" }, | ||
265 | { "gzip","gzip" }, | ||
266 | { "Encryption:","Verschlüsselung:" }, | ||
267 | { "Blowfish (128 bit)","Blowfish (128 bit)" }, | ||
268 | { "AES-128, Rijndael (128 bit)","AES-128, Rijndael (128 bit)" }, | ||
269 | { "AES-192, Rijndael (192 bit)","AES-192, Rijndael (192 bit)" }, | ||
270 | { "AES-256, Rijndael (256 bit)","AES-256, Rijndael (256 bit)" }, | ||
271 | { "Triple-DES (168 bit)","Triple-DES (168 bit)" }, | ||
272 | { "Twofish (256 bit)","Twofish (256 bit)" }, | ||
273 | { "Twofish-128 (128 bit)","Twofish-128 (128 bit)" }, | ||
274 | { "Hashing:","Hashing:" }, | ||
275 | { "SHA-160, SHA1 (160 bit)","SHA-160, SHA1 (160 bit)" }, | ||
276 | { "SHA-256 (256 bit)","SHA-256 (256 bit)" }, | ||
277 | { "SHA-384 (384 bit)","SHA-384 (384 bit)" }, | ||
278 | { "SHA-512 (512 bit)","SHA-512 (512 bit)" }, | ||
279 | { "MD5 (128 bit)","MD5 (128 bit)" }, | ||
280 | { "RIPE-MD-160 (160 bit)","RIPE-MD-160 (160 bit)" }, | ||
281 | { "Tiger (192 bit)","Tiger (192 bit)" }, | ||
282 | { "Permissions:","Zugriffsrechte:" }, | ||
283 | { "Make backup before saving","Mache Backup vor dem Speichern" }, | ||
284 | { "Password timeout\n(timeout to hold password in\nmemory,so you don't have to\nre-enter it,if you\nalready have entered it)\n[set to 0 to disable]:","Passwort Timeout\n(Timeout um das Passwort\nim Speicher zu halten,\nso dass es nicht noch mal\neingegeben werden muß.)\n[Setze auf 0 zum deaktivieren]:" }, | ||
285 | { "Auto-lock timeout\n(auto lock document after this\namount of seconds)\n[set to 0 to disable]:","(Total-)Sperr-Timeout\n(Sperre Dokument total nach\ndieser Anzahl Sekunden)\n[Setze auf 0 zum deaktivieren]:" }, | ||
286 | { "deep-lock on autolock","Sperre total beim Sperr-Timeout" }, | ||
287 | { "open deeplocked","Öffne total gesperrt" }, | ||
288 | { "Favourite browser:","Bevorzugter Browser:" }, | ||
289 | { "Favourite x-terminal:","Bevorzugtes x-terminal:" }, | ||
290 | { "Open document with passwords unlocked","Öffne Dokument mit Passwort ungesperrt" }, | ||
291 | { "Look && feel","Aussehen" }, | ||
292 | { "File","Datei" }, | ||
293 | { "Timeout","Timeout" }, | ||
294 | { "Autostart","Autostart" }, | ||
295 | { "External apps","Externe Applik." }, | ||
296 | { "Miscellaneous","Verschiedenes" }, | ||
297 | { "+01:00 Europe/Oslo(CET)","+01:00 Europe/Oslo(CET)" }, | ||
298 | { "edit category descriptions","Ändrere Kategoriebeschreibungen" }, | ||
299 | { "Close","Schließen" }, | ||
300 | { "Category:","Category:" }, | ||
301 | { "Text1 (Description):","Text1 (Beschreibung):" }, | ||
302 | { "Text2 (Username):","Text2 (Benutzername):" }, | ||
303 | { "Text3 (Password):","Text3 (Passwort):" }, | ||
304 | { "edit/add a password entry","Ändere/hinzufüge Passwort Eintrag" }, | ||
305 | { "Description:","Beschreibung:" }, | ||
306 | { "Username:","Benutzername:" }, | ||
307 | { "Password:","Passwort:" }, | ||
308 | { "&Reveal","&Offen zeigen" }, | ||
309 | { "&Generate","&Generiere" }, | ||
310 | { "&Password","&Passwort" }, | ||
311 | { "&Comments","Kommentare" }, | ||
312 | { "Launcher:","Launcher:" }, | ||
313 | { "$d = Description","$d = Beschreibung" }, | ||
314 | { "$n = Username","$n = Benutzername" }, | ||
315 | { "$c = Comment","$c = Kommentar" }, | ||
316 | { "$u = URL","$u = URL" }, | ||
317 | { "$p = Password","$p = Passwort" }, | ||
318 | { "&Launcher","&Launcher" }, | ||
319 | { "Password generator","Passwort Generator" }, | ||
320 | { "Character set:","Buchstaben Set:" }, | ||
321 | { "Lowercase (abc)","Klein (abc)" }, | ||
322 | { "Uppercase (ABC)","Groß (ABC)" }, | ||
323 | { "Numbers (123)","Nummmern (123)" }, | ||
324 | { "Special characters:","Spezielle Buchstaben:" }, | ||
325 | { "Spaces (blank characters)","Leerzeichen" }, | ||
326 | { "User defined:","Benutzer definiert:" }, | ||
327 | { "Password Length:","Passwort Länge:" }, | ||
328 | { "Enable Filtering to get better passwords","Enable Filtering to get better passwords" }, | ||
329 | { "no password","Kein Passwort" }, | ||
330 | { "Sorry, you haven't set a password.","Sorry, Sie haben kein Passwort angegeben." }, | ||
331 | { "not saved, yet","not saved, yet" }, | ||
332 | { "Can't deep-lock, because the document\nhasn't been saved, yet. Please save\nto a file and try again.","Kann nicht tiefsperren, weil das\nDokument noch nicht gespeichert wurde.\nBitte speichern und noch einmal versuchen." }, | ||
333 | { "Find","Finde" }, | ||
334 | { "&Exact match","Genaue Übereinstimmung" }, | ||
335 | { "&Case sensitive","Großschrift abhängig" }, | ||
336 | { "Search in Column","Suche in Spalten" }, | ||
337 | { "&Description","Beschreibung" }, | ||
338 | { "C&omment","Kommentar" }, | ||
339 | { "&Username","Benutzername" }, | ||
340 | { "U&RL","URL" }, | ||
341 | { "delete?","Löschen?" }, | ||
342 | { "Do you really want to delete\nthe selected entry","Wollen Sie wirklich\nden Eintrag löschen:" }, | ||
343 | { "Save?","Speichern?" }, | ||
344 | { ""\nhas been modified.\nDo you want to save it?",""\nwurde geändert.\nMöchten Sie speichern?" }, | ||
345 | { "The list\n "","Die Liste\n "" }, | ||
346 | { "nothing to do","Nichts zu tun" }, | ||
347 | { "Sorry, there's nothing to save.\nPlease first add some passwords.","Sorry, es gibt nichts zu speichern.\nBitte erst Passwörter hinzufügen." }, | ||
348 | { "","" }, | ||
349 | { "","" }, | ||
350 | { "","" }, | ||
351 | { "","" }, | ||
352 | { "","" }, | ||
353 | |||
diff --git a/korganizer/kolistview.cpp b/korganizer/kolistview.cpp index f8bfc8b..b21b419 100644 --- a/korganizer/kolistview.cpp +++ b/korganizer/kolistview.cpp | |||
@@ -9,345 +9,346 @@ | |||
9 | (at your option) any later version. | 9 | (at your option) any later version. |
10 | 10 | ||
11 | This program is distributed in the hope that it will be useful, | 11 | This program is distributed in the hope that it will be useful, |
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of | 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of |
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
14 | GNU General Public License for more details. | 14 | GNU General Public License for more details. |
15 | 15 | ||
16 | You should have received a copy of the GNU General Public License | 16 | You should have received a copy of the GNU General Public License |
17 | along with this program; if not, write to the Free Software | 17 | along with this program; if not, write to the Free Software |
18 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. | 18 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. |
19 | 19 | ||
20 | As a special exception, permission is given to link this program | 20 | As a special exception, permission is given to link this program |
21 | with any edition of Qt, and distribute the resulting executable, | 21 | with any edition of Qt, and distribute the resulting executable, |
22 | without including the source code for Qt in the source distribution. | 22 | without including the source code for Qt in the source distribution. |
23 | */ | 23 | */ |
24 | 24 | ||
25 | #include <qlistview.h> | 25 | #include <qlistview.h> |
26 | #include <qlayout.h> | 26 | #include <qlayout.h> |
27 | #include <qlabel.h> | 27 | #include <qlabel.h> |
28 | #include <qpopupmenu.h> | 28 | #include <qpopupmenu.h> |
29 | #include <qprogressbar.h> | 29 | #include <qprogressbar.h> |
30 | #include <qfileinfo.h> | 30 | #include <qfileinfo.h> |
31 | #include <qmessagebox.h> | 31 | #include <qmessagebox.h> |
32 | #include <qdialog.h> | 32 | #include <qdialog.h> |
33 | #include <qtextstream.h> | 33 | #include <qtextstream.h> |
34 | #include <qdir.h> | 34 | #include <qdir.h> |
35 | #include <qregexp.h> | 35 | #include <qregexp.h> |
36 | 36 | ||
37 | #include <klocale.h> | 37 | #include <klocale.h> |
38 | #include <kdebug.h> | 38 | #include <kdebug.h> |
39 | #include <kiconloader.h> | 39 | #include <kiconloader.h> |
40 | #include <kglobal.h> | 40 | #include <kglobal.h> |
41 | 41 | ||
42 | #include <libkdepim/kpimglobalprefs.h> | 42 | #include <libkdepim/kpimglobalprefs.h> |
43 | #include <libkcal/calendar.h> | 43 | #include <libkcal/calendar.h> |
44 | #include <libkcal/calendarlocal.h> | 44 | #include <libkcal/calendarlocal.h> |
45 | #include <libkcal/icalformat.h> | 45 | #include <libkcal/icalformat.h> |
46 | #include <libkcal/vcalformat.h> | 46 | #include <libkcal/vcalformat.h> |
47 | #include <libkcal/recurrence.h> | 47 | #include <libkcal/recurrence.h> |
48 | #include <libkcal/filestorage.h> | 48 | #include <libkcal/filestorage.h> |
49 | #include <libkdepim/categoryselectdialog.h> | 49 | #include <libkdepim/categoryselectdialog.h> |
50 | #ifndef DESKTOP_VERSION | 50 | #ifndef DESKTOP_VERSION |
51 | #include <qpe/qpeapplication.h> | 51 | #include <qpe/qpeapplication.h> |
52 | #else | 52 | #else |
53 | #include <qapplication.h> | 53 | #include <qapplication.h> |
54 | #endif | 54 | #endif |
55 | 55 | ||
56 | #ifndef KORG_NOPRINTER | 56 | #ifndef KORG_NOPRINTER |
57 | #include "calprinter.h" | 57 | #include "calprinter.h" |
58 | #endif | 58 | #endif |
59 | #include "koglobals.h" | 59 | #include "koglobals.h" |
60 | #include "koprefs.h" | 60 | #include "koprefs.h" |
61 | #include "kfiledialog.h" | 61 | #include "kfiledialog.h" |
62 | 62 | ||
63 | #include "kolistview.h" | 63 | #include "kolistview.h" |
64 | 64 | ||
65 | ListItemVisitor::ListItemVisitor(KOListViewItem *item, QDate date ) | 65 | ListItemVisitor::ListItemVisitor(KOListViewItem *item, QDate date ) |
66 | { | 66 | { |
67 | mItem = item; | 67 | mItem = item; |
68 | mDate = date; | 68 | mDate = date; |
69 | } | 69 | } |
70 | 70 | ||
71 | ListItemVisitor::~ListItemVisitor() | 71 | ListItemVisitor::~ListItemVisitor() |
72 | { | 72 | { |
73 | } | 73 | } |
74 | 74 | ||
75 | bool ListItemVisitor::visit(Event *e) | 75 | bool ListItemVisitor::visit(Event *e) |
76 | { | 76 | { |
77 | 77 | ||
78 | bool ok = false; | 78 | bool ok = false; |
79 | QString start, end; | 79 | QString start, end; |
80 | QDate ds, de; | 80 | QDate ds, de; |
81 | if ( e->doesRecur() ) { | 81 | if ( e->doesRecur() ) { |
82 | ds = e->getNextOccurence( QDateTime( mDate, QTime(0,0,0)), &ok ).date(); | 82 | ds = e->getNextOccurence( QDateTime( mDate, QTime(0,0,0)), &ok ).date(); |
83 | if ( ok ) { | 83 | if ( ok ) { |
84 | int days = e->dtStart().date().daysTo(e->dtEnd().date() ); | 84 | int days = e->dtStart().date().daysTo(e->dtEnd().date() ); |
85 | start = KGlobal::locale()->formatDate(ds,true); | 85 | start = KGlobal::locale()->formatDate(ds,true); |
86 | de = ds.addDays( days); | 86 | de = ds.addDays( days); |
87 | end = KGlobal::locale()->formatDate(de,true); | 87 | end = KGlobal::locale()->formatDate(de,true); |
88 | } | 88 | } |
89 | 89 | ||
90 | } | 90 | } |
91 | if ( ! ok ) { | 91 | if ( ! ok ) { |
92 | start =e->dtStartDateStr(); | 92 | start =e->dtStartDateStr(); |
93 | end = e->dtEndDateStr(); | 93 | end = e->dtEndDateStr(); |
94 | ds = e->dtStart().date(); | 94 | ds = e->dtStart().date(); |
95 | de = e->dtEnd().date(); | 95 | de = e->dtEnd().date(); |
96 | } | 96 | } |
97 | mItem->setText(0,e->summary()); | 97 | mItem->setText(0,e->summary()); |
98 | mItem->setText(1,start); | 98 | mItem->setText(1,start); |
99 | mItem->setText(2,e->dtStartTimeStr()); | 99 | mItem->setText(2,e->dtStartTimeStr()); |
100 | mItem->setText(3,end); | 100 | mItem->setText(3,end); |
101 | mItem->setText(4,e->dtEndTimeStr()); | 101 | mItem->setText(4,e->dtEndTimeStr()); |
102 | mItem->setText(5,e->isAlarmEnabled() ? i18n("Yes") : i18n("No")); | 102 | mItem->setText(5,e->isAlarmEnabled() ? i18n("Yes") : i18n("No")); |
103 | mItem->setText(6, e->recurrence()->recurrenceText()); | 103 | mItem->setText(6, e->recurrence()->recurrenceText()); |
104 | mItem->setText(7,"---"); | 104 | mItem->setText(7,"---"); |
105 | mItem->setText(8,"---"); | 105 | mItem->setText(8,"---"); |
106 | mItem->setText(9, e->cancelled() ? i18n("Yes") : i18n("No")); | 106 | mItem->setText(9, e->cancelled() ? i18n("Yes") : i18n("No")); |
107 | mItem->setText(10,e->categoriesStr()); | 107 | mItem->setText(10,e->categoriesStr()); |
108 | 108 | ||
109 | QString key; | 109 | QString key; |
110 | QTime t = e->doesFloat() ? QTime(0,0) : e->dtStart().time(); | 110 | QTime t = e->doesFloat() ? QTime(0,0) : e->dtStart().time(); |
111 | key.sprintf("%04d%02d%02d%02d%02d",ds.year(),ds.month(),ds.day(),t.hour(),t.minute()); | 111 | key.sprintf("%04d%02d%02d%02d%02d",ds.year(),ds.month(),ds.day(),t.hour(),t.minute()); |
112 | mItem->setSortKey(1,key); | 112 | mItem->setSortKey(1,key); |
113 | 113 | ||
114 | t = e->doesFloat() ? QTime(0,0) : e->dtEnd().time(); | 114 | t = e->doesFloat() ? QTime(0,0) : e->dtEnd().time(); |
115 | key.sprintf("%04d%02d%02d%02d%02d",de.year(),de.month(),de.day(),t.hour(),t.minute()); | 115 | key.sprintf("%04d%02d%02d%02d%02d",de.year(),de.month(),de.day(),t.hour(),t.minute()); |
116 | mItem->setSortKey(3,key); | 116 | mItem->setSortKey(3,key); |
117 | 117 | ||
118 | return true; | 118 | return true; |
119 | } | 119 | } |
120 | 120 | ||
121 | bool ListItemVisitor::visit(Todo *t) | 121 | bool ListItemVisitor::visit(Todo *t) |
122 | { | 122 | { |
123 | mItem->setText(0,i18n("To-Do: %1").arg(t->summary())); | 123 | mItem->setText(0,i18n("To-Do: %1").arg(t->summary())); |
124 | if (t->hasStartDate()) { | 124 | if (t->hasStartDate()) { |
125 | mItem->setText(1,t->dtStartDateStr()); | 125 | mItem->setText(1,t->dtStartDateStr()); |
126 | if (t->doesFloat()) { | 126 | if (t->doesFloat()) { |
127 | mItem->setText(2,"---"); | 127 | mItem->setText(2,"---"); |
128 | } else { | 128 | } else { |
129 | mItem->setText(2,t->dtStartTimeStr()); | 129 | mItem->setText(2,t->dtStartTimeStr()); |
130 | } | 130 | } |
131 | } else { | 131 | } else { |
132 | mItem->setText(1,"---"); | 132 | mItem->setText(1,"---"); |
133 | mItem->setText(2,"---"); | 133 | mItem->setText(2,"---"); |
134 | } | 134 | } |
135 | mItem->setText(3,"---"); | 135 | mItem->setText(3,"---"); |
136 | mItem->setText(4,"---"); | 136 | mItem->setText(4,"---"); |
137 | mItem->setText(5,"---"); | 137 | mItem->setText(5,t->isAlarmEnabled() ? i18n("Yes") : i18n("No")); |
138 | mItem->setText(6,"---"); | 138 | mItem->setText(6,"---"); |
139 | if (t->hasDueDate()) { | 139 | if (t->hasDueDate()) { |
140 | mItem->setText(7,t->dtDueDateStr()); | 140 | mItem->setText(7,t->dtDueDateStr()); |
141 | if (t->doesFloat()) { | 141 | if (t->doesFloat()) { |
142 | mItem->setText(8,"---"); | 142 | mItem->setText(8,"---"); |
143 | } else { | 143 | } else { |
144 | mItem->setText(8,t->dtDueTimeStr()); | 144 | mItem->setText(8,t->dtDueTimeStr()); |
145 | } | 145 | } |
146 | } else { | 146 | } else { |
147 | mItem->setText(7,"---"); | 147 | mItem->setText(7,"---"); |
148 | mItem->setText(8,"---"); | 148 | mItem->setText(8,"---"); |
149 | } | 149 | } |
150 | mItem->setText(9, t->cancelled() ? i18n("Yes") : i18n("No")); | 150 | mItem->setText(9, t->cancelled() ? i18n("Yes") : i18n("No")); |
151 | mItem->setText(10,t->categoriesStr()); | 151 | mItem->setText(10,t->categoriesStr()); |
152 | 152 | ||
153 | QString key; | 153 | QString key; |
154 | QDate d; | 154 | QDate d; |
155 | if (t->hasDueDate()) { | 155 | if (t->hasDueDate()) { |
156 | d = t->dtDue().date(); | 156 | d = t->dtDue().date(); |
157 | QTime tm = t->doesFloat() ? QTime(0,0) : t->dtDue().time(); | 157 | QTime tm = t->doesFloat() ? QTime(0,0) : t->dtDue().time(); |
158 | key.sprintf("%04d%02d%02d%02d%02d",d.year(),d.month(),d.day(),tm.hour(),tm.minute()); | 158 | key.sprintf("%04d%02d%02d%02d%02d",d.year(),d.month(),d.day(),tm.hour(),tm.minute()); |
159 | mItem->setSortKey(7,key); | 159 | mItem->setSortKey(7,key); |
160 | } | 160 | } |
161 | if ( t->hasStartDate() ) { | 161 | if ( t->hasStartDate() ) { |
162 | d = t->dtStart().date(); | 162 | d = t->dtStart().date(); |
163 | QTime tm = t->doesFloat() ? QTime(0,0) : t->dtStart().time(); | 163 | QTime tm = t->doesFloat() ? QTime(0,0) : t->dtStart().time(); |
164 | key.sprintf("%04d%02d%02d%02d%02d",d.year(),d.month(),d.day(),tm.hour(),tm.minute()); | 164 | key.sprintf("%04d%02d%02d%02d%02d",d.year(),d.month(),d.day(),tm.hour(),tm.minute()); |
165 | mItem->setSortKey(1,key); | 165 | mItem->setSortKey(1,key); |
166 | } | 166 | } |
167 | return true; | 167 | return true; |
168 | } | 168 | } |
169 | 169 | ||
170 | bool ListItemVisitor::visit(Journal * j) | 170 | bool ListItemVisitor::visit(Journal * j) |
171 | { | 171 | { |
172 | QString des = j->description().left(50); | 172 | QString des = j->description().left(50); |
173 | des = des.simplifyWhiteSpace (); | 173 | des = des.simplifyWhiteSpace (); |
174 | des.replace (QRegExp ("\\n"),"" ); | 174 | des.replace (QRegExp ("\\n"),"" ); |
175 | des.replace (QRegExp ("\\r"),"" ); | 175 | des.replace (QRegExp ("\\r"),"" ); |
176 | mItem->setText(0,i18n("Journal")+": "+des.left(25)); | 176 | mItem->setText(0,i18n("Journal")+": "+des.left(25)); |
177 | mItem->setText(1,j->dtStartDateStr()); | 177 | mItem->setText(1,j->dtStartDateStr()); |
178 | mItem->setText(2,"---"); | 178 | mItem->setText(2,"---"); |
179 | mItem->setText(3,"---"); | 179 | mItem->setText(3,"---"); |
180 | mItem->setText(4,"---"); | 180 | mItem->setText(4,"---"); |
181 | mItem->setText(5,"---"); | 181 | mItem->setText(5,"---"); |
182 | mItem->setText(6,"---"); | 182 | mItem->setText(6,"---"); |
183 | mItem->setText(7,j->dtStartDateStr()); | 183 | mItem->setText(7,j->dtStartDateStr()); |
184 | mItem->setText(8,"---"); | 184 | mItem->setText(8,"---"); |
185 | mItem->setText(9,"---"); | 185 | mItem->setText(9,"---"); |
186 | mItem->setText(10,i18n("Last Modified: ")+ KGlobal::locale()->formatDateTime( j->lastModified() , true) ); | 186 | mItem->setText(10,i18n("Last Modified: ")+ KGlobal::locale()->formatDateTime( j->lastModified() , true) ); |
187 | 187 | ||
188 | QString key; | 188 | QString key; |
189 | QDate d = j->dtStart().date(); | 189 | QDate d = j->dtStart().date(); |
190 | key.sprintf("%04d%02d%02d",d.year(),d.month(),d.day()); | 190 | key.sprintf("%04d%02d%02d",d.year(),d.month(),d.day()); |
191 | mItem->setSortKey(1,key); | 191 | mItem->setSortKey(1,key); |
192 | mItem->setSortKey(7,key); | 192 | mItem->setSortKey(7,key); |
193 | 193 | ||
194 | return true; | 194 | return true; |
195 | } | 195 | } |
196 | 196 | ||
197 | KOListView::KOListView(Calendar *calendar, QWidget *parent, | 197 | KOListView::KOListView(Calendar *calendar, QWidget *parent, |
198 | const char *name) | 198 | const char *name) |
199 | : KOEventView(calendar, parent, name) | 199 | : KOEventView(calendar, parent, name) |
200 | { | 200 | { |
201 | mActiveItem = 0; | 201 | mActiveItem = 0; |
202 | mListView = new KOListViewListView(this); | 202 | mListView = new KOListViewListView(this); |
203 | mListView->addColumn(i18n("Summary")); | 203 | mListView->addColumn(i18n("Summary")); |
204 | mListView->addColumn(i18n("Start Date")); | 204 | mListView->addColumn(i18n("Start Date")); |
205 | mListView->addColumn(i18n("Start Time")); | 205 | mListView->addColumn(i18n("Start Time")); |
206 | mListView->addColumn(i18n("End Date")); | 206 | mListView->addColumn(i18n("End Date")); |
207 | mListView->addColumn(i18n("End Time")); | 207 | mListView->addColumn(i18n("End Time")); |
208 | mListView->addColumn(i18n("Alarm")); // alarm set? | 208 | mListView->addColumn(i18n("Alarm")); // alarm set? |
209 | mListView->addColumn(i18n("Recurs")); // recurs? | 209 | mListView->addColumn(i18n("Recurs")); // recurs? |
210 | mListView->addColumn(i18n("Due Date")); | 210 | mListView->addColumn(i18n("Due Date")); |
211 | mListView->addColumn(i18n("Due Time")); | 211 | mListView->addColumn(i18n("Due Time")); |
212 | mListView->addColumn(i18n("Cancelled")); | 212 | mListView->addColumn(i18n("Cancelled")); |
213 | mListView->addColumn(i18n("Categories")); | 213 | mListView->addColumn(i18n("Categories")); |
214 | 214 | ||
215 | mListView->setColumnAlignment(0,AlignLeft); | 215 | mListView->setColumnAlignment(0,AlignLeft); |
216 | mListView->setColumnAlignment(1,AlignLeft); | 216 | mListView->setColumnAlignment(1,AlignLeft); |
217 | mListView->setColumnAlignment(2,AlignHCenter); | 217 | mListView->setColumnAlignment(2,AlignHCenter); |
218 | mListView->setColumnAlignment(3,AlignLeft); | 218 | mListView->setColumnAlignment(3,AlignLeft); |
219 | mListView->setColumnAlignment(4,AlignHCenter); | 219 | mListView->setColumnAlignment(4,AlignHCenter); |
220 | mListView->setColumnAlignment(5,AlignLeft); | 220 | mListView->setColumnAlignment(5,AlignLeft); |
221 | mListView->setColumnAlignment(6,AlignLeft); | 221 | mListView->setColumnAlignment(6,AlignLeft); |
222 | mListView->setColumnAlignment(7,AlignLeft); | 222 | mListView->setColumnAlignment(7,AlignLeft); |
223 | mListView->setColumnAlignment(8,AlignLeft); | 223 | mListView->setColumnAlignment(8,AlignLeft); |
224 | mListView->setColumnAlignment(9,AlignLeft); | 224 | mListView->setColumnAlignment(9,AlignLeft); |
225 | mListView->setColumnAlignment(10,AlignLeft); | 225 | mListView->setColumnAlignment(10,AlignLeft); |
226 | mListView->setColumnWidthMode(10, QListView::Manual); | ||
226 | 227 | ||
227 | int iii = 0; | 228 | int iii = 0; |
228 | for ( iii = 0; iii< 10 ; ++iii ) | 229 | for ( iii = 0; iii< 10 ; ++iii ) |
229 | mListView->setColumnWidthMode( iii, QListView::Manual ); | 230 | mListView->setColumnWidthMode( iii, QListView::Manual ); |
230 | 231 | ||
231 | QBoxLayout *layoutTop = new QVBoxLayout(this); | 232 | QBoxLayout *layoutTop = new QVBoxLayout(this); |
232 | layoutTop->addWidget(mListView); | 233 | layoutTop->addWidget(mListView); |
233 | mListView->setFont ( KOPrefs::instance()->mListViewFont ); | 234 | mListView->setFont ( KOPrefs::instance()->mListViewFont ); |
234 | mPopupMenu = eventPopup(); | 235 | mPopupMenu = eventPopup(); |
235 | mPopupMenu->addAdditionalItem(QIconSet(QPixmap()), | 236 | mPopupMenu->addAdditionalItem(QIconSet(QPixmap()), |
236 | i18n("Select all"),this, | 237 | i18n("Select all"),this, |
237 | SLOT(allSelection()),true); | 238 | SLOT(allSelection()),true); |
238 | mPopupMenu->addAdditionalItem(QIconSet(QPixmap()), | 239 | mPopupMenu->addAdditionalItem(QIconSet(QPixmap()), |
239 | i18n("Deselect All"),this, | 240 | i18n("Deselect All"),this, |
240 | SLOT(clearSelection()),true); | 241 | SLOT(clearSelection()),true); |
241 | mPopupMenu->addAdditionalItem(QIconSet(QPixmap()), | 242 | mPopupMenu->addAdditionalItem(QIconSet(QPixmap()), |
242 | i18n("Delete all selected"),this, | 243 | i18n("Delete all selected"),this, |
243 | SLOT(deleteAll()),true); | 244 | SLOT(deleteAll()),true); |
244 | mPopupMenu->insertSeparator(); | 245 | mPopupMenu->insertSeparator(); |
245 | mPopupMenu->addAdditionalItem(QIconSet(QPixmap()), | 246 | mPopupMenu->addAdditionalItem(QIconSet(QPixmap()), |
246 | i18n("Save selected to file..."),this, | 247 | i18n("Save selected to file..."),this, |
247 | SLOT(saveToFile()),true); | 248 | SLOT(saveToFile()),true); |
248 | mPopupMenu->addAdditionalItem(QIconSet(QPixmap()), | 249 | mPopupMenu->addAdditionalItem(QIconSet(QPixmap()), |
249 | i18n("Save Journal/Description..."),this, | 250 | i18n("Save Journal/Description..."),this, |
250 | SLOT(saveDescriptionToFile()),true); | 251 | SLOT(saveDescriptionToFile()),true); |
251 | mPopupMenu->insertSeparator(); | 252 | mPopupMenu->insertSeparator(); |
252 | mPopupMenu->addAdditionalItem(QIconSet(QPixmap()), | 253 | mPopupMenu->addAdditionalItem(QIconSet(QPixmap()), |
253 | i18n("Add Categ. to selected..."),this, | 254 | i18n("Add Categ. to selected..."),this, |
254 | SLOT(addCat()),true); | 255 | SLOT(addCat()),true); |
255 | mPopupMenu->addAdditionalItem(QIconSet(QPixmap()), | 256 | mPopupMenu->addAdditionalItem(QIconSet(QPixmap()), |
256 | i18n("Set Categ. for selected..."),this, | 257 | i18n("Set Categ. for selected..."),this, |
257 | SLOT(setCat()),true); | 258 | SLOT(setCat()),true); |
258 | mPopupMenu->insertSeparator(); | 259 | mPopupMenu->insertSeparator(); |
259 | 260 | ||
260 | 261 | ||
261 | #ifndef DESKTOP_VERSION | 262 | #ifndef DESKTOP_VERSION |
262 | mPopupMenu->addAdditionalItem(QIconSet(QPixmap()), | 263 | mPopupMenu->addAdditionalItem(QIconSet(QPixmap()), |
263 | i18n("Beam selected via IR"),this, | 264 | i18n("Beam selected via IR"),this, |
264 | SLOT(beamSelected()),true); | 265 | SLOT(beamSelected()),true); |
265 | #endif | 266 | #endif |
266 | /* | 267 | /* |
267 | mPopupMenu = new QPopupMenu; | 268 | mPopupMenu = new QPopupMenu; |
268 | mPopupMenu->insertItem(i18n("Edit Event"), this, | 269 | mPopupMenu->insertItem(i18n("Edit Event"), this, |
269 | SLOT (editEvent())); | 270 | SLOT (editEvent())); |
270 | mPopupMenu->insertItem(SmallIcon("delete"), i18n("Delete Event"), this, | 271 | mPopupMenu->insertItem(SmallIcon("delete"), i18n("Delete Event"), this, |
271 | SLOT (deleteEvent())); | 272 | SLOT (deleteEvent())); |
272 | mPopupMenu->insertSeparator(); | 273 | mPopupMenu->insertSeparator(); |
273 | mPopupMenu->insertItem(i18n("Show Dates"), this, | 274 | mPopupMenu->insertItem(i18n("Show Dates"), this, |
274 | SLOT(showDates())); | 275 | SLOT(showDates())); |
275 | mPopupMenu->insertItem(i18n("Hide Dates"), this, | 276 | mPopupMenu->insertItem(i18n("Hide Dates"), this, |
276 | SLOT(hideDates())); | 277 | SLOT(hideDates())); |
277 | */ | 278 | */ |
278 | QObject::connect(mListView,SIGNAL( newEvent()), | 279 | QObject::connect(mListView,SIGNAL( newEvent()), |
279 | this,SIGNAL(signalNewEvent())); | 280 | this,SIGNAL(signalNewEvent())); |
280 | QObject::connect(mListView,SIGNAL(doubleClicked(QListViewItem *)), | 281 | QObject::connect(mListView,SIGNAL(doubleClicked(QListViewItem *)), |
281 | this,SLOT(defaultItemAction(QListViewItem *))); | 282 | this,SLOT(defaultItemAction(QListViewItem *))); |
282 | QObject::connect(mListView,SIGNAL(rightButtonClicked ( QListViewItem *, | 283 | QObject::connect(mListView,SIGNAL(rightButtonClicked ( QListViewItem *, |
283 | const QPoint &, int )), | 284 | const QPoint &, int )), |
284 | this,SLOT(popupMenu(QListViewItem *,const QPoint &,int))); | 285 | this,SLOT(popupMenu(QListViewItem *,const QPoint &,int))); |
285 | QObject::connect(mListView,SIGNAL(currentChanged(QListViewItem *)), | 286 | QObject::connect(mListView,SIGNAL(currentChanged(QListViewItem *)), |
286 | SLOT(processSelectionChange(QListViewItem *))); | 287 | SLOT(processSelectionChange(QListViewItem *))); |
287 | QObject::connect(mListView,SIGNAL(showIncidence(Incidence *)), | 288 | QObject::connect(mListView,SIGNAL(showIncidence(Incidence *)), |
288 | SIGNAL(showIncidenceSignal(Incidence *)) ); | 289 | SIGNAL(showIncidenceSignal(Incidence *)) ); |
289 | 290 | ||
290 | readSettings(KOGlobals::config(),"KOListView Layout"); | 291 | readSettings(KOGlobals::config(),"KOListView Layout"); |
291 | } | 292 | } |
292 | 293 | ||
293 | KOListView::~KOListView() | 294 | KOListView::~KOListView() |
294 | { | 295 | { |
295 | delete mPopupMenu; | 296 | delete mPopupMenu; |
296 | } | 297 | } |
297 | 298 | ||
298 | void KOListView::updateList() | 299 | void KOListView::updateList() |
299 | { | 300 | { |
300 | // qDebug(" KOListView::updateList() "); | 301 | // qDebug(" KOListView::updateList() "); |
301 | 302 | ||
302 | } | 303 | } |
303 | 304 | ||
304 | void KOListView::addCat( ) | 305 | void KOListView::addCat( ) |
305 | { | 306 | { |
306 | setCategories( false ); | 307 | setCategories( false ); |
307 | } | 308 | } |
308 | void KOListView::setCat() | 309 | void KOListView::setCat() |
309 | { | 310 | { |
310 | setCategories( true ); | 311 | setCategories( true ); |
311 | } | 312 | } |
312 | void KOListView::setCategories( bool removeOld ) | 313 | void KOListView::setCategories( bool removeOld ) |
313 | { | 314 | { |
314 | 315 | ||
315 | KPIM::CategorySelectDialog* csd = new KPIM::CategorySelectDialog( KOPrefs::instance(), 0 ); | 316 | KPIM::CategorySelectDialog* csd = new KPIM::CategorySelectDialog( KOPrefs::instance(), 0 ); |
316 | if (! csd->exec()) { | 317 | if (! csd->exec()) { |
317 | delete csd; | 318 | delete csd; |
318 | return; | 319 | return; |
319 | } | 320 | } |
320 | QStringList catList = csd->selectedCategories(); | 321 | QStringList catList = csd->selectedCategories(); |
321 | delete csd; | 322 | delete csd; |
322 | // if ( catList.count() == 0 ) | 323 | // if ( catList.count() == 0 ) |
323 | // return; | 324 | // return; |
324 | catList.sort(); | 325 | catList.sort(); |
325 | QString categoriesStr = catList.join(","); | 326 | QString categoriesStr = catList.join(","); |
326 | int i; | 327 | int i; |
327 | QStringList itemList; | 328 | QStringList itemList; |
328 | QPtrList<KOListViewItem> sel ; | 329 | QPtrList<KOListViewItem> sel ; |
329 | QListViewItem *qitem = mListView->firstChild (); | 330 | QListViewItem *qitem = mListView->firstChild (); |
330 | while ( qitem ) { | 331 | while ( qitem ) { |
331 | if ( qitem->isSelected() ) { | 332 | if ( qitem->isSelected() ) { |
332 | sel.append(((KOListViewItem *)qitem)); | 333 | sel.append(((KOListViewItem *)qitem)); |
333 | } | 334 | } |
334 | qitem = qitem->nextSibling(); | 335 | qitem = qitem->nextSibling(); |
335 | } | 336 | } |
336 | KOListViewItem * item, *temp; | 337 | KOListViewItem * item, *temp; |
337 | item = sel.first(); | 338 | item = sel.first(); |
338 | Incidence* inc; | 339 | Incidence* inc; |
339 | while ( item ) { | 340 | while ( item ) { |
340 | inc = item->data(); | 341 | inc = item->data(); |
341 | if ( removeOld ) { | 342 | if ( removeOld ) { |
342 | inc->setCategories( categoriesStr ); | 343 | inc->setCategories( categoriesStr ); |
343 | } else { | 344 | } else { |
344 | itemList = QStringList::split (",", inc->categoriesStr() ); | 345 | itemList = QStringList::split (",", inc->categoriesStr() ); |
345 | for( i = 0; i< catList.count(); ++i ) { | 346 | for( i = 0; i< catList.count(); ++i ) { |
346 | if ( !itemList.contains (catList[i])) | 347 | if ( !itemList.contains (catList[i])) |
347 | itemList.append( catList[i] ); | 348 | itemList.append( catList[i] ); |
348 | } | 349 | } |
349 | itemList.sort(); | 350 | itemList.sort(); |
350 | inc->setCategories( itemList.join(",") ); | 351 | inc->setCategories( itemList.join(",") ); |
351 | } | 352 | } |
352 | temp = item; | 353 | temp = item; |
353 | item = sel.next(); | 354 | item = sel.next(); |
diff --git a/pwmanager/pwmanager/main.cpp b/pwmanager/pwmanager/main.cpp index 70df15d..6e449c6 100644 --- a/pwmanager/pwmanager/main.cpp +++ b/pwmanager/pwmanager/main.cpp | |||
@@ -1,220 +1,222 @@ | |||
1 | /*************************************************************************** | 1 | /*************************************************************************** |
2 | * * | 2 | * * |
3 | * copyright (C) 2003, 2004 by Michael Buesch * | 3 | * copyright (C) 2003, 2004 by Michael Buesch * |
4 | * email: mbuesch@freenet.de * | 4 | * email: mbuesch@freenet.de * |
5 | * * | 5 | * * |
6 | * This program is free software; you can redistribute it and/or modify * | 6 | * This program is free software; you can redistribute it and/or modify * |
7 | * it under the terms of the GNU General Public License version 2 * | 7 | * it under the terms of the GNU General Public License version 2 * |
8 | * as published by the Free Software Foundation. * | 8 | * as published by the Free Software Foundation. * |
9 | * * | 9 | * * |
10 | ***************************************************************************/ | 10 | ***************************************************************************/ |
11 | 11 | ||
12 | /*************************************************************************** | 12 | /*************************************************************************** |
13 | * copyright (C) 2004 by Ulf Schenk | 13 | * copyright (C) 2004 by Ulf Schenk |
14 | * This file is originaly based on version 1.0.1 of pwmanager | 14 | * This file is originaly based on version 1.0.1 of pwmanager |
15 | * and was modified to run on embedded devices that run microkde | 15 | * and was modified to run on embedded devices that run microkde |
16 | * | 16 | * |
17 | * $Id$ | 17 | * $Id$ |
18 | **************************************************************************/ | 18 | **************************************************************************/ |
19 | 19 | ||
20 | #ifndef PWM_EMBEDDED | 20 | #ifndef PWM_EMBEDDED |
21 | #include <kcmdlineargs.h> | 21 | #include <kcmdlineargs.h> |
22 | #include <kaboutdata.h> | 22 | #include <kaboutdata.h> |
23 | #else | 23 | #else |
24 | #include <qdir.h> | 24 | #include <qdir.h> |
25 | #include <kpimglobalprefs.h> | 25 | #include <kpimglobalprefs.h> |
26 | #endif | 26 | #endif |
27 | 27 | ||
28 | #include <klocale.h> | 28 | #include <klocale.h> |
29 | #include <kstandarddirs.h> | 29 | #include <kstandarddirs.h> |
30 | 30 | ||
31 | #include "pwmexception.h" | 31 | #include "pwmexception.h" |
32 | #include "pwminit.h" | 32 | #include "pwminit.h" |
33 | void dumpMissing(); | ||
33 | 34 | ||
34 | #define LICENSE_FILE(::locate("data", "pwmanager/pwmanager_license_text")) | 35 | #define LICENSE_FILE(::locate("data", "pwmanager/pwmanager_license_text")) |
35 | 36 | ||
36 | int PwMApplication::newInstance() | 37 | int PwMApplication::newInstance() |
37 | { | 38 | { |
38 | static bool initial = true; | 39 | static bool initial = true; |
39 | if (initial) { | 40 | if (initial) { |
40 | initial = false; | 41 | initial = false; |
41 | init = new PwMInit(this); | 42 | init = new PwMInit(this); |
42 | init->initializeApp(); | 43 | init->initializeApp(); |
43 | } else { | 44 | } else { |
44 | BUG_ON(!init); | 45 | BUG_ON(!init); |
45 | printInfo("passing parameters to old instance."); | 46 | printInfo("passing parameters to old instance."); |
46 | init->handleCmdLineArgs(false); | 47 | init->handleCmdLineArgs(false); |
47 | } | 48 | } |
48 | return EXIT_SUCCESS; | 49 | return EXIT_SUCCESS; |
49 | } | 50 | } |
50 | 51 | ||
51 | 52 | ||
52 | static const char *description = I18N_NOOP("PwManager\n" | 53 | static const char *description = I18N_NOOP("PwManager\n" |
53 | "The convenient way of managing passwords"); | 54 | "The convenient way of managing passwords"); |
54 | 55 | ||
55 | #ifndef PWM_EMBEDDED | 56 | #ifndef PWM_EMBEDDED |
56 | static KCmdLineOptions options[] = | 57 | static KCmdLineOptions options[] = |
57 | { | 58 | { |
58 | { "minimized", I18N_NOOP("Windows minimized"), 0 }, | 59 | { "minimized", I18N_NOOP("Windows minimized"), 0 }, |
59 | { "mintray", I18N_NOOP("Windows minimized to tray"),0 }, | 60 | { "mintray", I18N_NOOP("Windows minimized to tray"),0 }, |
60 | { "open-deeplocked", I18N_NOOP("Open all \"files\" deeplocked"),0 }, | 61 | { "open-deeplocked", I18N_NOOP("Open all \"files\" deeplocked"),0 }, |
61 | { "skip-self-test", I18N_NOOP("Don't run a self-test on startup"),0 }, | 62 | { "skip-self-test", I18N_NOOP("Don't run a self-test on startup"),0 }, |
62 | { "+[files...]", I18N_NOOP("Files to open on startup"), 0 }, | 63 | { "+[files...]", I18N_NOOP("Files to open on startup"), 0 }, |
63 | { 0, 0, 0 } | 64 | { 0, 0, 0 } |
64 | }; | 65 | }; |
65 | #endif | 66 | #endif |
66 | 67 | ||
67 | #ifdef PWM_DEBUG | 68 | #ifdef PWM_DEBUG |
68 | static void printDebugConfigureInfo() | 69 | static void printDebugConfigureInfo() |
69 | { | 70 | { |
70 | cout << "================================" << endl; | 71 | cout << "================================" << endl; |
71 | cout << PROG_NAME " version " PACKAGE_VER << endl; | 72 | cout << PROG_NAME " version " PACKAGE_VER << endl; |
72 | #ifdef CONFIG_KEYCARD | 73 | #ifdef CONFIG_KEYCARD |
73 | cout << "CONFIG_KEYCARD: enabled" << endl; | 74 | cout << "CONFIG_KEYCARD: enabled" << endl; |
74 | #else | 75 | #else |
75 | cout << "CONFIG_KEYCARD: disabled" << endl; | 76 | cout << "CONFIG_KEYCARD: disabled" << endl; |
76 | #endif | 77 | #endif |
77 | #ifdef CONFIG_KWALLETIF | 78 | #ifdef CONFIG_KWALLETIF |
78 | cout << "CONFIG_KWALLETIF: enabled" << endl; | 79 | cout << "CONFIG_KWALLETIF: enabled" << endl; |
79 | #else | 80 | #else |
80 | cout << "CONFIG_KWALLETIF: disabled" << endl; | 81 | cout << "CONFIG_KWALLETIF: disabled" << endl; |
81 | #endif | 82 | #endif |
82 | #ifdef BIG_ENDIAN_HOST | 83 | #ifdef BIG_ENDIAN_HOST |
83 | cout << "Endianess: big-endian" << endl; | 84 | cout << "Endianess: big-endian" << endl; |
84 | #else | 85 | #else |
85 | cout << "Endianess: little-endian" << endl; | 86 | cout << "Endianess: little-endian" << endl; |
86 | #endif | 87 | #endif |
87 | #ifdef WORDS_BIGENDIAN | 88 | #ifdef WORDS_BIGENDIAN |
88 | cout << "Endianess 2: big-endian" << endl; | 89 | cout << "Endianess 2: big-endian" << endl; |
89 | #else | 90 | #else |
90 | cout << "Endianess 2: little-endian" << endl; | 91 | cout << "Endianess 2: little-endian" << endl; |
91 | #endif | 92 | #endif |
92 | 93 | ||
93 | cout << "sizeof(long): " << sizeof(long) << endl; | 94 | cout << "sizeof(long): " << sizeof(long) << endl; |
94 | cout << "================================" << endl; | 95 | cout << "================================" << endl; |
95 | } | 96 | } |
96 | #else // PWM_DEBUG | 97 | #else // PWM_DEBUG |
97 | static inline void printDebugConfigureInfo() { /* nothing */ } | 98 | static inline void printDebugConfigureInfo() { /* nothing */ } |
98 | #endif // PWM_DEBUG | 99 | #endif // PWM_DEBUG |
99 | 100 | ||
100 | #ifndef PWM_EMBEDDED | 101 | #ifndef PWM_EMBEDDED |
101 | static void addAuthors(KAboutData *aboutData) | 102 | static void addAuthors(KAboutData *aboutData) |
102 | { | 103 | { |
103 | aboutData->addAuthor("Michael Buesch", | 104 | aboutData->addAuthor("Michael Buesch", |
104 | I18N_NOOP( | 105 | I18N_NOOP( |
105 | "main programming and current maintainer"), | 106 | "main programming and current maintainer"), |
106 | "mbuesch@freenet.de"); | 107 | "mbuesch@freenet.de"); |
107 | aboutData->addAuthor("Matt Scifo", | 108 | aboutData->addAuthor("Matt Scifo", |
108 | I18N_NOOP( | 109 | I18N_NOOP( |
109 | "original implementaion of \n" | 110 | "original implementaion of \n" |
110 | "\"categories\" and the password-tree \n" | 111 | "\"categories\" and the password-tree \n" |
111 | "in the system-tray. Original implementations of \n" | 112 | "in the system-tray. Original implementations of \n" |
112 | "numerous view-improvements."), | 113 | "numerous view-improvements."), |
113 | "mscifo@o1.com"); | 114 | "mscifo@o1.com"); |
114 | aboutData->addCredit("Elias Probst", | 115 | aboutData->addCredit("Elias Probst", |
115 | I18N_NOOP( | 116 | I18N_NOOP( |
116 | "Gentoo ebuild maintainer."), | 117 | "Gentoo ebuild maintainer."), |
117 | "elias.probst@gmx.de"); | 118 | "elias.probst@gmx.de"); |
118 | aboutData->addCredit("George Staikos", | 119 | aboutData->addCredit("George Staikos", |
119 | I18N_NOOP("KWallet"), | 120 | I18N_NOOP("KWallet"), |
120 | "staikos@kde.org"); | 121 | "staikos@kde.org"); |
121 | aboutData->addCredit("Matthew Palmer", | 122 | aboutData->addCredit("Matthew Palmer", |
122 | I18N_NOOP("rc2 code"), | 123 | I18N_NOOP("rc2 code"), |
123 | "mjp16@uow.edu.au"); | 124 | "mjp16@uow.edu.au"); |
124 | aboutData->addCredit("Olivier Sessink", | 125 | aboutData->addCredit("Olivier Sessink", |
125 | I18N_NOOP("gpasman"), | 126 | I18N_NOOP("gpasman"), |
126 | "gpasman@nl.linux.org"); | 127 | "gpasman@nl.linux.org"); |
127 | aboutData->addCredit("The libgcrypt developers", | 128 | aboutData->addCredit("The libgcrypt developers", |
128 | I18N_NOOP("Blowfish and SHA1 algorithms"), | 129 | I18N_NOOP("Blowfish and SHA1 algorithms"), |
129 | 0, "ftp://ftp.gnupg.org/gcrypt/alpha/libgcrypt/"); | 130 | 0, "ftp://ftp.gnupg.org/gcrypt/alpha/libgcrypt/"); |
130 | aboutData->addCredit("Troy Engel", | 131 | aboutData->addCredit("Troy Engel", |
131 | I18N_NOOP("kpasman"), | 132 | I18N_NOOP("kpasman"), |
132 | "tengel@sonic.net"); | 133 | "tengel@sonic.net"); |
133 | aboutData->addCredit("Wickey", | 134 | aboutData->addCredit("Wickey", |
134 | I18N_NOOP("graphics-design in older versions."), | 135 | I18N_NOOP("graphics-design in older versions."), |
135 | "wickey@gmx.at"); | 136 | "wickey@gmx.at"); |
136 | aboutData->addCredit("Ian MacGregor", | 137 | aboutData->addCredit("Ian MacGregor", |
137 | I18N_NOOP( | 138 | I18N_NOOP( |
138 | "original documentation author.")); | 139 | "original documentation author.")); |
139 | } | 140 | } |
140 | #endif | 141 | #endif |
141 | 142 | ||
142 | int main(int argc, char *argv[]) | 143 | int main(int argc, char *argv[]) |
143 | { | 144 | { |
144 | printDebugConfigureInfo(); | 145 | printDebugConfigureInfo(); |
145 | #ifndef PWM_EMBEDDED | 146 | #ifndef PWM_EMBEDDED |
146 | KAboutData aboutData(PACKAGE_NAME, PROG_NAME, | 147 | KAboutData aboutData(PACKAGE_NAME, PROG_NAME, |
147 | PACKAGE_VER, description, KAboutData::License_File, | 148 | PACKAGE_VER, description, KAboutData::License_File, |
148 | "(c) 2003, 2004 Michael Buesch and the PwManager Team", 0, | 149 | "(c) 2003, 2004 Michael Buesch and the PwManager Team", 0, |
149 | "http://passwordmanager.sourceforge.net/", | 150 | "http://passwordmanager.sourceforge.net/", |
150 | "mbuesch@freenet.de"); | 151 | "mbuesch@freenet.de"); |
151 | addAuthors(&aboutData); | 152 | addAuthors(&aboutData); |
152 | 153 | ||
153 | KCmdLineArgs::init(argc, argv, &aboutData); | 154 | KCmdLineArgs::init(argc, argv, &aboutData); |
154 | KCmdLineArgs::addCmdLineOptions(options); | 155 | KCmdLineArgs::addCmdLineOptions(options); |
155 | 156 | ||
156 | KUniqueApplication::addCmdLineOptions(); | 157 | KUniqueApplication::addCmdLineOptions(); |
157 | if (!KUniqueApplication::start()) { | 158 | if (!KUniqueApplication::start()) { |
158 | printInfo("already running."); | 159 | printInfo("already running."); |
159 | return EXIT_SUCCESS; | 160 | return EXIT_SUCCESS; |
160 | } | 161 | } |
161 | PwMApplication a; | 162 | PwMApplication a; |
162 | aboutData.setLicenseTextFile(LICENSE_FILE); | 163 | aboutData.setLicenseTextFile(LICENSE_FILE); |
163 | return a.exec(); | 164 | return a.exec(); |
164 | #else | 165 | #else |
165 | 166 | ||
166 | bool exitHelp = false; | 167 | bool exitHelp = false; |
167 | if ( argc > 1 ) { | 168 | if ( argc > 1 ) { |
168 | QString command = argv[1]; | 169 | QString command = argv[1]; |
169 | if ( command == "-help" ){ | 170 | if ( command == "-help" ){ |
170 | printf("PWM/PI command line commands:\n"); | 171 | printf("PWM/PI command line commands:\n"); |
171 | printf(" no command: Start PWM/PI in usual way\n"); | 172 | printf(" no command: Start PWM/PI in usual way\n"); |
172 | printf(" -help: This output\n"); | 173 | printf(" -help: This output\n"); |
173 | printf(" PWM/PI is exiting now. Bye!\n"); | 174 | printf(" PWM/PI is exiting now. Bye!\n"); |
174 | exitHelp = true; | 175 | exitHelp = true; |
175 | } | 176 | } |
176 | } | 177 | } |
177 | if ( ! exitHelp ) { | 178 | if ( ! exitHelp ) { |
178 | 179 | ||
179 | PwMApplication a(argc, argv); | 180 | PwMApplication a(argc, argv); |
180 | 181 | ||
181 | KGlobal::setAppName( "pwmanager" ); | 182 | KGlobal::setAppName( "pwmanager" ); |
182 | #ifndef DESKTOP_VERSION | 183 | #ifndef DESKTOP_VERSION |
183 | //qDebug("width %d ",QApplication::desktop()->width() ); | 184 | //qDebug("width %d ",QApplication::desktop()->width() ); |
184 | if ( QApplication::desktop()->width() > 320 ) | 185 | if ( QApplication::desktop()->width() > 320 ) |
185 | KGlobal::iconLoader()->setIconPath(QString(getenv("QPEDIR"))+"/pics/kdepim/pwmanager/icons22/"); | 186 | KGlobal::iconLoader()->setIconPath(QString(getenv("QPEDIR"))+"/pics/kdepim/pwmanager/icons22/"); |
186 | else | 187 | else |
187 | KGlobal::iconLoader()->setIconPath(QString(getenv("QPEDIR"))+"/pics/kdepim/pwmanager/icons16/"); | 188 | KGlobal::iconLoader()->setIconPath(QString(getenv("QPEDIR"))+"/pics/kdepim/pwmanager/icons16/"); |
188 | #else | 189 | #else |
189 | QString fileName ; | 190 | QString fileName ; |
190 | fileName = qApp->applicationDirPath () + "/kdepim/pwmanager/icons22/"; | 191 | fileName = qApp->applicationDirPath () + "/kdepim/pwmanager/icons22/"; |
191 | KGlobal::iconLoader()->setIconPath(QDir::convertSeparators(fileName)); | 192 | KGlobal::iconLoader()->setIconPath(QDir::convertSeparators(fileName)); |
192 | QApplication::addLibraryPath ( qApp->applicationDirPath () ); | 193 | QApplication::addLibraryPath ( qApp->applicationDirPath () ); |
193 | 194 | ||
194 | #endif | 195 | #endif |
195 | KStandardDirs::setAppDir( QDir::convertSeparators(locateLocal("data", "pwmanager"))); | 196 | KStandardDirs::setAppDir( QDir::convertSeparators(locateLocal("data", "pwmanager"))); |
196 | KPimGlobalPrefs::instance()->setGlobalConfig(); | 197 | KPimGlobalPrefs::instance()->setGlobalConfig(); |
197 | 198 | ||
198 | a.newInstance(); | 199 | a.newInstance(); |
199 | 200 | ||
200 | //US KAddressBookMain m ; | 201 | //US KAddressBookMain m ; |
201 | 202 | ||
202 | //US QObject::connect(&a, SIGNAL (appMessage ( const QCString &, const QByteArray & )), ExternalAppHandler::instance(), SLOT (appMessage ( const QCString &, const QByteArray & ))); | 203 | //US QObject::connect(&a, SIGNAL (appMessage ( const QCString &, const QByteArray & )), ExternalAppHandler::instance(), SLOT (appMessage ( const QCString &, const QByteArray & ))); |
203 | /*US | 204 | /*US |
204 | #ifndef DESKTOP_VERSION | 205 | #ifndef DESKTOP_VERSION |
205 | a.showMainWidget( &m ); | 206 | a.showMainWidget( &m ); |
206 | #else | 207 | #else |
207 | a.setMainWidget( &m ); | 208 | a.setMainWidget( &m ); |
208 | m.resize (640, 480 ); | 209 | m.resize (640, 480 ); |
209 | m.show(); | 210 | m.show(); |
210 | #endif | 211 | #endif |
211 | */ | 212 | */ |
212 | QObject::connect( &a, SIGNAL( lastWindowClosed()), &a, SLOT (quit())); | 213 | QObject::connect( &a, SIGNAL( lastWindowClosed()), &a, SLOT (quit())); |
213 | a.exec(); | 214 | a.exec(); |
215 | dumpMissing(); | ||
214 | KPimGlobalPrefs::instance()->writeConfig(); | 216 | KPimGlobalPrefs::instance()->writeConfig(); |
215 | } | 217 | } |
216 | qDebug("PWMPI: Bye! "); | 218 | qDebug("PWMPI: Bye! "); |
217 | 219 | ||
218 | #endif | 220 | #endif |
219 | 221 | ||
220 | } | 222 | } |
diff --git a/pwmanager/pwmanager/pwminit.cpp b/pwmanager/pwmanager/pwminit.cpp index 68f3637..0cf248c 100644 --- a/pwmanager/pwmanager/pwminit.cpp +++ b/pwmanager/pwmanager/pwminit.cpp | |||
@@ -62,258 +62,259 @@ static NOREGPARM void sig_handler(int signum) | |||
62 | #endif | 62 | #endif |
63 | { | 63 | { |
64 | switch (signum) { | 64 | switch (signum) { |
65 | case SIGINT: | 65 | case SIGINT: |
66 | case SIGTERM: | 66 | case SIGTERM: |
67 | sig_init_pointer->shutdownApp(20 + signum); | 67 | sig_init_pointer->shutdownApp(20 + signum); |
68 | break; | 68 | break; |
69 | default: | 69 | default: |
70 | printDebug(string("unhandled signal ") | 70 | printDebug(string("unhandled signal ") |
71 | + tostr(signum)); | 71 | + tostr(signum)); |
72 | } | 72 | } |
73 | } | 73 | } |
74 | 74 | ||
75 | 75 | ||
76 | 76 | ||
77 | PwMInit::PwMInit(PwMApplication *_app) | 77 | PwMInit::PwMInit(PwMApplication *_app) |
78 | : runStatus (unknown) | 78 | : runStatus (unknown) |
79 | , _curWidget (0) | 79 | , _curWidget (0) |
80 | , _dcopClient (0) | 80 | , _dcopClient (0) |
81 | , _kwalletEmu (0) | 81 | , _kwalletEmu (0) |
82 | , _keycard (0) | 82 | , _keycard (0) |
83 | , _tray (0) | 83 | , _tray (0) |
84 | { | 84 | { |
85 | sig_init_pointer = this; | 85 | sig_init_pointer = this; |
86 | app = _app; | 86 | app = _app; |
87 | } | 87 | } |
88 | 88 | ||
89 | PwMInit::~PwMInit() | 89 | PwMInit::~PwMInit() |
90 | { | 90 | { |
91 | qDebug("PwMInit::~PwMInit() "); | 91 | qDebug("PwMInit::~PwMInit() "); |
92 | #ifndef PWM_EMBEDDED | 92 | #ifndef PWM_EMBEDDED |
93 | SelfTest::cancel(); | 93 | SelfTest::cancel(); |
94 | // close all open mainwnds | 94 | // close all open mainwnds |
95 | QValueList<PwM *>::iterator i = _mainWndList.begin(), | 95 | QValueList<PwM *>::iterator i = _mainWndList.begin(), |
96 | end = _mainWndList.end(); | 96 | end = _mainWndList.end(); |
97 | 97 | ||
98 | #else | 98 | #else |
99 | // close all open mainwnds | 99 | // close all open mainwnds |
100 | QValueList<PwM *>::Iterator i = _mainWndList.begin(), | 100 | QValueList<PwM *>::Iterator i = _mainWndList.begin(), |
101 | end = _mainWndList.end(); | 101 | end = _mainWndList.end(); |
102 | #endif | 102 | #endif |
103 | while (i != end) { | 103 | while (i != end) { |
104 | disconnect(*i, SIGNAL(closed(PwM *)), | 104 | disconnect(*i, SIGNAL(closed(PwM *)), |
105 | this, SLOT(mainWndClosed(PwM *))); | 105 | this, SLOT(mainWndClosed(PwM *))); |
106 | delete *i; | 106 | delete *i; |
107 | ++i; | 107 | ++i; |
108 | } | 108 | } |
109 | _mainWndList.clear(); | 109 | _mainWndList.clear(); |
110 | // close all remaining open documents | 110 | // close all remaining open documents |
111 | PwMDocList *_dl = PwMDoc::getOpenDocList(); | 111 | PwMDocList *_dl = PwMDoc::getOpenDocList(); |
112 | vector<PwMDocList::listItem> dl = *(_dl->getList()); | 112 | vector<PwMDocList::listItem> dl = *(_dl->getList()); |
113 | vector<PwMDocList::listItem>::iterator i2 = dl.begin(), | 113 | vector<PwMDocList::listItem>::iterator i2 = dl.begin(), |
114 | end2 = dl.end(); | 114 | end2 = dl.end(); |
115 | while (i2 != end2) { | 115 | while (i2 != end2) { |
116 | delete (*i2).doc; | 116 | delete (*i2).doc; |
117 | ++i2; | 117 | ++i2; |
118 | } | 118 | } |
119 | 119 | ||
120 | #ifdef CONFIG_KWALLETIF | 120 | #ifdef CONFIG_KWALLETIF |
121 | delete_ifnot_null(_kwalletEmu); | 121 | delete_ifnot_null(_kwalletEmu); |
122 | #endif // CONFIG_KWALLETIF | 122 | #endif // CONFIG_KWALLETIF |
123 | #ifdef CONFIG_KEYCARD | 123 | #ifdef CONFIG_KEYCARD |
124 | delete_ifnot_null(_keycard); | 124 | delete_ifnot_null(_keycard); |
125 | #endif // CONFIG_KEYCARD | 125 | #endif // CONFIG_KEYCARD |
126 | delete_ifnot_null(_tray); | 126 | delete_ifnot_null(_tray); |
127 | 127 | ||
128 | Randomizer::cleanup(); | 128 | Randomizer::cleanup(); |
129 | #ifndef PWM_EMBEDDED | 129 | #ifndef PWM_EMBEDDED |
130 | Configuration::cleanup(); | 130 | Configuration::cleanup(); |
131 | #endif | 131 | #endif |
132 | } | 132 | } |
133 | 133 | ||
134 | void PwMInit::initializeApp() | 134 | void PwMInit::initializeApp() |
135 | { | 135 | { |
136 | //qDebug("PwMInit::initializeApp() "); | 136 | //qDebug("PwMInit::initializeApp() "); |
137 | PWM_ASSERT(runStatus == unknown); | 137 | PWM_ASSERT(runStatus == unknown); |
138 | runStatus = init; | 138 | runStatus = init; |
139 | initPosixSignalHandler(); | 139 | initPosixSignalHandler(); |
140 | Randomizer::init(); | 140 | Randomizer::init(); |
141 | #ifndef PWM_EMBEDDED | 141 | #ifndef PWM_EMBEDDED |
142 | Configuration::init(); | 142 | Configuration::init(); |
143 | #endif | 143 | #endif |
144 | initDCOP(); | 144 | initDCOP(); |
145 | initKWalletEmu(); | 145 | initKWalletEmu(); |
146 | initKeycard(); | 146 | initKeycard(); |
147 | initTray(); | 147 | initTray(); |
148 | handleCmdLineArgs(); | 148 | handleCmdLineArgs(); |
149 | bool openDeeplocked = false; | 149 | bool openDeeplocked = false; |
150 | if (conf()->confGlobAutostartDeepLocked() || | 150 | if (conf()->confGlobAutostartDeepLocked() || |
151 | savedCmd.open_deeplocked) | 151 | savedCmd.open_deeplocked) |
152 | openDeeplocked = true; | 152 | openDeeplocked = true; |
153 | if ( false ){ | 153 | if ( false ){ |
154 | // LR is not working | 154 | // LR is not working |
155 | //if (conf()->confWndAutoMinimizeOnStart() || | 155 | //if (conf()->confWndAutoMinimizeOnStart() || |
156 | // savedCmd.minToTray) { | 156 | // savedCmd.minToTray) { |
157 | PwMDoc *newDoc = createDoc(); | 157 | PwMDoc *newDoc = createDoc(); |
158 | qDebug(" createDoc()"); | 158 | qDebug(" createDoc()"); |
159 | if (!newDoc->openDocUi(newDoc, | 159 | if (!newDoc->openDocUi(newDoc, |
160 | conf()->confGlobAutoStart(), | 160 | conf()->confGlobAutoStart(), |
161 | openDeeplocked)) { | 161 | openDeeplocked)) { |
162 | delete newDoc; | 162 | delete newDoc; |
163 | } | 163 | } |
164 | 164 | ||
165 | //US ENH for embedded devices: in the case of failure, open a document the default way | 165 | //US ENH for embedded devices: in the case of failure, open a document the default way |
166 | createMainWnd(conf()->confGlobAutoStart(), | 166 | createMainWnd(conf()->confGlobAutoStart(), |
167 | openDeeplocked, | 167 | openDeeplocked, |
168 | true, | 168 | true, |
169 | 0, | 169 | 0, |
170 | savedCmd.minimized); | 170 | savedCmd.minimized); |
171 | 171 | ||
172 | 172 | ||
173 | 173 | ||
174 | 174 | ||
175 | //} | 175 | //} |
176 | } else { | 176 | } else { |
177 | createMainWnd(conf()->confGlobAutoStart(), | 177 | createMainWnd(conf()->confGlobAutoStart(), |
178 | openDeeplocked, | 178 | openDeeplocked, |
179 | true, | 179 | true, |
180 | 0, | 180 | 0, |
181 | savedCmd.minimized); | 181 | savedCmd.minimized); |
182 | } | 182 | } |
183 | runStatus = running; | 183 | runStatus = running; |
184 | } | 184 | } |
185 | 185 | ||
186 | void PwMInit::shutdownApp(int exitStatus) | 186 | void PwMInit::shutdownApp(int exitStatus) |
187 | { | 187 | { |
188 | 188 | ||
189 | 189 | ||
190 | PwM * iii; | 190 | PwM * iii;; |
191 | while ( iii = _mainWndList.first() ) { | 191 | while ( _mainWndList.count() ) { |
192 | iii = _mainWndList.first(); | ||
192 | disconnect(iii, SIGNAL(closed(PwM *)), | 193 | disconnect(iii, SIGNAL(closed(PwM *)), |
193 | this, SLOT(mainWndClosed(PwM *))); | 194 | this, SLOT(mainWndClosed(PwM *))); |
194 | mainWndClosed((iii)); | 195 | mainWndClosed((iii)); |
195 | } | 196 | } |
196 | 197 | ||
197 | printDebug(string("PwMInit::shutdownApp(") | 198 | printDebug(string("PwMInit::shutdownApp(") |
198 | + tostr(exitStatus) + ") called."); | 199 | + tostr(exitStatus) + ") called."); |
199 | PWM_ASSERT((runStatus == running) || (runStatus == init)); | 200 | PWM_ASSERT((runStatus == running) || (runStatus == init)); |
200 | runStatus = shutdown; | 201 | runStatus = shutdown; |
201 | QApplication::exit(exitStatus); | 202 | QApplication::exit(exitStatus); |
202 | /* The destructor of PwMInit is called when control | 203 | /* The destructor of PwMInit is called when control |
203 | * leaves main() | 204 | * leaves main() |
204 | */ | 205 | */ |
205 | } | 206 | } |
206 | 207 | ||
207 | void PwMInit::initPosixSignalHandler() | 208 | void PwMInit::initPosixSignalHandler() |
208 | { | 209 | { |
209 | signal(SIGINT, sig_handler); | 210 | signal(SIGINT, sig_handler); |
210 | signal(SIGTERM, sig_handler); | 211 | signal(SIGTERM, sig_handler); |
211 | } | 212 | } |
212 | 213 | ||
213 | void PwMInit::initDCOP() | 214 | void PwMInit::initDCOP() |
214 | { | 215 | { |
215 | #ifndef PWM_EMBEDDED | 216 | #ifndef PWM_EMBEDDED |
216 | _dcopClient = app->dcopClient(); | 217 | _dcopClient = app->dcopClient(); |
217 | _dcopClient->setNotifications(true); | 218 | _dcopClient->setNotifications(true); |
218 | #endif | 219 | #endif |
219 | 220 | ||
220 | } | 221 | } |
221 | 222 | ||
222 | void PwMInit::initKWalletEmu(bool forceDisable, bool forceReload) | 223 | void PwMInit::initKWalletEmu(bool forceDisable, bool forceReload) |
223 | { | 224 | { |
224 | #ifdef CONFIG_KWALLETIF | 225 | #ifdef CONFIG_KWALLETIF |
225 | if (!conf()->confGlobKwalletEmu() || | 226 | if (!conf()->confGlobKwalletEmu() || |
226 | forceDisable) { | 227 | forceDisable) { |
227 | delete_ifnot_null(_kwalletEmu); | 228 | delete_ifnot_null(_kwalletEmu); |
228 | return; | 229 | return; |
229 | } | 230 | } |
230 | try { | 231 | try { |
231 | if (_kwalletEmu && forceReload) | 232 | if (_kwalletEmu && forceReload) |
232 | delete_and_null(_kwalletEmu); | 233 | delete_and_null(_kwalletEmu); |
233 | if (!_kwalletEmu) | 234 | if (!_kwalletEmu) |
234 | _kwalletEmu = new KWalletEmu(this); | 235 | _kwalletEmu = new KWalletEmu(this); |
235 | } catch (PwMException e) { | 236 | } catch (PwMException e) { |
236 | string errMsg("initializing KWallet emulation failed. ID: "); | 237 | string errMsg("initializing KWallet emulation failed. ID: "); |
237 | errMsg += tostr(static_cast<int>(e.getId())); | 238 | errMsg += tostr(static_cast<int>(e.getId())); |
238 | errMsg += " err-message: "; | 239 | errMsg += " err-message: "; |
239 | errMsg += e.getMessage(); | 240 | errMsg += e.getMessage(); |
240 | printWarn(errMsg); | 241 | printWarn(errMsg); |
241 | return; | 242 | return; |
242 | } | 243 | } |
243 | #else // CONFIG_KWALLETIF | 244 | #else // CONFIG_KWALLETIF |
244 | PARAM_UNUSED(forceDisable); | 245 | PARAM_UNUSED(forceDisable); |
245 | PARAM_UNUSED(forceReload); | 246 | PARAM_UNUSED(forceReload); |
246 | #endif // CONFIG_KWALLETIF | 247 | #endif // CONFIG_KWALLETIF |
247 | } | 248 | } |
248 | 249 | ||
249 | void PwMInit::initKeycard() | 250 | void PwMInit::initKeycard() |
250 | { | 251 | { |
251 | #ifdef CONFIG_KEYCARD | 252 | #ifdef CONFIG_KEYCARD |
252 | PWM_ASSERT(!_keycard); | 253 | PWM_ASSERT(!_keycard); |
253 | _keycard = new PwMKeyCard(this); | 254 | _keycard = new PwMKeyCard(this); |
254 | #endif // CONFIG_KEYCARD | 255 | #endif // CONFIG_KEYCARD |
255 | } | 256 | } |
256 | 257 | ||
257 | void PwMInit::initTray() | 258 | void PwMInit::initTray() |
258 | { | 259 | { |
259 | #ifdef PWM_EMBEDDED | 260 | #ifdef PWM_EMBEDDED |
260 | //US ENH : embedded version does not support a tray | 261 | //US ENH : embedded version does not support a tray |
261 | return; | 262 | return; |
262 | #endif | 263 | #endif |
263 | 264 | ||
264 | if (!conf()->confGlobTray()) { | 265 | if (!conf()->confGlobTray()) { |
265 | if (!_tray) | 266 | if (!_tray) |
266 | return; | 267 | return; |
267 | _tray->hide(); | 268 | _tray->hide(); |
268 | delete_and_null(_tray); | 269 | delete_and_null(_tray); |
269 | return; | 270 | return; |
270 | } | 271 | } |
271 | if (_tray) | 272 | if (_tray) |
272 | return; | 273 | return; |
273 | _tray = new PwMTray(this); | 274 | _tray = new PwMTray(this); |
274 | connect(_tray, SIGNAL(quitSelected()), | 275 | connect(_tray, SIGNAL(quitSelected()), |
275 | this, SLOT(removeTrayAndQuit())); | 276 | this, SLOT(removeTrayAndQuit())); |
276 | connect(_tray, SIGNAL(closed(PwMTray *)), | 277 | connect(_tray, SIGNAL(closed(PwMTray *)), |
277 | this, SLOT(trayIconClosed(PwMTray *))); | 278 | this, SLOT(trayIconClosed(PwMTray *))); |
278 | KIconLoader icons; | 279 | KIconLoader icons; |
279 | #ifndef PWM_EMBEDDED | 280 | #ifndef PWM_EMBEDDED |
280 | _tray->setPixmap(icons.loadIcon(PACKAGE_NAME, KIcon::Small)); | 281 | _tray->setPixmap(icons.loadIcon(PACKAGE_NAME, KIcon::Small)); |
281 | #endif | 282 | #endif |
282 | _tray->show(); | 283 | _tray->show(); |
283 | // connect the signals of all open documents. | 284 | // connect the signals of all open documents. |
284 | const vector<PwMDocList::listItem> *dl = PwMDoc::getOpenDocList()->getList(); | 285 | const vector<PwMDocList::listItem> *dl = PwMDoc::getOpenDocList()->getList(); |
285 | vector<PwMDocList::listItem>::const_iterator i = dl->begin(), | 286 | vector<PwMDocList::listItem>::const_iterator i = dl->begin(), |
286 | end = dl->end(); | 287 | end = dl->end(); |
287 | while (i != end) { | 288 | while (i != end) { |
288 | _tray->connectDocToTray((*i).doc); | 289 | _tray->connectDocToTray((*i).doc); |
289 | ++i; | 290 | ++i; |
290 | } | 291 | } |
291 | } | 292 | } |
292 | 293 | ||
293 | void PwMInit::removeTrayAndQuit() | 294 | void PwMInit::removeTrayAndQuit() |
294 | { | 295 | { |
295 | PWM_ASSERT(_tray); | 296 | PWM_ASSERT(_tray); |
296 | // _tray is deleted in ~PwMInit | 297 | // _tray is deleted in ~PwMInit |
297 | shutdownApp(0); | 298 | shutdownApp(0); |
298 | } | 299 | } |
299 | 300 | ||
300 | PwM * PwMInit::createMainWnd(const QString &loadFile, | 301 | PwM * PwMInit::createMainWnd(const QString &loadFile, |
301 | bool loadFileDeepLocked, | 302 | bool loadFileDeepLocked, |
302 | bool virginity, | 303 | bool virginity, |
303 | PwMDoc *doc, | 304 | PwMDoc *doc, |
304 | bool minimized) | 305 | bool minimized) |
305 | { | 306 | { |
306 | PwM *newWnd; | 307 | PwM *newWnd; |
307 | if (!doc) | 308 | if (!doc) |
308 | doc = createDoc(); | 309 | doc = createDoc(); |
309 | newWnd = new PwM(this, doc, virginity); | 310 | newWnd = new PwM(this, doc, virginity); |
310 | #ifndef PWM_EMBEDDED | 311 | #ifndef PWM_EMBEDDED |
311 | _mainWndList.push_back(newWnd); | 312 | _mainWndList.push_back(newWnd); |
312 | #else | 313 | #else |
313 | _mainWndList.append(newWnd); | 314 | _mainWndList.append(newWnd); |
314 | #endif | 315 | #endif |
315 | connect(newWnd, SIGNAL(closed(PwM *)), | 316 | connect(newWnd, SIGNAL(closed(PwM *)), |
316 | this, SLOT(mainWndClosed(PwM *))); | 317 | this, SLOT(mainWndClosed(PwM *))); |
317 | connect(newWnd, SIGNAL(gotFocus(PwM *)), | 318 | connect(newWnd, SIGNAL(gotFocus(PwM *)), |
318 | this, SLOT(setCurWidget(PwM *))); | 319 | this, SLOT(setCurWidget(PwM *))); |
319 | connect(newWnd, SIGNAL(lostFocus(PwM *)), | 320 | connect(newWnd, SIGNAL(lostFocus(PwM *)), |