jcorporation
7bf43a9712
Add "added" timestamp to song database
...
- added is set to current time, if a new song is added to the database.
- GetAdded falls back to mtime.
Code for proxy plugin is missing, this needs a patch for libmpdclient.
closes #378
2023-10-20 17:29:31 +02:00
Max Kellermann
181b96dd2d
command/player, SongPrint: use AudioFormatFormatter()
...
libfmt version 10 apparently doesn't know how to format a
`StringBuffer`, failing the MPD build. Since we have a formatter
specialization for `AudioFormat`, let's use that - it's better and
easier to use.
Closes https://github.com/MusicPlayerDaemon/MPD/issues/1807
2023-05-15 20:59:05 +02:00
Max Kellermann
148aca23be
use SPDX IDs, replacing the long copyright headers
2023-03-06 14:59:48 +01:00
Max Kellermann
cc0def15c4
Copyright year 2022
2022-07-14 17:59:35 +02:00
Max Kellermann
b22d7218aa
command/player, ...: use decimal notation
...
During the libfmt migration, I converted "%1.3f" to just "{:1.3}"
without the "f" suffix, but libfmt defaults to scientific notation,
which can break some MPD clients.
Closes https://github.com/MusicPlayerDaemon/MPD/issues/1291
2021-10-18 16:54:53 +02:00
Max Kellermann
792411384d
protocol/ArgParser: add function MakeArgError()
...
Replaces FormatProtocolError().
2021-05-27 16:01:44 +02:00
Max Kellermann
0440c41cba
client/Response: add method Fmt() based on libfmt
2021-05-25 16:01:56 +02:00
Max Kellermann
c729f16dcd
song/DetachedSong: copy the AudioFormat from LightSong
...
Enables the "Format" row in "playlistinfo" responses.
https://github.com/MusicPlayerDaemon/MPD/issues/1094
2021-02-18 22:16:11 +01:00
Max Kellermann
fee282f49c
SongPrint: use LightSong::GetDuration()
...
This properly prints the "Time"/"duration" values for songs in virtual
CUE folders.
This is loosely related to
https://github.com/MusicPlayerDaemon/MPD/issues/1048
2021-01-21 13:52:00 +01:00
Max Kellermann
5348f8c9c8
copyright year 2021
2021-01-01 19:54:28 +01:00
Max Kellermann
2817bf9e95
copyright year 2020
2020-01-18 19:23:49 +01:00
Max Kellermann
d663f81420
include cleanups (powered by iwyu)
2019-07-05 09:59:58 +02:00
Max Kellermann
a139279575
Copyright year 2019
2019-06-17 11:17:30 +02:00
Max Kellermann
214ddee2f5
util/Time*: move to time/
2019-05-08 15:47:58 +02:00
Max Kellermann
ce49d99c2f
check.h: remove obsolete header
...
Since we switched from autotools to Meson in commit
94592c1406
, we don't need to include
`config.h` early to properly enable large file support. Meson passes
the required macros on the compiler command line instead of defining
them in `config.h`.
This means we can include `config.h` at any time, whenever we want to
check its macros, and there are no ordering constraints.
2018-11-19 16:33:49 +01:00
Max Kellermann
f5c9071494
*: copyright year 2018
2018-10-31 17:54:59 +01:00
Max Kellermann
90201e9970
DetachedSong, db/LightSong, SongFilter: move to src/song/
2018-08-02 13:51:18 +02:00
Max Kellermann
72b6c09a73
db/simple: add an AudioFormat to each Song
2018-07-06 22:49:02 +02:00
Max Kellermann
b9ff6383a4
db/LightSong: make Tag a reference
...
This enforces the "not nullptr" rule.
2018-07-06 16:47:47 +02:00
Max Kellermann
2b67a14155
SongPrint: add "noexcept"
2018-01-21 11:32:10 +01:00
Max Kellermann
b886dfae4d
DetachedSong, db/LightSong, db/simple/Song: use std::chrono::system_clock::time_point
2017-08-18 12:22:47 +02:00
Max Kellermann
71ce1a25dd
SongPrint: remove Storage::MapToRelativeUTF8() call
...
This code (added 7 years ago with commit b233c145f
) has been obsoleted
by the SongLoader class (added 3 years ago).
2017-02-24 13:56:13 +01:00
Max Kellermann
1d445d1039
SongPrint: move duplicate code into PrintRange()
2017-02-20 22:00:11 +01:00
Max Kellermann
5900253b85
update copyright year
2017-01-03 20:48:59 +01:00
Max Kellermann
1d67aa7bf2
update copyright year to 2016
2016-02-26 17:54:05 +01:00
Max Kellermann
7652a2986b
client/Response: new Client wrapper class for writing responses
2015-08-12 08:41:05 +02:00
Max Kellermann
a62fe30546
SongPrint: let CPP concatenate string literals
2015-02-06 13:06:38 +01:00
Max Kellermann
712ed555e6
Copyright year 2015
2015-01-01 19:48:13 +01:00
Max Kellermann
70b5a81a29
{Tag,Song}Print, PlayerCommands: report song duration with milliseconds precision
2014-11-25 17:46:43 +01:00
Max Kellermann
89f9561d10
storage/Interface: include cleanup
2014-10-01 23:38:17 +02:00
Max Kellermann
7c25d83f1c
Tag: use SignedSongTime for the song duration
2014-08-29 13:20:58 +02:00
Max Kellermann
2efd8ef52d
db/LightSong: use std::chrono::duration for start_ms and end_ms
2014-08-28 13:03:18 +02:00
Max Kellermann
6ad933982f
DetachedSong: use std::chrono::duration for start_ms and end_ms
2014-08-28 13:03:18 +02:00
Max Kellermann
071d05465a
SongPrint: use DetachedSong::GetDuration()
...
Fixes the bogus duration of the last track in a CUE sheet.
2014-07-12 18:41:15 +02:00
Max Kellermann
96afa8bd2b
command: add command "listfiles"
...
Lists files and directories. Supports storage plugins.
2014-03-01 06:25:57 +01:00
Max Kellermann
ffd16b55a6
StoragePlugin: add method MapToRelativeUTF8()
...
Replaces map_to_relative_path() from Mapper.cxx.
2014-02-07 19:09:28 +01:00
Max Kellermann
9d34fc394c
Database*: move to db/
2014-01-24 16:38:44 +01:00
Max Kellermann
e199c33c6e
Client*: move to client/
2014-01-24 00:26:53 +01:00
Max Kellermann
a42f9e4ee3
LightDirectory: new struct replacing Directory in the DB API
2014-01-22 23:01:32 +01:00
Max Kellermann
f5ae1ce00b
LightSong: new class to be used by DatabasePlugin callbacks
...
Detach the Song class completely from the public API, only to be used
by SimpleDatabase and the update thread.
2014-01-19 17:04:51 +01:00
Max Kellermann
d2cf74027c
Song: embed the Tag object statically into class Song
...
Reduces overhead because we need to manage only one memory allocation.
According to valgrind/massif, we save 7%.
2014-01-19 02:58:55 +01:00
Max Kellermann
4f83c60296
copyright year 2014
2014-01-13 22:31:55 +01:00
Max Kellermann
322b061632
DetachedSong: fork of struct Song
...
From now on, struct Song will be used by the database only, and
DetachedSong will be used by everybody else. DetachedSong is easier
to use, but Song has lower overhead.
2014-01-09 09:05:58 +01:00
Max Kellermann
3d12f8d246
UriUtil: uri_remove_auth() returns std::string
2013-10-23 21:58:44 +02:00
Max Kellermann
ff626ac763
*: use references instead of pointers
2013-10-19 18:48:38 +02:00
Max Kellermann
06f898cc12
tag: convert to C++
2013-07-30 20:19:53 +02:00
Max Kellermann
ba161ec572
song: convert header to C++
2013-07-28 13:25:12 +02:00
Max Kellermann
7ec1121cc8
uri: convert to C++
2013-04-08 23:45:31 +02:00
Max Kellermann
5ed9f02c4d
TagPool, ...: include cleanup
2013-01-30 22:53:12 +01:00
Max Kellermann
7a982169c9
Client: rename the struct client to class Client
2013-01-03 17:36:28 +01:00