mirror of
https://github.com/fwbuilder/fwbuilder
synced 2026-09-11 15:41:41 +02:00
bugfix 2641,2656
This commit is contained in:
@@ -83,23 +83,6 @@ void RuleOptionsDialog::loadFWObject(FWObject *o)
|
|||||||
|
|
||||||
Rule *rule = dynamic_cast<Rule*>(o);
|
Rule *rule = dynamic_cast<Rule*>(o);
|
||||||
FWOptions *ropt = rule->getOptionsObject();
|
FWOptions *ropt = rule->getOptionsObject();
|
||||||
m_dialog->icon->setVisible(false);
|
|
||||||
PolicyRule *policyRule = PolicyRule::cast( rule );
|
|
||||||
NATRule *natRule = NATRule::cast( rule );
|
|
||||||
RoutingRule *routingRule = RoutingRule::cast( rule );
|
|
||||||
if (policyRule && policyRule->getLogging())
|
|
||||||
{
|
|
||||||
|
|
||||||
m_dialog->icon->setVisible(true);
|
|
||||||
m_dialog->icon->setPixmap (QIcon(":/Icons/Log").pixmap (25,25));
|
|
||||||
}
|
|
||||||
if ((policyRule && ! isDefaultPolicyRuleOptions( rule->getOptionsObject())) ||
|
|
||||||
(routingRule && ! isDefaultRoutingRuleOptions( rule->getOptionsObject())) ||
|
|
||||||
(natRule && ! isDefaultNATRuleOptions( rule->getOptionsObject())))
|
|
||||||
{
|
|
||||||
m_dialog->icon->setVisible(true);
|
|
||||||
m_dialog->icon->setPixmap (QIcon(":/Icons/Options").pixmap (25,25));
|
|
||||||
}
|
|
||||||
m_dialog->editorTitle->setText(QString("%1 / %2 / %3 ")
|
m_dialog->editorTitle->setText(QString("%1 / %2 / %3 ")
|
||||||
.arg(QString::fromUtf8(p->getName().c_str()))
|
.arg(QString::fromUtf8(p->getName().c_str()))
|
||||||
.arg(rule->getTypeName().c_str())
|
.arg(rule->getTypeName().c_str())
|
||||||
|
|||||||
@@ -2289,7 +2289,8 @@ void RuleSetView::mousePressEvent( QMouseEvent* ev )
|
|||||||
|
|
||||||
int row=rowAt(ev->y());
|
int row=rowAt(ev->y());
|
||||||
int col=columnAt(ev->x());
|
int col=columnAt(ev->x());
|
||||||
|
if (row==-1)
|
||||||
|
return ;
|
||||||
if (col==0)
|
if (col==0)
|
||||||
{
|
{
|
||||||
if (row<rowsInfo.size()&&row>=0)
|
if (row<rowsInfo.size()&&row>=0)
|
||||||
|
|||||||
@@ -117,16 +117,16 @@
|
|||||||
</property>
|
</property>
|
||||||
<layout class="QGridLayout" >
|
<layout class="QGridLayout" >
|
||||||
<property name="leftMargin" >
|
<property name="leftMargin" >
|
||||||
<number>0</number>
|
<number>2</number>
|
||||||
</property>
|
</property>
|
||||||
<property name="topMargin" >
|
<property name="topMargin" >
|
||||||
<number>0</number>
|
<number>2</number>
|
||||||
</property>
|
</property>
|
||||||
<property name="rightMargin" >
|
<property name="rightMargin" >
|
||||||
<number>0</number>
|
<number>2</number>
|
||||||
</property>
|
</property>
|
||||||
<property name="bottomMargin" >
|
<property name="bottomMargin" >
|
||||||
<number>0</number>
|
<number>2</number>
|
||||||
</property>
|
</property>
|
||||||
<property name="horizontalSpacing" >
|
<property name="horizontalSpacing" >
|
||||||
<number>2</number>
|
<number>2</number>
|
||||||
@@ -162,7 +162,7 @@
|
|||||||
<string/>
|
<string/>
|
||||||
</property>
|
</property>
|
||||||
<property name="pixmap" >
|
<property name="pixmap" >
|
||||||
<pixmap resource="MainRes.qrc" >:/Icons/Log</pixmap>
|
<pixmap resource="MainRes.qrc" >:/Icons/Options</pixmap>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
|
|||||||
Reference in New Issue
Block a user