mirror of
https://github.com/fwbuilder/fwbuilder
synced 2026-09-11 07:31:25 +02:00
bugfix 2641,2656
This commit is contained in:
@@ -83,7 +83,23 @@ void RuleOptionsDialog::loadFWObject(FWObject *o)
|
||||
|
||||
Rule *rule = dynamic_cast<Rule*>(o);
|
||||
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 ")
|
||||
.arg(QString::fromUtf8(p->getName().c_str()))
|
||||
.arg(rule->getTypeName().c_str())
|
||||
|
||||
@@ -1592,7 +1592,7 @@ void RuleSetView::paintCell(QPainter *pntr,
|
||||
p.setPen( cg.highlightedText().color() );
|
||||
} else
|
||||
{
|
||||
p.fillRect(rect, cg.brush( QPalette::Base ));//cg.brush( crole ));
|
||||
p.fillRect(rect, cg.brush( QPalette::Mid ));//cg.brush( crole ));
|
||||
p.setPen( cg.text().color() );
|
||||
}
|
||||
} else
|
||||
|
||||
@@ -39,9 +39,76 @@
|
||||
<property name="minimumSize" >
|
||||
<size>
|
||||
<width>16</width>
|
||||
<height>20</height>
|
||||
<height>35</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="palette" >
|
||||
<palette>
|
||||
<active>
|
||||
<colorrole role="Base" >
|
||||
<brush brushstyle="SolidPattern" >
|
||||
<color alpha="255" >
|
||||
<red>255</red>
|
||||
<green>255</green>
|
||||
<blue>255</blue>
|
||||
</color>
|
||||
</brush>
|
||||
</colorrole>
|
||||
<colorrole role="Window" >
|
||||
<brush brushstyle="SolidPattern" >
|
||||
<color alpha="255" >
|
||||
<red>255</red>
|
||||
<green>254</green>
|
||||
<blue>253</blue>
|
||||
</color>
|
||||
</brush>
|
||||
</colorrole>
|
||||
</active>
|
||||
<inactive>
|
||||
<colorrole role="Base" >
|
||||
<brush brushstyle="SolidPattern" >
|
||||
<color alpha="255" >
|
||||
<red>255</red>
|
||||
<green>255</green>
|
||||
<blue>255</blue>
|
||||
</color>
|
||||
</brush>
|
||||
</colorrole>
|
||||
<colorrole role="Window" >
|
||||
<brush brushstyle="SolidPattern" >
|
||||
<color alpha="255" >
|
||||
<red>255</red>
|
||||
<green>254</green>
|
||||
<blue>253</blue>
|
||||
</color>
|
||||
</brush>
|
||||
</colorrole>
|
||||
</inactive>
|
||||
<disabled>
|
||||
<colorrole role="Base" >
|
||||
<brush brushstyle="SolidPattern" >
|
||||
<color alpha="255" >
|
||||
<red>255</red>
|
||||
<green>254</green>
|
||||
<blue>253</blue>
|
||||
</color>
|
||||
</brush>
|
||||
</colorrole>
|
||||
<colorrole role="Window" >
|
||||
<brush brushstyle="SolidPattern" >
|
||||
<color alpha="255" >
|
||||
<red>255</red>
|
||||
<green>254</green>
|
||||
<blue>253</blue>
|
||||
</color>
|
||||
</brush>
|
||||
</colorrole>
|
||||
</disabled>
|
||||
</palette>
|
||||
</property>
|
||||
<property name="autoFillBackground" >
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<property name="frameShape" >
|
||||
<enum>QFrame::Box</enum>
|
||||
</property>
|
||||
@@ -67,7 +134,7 @@
|
||||
<property name="verticalSpacing" >
|
||||
<number>2</number>
|
||||
</property>
|
||||
<item row="0" column="0" >
|
||||
<item row="0" column="1" >
|
||||
<widget class="QLabel" name="editorTitle" >
|
||||
<property name="font" >
|
||||
<font>
|
||||
@@ -83,6 +150,22 @@
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="0" column="0" >
|
||||
<widget class="QLabel" name="icon" >
|
||||
<property name="sizePolicy" >
|
||||
<sizepolicy vsizetype="Preferred" hsizetype="Maximum" >
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="text" >
|
||||
<string/>
|
||||
</property>
|
||||
<property name="pixmap" >
|
||||
<pixmap resource="MainRes.qrc" >:/Icons/Log</pixmap>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</item>
|
||||
@@ -2342,7 +2425,9 @@
|
||||
<tabstop>ipfw_stateless</tabstop>
|
||||
<tabstop>pf_logPrefix</tabstop>
|
||||
</tabstops>
|
||||
<resources/>
|
||||
<resources>
|
||||
<include location="MainRes.qrc" />
|
||||
</resources>
|
||||
<connections>
|
||||
<connection>
|
||||
<sender>pf_max_src_states</sender>
|
||||
|
||||
Reference in New Issue
Block a user