aboutsummaryrefslogtreecommitdiff
path: root/src/experiment-player.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/experiment-player.h')
-rw-r--r--src/experiment-player.h15
1 files changed, 15 insertions, 0 deletions
diff --git a/src/experiment-player.h b/src/experiment-player.h
index a8f6e87..a7cda8a 100644
--- a/src/experiment-player.h
+++ b/src/experiment-player.h
@@ -1,6 +1,9 @@
#ifndef __EXPERIMENT_PLAYER_H
#define __EXPERIMENT_PLAYER_H
+#include <glib.h>
+#include <glib/gprintf.h>
+
#include <gtk/gtk.h>
gboolean load_media_file(const gchar *file);
@@ -40,4 +43,16 @@ extern GtkWidget *transcript_wizard_combo,
VAR = GTK_WIDGET(gtk_builder_get_object(BUILDER, #VAR)); \
} while (0)
+static inline gchar *
+path_strip_extension(const gchar *filename)
+{
+ gchar *ret = g_strdup(filename);
+ gchar *p;
+
+ if ((p = g_strrstr(ret, ".")) != NULL)
+ *p = '\0';
+
+ return ret;
+}
+
#endif \ No newline at end of file