[gnome-games] collection: Introduce Collection
- From: Alexander Mikhaylenko <alexm src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-games] collection: Introduce Collection
- Date: Thu, 16 Jul 2020 14:49:52 +0000 (UTC)
commit 610c26cfb1d02c1852b13358c12e16be54ea4de8
Author: Neville <nevilleantony98 gmail com>
Date: Thu Jun 18 20:40:08 2020 +0530
collection: Introduce Collection
This will provide a common interface for several different types of
collections which will be introduced later on.
src/collection/collection.vala | 25 +++++++++++++++++++++++++
src/meson.build | 2 ++
2 files changed, 27 insertions(+)
---
diff --git a/src/collection/collection.vala b/src/collection/collection.vala
new file mode 100644
index 00000000..73b692b4
--- /dev/null
+++ b/src/collection/collection.vala
@@ -0,0 +1,25 @@
+// This file is part of GNOME Games. License: GPL-3.0+.
+
+private interface Games.Collection : Object {
+ public signal void games_changed ();
+
+ public abstract void load ();
+
+ public abstract string get_id ();
+
+ public abstract string get_title ();
+
+ public abstract bool get_hide_stars ();
+
+ public abstract GameModel get_game_model ();
+
+ public abstract void add_games (Game[] games);
+
+ public abstract void remove_games (Game[] games);
+
+ public abstract void on_game_added (Game game);
+
+ public abstract void on_game_removed (Game game);
+
+ public abstract void on_game_replaced (Game game, Game prev_game);
+}
diff --git a/src/meson.build b/src/meson.build
index 4cb22389..edc9ac0f 100644
--- a/src/meson.build
+++ b/src/meson.build
@@ -11,6 +11,8 @@ c_args = [
]
vala_sources = [
+ 'collection/collection.vala',
+
'command/command-error.vala',
'command/command-runner.vala',
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]