[gnome-games/wip/abhinavsingh/gamepad-config: 18/23] gamepad: Add GamepadMappingsManager vapi



commit ab5b782d04535485927ed106cbb1faff1a821525
Author: theawless <theawless gmail com>
Date:   Wed Jun 21 05:27:08 2017 +0530

    gamepad: Add GamepadMappingsManager vapi
    
    This will be used to save the sdl_string using vala code.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=780754

 src/Makefile.am                           |    2 ++
 src/gamepad/gamepad-mappings-manager.vapi |    9 +++++++++
 2 files changed, 11 insertions(+), 0 deletions(-)
---
diff --git a/src/Makefile.am b/src/Makefile.am
index 4a59176..40def28 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -29,6 +29,7 @@ EXTRA_DIST = \
        gamepad/gamepad-dpad.vapi \
        gamepad/gamepad-input.vapi \
        gamepad/gamepad-mapping.vapi \
+       gamepad/gamepad-mappings-manager.vapi \
        gamepad/gamepad-monitor.vapi \
        gamepad/raw-gamepad.vapi \
        $(NULL)
@@ -204,6 +205,7 @@ gnome_games_VALAFLAGS = \
        --pkg gamepad-dpad \
        --pkg gamepad-input \
        --pkg gamepad-mapping \
+       --pkg gamepad-mappings-manager \
        --pkg gamepad-monitor \
        --pkg raw-gamepad \
        --gresources $(gresource_file) \
diff --git a/src/gamepad/gamepad-mappings-manager.vapi b/src/gamepad/gamepad-mappings-manager.vapi
new file mode 100644
index 0000000..6119e34
--- /dev/null
+++ b/src/gamepad/gamepad-mappings-manager.vapi
@@ -0,0 +1,9 @@
+// This file is part of GNOME Games. License: GPL-3.0+.
+
+[CCode (cheader_filename = "gamepad-mappings-manager.h")]
+private class Games.GamepadMappingsManager : GLib.Object {
+       public static GamepadMappingsManager get_instance ();
+       public string? get_mapping (string guid);
+       public string? get_default_mapping (string guid);
+       public void save_mapping (string guid, string name, string mapping_string);
+}
\ No newline at end of file


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]