[retro-gtk/wip/aplazas/c-port: 18/25] Merge CbError into CoreError
- From: Adrien Plazas <aplazas src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [retro-gtk/wip/aplazas/c-port: 18/25] Merge CbError into CoreError
- Date: Tue, 10 Oct 2017 16:40:20 +0000 (UTC)
commit e154ac020d59673798d729504214d42dab803ed2
Author: Adrien Plazas <kekun plazas laposte net>
Date: Mon Sep 25 13:28:53 2017 +0200
Merge CbError into CoreError
retro-gtk/retro-core.c | 21 +++++++++++----------
retro-gtk/retro.vala | 9 ---------
2 files changed, 11 insertions(+), 19 deletions(-)
---
diff --git a/retro-gtk/retro-core.c b/retro-gtk/retro-core.c
index 19b102c..1c8fff1 100644
--- a/retro-gtk/retro-core.c
+++ b/retro-gtk/retro-core.c
@@ -12,6 +12,7 @@ enum {
RETRO_CORE_ERROR_COULDNT_SERIALIZE,
RETRO_CORE_ERROR_COULDNT_DESERIALIZE,
RETRO_CORE_ERROR_SERIALIZATION_NOT_SUPPORTED,
+ RETRO_CORE_ERROR_NO_CALLBACK,
};
/* Private */
@@ -244,8 +245,8 @@ retro_core_set_disk_ejected (RetroCore *self,
if (set_eject_state == NULL) {
g_set_error_literal (error,
- RETRO_CB_ERROR,
- RETRO_CB_ERROR_NO_CALLBACK,
+ RETRO_CORE_ERROR,
+ RETRO_CORE_ERROR_NO_CALLBACK,
"DiskControl has no callback for this operation.");
return FALSE;
@@ -275,8 +276,8 @@ retro_core_set_disk_image_index (RetroCore *self,
if (set_image_index == NULL) {
g_set_error_literal (error,
- RETRO_CB_ERROR,
- RETRO_CB_ERROR_NO_CALLBACK,
+ RETRO_CORE_ERROR,
+ RETRO_CORE_ERROR_NO_CALLBACK,
"DiskControl has no callback for this operation.");
return FALSE;
@@ -305,8 +306,8 @@ retro_core_get_disk_images_number (RetroCore *self,
if (get_num_images == NULL) {
g_set_error_literal (error,
- RETRO_CB_ERROR,
- RETRO_CB_ERROR_NO_CALLBACK,
+ RETRO_CORE_ERROR,
+ RETRO_CORE_ERROR_NO_CALLBACK,
"DiskControl has no callback for this operation.");
return FALSE;
@@ -337,8 +338,8 @@ retro_core_replace_disk_image_index (RetroCore *self,
if (replace_image_index == NULL) {
g_set_error_literal (error,
- RETRO_CB_ERROR,
- RETRO_CB_ERROR_NO_CALLBACK,
+ RETRO_CORE_ERROR,
+ RETRO_CORE_ERROR_NO_CALLBACK,
"DiskControl has no callback for this operation.");
return FALSE;
@@ -367,8 +368,8 @@ retro_core_add_disk_image_index (RetroCore *self,
if (add_image_index == NULL) {
g_set_error_literal (error,
- RETRO_CB_ERROR,
- RETRO_CB_ERROR_NO_CALLBACK,
+ RETRO_CORE_ERROR,
+ RETRO_CORE_ERROR_NO_CALLBACK,
"DiskControl has no callback for this operation.");
return FALSE;
diff --git a/retro-gtk/retro.vala b/retro-gtk/retro.vala
index 2d77e8e..559b41e 100644
--- a/retro-gtk/retro.vala
+++ b/retro-gtk/retro.vala
@@ -10,14 +10,5 @@ public const uint API_VERSION = 1;
private const string ENV_PLUGIN_PATH = "RETRO_PLUGIN_PATH_1_0";
-/**
- * Error type thrown by interfaces when accessing one of their Core's
- * callback.
- */
-private errordomain CbError {
- NO_CORE,
- NO_CALLBACK
-}
-
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]