[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: extragear/multimedia/amarok/src/scriptengine
From: Leo Franchi <lfranchi () kde ! org>
Date: 2009-05-04 8:35:50
Message-ID: 1241426150.496287.23235.nullmailer () svn ! kde ! org
[Download RAW message or body]
SVN commit 963223 by lfranchi:
add track.url() function to the scripting API, so scripts can properly
use the setLyricsForTrack function which already exists (although it
doesn't work yet)
M +7 -0 MetaTypeExporter.cpp
M +2 -0 MetaTypeExporter.h
--- trunk/extragear/multimedia/amarok/src/scriptengine/MetaTypeExporter.cpp #963222:963223
@@ -186,6 +186,13 @@
return ( track && track->album() ) ? track->album()->imageLocation().prettyUrl() : QString();
}
+QString
+MetaTrackPrototype::url() const
+{
+ GET_TRACK
+ return track ? track->playableUrl().url() : QString();
+}
+
QScriptValue
MetaTrackPrototype::imagePixmap( int size ) const
{
--- trunk/extragear/multimedia/amarok/src/scriptengine/MetaTypeExporter.h #963222:963223
@@ -52,6 +52,7 @@
Q_PROPERTY( bool isEditable READ isEditable )
Q_PROPERTY( QString lyrics WRITE setLyrics READ lyrics )
Q_PROPERTY( QString imageUrl WRITE setImageUrl READ imageUrl )
+ Q_PROPERTY( QString url READ url )
public:
MetaTrackPrototype();
@@ -85,6 +86,7 @@
QString lyrics() const;
QString title() const;
QString imageUrl() const;
+ QString url() const;
void setScore( double score );
void setRating( int rating );
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic