diff options
| author | trialuser02 <trialuser02@90c681e8-e032-0410-971d-27865f9a5e38> | 2010-09-18 16:50:38 +0000 |
|---|---|---|
| committer | trialuser02 <trialuser02@90c681e8-e032-0410-971d-27865f9a5e38> | 2010-09-18 16:50:38 +0000 |
| commit | 5717444b38b4f45ad185bbc6ea81cdb141befb8c (patch) | |
| tree | 9ab1fdb4070f7dab49ce5da8b8cf07b79c508eb4 /src/plugins/CommandLineOptions/SeekOption/seekoption.cpp | |
| parent | 42aa3971c31736f04f668f84884c05f4dad793bd (diff) | |
| download | qmmp-5717444b38b4f45ad185bbc6ea81cdb141befb8c.tar.gz qmmp-5717444b38b4f45ad185bbc6ea81cdb141befb8c.tar.bz2 qmmp-5717444b38b4f45ad185bbc6ea81cdb141befb8c.zip | |
added --status and --nowplaying command line option (Closes issue 266)
git-svn-id: http://svn.code.sf.net/p/qmmp-dev/code/trunk/qmmp@1893 90c681e8-e032-0410-971d-27865f9a5e38
Diffstat (limited to 'src/plugins/CommandLineOptions/SeekOption/seekoption.cpp')
| -rw-r--r-- | src/plugins/CommandLineOptions/SeekOption/seekoption.cpp | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/src/plugins/CommandLineOptions/SeekOption/seekoption.cpp b/src/plugins/CommandLineOptions/SeekOption/seekoption.cpp index 444bc73be..e8dbacd30 100644 --- a/src/plugins/CommandLineOptions/SeekOption/seekoption.cpp +++ b/src/plugins/CommandLineOptions/SeekOption/seekoption.cpp @@ -41,13 +41,13 @@ const QString SeekOption::helpString() const return help; } -void SeekOption::executeCommand(const QString &opt_str, const QStringList &args) +QString SeekOption::executeCommand(const QString &opt_str, const QStringList &args) { SoundCore *core = SoundCore::instance(); if(core->state() != Qmmp::Playing && core->totalTime()) - return; + return QString(); if(args.isEmpty()) - return; + return QString(); int seek_pos = -1; int elapsed = core->elapsed()/1000; @@ -71,6 +71,9 @@ void SeekOption::executeCommand(const QString &opt_str, const QStringList &args) if(seek_pos >= 0 && seek_pos < core->totalTime()) core->seek(seek_pos * 1000); + else + return QString(); + return QString(); } const QString SeekOption::name() const |
