48 createMenuActions(); |
47 createMenuActions(); |
49 |
48 |
50 // create actions for push buttons |
49 // create actions for push buttons |
51 createBubbleActions(); |
50 createBubbleActions(); |
52 |
51 |
53 // tester |
52 // disable toolbar effects |
54 mBubbleTester = new BubbleTester(); |
53 HbEffect::disable(toolBar()); |
55 connect(mBubbleTester,SIGNAL(dataChanged()),this,SLOT(handleTesterDataChanged())); |
|
56 mBubbleTester->connectToServer(); |
|
57 |
|
58 // create state map |
|
59 mStateMap.insert("Idle", BubbleManagerIF::None ); |
|
60 mStateMap.insert("Incoming", BubbleManagerIF::Incoming ); |
|
61 mStateMap.insert("Active", BubbleManagerIF::Active ); |
|
62 mStateMap.insert("Disconnected", BubbleManagerIF::Disconnected ); |
|
63 mStateMap.insert("Outgoing", BubbleManagerIF::Outgoing ); |
|
64 mStateMap.insert("Waiting", BubbleManagerIF::Waiting ); |
|
65 mStateMap.insert("OnHold", BubbleManagerIF::OnHold ); |
|
66 // create label map |
|
67 mLabelMap.insert("Idle", "" ); |
|
68 mLabelMap.insert("Incoming", "calling" ); |
|
69 mLabelMap.insert("Active", "" ); |
|
70 mLabelMap.insert("Disconnected", "disconnected" ); |
|
71 mLabelMap.insert("Outgoing", "Calling" ); |
|
72 mLabelMap.insert("Waiting", "waiting" ); |
|
73 mLabelMap.insert("OnHold", "on hold" ); |
|
74 } |
54 } |
75 |
55 |
76 BubbleTestView::~BubbleTestView() |
56 BubbleTestView::~BubbleTestView() |
77 { |
57 { |
78 toolBar()->clearActions(); |
58 toolBar()->clearActions(); |
79 delete mBubbleTester; |
|
80 } |
59 } |
81 |
60 |
82 void BubbleTestView::keyPressEvent(QKeyEvent *event) |
61 void BubbleTestView::keyPressEvent(QKeyEvent *event) |
83 { |
62 { |
84 switch( event->key() ) |
63 switch( event->key() ) |
336 bubbleManager().setState(mConfBubbleId,BubbleManagerIF::Active); |
315 bubbleManager().setState(mConfBubbleId,BubbleManagerIF::Active); |
337 bubbleManager().setCli(mConfBubbleId,"Conference call",Qt::ElideRight); |
316 bubbleManager().setCli(mConfBubbleId,"Conference call",Qt::ElideRight); |
338 if (mCallTimer->isChecked()) { |
317 if (mCallTimer->isChecked()) { |
339 bubbleManager().setCallTime( mConfBubbleId, "0:00" ); |
318 bubbleManager().setCallTime( mConfBubbleId, "0:00" ); |
340 } |
319 } |
341 bubbleManager().addAction(mConfBubbleId, mHold); |
320 bubbleManager().addAction(mConfBubbleId, mMute); |
342 bubbleManager().addAction(mConfBubbleId, mEndConference); |
321 bubbleManager().addAction(mConfBubbleId, mEndConference); |
343 bubbleManager().clearParticipantListActions(); |
322 bubbleManager().clearParticipantListActions(); |
344 bubbleManager().addParticipantListAction(mPrivate); |
323 bubbleManager().addParticipantListAction(mPrivate); |
345 bubbleManager().addParticipantListAction(mDrop); |
324 bubbleManager().addParticipantListAction(mDrop); |
346 bubbleManager().setState(heldCallId,BubbleManagerIF::Active); |
325 bubbleManager().setState(heldCallId,BubbleManagerIF::Active); |
498 bubbleManager().setSecondaryCli(bubble, "+35840987654321"); |
475 bubbleManager().setSecondaryCli(bubble, "+35840987654321"); |
499 } else { |
476 } else { |
500 bubbleManager().setCli(bubble, "John Doe", Qt::ElideRight); |
477 bubbleManager().setCli(bubble, "John Doe", Qt::ElideRight); |
501 bubbleManager().setSecondaryCli(bubble, "+35840987654321"); |
478 bubbleManager().setSecondaryCli(bubble, "+35840987654321"); |
502 } |
479 } |
503 mPhoneNumber.clear(); |
|
504 } else { |
480 } else { |
505 if (callCount()==2) { |
481 if (callCount()==2) { |
506 mPhoneNumber.append("+35850232323232"); |
482 bubbleManager().setCli(bubble, "+35850232323232", Qt::ElideRight); |
507 } else { |
483 } else { |
508 mPhoneNumber.append("+35840987654321"); |
484 bubbleManager().setCli(bubble, "+35840987654321", Qt::ElideRight); |
509 } |
485 } |
510 bubbleManager().setCli(bubble, mPhoneNumber, Qt::ElideRight); |
486 |
511 } |
487 } |
512 setCallObject(bubble, ":resources/contactpic3.png"); |
488 setCallObject(bubble, ":resources/contactpic3.png"); |
513 bubbleManager().setNumberType(bubble, BubbleManager::Mobile); |
489 bubbleManager().setNumberType(bubble, BubbleManager::Mobile); |
514 bubbleManager().setCallFlag(bubble, BubbleManager::Diverted, mCallDivert->isChecked()); |
490 bubbleManager().setCallFlag(bubble, BubbleManager::Diverted, mCallDivert->isChecked()); |
515 bubbleManager().setCallFlag(bubble, BubbleManager::NoCiphering, mCipheringOff->isChecked()); |
491 bubbleManager().setCallFlag(bubble, BubbleManager::NoCiphering, mCipheringOff->isChecked()); |
526 bubbleManager().setLabel( bubble, "Attempting", Qt::ElideRight ); |
502 bubbleManager().setLabel( bubble, "Attempting", Qt::ElideRight ); |
527 } else { |
503 } else { |
528 if ( mContactName->isChecked() ) { |
504 if ( mContactName->isChecked() ) { |
529 bubbleManager().setCli( bubble, "Bart Simpson", Qt::ElideRight ); |
505 bubbleManager().setCli( bubble, "Bart Simpson", Qt::ElideRight ); |
530 bubbleManager().setSecondaryCli( bubble, "+35890987654321" ); |
506 bubbleManager().setSecondaryCli( bubble, "+35890987654321" ); |
531 mPhoneNumber.clear(); |
|
532 } else { |
507 } else { |
533 mPhoneNumber.append("+35890987654321"); |
508 bubbleManager().setCli( bubble, "+35890987654321", Qt::ElideRight ); |
534 bubbleManager().setCli( bubble, mPhoneNumber, Qt::ElideRight ); |
|
535 } |
509 } |
536 setCallObject(bubble, ":resources/contactpic2.jpg"); |
510 setCallObject(bubble, ":resources/contactpic2.jpg"); |
537 bubbleManager().setLabel( bubble, "Calling", Qt::ElideRight ); |
511 bubbleManager().setLabel( bubble, "Calling", Qt::ElideRight ); |
538 } |
512 } |
539 break; |
513 break; |
540 } |
514 } |
541 |
515 |
542 case BubbleManager::Alerting: |
516 case BubbleManager::Alerting: |
543 { |
517 { |
544 if ( mPhoneNumber.length() ) { |
|
545 QString cli("Call %1"); |
|
546 QString index; |
|
547 index.setNum(bubble+1); |
|
548 cli = cli.arg(index); |
|
549 bubbleManager().setCli( bubble, cli, Qt::ElideRight ); |
|
550 bubbleManager().setSecondaryCli( bubble, mPhoneNumber ); |
|
551 mPhoneNumber.clear(); |
|
552 } |
|
553 |
|
554 if ( mEmergencyCall->isChecked() ) { |
518 if ( mEmergencyCall->isChecked() ) { |
555 bubbleManager().setCli( bubble, "Emergency call", Qt::ElideRight ); |
519 bubbleManager().setCli( bubble, "Emergency call", Qt::ElideRight ); |
556 } |
520 } |
557 break; |
521 break; |
558 } |
522 } |
559 |
523 |
560 case BubbleManager::Active: |
524 case BubbleManager::Active: |
561 { |
525 { |
562 if ( mPhoneNumber.length() && bubble!=mConfBubbleId ) { |
|
563 QString cli("Call %1"); |
|
564 QString index; |
|
565 index.setNum(bubble+1); |
|
566 cli = cli.arg(index); |
|
567 bubbleManager().setCli( bubble, cli, Qt::ElideRight ); |
|
568 bubbleManager().setSecondaryCli( bubble, mPhoneNumber ); |
|
569 mPhoneNumber.clear(); |
|
570 } |
|
571 |
|
572 if ( mCallTimer->isChecked() ) { |
526 if ( mCallTimer->isChecked() ) { |
573 bubbleManager().setCallTime( bubble, "0:00" ); |
527 bubbleManager().setCallTime( bubble, "0:00" ); |
574 } |
528 } |
575 break; |
529 break; |
576 } |
530 } |
646 break; |
581 break; |
647 } |
582 } |
648 case BubbleManager::Outgoing: |
583 case BubbleManager::Outgoing: |
649 case BubbleManager::Alerting: // flow through |
584 case BubbleManager::Alerting: // flow through |
650 { |
585 { |
|
586 bubbleManager().addAction( bubble, mMute ); |
651 bubbleManager().addAction( bubble, mEndCall ); |
587 bubbleManager().addAction( bubble, mEndCall ); |
652 break; |
588 break; |
653 } |
589 } |
654 case BubbleManager::OnHold: |
590 case BubbleManager::OnHold: |
655 { |
591 { |
656 bubbleManager().addAction( bubble, mUnhold ); |
592 if (mMuted) { |
|
593 bubbleManager().addAction( bubble, mUnmute ); |
|
594 } else { |
|
595 bubbleManager().addAction( bubble, mMute ); |
|
596 } |
657 bubbleManager().addAction( bubble, mEndCall ); |
597 bubbleManager().addAction( bubble, mEndCall ); |
658 } |
598 } |
659 break; |
599 break; |
660 default: // Active call |
600 default: // Active call |
661 { |
601 { |
662 HbAction* action; |
602 if (mMuted) { |
663 |
603 bubbleManager().addAction( bubble, mUnmute ); |
664 if (!mEmergencyCall->isChecked()) { |
604 } else { |
665 int i; |
605 bubbleManager().addAction( bubble, mMute ); |
666 if ( (mCalls.count()>1 && !callIndexByState(BubbleManagerIF::Waiting,i)) |
606 } |
667 || (mCalls.count()> 1 && mProvideJoin) ) { |
|
668 action = mJoin; |
|
669 } else { |
|
670 action = mHold; |
|
671 } |
|
672 |
|
673 bubbleManager().addAction( bubble, action ); |
|
674 } |
|
675 |
|
676 bubbleManager().addAction( bubble, mEndCall ); |
607 bubbleManager().addAction( bubble, mEndCall ); |
677 break; |
608 break; |
678 } |
609 } |
679 } |
610 } |
680 } |
611 } |
795 bubbleManager().removeConference(); |
736 bubbleManager().removeConference(); |
796 callIndexByBubbleId(mConfBubbleId,i); |
737 callIndexByBubbleId(mConfBubbleId,i); |
797 mCalls.removeAt(i); |
738 mCalls.removeAt(i); |
798 mConfBubbleId = -1; |
739 mConfBubbleId = -1; |
799 callIndexByBubbleId(selection,i); |
740 callIndexByBubbleId(selection,i); |
800 int held = (i==0) ? 1 : 0; |
741 int held = (i==0) ? 1 : 0; // ?? |
801 setBubbleActions(selection,BubbleManagerIF::Active); |
742 setBubbleActions(selection,BubbleManagerIF::Active); |
802 setBubbleData(selection,BubbleManagerIF::Active); |
743 setBubbleData(selection,BubbleManagerIF::Active); |
803 setBubbleActions(held,BubbleManagerIF::OnHold); |
744 setBubbleActions(held,BubbleManagerIF::OnHold); |
804 setBubbleData(held,BubbleManagerIF::OnHold); |
745 setBubbleData(held,BubbleManagerIF::OnHold); |
805 mCalls[0].isInConf = false; |
746 mCalls[i].isInConf = false; |
806 mCalls[1].isInConf = false; |
747 mCalls[i].callState = BubbleManagerIF::Active; |
|
748 int callId; |
|
749 callIndexByBubbleId(held, callId); |
|
750 mCalls[callId].callState = BubbleManagerIF::OnHold; |
|
751 mCalls[callId].isInConf = false; |
807 setExpandActions(); |
752 setExpandActions(); |
808 } |
753 } |
809 bubbleManager().endChanges(); |
754 bubbleManager().endChanges(); |
810 } |
755 } |
811 |
756 |
868 mUnmute = new HbAction(HbIcon("qtg_mono_mic_unmute"), "", this); |
813 mUnmute = new HbAction(HbIcon("qtg_mono_mic_unmute"), "", this); |
869 connect( mUnmute, SIGNAL(triggered()), this, SLOT(setMuted()), Qt::QueuedConnection ); |
814 connect( mUnmute, SIGNAL(triggered()), this, SLOT(setMuted()), Qt::QueuedConnection ); |
870 |
815 |
871 // not connected to anywhere |
816 // not connected to anywhere |
872 mActivateLoudspeaker = new HbAction(HbIcon("qtg_mono_speaker"), "", this); |
817 mActivateLoudspeaker = new HbAction(HbIcon("qtg_mono_speaker"), "", this); |
|
818 connect( mActivateLoudspeaker, SIGNAL(triggered()), this, SLOT(createIncomingCall()), Qt::QueuedConnection ); |
873 mActivateHandset = new HbAction(HbIcon("qtg_mono_mobile"), "", this); |
819 mActivateHandset = new HbAction(HbIcon("qtg_mono_mobile"), "", this); |
874 mSendMessage = new HbAction(HbIcon("qtg_mono_send"), "", this); |
820 mSendMessage = new HbAction(HbIcon("qtg_mono_send"), "", this); |
875 mSilence = new HbAction(HbIcon("qtg_mono_speaker_off"), "", this); |
821 mSilence = new HbAction(HbIcon("qtg_mono_speaker_off"), "", this); |
876 mOpenDialer = new HbAction(HbIcon("qtg_mono_dialer"), "", this); |
822 mOpenDialer = new HbAction(HbIcon("qtg_mono_dialer"), "", this); |
877 mOpenContacts = new HbAction(HbIcon("qtg_mono_contacts"), "", this); |
823 mOpenContacts = new HbAction(HbIcon("qtg_mono_contacts"), "", this); |
917 if ( state == BubbleManagerIF::Incoming || |
863 if ( state == BubbleManagerIF::Incoming || |
918 state == BubbleManagerIF::Waiting ) { |
864 state == BubbleManagerIF::Waiting ) { |
919 toolBar()->addAction(mSendMessage); |
865 toolBar()->addAction(mSendMessage); |
920 toolBar()->addAction(mSilence); |
866 toolBar()->addAction(mSilence); |
921 } else { |
867 } else { |
|
868 toolBar()->addAction(mActivateLoudspeaker); |
|
869 |
|
870 if (callCount()==1) { |
|
871 toolBar()->addAction(mHold); |
|
872 } else { |
|
873 toolBar()->addAction(mSwap); |
|
874 } |
|
875 |
|
876 if (callCount()==1) { |
|
877 toolBar()->addAction(mOpenContacts); |
|
878 } else { |
|
879 toolBar()->addAction(mJoin); |
|
880 } |
|
881 |
922 toolBar()->addAction(mOpenDialer); |
882 toolBar()->addAction(mOpenDialer); |
923 if (!mMuted) { |
|
924 toolBar()->addAction(mMute); |
|
925 } else if (mMuted) { |
|
926 toolBar()->addAction(mUnmute); |
|
927 } |
|
928 toolBar()->addAction(mActivateLoudspeaker); |
|
929 toolBar()->addAction(mOpenContacts); |
|
930 } |
883 } |
931 } |
884 } |
932 |
885 |
933 void BubbleTestView::createBubbleActions() |
886 void BubbleTestView::createBubbleActions() |
934 { |
887 { |
935 mAnswer = new HbAction( HbIcon("qtg_mono_call"),"Answer", this); |
888 mAnswer = new HbAction( HbIcon("qtg_mono_call"),QString(), this); |
936 mAnswer->setSoftKeyRole(QAction::PositiveSoftKey); |
889 mAnswer->setSoftKeyRole(QAction::PositiveSoftKey); |
937 connect( mAnswer, SIGNAL( triggered() ), this, SLOT( answerCall() ) ); |
890 connect( mAnswer, SIGNAL( triggered() ), this, SLOT( answerCall() ) ); |
938 |
891 |
939 mReject= new HbAction( HbIcon("qtg_mono_reject_call"),"Reject", this); |
892 mReject= new HbAction( HbIcon("qtg_mono_reject_call"),QString(), this); |
940 mReject->setSoftKeyRole(QAction::NegativeSoftKey); |
893 mReject->setSoftKeyRole(QAction::NegativeSoftKey); |
941 connect( mReject, SIGNAL( triggered() ), this, SLOT( rejectCall() ) ); |
894 connect( mReject, SIGNAL( triggered() ), this, SLOT( rejectCall() ) ); |
942 |
895 |
943 mHold = new HbAction( HbIcon("qtg_mono_hold_call"),"Hold", this); |
896 mHold = new HbAction( HbIcon("qtg_mono_hold_call"),QString(), this); |
944 connect( mHold, SIGNAL( triggered() ), this, SLOT( toggleHold() ) ); |
897 connect( mHold, SIGNAL( triggered() ), this, SLOT( toggleHold() ) ); |
945 |
898 |
946 mUnhold = new HbAction( HbIcon("qtg_mono_call"),"Activate", this); |
899 mUnhold = new HbAction( HbIcon("qtg_mono_call"),QString(), this); |
947 connect( mUnhold, SIGNAL( triggered() ), this, SLOT( toggleHold() ) ); |
900 connect( mUnhold, SIGNAL( triggered() ), this, SLOT( toggleHold() ) ); |
948 |
901 |
949 mSwap = new HbAction( HbIcon("qtg_mono_hold_call"),"Swap", this); |
902 mSwap = new HbAction( HbIcon("qtg_mono_hold_call"),QString(), this); |
950 connect( mSwap, SIGNAL( triggered() ), this, SLOT( toggleHold() ) ); |
903 connect( mSwap, SIGNAL( triggered() ), this, SLOT( toggleHold() ) ); |
951 |
904 |
952 mEndCall = new HbAction(HbIcon("qtg_mono_end_call"),"End call", this); |
905 mEndCall = new HbAction(HbIcon("qtg_mono_end_call"),QString(), this); |
953 mEndCall->setSoftKeyRole(QAction::NegativeSoftKey); |
906 mEndCall->setSoftKeyRole(QAction::NegativeSoftKey); |
954 connect( mEndCall, SIGNAL( triggered() ), this, SLOT( endCall() ) ); |
907 connect( mEndCall, SIGNAL( triggered() ), this, SLOT( endCall() ) ); |
955 |
908 |
956 mEndConference = new HbAction(HbIcon("qtg_mono_end_all_call"),"End conference", this); |
909 mEndConference = new HbAction(HbIcon("qtg_mono_end_call"),QString(), this); |
957 mEndConference->setSoftKeyRole(QAction::NegativeSoftKey); |
910 mEndConference->setSoftKeyRole(QAction::NegativeSoftKey); |
958 connect( mEndConference, SIGNAL( triggered() ), this, SLOT( endConferenceCall() ) ); |
911 connect( mEndConference, SIGNAL( triggered() ), this, SLOT( endConferenceCall() ) ); |
959 |
912 |
960 mJoin = new HbAction(HbIcon("qtg_mono_join_call"),"Join", this); |
913 mJoin = new HbAction(HbIcon("qtg_mono_join_call"),QString(), this); |
961 connect( mJoin, SIGNAL( triggered() ), this, SLOT(joinToConference()) ); |
914 connect( mJoin, SIGNAL( triggered() ), this, SLOT(joinToConference()) ); |
962 |
915 |
963 mPrivate = new HbAction(HbIcon("qtg_mono_private_call"),"Private", this); |
916 mPrivate = new HbAction(HbIcon("qtg_mono_private_call"),QString(), this); |
964 connect( mPrivate, SIGNAL( triggered() ), this, SLOT(handlePrivate()) ); |
917 connect( mPrivate, SIGNAL( triggered() ), this, SLOT(handlePrivate()) ); |
965 |
918 |
966 mDrop = new HbAction(HbIcon("qtg_mono_drop_call"),"Drop", this); |
919 mDrop = new HbAction(HbIcon("qtg_mono_drop_call"),QString(), this); |
967 connect( mDrop, SIGNAL( triggered() ), this, SLOT(handleDrop()) ); |
920 connect( mDrop, SIGNAL( triggered() ), this, SLOT(handleDrop()) ); |
968 |
921 |
969 mReplace = new HbAction(HbIcon("qtg_mono_replace_call"),"Replace", this); |
922 mReplace = new HbAction(HbIcon("qtg_mono_replace_call"),QString(), this); |
970 connect( mReplace, SIGNAL( triggered() ), this, SLOT(replaceActiveCall()) ); |
923 connect( mReplace, SIGNAL( triggered() ), this, SLOT(replaceActiveCall()) ); |
971 |
924 |
972 mUpdateUiControls = new HbAction(QString(), this); |
925 mUpdateUiControls = new HbAction(QString(), this); |
973 connect( mUpdateUiControls, SIGNAL(triggered()), this, SLOT(updateUiControls()) ); |
926 connect( mUpdateUiControls, SIGNAL(triggered()), this, SLOT(updateUiControls()) ); |
974 } |
927 } |
1045 { |
998 { |
1046 int i; |
999 int i; |
1047 callIndexByBubbleId(mConfBubbleId, i); |
1000 callIndexByBubbleId(mConfBubbleId, i); |
1048 BubbleManagerIF::PhoneCallState confState = |
1001 BubbleManagerIF::PhoneCallState confState = |
1049 (BubbleManagerIF::PhoneCallState)mCalls[i].callState; |
1002 (BubbleManagerIF::PhoneCallState)mCalls[i].callState; |
1050 qDebug() << "toggleConferenceHoldDelayed state:" << confState; |
1003 // qDebug() << "toggleConferenceHoldDelayed state:" << confState; |
1051 |
1004 |
1052 QListIterator<TestCall> calls(mCalls); |
1005 QListIterator<TestCall> calls(mCalls); |
1053 int j=0; |
1006 int j=0; |
1054 while(calls.hasNext()) { |
1007 while(calls.hasNext()) { |
1055 TestCall call = calls.next(); |
1008 TestCall call = calls.next(); |
1056 qDebug() << "toggleConferenceHoldDelayed callState:" << call.callState; |
1009 // qDebug() << "toggleConferenceHoldDelayed callState:" << call.callState; |
1057 if (call.isInConf && call.callState!=confState) { |
1010 if (call.isInConf && call.callState!=confState) { |
1058 bubbleManager().startChanges(); |
1011 bubbleManager().startChanges(); |
1059 setBubbleData(call.bubbleId, confState); |
1012 setBubbleData(call.bubbleId, confState); |
1060 setBubbleActions(call.bubbleId, confState); |
1013 setBubbleActions(call.bubbleId, confState); |
1061 mCalls[j].callState=confState; |
1014 mCalls[j].callState=confState; |
1066 } |
1019 } |
1067 j++; |
1020 j++; |
1068 } |
1021 } |
1069 } |
1022 } |
1070 |
1023 |
1071 void BubbleTestView::connectToTester() |
|
1072 { |
|
1073 mBubbleTester->connectToServer(); |
|
1074 } |
|
1075 |
|
1076 void BubbleTestView::handleTesterDataChanged() |
|
1077 { |
|
1078 bubbleManager().startChanges(); |
|
1079 |
|
1080 QString mute = mBubbleTester->dataField("mute"); |
|
1081 bubbleManager().setPhoneMuted( mute == "On" ); |
|
1082 |
|
1083 QList<QString> testBubbles = mBubbleTester->bubbles(); |
|
1084 |
|
1085 foreach (QString bubbleId, testBubbles) { |
|
1086 QString state = mBubbleTester->dataField(bubbleId,"state"); |
|
1087 |
|
1088 // create or remove bubble |
|
1089 if ( mTestBubbleIds.contains(bubbleId) && state=="Idle" ) { |
|
1090 bubbleManager().removeCallHeader(mTestBubbleIds.value(bubbleId)); |
|
1091 mTestBubbleIds.remove(bubbleId); |
|
1092 } else if (!mTestBubbleIds.contains(bubbleId) && state!="Idle" ) { |
|
1093 int id = bubbleManager().createCallHeader(); |
|
1094 mTestBubbleIds.insert(bubbleId,id); |
|
1095 } |
|
1096 |
|
1097 // set data |
|
1098 if (mTestBubbleIds.contains(bubbleId)) { |
|
1099 int id = mTestBubbleIds.value(bubbleId); |
|
1100 |
|
1101 QString name = mBubbleTester->dataField(bubbleId,"name"); |
|
1102 QString number = mBubbleTester->dataField(bubbleId,"number"); |
|
1103 QString divert = mBubbleTester->dataField(bubbleId,"divert"); |
|
1104 |
|
1105 bubbleManager().setState(id, mStateMap.value(state)); |
|
1106 bubbleManager().setCli(id, name, Qt::ElideRight); |
|
1107 bubbleManager().setSecondaryCli(id, number ); |
|
1108 bubbleManager().setLabel(id, mLabelMap.value(state), Qt::ElideRight); |
|
1109 |
|
1110 bubbleManager().setCallFlag(id, BubbleManager::Diverted, (divert == "On") ); |
|
1111 |
|
1112 setCallObject(id,":resources/contactpic.jpg"); |
|
1113 |
|
1114 setBubbleActions(id, mStateMap.value(state) ); |
|
1115 } |
|
1116 } |
|
1117 |
|
1118 bubbleManager().endChanges(); |
|
1119 } |
|