-rw-r--r-- | core/pim/addressbook/addressbook.cpp | 16 | ||||
-rw-r--r-- | core/pim/addressbook/contacteditor.cpp | 255 | ||||
-rw-r--r-- | core/pim/addressbook/contacteditor.h | 4 |
3 files changed, 261 insertions, 14 deletions
diff --git a/core/pim/addressbook/addressbook.cpp b/core/pim/addressbook/addressbook.cpp index e8fa37c..5a8038b 100644 --- a/core/pim/addressbook/addressbook.cpp +++ b/core/pim/addressbook/addressbook.cpp | |||
@@ -29,7 +29,11 @@ | |||
29 | #include <qpe/qpeapplication.h> | 29 | #include <qpe/qpeapplication.h> |
30 | #include <qpe/config.h> | 30 | #include <qpe/config.h> |
31 | #include <qpe/contact.h> | 31 | #include <qpe/contact.h> |
32 | |||
33 | #ifndef MAKE_FOR_SHARP_ROM | ||
32 | #include <qpe/finddialog.h> | 34 | #include <qpe/finddialog.h> |
35 | #endif | ||
36 | |||
33 | #include <qpe/global.h> | 37 | #include <qpe/global.h> |
34 | #include <qpe/resource.h> | 38 | #include <qpe/resource.h> |
35 | #include <qpe/ir.h> | 39 | #include <qpe/ir.h> |
@@ -129,12 +133,14 @@ AddressbookWindow::AddressbookWindow( QWidget *parent, const char *name, | |||
129 | a->addTo( edit ); | 133 | a->addTo( edit ); |
130 | a->addTo( listTools ); | 134 | a->addTo( listTools ); |
131 | 135 | ||
136 | #ifndef MAKE_FOR_SHARP_ROM | ||
132 | a = new QAction( tr( "Find" ), Resource::loadPixmap( "mag" ), | 137 | a = new QAction( tr( "Find" ), Resource::loadPixmap( "mag" ), |
133 | QString::null, 0, this, 0 ); | 138 | QString::null, 0, this, 0 ); |
134 | actionFind = a; | 139 | actionFind = a; |
135 | connect( a, SIGNAL(activated()), this, SLOT(slotFind()) ); | 140 | connect( a, SIGNAL(activated()), this, SLOT(slotFind()) ); |
136 | a->addTo( edit ); | 141 | a->addTo( edit ); |
137 | a->addTo( listTools ); | 142 | a->addTo( listTools ); |
143 | #endif | ||
138 | 144 | ||
139 | 145 | ||
140 | a = new QAction( tr( "Write Mail To" ), Resource::loadPixmap( "qtmail/reply" ), | 146 | a = new QAction( tr( "Write Mail To" ), Resource::loadPixmap( "qtmail/reply" ), |
@@ -510,7 +516,9 @@ void AddressbookWindow::slotPersonalView() | |||
510 | setCaption( tr("Contacts") ); | 516 | setCaption( tr("Contacts") ); |
511 | actionNew->setEnabled(TRUE); | 517 | actionNew->setEnabled(TRUE); |
512 | actionTrash->setEnabled(TRUE); | 518 | actionTrash->setEnabled(TRUE); |
519 | #ifndef MAKE_FOR_SHARP_ROM | ||
513 | actionFind->setEnabled(TRUE); | 520 | actionFind->setEnabled(TRUE); |
521 | #endif | ||
514 | slotUpdateToolbar(); // maybe some of the above could be moved there | 522 | slotUpdateToolbar(); // maybe some of the above could be moved there |
515 | showList(); | 523 | showList(); |
516 | return; | 524 | return; |
@@ -519,7 +527,9 @@ void AddressbookWindow::slotPersonalView() | |||
519 | // XXX need to disable some QActions. | 527 | // XXX need to disable some QActions. |
520 | actionNew->setEnabled(FALSE); | 528 | actionNew->setEnabled(FALSE); |
521 | actionTrash->setEnabled(FALSE); | 529 | actionTrash->setEnabled(FALSE); |
530 | #ifndef MAKE_FOR_SHARP_ROM | ||
522 | actionFind->setEnabled(FALSE); | 531 | actionFind->setEnabled(FALSE); |
532 | #endif | ||
523 | actionMail->setEnabled(FALSE); | 533 | actionMail->setEnabled(FALSE); |
524 | 534 | ||
525 | setCaption( tr("Contacts - My Personal Details") ); | 535 | setCaption( tr("Contacts - My Personal Details") ); |
@@ -776,16 +786,22 @@ AbLabel *AddressbookWindow::abView() | |||
776 | 786 | ||
777 | void AddressbookWindow::slotFind() | 787 | void AddressbookWindow::slotFind() |
778 | { | 788 | { |
789 | #ifndef MAKE_FOR_SHARP_ROM | ||
779 | if ( centralWidget() == abView() ) | 790 | if ( centralWidget() == abView() ) |
780 | showList(); | 791 | showList(); |
792 | |||
781 | FindDialog frmFind( "Contacts", this ); | 793 | FindDialog frmFind( "Contacts", this ); |
782 | QObject::connect( &frmFind, SIGNAL(signalFindClicked(const QString &, bool, bool, int)), abList, SLOT(slotDoFind( const QString&,bool,bool,int))); | 794 | QObject::connect( &frmFind, SIGNAL(signalFindClicked(const QString &, bool, bool, int)), abList, SLOT(slotDoFind( const QString&,bool,bool,int))); |
783 | QObject::connect( abList, SIGNAL(signalNotFound()), &frmFind, SLOT(slotNotFound()) ); | 795 | QObject::connect( abList, SIGNAL(signalNotFound()), &frmFind, SLOT(slotNotFound()) ); |
784 | QObject::connect( abList, SIGNAL(signalWrapAround()), &frmFind, SLOT(slotWrapAround()) ); | 796 | QObject::connect( abList, SIGNAL(signalWrapAround()), &frmFind, SLOT(slotWrapAround()) ); |
797 | |||
785 | frmFind.exec(); | 798 | frmFind.exec(); |
799 | |||
786 | if ( abList->numSelections() ) | 800 | if ( abList->numSelections() ) |
787 | abList->clearSelection(); | 801 | abList->clearSelection(); |
802 | |||
788 | abList->clearFindRow(); | 803 | abList->clearFindRow(); |
804 | #endif | ||
789 | } | 805 | } |
790 | 806 | ||
791 | void AddressbookWindow::slotSetCategory( int c ) | 807 | void AddressbookWindow::slotSetCategory( int c ) |
diff --git a/core/pim/addressbook/contacteditor.cpp b/core/pim/addressbook/contacteditor.cpp index 6edab2c..cbcd11f 100644 --- a/core/pim/addressbook/contacteditor.cpp +++ b/core/pim/addressbook/contacteditor.cpp | |||
@@ -283,7 +283,7 @@ void ContactEditor::init() { | |||
283 | QWidget *container = new QWidget( svGeneral->viewport() ); | 283 | QWidget *container = new QWidget( svGeneral->viewport() ); |
284 | svGeneral->addChild( container ); | 284 | svGeneral->addChild( container ); |
285 | 285 | ||
286 | QGridLayout *gl = new QGridLayout( container, 1, 1, 2, 3 ); | 286 | QGridLayout *gl = new QGridLayout( container, 1, 1, 2, 4 ); |
287 | gl->setResizeMode( QLayout::FreeResize ); | 287 | gl->setResizeMode( QLayout::FreeResize ); |
288 | 288 | ||
289 | btnFullName = new QPushButton( tr( "Full Name..." ), container ); | 289 | btnFullName = new QPushButton( tr( "Full Name..." ), container ); |
@@ -302,19 +302,19 @@ void ContactEditor::init() { | |||
302 | gl->addWidget( txtOrganization, 2, 1 ); | 302 | gl->addWidget( txtOrganization, 2, 1 ); |
303 | 303 | ||
304 | cmbChooserField1 = new QComboBox( FALSE, container ); | 304 | cmbChooserField1 = new QComboBox( FALSE, container ); |
305 | cmbChooserField1->setMaximumWidth( 100 ); | 305 | cmbChooserField1->setMaximumWidth( 90 ); |
306 | gl->addWidget( cmbChooserField1, 3, 0 ); | 306 | gl->addWidget( cmbChooserField1, 3, 0 ); |
307 | txtChooserField1 = new QLineEdit( container ); | 307 | txtChooserField1 = new QLineEdit( container ); |
308 | gl->addWidget( txtChooserField1, 3, 1 ); | 308 | gl->addWidget( txtChooserField1, 3, 1 ); |
309 | 309 | ||
310 | cmbChooserField2 = new QComboBox( FALSE, container ); | 310 | cmbChooserField2 = new QComboBox( FALSE, container ); |
311 | cmbChooserField2->setMaximumWidth( 100 ); | 311 | cmbChooserField2->setMaximumWidth( 90 ); |
312 | gl->addWidget( cmbChooserField2, 4, 0 ); | 312 | gl->addWidget( cmbChooserField2, 4, 0 ); |
313 | txtChooserField2 = new QLineEdit( container ); | 313 | txtChooserField2 = new QLineEdit( container ); |
314 | gl->addWidget( txtChooserField2, 4, 1 ); | 314 | gl->addWidget( txtChooserField2, 4, 1 ); |
315 | 315 | ||
316 | cmbChooserField3 = new QComboBox( FALSE, container ); | 316 | cmbChooserField3 = new QComboBox( FALSE, container ); |
317 | cmbChooserField3->setMaximumWidth( 100 ); | 317 | cmbChooserField3->setMaximumWidth( 90 ); |
318 | gl->addWidget( cmbChooserField3, 5, 0 ); | 318 | gl->addWidget( cmbChooserField3, 5, 0 ); |
319 | txtChooserField3 = new QLineEdit( container ); | 319 | txtChooserField3 = new QLineEdit( container ); |
320 | gl->addWidget( txtChooserField3, 5, 1 ); | 320 | gl->addWidget( txtChooserField3, 5, 1 ); |
@@ -346,7 +346,7 @@ void ContactEditor::init() { | |||
346 | container = new QWidget( svAddress->viewport() ); | 346 | container = new QWidget( svAddress->viewport() ); |
347 | svAddress->addChild( container ); | 347 | svAddress->addChild( container ); |
348 | 348 | ||
349 | gl = new QGridLayout( container, 5, 3, 2, 3 ); | 349 | gl = new QGridLayout( container, 6, 3, 2, 4 ); |
350 | 350 | ||
351 | cmbAddress = new QComboBox( FALSE, container ); | 351 | cmbAddress = new QComboBox( FALSE, container ); |
352 | cmbAddress->insertItem( tr( "Business" ) ); | 352 | cmbAddress->insertItem( tr( "Business" ) ); |
@@ -387,16 +387,226 @@ void ContactEditor::init() { | |||
387 | gl->addWidget( l, 5, 0 ); | 387 | gl->addWidget( l, 5, 0 ); |
388 | cmbCountry = new QComboBox( TRUE, container ); | 388 | cmbCountry = new QComboBox( TRUE, container ); |
389 | cmbCountry->insertItem( tr( "" ) ); | 389 | cmbCountry->insertItem( tr( "" ) ); |
390 | cmbCountry->insertItem( tr( "United States" ) ); | 390 | cmbCountry->insertItem( tr ( "United States" ) ); |
391 | cmbCountry->insertItem( tr( "United Kingdom" ) ); | 391 | cmbCountry->insertItem( tr ( "United Kingdom" ) ); |
392 | cmbCountry->insertItem( tr( "Japan" ) ); | 392 | cmbCountry->insertItem( tr ( "Afganistan" ) ); |
393 | cmbCountry->insertItem( tr( "France" ) ); | 393 | cmbCountry->insertItem( tr ( "Albania" ) ); |
394 | cmbCountry->insertItem( tr( "Germany" ) ); | 394 | cmbCountry->insertItem( tr ( "Algeria" ) ); |
395 | cmbCountry->insertItem( tr( "Norway" ) ); | 395 | cmbCountry->insertItem( tr ( "American Samoa" ) ); |
396 | cmbCountry->insertItem( tr( "Canada" ) ); | 396 | cmbCountry->insertItem( tr ( "Andorra" ) ); |
397 | 397 | cmbCountry->insertItem( tr ( "Angola" ) ); | |
398 | cmbCountry->insertItem( tr ( "Anguilla" ) ); | ||
399 | cmbCountry->insertItem( tr ( "Antartica" ) ); | ||
400 | cmbCountry->insertItem( tr ( "Argentina" ) ); | ||
401 | cmbCountry->insertItem( tr ( "Armania" ) ); | ||
402 | cmbCountry->insertItem( tr ( "Aruba" ) ); | ||
403 | cmbCountry->insertItem( tr ( "Australia" ) ); | ||
404 | cmbCountry->insertItem( tr ( "Austria" ) ); | ||
405 | cmbCountry->insertItem( tr ( "Azerbaijan" ) ); | ||
406 | cmbCountry->insertItem( tr ( "Bahamas" ) ); | ||
407 | cmbCountry->insertItem( tr ( "Bahrain" ) ); | ||
408 | cmbCountry->insertItem( tr ( "Bangladesh" ) ); | ||
409 | cmbCountry->insertItem( tr ( "Barbados" ) ); | ||
410 | cmbCountry->insertItem( tr ( "Belarus" ) ); | ||
411 | cmbCountry->insertItem( tr ( "Belgium" ) ); | ||
412 | cmbCountry->insertItem( tr ( "Belize" ) ); | ||
413 | cmbCountry->insertItem( tr ( "Benin" ) ); | ||
414 | cmbCountry->insertItem( tr ( "Bermuda" ) ); | ||
415 | cmbCountry->insertItem( tr ( "Bhutan" ) ); | ||
416 | cmbCountry->insertItem( tr ( "Boliva" ) ); | ||
417 | cmbCountry->insertItem( tr ( "Botswana" ) ); | ||
418 | cmbCountry->insertItem( tr ( "Bouvet Island" ) ); | ||
419 | cmbCountry->insertItem( tr ( "Brazil" ) ); | ||
420 | cmbCountry->insertItem( tr ( "Brunei Darussalam" ) ); | ||
421 | cmbCountry->insertItem( tr ( "Bulgaria" ) ); | ||
422 | cmbCountry->insertItem( tr ( "Burkina Faso" ) ); | ||
423 | cmbCountry->insertItem( tr ( "Burundi" ) ); | ||
424 | cmbCountry->insertItem( tr ( "Cambodia" ) ); | ||
425 | cmbCountry->insertItem( tr ( "Camaroon" ) ); | ||
426 | cmbCountry->insertItem( tr ( "Canada" ) ); | ||
427 | cmbCountry->insertItem( tr ( "Cape Verde" ) ); | ||
428 | cmbCountry->insertItem( tr ( "Cayman Islands" ) ); | ||
429 | cmbCountry->insertItem( tr ( "Chad" ) ); | ||
430 | cmbCountry->insertItem( tr ( "Chile" ) ); | ||
431 | cmbCountry->insertItem( tr ( "China" ) ); | ||
432 | cmbCountry->insertItem( tr ( "Christmas Island" ) ); | ||
433 | cmbCountry->insertItem( tr ( "Colombia" ) ); | ||
434 | cmbCountry->insertItem( tr ( "Comoros" ) ); | ||
435 | cmbCountry->insertItem( tr ( "Congo" ) ); | ||
436 | cmbCountry->insertItem( tr ( "Cook Island" ) ); | ||
437 | cmbCountry->insertItem( tr ( "Costa Rica" ) ); | ||
438 | cmbCountry->insertItem( tr ( "Cote d'Ivoire" ) ); | ||
439 | cmbCountry->insertItem( tr ( "Croatia" ) ); | ||
440 | cmbCountry->insertItem( tr ( "Cuba" ) ); | ||
441 | cmbCountry->insertItem( tr ( "Cyprus" ) ); | ||
442 | cmbCountry->insertItem( tr ( "Czech Republic" ) ); | ||
443 | cmbCountry->insertItem( tr ( "Denmark" ) ); | ||
444 | cmbCountry->insertItem( tr ( "Djibouti" ) ); | ||
445 | cmbCountry->insertItem( tr ( "Dominica" ) ); | ||
446 | cmbCountry->insertItem( tr ( "Dominican Republic" ) ); | ||
447 | cmbCountry->insertItem( tr ( "East Timor" ) ); | ||
448 | cmbCountry->insertItem( tr ( "Ecuador" ) ); | ||
449 | cmbCountry->insertItem( tr ( "Egypt" ) ); | ||
450 | cmbCountry->insertItem( tr ( "El Salvador" ) ); | ||
451 | cmbCountry->insertItem( tr ( "Equatorial Guinea" ) ); | ||
452 | cmbCountry->insertItem( tr ( "Eritrea" ) ); | ||
453 | cmbCountry->insertItem( tr ( "Estonia" ) ); | ||
454 | cmbCountry->insertItem( tr ( "Ethiopia" ) ); | ||
455 | cmbCountry->insertItem( tr ( "Falkland Islands" ) ); | ||
456 | cmbCountry->insertItem( tr ( "Faroe Islands" ) ); | ||
457 | cmbCountry->insertItem( tr ( "Fiji" ) ); | ||
458 | cmbCountry->insertItem( tr ( "Finland" ) ); | ||
459 | cmbCountry->insertItem( tr ( "France" ) ); | ||
460 | cmbCountry->insertItem( tr ( "French Guiana" ) ); | ||
461 | cmbCountry->insertItem( tr ( "French Polynesia" ) ); | ||
462 | cmbCountry->insertItem( tr ( "Gabon" ) ); | ||
463 | cmbCountry->insertItem( tr ( "Gambia" ) ); | ||
464 | cmbCountry->insertItem( tr ( "Georgia" ) ); | ||
465 | cmbCountry->insertItem( tr ( "Germany" ) ); | ||
466 | cmbCountry->insertItem( tr ( "Gahna" ) ); | ||
467 | cmbCountry->insertItem( tr ( "Gibraltar" ) ); | ||
468 | cmbCountry->insertItem( tr ( "Greece" ) ); | ||
469 | cmbCountry->insertItem( tr ( "Greenland" ) ); | ||
470 | cmbCountry->insertItem( tr ( "Grenada" ) ); | ||
471 | cmbCountry->insertItem( tr ( "Guadelupe" ) ); | ||
472 | cmbCountry->insertItem( tr ( "Guam" ) ); | ||
473 | cmbCountry->insertItem( tr ( "Guatemala" ) ); | ||
474 | cmbCountry->insertItem( tr ( "Guinea" ) ); | ||
475 | cmbCountry->insertItem( tr ( "Guinea-bissau" ) ); | ||
476 | cmbCountry->insertItem( tr ( "Guyana" ) ); | ||
477 | cmbCountry->insertItem( tr ( "Haiti" ) ); | ||
478 | cmbCountry->insertItem( tr ( "Holy See" ) ); | ||
479 | cmbCountry->insertItem( tr ( "Honduras" ) ); | ||
480 | cmbCountry->insertItem( tr ( "Hong Kong" ) ); | ||
481 | cmbCountry->insertItem( tr ( "Hungary" ) ); | ||
482 | cmbCountry->insertItem( tr ( "Iceland" ) ); | ||
483 | cmbCountry->insertItem( tr ( "India" ) ); | ||
484 | cmbCountry->insertItem( tr ( "Indonesia" ) ); | ||
485 | cmbCountry->insertItem( tr ( "Ireland" ) ); | ||
486 | cmbCountry->insertItem( tr ( "Israel" ) ); | ||
487 | cmbCountry->insertItem( tr ( "Italy" ) ); | ||
488 | cmbCountry->insertItem( tr ( "Jamacia" ) ); | ||
489 | cmbCountry->insertItem( tr ( "Japan" ) ); | ||
490 | cmbCountry->insertItem( tr ( "Jordan" ) ); | ||
491 | cmbCountry->insertItem( tr ( "Kazakhstan" ) ); | ||
492 | cmbCountry->insertItem( tr ( "Kenya" ) ); | ||
493 | cmbCountry->insertItem( tr ( "Kribati" ) ); | ||
494 | cmbCountry->insertItem( tr ( "Korea" ) ); | ||
495 | cmbCountry->insertItem( tr ( "Kuait" ) ); | ||
496 | cmbCountry->insertItem( tr ( "Kyrgyztan" ) ); | ||
497 | cmbCountry->insertItem( tr ( "Laos" ) ); | ||
498 | cmbCountry->insertItem( tr ( "Latvia" ) ); | ||
499 | cmbCountry->insertItem( tr ( "Lebanon" ) ); | ||
500 | cmbCountry->insertItem( tr ( "Lesotho" ) ); | ||
501 | cmbCountry->insertItem( tr ( "Liberia" ) ); | ||
502 | cmbCountry->insertItem( tr ( "Liechtenstein" ) ); | ||
503 | cmbCountry->insertItem( tr ( "Lithuania" ) ); | ||
504 | cmbCountry->insertItem( tr ( "Luxembourg" ) ); | ||
505 | cmbCountry->insertItem( tr ( "Macau" ) ); | ||
506 | cmbCountry->insertItem( tr ( "Macedonia" ) ); | ||
507 | cmbCountry->insertItem( tr ( "Madagascar" ) ); | ||
508 | cmbCountry->insertItem( tr ( "Malawi" ) ); | ||
509 | cmbCountry->insertItem( tr ( "Malaysia" ) ); | ||
510 | cmbCountry->insertItem( tr ( "Maldives" ) ); | ||
511 | cmbCountry->insertItem( tr ( "Mali" ) ); | ||
512 | cmbCountry->insertItem( tr ( "Malta" ) ); | ||
513 | cmbCountry->insertItem( tr ( "Martinique" ) ); | ||
514 | cmbCountry->insertItem( tr ( "Mauritania" ) ); | ||
515 | cmbCountry->insertItem( tr ( "Mauritius" ) ); | ||
516 | cmbCountry->insertItem( tr ( "Mayotte" ) ); | ||
517 | cmbCountry->insertItem( tr ( "Mexico" ) ); | ||
518 | cmbCountry->insertItem( tr ( "Micronesia" ) ); | ||
519 | cmbCountry->insertItem( tr ( "Moldova" ) ); | ||
520 | cmbCountry->insertItem( tr ( "Monaco" ) ); | ||
521 | cmbCountry->insertItem( tr ( "Mongolia" ) ); | ||
522 | cmbCountry->insertItem( tr ( "Montserrat" ) ); | ||
523 | cmbCountry->insertItem( tr ( "Morocco" ) ); | ||
524 | cmbCountry->insertItem( tr ( "Mozambique" ) ); | ||
525 | cmbCountry->insertItem( tr ( "Myanmar" ) ); | ||
526 | cmbCountry->insertItem( tr ( "Namibia" ) ); | ||
527 | cmbCountry->insertItem( tr ( "Nauru" ) ); | ||
528 | cmbCountry->insertItem( tr ( "Nepal" ) ); | ||
529 | cmbCountry->insertItem( tr ( "Netherlands" ) ); | ||
530 | cmbCountry->insertItem( tr ( "New Caledonia" ) ); | ||
531 | cmbCountry->insertItem( tr ( "New Zealand" ) ); | ||
532 | cmbCountry->insertItem( tr ( "Nicaragua" ) ); | ||
533 | cmbCountry->insertItem( tr ( "Niger" ) ); | ||
534 | cmbCountry->insertItem( tr ( "Nigeria" ) ); | ||
535 | cmbCountry->insertItem( tr ( "Niue" ) ); | ||
536 | cmbCountry->insertItem( tr ( "Norway" ) ); | ||
537 | cmbCountry->insertItem( tr ( "Oman" ) ); | ||
538 | cmbCountry->insertItem( tr ( "Pakistan" ) ); | ||
539 | cmbCountry->insertItem( tr ( "Palau" ) ); | ||
540 | cmbCountry->insertItem( tr ( "Palestinian Territory" ) ); | ||
541 | cmbCountry->insertItem( tr ( "Panama" ) ); | ||
542 | cmbCountry->insertItem( tr ( "Papua New Guinea" ) ); | ||
543 | cmbCountry->insertItem( tr ( "Paraguay" ) ); | ||
544 | cmbCountry->insertItem( tr ( "Peru" ) ); | ||
545 | cmbCountry->insertItem( tr ( "Philippines" ) ); | ||
546 | cmbCountry->insertItem( tr ( "Pitcairn" ) ); | ||
547 | cmbCountry->insertItem( tr ( "Poland" ) ); | ||
548 | cmbCountry->insertItem( tr ( "Portugal" ) ); | ||
549 | cmbCountry->insertItem( tr ( "Puerto Rico" ) ); | ||
550 | cmbCountry->insertItem( tr ( "Qatar" ) ); | ||
551 | cmbCountry->insertItem( tr ( "Reunion" ) ); | ||
552 | cmbCountry->insertItem( tr ( "Romania" ) ); | ||
553 | cmbCountry->insertItem( tr ( "Russia" ) ); | ||
554 | cmbCountry->insertItem( tr ( "Rwanda" ) ); | ||
555 | cmbCountry->insertItem( tr ( "Saint Lucia" ) ); | ||
556 | cmbCountry->insertItem( tr ( "Samoa" ) ); | ||
557 | cmbCountry->insertItem( tr ( "San Marino" ) ); | ||
558 | cmbCountry->insertItem( tr ( "Saudi Arabia" ) ); | ||
559 | cmbCountry->insertItem( tr ( "Senegal" ) ); | ||
560 | cmbCountry->insertItem( tr ( "Seychelles" ) ); | ||
561 | cmbCountry->insertItem( tr ( "Sierra Leone" ) ); | ||
562 | cmbCountry->insertItem( tr ( "Singapore" ) ); | ||
563 | cmbCountry->insertItem( tr ( "Slovakia" ) ); | ||
564 | cmbCountry->insertItem( tr ( "Slovenia" ) ); | ||
565 | cmbCountry->insertItem( tr ( "Solomon Islands" ) ); | ||
566 | cmbCountry->insertItem( tr ( "Somalia" ) ); | ||
567 | cmbCountry->insertItem( tr ( "South Africa" ) ); | ||
568 | cmbCountry->insertItem( tr ( "Spain" ) ); | ||
569 | cmbCountry->insertItem( tr ( "Sri Lanka" ) ); | ||
570 | cmbCountry->insertItem( tr ( "St. Helena" ) ); | ||
571 | cmbCountry->insertItem( tr ( "Sudan" ) ); | ||
572 | cmbCountry->insertItem( tr ( "Suriname" ) ); | ||
573 | cmbCountry->insertItem( tr ( "Swaziland" ) ); | ||
574 | cmbCountry->insertItem( tr ( "Sweden" ) ); | ||
575 | cmbCountry->insertItem( tr ( "Switzerland" ) ); | ||
576 | cmbCountry->insertItem( tr ( "Taiwan" ) ); | ||
577 | cmbCountry->insertItem( tr ( "Tajikistan" ) ); | ||
578 | cmbCountry->insertItem( tr ( "Tanzania" ) ); | ||
579 | cmbCountry->insertItem( tr ( "Thailand" ) ); | ||
580 | cmbCountry->insertItem( tr ( "Togo" ) ); | ||
581 | cmbCountry->insertItem( tr ( "Tokelau" ) ); | ||
582 | cmbCountry->insertItem( tr ( "Tonga" ) ); | ||
583 | cmbCountry->insertItem( tr ( "Tunisia" ) ); | ||
584 | cmbCountry->insertItem( tr ( "Turkey" ) ); | ||
585 | cmbCountry->insertItem( tr ( "Turkmenistan" ) ); | ||
586 | cmbCountry->insertItem( tr ( "Tuvalu" ) ); | ||
587 | cmbCountry->insertItem( tr ( "Uganda" ) ); | ||
588 | cmbCountry->insertItem( tr ( "Ukraine" ) ); | ||
589 | cmbCountry->insertItem( tr ( "Uruguay" ) ); | ||
590 | cmbCountry->insertItem( tr ( "Uzbekistan" ) ); | ||
591 | cmbCountry->insertItem( tr ( "Vanuatu" ) ); | ||
592 | cmbCountry->insertItem( tr ( "Venezuela" ) ); | ||
593 | cmbCountry->insertItem( tr ( "Viet Nam" ) ); | ||
594 | cmbCountry->insertItem( tr ( "Virgin Islands" ) ); | ||
595 | cmbCountry->insertItem( tr ( "Western Sahara" ) ); | ||
596 | cmbCountry->insertItem( tr ( "Yemen" ) ); | ||
597 | cmbCountry->insertItem( tr ( "Yugoslavia" ) ); | ||
598 | cmbCountry->insertItem( tr ( "Zambia" ) ); | ||
599 | cmbCountry->insertItem( tr ( "Zimbabwe" ) ); | ||
600 | |||
601 | cmbCountry->setMaximumWidth( 135 ); | ||
602 | |||
398 | gl->addMultiCellWidget( cmbCountry, 5, 5, 1, 2 ); | 603 | gl->addMultiCellWidget( cmbCountry, 5, 5, 1, 2 ); |
399 | 604 | ||
605 | cmbChooserField4 = new QComboBox( FALSE, container ); | ||
606 | cmbChooserField4->setMaximumWidth( 90 ); | ||
607 | gl->addWidget( cmbChooserField4, 6, 0 ); | ||
608 | txtChooserField4 = new QLineEdit( container ); | ||
609 | gl->addMultiCellWidget( txtChooserField4, 6, 6, 1, 2 ); | ||
400 | tabMain->insertTab( tabViewport, tr( "Address" ) ); | 610 | tabMain->insertTab( tabViewport, tr( "Address" ) ); |
401 | 611 | ||
402 | tabViewport = new QWidget ( tabMain ); | 612 | tabViewport = new QWidget ( tabMain ); |
@@ -411,7 +621,7 @@ void ContactEditor::init() { | |||
411 | container = new QWidget( svDetails->viewport() ); | 621 | container = new QWidget( svDetails->viewport() ); |
412 | svDetails->addChild( container ); | 622 | svDetails->addChild( container ); |
413 | 623 | ||
414 | gl = new QGridLayout( container, 1, 2, 2, 3 ); | 624 | gl = new QGridLayout( container, 1, 2, 2, 4 ); |
415 | 625 | ||
416 | QStringList::ConstIterator it = slDynamicEntries->begin(); | 626 | QStringList::ConstIterator it = slDynamicEntries->begin(); |
417 | for (i = 0; it != slDynamicEntries->end(); i++, ++it) { | 627 | for (i = 0; it != slDynamicEntries->end(); i++, ++it) { |
@@ -467,6 +677,7 @@ void ContactEditor::init() { | |||
467 | cmbChooserField1->insertStringList( *slChooserNames ); | 677 | cmbChooserField1->insertStringList( *slChooserNames ); |
468 | cmbChooserField2->insertStringList( *slChooserNames ); | 678 | cmbChooserField2->insertStringList( *slChooserNames ); |
469 | cmbChooserField3->insertStringList( *slChooserNames ); | 679 | cmbChooserField3->insertStringList( *slChooserNames ); |
680 | cmbChooserField4->insertStringList( *slChooserNames ); | ||
470 | 681 | ||
471 | cmbChooserField1->setCurrentItem( 0 ); | 682 | cmbChooserField1->setCurrentItem( 0 ); |
472 | cmbChooserField2->setCurrentItem( 1 ); | 683 | cmbChooserField2->setCurrentItem( 1 ); |
@@ -479,6 +690,7 @@ void ContactEditor::init() { | |||
479 | connect( txtChooserField1, SIGNAL(textChanged(const QString &)), this, SLOT(slotChooser1Change(const QString &)) ); | 690 | connect( txtChooserField1, SIGNAL(textChanged(const QString &)), this, SLOT(slotChooser1Change(const QString &)) ); |
480 | connect( txtChooserField2, SIGNAL(textChanged(const QString &)), this, SLOT(slotChooser2Change(const QString &)) ); | 691 | connect( txtChooserField2, SIGNAL(textChanged(const QString &)), this, SLOT(slotChooser2Change(const QString &)) ); |
481 | connect( txtChooserField3, SIGNAL(textChanged(const QString &)), this, SLOT(slotChooser3Change(const QString &)) ); | 692 | connect( txtChooserField3, SIGNAL(textChanged(const QString &)), this, SLOT(slotChooser3Change(const QString &)) ); |
693 | connect( txtChooserField4, SIGNAL(textChanged(const QString &)), this, SLOT(slotChooser4Change(const QString &)) ); | ||
482 | connect( txtAddress, SIGNAL(textChanged(const QString &)), this, SLOT(slotAddressChange(const QString &)) ); | 694 | connect( txtAddress, SIGNAL(textChanged(const QString &)), this, SLOT(slotAddressChange(const QString &)) ); |
483 | //connect( txtAddress2, SIGNAL(textChanged(const QString &)), this, SLOT(slotAddress2Change(const QString &)) ); | 695 | //connect( txtAddress2, SIGNAL(textChanged(const QString &)), this, SLOT(slotAddress2Change(const QString &)) ); |
484 | //connect( txtPOBox, SIGNAL(textChanged(const QString &)), this, SLOT(slotPOBoxChange(const QString &)) ); | 696 | //connect( txtPOBox, SIGNAL(textChanged(const QString &)), this, SLOT(slotPOBoxChange(const QString &)) ); |
@@ -490,6 +702,7 @@ void ContactEditor::init() { | |||
490 | connect( cmbChooserField1, SIGNAL(activated(int)), this, SLOT(slotCmbChooser1Change(int)) ); | 702 | connect( cmbChooserField1, SIGNAL(activated(int)), this, SLOT(slotCmbChooser1Change(int)) ); |
491 | connect( cmbChooserField2, SIGNAL(activated(int)), this, SLOT(slotCmbChooser2Change(int)) ); | 703 | connect( cmbChooserField2, SIGNAL(activated(int)), this, SLOT(slotCmbChooser2Change(int)) ); |
492 | connect( cmbChooserField3, SIGNAL(activated(int)), this, SLOT(slotCmbChooser3Change(int)) ); | 704 | connect( cmbChooserField3, SIGNAL(activated(int)), this, SLOT(slotCmbChooser3Change(int)) ); |
705 | connect( cmbChooserField4, SIGNAL(activated(int)), this, SLOT(slotCmbChooser4Change(int)) ); | ||
493 | connect( cmbAddress, SIGNAL(activated(int)), this, SLOT(slotAddressTypeChange(int)) ); | 706 | connect( cmbAddress, SIGNAL(activated(int)), this, SLOT(slotAddressTypeChange(int)) ); |
494 | new QPEDialogListener(this); | 707 | new QPEDialogListener(this); |
495 | } | 708 | } |
@@ -546,6 +759,14 @@ void ContactEditor::slotChooser3Change( const QString &textChanged ) { | |||
546 | 759 | ||
547 | } | 760 | } |
548 | 761 | ||
762 | void ContactEditor::slotChooser4Change( const QString &textChanged ) { | ||
763 | |||
764 | int index = cmbChooserField4->currentItem(); | ||
765 | |||
766 | (*slChooserValues)[index] = textChanged; | ||
767 | |||
768 | } | ||
769 | |||
549 | void ContactEditor::slotAddressChange( const QString &textChanged ) { | 770 | void ContactEditor::slotAddressChange( const QString &textChanged ) { |
550 | 771 | ||
551 | if ( cmbAddress->currentItem() == 0 ) { | 772 | if ( cmbAddress->currentItem() == 0 ) { |
@@ -628,6 +849,12 @@ void ContactEditor::slotCmbChooser3Change( int index ) { | |||
628 | 849 | ||
629 | } | 850 | } |
630 | 851 | ||
852 | void ContactEditor::slotCmbChooser4Change( int index ) { | ||
853 | |||
854 | txtChooserField4->setText( (*slChooserValues)[index] ); | ||
855 | |||
856 | } | ||
857 | |||
631 | void ContactEditor::slotAddressTypeChange( int index ) { | 858 | void ContactEditor::slotAddressTypeChange( int index ) { |
632 | 859 | ||
633 | if ( index == 0 ) { | 860 | if ( index == 0 ) { |
diff --git a/core/pim/addressbook/contacteditor.h b/core/pim/addressbook/contacteditor.h index a799672..a58a860 100644 --- a/core/pim/addressbook/contacteditor.h +++ b/core/pim/addressbook/contacteditor.h | |||
@@ -83,9 +83,11 @@ class ContactEditor : public QDialog { | |||
83 | void slotChooser1Change( const QString &textChanged ); | 83 | void slotChooser1Change( const QString &textChanged ); |
84 | void slotChooser2Change( const QString &textChanged ); | 84 | void slotChooser2Change( const QString &textChanged ); |
85 | void slotChooser3Change( const QString &textChanged ); | 85 | void slotChooser3Change( const QString &textChanged ); |
86 | void slotChooser4Change( const QString &textChanged ); | ||
86 | void slotCmbChooser1Change( int index ); | 87 | void slotCmbChooser1Change( int index ); |
87 | void slotCmbChooser2Change( int index ); | 88 | void slotCmbChooser2Change( int index ); |
88 | void slotCmbChooser3Change( int index ); | 89 | void slotCmbChooser3Change( int index ); |
90 | void slotCmbChooser4Change( int index ); | ||
89 | void slotAddressTypeChange( int index ); | 91 | void slotAddressTypeChange( int index ); |
90 | void slotAddressChange( const QString &textChanged ); | 92 | void slotAddressChange( const QString &textChanged ); |
91 | void slotAddress2Change( const QString &textChanged ); | 93 | void slotAddress2Change( const QString &textChanged ); |
@@ -134,9 +136,11 @@ class ContactEditor : public QDialog { | |||
134 | QLineEdit *txtChooserField1; | 136 | QLineEdit *txtChooserField1; |
135 | QLineEdit *txtChooserField2; | 137 | QLineEdit *txtChooserField2; |
136 | QLineEdit *txtChooserField3; | 138 | QLineEdit *txtChooserField3; |
139 | QLineEdit *txtChooserField4; | ||
137 | QComboBox *cmbChooserField1; | 140 | QComboBox *cmbChooserField1; |
138 | QComboBox *cmbChooserField2; | 141 | QComboBox *cmbChooserField2; |
139 | QComboBox *cmbChooserField3; | 142 | QComboBox *cmbChooserField3; |
143 | QComboBox *cmbChooserField4; | ||
140 | QComboBox *cmbFileAs; | 144 | QComboBox *cmbFileAs; |
141 | CategorySelect *cmbCat; | 145 | CategorySelect *cmbCat; |
142 | 146 | ||