This commit is contained in:
J-F Martel
2016-02-29 07:42:20 -05:00
parent 8f5a0f68ff
commit 2139293944
19 changed files with 658 additions and 3 deletions
+5
View File
@@ -136,6 +136,7 @@ int CVoipMsSMSClient::DownloadNewSMS()
int CVoipMsSMSClient::CheckForNewSMS()
{
// qDebug("Check new SMS");
if(mSMSMessagesList.isEmpty() == true)
{
return RET_ERROR;
@@ -310,6 +311,7 @@ unsigned int CVoipMsSMSClient::SMSReceived(QJsonArray *SMSArray)
NewMessages.append(mSMSMessagesList);
mSMSMessagesList = NewMessages;
StartSMSCheckTimer();
}
else
@@ -335,6 +337,7 @@ unsigned int CVoipMsSMSClient::SMSReceived(QJsonArray *SMSArray)
}
}
mSMSMessagesList.append(NewMessages);
StartSMSCheckTimer();
if(mFirstDownloadDone == true && NewMessages.size() > 0)
{
mProgramHandle->NewSMSMessagesArrived(NewMessages);
@@ -504,12 +507,14 @@ void CVoipMsSMSClient::StartSMSCheckTimer()
{
if(mFirstDownloadDone == true)
{
//qDebug("Timer started");
mCheckNewSMSTimer->start(VOIP_MS_SMS_CHECK_TIMEOUT);
}
}
void CVoipMsSMSClient::StopSMSCheckTimer()
{
//qDebug("Timer Stopped");
mCheckNewSMSTimer->stop();
}