]> git.sur5r.net Git - minitube/commitdiff
Demo stuff
authorFlavio <flavio@odisseo.local>
Wed, 15 Dec 2010 22:55:48 +0000 (23:55 +0100)
committerFlavio <flavio@odisseo.local>
Wed, 15 Dec 2010 22:55:48 +0000 (23:55 +0100)
src/MediaView.cpp
src/SearchView.cpp

index 8890acebddf2abeee5818edca4debedc2999cd14..116c148f25f5c6dc373cc8ed9c55395381ff91c0 100644 (file)
@@ -578,6 +578,7 @@ void MediaView::demoMessage() {
         QDesktopServices::openUrl(QString(Constants::WEBSITE) + "#download");
     } else {
         mediaObject->play();
+        demoTimer->start();
     }
 }
 #endif
index 76f7da4abe9980b65789db1f3b7c1b6bda2e717f..eda7d87805b5a6ad35494a9199883bf5e0eaca57 100644 (file)
@@ -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("<a style='color:palette(text);text-decoration:none' href='%1'>%2</a>").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);