[retro-gtk/wip/aplazas/0.13: 26/33] Port MemoryType to C
- From: Adrien Plazas <aplazas src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [retro-gtk/wip/aplazas/0.13: 26/33] Port MemoryType to C
- Date: Sat, 23 Sep 2017 10:43:24 +0000 (UTC)
commit 4757a38802d210307ada53074765edb12731b761
Author: Adrien Plazas <kekun plazas laposte net>
Date: Thu Sep 7 11:33:01 2017 +0200
Port MemoryType to C
retro-gtk/Makefile.am | 2 +-
retro-gtk/memory.vala | 16 ----------------
retro-gtk/retro-gtk.h | 1 +
retro-gtk/retro-memory-type.h | 29 +++++++++++++++++++++++++++++
retro-gtk/vapi/retro-gtk-c.vapi | 8 ++++++++
5 files changed, 39 insertions(+), 17 deletions(-)
---
diff --git a/retro-gtk/Makefile.am b/retro-gtk/Makefile.am
index 4646e97..f5faa25 100644
--- a/retro-gtk/Makefile.am
+++ b/retro-gtk/Makefile.am
@@ -37,7 +37,6 @@ libretro_gtk_la_SOURCES = \
\
core.vala \
core-error.vala \
- memory.vala \
retro.vala \
retro-cairo-display.c \
retro-core-descriptor.vala \
@@ -117,6 +116,7 @@ retro_gtkinclude_HEADERS = \
retro-input-device.h \
retro-joypad-id.h \
retro-lightgun-id.h \
+ retro-memory-type.h \
retro-mouse-id.h \
retro-option.h \
retro-options.h \
diff --git a/retro-gtk/retro-gtk.h b/retro-gtk/retro-gtk.h
index b249b6a..b384f6a 100644
--- a/retro-gtk/retro-gtk.h
+++ b/retro-gtk/retro-gtk.h
@@ -16,6 +16,7 @@
#include "retro-input-device.h"
#include "retro-joypad-id.h"
#include "retro-lightgun-id.h"
+#include "retro-memory-type.h"
#include "retro-mouse-id.h"
#include "retro-pixel-format.h"
#include "retro-pointer-id.h"
diff --git a/retro-gtk/retro-memory-type.h b/retro-gtk/retro-memory-type.h
new file mode 100644
index 0000000..ce38842
--- /dev/null
+++ b/retro-gtk/retro-memory-type.h
@@ -0,0 +1,29 @@
+// This file is part of retro-gtk. License: GPL-3.0+.
+
+#ifndef RETRO_MEMORY_TYPE_H
+#define RETRO_MEMORY_TYPE_H
+
+#include <glib.h>
+
+G_BEGIN_DECLS
+
+/**
+ * RetroMemoryType:
+ * @RETRO_MEMORY_TYPE_SAVE_RAM: The save RAM.
+ * @RETRO_MEMORY_TYPE_RTC: The real time clock.
+ * @RETRO_MEMORY_TYPE_SYSTEM_RAM: The system RAM.
+ * @RETRO_MEMORY_TYPE_VIDEO_RAM: The video RAM.
+ *
+ * Represents the memory types for the Libretro core.
+ */
+typedef enum
+{
+ RETRO_MEMORY_TYPE_SAVE_RAM,
+ RETRO_MEMORY_TYPE_RTC,
+ RETRO_MEMORY_TYPE_SYSTEM_RAM,
+ RETRO_MEMORY_TYPE_VIDEO_RAM,
+} RetroMemoryType;
+
+G_END_DECLS
+
+#endif /* RETRO_MEMORY_TYPE_H */
diff --git a/retro-gtk/vapi/retro-gtk-c.vapi b/retro-gtk/vapi/retro-gtk-c.vapi
index 1d548e2..bf0ea78 100644
--- a/retro-gtk/vapi/retro-gtk-c.vapi
+++ b/retro-gtk/vapi/retro-gtk-c.vapi
@@ -12,6 +12,14 @@ public enum Retro.DeviceType {
POINTER = 6,
}
+[CCode (cheader_filename = "retro-memory-type.h")]
+public enum Retro.MemoryType {
+ SAVE_RAM,
+ RTC,
+ SYSTEM_RAM,
+ VIDEO_RAM,
+}
+
[CCode (cheader_filename = "retro-pixel-format.h")]
public enum Retro.PixelFormat {
XRGB1555,
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]