From b2e54fc7cee9945f05c4e25ee65f26c196eed094 Mon Sep 17 00:00:00 2001 From: Flavio Date: Wed, 15 Dec 2010 23:55:48 +0100 Subject: [PATCH] Demo stuff --- src/MediaView.cpp | 1 + src/SearchView.cpp | 20 ++++++++++++++++++++ 2 files changed, 21 insertions(+) diff --git a/src/MediaView.cpp b/src/MediaView.cpp index 8890ace..116c148 100644 --- a/src/MediaView.cpp +++ b/src/MediaView.cpp @@ -578,6 +578,7 @@ void MediaView::demoMessage() { QDesktopServices::openUrl(QString(Constants::WEBSITE) + "#download"); } else { mediaObject->play(); + demoTimer->start(); } } #endif diff --git a/src/SearchView.cpp b/src/SearchView.cpp index 76f7da4..eda7d87 100644 --- a/src/SearchView.cpp +++ b/src/SearchView.cpp @@ -29,6 +29,26 @@ SearchView::SearchView(QWidget *parent) : QWidget(parent) { message->hide(); mainLayout->addWidget(message); +#ifdef APP_DEMO + QLabel *buy = new QLabel(this); + buy->setSizePolicy(QSizePolicy::Maximum, QSizePolicy::Preferred); + buy->setText(QString("%2").arg( + QString(Constants::WEBSITE) + "#download", + tr("Get the full version").toUpper() + )); + buy->setOpenExternalLinks(true); + buy->setMargin(7); + buy->setAlignment(Qt::AlignRight); + buy->setStyleSheet("QLabel {" + "background-color: qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1, stop: 0 #CCD6E0, stop: 1 #ADBCCC);" + "border-bottom-left-radius: 8px;" + "border-bottom-right-radius: 8px;" + "font-size: 10px;" + "margin-right: 50px;" + "}"); + mainLayout->addWidget(buy, 0, Qt::AlignRight); +#endif + mainLayout->addStretch(); mainLayout->addSpacing(PADDING); -- 2.39.5