| Commit message (Collapse) | Author | Files | Lines |
|
Making the function return the index makes it more flexible: those who
want the pointer can use filelist_get(), and the others may use the
index for other purposes.
|
|
The function filelist_find_directory() will be useful for the
following patch.
|
|
Since all screen updating is now on demand, we don't need this flag
anymore.
|
|
When I converted the filelist from GList to GPtrArray, I missed that
the GCompareFunc does not actually get the pointers from
g_ptr_array_sort(), but pointers to the pointers... run
g_ptr_array_sort_with_data() instead with a wrapper function.
|
|
Somehow I forgot about changing free() to g_slice_free() in the
previous patch...
|
|
In this case, slices are faster. Also fix a memory leak in
filelist_prepend() which I simply forgot about in the last patch set.
|
|
Since we do a lot of indexed accesses to the filelist, a linked list
doesn't seem appropriate. Use GPtrArray instead.
|
|
Avoid direct accesses to the filelist struct, provide an API for that.
|
|
The separate filelist library does not depend on mpdclient, so the
prefix is superfluous.
|
|
A caller must not pass NULL to mpdclient_filelist_find_song().
Replace the check with an assertion.
|
|
Move everything which is solely filelist related to filelist.c and
filelist.h. Fix the indentation of that file, and provide the struct
name "filelist". Don't clear data in mpdclient_filelist_free() before
calling g_free(). Constify the "song" parameter to
mpdclient_filelist_find_song().
|