mirror of
https://github.com/Rafostar/clapper.git
synced 2025-08-29 23:32:04 +02:00
Compare commits
14 Commits
disallow-e
...
ff054743e6
Author | SHA1 | Date | |
---|---|---|---|
|
ff054743e6 | ||
|
9432156aec | ||
|
47d3ebe693 | ||
|
5f8270f0e8 | ||
|
54f059aaa3 | ||
|
f63e13ed39 | ||
|
daadabba8d | ||
|
225e665aff | ||
|
31564b568b | ||
|
1c376612b8 | ||
|
c4afd8bea1 | ||
|
266c588db9 | ||
|
1c0049ec2b | ||
|
7f326e6875 |
Submodule pkgs/flatpak/flathub updated: b7c25acba8...3a672be190
@@ -582,7 +582,7 @@ _create_pipeline_svg_file_in_thread (GTask *task, GObject *source G_GNUC_UNUSED,
|
|||||||
GVC_t *gvc;
|
GVC_t *gvc;
|
||||||
gchar *path, *template = NULL, *dot_data = NULL, *img_data = NULL;
|
gchar *path, *template = NULL, *dot_data = NULL, *img_data = NULL;
|
||||||
gint fd;
|
gint fd;
|
||||||
guint size = 0;
|
gsize size = 0;
|
||||||
|
|
||||||
if (!(tmp_subdir = _create_tmp_subdir ("pipelines", cancellable, &error)))
|
if (!(tmp_subdir = _create_tmp_subdir ("pipelines", cancellable, &error)))
|
||||||
goto finish;
|
goto finish;
|
||||||
@@ -610,7 +610,16 @@ _create_pipeline_svg_file_in_thread (GTask *task, GObject *source G_GNUC_UNUSED,
|
|||||||
|
|
||||||
gvc = gvContext ();
|
gvc = gvContext ();
|
||||||
gvLayout (gvc, graph, "dot");
|
gvLayout (gvc, graph, "dot");
|
||||||
|
|
||||||
|
#ifdef HAVE_GVC_13
|
||||||
gvRenderData (gvc, graph, "svg", &img_data, &size);
|
gvRenderData (gvc, graph, "svg", &img_data, &size);
|
||||||
|
#else
|
||||||
|
{
|
||||||
|
guint tmp_size = 0; // Temporary uint to satisfy older API
|
||||||
|
gvRenderData (gvc, graph, "svg", &img_data, &tmp_size);
|
||||||
|
size = tmp_size;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
agclose (graph);
|
agclose (graph);
|
||||||
gvFreeContext (gvc);
|
gvFreeContext (gvc);
|
||||||
|
@@ -1237,6 +1237,8 @@ clapper_app_window_constructed (GObject *object)
|
|||||||
ClapperAppWindow *self = CLAPPER_APP_WINDOW_CAST (object);
|
ClapperAppWindow *self = CLAPPER_APP_WINDOW_CAST (object);
|
||||||
ClapperPlayer *player = clapper_app_window_get_player (self);
|
ClapperPlayer *player = clapper_app_window_get_player (self);
|
||||||
ClapperQueue *queue = clapper_player_get_queue (player);
|
ClapperQueue *queue = clapper_player_get_queue (player);
|
||||||
|
ClapperEnhancerProxyList *proxies = clapper_player_get_enhancer_proxies (player);
|
||||||
|
ClapperEnhancerProxy *proxy;
|
||||||
ClapperGtkExtraMenuButton *button;
|
ClapperGtkExtraMenuButton *button;
|
||||||
AdwStyleManager *manager;
|
AdwStyleManager *manager;
|
||||||
|
|
||||||
@@ -1250,10 +1252,6 @@ clapper_app_window_constructed (GObject *object)
|
|||||||
#if (CLAPPER_HAVE_MPRIS || CLAPPER_HAVE_SERVER || CLAPPER_HAVE_DISCOVERER)
|
#if (CLAPPER_HAVE_MPRIS || CLAPPER_HAVE_SERVER || CLAPPER_HAVE_DISCOVERER)
|
||||||
ClapperFeature *feature = NULL;
|
ClapperFeature *feature = NULL;
|
||||||
#endif
|
#endif
|
||||||
#if (!CLAPPER_HAVE_MPRIS || !CLAPPER_HAVE_SERVER || !CLAPPER_HAVE_DISCOVERER)
|
|
||||||
ClapperEnhancerProxyList *proxies = clapper_player_get_enhancer_proxies (player);
|
|
||||||
ClapperEnhancerProxy *proxy;
|
|
||||||
#endif
|
|
||||||
|
|
||||||
gchar mpris_name[45];
|
gchar mpris_name[45];
|
||||||
g_snprintf (mpris_name, sizeof (mpris_name),
|
g_snprintf (mpris_name, sizeof (mpris_name),
|
||||||
@@ -1262,7 +1260,6 @@ clapper_app_window_constructed (GObject *object)
|
|||||||
self->settings = g_settings_new (CLAPPER_APP_ID);
|
self->settings = g_settings_new (CLAPPER_APP_ID);
|
||||||
self->last_volume = PERCENTAGE_ROUND (g_settings_get_double (self->settings, "volume"));
|
self->last_volume = PERCENTAGE_ROUND (g_settings_get_double (self->settings, "volume"));
|
||||||
|
|
||||||
#if !CLAPPER_HAVE_MPRIS
|
|
||||||
if ((proxy = clapper_enhancer_proxy_list_get_proxy_by_module (proxies, "clapper-mpris"))) {
|
if ((proxy = clapper_enhancer_proxy_list_get_proxy_by_module (proxies, "clapper-mpris"))) {
|
||||||
clapper_enhancer_proxy_set_locally (proxy,
|
clapper_enhancer_proxy_set_locally (proxy,
|
||||||
"own-name", mpris_name,
|
"own-name", mpris_name,
|
||||||
@@ -1270,14 +1267,15 @@ clapper_app_window_constructed (GObject *object)
|
|||||||
"desktop-entry", CLAPPER_APP_ID,
|
"desktop-entry", CLAPPER_APP_ID,
|
||||||
"queue-controllable", TRUE, NULL);
|
"queue-controllable", TRUE, NULL);
|
||||||
gst_object_unref (proxy);
|
gst_object_unref (proxy);
|
||||||
}
|
} else {
|
||||||
#else
|
#if CLAPPER_HAVE_MPRIS
|
||||||
feature = CLAPPER_FEATURE (clapper_mpris_new (
|
feature = CLAPPER_FEATURE (clapper_mpris_new (
|
||||||
mpris_name, CLAPPER_APP_NAME, CLAPPER_APP_ID));
|
mpris_name, CLAPPER_APP_NAME, CLAPPER_APP_ID));
|
||||||
clapper_mpris_set_queue_controllable (CLAPPER_MPRIS (feature), TRUE);
|
clapper_mpris_set_queue_controllable (CLAPPER_MPRIS (feature), TRUE);
|
||||||
clapper_player_add_feature (player, feature);
|
clapper_player_add_feature (player, feature);
|
||||||
gst_object_unref (feature);
|
gst_object_unref (feature);
|
||||||
#endif
|
#endif
|
||||||
|
}
|
||||||
|
|
||||||
#if CLAPPER_HAVE_SERVER
|
#if CLAPPER_HAVE_SERVER
|
||||||
feature = CLAPPER_FEATURE (clapper_server_new ());
|
feature = CLAPPER_FEATURE (clapper_server_new ());
|
||||||
|
@@ -105,6 +105,9 @@ if not pp_option.disabled()
|
|||||||
if cgraph_dep.found() and gvc_dep.found()
|
if cgraph_dep.found() and gvc_dep.found()
|
||||||
clapperapp_c_args += ['-DHAVE_GRAPHVIZ']
|
clapperapp_c_args += ['-DHAVE_GRAPHVIZ']
|
||||||
clapperapp_deps += [cgraph_dep, gvc_dep]
|
clapperapp_deps += [cgraph_dep, gvc_dep]
|
||||||
|
if gvc_dep.version().version_compare('>= 13.0.0')
|
||||||
|
clapperapp_c_args += ['-DHAVE_GVC_13']
|
||||||
|
endif
|
||||||
clapperapp_available_functionalities += 'pipeline-preview'
|
clapperapp_available_functionalities += 'pipeline-preview'
|
||||||
elif pp_option.enabled()
|
elif pp_option.enabled()
|
||||||
error('pipeline-preview option was enabled, but required dependencies were not found')
|
error('pipeline-preview option was enabled, but required dependencies were not found')
|
||||||
|
@@ -395,6 +395,47 @@ _update_duration_label (ClapperGtkSeekBar *self, gdouble duration)
|
|||||||
gtk_adjustment_set_upper (adjustment, duration);
|
gtk_adjustment_set_upper (adjustment, duration);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static gboolean
|
||||||
|
_find_marks_in_widget (GtkWidget *widget, GtkWidget **top_marks, GtkWidget **bottom_marks)
|
||||||
|
{
|
||||||
|
GtkWidget *child;
|
||||||
|
|
||||||
|
if (g_strcmp0 (gtk_widget_get_css_name (widget), "marks") == 0) {
|
||||||
|
if (gtk_widget_has_css_class (widget, "top"))
|
||||||
|
*top_marks = widget;
|
||||||
|
else if (gtk_widget_has_css_class (widget, "bottom"))
|
||||||
|
*bottom_marks = widget;
|
||||||
|
|
||||||
|
/* Its unexpected to have marks within marks,
|
||||||
|
* so do not iterate children of marks widget */
|
||||||
|
return (*top_marks && *bottom_marks);
|
||||||
|
}
|
||||||
|
|
||||||
|
child = gtk_widget_get_first_child (widget);
|
||||||
|
|
||||||
|
while (child != NULL) {
|
||||||
|
if (_find_marks_in_widget (child, top_marks, bottom_marks))
|
||||||
|
return TRUE;
|
||||||
|
|
||||||
|
child = gtk_widget_get_next_sibling (child);
|
||||||
|
}
|
||||||
|
|
||||||
|
return FALSE;
|
||||||
|
}
|
||||||
|
|
||||||
|
static gboolean
|
||||||
|
_find_last_mark_in_marks (GtkWidget *marks, GtkWidget **last_mark)
|
||||||
|
{
|
||||||
|
GtkWidget *widget = gtk_widget_get_last_child (marks);
|
||||||
|
|
||||||
|
if (widget && g_strcmp0 (gtk_widget_get_css_name (widget), "mark") == 0) {
|
||||||
|
*last_mark = widget;
|
||||||
|
return TRUE;
|
||||||
|
}
|
||||||
|
|
||||||
|
return FALSE;
|
||||||
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
_update_scale_marks (ClapperGtkSeekBar *self, ClapperTimeline *timeline)
|
_update_scale_marks (ClapperGtkSeekBar *self, ClapperTimeline *timeline)
|
||||||
{
|
{
|
||||||
@@ -423,11 +464,43 @@ _update_scale_marks (ClapperGtkSeekBar *self, ClapperTimeline *timeline)
|
|||||||
|
|
||||||
for (i = 0; i < n_markers; ++i) {
|
for (i = 0; i < n_markers; ++i) {
|
||||||
ClapperMarker *marker = clapper_timeline_get_marker (timeline, i);
|
ClapperMarker *marker = clapper_timeline_get_marker (timeline, i);
|
||||||
|
ClapperMarkerType marker_type = clapper_marker_get_marker_type (marker);
|
||||||
gdouble start = clapper_marker_get_start (marker);
|
gdouble start = clapper_marker_get_start (marker);
|
||||||
|
|
||||||
gtk_scale_add_mark (GTK_SCALE (self->scale), start, GTK_POS_TOP, NULL);
|
gtk_scale_add_mark (GTK_SCALE (self->scale), start, GTK_POS_TOP, NULL);
|
||||||
gtk_scale_add_mark (GTK_SCALE (self->scale), start, GTK_POS_BOTTOM, NULL);
|
gtk_scale_add_mark (GTK_SCALE (self->scale), start, GTK_POS_BOTTOM, NULL);
|
||||||
|
|
||||||
|
if (marker_type >= CLAPPER_MARKER_TYPE_CUSTOM_1) {
|
||||||
|
GtkWidget *top_marks = NULL, *bottom_marks = NULL;
|
||||||
|
GtkWidget *top_mark = NULL, *bottom_mark = NULL;
|
||||||
|
|
||||||
|
if (_find_marks_in_widget (self->scale, &top_marks, &bottom_marks)
|
||||||
|
&& _find_last_mark_in_marks (top_marks, &top_mark)
|
||||||
|
&& _find_last_mark_in_marks (bottom_marks, &bottom_mark)) {
|
||||||
|
const gchar *custom_name;
|
||||||
|
|
||||||
|
switch (marker_type) {
|
||||||
|
case CLAPPER_MARKER_TYPE_CUSTOM_1:
|
||||||
|
custom_name = "custom1";
|
||||||
|
break;
|
||||||
|
case CLAPPER_MARKER_TYPE_CUSTOM_2:
|
||||||
|
custom_name = "custom2";
|
||||||
|
break;
|
||||||
|
case CLAPPER_MARKER_TYPE_CUSTOM_3:
|
||||||
|
custom_name = "custom3";
|
||||||
|
break;
|
||||||
|
default:
|
||||||
|
custom_name = NULL;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (G_LIKELY (custom_name != NULL)) {
|
||||||
|
gtk_widget_add_css_class (top_mark, custom_name);
|
||||||
|
gtk_widget_add_css_class (bottom_mark, custom_name);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
gst_object_unref (marker);
|
gst_object_unref (marker);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -129,6 +129,15 @@ clapper-gtk-seek-bar label {
|
|||||||
margin-left: 2px;
|
margin-left: 2px;
|
||||||
margin-right: 2px;
|
margin-right: 2px;
|
||||||
}
|
}
|
||||||
|
clapper-gtk-seek-bar scale marks .custom1 indicator {
|
||||||
|
color: tomato;
|
||||||
|
}
|
||||||
|
clapper-gtk-seek-bar scale marks .custom2 indicator {
|
||||||
|
color: goldenrod;
|
||||||
|
}
|
||||||
|
clapper-gtk-seek-bar scale marks .custom3 indicator {
|
||||||
|
color: limegreen;
|
||||||
|
}
|
||||||
|
|
||||||
clapper-gtk-extra-menu-button popover .spinsidebutton {
|
clapper-gtk-extra-menu-button popover .spinsidebutton {
|
||||||
min-width: 28px;
|
min-width: 28px;
|
||||||
|
@@ -34,8 +34,6 @@ static HMODULE _enhancers_dll_handle = NULL;
|
|||||||
#include "clapper-extractable.h"
|
#include "clapper-extractable.h"
|
||||||
#include "clapper-reactable.h"
|
#include "clapper-reactable.h"
|
||||||
|
|
||||||
#include <clapper-functionalities-availability.h>
|
|
||||||
|
|
||||||
#define GST_CAT_DEFAULT clapper_enhancers_loader_debug
|
#define GST_CAT_DEFAULT clapper_enhancers_loader_debug
|
||||||
GST_DEBUG_CATEGORY_STATIC (GST_CAT_DEFAULT);
|
GST_DEBUG_CATEGORY_STATIC (GST_CAT_DEFAULT);
|
||||||
|
|
||||||
@@ -134,36 +132,6 @@ clapper_enhancers_loader_initialize (ClapperEnhancerProxyList *proxies)
|
|||||||
ClapperEnhancerProxy *proxy;
|
ClapperEnhancerProxy *proxy;
|
||||||
gboolean filled;
|
gboolean filled;
|
||||||
|
|
||||||
/* FIXME: 1.0: Remove together with features code and manager.
|
|
||||||
* These would clash with each other, so avoid loading these
|
|
||||||
* as enhancers when also compiled as part of the library. */
|
|
||||||
#if (CLAPPER_HAVE_MPRIS || CLAPPER_HAVE_DISCOVERER || CLAPPER_HAVE_SERVER)
|
|
||||||
guint f_index;
|
|
||||||
const gchar *module_name = peas_plugin_info_get_module_name (info);
|
|
||||||
const gchar *ported_features[] = {
|
|
||||||
#if CLAPPER_HAVE_MPRIS
|
|
||||||
"clapper-mpris",
|
|
||||||
#endif
|
|
||||||
#if CLAPPER_HAVE_DISCOVERER
|
|
||||||
"clapper-discoverer",
|
|
||||||
#endif
|
|
||||||
#if CLAPPER_HAVE_SERVER
|
|
||||||
"clapper-server",
|
|
||||||
#endif
|
|
||||||
};
|
|
||||||
|
|
||||||
for (f_index = 0; f_index < G_N_ELEMENTS (ported_features); ++f_index) {
|
|
||||||
if (strcmp (module_name, ported_features[f_index]) == 0) {
|
|
||||||
GST_INFO ("Skipped \"%s\" enhancer module, since its"
|
|
||||||
" loaded from deprecated feature object", module_name);
|
|
||||||
g_clear_object (&info);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if (!info) // cleared when exists as feature
|
|
||||||
continue;
|
|
||||||
#endif
|
|
||||||
|
|
||||||
/* Clapper supports only 1 proxy per plugin. Each plugin can
|
/* Clapper supports only 1 proxy per plugin. Each plugin can
|
||||||
* ship 1 class, but it can implement more than 1 interface. */
|
* ship 1 class, but it can implement more than 1 interface. */
|
||||||
proxy = clapper_enhancer_proxy_new_global_take ((GObject *) info);
|
proxy = clapper_enhancer_proxy_new_global_take ((GObject *) info);
|
||||||
|
@@ -34,4 +34,10 @@ gboolean clapper_timeline_set_toc (ClapperTimeline *timeline, GstToc *toc, gbool
|
|||||||
G_GNUC_INTERNAL
|
G_GNUC_INTERNAL
|
||||||
void clapper_timeline_refresh (ClapperTimeline *timeline);
|
void clapper_timeline_refresh (ClapperTimeline *timeline);
|
||||||
|
|
||||||
|
G_GNUC_INTERNAL
|
||||||
|
void clapper_timeline_insert_marker_internal (ClapperTimeline *timeline, ClapperMarker *marker);
|
||||||
|
|
||||||
|
G_GNUC_INTERNAL
|
||||||
|
void clapper_timeline_remove_marker_internal (ClapperTimeline *timeline, ClapperMarker *marker);
|
||||||
|
|
||||||
G_END_DECLS
|
G_END_DECLS
|
||||||
|
@@ -30,6 +30,7 @@
|
|||||||
#include "clapper-player-private.h"
|
#include "clapper-player-private.h"
|
||||||
#include "clapper-reactables-manager-private.h"
|
#include "clapper-reactables-manager-private.h"
|
||||||
#include "clapper-features-manager-private.h"
|
#include "clapper-features-manager-private.h"
|
||||||
|
#include "clapper-utils-private.h"
|
||||||
|
|
||||||
#define GST_CAT_DEFAULT clapper_timeline_debug
|
#define GST_CAT_DEFAULT clapper_timeline_debug
|
||||||
GST_DEBUG_CATEGORY_STATIC (GST_CAT_DEFAULT);
|
GST_DEBUG_CATEGORY_STATIC (GST_CAT_DEFAULT);
|
||||||
@@ -187,25 +188,12 @@ _take_marker_unlocked (ClapperTimeline *self, ClapperMarker *marker)
|
|||||||
return g_sequence_iter_get_position (iter);
|
return g_sequence_iter_get_position (iter);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
void
|
||||||
* clapper_timeline_insert_marker:
|
clapper_timeline_insert_marker_internal (ClapperTimeline *self, ClapperMarker *marker)
|
||||||
* @timeline: a #ClapperTimeline
|
|
||||||
* @marker: a #ClapperMarker
|
|
||||||
*
|
|
||||||
* Insert the #ClapperMarker into @timeline.
|
|
||||||
*
|
|
||||||
* Returns: %TRUE if inserted, %FALSE if marker was
|
|
||||||
* already inserted into timeline.
|
|
||||||
*/
|
|
||||||
gboolean
|
|
||||||
clapper_timeline_insert_marker (ClapperTimeline *self, ClapperMarker *marker)
|
|
||||||
{
|
{
|
||||||
gboolean success;
|
gboolean success;
|
||||||
gint position = 0;
|
gint position = 0;
|
||||||
|
|
||||||
g_return_val_if_fail (CLAPPER_IS_TIMELINE (self), FALSE);
|
|
||||||
g_return_val_if_fail (CLAPPER_IS_MARKER (marker), FALSE);
|
|
||||||
|
|
||||||
GST_OBJECT_LOCK (self);
|
GST_OBJECT_LOCK (self);
|
||||||
|
|
||||||
if ((success = !g_sequence_lookup (self->markers_seq, marker,
|
if ((success = !g_sequence_lookup (self->markers_seq, marker,
|
||||||
@@ -220,30 +208,34 @@ clapper_timeline_insert_marker (ClapperTimeline *self, ClapperMarker *marker)
|
|||||||
|
|
||||||
clapper_timeline_post_item_updated (self);
|
clapper_timeline_post_item_updated (self);
|
||||||
}
|
}
|
||||||
|
|
||||||
return success;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* clapper_timeline_remove_marker:
|
* clapper_timeline_insert_marker:
|
||||||
* @timeline: a #ClapperTimeline
|
* @timeline: a #ClapperTimeline
|
||||||
* @marker: a #ClapperMarker
|
* @marker: a #ClapperMarker
|
||||||
*
|
*
|
||||||
* Removes #ClapperMarker from the timeline.
|
* Insert the #ClapperMarker into @timeline.
|
||||||
*
|
|
||||||
* If marker was not in the @timeline, this function will do nothing,
|
|
||||||
* so it is safe to call if unsure.
|
|
||||||
*/
|
*/
|
||||||
void
|
void
|
||||||
clapper_timeline_remove_marker (ClapperTimeline *self, ClapperMarker *marker)
|
clapper_timeline_insert_marker (ClapperTimeline *self, ClapperMarker *marker)
|
||||||
|
{
|
||||||
|
g_return_if_fail (CLAPPER_IS_TIMELINE (self));
|
||||||
|
g_return_if_fail (CLAPPER_IS_MARKER (marker));
|
||||||
|
|
||||||
|
if (g_main_context_is_owner (g_main_context_default ()))
|
||||||
|
clapper_timeline_insert_marker_internal (self, marker);
|
||||||
|
else
|
||||||
|
clapper_utils_timeline_insert_on_main_sync (self, marker);
|
||||||
|
}
|
||||||
|
|
||||||
|
void
|
||||||
|
clapper_timeline_remove_marker_internal (ClapperTimeline *self, ClapperMarker *marker)
|
||||||
{
|
{
|
||||||
GSequenceIter *iter;
|
GSequenceIter *iter;
|
||||||
gint position = 0;
|
gint position = 0;
|
||||||
gboolean success = FALSE;
|
gboolean success = FALSE;
|
||||||
|
|
||||||
g_return_if_fail (CLAPPER_IS_TIMELINE (self));
|
|
||||||
g_return_if_fail (CLAPPER_IS_MARKER (marker));
|
|
||||||
|
|
||||||
GST_OBJECT_LOCK (self);
|
GST_OBJECT_LOCK (self);
|
||||||
|
|
||||||
if ((iter = g_sequence_lookup (self->markers_seq, marker,
|
if ((iter = g_sequence_lookup (self->markers_seq, marker,
|
||||||
@@ -264,6 +256,25 @@ clapper_timeline_remove_marker (ClapperTimeline *self, ClapperMarker *marker)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* clapper_timeline_remove_marker:
|
||||||
|
* @timeline: a #ClapperTimeline
|
||||||
|
* @marker: a #ClapperMarker
|
||||||
|
*
|
||||||
|
* Removes #ClapperMarker from the timeline if present.
|
||||||
|
*/
|
||||||
|
void
|
||||||
|
clapper_timeline_remove_marker (ClapperTimeline *self, ClapperMarker *marker)
|
||||||
|
{
|
||||||
|
g_return_if_fail (CLAPPER_IS_TIMELINE (self));
|
||||||
|
g_return_if_fail (CLAPPER_IS_MARKER (marker));
|
||||||
|
|
||||||
|
if (g_main_context_is_owner (g_main_context_default ()))
|
||||||
|
clapper_timeline_remove_marker_internal (self, marker);
|
||||||
|
else
|
||||||
|
clapper_utils_timeline_remove_on_main_sync (self, marker);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* clapper_timeline_get_marker:
|
* clapper_timeline_get_marker:
|
||||||
* @timeline: a #ClapperTimeline
|
* @timeline: a #ClapperTimeline
|
||||||
|
@@ -38,7 +38,7 @@ CLAPPER_API
|
|||||||
G_DECLARE_FINAL_TYPE (ClapperTimeline, clapper_timeline, CLAPPER, TIMELINE, GstObject)
|
G_DECLARE_FINAL_TYPE (ClapperTimeline, clapper_timeline, CLAPPER, TIMELINE, GstObject)
|
||||||
|
|
||||||
CLAPPER_API
|
CLAPPER_API
|
||||||
gboolean clapper_timeline_insert_marker (ClapperTimeline *timeline, ClapperMarker *marker);
|
void clapper_timeline_insert_marker (ClapperTimeline *timeline, ClapperMarker *marker);
|
||||||
|
|
||||||
CLAPPER_API
|
CLAPPER_API
|
||||||
void clapper_timeline_remove_marker (ClapperTimeline *timeline, ClapperMarker *marker);
|
void clapper_timeline_remove_marker (ClapperTimeline *timeline, ClapperMarker *marker);
|
||||||
|
@@ -26,6 +26,8 @@
|
|||||||
#include "clapper-utils.h"
|
#include "clapper-utils.h"
|
||||||
#include "clapper-queue.h"
|
#include "clapper-queue.h"
|
||||||
#include "clapper-media-item.h"
|
#include "clapper-media-item.h"
|
||||||
|
#include "clapper-timeline.h"
|
||||||
|
#include "clapper-marker.h"
|
||||||
|
|
||||||
G_BEGIN_DECLS
|
G_BEGIN_DECLS
|
||||||
|
|
||||||
@@ -44,6 +46,12 @@ void clapper_utils_queue_remove_on_main_sync (ClapperQueue *queue, ClapperMediaI
|
|||||||
G_GNUC_INTERNAL
|
G_GNUC_INTERNAL
|
||||||
void clapper_utils_queue_clear_on_main_sync (ClapperQueue *queue);
|
void clapper_utils_queue_clear_on_main_sync (ClapperQueue *queue);
|
||||||
|
|
||||||
|
G_GNUC_INTERNAL
|
||||||
|
void clapper_utils_timeline_insert_on_main_sync (ClapperTimeline *timeline, ClapperMarker *marker);
|
||||||
|
|
||||||
|
G_GNUC_INTERNAL
|
||||||
|
void clapper_utils_timeline_remove_on_main_sync (ClapperTimeline *timeline, ClapperMarker *marker);
|
||||||
|
|
||||||
G_GNUC_INTERNAL
|
G_GNUC_INTERNAL
|
||||||
void clapper_utils_prop_notify_on_main_sync (GObject *object, GParamSpec *pspec);
|
void clapper_utils_prop_notify_on_main_sync (GObject *object, GParamSpec *pspec);
|
||||||
|
|
||||||
|
@@ -17,6 +17,7 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include "clapper-utils-private.h"
|
#include "clapper-utils-private.h"
|
||||||
|
#include "clapper-timeline-private.h"
|
||||||
#include "../shared/clapper-shared-utils-private.h"
|
#include "../shared/clapper-shared-utils-private.h"
|
||||||
|
|
||||||
#define GST_CAT_DEFAULT clapper_utils_debug
|
#define GST_CAT_DEFAULT clapper_utils_debug
|
||||||
@@ -24,19 +25,21 @@ GST_DEBUG_CATEGORY_STATIC (GST_CAT_DEFAULT);
|
|||||||
|
|
||||||
typedef enum
|
typedef enum
|
||||||
{
|
{
|
||||||
CLAPPER_UTILS_QUEUE_ALTER_APPEND = 1,
|
CLAPPER_UTILS_LIST_ALTER_QUEUE_APPEND = 1,
|
||||||
CLAPPER_UTILS_QUEUE_ALTER_INSERT,
|
CLAPPER_UTILS_LIST_ALTER_QUEUE_INSERT,
|
||||||
CLAPPER_UTILS_QUEUE_ALTER_REMOVE,
|
CLAPPER_UTILS_LIST_ALTER_QUEUE_REMOVE,
|
||||||
CLAPPER_UTILS_QUEUE_ALTER_CLEAR
|
CLAPPER_UTILS_LIST_ALTER_QUEUE_CLEAR,
|
||||||
} ClapperUtilsQueueAlterMethod;
|
CLAPPER_UTILS_LIST_ALTER_TIMELINE_INSERT,
|
||||||
|
CLAPPER_UTILS_LIST_ALTER_TIMELINE_REMOVE
|
||||||
|
} ClapperUtilsListAlterMethod;
|
||||||
|
|
||||||
typedef struct
|
typedef struct
|
||||||
{
|
{
|
||||||
ClapperQueue *queue;
|
GListModel *list;
|
||||||
ClapperMediaItem *item;
|
GObject *item;
|
||||||
ClapperMediaItem *after_item;
|
GObject *after_item;
|
||||||
ClapperUtilsQueueAlterMethod method;
|
ClapperUtilsListAlterMethod method;
|
||||||
} ClapperUtilsQueueAlterData;
|
} ClapperUtilsListAlterData;
|
||||||
|
|
||||||
typedef struct
|
typedef struct
|
||||||
{
|
{
|
||||||
@@ -51,27 +54,26 @@ clapper_utils_initialize (void)
|
|||||||
"Clapper Utilities");
|
"Clapper Utilities");
|
||||||
}
|
}
|
||||||
|
|
||||||
static ClapperUtilsQueueAlterData *
|
static ClapperUtilsListAlterData *
|
||||||
clapper_utils_queue_alter_data_new (ClapperQueue *queue,
|
clapper_utils_list_alter_data_new (GListModel *list, GObject *item,
|
||||||
ClapperMediaItem *item, ClapperMediaItem *after_item,
|
GObject *after_item, ClapperUtilsListAlterMethod method)
|
||||||
ClapperUtilsQueueAlterMethod method)
|
|
||||||
{
|
{
|
||||||
ClapperUtilsQueueAlterData *data = g_new (ClapperUtilsQueueAlterData, 1);
|
ClapperUtilsListAlterData *data = g_new (ClapperUtilsListAlterData, 1);
|
||||||
|
|
||||||
data->queue = queue;
|
data->list = list;
|
||||||
data->item = item;
|
data->item = item;
|
||||||
data->after_item = after_item;
|
data->after_item = after_item;
|
||||||
data->method = method;
|
data->method = method;
|
||||||
|
|
||||||
GST_TRACE ("Created queue alter data: %p", data);
|
GST_TRACE ("Created list alter data: %p", data);
|
||||||
|
|
||||||
return data;
|
return data;
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
clapper_utils_queue_alter_data_free (ClapperUtilsQueueAlterData *data)
|
clapper_utils_list_alter_data_free (ClapperUtilsListAlterData *data)
|
||||||
{
|
{
|
||||||
GST_TRACE ("Freeing queue alter data: %p", data);
|
GST_TRACE ("Freeing list alter data: %p", data);
|
||||||
|
|
||||||
g_free (data);
|
g_free (data);
|
||||||
}
|
}
|
||||||
@@ -98,35 +100,48 @@ clapper_utils_prop_notify_data_free (ClapperUtilsPropNotifyData *data)
|
|||||||
}
|
}
|
||||||
|
|
||||||
static gpointer
|
static gpointer
|
||||||
clapper_utils_queue_alter_on_main (ClapperUtilsQueueAlterData *data)
|
clapper_utils_list_alter_on_main (ClapperUtilsListAlterData *data)
|
||||||
{
|
{
|
||||||
GST_DEBUG ("Queue alter invoked");
|
GST_DEBUG ("Queue alter invoked");
|
||||||
|
|
||||||
switch (data->method) {
|
switch (data->method) {
|
||||||
case CLAPPER_UTILS_QUEUE_ALTER_APPEND:
|
case CLAPPER_UTILS_LIST_ALTER_QUEUE_APPEND:
|
||||||
clapper_queue_add_item (data->queue, data->item);
|
clapper_queue_add_item (CLAPPER_QUEUE_CAST (data->list),
|
||||||
|
CLAPPER_MEDIA_ITEM_CAST (data->item));
|
||||||
break;
|
break;
|
||||||
case CLAPPER_UTILS_QUEUE_ALTER_INSERT:{
|
case CLAPPER_UTILS_LIST_ALTER_QUEUE_INSERT:{
|
||||||
guint index;
|
guint index;
|
||||||
|
|
||||||
/* If we have "after_item" then we need to insert after it, otherwise prepend */
|
/* If we have "after_item" then we need to insert after it, otherwise prepend */
|
||||||
if (data->after_item) {
|
if (data->after_item) {
|
||||||
if (clapper_queue_find_item (data->queue, data->after_item, &index))
|
if (clapper_queue_find_item (CLAPPER_QUEUE_CAST (data->list),
|
||||||
|
CLAPPER_MEDIA_ITEM_CAST (data->after_item), &index)) {
|
||||||
index++;
|
index++;
|
||||||
else // If not found, just append at the end
|
} else {
|
||||||
index = -1;
|
index = -1; // if not found, just append at the end
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
index = 0;
|
index = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
clapper_queue_insert_item (data->queue, data->item, index);
|
clapper_queue_insert_item (CLAPPER_QUEUE_CAST (data->list),
|
||||||
|
CLAPPER_MEDIA_ITEM_CAST (data->item), index);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case CLAPPER_UTILS_QUEUE_ALTER_REMOVE:
|
case CLAPPER_UTILS_LIST_ALTER_QUEUE_REMOVE:
|
||||||
clapper_queue_remove_item (data->queue, data->item);
|
clapper_queue_remove_item (CLAPPER_QUEUE_CAST (data->list),
|
||||||
|
CLAPPER_MEDIA_ITEM_CAST (data->item));
|
||||||
break;
|
break;
|
||||||
case CLAPPER_UTILS_QUEUE_ALTER_CLEAR:
|
case CLAPPER_UTILS_LIST_ALTER_QUEUE_CLEAR:
|
||||||
clapper_queue_clear (data->queue);
|
clapper_queue_clear (CLAPPER_QUEUE_CAST (data->list));
|
||||||
|
break;
|
||||||
|
case CLAPPER_UTILS_LIST_ALTER_TIMELINE_INSERT:
|
||||||
|
clapper_timeline_insert_marker_internal (CLAPPER_TIMELINE_CAST (data->list),
|
||||||
|
CLAPPER_MARKER_CAST (data->item));
|
||||||
|
break;
|
||||||
|
case CLAPPER_UTILS_LIST_ALTER_TIMELINE_REMOVE:
|
||||||
|
clapper_timeline_remove_marker_internal (CLAPPER_TIMELINE_CAST (data->list),
|
||||||
|
CLAPPER_MARKER_CAST (data->item));
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
g_assert_not_reached ();
|
g_assert_not_reached ();
|
||||||
@@ -146,13 +161,13 @@ clapper_utils_prop_notify_on_main (ClapperUtilsPropNotifyData *data)
|
|||||||
}
|
}
|
||||||
|
|
||||||
static inline void
|
static inline void
|
||||||
clapper_utils_queue_alter_invoke_on_main_sync_take (ClapperUtilsQueueAlterData *data)
|
clapper_utils_list_alter_invoke_on_main_sync_take (ClapperUtilsListAlterData *data)
|
||||||
{
|
{
|
||||||
GST_DEBUG ("Invoking queue alter on main...");
|
GST_DEBUG ("Invoking queue alter on main...");
|
||||||
|
|
||||||
clapper_shared_utils_context_invoke_sync_full (g_main_context_default (),
|
clapper_shared_utils_context_invoke_sync_full (g_main_context_default (),
|
||||||
(GThreadFunc) clapper_utils_queue_alter_on_main, data,
|
(GThreadFunc) clapper_utils_list_alter_on_main, data,
|
||||||
(GDestroyNotify) clapper_utils_queue_alter_data_free);
|
(GDestroyNotify) clapper_utils_list_alter_data_free);
|
||||||
|
|
||||||
GST_DEBUG ("Queue alter invoke finished");
|
GST_DEBUG ("Queue alter invoke finished");
|
||||||
}
|
}
|
||||||
@@ -160,34 +175,56 @@ clapper_utils_queue_alter_invoke_on_main_sync_take (ClapperUtilsQueueAlterData *
|
|||||||
void
|
void
|
||||||
clapper_utils_queue_append_on_main_sync (ClapperQueue *queue, ClapperMediaItem *item)
|
clapper_utils_queue_append_on_main_sync (ClapperQueue *queue, ClapperMediaItem *item)
|
||||||
{
|
{
|
||||||
ClapperUtilsQueueAlterData *data = clapper_utils_queue_alter_data_new (queue,
|
ClapperUtilsListAlterData *data = clapper_utils_list_alter_data_new (
|
||||||
item, NULL, CLAPPER_UTILS_QUEUE_ALTER_APPEND);
|
(GListModel *) queue, (GObject *) item, NULL,
|
||||||
clapper_utils_queue_alter_invoke_on_main_sync_take (data);
|
CLAPPER_UTILS_LIST_ALTER_QUEUE_APPEND);
|
||||||
|
clapper_utils_list_alter_invoke_on_main_sync_take (data);
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
clapper_utils_queue_insert_on_main_sync (ClapperQueue *queue,
|
clapper_utils_queue_insert_on_main_sync (ClapperQueue *queue,
|
||||||
ClapperMediaItem *item, ClapperMediaItem *after_item)
|
ClapperMediaItem *item, ClapperMediaItem *after_item)
|
||||||
{
|
{
|
||||||
ClapperUtilsQueueAlterData *data = clapper_utils_queue_alter_data_new (queue,
|
ClapperUtilsListAlterData *data = clapper_utils_list_alter_data_new (
|
||||||
item, after_item, CLAPPER_UTILS_QUEUE_ALTER_INSERT);
|
(GListModel *) queue, (GObject *) item, (GObject *) after_item,
|
||||||
clapper_utils_queue_alter_invoke_on_main_sync_take (data);
|
CLAPPER_UTILS_LIST_ALTER_QUEUE_INSERT);
|
||||||
|
clapper_utils_list_alter_invoke_on_main_sync_take (data);
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
clapper_utils_queue_remove_on_main_sync (ClapperQueue *queue, ClapperMediaItem *item)
|
clapper_utils_queue_remove_on_main_sync (ClapperQueue *queue, ClapperMediaItem *item)
|
||||||
{
|
{
|
||||||
ClapperUtilsQueueAlterData *data = clapper_utils_queue_alter_data_new (queue,
|
ClapperUtilsListAlterData *data = clapper_utils_list_alter_data_new (
|
||||||
item, NULL, CLAPPER_UTILS_QUEUE_ALTER_REMOVE);
|
(GListModel *) queue, (GObject *) item, NULL,
|
||||||
clapper_utils_queue_alter_invoke_on_main_sync_take (data);
|
CLAPPER_UTILS_LIST_ALTER_QUEUE_REMOVE);
|
||||||
|
clapper_utils_list_alter_invoke_on_main_sync_take (data);
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
clapper_utils_queue_clear_on_main_sync (ClapperQueue *queue)
|
clapper_utils_queue_clear_on_main_sync (ClapperQueue *queue)
|
||||||
{
|
{
|
||||||
ClapperUtilsQueueAlterData *data = clapper_utils_queue_alter_data_new (queue,
|
ClapperUtilsListAlterData *data = clapper_utils_list_alter_data_new (
|
||||||
NULL, NULL, CLAPPER_UTILS_QUEUE_ALTER_CLEAR);
|
(GListModel *) queue, NULL, NULL,
|
||||||
clapper_utils_queue_alter_invoke_on_main_sync_take (data);
|
CLAPPER_UTILS_LIST_ALTER_QUEUE_CLEAR);
|
||||||
|
clapper_utils_list_alter_invoke_on_main_sync_take (data);
|
||||||
|
}
|
||||||
|
|
||||||
|
void
|
||||||
|
clapper_utils_timeline_insert_on_main_sync (ClapperTimeline *timeline, ClapperMarker *marker)
|
||||||
|
{
|
||||||
|
ClapperUtilsListAlterData *data = clapper_utils_list_alter_data_new (
|
||||||
|
(GListModel *) timeline, (GObject *) marker, NULL,
|
||||||
|
CLAPPER_UTILS_LIST_ALTER_TIMELINE_INSERT);
|
||||||
|
clapper_utils_list_alter_invoke_on_main_sync_take (data);
|
||||||
|
}
|
||||||
|
|
||||||
|
void
|
||||||
|
clapper_utils_timeline_remove_on_main_sync (ClapperTimeline *timeline, ClapperMarker *marker)
|
||||||
|
{
|
||||||
|
ClapperUtilsListAlterData *data = clapper_utils_list_alter_data_new (
|
||||||
|
(GListModel *) timeline, (GObject *) marker, NULL,
|
||||||
|
CLAPPER_UTILS_LIST_ALTER_TIMELINE_REMOVE);
|
||||||
|
clapper_utils_list_alter_invoke_on_main_sync_take (data);
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
@@ -23,6 +23,8 @@
|
|||||||
*
|
*
|
||||||
* Not every OS supports `MPRIS`. Use [const@Clapper.HAVE_MPRIS] macro
|
* Not every OS supports `MPRIS`. Use [const@Clapper.HAVE_MPRIS] macro
|
||||||
* to check if Clapper API was compiled with this feature.
|
* to check if Clapper API was compiled with this feature.
|
||||||
|
*
|
||||||
|
* Deprecated: 0.10: Use MPRIS from `clapper-enhancers` repo instead.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include "clapper-mpris.h"
|
#include "clapper-mpris.h"
|
||||||
@@ -1346,6 +1348,8 @@ clapper_mpris_property_changed (ClapperFeature *feature, GParamSpec *pspec)
|
|||||||
* Creates a new #ClapperMpris instance.
|
* Creates a new #ClapperMpris instance.
|
||||||
*
|
*
|
||||||
* Returns: (transfer full): a new #ClapperMpris instance.
|
* Returns: (transfer full): a new #ClapperMpris instance.
|
||||||
|
*
|
||||||
|
* Deprecated: 0.10: Use MPRIS from `clapper-enhancers` repo instead.
|
||||||
*/
|
*/
|
||||||
ClapperMpris *
|
ClapperMpris *
|
||||||
clapper_mpris_new (const gchar *own_name, const gchar *identity,
|
clapper_mpris_new (const gchar *own_name, const gchar *identity,
|
||||||
@@ -1376,6 +1380,8 @@ clapper_mpris_new (const gchar *own_name, const gchar *identity,
|
|||||||
*
|
*
|
||||||
* You probably want to keep this disabled if your application
|
* You probably want to keep this disabled if your application
|
||||||
* is supposed to manage what is played now and not MPRIS client.
|
* is supposed to manage what is played now and not MPRIS client.
|
||||||
|
*
|
||||||
|
* Deprecated: 0.10: Use MPRIS from `clapper-enhancers` repo instead.
|
||||||
*/
|
*/
|
||||||
void
|
void
|
||||||
clapper_mpris_set_queue_controllable (ClapperMpris *self, gboolean controllable)
|
clapper_mpris_set_queue_controllable (ClapperMpris *self, gboolean controllable)
|
||||||
@@ -1397,6 +1403,8 @@ clapper_mpris_set_queue_controllable (ClapperMpris *self, gboolean controllable)
|
|||||||
* Get whether remote `MPRIS` clients can control [class@Clapper.Queue].
|
* Get whether remote `MPRIS` clients can control [class@Clapper.Queue].
|
||||||
*
|
*
|
||||||
* Returns: %TRUE if control over #ClapperQueue is allowed, %FALSE otherwise.
|
* Returns: %TRUE if control over #ClapperQueue is allowed, %FALSE otherwise.
|
||||||
|
*
|
||||||
|
* Deprecated: 0.10: Use MPRIS from `clapper-enhancers` repo instead.
|
||||||
*/
|
*/
|
||||||
gboolean
|
gboolean
|
||||||
clapper_mpris_get_queue_controllable (ClapperMpris *self)
|
clapper_mpris_get_queue_controllable (ClapperMpris *self)
|
||||||
@@ -1412,6 +1420,8 @@ clapper_mpris_get_queue_controllable (ClapperMpris *self)
|
|||||||
* @art_url: (nullable): an art URL
|
* @art_url: (nullable): an art URL
|
||||||
*
|
*
|
||||||
* Set fallback artwork to show when media does not provide one.
|
* Set fallback artwork to show when media does not provide one.
|
||||||
|
*
|
||||||
|
* Deprecated: 0.10: Use MPRIS from `clapper-enhancers` repo instead.
|
||||||
*/
|
*/
|
||||||
void
|
void
|
||||||
clapper_mpris_set_fallback_art_url (ClapperMpris *self, const gchar *art_url)
|
clapper_mpris_set_fallback_art_url (ClapperMpris *self, const gchar *art_url)
|
||||||
@@ -1435,6 +1445,8 @@ clapper_mpris_set_fallback_art_url (ClapperMpris *self, const gchar *art_url)
|
|||||||
* Get fallback art URL earlier set by user.
|
* Get fallback art URL earlier set by user.
|
||||||
*
|
*
|
||||||
* Returns: (transfer full) (nullable): fallback art URL.
|
* Returns: (transfer full) (nullable): fallback art URL.
|
||||||
|
*
|
||||||
|
* Deprecated: 0.10: Use MPRIS from `clapper-enhancers` repo instead.
|
||||||
*/
|
*/
|
||||||
gchar *
|
gchar *
|
||||||
clapper_mpris_get_fallback_art_url (ClapperMpris *self)
|
clapper_mpris_get_fallback_art_url (ClapperMpris *self)
|
||||||
@@ -1611,6 +1623,8 @@ clapper_mpris_class_init (ClapperMprisClass *klass)
|
|||||||
* Each #ClapperMpris instance running on the same system must have an unique name.
|
* Each #ClapperMpris instance running on the same system must have an unique name.
|
||||||
*
|
*
|
||||||
* Example: "org.mpris.MediaPlayer2.MyPlayer.instance123"
|
* Example: "org.mpris.MediaPlayer2.MyPlayer.instance123"
|
||||||
|
*
|
||||||
|
* Deprecated: 0.10: Use MPRIS from `clapper-enhancers` repo instead.
|
||||||
*/
|
*/
|
||||||
param_specs[PROP_OWN_NAME] = g_param_spec_string ("own-name",
|
param_specs[PROP_OWN_NAME] = g_param_spec_string ("own-name",
|
||||||
NULL, NULL, NULL,
|
NULL, NULL, NULL,
|
||||||
@@ -1622,6 +1636,8 @@ clapper_mpris_class_init (ClapperMprisClass *klass)
|
|||||||
* A friendly name to identify the media player.
|
* A friendly name to identify the media player.
|
||||||
*
|
*
|
||||||
* Example: "My Player"
|
* Example: "My Player"
|
||||||
|
*
|
||||||
|
* Deprecated: 0.10: Use MPRIS from `clapper-enhancers` repo instead.
|
||||||
*/
|
*/
|
||||||
param_specs[PROP_IDENTITY] = g_param_spec_string ("identity",
|
param_specs[PROP_IDENTITY] = g_param_spec_string ("identity",
|
||||||
NULL, NULL, NULL,
|
NULL, NULL, NULL,
|
||||||
@@ -1631,6 +1647,8 @@ clapper_mpris_class_init (ClapperMprisClass *klass)
|
|||||||
* ClapperMpris:desktop-entry:
|
* ClapperMpris:desktop-entry:
|
||||||
*
|
*
|
||||||
* The basename of an installed .desktop file with the ".desktop" extension stripped.
|
* The basename of an installed .desktop file with the ".desktop" extension stripped.
|
||||||
|
*
|
||||||
|
* Deprecated: 0.10: Use MPRIS from `clapper-enhancers` repo instead.
|
||||||
*/
|
*/
|
||||||
param_specs[PROP_DESKTOP_ENTRY] = g_param_spec_string ("desktop-entry",
|
param_specs[PROP_DESKTOP_ENTRY] = g_param_spec_string ("desktop-entry",
|
||||||
NULL, NULL, NULL,
|
NULL, NULL, NULL,
|
||||||
@@ -1640,6 +1658,8 @@ clapper_mpris_class_init (ClapperMprisClass *klass)
|
|||||||
* ClapperMpris:queue-controllable:
|
* ClapperMpris:queue-controllable:
|
||||||
*
|
*
|
||||||
* Whether remote MPRIS clients can control #ClapperQueue.
|
* Whether remote MPRIS clients can control #ClapperQueue.
|
||||||
|
*
|
||||||
|
* Deprecated: 0.10: Use MPRIS from `clapper-enhancers` repo instead.
|
||||||
*/
|
*/
|
||||||
param_specs[PROP_QUEUE_CONTROLLABLE] = g_param_spec_boolean ("queue-controllable",
|
param_specs[PROP_QUEUE_CONTROLLABLE] = g_param_spec_boolean ("queue-controllable",
|
||||||
NULL, NULL, DEFAULT_QUEUE_CONTROLLABLE,
|
NULL, NULL, DEFAULT_QUEUE_CONTROLLABLE,
|
||||||
@@ -1649,6 +1669,8 @@ clapper_mpris_class_init (ClapperMprisClass *klass)
|
|||||||
* ClapperMpris:fallback-art-url:
|
* ClapperMpris:fallback-art-url:
|
||||||
*
|
*
|
||||||
* Fallback artwork to show when media does not provide one.
|
* Fallback artwork to show when media does not provide one.
|
||||||
|
*
|
||||||
|
* Deprecated: 0.10: Use MPRIS from `clapper-enhancers` repo instead.
|
||||||
*/
|
*/
|
||||||
param_specs[PROP_FALLBACK_ART_URL] = g_param_spec_string ("fallback-art-url",
|
param_specs[PROP_FALLBACK_ART_URL] = g_param_spec_string ("fallback-art-url",
|
||||||
NULL, NULL, NULL,
|
NULL, NULL, NULL,
|
||||||
|
@@ -34,22 +34,22 @@ G_BEGIN_DECLS
|
|||||||
#define CLAPPER_TYPE_MPRIS (clapper_mpris_get_type())
|
#define CLAPPER_TYPE_MPRIS (clapper_mpris_get_type())
|
||||||
#define CLAPPER_MPRIS_CAST(obj) ((ClapperMpris *)(obj))
|
#define CLAPPER_MPRIS_CAST(obj) ((ClapperMpris *)(obj))
|
||||||
|
|
||||||
CLAPPER_API
|
CLAPPER_DEPRECATED
|
||||||
G_DECLARE_FINAL_TYPE (ClapperMpris, clapper_mpris, CLAPPER, MPRIS, ClapperFeature)
|
G_DECLARE_FINAL_TYPE (ClapperMpris, clapper_mpris, CLAPPER, MPRIS, ClapperFeature)
|
||||||
|
|
||||||
CLAPPER_API
|
CLAPPER_DEPRECATED
|
||||||
ClapperMpris * clapper_mpris_new (const gchar *own_name, const gchar *identity, const gchar *desktop_entry);
|
ClapperMpris * clapper_mpris_new (const gchar *own_name, const gchar *identity, const gchar *desktop_entry);
|
||||||
|
|
||||||
CLAPPER_API
|
CLAPPER_DEPRECATED
|
||||||
void clapper_mpris_set_queue_controllable (ClapperMpris *mpris, gboolean controllable);
|
void clapper_mpris_set_queue_controllable (ClapperMpris *mpris, gboolean controllable);
|
||||||
|
|
||||||
CLAPPER_API
|
CLAPPER_DEPRECATED
|
||||||
gboolean clapper_mpris_get_queue_controllable (ClapperMpris *mpris);
|
gboolean clapper_mpris_get_queue_controllable (ClapperMpris *mpris);
|
||||||
|
|
||||||
CLAPPER_API
|
CLAPPER_DEPRECATED
|
||||||
void clapper_mpris_set_fallback_art_url (ClapperMpris *mpris, const gchar *art_url);
|
void clapper_mpris_set_fallback_art_url (ClapperMpris *mpris, const gchar *art_url);
|
||||||
|
|
||||||
CLAPPER_API
|
CLAPPER_DEPRECATED
|
||||||
gchar * clapper_mpris_get_fallback_art_url (ClapperMpris *mpris);
|
gchar * clapper_mpris_get_fallback_art_url (ClapperMpris *mpris);
|
||||||
|
|
||||||
G_END_DECLS
|
G_END_DECLS
|
||||||
|
Reference in New Issue
Block a user