[gnome-games] retro: Deinit RetroRunner on destruction
- From: Adrien Plazas <aplazas src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-games] retro: Deinit RetroRunner on destruction
- Date: Thu, 18 May 2017 13:05:03 +0000 (UTC)
commit 9c40b4a52bd2e3351ff0b88adb6be05dfcb4ef99
Author: Adrien Plazas <kekun plazas laposte net>
Date: Thu May 18 08:40:53 2017 +0200
retro: Deinit RetroRunner on destruction
This helps ensuring we unload the game, deinit the core, and by
extension that cores saving on unload save as expected.
https://bugzilla.gnome.org/show_bug.cgi?id=782772
src/retro/retro-runner.vala | 14 ++------------
1 files changed, 2 insertions(+), 12 deletions(-)
---
diff --git a/src/retro/retro-runner.vala b/src/retro/retro-runner.vala
index 3d3acb5..d63c0b2 100644
--- a/src/retro/retro-runner.vala
+++ b/src/retro/retro-runner.vala
@@ -120,18 +120,8 @@ public class Games.RetroRunner : Object, Runner {
}
~RetroRunner () {
- if (!is_initialized)
- return;
-
- loop.stop ();
- running = false;
-
- try {
- save ();
- }
- catch (Error e) {
- warning (e.message);
- }
+ pause ();
+ deinit ();
}
public bool check_is_valid (out string error_message) throws Error {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]