From 939af726dc0b5e07e7d941719dfadf2c9831f4e0 Mon Sep 17 00:00:00 2001 From: keshavbhatt Date: Mon, 5 Apr 2021 23:52:34 +0530 Subject: new about dialog --- src/about.cpp | 48 +++++++++++++ src/about.h | 22 ++++++ src/about.ui | 216 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 286 insertions(+) create mode 100644 src/about.cpp create mode 100644 src/about.h create mode 100644 src/about.ui (limited to 'src') diff --git a/src/about.cpp b/src/about.cpp new file mode 100644 index 0000000..c49e68b --- /dev/null +++ b/src/about.cpp @@ -0,0 +1,48 @@ +#include "about.h" +#include "ui_about.h" +#include +#include +#include +#include + +About::About(QWidget *parent) : + QWidget(parent), + ui(new Ui::About) +{ + ui->setupUi(this); + + ui->version->setText("Version: "+QApplication::applicationVersion()); + + connect(ui->donate,&QPushButton::clicked,[=](){ + QDesktopServices::openUrl(QUrl("https://paypal.me/keshavnrj/10")); + }); + + connect(ui->rate,&QPushButton::clicked,[=](){ + QDesktopServices::openUrl(QUrl("snap://whatsie")); + }); + connect(ui->more_apps,&QPushButton::clicked,[=](){ + QDesktopServices::openUrl(QUrl("https://snapcraft.io/search?q=keshavnrj")); + }); + connect(ui->source_code,&QPushButton::clicked,[=](){ + QDesktopServices::openUrl(QUrl("https://github.com/keshavbhatt/whatsie")); + }); + + setWindowTitle(QApplication::applicationName() +" | About"); + + ui->centerWidget->hide(); + + QGraphicsOpacityEffect *eff = new QGraphicsOpacityEffect(this); + ui->centerWidget->setGraphicsEffect(eff); + QPropertyAnimation *a = new QPropertyAnimation(eff,"opacity"); + a->setDuration(1000); + a->setStartValue(0); + a->setEndValue(1); + a->setEasingCurve(QEasingCurve::InCurve); + a->start(QPropertyAnimation::DeleteWhenStopped); + ui->centerWidget->show(); +} + +About::~About() +{ + delete ui; +} diff --git a/src/about.h b/src/about.h new file mode 100644 index 0000000..360749f --- /dev/null +++ b/src/about.h @@ -0,0 +1,22 @@ +#ifndef ABOUT_H +#define ABOUT_H + +#include + +namespace Ui { +class About; +} + +class About : public QWidget +{ + Q_OBJECT + +public: + explicit About(QWidget *parent = nullptr); + ~About(); + +private: + Ui::About *ui; +}; + +#endif // ABOUT_H diff --git a/src/about.ui b/src/about.ui new file mode 100644 index 0000000..0baa5a5 --- /dev/null +++ b/src/about.ui @@ -0,0 +1,216 @@ + + + About + + + + 0 + 0 + 509 + 267 + + + + Form + + + + 0 + + + 0 + + + 0 + + + 0 + + + + + + + + + + QLayout::SetDefaultConstraint + + + 12 + + + + + Qt::Vertical + + + + 20 + 40 + + + + + + + + + 0 + 0 + + + + + 100 + 100 + + + + + 100 + 100 + + + + + + + :/icons/app/icon-256.png + + + true + + + Qt::AlignCenter + + + + + + + Qt::Vertical + + + + 20 + 40 + + + + + + + + + + + + + 0 + 0 + + + + <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +<html><head><meta name="qrichtext" content="1" /><style type="text/css"> +p, li { white-space: pre-wrap; } +</style></head><body style=" font-family:'Ubuntu'; font-size:11pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:18pt;">WhatSie</span></p> +<p style=" margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">WhatsApp Web Client for Linux Desktop.</p></body></html> + + + true + + + true + + + + + + + + 0 + 0 + + + + - + + + + + + + <html><head/><body><p><span style=" font-weight:600;">Designed &amp; Developed by:</span> Keshav Bhatt </p><p><span style=" font-weight:600;">Developer Email address: </span>keshavnrj@gmail.com</p><p><span style=" font-weight:600;">Developer Website:</span> http://ktechpit.com</p></body></html> + + + + + + + + + + + QWidget#widget + { + background-image:url(:/icons/texture.png), linear-gradient(hsla(0,0%,32%,.99), hsla(0,0%,27%,.95)); + selection-background-color:#3d8ec9; + selection-color: black; background-clip: border; + border-image: none; outline: 0;} + + + + + + 0 + + + + + Donate + + + + + + + Rate in Store + + + + + + + Source Code + + + + + + + + + + + More Application by Developer + + + + + + + + + + + + + + + + + + -- cgit v1.2.3