rhythmbox r5644 - in trunk: . backends doc/reference sources widgets
- From: jmatthew svn gnome org
- To: svn-commits-list gnome org
- Subject: rhythmbox r5644 - in trunk: . backends doc/reference sources widgets
- Date: Sun, 23 Mar 2008 13:29:51 +0000 (GMT)
Author: jmatthew
Date: Sun Mar 23 13:29:51 2008
New Revision: 5644
URL: http://svn.gnome.org/viewvc/rhythmbox?rev=5644&view=rev
Log:
2008-03-23 Jonathan Matthew <jonathan d14n org>
* backends/rb-player-gst-filter.c:
(rb_player_gst_filter_interface_init):
* backends/rb-player-gst-tee.c: (rb_player_gst_tee_interface_init):
* backends/rb-player-gst-tee.h:
* sources/rb-auto-playlist-source.c:
* sources/rb-auto-playlist-source.h:
* doc/reference/rhythmbox-sections.txt:
Add docs for RBPlayerGstTee, RBPlayerGstFilter, RBAutoPlaylistSource
* widgets/rb-entry-view.h:
* widgets/rb-header.h:
* widgets/rb-property-view.h:
Rename some args to match the code.
Modified:
trunk/ChangeLog
trunk/backends/rb-player-gst-filter.c
trunk/backends/rb-player-gst-tee.c
trunk/backends/rb-player-gst-tee.h
trunk/doc/reference/rhythmbox-sections.txt
trunk/sources/rb-auto-playlist-source.c
trunk/sources/rb-auto-playlist-source.h
trunk/widgets/rb-entry-view.h
trunk/widgets/rb-header.h
trunk/widgets/rb-property-view.h
Modified: trunk/backends/rb-player-gst-filter.c
==============================================================================
--- trunk/backends/rb-player-gst-filter.c (original)
+++ trunk/backends/rb-player-gst-filter.c Sun Mar 23 13:29:51 2008
@@ -23,6 +23,15 @@
#include "rb-player-gst-filter.h"
#include "rb-marshal.h"
+/**
+ * SECTION:rb-player-gst-filter
+ * @short_description: player interface for inserting filter elements
+ * @include: rb-player-gst-filter.h
+ *
+ * This interface allows a caller to add filter elements to the GStreamer playback
+ * pipeline.
+ */
+
enum {
FILTER_INSERTED,
FILTER_PRE_REMOVE,
@@ -35,7 +44,8 @@
rb_player_gst_filter_interface_init (RBPlayerGstFilterIface *iface)
{
/**
- * RBPlayerGstFilter::tee-inserted
+ * RBPlayerGstFilter::filter-inserted:
+ * @player: the #RBPlayerGstFilter implementation
* @filter: the element which has been inserted
*
* The 'filter-inserted' signal is emitted when the tee element has been
@@ -52,7 +62,8 @@
1, G_TYPE_OBJECT);
/**
- * RBPlayerGstFilter::tee-pre-remove
+ * RBPlayerGstFilter::filter-pre-remove:
+ * @player: the #RBPlayerGstFilter implementation
* @filter: the element which is about to be removed
*
* The 'filter-pre-remove' signal is emitted immediately before the element
@@ -94,6 +105,17 @@
return our_type;
}
+/**
+ * rb_player_gst_filter_add_filter:
+ * @player: #RBPlayerGstFilter implementation
+ * @element: new filter element (or bin) to add
+ *
+ * Adds a new filter to the playback pipeline. The filter may not be
+ * inserted immediately. The 'filter-inserted' signal will be emitted
+ * when this actually happens.
+ *
+ * Return value: TRUE if the filter will be added
+ */
gboolean
rb_player_gst_filter_add_filter (RBPlayerGstFilter *player, GstElement *element)
{
@@ -102,6 +124,17 @@
return iface->add_filter (player, element);
}
+/**
+ * rb_player_gst_filter_remove_filter:
+ * @player: #RBPlayerGstFilter implementation
+ * @element: the filter element (or bin) to remove
+ *
+ * Removes a filter from the playback pipeline. The filter may not be
+ * removed immediately. The 'filter-pre-remove' signal will be emitted
+ * immediately before this actually happens.
+ *
+ * Return value: TRUE if the filter was found and will be removed
+ */
gboolean
rb_player_gst_filter_remove_filter (RBPlayerGstFilter *player, GstElement *element)
{
Modified: trunk/backends/rb-player-gst-tee.c
==============================================================================
--- trunk/backends/rb-player-gst-tee.c (original)
+++ trunk/backends/rb-player-gst-tee.c Sun Mar 23 13:29:51 2008
@@ -23,6 +23,14 @@
#include "rb-player-gst-tee.h"
#include "rb-marshal.h"
+/**
+ * SECTION:rb-player-gst-tee
+ * @short_description: player interface for inserting additional sinks
+ * @include: rb-player-gst-tee.h
+ *
+ * This interface allows a caller to add a new sink to the GStreamer playback
+ * pipeline.
+ */
enum {
TEE_INSERTED,
@@ -36,7 +44,8 @@
rb_player_gst_tee_interface_init (RBPlayerGstTeeIface *iface)
{
/**
- * RBPlayerGstTee::tee-inserted
+ * RBPlayerGstTee::tee-inserted:
+ * @player: the #RBPlayerGstTee implementation
* @tee: the element which has been inserted
*
* The 'tee-inserted' signal is emitted when the tee element has been
@@ -54,6 +63,7 @@
/**
* RBPlayerGstTee::tee-pre-remove
+ * @player: the #RBPlayerGstTee implementation
* @tee: the element which is about to be removed
*
* The 'tee-pre-remove' signal is emitted immediately before the element
@@ -94,6 +104,17 @@
return our_type;
}
+/**
+ * rb_player_gst_tee_add_tee:
+ * @player: #RBPlayerGstTee implementation
+ * @element: new sink element (or bin) to add
+ *
+ * Adds a new sink to the playback pipeline. The sink may not be
+ * inserted immediately. The 'tee-inserted' signal will be emitted
+ * when this actually happens.
+ *
+ * Return value: TRUE if the sink will be added
+ */
gboolean
rb_player_gst_tee_add_tee (RBPlayerGstTee *player, GstElement *element)
{
@@ -102,6 +123,17 @@
return iface->add_tee (player, element);
}
+/**
+ * rb_player_gst_tee_remove_tee:
+ * @player: #RBPlayerGstTee implementation
+ * @element: the sink element (or bin) to remove
+ *
+ * Removes a sink from the playback pipeline. The sink may not be
+ * removed immediately. The 'tee-pre-remove' signal will be emitted
+ * immediately before this actually happens.
+ *
+ * Return value: TRUE if the sink was found and will be removed
+ */
gboolean
rb_player_gst_tee_remove_tee (RBPlayerGstTee *player, GstElement *element)
{
Modified: trunk/backends/rb-player-gst-tee.h
==============================================================================
--- trunk/backends/rb-player-gst-tee.h (original)
+++ trunk/backends/rb-player-gst-tee.h Sun Mar 23 13:29:51 2008
@@ -35,8 +35,9 @@
#define RB_PLAYER_GST_TEE_GET_IFACE(o) (G_TYPE_INSTANCE_GET_INTERFACE ((o), RB_TYPE_PLAYER_GST_TEE, RBPlayerGstTeeIface))
typedef struct _RBPlayerGstTee RBPlayerGstTee;
+typedef struct _RBPlayerGstTeeIface RBPlayerGstTeeIface;
-typedef struct
+struct _RBPlayerGstTeeIface
{
GTypeInterface g_iface;
@@ -47,7 +48,7 @@
/* signals */
void (*tee_inserted) (RBPlayerGstTee *player, GstElement *tee);
void (*tee_pre_remove) (RBPlayerGstTee *player, GstElement *tee);
-} RBPlayerGstTeeIface;
+};
GType rb_player_gst_tee_get_type (void);
Modified: trunk/doc/reference/rhythmbox-sections.txt
==============================================================================
--- trunk/doc/reference/rhythmbox-sections.txt (original)
+++ trunk/doc/reference/rhythmbox-sections.txt Sun Mar 23 13:29:51 2008
@@ -2016,7 +2016,9 @@
<SECTION>
<FILE>rb-player-gst-filter</FILE>
+<TITLE>RBPlayerGstFilter</TITLE>
RBPlayerGstFilter
+RBPlayerGstFilterIface
rb_player_gst_filter_add_filter
rb_player_gst_filter_remove_filter
<SUBSECTION Standard>
@@ -2029,7 +2031,9 @@
<SECTION>
<FILE>rb-player-gst-tee</FILE>
+<TITLE>RBPlayerGstTee</TITLE>
RBPlayerGstTee
+RBPlayerGstTeeIface
rb_player_gst_tee_add_tee
rb_player_gst_tee_remove_tee
<SUBSECTION Standard>
@@ -2321,6 +2325,9 @@
<SECTION>
<FILE>rb-auto-playlist-source</FILE>
+<TITLE>RBAutoPlaylistSource</TITLE>
+RBAutoPlaylistSource
+RBAutoPlaylistSourceClass
rb_auto_playlist_source_new
rb_auto_playlist_source_new_from_xml
rb_auto_playlist_source_set_query
Modified: trunk/sources/rb-auto-playlist-source.c
==============================================================================
--- trunk/sources/rb-auto-playlist-source.c (original)
+++ trunk/sources/rb-auto-playlist-source.c Sun Mar 23 13:29:51 2008
@@ -35,6 +35,25 @@
#include "rb-stock-icons.h"
#include "rb-playlist-xml.h"
+/**
+ * SECTION:rb-auto-playlist-source
+ * @short_description: automatic playlist source, based on a database query
+ *
+ * A playlist populated with the results of a database query.
+ *
+ * The query, limit, and sort settings are saved to the playlists file, so
+ * they are persistent.
+ *
+ * Searching is implemented by appending the query criteria generated from
+ * the search text to the query. Browsing is implemented by using the base
+ * query model (or a query model using the query generated from the search text,
+ * there is some) as the input to a #RBLibraryBrowser.
+ *
+ * If the user has not set a sort order as part of the playlist definition,
+ * the entry view columns are made clickable to allow the user to sort the
+ * results.
+ */
+
static GObject *rb_auto_playlist_source_constructor (GType type, guint n_construct_properties,
GObjectConstructParam *construct_properties);
static void rb_auto_playlist_source_dispose (GObject *object);
@@ -256,6 +275,16 @@
return G_OBJECT (source);
}
+/**
+ * rb_auto_playlist_source_new:
+ * @shell: the #RBShell instance
+ * @name: the name of the new playlist
+ * @local: if TRUE, the playlist will be considered local
+ *
+ * Creates a new automatic playlist source, initially with an empty query.
+ *
+ * Return value: the new source
+ */
RBSource *
rb_auto_playlist_source_new (RBShell *shell, const char *name, gboolean local)
{
@@ -271,6 +300,15 @@
NULL));
}
+/**
+ * rb_auto_playlist_source_new_from_xml:
+ * @shell: the #RBShell instance
+ * @node: libxml node containing the playlist
+ *
+ * Creates a new auto playlist source by parsing an XML-encoded query.
+ *
+ * Return value: the new source
+ */
RBSource *
rb_auto_playlist_source_new_from_xml (RBShell *shell, xmlNodePtr node)
{
@@ -691,6 +729,18 @@
rhythmdb_query_free (query);
}
+/**
+ * rb_auto_playlist_source_set_query:
+ * @source: the #RBAutoPlaylistSource
+ * @query: the new database query
+ * @limit_type: the playlist limit type
+ * @limit_value: the playlist limit value
+ * @sort_key: the sorting key
+ * @sort_direction: the sorting direction (as a #GtkSortType)
+ *
+ * Sets the database query used to populate the playlist, and also the limit on
+ * playlist size, and the sorting type used.
+ */
void
rb_auto_playlist_source_set_query (RBAutoPlaylistSource *source,
GPtrArray *query,
@@ -737,6 +787,17 @@
priv->query_resetting = FALSE;
}
+/**
+ * rb_auto_playlist_source_get_query:
+ * @source: the #RBAutoPlaylistSource
+ * @query: returns the database query for the playlist
+ * @limit_type: returns the playlist limit type
+ * @limit_value: returns the playlist limit value
+ * @sort_key: returns the playlist sorting key
+ * @sort_direction: returns the playlist sorting direction (as a GtkSortOrder)
+ *
+ * Extracts the current query, playlist limit, and sorting settings for the playlist.
+ */
void
rb_auto_playlist_source_get_query (RBAutoPlaylistSource *source,
GPtrArray **query,
Modified: trunk/sources/rb-auto-playlist-source.h
==============================================================================
--- trunk/sources/rb-auto-playlist-source.h (original)
+++ trunk/sources/rb-auto-playlist-source.h Sun Mar 23 13:29:51 2008
@@ -36,15 +36,18 @@
#define RB_IS_AUTO_PLAYLIST_SOURCE_CLASS(k) (G_TYPE_CHECK_CLASS_TYPE ((k), RB_TYPE_AUTO_PLAYLIST_SOURCE))
#define RB_AUTO_PLAYLIST_SOURCE_GET_CLASS(o) (G_TYPE_INSTANCE_GET_CLASS ((o), RB_TYPE_AUTO_PLAYLIST_SOURCE, RBAutoPlaylistSourceClass))
-typedef struct
+typedef struct _RBAutoPlaylistSource RBAutoPlaylistSource;
+typedef struct _RBAutoPlaylistSourceClass RBAutoPlaylistSourceClass;
+
+struct _RBAutoPlaylistSource
{
RBPlaylistSource parent;
-} RBAutoPlaylistSource;
+};
-typedef struct
+struct _RBAutoPlaylistSourceClass
{
RBPlaylistSourceClass parent;
-} RBAutoPlaylistSourceClass;
+};
GType rb_auto_playlist_source_get_type (void);
Modified: trunk/widgets/rb-entry-view.h
==============================================================================
--- trunk/widgets/rb-entry-view.h (original)
+++ trunk/widgets/rb-entry-view.h Sun Mar 23 13:29:51 2008
@@ -104,8 +104,8 @@
RBEntryView * rb_entry_view_new (RhythmDB *db,
GObject *shell_player,
const char *sort_key,
- gboolean drag_source,
- gboolean drag_dest);
+ gboolean is_drag_source,
+ gboolean is_drag_dest);
void rb_entry_view_append_column (RBEntryView *view,
RBEntryViewColumn coltype,
Modified: trunk/widgets/rb-header.h
==============================================================================
--- trunk/widgets/rb-header.h (original)
+++ trunk/widgets/rb-header.h Sun Mar 23 13:29:51 2008
@@ -56,7 +56,7 @@
GType rb_header_get_type (void);
-RBHeader * rb_header_new (RBShellPlayer *header,
+RBHeader * rb_header_new (RBShellPlayer *shell_player,
RhythmDB *db);
void rb_header_set_playing_entry (RBHeader *header,
Modified: trunk/widgets/rb-property-view.h
==============================================================================
--- trunk/widgets/rb-property-view.h (original)
+++ trunk/widgets/rb-property-view.h Sun Mar 23 13:29:51 2008
@@ -75,7 +75,7 @@
void rb_property_view_reset (RBPropertyView *view);
void rb_property_view_set_selection (RBPropertyView *view,
- const GList *names);
+ const GList *vals);
GList * rb_property_view_get_selection (RBPropertyView *view);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]