summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLubos Dolezel <lubos@dolezel.info>2015-06-05 15:18:11 +0200
committerLubos Dolezel <lubos@dolezel.info>2015-06-05 15:18:11 +0200
commit83682370bdf2e50fd83bc005b1505213a9612ab4 (patch)
treecca0ac05322db2af6993036fa083e31ad00caf28
parentb62f8a7e002fc48ae7a397d9d2b718367eb84834 (diff)
downloadtwinkle-83682370bdf2e50fd83bc005b1505213a9612ab4.tar
twinkle-83682370bdf2e50fd83bc005b1505213a9612ab4.tar.gz
twinkle-83682370bdf2e50fd83bc005b1505213a9612ab4.tar.lz
twinkle-83682370bdf2e50fd83bc005b1505213a9612ab4.tar.xz
twinkle-83682370bdf2e50fd83bc005b1505213a9612ab4.zip
Visual DTMF feedback, clipboard support (fixes #4 and #5)
-rw-r--r--CMakeLists.txt2
-rw-r--r--src/gui/dtmfform.cpp218
-rw-r--r--src/gui/dtmfform.h9
-rw-r--r--src/gui/dtmfform.ui1457
4 files changed, 938 insertions, 748 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 769c440..8df0546 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -4,7 +4,7 @@ cmake_minimum_required(VERSION 2.6.0 FATAL_ERROR)
set(PRODUCT_VERSION "1.9.0")
set(PRODUCT_DATE "June 1, 2015")
-set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11")
+set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11 -ggdb -O0")
OPTION(WITH_ZRTP "Enable ZRTP encrypted calls" OFF)
OPTION(WITH_SPEEX "Enable the Speex codec" OFF)
diff --git a/src/gui/dtmfform.cpp b/src/gui/dtmfform.cpp
index bd61830..d5d02d9 100644
--- a/src/gui/dtmfform.cpp
+++ b/src/gui/dtmfform.cpp
@@ -1,4 +1,6 @@
#include "dtmfform.h"
+#include <QClipboard>
+#include <QTimer>
/*
* Constructs a DtmfForm which is a child of 'parent', with the
@@ -11,6 +13,12 @@ DtmfForm::DtmfForm(QWidget* parent)
: QDialog(parent)
{
setupUi(this);
+
+ // Speed 40/40 (i.e. one tone every 80ms)
+ m_insertTimer.setInterval(80);
+ m_insertTimer.setSingleShot(false);
+
+ connect(&m_insertTimer, SIGNAL(timeout()), this, SLOT(insertNextKey()));
}
/*
@@ -105,71 +113,149 @@ void DtmfForm::dtmfD()
void DtmfForm::keyPressEvent(QKeyEvent *e)
{
// DTMF keys
- switch (e->key()) {
- case Qt::Key_1:
- dtmf1();
- break;
- case Qt::Key_2:
- case Qt::Key_A:
- case Qt::Key_B:
- case Qt::Key_C:
- dtmf2();
- break;
- case Qt::Key_3:
- case Qt::Key_D:
- case Qt::Key_E:
- case Qt::Key_F:
- dtmf3();
- break;
- case Qt::Key_4:
- case Qt::Key_G:
- case Qt::Key_H:
- case Qt::Key_I:
- dtmf4();
- break;
- case Qt::Key_5:
- case Qt::Key_J:
- case Qt::Key_K:
- case Qt::Key_L:
- dtmf5();
- break;
- case Qt::Key_6:
- case Qt::Key_M:
- case Qt::Key_N:
- case Qt::Key_O:
- dtmf6();
- break;
- case Qt::Key_7:
- case Qt::Key_P:
- case Qt::Key_Q:
- case Qt::Key_R:
- case Qt::Key_S:
- dtmf7();
- break;
- case Qt::Key_8:
- case Qt::Key_T:
- case Qt::Key_U:
- case Qt::Key_V:
- dtmf8();
- break;
- case Qt::Key_9:
- case Qt::Key_W:
- case Qt::Key_X:
- case Qt::Key_Y:
- case Qt::Key_Z:
- dtmf9();
- break;
- case Qt::Key_0:
- case Qt::Key_Space:
- dtmf0();
- break;
- case Qt::Key_Asterisk:
- dtmfStar();
- break;
- case Qt::Key_NumberSign:
- dtmfPound();
- break;
- default:
- e->ignore();
+ if ((e->modifiers() & (Qt::ControlModifier | Qt::AltModifier | Qt::MetaModifier))
+ == Qt::NoModifier)
+ {
+ switch (e->key()) {
+ case Qt::Key_1:
+ onePushButton->animateClick();
+ break;
+ case Qt::Key_2:
+ case Qt::Key_A:
+ case Qt::Key_B:
+ case Qt::Key_C:
+ twoPushButton->animateClick();
+ break;
+ case Qt::Key_3:
+ case Qt::Key_D:
+ case Qt::Key_E:
+ case Qt::Key_F:
+ threePushButton->animateClick();
+ dtmf3();
+ break;
+ case Qt::Key_4:
+ case Qt::Key_G:
+ case Qt::Key_H:
+ case Qt::Key_I:
+ fourPushButton->animateClick();
+ break;
+ case Qt::Key_5:
+ case Qt::Key_J:
+ case Qt::Key_K:
+ case Qt::Key_L:
+ fivePushButton->animateClick();
+ break;
+ case Qt::Key_6:
+ case Qt::Key_M:
+ case Qt::Key_N:
+ case Qt::Key_O:
+ sixPushButton->animateClick();
+ break;
+ case Qt::Key_7:
+ case Qt::Key_P:
+ case Qt::Key_Q:
+ case Qt::Key_R:
+ case Qt::Key_S:
+ sevenPushButton->animateClick();
+ break;
+ case Qt::Key_8:
+ case Qt::Key_T:
+ case Qt::Key_U:
+ case Qt::Key_V:
+ eightPushButton->animateClick();
+ break;
+ case Qt::Key_9:
+ case Qt::Key_W:
+ case Qt::Key_X:
+ case Qt::Key_Y:
+ case Qt::Key_Z:
+ ninePushButton->animateClick();
+ break;
+ case Qt::Key_0:
+ case Qt::Key_Space:
+ zeroPushButton->animateClick();
+ break;
+ case Qt::Key_Asterisk:
+ starPushButton->animateClick();
+ break;
+ case Qt::Key_NumberSign:
+ poundPushButton->animateClick();
+ break;
+ default:
+ e->ignore();
+ }
+ }
+ else if ((e->modifiers() == Qt::ShiftModifier && e->key() == Qt::Key_Insert)
+ || (e->modifiers() == Qt::ControlModifier && e->key() == Qt::Key_V))
+ {
+ // Insert from clipboard
+ QClipboard *clipboard = QApplication::clipboard();
+ QString text = clipboard->text();
+
+ if (!text.isEmpty())
+ {
+ m_remainingKeys = text;
+ insertNextKey();
+ m_insertTimer.start();
+ }
}
}
+
+void DtmfForm::insertNextKey()
+{
+ QChar key;
+ bool keyValid;
+
+ do
+ {
+ keyValid = true;
+ key = m_remainingKeys[0].toLower();
+ m_remainingKeys = m_remainingKeys.mid(1);
+
+ switch (key.toLatin1()) {
+ case '0':
+ zeroPushButton->animateClick();
+ break;
+ case '1':
+ onePushButton->animateClick();
+ break;
+ case '2':
+ twoPushButton->animateClick();
+ break;
+ case '3':
+ threePushButton->animateClick();
+ break;
+ case '4':
+ fourPushButton->animateClick();
+ break;
+ case '5':
+ fivePushButton->animateClick();
+ break;
+ case '6' :
+ sixPushButton->animateClick();
+ break;
+ case '7':
+ sevenPushButton->animateClick();
+ break;
+ case '8':
+ eightPushButton->animateClick();
+ break;
+ case '9':
+ ninePushButton->animateClick();
+ break;
+ case '#':
+ poundPushButton->animateClick();
+ break;
+ case '*':
+ starPushButton->animateClick();
+ break;
+ default:
+ keyValid = false;
+ break;
+ }
+ }
+ while (!keyValid);
+
+ if (m_remainingKeys.isEmpty())
+ m_insertTimer.stop();
+}
diff --git a/src/gui/dtmfform.h b/src/gui/dtmfform.h
index a9c6b45..82ad117 100644
--- a/src/gui/dtmfform.h
+++ b/src/gui/dtmfform.h
@@ -3,6 +3,7 @@
#include <QDialog>
#include <QKeyEvent>
+#include <QTimer>
#include "ui_dtmfform.h"
class DtmfForm : public QDialog, private Ui::DtmfForm
@@ -30,10 +31,16 @@ public slots:
void dtmfB();
void dtmfC();
void dtmfD();
- void keyPressEvent(QKeyEvent* e);
+ void insertNextKey();
+
+protected:
+ void keyPressEvent(QKeyEvent* e);
signals:
void digits(const QString&);
+private:
+ QTimer m_insertTimer;
+ QString m_remainingKeys;
};
#endif // DTMFFORM_H
diff --git a/src/gui/dtmfform.ui b/src/gui/dtmfform.ui
index 0afc026..ceac3b5 100644
--- a/src/gui/dtmfform.ui
+++ b/src/gui/dtmfform.ui
@@ -1,685 +1,782 @@
<?xml version="1.0" encoding="UTF-8"?>
-<ui version="4.0" stdsetdef="1">
- <author></author>
- <comment></comment>
- <exportmacro></exportmacro>
- <class>DtmfForm</class>
- <widget class="QDialog" name="DtmfForm">
- <property name="geometry">
- <rect>
- <x>0</x>
- <y>0</y>
- <width>350</width>
- <height>302</height>
- </rect>
- </property>
- <property name="sizePolicy">
- <sizepolicy>
- <hsizetype>5</hsizetype>
- <vsizetype>5</vsizetype>
- <horstretch>0</horstretch>
- <verstretch>0</verstretch>
- </sizepolicy>
- </property>
- <property name="windowTitle">
- <string>Twinkle - DTMF</string>
- </property>
- <layout class="QVBoxLayout">
- <item>
- <widget class="QGroupBox" name="keypadGroupBox">
- <property name="title">
- <string>Keypad</string>
- </property>
- <layout class="QGridLayout">
- <item row="0" column="1">
- <widget class="QPushButton" name="twoPushButton">
- <property name="font">
- <font>
- <pointsize>10</pointsize>
- </font>
- </property>
- <property name="text">
- <string/>
- </property>
- <property name="icon">
- <iconset resource="icons.qrc">
- <normaloff>:/icons/images/dtmf-2.png</normaloff>:/icons/images/dtmf-2.png</iconset>
- </property>
- <property name="iconSize">
- <size>
- <width>22</width>
- <height>22</height>
- </size>
- </property>
- <property name="whatsThis" stdset="0">
- <string>2</string>
- </property>
- </widget>
- </item>
- <item row="0" column="2">
- <widget class="QPushButton" name="threePushButton">
- <property name="font">
- <font>
- <pointsize>10</pointsize>
- </font>
- </property>
- <property name="text">
- <string/>
- </property>
- <property name="icon">
- <iconset resource="icons.qrc">
- <normaloff>:/icons/images/dtmf-3.png</normaloff>:/icons/images/dtmf-3.png</iconset>
- </property>
- <property name="iconSize">
- <size>
- <width>22</width>
- <height>22</height>
- </size>
- </property>
- <property name="whatsThis" stdset="0">
- <string>3</string>
- </property>
- </widget>
- </item>
- <item row="0" column="3">
- <widget class="QPushButton" name="aPushButton">
- <property name="text">
- <string/>
- </property>
- <property name="icon">
- <iconset resource="icons.qrc">
- <normaloff>:/icons/images/dtmf-a.png</normaloff>:/icons/images/dtmf-a.png</iconset>
- </property>
- <property name="iconSize">
- <size>
- <width>22</width>
- <height>22</height>
- </size>
- </property>
- <property name="whatsThis" stdset="0">
- <string>Over decadic A. Normally not needed.</string>
- </property>
- <property name="palette">
- <palette>
- <active>
- <colorrole role="Button">
- <brush brushstyle="SolidPattern">
- <color alpha="255">
- <red>194</red>
- <green>202</green>
- <blue>210</blue>
- </color>
- </brush>
- </colorrole>
- </active>
- <inactive>
- <colorrole role="Button">
- <brush brushstyle="SolidPattern">
- <color alpha="255">
- <red>194</red>
- <green>202</green>
- <blue>210</blue>
- </color>
- </brush>
- </colorrole>
- </inactive>
- <disabled>
- <colorrole role="Button">
- <brush brushstyle="SolidPattern">
- <color alpha="255">
- <red>194</red>
- <green>202</green>
- <blue>210</blue>
- </color>
- </brush>
- </colorrole>
- </disabled>
- </palette>
- </property>
- </widget>
- </item>
- <item row="1" column="0">
- <widget class="QPushButton" name="fourPushButton">
- <property name="text">
- <string/>
- </property>
- <property name="icon">
- <iconset resource="icons.qrc">
- <normaloff>:/icons/images/dtmf-4.png</normaloff>:/icons/images/dtmf-4.png</iconset>
- </property>
- <property name="iconSize">
- <size>
- <width>22</width>
- <height>22</height>
- </size>
- </property>
- <property name="whatsThis" stdset="0">
- <string>4</string>
- </property>
- </widget>
- </item>
- <item row="1" column="1">
- <widget class="QPushButton" name="fivePushButton">
- <property name="text">
- <string/>
- </property>
- <property name="icon">
- <iconset resource="icons.qrc">
- <normaloff>:/icons/images/dtmf-5.png</normaloff>:/icons/images/dtmf-5.png</iconset>
- </property>
- <property name="iconSize">
- <size>
- <width>22</width>
- <height>22</height>
- </size>
- </property>
- <property name="whatsThis" stdset="0">
- <string>5</string>
- </property>
- </widget>
- </item>
- <item row="1" column="2">
- <widget class="QPushButton" name="sixPushButton">
- <property name="text">
- <string/>
- </property>
- <property name="icon">
- <iconset resource="icons.qrc">
- <normaloff>:/icons/images/dtmf-6.png</normaloff>:/icons/images/dtmf-6.png</iconset>
- </property>
- <property name="iconSize">
- <size>
- <width>22</width>
- <height>22</height>
- </size>
- </property>
- <property name="whatsThis" stdset="0">
- <string>6</string>
- </property>
- </widget>
- </item>
- <item row="1" column="3">
- <widget class="QPushButton" name="bPushButton">
- <property name="text">
- <string/>
- </property>
- <property name="icon">
- <iconset resource="icons.qrc">
- <normaloff>:/icons/images/dtmf-b.png</normaloff>:/icons/images/dtmf-b.png</iconset>
- </property>
- <property name="iconSize">
- <size>
- <width>22</width>
- <height>22</height>
- </size>
- </property>
- <property name="whatsThis" stdset="0">
- <string>Over decadic B. Normally not needed.</string>
- </property>
- <property name="palette">
- <palette>
- <active>
- <colorrole role="Button">
- <brush brushstyle="SolidPattern">
- <color alpha="255">
- <red>194</red>
- <green>202</green>
- <blue>210</blue>
- </color>
- </brush>
- </colorrole>
- </active>
- <inactive>
- <colorrole role="Button">
- <brush brushstyle="SolidPattern">
- <color alpha="255">
- <red>194</red>
- <green>202</green>
- <blue>210</blue>
- </color>
- </brush>
- </colorrole>
- </inactive>
- <disabled>
- <colorrole role="Button">
- <brush brushstyle="SolidPattern">
- <color alpha="255">
- <red>194</red>
- <green>202</green>
- <blue>210</blue>
- </color>
- </brush>
- </colorrole>
- </disabled>
- </palette>
- </property>
- </widget>
- </item>
- <item row="2" column="0">
- <widget class="QPushButton" name="sevenPushButton">
- <property name="text">
- <string/>
- </property>
- <property name="icon">
- <iconset resource="icons.qrc">
- <normaloff>:/icons/images/dtmf-7.png</normaloff>:/icons/images/dtmf-7.png</iconset>
- </property>
- <property name="iconSize">
- <size>
- <width>22</width>
- <height>22</height>
- </size>
- </property>
- <property name="whatsThis" stdset="0">
- <string>7</string>
- </property>
- </widget>
- </item>
- <item row="2" column="1">
- <widget class="QPushButton" name="eightPushButton">
- <property name="text">
- <string/>
- </property>
- <property name="icon">
- <iconset resource="icons.qrc">
- <normaloff>:/icons/images/dtmf-8.png</normaloff>:/icons/images/dtmf-8.png</iconset>
- </property>
- <property name="iconSize">
- <size>
- <width>22</width>
- <height>22</height>
- </size>
- </property>
- <property name="whatsThis" stdset="0">
- <string>8</string>
- </property>
- </widget>
- </item>
- <item row="2" column="2">
- <widget class="QPushButton" name="ninePushButton">
- <property name="text">
- <string/>
- </property>
- <property name="icon">
- <iconset resource="icons.qrc">
- <normaloff>:/icons/images/dtmf-9.png</normaloff>:/icons/images/dtmf-9.png</iconset>
- </property>
- <property name="iconSize">
- <size>
- <width>22</width>
- <height>22</height>
- </size>
- </property>
- <property name="whatsThis" stdset="0">
- <string>9</string>
- </property>
- </widget>
- </item>
- <item row="2" column="3">
- <widget class="QPushButton" name="cPushButton">
- <property name="text">
- <string/>
- </property>
- <property name="icon">
- <iconset resource="icons.qrc">
- <normaloff>:/icons/images/dtmf-c.png</normaloff>:/icons/images/dtmf-c.png</iconset>
- </property>
- <property name="iconSize">
- <size>
- <width>22</width>
- <height>22</height>
- </size>
- </property>
- <property name="whatsThis" stdset="0">
- <string>Over decadic C. Normally not needed.</string>
- </property>
- <property name="palette">
- <palette>
- <active>
- <colorrole role="Button">
- <brush brushstyle="SolidPattern">
- <color alpha="255">
- <red>194</red>
- <green>202</green>
- <blue>210</blue>
- </color>
- </brush>
- </colorrole>
- </active>
- <inactive>
- <colorrole role="Button">
- <brush brushstyle="SolidPattern">
- <color alpha="255">
- <red>194</red>
- <green>202</green>
- <blue>210</blue>
- </color>
- </brush>
- </colorrole>
- </inactive>
- <disabled>
- <colorrole role="Button">
- <brush brushstyle="SolidPattern">
- <color alpha="255">
- <red>194</red>
- <green>202</green>
- <blue>210</blue>
- </color>
- </brush>
- </colorrole>
- </disabled>
- </palette>
- </property>
- </widget>
- </item>
- <item row="3" column="0">
- <widget class="QPushButton" name="starPushButton">
- <property name="text">
- <string/>
- </property>
- <property name="icon">
- <iconset resource="icons.qrc">
- <normaloff>:/icons/images/dtmf-star.png</normaloff>:/icons/images/dtmf-star.png</iconset>
- </property>
- <property name="iconSize">
- <size>
- <width>22</width>
- <height>22</height>
- </size>
- </property>
- <property name="whatsThis" stdset="0">
- <string>Star (*)</string>
- </property>
- </widget>
- </item>
- <item row="3" column="1">
- <widget class="QPushButton" name="zeroPushButton">
- <property name="text">
- <string/>
- </property>
- <property name="icon">
- <iconset resource="icons.qrc">
- <normaloff>:/icons/images/dtmf-0.png</normaloff>:/icons/images/dtmf-0.png</iconset>
- </property>
- <property name="iconSize">
- <size>
- <width>22</width>
- <height>22</height>
- </size>
- </property>
- <property name="whatsThis" stdset="0">
- <string>0</string>
- </property>
- </widget>
- </item>
- <item row="3" column="2">
- <widget class="QPushButton" name="poundPushButton">
- <property name="text">
- <string/>
- </property>
- <property name="icon">
- <iconset resource="icons.qrc">
- <normaloff>:/icons/images/dtmf-pound.png</normaloff>:/icons/images/dtmf-pound.png</iconset>
- </property>
- <property name="iconSize">
- <size>
- <width>22</width>
- <height>22</height>
- </size>
- </property>
- <property name="whatsThis" stdset="0">
- <string>Pound (#)</string>
- </property>
- </widget>
- </item>
- <item row="3" column="3">
- <widget class="QPushButton" name="dPushButton">
- <property name="text">
- <string/>
- </property>
- <property name="icon">
- <iconset resource="icons.qrc">
- <normaloff>:/icons/images/dtmf-d.png</normaloff>:/icons/images/dtmf-d.png</iconset>
- </property>
- <property name="iconSize">
- <size>
- <width>22</width>
- <height>22</height>
- </size>
- </property>
- <property name="whatsThis" stdset="0">
- <string>Over decadic D. Normally not needed.</string>
- </property>
- <property name="palette">
- <palette>
- <active>
- <colorrole role="Button">
- <brush brushstyle="SolidPattern">
- <color alpha="255">
- <red>194</red>
- <green>202</green>
- <blue>210</blue>
- </color>
- </brush>
- </colorrole>
- </active>
- <inactive>
- <colorrole role="Button">
- <brush brushstyle="SolidPattern">
- <color alpha="255">
- <red>194</red>
- <green>202</green>
- <blue>210</blue>
- </color>
- </brush>
- </colorrole>
- </inactive>
- <disabled>
- <colorrole role="Button">
- <brush brushstyle="SolidPattern">
- <color alpha="255">
- <red>194</red>
- <green>202</green>
- <blue>210</blue>
- </color>
- </brush>
- </colorrole>
- </disabled>
- </palette>
- </property>
- </widget>
- </item>
- <item row="0" column="0">
- <widget class="QPushButton" name="onePushButton">
- <property name="font">
- <font>
- <pointsize>10</pointsize>
- </font>
- </property>
- <property name="text">
- <string/>
- </property>
- <property name="icon">
- <iconset resource="icons.qrc">
- <normaloff>:/icons/images/dtmf-1.png</normaloff>:/icons/images/dtmf-1.png</iconset>
- </property>
- <property name="iconSize">
- <size>
- <width>22</width>
- <height>22</height>
- </size>
- </property>
- <property name="autoDefault">
- <bool>true</bool>
- </property>
- <property name="whatsThis" stdset="0">
- <string>1</string>
- </property>
- </widget>
- </item>
- </layout>
- </widget>
+<ui version="4.0">
+ <class>DtmfForm</class>
+ <widget class="QDialog" name="DtmfForm">
+ <property name="geometry">
+ <rect>
+ <x>0</x>
+ <y>0</y>
+ <width>350</width>
+ <height>302</height>
+ </rect>
+ </property>
+ <property name="sizePolicy">
+ <sizepolicy hsizetype="Preferred" vsizetype="Preferred">
+ <horstretch>0</horstretch>
+ <verstretch>0</verstretch>
+ </sizepolicy>
+ </property>
+ <property name="windowTitle">
+ <string>Twinkle - DTMF</string>
+ </property>
+ <layout class="QVBoxLayout">
+ <item>
+ <widget class="QGroupBox" name="keypadGroupBox">
+ <property name="title">
+ <string>Keypad</string>
+ </property>
+ <layout class="QGridLayout">
+ <item row="0" column="1">
+ <widget class="QPushButton" name="twoPushButton">
+ <property name="sizePolicy">
+ <sizepolicy hsizetype="Minimum" vsizetype="MinimumExpanding">
+ <horstretch>0</horstretch>
+ <verstretch>0</verstretch>
+ </sizepolicy>
+ </property>
+ <property name="font">
+ <font>
+ <pointsize>8</pointsize>
+ </font>
+ </property>
+ <property name="whatsThis">
+ <string>2</string>
+ </property>
+ <property name="text">
+ <string notr="true">2
+abc</string>
+ </property>
+ </widget>
</item>
- <item>
- <layout class="QHBoxLayout">
- <item>
- <spacer name="spacer20">
- <property name="sizeHint">
- <size>
- <width>291</width>
- <height>20</height>
- </size>
- </property>
- <property name="sizeType">
- <enum>QSizePolicy::Expanding</enum>
- </property>
- <property name="orientation">
- <enum>Qt::Horizontal</enum>
- </property>
- </spacer>
- </item>
- <item>
- <widget class="QPushButton" name="closePushButton">
- <property name="text">
- <string>&amp;Close</string>
- </property>
- <property name="shortcut">
- <string>Alt+C</string>
- </property>
- <property name="default">
- <bool>true</bool>
- </property>
- </widget>
- </item>
- </layout>
+ <item row="0" column="2">
+ <widget class="QPushButton" name="threePushButton">
+ <property name="sizePolicy">
+ <sizepolicy hsizetype="Minimum" vsizetype="MinimumExpanding">
+ <horstretch>0</horstretch>
+ <verstretch>0</verstretch>
+ </sizepolicy>
+ </property>
+ <property name="whatsThis">
+ <string>3</string>
+ </property>
+ <property name="text">
+ <string notr="true">3
+def</string>
+ </property>
+ </widget>
</item>
+ <item row="0" column="3">
+ <widget class="QPushButton" name="aPushButton">
+ <property name="sizePolicy">
+ <sizepolicy hsizetype="Minimum" vsizetype="MinimumExpanding">
+ <horstretch>0</horstretch>
+ <verstretch>0</verstretch>
+ </sizepolicy>
+ </property>
+ <property name="palette">
+ <palette>
+ <active>
+ <colorrole role="Button">
+ <brush brushstyle="SolidPattern">
+ <color alpha="255">
+ <red>194</red>
+ <green>202</green>
+ <blue>210</blue>
+ </color>
+ </brush>
+ </colorrole>
+ </active>
+ <inactive>
+ <colorrole role="Button">
+ <brush brushstyle="SolidPattern">
+ <color alpha="255">
+ <red>194</red>
+ <green>202</green>
+ <blue>210</blue>
+ </color>
+ </brush>
+ </colorrole>
+ </inactive>
+ <disabled>
+ <colorrole role="Button">
+ <brush brushstyle="SolidPattern">
+ <color alpha="255">
+ <red>194</red>
+ <green>202</green>
+ <blue>210</blue>
+ </color>
+ </brush>
+ </colorrole>
+ </disabled>
+ </palette>
+ </property>
+ <property name="whatsThis">
+ <string>Over decadic A. Normally not needed.</string>
+ </property>
+ <property name="text">
+ <string notr="true">A</string>
+ </property>
+ </widget>
+ </item>
+ <item row="1" column="0">
+ <widget class="QPushButton" name="fourPushButton">
+ <property name="sizePolicy">
+ <sizepolicy hsizetype="Minimum" vsizetype="MinimumExpanding">
+ <horstretch>0</horstretch>
+ <verstretch>0</verstretch>
+ </sizepolicy>
+ </property>
+ <property name="whatsThis">
+ <string>4</string>
+ </property>
+ <property name="text">
+ <string notr="true">4
+ghi</string>
+ </property>
+ </widget>
+ </item>
+ <item row="1" column="1">
+ <widget class="QPushButton" name="fivePushButton">
+ <property name="sizePolicy">
+ <sizepolicy hsizetype="Minimum" vsizetype="MinimumExpanding">
+ <horstretch>0</horstretch>
+ <verstretch>0</verstretch>
+ </sizepolicy>
+ </property>
+ <property name="whatsThis">
+ <string>5</string>
+ </property>
+ <property name="text">
+ <string notr="true">5
+jkl</string>
+ </property>
+ </widget>
+ </item>
+ <item row="1" column="2">
+ <widget class="QPushButton" name="sixPushButton">
+ <property name="sizePolicy">
+ <sizepolicy hsizetype="Minimum" vsizetype="MinimumExpanding">
+ <horstretch>0</horstretch>
+ <verstretch>0</verstretch>
+ </sizepolicy>
+ </property>
+ <property name="whatsThis">
+ <string>6</string>
+ </property>
+ <property name="text">
+ <string notr="true">6
+mno</string>
+ </property>
+ </widget>
+ </item>
+ <item row="1" column="3">
+ <widget class="QPushButton" name="bPushButton">
+ <property name="sizePolicy">
+ <sizepolicy hsizetype="Minimum" vsizetype="MinimumExpanding">
+ <horstretch>0</horstretch>
+ <verstretch>0</verstretch>
+ </sizepolicy>
+ </property>
+ <property name="palette">
+ <palette>
+ <active>
+ <colorrole role="Button">
+ <brush brushstyle="SolidPattern">
+ <color alpha="255">
+ <red>194</red>
+ <green>202</green>
+ <blue>210</blue>
+ </color>
+ </brush>
+ </colorrole>
+ </active>
+ <inactive>
+ <colorrole role="Button">
+ <brush brushstyle="SolidPattern">
+ <color alpha="255">
+ <red>194</red>
+ <green>202</green>
+ <blue>210</blue>
+ </color>
+ </brush>
+ </colorrole>
+ </inactive>
+ <disabled>
+ <colorrole role="Button">
+ <brush brushstyle="SolidPattern">
+ <color alpha="255">
+ <red>194</red>
+ <green>202</green>
+ <blue>210</blue>
+ </color>
+ </brush>
+ </colorrole>
+ </disabled>
+ </palette>
+ </property>
+ <property name="whatsThis">
+ <string>Over decadic B. Normally not needed.</string>
+ </property>
+ <property name="text">
+ <string notr="true">B</string>
+ </property>
+ </widget>
+ </item>
+ <item row="2" column="0">
+ <widget class="QPushButton" name="sevenPushButton">
+ <property name="sizePolicy">
+ <sizepolicy hsizetype="Minimum" vsizetype="MinimumExpanding">
+ <horstretch>0</horstretch>
+ <verstretch>0</verstretch>
+ </sizepolicy>
+ </property>
+ <property name="whatsThis">
+ <string>7</string>
+ </property>
+ <property name="text">
+ <string notr="true">7
+pqrs</string>
+ </property>
+ </widget>
+ </item>
+ <item row="2" column="1">
+ <widget class="QPushButton" name="eightPushButton">
+ <property name="sizePolicy">
+ <sizepolicy hsizetype="Minimum" vsizetype="MinimumExpanding">
+ <horstretch>0</horstretch>
+ <verstretch>0</verstretch>
+ </sizepolicy>
+ </property>
+ <property name="whatsThis">
+ <string>8</string>
+ </property>
+ <property name="text">
+ <string notr="true">8
+tuv</string>
+ </property>
+ </widget>
+ </item>
+ <item row="2" column="2">
+ <widget class="QPushButton" name="ninePushButton">
+ <property name="sizePolicy">
+ <sizepolicy hsizetype="Minimum" vsizetype="MinimumExpanding">
+ <horstretch>0</horstretch>
+ <verstretch>0</verstretch>
+ </sizepolicy>
+ </property>
+ <property name="whatsThis">
+ <string>9</string>
+ </property>
+ <property name="text">
+ <string notr="true">9
+wxyz</string>
+ </property>
+ </widget>
+ </item>
+ <item row="2" column="3">
+ <widget class="QPushButton" name="cPushButton">
+ <property name="sizePolicy">
+ <sizepolicy hsizetype="Minimum" vsizetype="MinimumExpanding">
+ <horstretch>0</horstretch>
+ <verstretch>0</verstretch>
+ </sizepolicy>
+ </property>
+ <property name="palette">
+ <palette>
+ <active>
+ <colorrole role="Button">
+ <brush brushstyle="SolidPattern">
+ <color alpha="255">
+ <red>194</red>
+ <green>202</green>
+ <blue>210</blue>
+ </color>
+ </brush>
+ </colorrole>
+ </active>
+ <inactive>
+ <colorrole role="Button">
+ <brush brushstyle="SolidPattern">
+ <color alpha="255">
+ <red>194</red>
+ <green>202</green>
+ <blue>210</blue>
+ </color>
+ </brush>
+ </colorrole>
+ </inactive>
+ <disabled>
+ <colorrole role="Button">
+ <brush brushstyle="SolidPattern">
+ <color alpha="255">
+ <red>194</red>
+ <green>202</green>
+ <blue>210</blue>
+ </color>
+ </brush>
+ </colorrole>
+ </disabled>
+ </palette>
+ </property>
+ <property name="whatsThis">
+ <string>Over decadic C. Normally not needed.</string>
+ </property>
+ <property name="text">
+ <string notr="true">C</string>
+ </property>
+ </widget>
+ </item>
+ <item row="3" column="0">
+ <widget class="QPushButton" name="starPushButton">
+ <property name="sizePolicy">
+ <sizepolicy hsizetype="Minimum" vsizetype="MinimumExpanding">
+ <horstretch>0</horstretch>
+ <verstretch>0</verstretch>
+ </sizepolicy>
+ </property>
+ <property name="whatsThis">
+ <string>Star (*)</string>
+ </property>
+ <property name="text">
+ <string notr="true">*</string>
+ </property>
+ </widget>
+ </item>
+ <item row="3" column="1">
+ <widget class="QPushButton" name="zeroPushButton">
+ <property name="sizePolicy">
+ <sizepolicy hsizetype="Minimum" vsizetype="MinimumExpanding">
+ <horstretch>0</horstretch>
+ <verstretch>0</verstretch>
+ </sizepolicy>
+ </property>
+ <property name="whatsThis">
+ <string>0</string>
+ </property>
+ <property name="text">
+ <string notr="true">0</string>
+ </property>
+ </widget>
+ </item>
+ <item row="3" column="2">
+ <widget class="QPushButton" name="poundPushButton">
+ <property name="sizePolicy">
+ <sizepolicy hsizetype="Minimum" vsizetype="MinimumExpanding">
+ <horstretch>0</horstretch>
+ <verstretch>0</verstretch>
+ </sizepolicy>
+ </property>
+ <property name="whatsThis">
+ <string>Pound (#)</string>
+ </property>
+ <property name="text">
+ <string notr="true">#</string>
+ </property>
+ </widget>
+ </item>
+ <item row="3" column="3">
+ <widget class="QPushButton" name="dPushButton">
+ <property name="sizePolicy">
+ <sizepolicy hsizetype="Minimum" vsizetype="MinimumExpanding">
+ <horstretch>0</horstretch>
+ <verstretch>0</verstretch>
+ </sizepolicy>
+ </property>
+ <property name="palette">
+ <palette>
+ <active>
+ <colorrole role="Button">
+ <brush brushstyle="SolidPattern">
+ <color alpha="255">
+ <red>194</red>
+ <green>202</green>
+ <blue>210</blue>
+ </color>
+ </brush>
+ </colorrole>
+ </active>
+ <inactive>
+ <colorrole role="Button">
+ <brush brushstyle="SolidPattern">
+ <color alpha="255">
+ <red>194</red>
+ <green>202</green>
+ <blue>210</blue>
+ </color>
+ </brush>
+ </colorrole>
+ </inactive>
+ <disabled>
+ <colorrole role="Button">
+ <brush brushstyle="SolidPattern">
+ <color alpha="255">
+ <red>194</red>
+ <green>202</green>
+ <blue>210</blue>
+ </color>
+ </brush>
+ </colorrole>
+ </disabled>
+ </palette>
+ </property>
+ <property name="whatsThis">
+ <string>Over decadic D. Normally not needed.</string>
+ </property>
+ <property name="text">
+ <string notr="true">D</string>
+ </property>
+ </widget>
+ </item>
+ <item row="0" column="0">
+ <widget class="QPushButton" name="onePushButton">
+ <property name="sizePolicy">
+ <sizepolicy hsizetype="Minimum" vsizetype="MinimumExpanding">
+ <horstretch>0</horstretch>
+ <verstretch>0</verstretch>
+ </sizepolicy>
+ </property>
+ <property name="whatsThis">
+ <string>1</string>
+ </property>
+ <property name="text">
+ <string notr="true">1</string>
+ </property>
+ <property name="autoDefault">
+ <bool>true</bool>
+ </property>
+ </widget>
+ </item>
+ </layout>
+ </widget>
+ </item>
+ <item>
+ <layout class="QHBoxLayout">
+ <item>
+ <spacer name="spacer20">
+ <property name="orientation">
+ <enum>Qt::Horizontal</enum>
+ </property>
+ <property name="sizeType">
+ <enum>QSizePolicy::Expanding</enum>
+ </property>
+ <property name="sizeHint" stdset="0">
+ <size>
+ <width>291</width>
+ <height>20</height>
+ </size>
+ </property>
+ </spacer>
+ </item>
+ <item>
+ <widget class="QPushButton" name="closePushButton">
+ <property name="text">
+ <string>&amp;Close</string>
+ </property>
+ <property name="shortcut">
+ <string>Alt+C</string>
+ </property>
+ <property name="default">
+ <bool>true</bool>
+ </property>
+ </widget>
+ </item>
</layout>
- </widget>
- <layoutdefault spacing="6" margin="11"/>
- <tabstops>
- <tabstop>onePushButton</tabstop>
- <tabstop>twoPushButton</tabstop>
- <tabstop>threePushButton</tabstop>
- <tabstop>aPushButton</tabstop>
- <tabstop>fourPushButton</tabstop>
- <tabstop>fivePushButton</tabstop>
- <tabstop>sixPushButton</tabstop>
- <tabstop>bPushButton</tabstop>
- <tabstop>sevenPushButton</tabstop>
- <tabstop>eightPushButton</tabstop>
- <tabstop>ninePushButton</tabstop>
- <tabstop>cPushButton</tabstop>
- <tabstop>starPushButton</tabstop>
- <tabstop>zeroPushButton</tabstop>
- <tabstop>poundPushButton</tabstop>
- <tabstop>dPushButton</tabstop>
- <tabstop>closePushButton</tabstop>
- </tabstops>
- <resources>
- <include location="icons.qrc"/>
- </resources>
- <connections>
- <connection>
- <sender>closePushButton</sender>
- <signal>clicked()</signal>
- <receiver>DtmfForm</receiver>
- <slot>accept()</slot>
- </connection>
- <connection>
- <sender>onePushButton</sender>
- <signal>clicked()</signal>
- <receiver>DtmfForm</receiver>
- <slot>dtmf1()</slot>
- </connection>
- <connection>
- <sender>twoPushButton</sender>
- <signal>clicked()</signal>
- <receiver>DtmfForm</receiver>
- <slot>dtmf2()</slot>
- </connection>
- <connection>
- <sender>threePushButton</sender>
- <signal>clicked()</signal>
- <receiver>DtmfForm</receiver>
- <slot>dtmf3()</slot>
- </connection>
- <connection>
- <sender>fourPushButton</sender>
- <signal>clicked()</signal>
- <receiver>DtmfForm</receiver>
- <slot>dtmf4()</slot>
- </connection>
- <connection>
- <sender>fivePushButton</sender>
- <signal>clicked()</signal>
- <receiver>DtmfForm</receiver>
- <slot>dtmf5()</slot>
- </connection>
- <connection>
- <sender>sixPushButton</sender>
- <signal>clicked()</signal>
- <receiver>DtmfForm</receiver>
- <slot>dtmf6()</slot>
- </connection>
- <connection>
- <sender>sevenPushButton</sender>
- <signal>clicked()</signal>
- <receiver>DtmfForm</receiver>
- <slot>dtmf7()</slot>
- </connection>
- <connection>
- <sender>eightPushButton</sender>
- <signal>clicked()</signal>
- <receiver>DtmfForm</receiver>
- <slot>dtmf8()</slot>
- </connection>
- <connection>
- <sender>ninePushButton</sender>
- <signal>clicked()</signal>
- <receiver>DtmfForm</receiver>
- <slot>dtmf9()</slot>
- </connection>
- <connection>
- <sender>zeroPushButton</sender>
- <signal>clicked()</signal>
- <receiver>DtmfForm</receiver>
- <slot>dtmf0()</slot>
- </connection>
- <connection>
- <sender>starPushButton</sender>
- <signal>clicked()</signal>
- <receiver>DtmfForm</receiver>
- <slot>dtmfStar()</slot>
- </connection>
- <connection>
- <sender>poundPushButton</sender>
- <signal>clicked()</signal>
- <receiver>DtmfForm</receiver>
- <slot>dtmfPound()</slot>
- </connection>
- <connection>
- <sender>aPushButton</sender>
- <signal>clicked()</signal>
- <receiver>DtmfForm</receiver>
- <slot>dtmfA()</slot>
- </connection>
- <connection>
- <sender>bPushButton</sender>
- <signal>clicked()</signal>
- <receiver>DtmfForm</receiver>
- <slot>dtmfB()</slot>
- </connection>
- <connection>
- <sender>cPushButton</sender>
- <signal>clicked()</signal>
- <receiver>DtmfForm</receiver>
- <slot>dtmfC()</slot>
- </connection>
- <connection>
- <sender>dPushButton</sender>
- <signal>clicked()</signal>
- <receiver>DtmfForm</receiver>
- <slot>dtmfD()</slot>
- </connection>
- </connections>
+ </item>
+ </layout>
+ </widget>
+ <layoutdefault spacing="6" margin="11"/>
+ <tabstops>
+ <tabstop>onePushButton</tabstop>
+ <tabstop>twoPushButton</tabstop>
+ <tabstop>threePushButton</tabstop>
+ <tabstop>aPushButton</tabstop>
+ <tabstop>fourPushButton</tabstop>
+ <tabstop>fivePushButton</tabstop>
+ <tabstop>sixPushButton</tabstop>
+ <tabstop>bPushButton</tabstop>
+ <tabstop>sevenPushButton</tabstop>
+ <tabstop>eightPushButton</tabstop>
+ <tabstop>ninePushButton</tabstop>
+ <tabstop>cPushButton</tabstop>
+ <tabstop>starPushButton</tabstop>
+ <tabstop>zeroPushButton</tabstop>
+ <tabstop>poundPushButton</tabstop>
+ <tabstop>dPushButton</tabstop>
+ <tabstop>closePushButton</tabstop>
+ </tabstops>
+ <resources/>
+ <connections>
+ <connection>
+ <sender>closePushButton</sender>
+ <signal>clicked()</signal>
+ <receiver>DtmfForm</receiver>
+ <slot>accept()</slot>
+ <hints>
+ <hint type="sourcelabel">
+ <x>20</x>
+ <y>20</y>
+ </hint>
+ <hint type="destinationlabel">
+ <x>20</x>
+ <y>20</y>
+ </hint>
+ </hints>
+ </connection>
+ <connection>
+ <sender>onePushButton</sender>
+ <signal>clicked()</signal>
+ <receiver>DtmfForm</receiver>
+ <slot>dtmf1()</slot>
+ <hints>
+ <hint type="sourcelabel">
+ <x>20</x>
+ <y>20</y>
+ </hint>
+ <hint type="destinationlabel">
+ <x>20</x>
+ <y>20</y>
+ </hint>
+ </hints>
+ </connection>
+ <connection>
+ <sender>twoPushButton</sender>
+ <signal>clicked()</signal>
+ <receiver>DtmfForm</receiver>
+ <slot>dtmf2()</slot>
+ <hints>
+ <hint type="sourcelabel">
+ <x>20</x>
+ <y>20</y>
+ </hint>
+ <hint type="destinationlabel">
+ <x>20</x>
+ <y>20</y>
+ </hint>
+ </hints>
+ </connection>
+ <connection>
+ <sender>threePushButton</sender>
+ <signal>clicked()</signal>
+ <receiver>DtmfForm</receiver>
+ <slot>dtmf3()</slot>
+ <hints>
+ <hint type="sourcelabel">
+ <x>20</x>
+ <y>20</y>
+ </hint>
+ <hint type="destinationlabel">
+ <x>20</x>
+ <y>20</y>
+ </hint>
+ </hints>
+ </connection>
+ <connection>
+ <sender>fourPushButton</sender>
+ <signal>clicked()</signal>
+ <receiver>DtmfForm</receiver>
+ <slot>dtmf4()</slot>
+ <hints>
+ <hint type="sourcelabel">
+ <x>20</x>
+ <y>20</y>
+ </hint>
+ <hint type="destinationlabel">
+ <x>20</x>
+ <y>20</y>
+ </hint>
+ </hints>
+ </connection>
+ <connection>
+ <sender>fivePushButton</sender>
+ <signal>clicked()</signal>
+ <receiver>DtmfForm</receiver>
+ <slot>dtmf5()</slot>
+ <hints>
+ <hint type="sourcelabel">
+ <x>20</x>
+ <y>20</y>
+ </hint>
+ <hint type="destinationlabel">
+ <x>20</x>
+ <y>20</y>
+ </hint>
+ </hints>
+ </connection>
+ <connection>
+ <sender>sixPushButton</sender>
+ <signal>clicked()</signal>
+ <receiver>DtmfForm</receiver>
+ <slot>dtmf6()</slot>
+ <hints>
+ <hint type="sourcelabel">
+ <x>20</x>
+ <y>20</y>
+ </hint>
+ <hint type="destinationlabel">
+ <x>20</x>
+ <y>20</y>
+ </hint>
+ </hints>
+ </connection>
+ <connection>
+ <sender>sevenPushButton</sender>
+ <signal>clicked()</signal>
+ <receiver>DtmfForm</receiver>
+ <slot>dtmf7()</slot>
+ <hints>
+ <hint type="sourcelabel">
+ <x>20</x>
+ <y>20</y>
+ </hint>
+ <hint type="destinationlabel">
+ <x>20</x>
+ <y>20</y>
+ </hint>
+ </hints>
+ </connection>
+ <connection>
+ <sender>eightPushButton</sender>
+ <signal>clicked()</signal>
+ <receiver>DtmfForm</receiver>
+ <slot>dtmf8()</slot>
+ <hints>
+ <hint type="sourcelabel">
+ <x>20</x>
+ <y>20</y>
+ </hint>
+ <hint type="destinationlabel">
+ <x>20</x>
+ <y>20</y>
+ </hint>
+ </hints>
+ </connection>
+ <connection>
+ <sender>ninePushButton</sender>
+ <signal>clicked()</signal>
+ <receiver>DtmfForm</receiver>
+ <slot>dtmf9()</slot>
+ <hints>
+ <hint type="sourcelabel">
+ <x>20</x>
+ <y>20</y>
+ </hint>
+ <hint type="destinationlabel">
+ <x>20</x>
+ <y>20</y>
+ </hint>
+ </hints>
+ </connection>
+ <connection>
+ <sender>zeroPushButton</sender>
+ <signal>clicked()</signal>
+ <receiver>DtmfForm</receiver>
+ <slot>dtmf0()</slot>
+ <hints>
+ <hint type="sourcelabel">
+ <x>20</x>
+ <y>20</y>
+ </hint>
+ <hint type="destinationlabel">
+ <x>20</x>
+ <y>20</y>
+ </hint>
+ </hints>
+ </connection>
+ <connection>
+ <sender>starPushButton</sender>
+ <signal>clicked()</signal>
+ <receiver>DtmfForm</receiver>
+ <slot>dtmfStar()</slot>
+ <hints>
+ <hint type="sourcelabel">
+ <x>20</x>
+ <y>20</y>
+ </hint>
+ <hint type="destinationlabel">
+ <x>20</x>
+ <y>20</y>
+ </hint>
+ </hints>
+ </connection>
+ <connection>
+ <sender>poundPushButton</sender>
+ <signal>clicked()</signal>
+ <receiver>DtmfForm</receiver>
+ <slot>dtmfPound()</slot>
+ <hints>
+ <hint type="sourcelabel">
+ <x>20</x>
+ <y>20</y>
+ </hint>
+ <hint type="destinationlabel">
+ <x>20</x>
+ <y>20</y>
+ </hint>
+ </hints>
+ </connection>
+ <connection>
+ <sender>aPushButton</sender>
+ <signal>clicked()</signal>
+ <receiver>DtmfForm</receiver>
+ <slot>dtmfA()</slot>
+ <hints>
+ <hint type="sourcelabel">
+ <x>20</x>
+ <y>20</y>
+ </hint>
+ <hint type="destinationlabel">
+ <x>20</x>
+ <y>20</y>
+ </hint>
+ </hints>
+ </connection>
+ <connection>
+ <sender>bPushButton</sender>
+ <signal>clicked()</signal>
+ <receiver>DtmfForm</receiver>
+ <slot>dtmfB()</slot>
+ <hints>
+ <hint type="sourcelabel">
+ <x>20</x>
+ <y>20</y>
+ </hint>
+ <hint type="destinationlabel">
+ <x>20</x>
+ <y>20</y>
+ </hint>
+ </hints>
+ </connection>
+ <connection>
+ <sender>cPushButton</sender>
+ <signal>clicked()</signal>
+ <receiver>DtmfForm</receiver>
+ <slot>dtmfC()</slot>
+ <hints>
+ <hint type="sourcelabel">
+ <x>20</x>
+ <y>20</y>
+ </hint>
+ <hint type="destinationlabel">
+ <x>20</x>
+ <y>20</y>
+ </hint>
+ </hints>
+ </connection>
+ <connection>
+ <sender>dPushButton</sender>
+ <signal>clicked()</signal>
+ <receiver>DtmfForm</receiver>
+ <slot>dtmfD()</slot>
+ <hints>
+ <hint type="sourcelabel">
+ <x>20</x>
+ <y>20</y>
+ </hint>
+ <hint type="destinationlabel">
+ <x>20</x>
+ <y>20</y>
+ </hint>
+ </hints>
+ </connection>
+ </connections>
</ui>