From 19ed899304622860f14e31f45e9cab83963295c7 Mon Sep 17 00:00:00 2001 From: trialuser02 Date: Thu, 10 Oct 2013 07:17:34 +0000 Subject: rgscan: added description, removed useless code git-svn-id: http://svn.code.sf.net/p/qmmp-dev/code/trunk/qmmp@3764 90c681e8-e032-0410-971d-27865f9a5e38 --- src/plugins/General/rgscan/rgscanfactory.cpp | 20 ++++++++++++-------- src/plugins/General/rgscan/rgscanhelper.cpp | 23 +++++------------------ src/plugins/General/rgscan/rgscanhelper.h | 9 --------- 3 files changed, 17 insertions(+), 35 deletions(-) (limited to 'src/plugins/General') diff --git a/src/plugins/General/rgscan/rgscanfactory.cpp b/src/plugins/General/rgscan/rgscanfactory.cpp index 8d1099818..f0d31ab53 100644 --- a/src/plugins/General/rgscan/rgscanfactory.cpp +++ b/src/plugins/General/rgscan/rgscanfactory.cpp @@ -25,8 +25,8 @@ const GeneralProperties RGScanFactory::properties() const { GeneralProperties properties; - properties.name = tr("ReplayGain Scaner"); - properties.shortName = "rgscaner"; + properties.name = tr("ReplayGain Scanner Plugin"); + properties.shortName = "rgscan"; properties.hasAbout = true; properties.hasSettings = false; properties.visibilityControl = false; @@ -46,11 +46,15 @@ QDialog *RGScanFactory::createConfigDialog(QWidget *parent) void RGScanFactory::showAbout(QWidget *parent) { - /*QMessageBox::about (parent, tr("About Converter Plugin"), - tr("Qmmp Converter Plugin")+"\n"+ - tr("This plugin converts supported audio files to other file formats " - "using external command-line encoders") +"\n"+ - tr("Written by: Ilya Kotov "));*/ + QMessageBox::about (parent, tr("About ReplayGain Scanner Plugin"), + tr("ReplayGain Scanner Plugin for Qmmp")+"\n"+ + tr("This plugin scans audio files and gives information for volume normalization") + "\n" + + tr("Written by: Ilya Kotov ") + "\n" + + tr("Based on source code by:") + "\n" + + tr("David Robinson ") + "\n" + + tr("Glen Sawyer ") + "\n" + + tr("Frank Klemm")); + } QTranslator *RGScanFactory::createTranslator(QObject *parent) @@ -61,4 +65,4 @@ QTranslator *RGScanFactory::createTranslator(QObject *parent) return translator; } -Q_EXPORT_PLUGIN2(rgscaner, RGScanFactory) +Q_EXPORT_PLUGIN2(rgscan, RGScanFactory) diff --git a/src/plugins/General/rgscan/rgscanhelper.cpp b/src/plugins/General/rgscan/rgscanhelper.cpp index 76da42dd4..c668390ca 100644 --- a/src/plugins/General/rgscan/rgscanhelper.cpp +++ b/src/plugins/General/rgscan/rgscanhelper.cpp @@ -19,8 +19,6 @@ ***************************************************************************/ #include -#include -#include #include #include #include @@ -32,25 +30,14 @@ RGScanHelper::RGScanHelper(QObject *parent) : QObject(parent) { - m_action = new QAction(tr("Calculate ReplayGain"), this); - m_action->setShortcut(tr("Meta+R")); - UiHelper::instance()->addAction(m_action, UiHelper::PLAYLIST_MENU); - connect (m_action, SIGNAL(triggered ()), SLOT(openRGScaner())); - //m_scaner = new RGScaner(this); - m_progress = new QProgressDialog(); - m_progress->setRange(0,100); - m_progress->setWindowTitle(tr("Scaning...")); - m_progress->setCancelButtonText(tr("Cancel")); - //connect(m_scaner,SIGNAL(progress(int)),m_progress,SLOT(setValue(int))); - //connect(m_scaner, SIGNAL(finished()), m_progress, SLOT(reset())); - //connect(m_scaner, SIGNAL(desriptionChanged(QString)), m_progress, SLOT(setLabelText(QString))); - //connect(m_progress, SIGNAL(canceled()), m_scaner, SLOT(stop())); + QAction *action = new QAction(tr("ReplayGain Scanner"), this); + action->setShortcut(tr("Meta+R")); + UiHelper::instance()->addAction(action, UiHelper::PLAYLIST_MENU); + connect (action, SIGNAL(triggered ()), SLOT(openRGScaner())); } RGScanHelper::~RGScanHelper() -{ - delete m_progress; -} +{} void RGScanHelper::openRGScaner() { diff --git a/src/plugins/General/rgscan/rgscanhelper.h b/src/plugins/General/rgscan/rgscanhelper.h index fe20c5b49..230bb95ec 100644 --- a/src/plugins/General/rgscan/rgscanhelper.h +++ b/src/plugins/General/rgscan/rgscanhelper.h @@ -20,13 +20,10 @@ #ifndef RGSCANHELPER_H #define RGSCANHELPER_H -#include - #include #include class QAction; -class QProgressDialog; class RGScaner; /** @@ -37,17 +34,11 @@ class RGScanHelper : public QObject Q_OBJECT public: RGScanHelper(QObject *parent = 0); - ~RGScanHelper(); private slots: void openRGScaner(); -private: - QAction *m_action; - //RGScaner *m_scaner; - QProgressDialog *m_progress; - }; #endif //RGSCANHELPER_H -- cgit v1.2.3-13-gbd6f