[gnome-games] Add MediaSet property to Runner
- From: Adrien Plazas <aplazas src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-games] Add MediaSet property to Runner
- Date: Fri, 19 Aug 2016 21:09:30 +0000 (UTC)
commit 1c5a317b8a7efa572a4950a1fc52ade92d803717
Author: Ricard Gascons <gascons1995 gmail com>
Date: Thu Aug 18 16:53:30 2016 +0200
Add MediaSet property to Runner
This commit adds the MediaSet property to the Runner interface to be
used by subsequent commits.
This is part of a series of commits to add multi-source support.
src/command/command-runner.vala | 4 ++++
src/core/runner.vala | 1 +
src/dummy/dummy-runner.vala | 4 ++++
src/retro/retro-runner.vala | 5 +++++
4 files changed, 14 insertions(+), 0 deletions(-)
---
diff --git a/src/command/command-runner.vala b/src/command/command-runner.vala
index 1cd310a..a96ff14 100644
--- a/src/command/command-runner.vala
+++ b/src/command/command-runner.vala
@@ -13,6 +13,10 @@ public class Games.CommandRunner : Object, Runner {
get { return false; }
}
+ public MediaSet? media_set {
+ get { return null; }
+ }
+
private string[] args;
private bool watch_child;
diff --git a/src/core/runner.vala b/src/core/runner.vala
index 50f0e90..c9684ca 100644
--- a/src/core/runner.vala
+++ b/src/core/runner.vala
@@ -6,6 +6,7 @@ public interface Games.Runner : Object {
public abstract bool can_fullscreen { get; }
public abstract bool can_quit_safely { get; }
public abstract bool can_resume { get; }
+ public abstract MediaSet? media_set { get; }
public abstract void check_is_valid () throws Error;
public abstract Gtk.Widget get_display ();
diff --git a/src/dummy/dummy-runner.vala b/src/dummy/dummy-runner.vala
index 89cc0d5..579e89d 100644
--- a/src/dummy/dummy-runner.vala
+++ b/src/dummy/dummy-runner.vala
@@ -13,6 +13,10 @@ private class Games.DummyRunner : Object, Runner {
get { return false; }
}
+ public MediaSet? media_set {
+ get { return null; }
+ }
+
public void check_is_valid () throws Error {
}
diff --git a/src/retro/retro-runner.vala b/src/retro/retro-runner.vala
index 3263001..26e4d5a 100644
--- a/src/retro/retro-runner.vala
+++ b/src/retro/retro-runner.vala
@@ -28,6 +28,11 @@ public class Games.RetroRunner : Object, Runner {
}
}
+ private MediaSet _media_set;
+ public MediaSet? media_set {
+ get { return _media_set; }
+ }
+
private Retro.Core core;
private RetroGtk.CairoDisplay video;
private RetroGtk.PaPlayer audio;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]