Small tweaks to the project page again, based on mae's feedback.

Feedback welcome, some of them are not necessarily better. Some things
aren't solved.
This commit is contained in:
dt
2009-09-29 18:06:13 +02:00
parent ce7b56f998
commit 3d62363fee
8 changed files with 169 additions and 73 deletions

View File

@@ -4,10 +4,11 @@ using namespace Utils;
DetailsButton::DetailsButton(QWidget *parent)
#ifdef Q_OS_MAC
: QPushButton(parent)
: QPushButton(parent),
#else
: QToolButton(parent)
: QToolButton(parent),
#endif
m_checked(false)
{
#ifdef Q_OS_MAC
setAttribute(Qt::WA_MacSmallSize);
@@ -15,5 +16,17 @@ DetailsButton::DetailsButton(QWidget *parent)
#else
setCheckable(true);
#endif
setText(tr("Details"));
setText(tr("Show Details"));
connect(this, SIGNAL(clicked()),
this, SLOT(onClicked()));
}
void DetailsButton::onClicked()
{
m_checked = !m_checked;
if (m_checked) {
setText(tr("Hide Details"));
} else {
setText(tr("Show Details"));
}
}