QmlDesigner.designModeWidget: fix style of error tooltip

DocumentWarningWidget is now derived from Utils::FakeToolTip and follows
the Qt Creator styling.
This commit is contained in:
Thomas Hartmann
2010-12-16 12:59:05 +01:00
parent 61edaf7716
commit b32873d3e6
2 changed files with 4 additions and 4 deletions

View File

@@ -90,13 +90,12 @@ namespace QmlDesigner {
namespace Internal {
DocumentWarningWidget::DocumentWarningWidget(DesignModeWidget *parent) :
QFrame(parent),
Utils::FakeToolTip(parent),
m_errorMessage(new QLabel("Placeholder", this)),
m_goToError(new QLabel(this)),
m_designModeWidget(parent)
{
setFrameStyle(QFrame::Panel | QFrame::Raised);
setLineWidth(1);
setWindowFlags(Qt::Widget); //We only want the visual style from a ToolTip
setForegroundRole(QPalette::ToolTipText);
setBackgroundRole(QPalette::ToolTipBase);
setAutoFillBackground(true);

View File

@@ -32,6 +32,7 @@
#include <coreplugin/minisplitter.h>
#include <coreplugin/editormanager/ieditor.h>
#include <utils/faketooltip.h>
#include <texteditor/itexteditor.h>
#include <integrationcore.h>
@@ -78,7 +79,7 @@ class DesignMode;
class DocumentWidget;
class DesignModeWidget;
class DocumentWarningWidget : public QFrame
class DocumentWarningWidget : public Utils::FakeToolTip
{
Q_OBJECT
Q_DISABLE_COPY(DocumentWarningWidget)