summaryrefslogtreecommitdiff
authoreilers <eilers>2003-05-09 13:41:06 (UTC)
committer eilers <eilers>2003-05-09 13:41:06 (UTC)
commitddadf9f70cbcd7c6b8addcc8c1f6ede0283f765d (patch) (unidiff)
tree3471c2ecec1ec034fb2855da230f05fef5e7b3b1
parent98196030da571da62ecb2fdd67e77a1e941d175a (diff)
downloadopie-ddadf9f70cbcd7c6b8addcc8c1f6ede0283f765d.zip
opie-ddadf9f70cbcd7c6b8addcc8c1f6ede0283f765d.tar.gz
opie-ddadf9f70cbcd7c6b8addcc8c1f6ede0283f765d.tar.bz2
No it jumps into the front if show(int) is used.. Thanks tille !
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--core/pim/addressbook/addressbook.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/core/pim/addressbook/addressbook.cpp b/core/pim/addressbook/addressbook.cpp
index 975911e..25c6f3a 100644
--- a/core/pim/addressbook/addressbook.cpp
+++ b/core/pim/addressbook/addressbook.cpp
@@ -677,64 +677,65 @@ void AddressbookWindow::appMessage(const QCString &msg, const QByteArray &data)
677 677
678 m_abView -> addEntry( cnt ); 678 m_abView -> addEntry( cnt );
679 679
680 // :SXm_abView()->init( cnt ); 680 // :SXm_abView()->init( cnt );
681 editEntry( EditEntry ); 681 editEntry( EditEntry );
682 } else if ( msg == "beamBusinessCard()" ) { 682 } else if ( msg == "beamBusinessCard()" ) {
683 QString beamFilename = addressbookPersonalVCardName(); 683 QString beamFilename = addressbookPersonalVCardName();
684 if ( !QFile::exists( beamFilename ) ) 684 if ( !QFile::exists( beamFilename ) )
685 return; // can't beam a non-existent file 685 return; // can't beam a non-existent file
686 686
687 Ir *ir = new Ir( this ); 687 Ir *ir = new Ir( this );
688 connect( ir, SIGNAL( done( Ir * ) ), this, SLOT( beamDone( Ir * ) ) ); 688 connect( ir, SIGNAL( done( Ir * ) ), this, SLOT( beamDone( Ir * ) ) );
689 QString description = "mycard.vcf"; 689 QString description = "mycard.vcf";
690 ir->send( beamFilename, description, "text/x-vCard" ); 690 ir->send( beamFilename, description, "text/x-vCard" );
691 } else if ( msg == "show(int)" ) { 691 } else if ( msg == "show(int)" ) {
692 QDataStream stream(data,IO_ReadOnly); 692 QDataStream stream(data,IO_ReadOnly);
693 int uid; 693 int uid;
694 stream >> uid; 694 stream >> uid;
695 695
696 qWarning( "Showing uid: %d" , uid ); 696 qWarning( "Showing uid: %d" , uid );
697 697
698 // Deactivate Personal View.. 698 // Deactivate Personal View..
699 if ( actionPersonal->isOn() ){ 699 if ( actionPersonal->isOn() ){
700 actionPersonal->setOn( false ); 700 actionPersonal->setOn( false );
701 slotPersonalView(); 701 slotPersonalView();
702 } 702 }
703 703
704 // Reset category and show as card.. 704 // Reset category and show as card..
705 m_abView -> setShowByCategory( QString::null ); 705 m_abView -> setShowByCategory( QString::null );
706 m_abView -> setCurrentUid( uid ); 706 m_abView -> setCurrentUid( uid );
707 slotViewSwitched ( AbView::CardView ); 707 slotViewSwitched ( AbView::CardView );
708 708
709 showMaximized();
709 qApp->exec(); 710 qApp->exec();
710 711
711 } else if ( msg == "edit(int)" ) { 712 } else if ( msg == "edit(int)" ) {
712 QDataStream stream(data,IO_ReadOnly); 713 QDataStream stream(data,IO_ReadOnly);
713 int uid; 714 int uid;
714 stream >> uid; 715 stream >> uid;
715 716
716 // Deactivate Personal View.. 717 // Deactivate Personal View..
717 if ( actionPersonal->isOn() ){ 718 if ( actionPersonal->isOn() ){
718 actionPersonal->setOn( false ); 719 actionPersonal->setOn( false );
719 slotPersonalView(); 720 slotPersonalView();
720 } 721 }
721 722
722 // Reset category and edit.. 723 // Reset category and edit..
723 m_abView -> setShowByCategory( QString::null ); 724 m_abView -> setShowByCategory( QString::null );
724 m_abView -> setCurrentUid( uid ); 725 m_abView -> setCurrentUid( uid );
725 slotViewEdit(); 726 slotViewEdit();
726 } 727 }
727 728
728} 729}
729 730
730void AddressbookWindow::editEntry( EntryMode entryMode ) 731void AddressbookWindow::editEntry( EntryMode entryMode )
731{ 732{
732 OContact entry; 733 OContact entry;
733 if ( !abEditor ) { 734 if ( !abEditor ) {
734 abEditor = new ContactEditor( entry, this, "editor" ); 735 abEditor = new ContactEditor( entry, this, "editor" );
735 } 736 }
736 if ( entryMode == EditEntry ) 737 if ( entryMode == EditEntry )
737 abEditor->setEntry( m_abView -> currentEntry() ); 738 abEditor->setEntry( m_abView -> currentEntry() );
738 else if ( entryMode == NewEntry ) 739 else if ( entryMode == NewEntry )
739 abEditor->setEntry( entry ); 740 abEditor->setEntry( entry );
740 // other things may change the caption. 741 // other things may change the caption.