Code style.
This commit is contained in:
parent
421a8df4be
commit
679bb9af48
|
@ -328,7 +328,7 @@ void VWidgetGroups::FillTable(QMap<quint32, VGroupData> groups)
|
||||||
++currentRow;
|
++currentRow;
|
||||||
const VGroupData data = i.value();
|
const VGroupData data = i.value();
|
||||||
|
|
||||||
QTableWidgetItem *item = new QTableWidgetItem();
|
auto *item = new QTableWidgetItem();
|
||||||
item->setTextAlignment(Qt::AlignHCenter);
|
item->setTextAlignment(Qt::AlignHCenter);
|
||||||
(data.visible) ? item->setIcon(QIcon("://icon/16x16/open_eye.png"))
|
(data.visible) ? item->setIcon(QIcon("://icon/16x16/open_eye.png"))
|
||||||
: item->setIcon(QIcon("://icon/16x16/closed_eye.png"));
|
: item->setIcon(QIcon("://icon/16x16/closed_eye.png"));
|
||||||
|
|
|
@ -474,19 +474,20 @@ int VAbstractPattern::CountPP() const
|
||||||
//---------------------------------------------------------------------------------------------------------------------
|
//---------------------------------------------------------------------------------------------------------------------
|
||||||
QDomElement VAbstractPattern::GetPPElement(const QString &name)
|
QDomElement VAbstractPattern::GetPPElement(const QString &name)
|
||||||
{
|
{
|
||||||
if (name.isEmpty() == false)
|
if (not name.isEmpty())
|
||||||
{
|
{
|
||||||
const QDomNodeList elements = this->documentElement().elementsByTagName( TagDraw );
|
const QDomNodeList elements = this->documentElement().elementsByTagName( TagDraw );
|
||||||
if (elements.size() == 0)
|
if (elements.size() == 0)
|
||||||
{
|
{
|
||||||
return QDomElement();
|
return QDomElement();
|
||||||
}
|
}
|
||||||
|
|
||||||
for ( qint32 i = 0; i < elements.count(); i++ )
|
for ( qint32 i = 0; i < elements.count(); i++ )
|
||||||
{
|
{
|
||||||
QDomElement element = elements.at( i ).toElement();
|
QDomElement element = elements.at(i).toElement();
|
||||||
if (element.isNull() == false)
|
if (not element.isNull())
|
||||||
{
|
{
|
||||||
if ( element.attribute( AttrName ) == name )
|
if (element.attribute(AttrName) == name)
|
||||||
{
|
{
|
||||||
return element;
|
return element;
|
||||||
}
|
}
|
||||||
|
|
|
@ -42,7 +42,7 @@ AddToCalc::AddToCalc(const QDomElement &xml, VAbstractPattern *doc, QUndoCommand
|
||||||
: VUndoCommand(xml, doc, parent), nameActivDraw(doc->GetNameActivPP()), cursor(doc->getCursor())
|
: VUndoCommand(xml, doc, parent), nameActivDraw(doc->GetNameActivPP()), cursor(doc->getCursor())
|
||||||
{
|
{
|
||||||
setText(tr("add object"));
|
setText(tr("add object"));
|
||||||
nodeId = doc->GetParametrId(xml);
|
nodeId = VAbstractPattern::GetParametrId(xml);
|
||||||
}
|
}
|
||||||
|
|
||||||
//---------------------------------------------------------------------------------------------------------------------
|
//---------------------------------------------------------------------------------------------------------------------
|
||||||
|
|
Loading…
Reference in New Issue
Block a user