author | ulf69 <ulf69> | 2004-10-19 01:12:41 (UTC) |
---|---|---|
committer | ulf69 <ulf69> | 2004-10-19 01:12:41 (UTC) |
commit | 6fdb13cb4142ecde29fd537ff32a3e8e6cc30b26 (patch) (unidiff) | |
tree | 760ad21fcdc4e2d885c5d875d91629a70ce89843 | |
parent | da724334d46c01ee9d4f04101dab5d048c35c833 (diff) | |
download | kdepimpi-6fdb13cb4142ecde29fd537ff32a3e8e6cc30b26.zip kdepimpi-6fdb13cb4142ecde29fd537ff32a3e8e6cc30b26.tar.gz kdepimpi-6fdb13cb4142ecde29fd537ff32a3e8e6cc30b26.tar.bz2 |
added whats new page
-rw-r--r-- | pwmanager/pwmanager/pwm.cpp | 13 | ||||
-rw-r--r-- | pwmanager/pwmanager/pwm.h | 1 |
2 files changed, 12 insertions, 2 deletions
diff --git a/pwmanager/pwmanager/pwm.cpp b/pwmanager/pwmanager/pwm.cpp index 57b4432..26a44b1 100644 --- a/pwmanager/pwmanager/pwm.cpp +++ b/pwmanager/pwmanager/pwm.cpp | |||
@@ -112,49 +112,50 @@ enum { | |||
112 | }; | 112 | }; |
113 | // Button IDs for "export" popup menu (in "file" popup menu) | 113 | // Button IDs for "export" popup menu (in "file" popup menu) |
114 | enum { | 114 | enum { |
115 | BUTTON_POPUP_EXPORT_TEXT = 0, | 115 | BUTTON_POPUP_EXPORT_TEXT = 0, |
116 | BUTTON_POPUP_EXPORT_GPASMAN | 116 | BUTTON_POPUP_EXPORT_GPASMAN |
117 | #ifdef CONFIG_KWALLETIF | 117 | #ifdef CONFIG_KWALLETIF |
118 | ,BUTTON_POPUP_EXPORT_KWALLET | 118 | ,BUTTON_POPUP_EXPORT_KWALLET |
119 | #endif | 119 | #endif |
120 | }; | 120 | }; |
121 | // Button IDs for "import" popup menu (in "file" popup menu) | 121 | // Button IDs for "import" popup menu (in "file" popup menu) |
122 | enum { | 122 | enum { |
123 | BUTTON_POPUP_IMPORT_TEXT = 0, | 123 | BUTTON_POPUP_IMPORT_TEXT = 0, |
124 | BUTTON_POPUP_IMPORT_GPASMAN | 124 | BUTTON_POPUP_IMPORT_GPASMAN |
125 | #ifdef CONFIG_KWALLETIF | 125 | #ifdef CONFIG_KWALLETIF |
126 | ,BUTTON_POPUP_IMPORT_KWALLET | 126 | ,BUTTON_POPUP_IMPORT_KWALLET |
127 | #endif | 127 | #endif |
128 | }; | 128 | }; |
129 | 129 | ||
130 | #ifdef PWM_EMBEDDED | 130 | #ifdef PWM_EMBEDDED |
131 | // Button IDs for "help" popup menu | 131 | // Button IDs for "help" popup menu |
132 | enum { | 132 | enum { |
133 | BUTTON_POPUP_HELP_LICENSE = 0, | 133 | BUTTON_POPUP_HELP_LICENSE = 0, |
134 | BUTTON_POPUP_HELP_FAQ, | 134 | BUTTON_POPUP_HELP_FAQ, |
135 | BUTTON_POPUP_HELP_ABOUT, | 135 | BUTTON_POPUP_HELP_ABOUT, |
136 | BUTTON_POPUP_HELP_SYNC | 136 | BUTTON_POPUP_HELP_SYNC, |
137 | BUTTON_POPUP_HELP_WHATSNEW | ||
137 | }; | 138 | }; |
138 | #endif | 139 | #endif |
139 | 140 | ||
140 | // Button IDs for toolbar | 141 | // Button IDs for toolbar |
141 | enum { | 142 | enum { |
142 | BUTTON_TOOL_NEW = 0, | 143 | BUTTON_TOOL_NEW = 0, |
143 | BUTTON_TOOL_OPEN, | 144 | BUTTON_TOOL_OPEN, |
144 | BUTTON_TOOL_SAVE, | 145 | BUTTON_TOOL_SAVE, |
145 | BUTTON_TOOL_SAVEAS, | 146 | BUTTON_TOOL_SAVEAS, |
146 | BUTTON_TOOL_PRINT, | 147 | BUTTON_TOOL_PRINT, |
147 | BUTTON_TOOL_ADD, | 148 | BUTTON_TOOL_ADD, |
148 | BUTTON_TOOL_EDIT, | 149 | BUTTON_TOOL_EDIT, |
149 | BUTTON_TOOL_DEL, | 150 | BUTTON_TOOL_DEL, |
150 | BUTTON_TOOL_FIND, | 151 | BUTTON_TOOL_FIND, |
151 | BUTTON_TOOL_LOCK, | 152 | BUTTON_TOOL_LOCK, |
152 | BUTTON_TOOL_DEEPLOCK, | 153 | BUTTON_TOOL_DEEPLOCK, |
153 | BUTTON_TOOL_UNLOCK | 154 | BUTTON_TOOL_UNLOCK |
154 | }; | 155 | }; |
155 | 156 | ||
156 | 157 | ||
157 | PwM::PwM(PwMInit *_init, PwMDoc *doc, | 158 | PwM::PwM(PwMInit *_init, PwMDoc *doc, |
158 | bool virginity, | 159 | bool virginity, |
159 | QWidget *parent, const char *name) | 160 | QWidget *parent, const char *name) |
160 | : KMainWindow(parent, "HALLO") | 161 | : KMainWindow(parent, "HALLO") |
@@ -342,48 +343,52 @@ void PwM::initMenubar() | |||
342 | 343 | ||
343 | 344 | ||
344 | 345 | ||
345 | 346 | ||
346 | 347 | ||
347 | helpPopup = new KPopupMenu(this); | 348 | helpPopup = new KPopupMenu(this); |
348 | 349 | ||
349 | 350 | ||
350 | helpPopup->insertItem(i18n("&License"), this, | 351 | helpPopup->insertItem(i18n("&License"), this, |
351 | SLOT(showLicense_slot()), 0, | 352 | SLOT(showLicense_slot()), 0, |
352 | BUTTON_POPUP_HELP_LICENSE); | 353 | BUTTON_POPUP_HELP_LICENSE); |
353 | 354 | ||
354 | helpPopup->insertItem(i18n("&Faq"), this, | 355 | helpPopup->insertItem(i18n("&Faq"), this, |
355 | SLOT(faq_slot()), 0, | 356 | SLOT(faq_slot()), 0, |
356 | BUTTON_POPUP_HELP_FAQ); | 357 | BUTTON_POPUP_HELP_FAQ); |
357 | 358 | ||
358 | helpPopup->insertItem(i18n("&About PwManager"), this, | 359 | helpPopup->insertItem(i18n("&About PwManager"), this, |
359 | SLOT(createAboutData_slot()), 0, | 360 | SLOT(createAboutData_slot()), 0, |
360 | BUTTON_POPUP_HELP_ABOUT); | 361 | BUTTON_POPUP_HELP_ABOUT); |
361 | 362 | ||
362 | helpPopup->insertItem(i18n("&Sync HowTo"), this, | 363 | helpPopup->insertItem(i18n("&Sync HowTo"), this, |
363 | SLOT(syncHowTo_slot()), 0, | 364 | SLOT(syncHowTo_slot()), 0, |
364 | BUTTON_POPUP_HELP_SYNC); | 365 | BUTTON_POPUP_HELP_SYNC); |
365 | 366 | ||
367 | helpPopup->insertItem(i18n("&What's New"), this, | ||
368 | SLOT(whatsnew_slot()), 0, | ||
369 | BUTTON_POPUP_HELP_WHATSNEW); | ||
370 | |||
366 | #endif | 371 | #endif |
367 | menuBar()->insertItem(i18n("&Help"), helpPopup); | 372 | menuBar()->insertItem(i18n("&Help"), helpPopup); |
368 | 373 | ||
369 | } | 374 | } |
370 | 375 | ||
371 | void PwM::initToolbar() | 376 | void PwM::initToolbar() |
372 | { | 377 | { |
373 | KIconLoader* picons; | 378 | KIconLoader* picons; |
374 | #ifndef PWM_EMBEDDED | 379 | #ifndef PWM_EMBEDDED |
375 | KIconLoader icons; | 380 | KIconLoader icons; |
376 | picons = &icons; | 381 | picons = &icons; |
377 | #else | 382 | #else |
378 | picons = KGlobal::iconLoader(); | 383 | picons = KGlobal::iconLoader(); |
379 | #endif | 384 | #endif |
380 | 385 | ||
381 | #ifdef PWM_EMBEDDED | 386 | #ifdef PWM_EMBEDDED |
382 | if ( QApplication::desktop()->width() > 320 ) | 387 | if ( QApplication::desktop()->width() > 320 ) |
383 | #endif | 388 | #endif |
384 | { | 389 | { |
385 | toolBar()->insertButton(picons->loadIcon("filenew", KIcon::Toolbar), | 390 | toolBar()->insertButton(picons->loadIcon("filenew", KIcon::Toolbar), |
386 | BUTTON_TOOL_NEW, SIGNAL(clicked(int)), this, | 391 | BUTTON_TOOL_NEW, SIGNAL(clicked(int)), this, |
387 | SLOT(new_slot()), true, i18n("New")); | 392 | SLOT(new_slot()), true, i18n("New")); |
388 | toolBar()->insertButton(picons->loadIcon("fileopen", KIcon::Toolbar), | 393 | toolBar()->insertButton(picons->loadIcon("fileopen", KIcon::Toolbar), |
389 | BUTTON_TOOL_OPEN, SIGNAL(clicked(int)), this, | 394 | BUTTON_TOOL_OPEN, SIGNAL(clicked(int)), this, |
@@ -1267,61 +1272,65 @@ void PwM::copyToClipboard(const QString &s) | |||
1267 | } | 1272 | } |
1268 | 1273 | ||
1269 | void PwM::showStatMsg(const QString &msg) | 1274 | void PwM::showStatMsg(const QString &msg) |
1270 | { | 1275 | { |
1271 | #ifndef PWM_EMBEDDED | 1276 | #ifndef PWM_EMBEDDED |
1272 | KStatusBar *statBar = statusBar(); | 1277 | KStatusBar *statBar = statusBar(); |
1273 | statBar->message(msg, STATUSBAR_MSG_TIMEOUT * 1000); | 1278 | statBar->message(msg, STATUSBAR_MSG_TIMEOUT * 1000); |
1274 | #else | 1279 | #else |
1275 | qDebug("Statusbar : %s",msg.latin1()); | 1280 | qDebug("Statusbar : %s",msg.latin1()); |
1276 | #endif | 1281 | #endif |
1277 | } | 1282 | } |
1278 | 1283 | ||
1279 | void PwM::focusInEvent(QFocusEvent *e) | 1284 | void PwM::focusInEvent(QFocusEvent *e) |
1280 | { | 1285 | { |
1281 | if (e->gotFocus()) { | 1286 | if (e->gotFocus()) { |
1282 | emit gotFocus(this); | 1287 | emit gotFocus(this); |
1283 | } else if (e->lostFocus()) { | 1288 | } else if (e->lostFocus()) { |
1284 | emit lostFocus(this); | 1289 | emit lostFocus(this); |
1285 | } | 1290 | } |
1286 | } | 1291 | } |
1287 | 1292 | ||
1288 | 1293 | ||
1289 | #ifdef PWM_EMBEDDED | 1294 | #ifdef PWM_EMBEDDED |
1290 | 1295 | ||
1296 | void PwM::whatsnew_slot() | ||
1297 | { | ||
1298 | KApplication::showFile( "KDE-Pim/Pi Version Info", "kdepim/WhatsNew.txt" ); | ||
1299 | } | ||
1300 | |||
1291 | void PwM::showLicense_slot() | 1301 | void PwM::showLicense_slot() |
1292 | { | 1302 | { |
1293 | KApplication::showLicence(); | 1303 | KApplication::showLicence(); |
1294 | } | 1304 | } |
1295 | 1305 | ||
1296 | void PwM::faq_slot() | 1306 | void PwM::faq_slot() |
1297 | { | 1307 | { |
1298 | KApplication::showFile( "PWM/Pi FAQ", "kdepim/pwmanager/pwmanagerFAQ.txt" ); | 1308 | KApplication::showFile( "PWM/Pi FAQ", "kdepim/pwmanager/pwmanagerFAQ.txt" ); |
1299 | } | 1309 | } |
1300 | 1310 | ||
1301 | void PwM::syncHowTo_slot() | 1311 | void PwM::syncHowTo_slot() |
1302 | { | 1312 | { |
1303 | qDebug("PwM::syncHowTo_slot"); | ||
1304 | KApplication::showFile( "KDE-Pim/Pi Synchronization HowTo", "kdepim/SyncHowto.txt" ); | 1313 | KApplication::showFile( "KDE-Pim/Pi Synchronization HowTo", "kdepim/SyncHowto.txt" ); |
1305 | } | 1314 | } |
1306 | 1315 | ||
1307 | 1316 | ||
1308 | void PwM::createAboutData_slot() | 1317 | void PwM::createAboutData_slot() |
1309 | { | 1318 | { |
1310 | QString version; | 1319 | QString version; |
1311 | #include <../version> | 1320 | #include <../version> |
1312 | QMessageBox::about( this, "About PwManager/Pi", | 1321 | QMessageBox::about( this, "About PwManager/Pi", |
1313 | "PwManager/Platform-independent\n" | 1322 | "PwManager/Platform-independent\n" |
1314 | "(PWM/Pi) " +version + " - " + | 1323 | "(PWM/Pi) " +version + " - " + |
1315 | #ifdef DESKTOP_VERSION | 1324 | #ifdef DESKTOP_VERSION |
1316 | "Desktop Edition\n" | 1325 | "Desktop Edition\n" |
1317 | #else | 1326 | #else |
1318 | "PDA-Edition\n" | 1327 | "PDA-Edition\n" |
1319 | "for: Zaurus 5500 / 7x0 / 8x0\n" | 1328 | "for: Zaurus 5500 / 7x0 / 8x0\n" |
1320 | #endif | 1329 | #endif |
1321 | 1330 | ||
1322 | "(c) 2004 Ulf Schenk\n" | 1331 | "(c) 2004 Ulf Schenk\n" |
1323 | "(c) 2004 Lutz Rogowski\n" | 1332 | "(c) 2004 Lutz Rogowski\n" |
1324 | "(c) 1997-2004, The KDE PIM Team\n" | 1333 | "(c) 1997-2004, The KDE PIM Team\n" |
1325 | 1334 | ||
1326 | "(c) Michael Buesch - main programming\nand current maintainer\nmbuesch@freenet.de\n" | 1335 | "(c) Michael Buesch - main programming\nand current maintainer\nmbuesch@freenet.de\n" |
1327 | "Matt Scifo - mscifo@o1.com\n" | 1336 | "Matt Scifo - mscifo@o1.com\n" |
diff --git a/pwmanager/pwmanager/pwm.h b/pwmanager/pwmanager/pwm.h index 6ed9d34..fe1f7a1 100644 --- a/pwmanager/pwmanager/pwm.h +++ b/pwmanager/pwmanager/pwm.h | |||
@@ -153,48 +153,49 @@ public slots: | |||
153 | /** lock current document */ | 153 | /** lock current document */ |
154 | void lockWnd_slot(); | 154 | void lockWnd_slot(); |
155 | /** deeplock current document */ | 155 | /** deeplock current document */ |
156 | void deepLockWnd_slot(); | 156 | void deepLockWnd_slot(); |
157 | /** window/unlock triggered */ | 157 | /** window/unlock triggered */ |
158 | void unlockWnd_slot(); | 158 | void unlockWnd_slot(); |
159 | /** find item */ | 159 | /** find item */ |
160 | void find_slot(); | 160 | void find_slot(); |
161 | /** configure clicked */ | 161 | /** configure clicked */ |
162 | void config_slot(); | 162 | void config_slot(); |
163 | /** (de)activate the "change master pw" button in the menu-bar */ | 163 | /** (de)activate the "change master pw" button in the menu-bar */ |
164 | void activateMpButton(bool activate = true); | 164 | void activateMpButton(bool activate = true); |
165 | /** generate a new chipcard */ | 165 | /** generate a new chipcard */ |
166 | void genNewCard_slot(); | 166 | void genNewCard_slot(); |
167 | /** completely erase the current card */ | 167 | /** completely erase the current card */ |
168 | void eraseCard_slot(); | 168 | void eraseCard_slot(); |
169 | /** returns the ID number of the current card */ | 169 | /** returns the ID number of the current card */ |
170 | void readCardId_slot(); | 170 | void readCardId_slot(); |
171 | /** make backup image of the current card */ | 171 | /** make backup image of the current card */ |
172 | void makeCardBackup_slot(); | 172 | void makeCardBackup_slot(); |
173 | /** write backup image to current card */ | 173 | /** write backup image to current card */ |
174 | void replayCardBackup_slot(); | 174 | void replayCardBackup_slot(); |
175 | 175 | ||
176 | #ifdef PWM_EMBEDDED | 176 | #ifdef PWM_EMBEDDED |
177 | void whatsnew_slot(); | ||
177 | void showLicense_slot(); | 178 | void showLicense_slot(); |
178 | void faq_slot(); | 179 | void faq_slot(); |
179 | void createAboutData_slot(); | 180 | void createAboutData_slot(); |
180 | void syncHowTo_slot(); | 181 | void syncHowTo_slot(); |
181 | #endif | 182 | #endif |
182 | 183 | ||
183 | protected: | 184 | protected: |
184 | /** is this window virgin? */ | 185 | /** is this window virgin? */ |
185 | bool isVirgin() | 186 | bool isVirgin() |
186 | { return virgin; } | 187 | { return virgin; } |
187 | /** add/remove virginity */ | 188 | /** add/remove virginity */ |
188 | void setVirgin(bool v); | 189 | void setVirgin(bool v); |
189 | /** initialize the menubar */ | 190 | /** initialize the menubar */ |
190 | void initMenubar(); | 191 | void initMenubar(); |
191 | /** initialize the toolbar */ | 192 | /** initialize the toolbar */ |
192 | void initToolbar(); | 193 | void initToolbar(); |
193 | /** initialize the window-metrics */ | 194 | /** initialize the window-metrics */ |
194 | void initMetrics(); | 195 | void initMetrics(); |
195 | /** close-event */ | 196 | /** close-event */ |
196 | void closeEvent(QCloseEvent *e); | 197 | void closeEvent(QCloseEvent *e); |
197 | /** creates a new PwM-ListView and returns it */ | 198 | /** creates a new PwM-ListView and returns it */ |
198 | PwMView * makeNewListView(PwMDoc *doc); | 199 | PwMView * makeNewListView(PwMDoc *doc); |
199 | /** Window hide-event */ | 200 | /** Window hide-event */ |
200 | void hideEvent(QHideEvent *); | 201 | void hideEvent(QHideEvent *); |