Blame SOURCES/0001-layout-Make-the-hot-corner-optional.patch

21e770
From 35cbad572120125d3b823f37d2100b2beee4c1d8 Mon Sep 17 00:00:00 2001
21e770
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
21e770
Date: Thu, 8 Jun 2017 17:07:56 +0200
21e770
Subject: [PATCH] layout: Make the hot corner optional
21e770
21e770
Whether people love or hate the hot corner depends in large extents
21e770
on hardware sensitivity and habits, which is hard to get right
21e770
universally. So bite the bullet and support an option to enable or
21e770
disable hot corners ...
21e770
21e770
https://bugzilla.gnome.org/show_bug.cgi?id=688320
21e770
---
21e770
 js/ui/layout.js | 14 +++++++++++++-
21e770
 1 file changed, 13 insertions(+), 1 deletion(-)
21e770
21e770
diff --git a/js/ui/layout.js b/js/ui/layout.js
21e770
index 2b3bb7442..beb4c0a5d 100644
21e770
--- a/js/ui/layout.js
21e770
+++ b/js/ui/layout.js
21e770
@@ -1,6 +1,6 @@
21e770
 // -*- mode: js; js-indent-level: 4; indent-tabs-mode: nil -*-
21e770
 
21e770
-const { Clutter, GLib, GObject, Meta, Shell, St } = imports.gi;
21e770
+const { Clutter, Gio, GLib, GObject, Meta, Shell, St } = imports.gi;
21e770
 const Signals = imports.signals;
21e770
 
21e770
 const Background = imports.ui.background;
21e770
@@ -267,6 +267,13 @@ var LayoutManager = GObject.registerClass({
21e770
         this._backgroundGroup.lower_bottom();
21e770
         this._bgManagers = [];
21e770
 
21e770
+        this._interfaceSettings = new Gio.Settings({
21e770
+            schema_id: 'org.gnome.desktop.interface'
21e770
+        });
21e770
+
21e770
+       this._interfaceSettings.connect('changed::enable-hot-corners',
21e770
+                                       this._updateHotCorners.bind(this));
21e770
+
21e770
         // Need to update struts on new workspaces when they are added
21e770
         let workspaceManager = global.workspace_manager;
21e770
         workspaceManager.connect('notify::n-workspaces',
21e770
@@ -358,6 +365,11 @@ var LayoutManager = GObject.registerClass({
21e770
         });
21e770
         this.hotCorners = [];
21e770
 
21e770
+        if (!this._interfaceSettings.get_boolean('enable-hot-corners')) {
21e770
+            this.emit('hot-corners-changed');
21e770
+            return;
21e770
+        }
21e770
+
21e770
         let size = this.panelBox.height;
21e770
 
21e770
         // build new hot corners
21e770
-- 
21e770
2.21.0
21e770