Commit Graph

79 Commits

Author SHA1 Message Date
John Maguire 3323c2d094 Convert all instances of foreach() to a C++11 for
find ext src -name '*.cpp' -exec \
    sed -i -e 's/foreach(\([^,]\+\),/for (\1 :/' {} \;
2014-02-10 14:43:32 +01:00
John Maguire bebd781fdf Reformat all non-3rd-party C/C++/Objective-C++.
Command line:
find src ext -regex '.*\.\(h\|cpp\|mm\)' -exec clang-format -i
 -style='{BasedOnStyle: Google, DerivePointerBinding: false}' {} \;
2014-02-07 16:34:20 +01:00
John Maguire 71893e4847 Use nullptr instead of NULL everywhere. 2014-02-06 17:29:59 +01:00
John Maguire d309d4ab27 Use c++11 instead of boost where possible. 2014-02-06 16:51:39 +01:00
David Sansome f816a47ad9 Make SongLoader add URLs as raw streams if there exists a URL handler
for that scheme.  This fixes a bug where sky:// URLs couldn't be added
with MPRIS.
2014-01-24 23:54:38 +11:00
David Sansome 115964d1b4 Load local tags asynchronously in SongLoader. 2013-02-17 18:19:05 +11:00
David Sansome 4acafb4930 Remove some old code 2013-02-17 18:10:08 +11:00
John Maguire 90803fa0e0 Remove use of deprecated gstreamer functions. 2013-01-29 13:19:26 +01:00
David Sansome 41f89904b6 Compare against the translated message text to determine whether a typefind failed. Fixes radio playlists in non-english languages. Fixes issue 3394 2013-01-04 21:16:26 +11:00
John Maguire fddce90624 Use boost::bind & boost::function instead of std equivalents for better compatibility. 2012-11-21 17:17:37 +01:00
John Maguire 1fd0515168 Make variadic version of ConcurrentRun::Run() 2012-11-21 16:39:10 +01:00
Arnaud Bienner 0e3dc5a8be Add new ConcurrentRun templates for void functions, and functions with 3 arguments + corresponding test cases.
+ SongLoader now has its own QThreadPool to load folders/playlist in background.
Update issue 2598
This should fix slowliness problems reported.
2012-07-16 00:06:55 +02:00
Arnaud Bienner 7f89e8832e When loading songs aync, always load the first song of our list, as it may be played immediately once added to the playlist
Fixes issue 2598
2012-07-14 00:53:42 +02:00
John Maguire cbc650f44b Use CHECKED_GCONNECT instead of g_signal_connect everywhere. 2012-06-08 15:34:00 +02:00
John Maguire e9ace3a2cb Support loading a spotify URL from the command line. 2012-03-22 16:55:05 -07:00
David Sansome 2750877a72 Support iTunes and Zune podcast URL schemes through SongLoader 2012-03-11 18:14:53 +00:00
David Sansome f16fc8867e Allow podcasts to be added through the normal SongLoader mechanism (dragging to the playlist, on the commandline, "Add Stream", etc.) 2012-03-11 17:57:15 +00:00
David Sansome c27b8a5e95 Fix some broken behaviour in SongLoader when loading a playlist that was bigger than one GstBuffer. The pipeline would be stopped early because it was still asynchronously moving to the PLAYING state. 2012-03-11 17:20:12 +00:00
David Sansome 4618651cf4 Merge branch 'master' into external-tagreader 2012-01-07 22:52:18 +00:00
David Sansome e9c0b4bd69 Musicbrainz tagging improvements:
* Fix a bug where the song title would be used for the album field
  * Get the album's year as well
  * Include all releases for a song in the results list
  * Remove duplicate albums
  * Sort results
2012-01-07 21:51:02 +00:00
David Sansome 9be641ee87 The external tagreader mostly works now:
* Make TagReaderClient a singleton until it's easier to pass dependencies around
 * Add a WaitForSignal() that uses a local event loop to wait for a signal to be emitted
 * Add a WaitForFinished() to _MessageReplyBase that blocks using a semaphore
 * Add blocking versions of all TagReaderClient methods
 * Use the TagReaderClient everywhere that Song::InitFromFile and friends were used before
2012-01-07 00:26:07 +00:00
David Sansome b873209d39 Remove the <xiphcomment.h> include from song.h so that windows headers don't infect everything else. Also move other bits of song.h into song.cpp, and reduce the number of includes in song.h. 2011-11-28 13:56:55 +00:00
Arnaud Bienner fdad2bd706 Make the async load of folders thread-safe 2011-11-18 21:55:54 +01:00
John Maguire 8e4ec35c61 Fix playlist detection when playlist size is < 512 bytes.
Fixes issue #2319
2011-11-10 21:42:40 +01:00
David Sansome 5884502389 Fix a bug loading where song metadata wouldn't be loaded from the library when loading a local file containing spaces. Fixes issue 2192 2011-08-27 22:51:30 +01:00
David Sansome 7e0e4e48e4 When loading a CUE from disk that isn't in the library, don't overwrite the metadata of its first song with the metadata from the audio file. Fixes issue 2092 2011-08-27 22:29:35 +01:00
Arnaud Bienner 5cbb86f247 Use toEncoded instead of toString in SQL query 2011-08-19 22:37:59 +02:00
Arnaud Bienner f319a615d9 Use url when checking if a file is already in DB instead of filename when loading files (this usecase has been missed when we have decide to use urls everywhere) 2011-08-18 22:43:52 +02:00
David Sansome 082716e9c9 Don't try to compile audio CD support if libcdio isn't installed. 2011-08-10 16:30:36 +01:00
Tyler Rhodes ded8e5f6f0 Refactor "Radio" files into "Internet" files. 2011-07-15 13:27:50 +00:00
David Sansome 7415d85dce When initialising a song from a library query, don't always assume the metadata originally came from a file (which means icycast tags are ignored when it is played). Fixes issue 1857 2011-06-17 20:00:10 +00:00
John Maguire 25587286b2 Fix error when unref'ing cdda element after failing to read CD. 2011-06-15 19:28:25 +00:00
Arnaud Bienner 7fca5d37dc Minor modifications on load audio CD, including better cleaning of objects 2011-06-14 23:38:43 +00:00
Tyler Rhodes 80abba66ca Fix my compile fix in r3373 2011-06-10 09:37:50 +00:00
John Maguire 4917ae8f4f Fix compile error. 2011-06-10 09:35:03 +00:00
Tyler Rhodes 006e085b7d Fixes 64-bit compile issue from r3372 2011-06-10 09:19:30 +00:00
Arnaud Bienner 272841ab73 Starting audio CD support. Starts issue 701 2011-06-09 23:08:43 +00:00
David Sansome ccb9f8cf94 Use URLs everywhere instead of filenames. Move the URL parsing and song loading code out of individual playlist parsers and into the base class. Fix the playlist parser unit tests. 2011-04-28 12:27:53 +00:00
David Sansome 3eedc916ad Add a new logging system 2011-04-22 16:50:29 +00:00
Arnaud Bienner 65ef047c38 Loading file in async way, in two times: fast loading files and insert them in playlist view, while loading info (tags, ...) in background thread 2011-04-16 14:04:15 +00:00
David Sansome 4471e27ef6 Python docs for PlaylistParser, and clean up the interface a bit 2011-02-27 12:14:32 +00:00
Paweł Bara ed4b7abde0 changed my mind - reverting my playlist changes to previous status quo (just making the PlaylistParser's contract more explicit)
this doesn't mean the previous revision was pointless - it still fixed one CUE related bug which I forgot to mention...
2011-02-03 22:21:15 +00:00
Paweł Bara 7bdac8fba6 when loading playlist, take only it's valid songs (+ force validity of CUE and PLS related songs) 2011-02-03 17:47:32 +00:00
Paweł Bara 4f7e804638 library: watcher now updates CUE associated songs + ignores the not-CUE-associated songs in a CUE sheet
CueParser: properly update length for the last song from every FILE in multifile CUE sheet
new 'playlist_path' argument in the 'Load' part of PlaylistParser's API
2011-01-11 23:09:59 +00:00
Paweł Bara 59378166b4 finalized the support for loading .cue based media using 'files' tab or drag and drop from the system's file browser
use FILE's PERFORMER as albumartist
2011-01-03 23:36:10 +00:00
David Sansome 6737b8a5c2 Always use the gstreamer engine, remove xine, vlc and phonon engines. 2010-12-26 13:01:35 +00:00
David Sansome f1f0a384a5 Sort songs loaded from directories by filename if there are no other tags present. Fixes issue #1104 2010-12-18 18:47:44 +00:00
David Sansome 08b2bcc816 Always write URLs in XML based playlists, instead of URLs of relative paths. Also load playlist items from the library if possible. Fixes issue #1054 2010-12-11 10:35:07 +00:00
David Sansome bbf0cd48c2 Insert songs as library playlist items if they're in the library. Fixes issue #1039 2010-12-07 19:33:19 +00:00
John Maguire eca1704384 Sort of working Jamendo dynamic playlist. 2010-11-26 15:16:48 +00:00