[gnome-flashback] input-settings: initial version
- From: Alberts Muktupāvels <muktupavels src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-flashback] input-settings: initial version
- Date: Fri, 10 Jun 2016 21:18:50 +0000 (UTC)
commit 3eb611abe7b6adba8943f1591ebc28fd3eb2f426
Author: Alberts Muktupāvels <alberts muktupavels gmail com>
Date: Fri Jun 10 18:48:14 2016 +0300
input-settings: initial version
configure.ac | 8 +++-
data/schemas/org.gnome.gnome-flashback.gschema.xml | 5 ++
gnome-flashback/Makefile.am | 2 +
gnome-flashback/gf-application.c | 3 +
gnome-flashback/libinput-settings/Makefile.am | 32 +++++++++++++++
.../libinput-settings/gf-input-settings.c | 43 ++++++++++++++++++++
.../libinput-settings/gf-input-settings.h | 33 +++++++++++++++
7 files changed, 125 insertions(+), 1 deletions(-)
---
diff --git a/configure.ac b/configure.ac
index cc50f63..f579814 100644
--- a/configure.ac
+++ b/configure.ac
@@ -110,7 +110,7 @@ GTK_REQUIRED=3.19.5
LIBGNOME_DESKTOP_REQUIRED=3.12.0
CANBERRA_REQUIRED=0.13
GLIB_REQUIRED=2.44.0
-GSETTINGS_DESKTOP_SCHEMAS_REQUIRED=3.12.0
+GSETTINGS_DESKTOP_SCHEMAS_REQUIRED=3.19.3
POLKIT_AGENT_REQUIRED=0.97
POLKIT_GOBJECT_REQUIRED=0.97
IBUS_REQUIRED=1.5.2
@@ -167,6 +167,11 @@ PKG_CHECK_MODULES([IDLE_MONITOR], [
xext
])
+PKG_CHECK_MODULES([INPUT_SETTINGS], [
+ gtk+-3.0 >= $GTK_REQUIRED
+ gsettings-desktop-schemas >= $GSETTINGS_DESKTOP_SCHEMAS_REQUIRED
+])
+
PKG_CHECK_MODULES([INPUT_SOURCES], [
gnome-desktop-3.0 >= $LIBGNOME_DESKTOP_REQUIRED
gtk+-3.0 >= $GTK_REQUIRED
@@ -293,6 +298,7 @@ AC_CONFIG_FILES([
gnome-flashback/libdisplay-config/Makefile
gnome-flashback/libend-session-dialog/Makefile
gnome-flashback/libidle-monitor/Makefile
+ gnome-flashback/libinput-settings/Makefile
gnome-flashback/libinput-sources/Makefile
gnome-flashback/libnotifications/Makefile
gnome-flashback/libpolkit/Makefile
diff --git a/data/schemas/org.gnome.gnome-flashback.gschema.xml
b/data/schemas/org.gnome.gnome-flashback.gschema.xml
index 3598757..9aa4e11 100644
--- a/data/schemas/org.gnome.gnome-flashback.gschema.xml
+++ b/data/schemas/org.gnome.gnome-flashback.gschema.xml
@@ -43,6 +43,11 @@
<description>If set to true, then GNOME Flashback application will be used for user activity
monitoring.</description>
</key>
+ <key name="input-settings" type="b">
+ <default>true</default>
+ <summary>Input settings</summary>
+ </key>
+
<key name="input-sources" type="b">
<default>true</default>
<summary>Keyboard layouts and input methods</summary>
diff --git a/gnome-flashback/Makefile.am b/gnome-flashback/Makefile.am
index 4b783d9..090bab1 100644
--- a/gnome-flashback/Makefile.am
+++ b/gnome-flashback/Makefile.am
@@ -9,6 +9,7 @@ SUBDIRS = \
libdisplay-config \
libend-session-dialog \
libidle-monitor \
+ libinput-settings \
libinput-sources \
libnotifications \
libpolkit \
@@ -60,6 +61,7 @@ gnome_flashback_LDADD = \
$(top_builddir)/gnome-flashback/libdisplay-config/libdisplay-config.la \
$(top_builddir)/gnome-flashback/libend-session-dialog/libend-session-dialog.la \
$(top_builddir)/gnome-flashback/libidle-monitor/libidle-monitor.la \
+ $(top_builddir)/gnome-flashback/libinput-settings/libinput-settings.la \
$(top_builddir)/gnome-flashback/libinput-sources/libinput-sources.la \
$(top_builddir)/gnome-flashback/libnotifications/libnotifications.la \
$(top_builddir)/gnome-flashback/libpolkit/libpolkit.la \
diff --git a/gnome-flashback/gf-application.c b/gnome-flashback/gf-application.c
index 6ba338e..dee0d09 100644
--- a/gnome-flashback/gf-application.c
+++ b/gnome-flashback/gf-application.c
@@ -28,6 +28,7 @@
#include "libdisplay-config/flashback-display-config.h"
#include "libend-session-dialog/gf-end-session-dialog.h"
#include "libidle-monitor/flashback-idle-monitor.h"
+#include "libinput-settings/gf-input-settings.h"
#include "libinput-sources/gf-input-sources.h"
#include "libnotifications/gf-notifications.h"
#include "libpolkit/flashback-polkit.h"
@@ -62,6 +63,7 @@ struct _GfApplication
GfBluetoothApplet *bluetooth;
GfDesktopBackground *background;
GfEndSessionDialog *dialog;
+ GfInputSettings *input_settings;
GfInputSources *input_sources;
GfNotifications *notifications;
GfPowerApplet *power;
@@ -160,6 +162,7 @@ settings_changed (GSettings *settings,
SETTING_CHANGED (bluetooth, "bluetooth-applet", gf_bluetooth_applet_new)
SETTING_CHANGED (background, "desktop-background", gf_desktop_background_new)
SETTING_CHANGED (dialog, "end-session-dialog", gf_end_session_dialog_new)
+ SETTING_CHANGED (input_settings, "input-settings", gf_input_settings_new)
SETTING_CHANGED (input_sources, "input-sources", gf_input_sources_new)
SETTING_CHANGED (notifications, "notifications", gf_notifications_new)
SETTING_CHANGED (power, "power-applet", gf_power_applet_new)
diff --git a/gnome-flashback/libinput-settings/Makefile.am b/gnome-flashback/libinput-settings/Makefile.am
new file mode 100644
index 0000000..c2f408b
--- /dev/null
+++ b/gnome-flashback/libinput-settings/Makefile.am
@@ -0,0 +1,32 @@
+NULL =
+
+noinst_LTLIBRARIES = \
+ libinput-settings.la \
+ $(NULL)
+
+libinput_settings_la_CPPFLAGS = \
+ -I$(top_builddir)/gnome-flashback/libinput-settings \
+ $(NULL)
+
+libinput_settings_la_CFLAGS = \
+ $(INPUT_SETTINGS_CFLAGS) \
+ $(WARN_CFLAGS) \
+ $(AM_CFLAGS) \
+ $(NULL)
+
+libinput_settings_la_SOURCES = \
+ gf-input-settings.c \
+ gf-input-settings.h \
+ $(NULL)
+
+libinput_settings_la_LDFLAGS = \
+ $(WARN_LDFLAGS) \
+ $(AM_LDFLAGS) \
+ $(NULL)
+
+libinput_settings_la_LIBADD = \
+ $(INPUT_SETTINGS_LIBS) \
+ $(LIBM) \
+ $(NULL)
+
+-include $(top_srcdir)/git.mk
diff --git a/gnome-flashback/libinput-settings/gf-input-settings.c
b/gnome-flashback/libinput-settings/gf-input-settings.c
new file mode 100644
index 0000000..963937f
--- /dev/null
+++ b/gnome-flashback/libinput-settings/gf-input-settings.c
@@ -0,0 +1,43 @@
+/*
+ * Copyright (C) 2016 Alberts Muktupāvels
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+#include "config.h"
+
+#include "gf-input-settings.h"
+
+struct _GfInputSettings
+{
+ GObject parent;
+};
+
+G_DEFINE_TYPE (GfInputSettings, gf_input_settings, G_TYPE_OBJECT)
+
+static void
+gf_input_settings_class_init (GfInputSettingsClass *settings_class)
+{
+}
+
+static void
+gf_input_settings_init (GfInputSettings *settings)
+{
+}
+
+GfInputSettings *
+gf_input_settings_new (void)
+{
+ return g_object_new (GF_TYPE_INPUT_SETTINGS, NULL);
+}
diff --git a/gnome-flashback/libinput-settings/gf-input-settings.h
b/gnome-flashback/libinput-settings/gf-input-settings.h
new file mode 100644
index 0000000..56e926a
--- /dev/null
+++ b/gnome-flashback/libinput-settings/gf-input-settings.h
@@ -0,0 +1,33 @@
+/*
+ * Copyright (C) 2016 Alberts Muktupāvels
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+#ifndef GF_INPUT_SETTINGS_H
+#define GF_INPUT_SETTINGS_H
+
+#include <glib-object.h>
+
+G_BEGIN_DECLS
+
+#define GF_TYPE_INPUT_SETTINGS gf_input_settings_get_type ()
+G_DECLARE_FINAL_TYPE (GfInputSettings, gf_input_settings,
+ GF, INPUT_SETTINGS, GObject)
+
+GfInputSettings *gf_input_settings_new (void);
+
+G_END_DECLS
+
+#endif
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]