[rygel-grilo] Move properties to a different header file
- From: Juan A. Suarez Romero <jasuarez src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [rygel-grilo] Move properties to a different header file
- Date: Tue, 13 Apr 2010 09:33:22 +0000 (UTC)
commit 7d585c245e90a0205262b102276f509bf6a7111f
Author: Juan A. Suarez Romero <jasuarez igalia com>
Date: Fri Apr 9 12:46:25 2010 +0200
Move properties to a different header file
This header file will be shared by client and server parts.
lib/Makefile.am | 1 +
lib/media-server2-common.h | 77 ++++++++++++++++++++++++++++++++++++++++++++
lib/media-server2-server.h | 55 ++-----------------------------
3 files changed, 82 insertions(+), 51 deletions(-)
---
diff --git a/lib/Makefile.am b/lib/Makefile.am
index 39e886f..df717cd 100644
--- a/lib/Makefile.am
+++ b/lib/Makefile.am
@@ -30,6 +30,7 @@ libmediaserver2_la_LIBADD = \
$(DEPS_LIBS)
libmediaserver2_la_SOURCES = \
+ media-server2-common.h \
media-server2-server-glue.h \
media-server2-server-private.h \
media-server2-server.h \
diff --git a/lib/media-server2-common.h b/lib/media-server2-common.h
new file mode 100644
index 0000000..be7e6df
--- /dev/null
+++ b/lib/media-server2-common.h
@@ -0,0 +1,77 @@
+/*
+ * Copyright (C) 2010 Igalia S.L.
+ *
+ * Authors: Juan A. Suarez Romero <jasuarez igalia com>
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA
+ *
+ */
+
+#ifndef _MEDIA_SERVER2_COMMON_H_
+#define _MEDIA_SERVER2_COMMON_H_
+
+/* Common properties */
+#define MS2_PROP_ID "id"
+#define MS2_PROP_PARENT "parent"
+#define MS2_PROP_DISPLAY_NAME "display-name"
+#define MS2_PROP_TYPE "type"
+
+/* Container properties */
+#define MS2_PROP_CHILD_COUNT "child-count"
+#define MS2_PROP_ICON "icon"
+
+/* Item properties */
+#define MS2_PROP_URLS "URLs"
+#define MS2_PROP_MIME_TYPE "mime-type"
+#define MS2_PROP_SIZE "size"
+#define MS2_PROP_ARTIST "artist"
+#define MS2_PROP_ALBUM "album"
+#define MS2_PROP_DATE "date"
+#define MS2_PROP_DLNA_PROFILE "dlna-profile"
+
+/* Audio/Video items properties */
+#define MS2_PROP_DURATION "duration"
+#define MS2_PROP_BITRATE "bitrate"
+#define MS2_PROP_SAMPLE_RATE "sample-rate"
+#define MS2_PROP_BITS_PER_SAMPLE "bits-per-sample"
+
+/* Video/Image items properties */
+#define MS2_PROP_WIDTH "width"
+#define MS2_PROP_HEIGHT "height"
+#define MS2_PROP_COLOR_DEPTH "depth"
+#define MS2_PROP_PIXEL_WIDTH "pixel-width"
+#define MS2_PROP_PIXEL_HEIGHT "pixel-height"
+#define MS2_PROP_THUMBNAIL "thumbnail"
+
+/* Audio items properties */
+#define MS2_PROP_GENRE "genre"
+
+/* Type items */
+#define MS2_TYPE_CONTAINER "container"
+#define MS2_TYPE_VIDEO "video"
+#define MS2_TYPE_MOVIE "video.movie"
+#define MS2_TYPE_AUDIO "audio"
+#define MS2_TYPE_MUSIC "audio.music"
+#define MS2_TYPE_IMAGE "image"
+#define MS2_TYPE_PHOTO "image.photo"
+
+/* Unknown values */
+#define MS2_UNKNOWN_INT -1
+#define MS2_UNKNOWN_STR ""
+
+#endif /* _MEDIA_SERVER2_COMMON_H_ */
+
+
diff --git a/lib/media-server2-server.h b/lib/media-server2-server.h
index 3768751..bd7ada3 100644
--- a/lib/media-server2-server.h
+++ b/lib/media-server2-server.h
@@ -20,60 +20,13 @@
*
*/
-#ifndef _MEDIA_SERVER2_H_
-#define _MEDIA_SERVER2_H_
+#ifndef _MEDIA_SERVER2_SERVER_H_
+#define _MEDIA_SERVER2_SERVER_H_
#include <glib.h>
#include <glib-object.h>
-/* Common properties */
-#define MS2_PROP_ID "id"
-#define MS2_PROP_PARENT "parent"
-#define MS2_PROP_DISPLAY_NAME "display-name"
-#define MS2_PROP_TYPE "type"
-
-/* Container properties */
-#define MS2_PROP_CHILD_COUNT "child-count"
-#define MS2_PROP_ICON "icon"
-
-/* Item properties */
-#define MS2_PROP_URLS "URLs"
-#define MS2_PROP_MIME_TYPE "mime-type"
-#define MS2_PROP_SIZE "size"
-#define MS2_PROP_ARTIST "artist"
-#define MS2_PROP_ALBUM "album"
-#define MS2_PROP_DATE "date"
-#define MS2_PROP_DLNA_PROFILE "dlna-profile"
-
-/* Audio/Video items properties */
-#define MS2_PROP_DURATION "duration"
-#define MS2_PROP_BITRATE "bitrate"
-#define MS2_PROP_SAMPLE_RATE "sample-rate"
-#define MS2_PROP_BITS_PER_SAMPLE "bits-per-sample"
-
-/* Video/Image items properties */
-#define MS2_PROP_WIDTH "width"
-#define MS2_PROP_HEIGHT "height"
-#define MS2_PROP_COLOR_DEPTH "depth"
-#define MS2_PROP_PIXEL_WIDTH "pixel-width"
-#define MS2_PROP_PIXEL_HEIGHT "pixel-height"
-#define MS2_PROP_THUMBNAIL "thumbnail"
-
-/* Audio items properties */
-#define MS2_PROP_GENRE "genre"
-
-/* Type items */
-#define MS2_TYPE_CONTAINER "container"
-#define MS2_TYPE_VIDEO "video"
-#define MS2_TYPE_MOVIE "video.movie"
-#define MS2_TYPE_AUDIO "audio"
-#define MS2_TYPE_MUSIC "audio.music"
-#define MS2_TYPE_IMAGE "image"
-#define MS2_TYPE_PHOTO "image.photo"
-
-/* Unknown values */
-#define MS2_UNKNOWN_INT -1
-#define MS2_UNKNOWN_STR ""
+#include "media-server2-common.h"
#define MEDIA_SERVER2_ERROR \
g_quark_from_static_string("media_server2_error")
@@ -228,4 +181,4 @@ void media_server2_set_pixel_height (GHashTable *properties,
void media_server2_set_urls (GHashTable *properties,
gchar **urls);
-#endif /* _MEDIA_SERVER2_H_ */
+#endif /* _MEDIA_SERVER2_SERVER_H_ */
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]