1
0
Fork 0
mirror of https://github.com/transmission/transmission synced 2024-12-26 09:37:56 +00:00
transmission/qt/license.cc

49 lines
1.6 KiB
C++
Raw Normal View History

2009-05-08 18:52:06 +00:00
/*
* This file Copyright (C) 2009-2014 Mnemosyne LLC
2009-05-08 18:52:06 +00:00
*
* It may be used under the GNU Public License v2 or v3 licenses,
* or any future license endorsed by Mnemosyne LLC.
2009-05-08 18:52:06 +00:00
*
* $Id$
2009-05-08 18:52:06 +00:00
*/
#include <QDialogButtonBox>
#include <QPlainTextEdit>
#include <QVBoxLayout>
#include "license.h"
LicenseDialog :: LicenseDialog (QWidget * parent):
QDialog (parent, Qt::Dialog)
2009-05-08 18:52:06 +00:00
{
setWindowTitle (tr ("License"));
resize (400, 300);
QVBoxLayout * v = new QVBoxLayout (this);
2009-05-08 18:52:06 +00:00
QPlainTextEdit * t = new QPlainTextEdit (this);
t->setReadOnly (true);
t->setPlainText (
"Copyright 2005-2014. All code is copyrighted by the respective authors.\n"
"\n"
"Transmission can be redistributed and/or modified under the terms of the "
"GNU GPL versions 2 or 3 or by any future license endorsed by Mnemosyne LLC.\n"
"\n"
"In addition, linking to and/or using OpenSSL is allowed.\n"
"\n"
"This program is distributed in the hope that it will be useful, "
"but WITHOUT ANY WARRANTY; without even the implied warranty of "
"MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.\n"
"\n"
"Some of Transmission's source files have more permissive licenses. "
"Those files may, of course, be used on their own under their own terms.\n");
v->addWidget (t);
2009-05-08 18:52:06 +00:00
QDialogButtonBox * box = new QDialogButtonBox;
box->setSizePolicy (QSizePolicy::Expanding, QSizePolicy::Fixed);
box->setOrientation (Qt::Horizontal);
box->setStandardButtons (QDialogButtonBox::Close);
v->addWidget (box);
2009-05-08 18:52:06 +00:00
connect (box, SIGNAL (rejected ()), this, SLOT (hide ()));
2009-05-08 18:52:06 +00:00
}