Commit 609c2292 authored by Ming Rui Zhang's avatar Ming Rui Zhang

DTMF: add the A,B,C,D dtmf signals on to keyReleaseEvent

Change-Id: I9d73c85c73ce509f838f0645fdaaa7713c918f5d
parent 37091c8d
......@@ -482,9 +482,14 @@ VideoView::keyReleaseEvent(QKeyEvent* event)
LRCInstance::getCurrentCallModel()->playDTMF(convInfo.callId, "#");
} else if (keyPressed_ == static_cast<int>(Qt::Key_Asterisk)) {
LRCInstance::getCurrentCallModel()->playDTMF(convInfo.callId, "*");
} else if (keyPressed_ >= 65 && keyPressed_ <= 68) {
//enum Qt::Key_A = 65, QT::Key_D = 68
// string::string(size_type count, charT ch)
LRCInstance::getCurrentCallModel()->playDTMF(convInfo.callId, std::string(1, char(keyPressed_)));
} else if (keyPressed_ >= 48 && keyPressed_ <= 57) {
//enum Qt::Key_0 = 48, QT::Key_9 = 57
LRCInstance::getCurrentCallModel()->playDTMF(convInfo.callId, std::to_string(keyPressed_ - 48));
}
keyPressed_ = -1;
QWidget::keyReleaseEvent(event);
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment