diff options
author | Friedemann Kleint <Friedemann.Kleint@nokia.com> | 2010-09-23 11:36:50 (GMT) |
---|---|---|
committer | Friedemann Kleint <Friedemann.Kleint@nokia.com> | 2010-09-23 11:36:50 (GMT) |
commit | 0402309e1e3fc30e9d7f643e135aa9af26cca99b (patch) | |
tree | be1db60caa5864ebd9a9d765128c2f9107c2a715 /tools/designer/src/components | |
parent | 82b4fff07dc21382274bc92e480a9eff897dabf1 (diff) | |
download | Qt-0402309e1e3fc30e9d7f643e135aa9af26cca99b.zip Qt-0402309e1e3fc30e9d7f643e135aa9af26cca99b.tar.gz Qt-0402309e1e3fc30e9d7f643e135aa9af26cca99b.tar.bz2 |
Designer/QFormBuilder::save(): Fix traversal of QGridLayout/QFormLayout
Remove redundant code in qdesigner_resource ass well.
Reviewed-by: Jarek Kobus <jaroslaw.kobus@nokia.com>
Task-number: QTBUG-13683
Diffstat (limited to 'tools/designer/src/components')
-rw-r--r-- | tools/designer/src/components/formeditor/qdesigner_resource.cpp | 28 |
1 files changed, 0 insertions, 28 deletions
diff --git a/tools/designer/src/components/formeditor/qdesigner_resource.cpp b/tools/designer/src/components/formeditor/qdesigner_resource.cpp index a29bc1f..7fabf68 100644 --- a/tools/designer/src/components/formeditor/qdesigner_resource.cpp +++ b/tools/designer/src/components/formeditor/qdesigner_resource.cpp @@ -1381,34 +1381,6 @@ DomLayoutItem *QDesignerResource::createDom(QLayoutItem *item, DomLayout *ui_lay } else { return 0; } - - if (m_chain.size() && item->widget()) { - if (QGridLayout *grid = qobject_cast<QGridLayout*>(m_chain.top())) { - const int index = Utils::indexOfWidget(grid, item->widget()); - - int row, column, rowspan, colspan; - grid->getItemPosition(index, &row, &column, &rowspan, &colspan); - ui_item->setAttributeRow(row); - ui_item->setAttributeColumn(column); - - if (colspan != 1) - ui_item->setAttributeColSpan(colspan); - - if (rowspan != 1) - ui_item->setAttributeRowSpan(rowspan); - } else { - if (QFormLayout *form = qobject_cast<QFormLayout*>(m_chain.top())) { - const int index = Utils::indexOfWidget(form, item->widget()); - int row, column, colspan; - getFormLayoutItemPosition(form, index, &row, &column, 0, &colspan); - ui_item->setAttributeRow(row); - ui_item->setAttributeColumn(column); - if (colspan != 1) - ui_item->setAttributeColSpan(colspan); - } - } - } - return ui_item; } |