本文整理汇总了C++中Contact::getVoxOxPhone方法的典型用法代码示例。如果您正苦于以下问题:C++ Contact::getVoxOxPhone方法的具体用法?C++ Contact::getVoxOxPhone怎么用?C++ Contact::getVoxOxPhone使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Contact
的用法示例。
在下文中一共展示了Contact::getVoxOxPhone方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: callContact
void CUserProfile::callContact( const std::string& contactId )
{
Contact* contact = getCContactList().getContactById( contactId );
if ( contact )
{
//VOXOX - CJC - 2009.06.23 Fix bug not calling voxox contact
if ( contact->getPreferredIMContact()->isIMAccountVoxOx() )
{
//VOXOX - JRT - 2009.09.24 - TODO: Reversed logic? This prevents block of code prevents retrieval of SIP number for this contact.
// Most of this logic already exists in makeContactCallThreadSafe(), which is called by makeContactCall()
if ( contact->getVoxOxPhone().empty() )
{
makeContactCall( contactId );
}
else
{
makeCall( contact->getPreferredNumber()); //VOXOX - CJC - 2009.06.11
}
}
else if(contact->getQtIMProtocol() == QtEnumIMProtocol::IMProtocolSkype){
makeContactCall(contactId);
}
else
{
if ( contact->getTelephones().hasValid() )
{
makeCall( contact->getPreferredNumber()); //VOXOX - CJC - 2009.06.11
}
}
}
}
示例2: makeContactCallThreadSafe
void CUserProfile::makeContactCallThreadSafe(std::string contactId) {
Contact * contact = _cContactList.getContact(contactId);
if (contact)
{
//VOXOXCHANGE CJC CALL VOXOX NUMBERS
if(contact->getIsIMAccountVoxox())
{
//We don't get the number if we already have it//TODO CHANGE THIS IF NUMBERS ARE CHANGED FREQUENTLY
if(!contact->getVoxOxPhone().empty())
{
EnumMakeCallError::MakeCallError error = _userProfile.makeCall(*contact);
if (error != EnumMakeCallError::NoError)
{
makeCallErrorEvent(*this, error, contact->getVoxOxPhone());//VOXOX CHANGE by Rolando - 2009.05.29 - added parameter phonenumber to check what call failed
}
}
else
{
if(_userProfile.getWsContactNumber())
{
WsContactNumber & wsContactNumber = *_userProfile.getWsContactNumber();
wsContactNumber.setContactId(contact->getKey());
wsContactNumber.contactNumberEvent += boost::bind(&CUserProfile::contactNumberEventHandler, this, _1, _2, _3);
wsContactNumber.execute();
}
}
}else if(contact->getQtIMProtocol() == QtEnumIMProtocol::IMProtocolSkype){
_userProfile.makeCall(*contact);
}
else
{
EnumMakeCallError::MakeCallError error = _userProfile.makeCall(*contact);
if (error != EnumMakeCallError::NoError)
{
makeCallErrorEvent(*this, error, contactId);//VOXOX CHANGE by Rolando - 2009.05.29 - added parameter contactId to check what call failed
}
}
}
else
{
makeCallErrorEvent(*this, EnumMakeCallError::ContactNotFound, contactId);//VOXOX CHANGE by Rolando - 2009.05.29 - added parameter contactId to check what call failed
}
}