Commit 135000c3 authored by Friedemann Kleint's avatar Friedemann Kleint
Browse files

Made uic-codecompletion use the new quiet-save API of Qt Designer.

parent 51500897
...@@ -38,6 +38,8 @@ ...@@ -38,6 +38,8 @@
#include <projectexplorer/projectnodes.h> #include <projectexplorer/projectnodes.h>
#include <projectexplorer/nodesvisitor.h> #include <projectexplorer/nodesvisitor.h>
#include <utils/qtcassert.h>
#include <QtDesigner/QDesignerFormWindowInterface> #include <QtDesigner/QDesignerFormWindowInterface>
#include <QtDesigner/QDesignerFormEditorInterface> #include <QtDesigner/QDesignerFormEditorInterface>
#include <QtDesigner/QDesignerFormWindowManagerInterface> #include <QtDesigner/QDesignerFormWindowManagerInterface>
...@@ -359,7 +361,14 @@ QString FormWindowEditor::contextHelpId() const ...@@ -359,7 +361,14 @@ QString FormWindowEditor::contextHelpId() const
QString FormWindowEditor::contents() const QString FormWindowEditor::contents() const
{ {
if (m_host && m_host->formWindow()) if (!m_formWindow)
return m_host->formWindow()->contents(); return QString::null;
return QString::null; #if QT_VERSION > 0x040501
// Quiet save as of Qt 4.5.2
qdesigner_internal::FormWindowBase *fwb = qobject_cast<qdesigner_internal::FormWindowBase *>(m_formWindow);
QTC_ASSERT(fwb, return QString::null);
return fwb->fileContents();
#else
return m_formWindow->contents();
#endif
} }
...@@ -78,6 +78,9 @@ public: ...@@ -78,6 +78,9 @@ public:
QVariantMap formData(); QVariantMap formData();
void setFormData(const QVariantMap &vm); void setFormData(const QVariantMap &vm);
// Return contents without warnings. Should be 'contents(bool quiet)'
QString fileContents() const;
// Return the widget containing the form. This is used to // Return the widget containing the form. This is used to
// apply embedded design settings to that are inherited (for example font). // apply embedded design settings to that are inherited (for example font).
// These are meant to be applied to the form only and not to the other editors // These are meant to be applied to the form only and not to the other editors
......
...@@ -74,6 +74,7 @@ Q_SIGNALS: ...@@ -74,6 +74,7 @@ Q_SIGNALS:
public Q_SLOTS: public Q_SLOTS:
virtual void closeAllPreviews() = 0; virtual void closeAllPreviews() = 0;
void aboutPlugins();
private: private:
void *m_unused; void *m_unused;
......
...@@ -55,8 +55,8 @@ syncHeader() ...@@ -55,8 +55,8 @@ syncHeader()
TARGET=qt_private/$HDR TARGET=qt_private/$HDR
# Exchange license header # Exchange license header
head -n 32 formwindowfile.h > $TARGET || exit 1 head -n 28 formwindowfile.h > $TARGET || exit 1
tail -n +11 $QTHDR >> $TARGET || exit 1 tail -n +41 $QTHDR >> $TARGET || exit 1
} }
for H in $REQUIRED_HEADERS for H in $REQUIRED_HEADERS
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment