|
|
2b55cd |
From 2c390d60532437972c2d28fd70a54c07c71b74db Mon Sep 17 00:00:00 2001
|
|
|
2b55cd |
From: Rui Matos <tiagomatos@gmail.com>
|
|
|
2b55cd |
Date: Wed, 8 Apr 2015 15:08:16 +0200
|
|
|
2b55cd |
Subject: [PATCH 10/12] shell_extensions: SESSION_MODE extensions can't be
|
|
|
2b55cd |
enabled/disabled
|
|
|
2b55cd |
|
|
|
2b55cd |
gnome-shell always enables this kind of extensions and doesn't allow
|
|
|
2b55cd |
disabling them so reflect that in the UI.
|
|
|
2b55cd |
---
|
|
|
2b55cd |
gtweak/tweaks/tweak_group_shell_extensions.py | 6 ++++--
|
|
|
2b55cd |
1 file changed, 4 insertions(+), 2 deletions(-)
|
|
|
2b55cd |
|
|
|
2b55cd |
diff --git a/gtweak/tweaks/tweak_group_shell_extensions.py b/gtweak/tweaks/tweak_group_shell_extensions.py
|
|
|
2b55cd |
index 1f6b7f0..a36515b 100644
|
|
|
2b55cd |
--- a/gtweak/tweaks/tweak_group_shell_extensions.py
|
|
|
2b55cd |
+++ b/gtweak/tweaks/tweak_group_shell_extensions.py
|
|
|
2b55cd |
@@ -49,7 +49,8 @@ class _ShellExtensionTweak(Gtk.ListBoxRow, Tweak):
|
|
|
2b55cd |
sw = Gtk.Switch()
|
|
|
2b55cd |
sw.props.vexpand = False
|
|
|
2b55cd |
sw.props.valign = Gtk.Align.CENTER
|
|
|
2b55cd |
- sw.set_active(self._shell.extension_is_active(state, uuid))
|
|
|
2b55cd |
+ sw.set_active(self._shell.extension_is_active(state, uuid) or
|
|
|
2b55cd |
+ ext.get("type") == GnomeShell.EXTENSION_TYPE["SESSION_MODE"])
|
|
|
2b55cd |
sw.connect('notify::active', self._on_extension_toggled, uuid)
|
|
|
2b55cd |
self.hbox.pack_start(sw, False, False, 0)
|
|
|
2b55cd |
|
|
|
2b55cd |
@@ -72,7 +73,8 @@ class _ShellExtensionTweak(Gtk.ListBoxRow, Tweak):
|
|
|
2b55cd |
if state == GnomeShell.EXTENSION_STATE["ENABLED"] or \
|
|
|
2b55cd |
state == GnomeShell.EXTENSION_STATE["DISABLED"] or \
|
|
|
2b55cd |
state == GnomeShell.EXTENSION_STATE["INITIALIZED"]:
|
|
|
2b55cd |
- sensitive = True
|
|
|
2b55cd |
+ if ext.get("type") != GnomeShell.EXTENSION_TYPE["SESSION_MODE"]:
|
|
|
2b55cd |
+ sensitive = True
|
|
|
2b55cd |
elif state == GnomeShell.EXTENSION_STATE["DOWNLOADING"]:
|
|
|
2b55cd |
info = _("Extension downloading")
|
|
|
2b55cd |
elif state == GnomeShell.EXTENSION_STATE["ERROR"]:
|
|
|
2b55cd |
--
|
|
|
2b55cd |
2.3.6
|
|
|
2b55cd |
|