def METHOD_NAME():
    def initEnhancements(self):
        self.listeners = {}
    def onChangedValue(self, key, user_func):
        if key not in self.listeners:
            self.listeners[key] = []
        self.listeners[key].append(user_func)
    def triggerOnChangedValue(self, settings, key, user_data=None):
        if key in self.listeners:
            for func in self.listeners[key]:
                func(settings, key, user_data)
    gi.repository.Gio.Settings.initEnhancements = initEnhancements
    gi.repository.Gio.Settings.onChangedValue = onChangedValue
    gi.repository.Gio.Settings.triggerOnChangedValue = triggerOnChangedValue