From 421b45c5537692585342ea127793952eb5aae362 Mon Sep 17 00:00:00 2001 From: Chocobo1 Date: Mon, 29 Jun 2015 16:01:00 +0800 Subject: [PATCH] Add tooltips/legend for availability bar & progress bar --- src/gui/properties/downloadedpiecesbar.cpp | 2 ++ src/gui/properties/pieceavailabilitybar.cpp | 2 ++ 2 files changed, 4 insertions(+) diff --git a/src/gui/properties/downloadedpiecesbar.cpp b/src/gui/properties/downloadedpiecesbar.cpp index c4f6fac17..eb799662a 100644 --- a/src/gui/properties/downloadedpiecesbar.cpp +++ b/src/gui/properties/downloadedpiecesbar.cpp @@ -33,6 +33,8 @@ DownloadedPiecesBar::DownloadedPiecesBar(QWidget *parent): QWidget(parent) { + setToolTip(QString("%1\n%2\n%3").arg(tr("White: Missing pieces")).arg(tr("Green: Partial pieces")).arg(tr("Blue: Completed pieces"))); + m_bgColor = 0xffffff; m_borderColor = palette().color(QPalette::Dark).rgb(); m_pieceColor = 0x0000ff; diff --git a/src/gui/properties/pieceavailabilitybar.cpp b/src/gui/properties/pieceavailabilitybar.cpp index 0f2b17087..830810a02 100644 --- a/src/gui/properties/pieceavailabilitybar.cpp +++ b/src/gui/properties/pieceavailabilitybar.cpp @@ -36,6 +36,8 @@ PieceAvailabilityBar::PieceAvailabilityBar(QWidget *parent) : QWidget(parent) { + setToolTip(QString("%1\n%2").arg(tr("White: Unavailable pieces")).arg(tr("Blue: Available pieces"))); + m_bgColor = 0xffffff; m_borderColor = palette().color(QPalette::Dark).rgb(); m_pieceColor = 0x0000ff;