diff options
author | Olivier Goffart <ogoffart@trolltech.com> | 2009-05-18 14:31:07 (GMT) |
---|---|---|
committer | Olivier Goffart <ogoffart@trolltech.com> | 2009-05-18 14:31:07 (GMT) |
commit | f3988241faa59596c1702b31e7bec9538f33ee79 (patch) | |
tree | 39cc06b8455545cd1fd754c44838afcc3a0bdaac /tools | |
parent | 7e4d4474d10cb17047d95e3a4820388468c74507 (diff) | |
parent | 5c25207628fbcc94e92b129ac7660af14613ad85 (diff) | |
download | Qt-f3988241faa59596c1702b31e7bec9538f33ee79.zip Qt-f3988241faa59596c1702b31e7bec9538f33ee79.tar.gz Qt-f3988241faa59596c1702b31e7bec9538f33ee79.tar.bz2 |
Merge commit 'origin/4.5'
Conflicts:
src/corelib/kernel/qobject.cpp
src/corelib/kernel/qobject_p.h
src/network/access/qhttpnetworkconnection.cpp
Diffstat (limited to 'tools')
3 files changed, 10 insertions, 3 deletions
diff --git a/tools/designer/src/components/formeditor/formwindow_widgetstack.cpp b/tools/designer/src/components/formeditor/formwindow_widgetstack.cpp index 7270628..58127b0 100644 --- a/tools/designer/src/components/formeditor/formwindow_widgetstack.cpp +++ b/tools/designer/src/components/formeditor/formwindow_widgetstack.cpp @@ -57,16 +57,20 @@ using namespace qdesigner_internal; FormWindowWidgetStack::FormWindowWidgetStack(QObject *parent) : QObject(parent), m_formContainer(new QWidget), - m_formContainerLayout(new QVBoxLayout), + m_formContainerLayout(new QStackedLayout), m_layout(new QStackedLayout) { m_layout->setMargin(0); m_layout->setSpacing(0); m_layout->setStackingMode(QStackedLayout::StackAll); + // We choose a QStackedLayout as immediate layout for + // the form windows as it ignores the sizePolicy of + // its child (for example, Fixed would cause undesired side effects). m_formContainerLayout->setMargin(0); m_formContainer->setObjectName(QLatin1String("formContainer")); m_formContainer->setLayout(m_formContainerLayout); + m_formContainerLayout->setStackingMode(QStackedLayout::StackAll); // System settings might have different background colors, autofill them // (affects for example mainwindow status bars) m_formContainer->setAutoFillBackground(true); diff --git a/tools/designer/src/components/formeditor/formwindow_widgetstack.h b/tools/designer/src/components/formeditor/formwindow_widgetstack.h index 92323c5..f21c4f0 100644 --- a/tools/designer/src/components/formeditor/formwindow_widgetstack.h +++ b/tools/designer/src/components/formeditor/formwindow_widgetstack.h @@ -51,7 +51,6 @@ QT_BEGIN_NAMESPACE class QDesignerFormWindowToolInterface; class QStackedLayout; -class QVBoxLayout; class QWidget; namespace qdesigner_internal { @@ -92,7 +91,7 @@ protected: private: QList<QDesignerFormWindowToolInterface*> m_tools; QWidget *m_formContainer; - QVBoxLayout *m_formContainerLayout; + QStackedLayout *m_formContainerLayout; QStackedLayout *m_layout; }; diff --git a/tools/designer/src/lib/shared/qdesigner_propertycommand.cpp b/tools/designer/src/lib/shared/qdesigner_propertycommand.cpp index ff3b50b..94e8044 100644 --- a/tools/designer/src/lib/shared/qdesigner_propertycommand.cpp +++ b/tools/designer/src/lib/shared/qdesigner_propertycommand.cpp @@ -316,6 +316,10 @@ Qt::Alignment variantToAlignment(const QVariant & q) // find changed subproperties of a variant unsigned compareSubProperties(const QVariant & q1, const QVariant & q2, qdesigner_internal::SpecialProperty specialProperty) { + // Do not clobber new value in the comparison function in + // case someone sets a QString on a PropertySheetStringValue. + if (q1.type() != q2.type()) + return SubPropertyAll; switch (q1.type()) { case QVariant::Rect: return compareSubProperties(q1.toRect(), q2.toRect()); |