diff options
author | Friedemann Kleint <Friedemann.Kleint@nokia.com> | 2010-04-14 14:34:10 +0200 |
---|---|---|
committer | Friedemann Kleint <Friedemann.Kleint@nokia.com> | 2010-04-14 14:34:43 +0200 |
commit | def1b610da28021fd4caaf21246bfdde03cc4d4a (patch) | |
tree | b502a839f86c22df46e81ed84bbc83be2ba13874 /src/tools/qtcreatorwidgets/customwidgets.cpp | |
parent | f6121924642c872557432c9aea5b996953d6603b (diff) | |
download | qt-creator-def1b610da28021fd4caaf21246bfdde03cc4d4a.tar.gz |
WelcomeModeTreeWidget: Add to Designer widgets lib.
Diffstat (limited to 'src/tools/qtcreatorwidgets/customwidgets.cpp')
-rw-r--r-- | src/tools/qtcreatorwidgets/customwidgets.cpp | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/src/tools/qtcreatorwidgets/customwidgets.cpp b/src/tools/qtcreatorwidgets/customwidgets.cpp index 98e8d89488..b281348fdf 100644 --- a/src/tools/qtcreatorwidgets/customwidgets.cpp +++ b/src/tools/qtcreatorwidgets/customwidgets.cpp @@ -223,6 +223,27 @@ Wizard_CW::Wizard_CW(QObject *parent) : { } +WelcomePageWidget_CW::WelcomePageWidget_CW(QObject *parent) : + QObject(parent), + CustomWidget<Utils::WelcomeModeTreeWidget> + (QLatin1String("<utils/welcomemodetreewidget.h>"), + false, + QLatin1String(groupC), + QIcon(), + QLatin1String("Welcome page widget")) +{ +} + +QWidget *WelcomePageWidget_CW::createWidget(QWidget *parent) +{ + Utils::WelcomeModeTreeWidget *rc = new Utils::WelcomeModeTreeWidget(parent); + rc->slotAddNewsItem(QLatin1String("Breaking news"), + QLatin1String("Bla bla bla"), QLatin1String("qt.nokia.com")); + rc->slotAddNewsItem(QLatin1String("Yesterday's breaking news"), + QLatin1String("Blub blub blub"), QLatin1String("qt.nokia.com")); + return rc; +} + DetailsWidget_CW::DetailsWidget_CW(QObject *parent) : QObject(parent), CustomWidget<Utils::DetailsWidget> @@ -348,6 +369,7 @@ WidgetCollection::WidgetCollection(QObject *parent) : m_plugins.push_back(new StyledBar_CW(this)); m_plugins.push_back(new StyledSeparator_CW(this)); m_plugins.push_back(new Wizard_CW(this)); + m_plugins.push_back(new WelcomePageWidget_CW(this)); } QList<QDesignerCustomWidgetInterface*> WidgetCollection::customWidgets() const |