added prefix inputMask (not working); added some code for sourceList (not complete)
This commit is contained in:
parent
30bd0cd7c8
commit
82bcc756f0
@ -36,6 +36,24 @@ GmpConfigForm::GmpConfigForm(QWidget *parent)
|
|||||||
msgTypeCombo->addItem(kIgmpV3Report, "IGMPv3 Report");
|
msgTypeCombo->addItem(kIgmpV3Report, "IGMPv3 Report");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void GmpConfigForm::on_addSource_clicked()
|
||||||
|
{
|
||||||
|
QListWidgetItem *item=new QListWidgetItem("0.0.0.0");
|
||||||
|
item->setFlags(item->flags() | Qt::ItemIsEditable);
|
||||||
|
sourceList->insertItem(sourceList->currentRow(), item);
|
||||||
|
|
||||||
|
if (!overrideSourceCount->isChecked())
|
||||||
|
sourceCount->setText(QString().setNum(sourceList->count()));
|
||||||
|
}
|
||||||
|
|
||||||
|
void GmpConfigForm::on_deleteSource_clicked()
|
||||||
|
{
|
||||||
|
delete sourceList->takeItem(sourceList->currentRow());
|
||||||
|
|
||||||
|
if (!overrideSourceCount->isChecked())
|
||||||
|
sourceCount->setText(QString().setNum(sourceList->count()));
|
||||||
|
}
|
||||||
|
|
||||||
void GmpConfigForm::on_msgTypeCombo_currentIndexChanged(int /*index*/)
|
void GmpConfigForm::on_msgTypeCombo_currentIndexChanged(int /*index*/)
|
||||||
{
|
{
|
||||||
switch(msgTypeCombo->currentValue())
|
switch(msgTypeCombo->currentValue())
|
||||||
|
@ -62,6 +62,8 @@ public:
|
|||||||
GmpConfigForm(QWidget *parent = 0);
|
GmpConfigForm(QWidget *parent = 0);
|
||||||
private slots:
|
private slots:
|
||||||
void on_msgTypeCombo_currentIndexChanged(int index);
|
void on_msgTypeCombo_currentIndexChanged(int index);
|
||||||
|
void on_addSource_clicked();
|
||||||
|
void on_deleteSource_clicked();
|
||||||
};
|
};
|
||||||
|
|
||||||
class GmpProtocol : public AbstractProtocol
|
class GmpProtocol : public AbstractProtocol
|
||||||
|
114
common/gmp.ui
114
common/gmp.ui
@ -6,7 +6,7 @@
|
|||||||
<x>0</x>
|
<x>0</x>
|
||||||
<y>0</y>
|
<y>0</y>
|
||||||
<width>586</width>
|
<width>586</width>
|
||||||
<height>321</height>
|
<height>281</height>
|
||||||
</rect>
|
</rect>
|
||||||
</property>
|
</property>
|
||||||
<property name="windowTitle" >
|
<property name="windowTitle" >
|
||||||
@ -171,6 +171,9 @@
|
|||||||
<verstretch>0</verstretch>
|
<verstretch>0</verstretch>
|
||||||
</sizepolicy>
|
</sizepolicy>
|
||||||
</property>
|
</property>
|
||||||
|
<property name="inputMask" >
|
||||||
|
<string>/900; </string>
|
||||||
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
</layout>
|
</layout>
|
||||||
@ -179,7 +182,7 @@
|
|||||||
<item>
|
<item>
|
||||||
<widget class="QStackedWidget" name="ssmWidget" >
|
<widget class="QStackedWidget" name="ssmWidget" >
|
||||||
<property name="currentIndex" >
|
<property name="currentIndex" >
|
||||||
<number>1</number>
|
<number>0</number>
|
||||||
</property>
|
</property>
|
||||||
<widget class="QWidget" name="page" >
|
<widget class="QWidget" name="page" >
|
||||||
<layout class="QHBoxLayout" >
|
<layout class="QHBoxLayout" >
|
||||||
@ -200,13 +203,13 @@
|
|||||||
<property name="title" >
|
<property name="title" >
|
||||||
<string/>
|
<string/>
|
||||||
</property>
|
</property>
|
||||||
|
<layout class="QHBoxLayout" >
|
||||||
|
<item>
|
||||||
<layout class="QGridLayout" >
|
<layout class="QGridLayout" >
|
||||||
<item row="0" column="0" >
|
<item row="0" column="0" colspan="3" >
|
||||||
<layout class="QGridLayout" >
|
|
||||||
<item row="0" column="0" >
|
|
||||||
<widget class="QCheckBox" name="sFlag" >
|
<widget class="QCheckBox" name="sFlag" >
|
||||||
<property name="text" >
|
<property name="text" >
|
||||||
<string>S Flag</string>
|
<string>S Flag (Suppress Router Processing)</string>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
@ -221,6 +224,9 @@
|
|||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="1" column="1" >
|
<item row="1" column="1" >
|
||||||
|
<widget class="QLineEdit" name="qrv" />
|
||||||
|
</item>
|
||||||
|
<item row="1" column="2" >
|
||||||
<spacer>
|
<spacer>
|
||||||
<property name="orientation" >
|
<property name="orientation" >
|
||||||
<enum>Qt::Horizontal</enum>
|
<enum>Qt::Horizontal</enum>
|
||||||
@ -233,9 +239,6 @@
|
|||||||
</property>
|
</property>
|
||||||
</spacer>
|
</spacer>
|
||||||
</item>
|
</item>
|
||||||
<item row="1" column="2" >
|
|
||||||
<widget class="QLineEdit" name="qrv" />
|
|
||||||
</item>
|
|
||||||
<item row="2" column="0" >
|
<item row="2" column="0" >
|
||||||
<widget class="QLabel" name="label_6" >
|
<widget class="QLabel" name="label_6" >
|
||||||
<property name="text" >
|
<property name="text" >
|
||||||
@ -246,14 +249,29 @@
|
|||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="2" column="2" >
|
<item row="2" column="1" >
|
||||||
<widget class="QLineEdit" name="qqi" />
|
<widget class="QLineEdit" name="qqi" />
|
||||||
</item>
|
</item>
|
||||||
|
<item row="3" column="1" >
|
||||||
|
<spacer>
|
||||||
|
<property name="orientation" >
|
||||||
|
<enum>Qt::Vertical</enum>
|
||||||
|
</property>
|
||||||
|
<property name="sizeHint" >
|
||||||
|
<size>
|
||||||
|
<width>61</width>
|
||||||
|
<height>41</height>
|
||||||
|
</size>
|
||||||
|
</property>
|
||||||
|
</spacer>
|
||||||
|
</item>
|
||||||
</layout>
|
</layout>
|
||||||
</item>
|
</item>
|
||||||
<item rowspan="2" row="0" column="1" >
|
<item>
|
||||||
<layout class="QGridLayout" >
|
<layout class="QVBoxLayout" >
|
||||||
<item row="0" column="0" >
|
<item>
|
||||||
|
<layout class="QHBoxLayout" >
|
||||||
|
<item>
|
||||||
<widget class="QLabel" name="label_13" >
|
<widget class="QLabel" name="label_13" >
|
||||||
<property name="text" >
|
<property name="text" >
|
||||||
<string>Source List</string>
|
<string>Source List</string>
|
||||||
@ -263,7 +281,48 @@
|
|||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="0" column="1" >
|
<item>
|
||||||
|
<spacer>
|
||||||
|
<property name="orientation" >
|
||||||
|
<enum>Qt::Horizontal</enum>
|
||||||
|
</property>
|
||||||
|
<property name="sizeHint" >
|
||||||
|
<size>
|
||||||
|
<width>16</width>
|
||||||
|
<height>20</height>
|
||||||
|
</size>
|
||||||
|
</property>
|
||||||
|
</spacer>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QToolButton" name="addSource" >
|
||||||
|
<property name="text" >
|
||||||
|
<string>A</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QToolButton" name="deleteSource" >
|
||||||
|
<property name="text" >
|
||||||
|
<string>D</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QListWidget" name="sourceList" >
|
||||||
|
<property name="dragEnabled" >
|
||||||
|
<bool>true</bool>
|
||||||
|
</property>
|
||||||
|
<property name="dragDropMode" >
|
||||||
|
<enum>QAbstractItemView::InternalMove</enum>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<layout class="QHBoxLayout" >
|
||||||
|
<item>
|
||||||
<spacer>
|
<spacer>
|
||||||
<property name="orientation" >
|
<property name="orientation" >
|
||||||
<enum>Qt::Horizontal</enum>
|
<enum>Qt::Horizontal</enum>
|
||||||
@ -276,43 +335,23 @@
|
|||||||
</property>
|
</property>
|
||||||
</spacer>
|
</spacer>
|
||||||
</item>
|
</item>
|
||||||
<item row="0" column="2" >
|
<item>
|
||||||
<widget class="QCheckBox" name="overrideSourceCount" >
|
<widget class="QCheckBox" name="overrideSourceCount" >
|
||||||
<property name="text" >
|
<property name="text" >
|
||||||
<string>Count</string>
|
<string>Count</string>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="0" column="3" >
|
<item>
|
||||||
<widget class="QLineEdit" name="sourceCount" >
|
<widget class="QLineEdit" name="sourceCount" >
|
||||||
<property name="enabled" >
|
<property name="enabled" >
|
||||||
<bool>false</bool>
|
<bool>false</bool>
|
||||||
</property>
|
</property>
|
||||||
<property name="sizePolicy" >
|
|
||||||
<sizepolicy vsizetype="Fixed" hsizetype="Fixed" >
|
|
||||||
<horstretch>0</horstretch>
|
|
||||||
<verstretch>0</verstretch>
|
|
||||||
</sizepolicy>
|
|
||||||
</property>
|
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="1" column="0" colspan="4" >
|
|
||||||
<widget class="QTextEdit" name="sourceList" />
|
|
||||||
</item>
|
|
||||||
</layout>
|
</layout>
|
||||||
</item>
|
</item>
|
||||||
<item row="1" column="0" >
|
</layout>
|
||||||
<spacer>
|
|
||||||
<property name="orientation" >
|
|
||||||
<enum>Qt::Vertical</enum>
|
|
||||||
</property>
|
|
||||||
<property name="sizeHint" >
|
|
||||||
<size>
|
|
||||||
<width>61</width>
|
|
||||||
<height>81</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
</spacer>
|
|
||||||
</item>
|
</item>
|
||||||
</layout>
|
</layout>
|
||||||
</widget>
|
</widget>
|
||||||
@ -587,7 +626,6 @@
|
|||||||
<tabstop>qqi</tabstop>
|
<tabstop>qqi</tabstop>
|
||||||
<tabstop>overrideSourceCount</tabstop>
|
<tabstop>overrideSourceCount</tabstop>
|
||||||
<tabstop>sourceCount</tabstop>
|
<tabstop>sourceCount</tabstop>
|
||||||
<tabstop>sourceList</tabstop>
|
|
||||||
</tabstops>
|
</tabstops>
|
||||||
<resources/>
|
<resources/>
|
||||||
<connections>
|
<connections>
|
||||||
|
Loading…
Reference in New Issue
Block a user