File cinnamon-no-gksu-requirement.patch of Package cinnamon
--- a/files/usr/bin/cinnamon-settings-users
+++ b/files/usr/bin/cinnamon-settings-users
@@ -5,4 +5,4 @@
import os
-os.system("gksu /usr/share/cinnamon/cinnamon-settings-users/cinnamon-settings-users.py")
+os.system("xdg-su -c '/usr/share/cinnamon/cinnamon-settings-users/cinnamon-settings-users.py'")
--- a/files/usr/share/cinnamon/applets/menu@cinnamon.org/applet.js
+++ b/files/usr/share/cinnamon/applets/menu@cinnamon.org/applet.js
@@ -165,10 +165,6 @@ ApplicationContextMenuItem.prototype = {
AppFavorites.getAppFavorites().removeFavorite(this._appButton.app.get_id());
this._appButton.toggleMenu();
break;
- case "uninstall":
- Util.spawnCommandLine("gksu -m '" + _("Please provide your password to uninstall this application") + "' /usr/bin/cinnamon-remove-application '" + this._appButton.app.get_app_info().get_filename() + "'");
- this._appButton.appsMenuButton.menu.close();
- break;
case "run_with_nvidia_gpu":
Util.spawnCommandLine("optirun gtk-launch " + this._appButton.app.get_id());
this._appButton.appsMenuButton.menu.close();
--- a/files/usr/share/cinnamon/cinnamon-settings/bin/SettingsWidgets.py
+++ b/files/usr/share/cinnamon/cinnamon-settings/bin/SettingsWidgets.py
@@ -205,6 +205,7 @@ class SAModule:
def process (self):
name = self.name.replace("gksudo ", "")
name = name.replace("gksu ", "")
+ name = name.replace("xdg-su -c ", "")
name = name.split()[0]
for path in os.environ["PATH"].split(os.pathsep):
--- a/files/usr/share/cinnamon/cinnamon-settings/bin/Spices.py
+++ b/files/usr/share/cinnamon/cinnamon-settings/bin/Spices.py
@@ -449,9 +449,8 @@ class Spice_Harvester:
subprocess.call(["msgfmt", "-c", os.path.join(dirname, file.filename), "-o", os.path.join(this_locale_dir, '%s.mo' % uuid)])
ui_thread_do(self.progresslabel.set_text, _("Installing %s...") % title)
elif "gschema.xml" in file.filename:
- sentence = _("Please enter your password to install the required settings schema for %s") % (uuid)
- if os.path.exists("/usr/bin/gksu") and os.path.exists("/usr/share/cinnamon/cinnamon-settings/bin/installSchema.py"):
- launcher = "gksu --message \"<b>%s</b>\"" % sentence
+ if os.path.exists("/usr/bin/xdg-su") and os.path.exists("/usr/share/cinnamon/cinnamon-settings/bin/installSchema.py"):
+ launcher = "xdg-su -c"
tool = "/usr/share/cinnamon/cinnamon-settings/bin/installSchema.py %s" % (os.path.join(dirname, file.filename))
command = "%s %s" % (launcher, tool)
os.system(command)
@@ -551,9 +550,8 @@ class Spice_Harvester:
try:
if not self.themes:
if schema_filename != "":
- sentence = _("Please enter your password to remove the settings schema for %s") % (uuid)
- if os.path.exists("/usr/bin/gksu") and os.path.exists("/usr/share/cinnamon/cinnamon-settings/bin/removeSchema.py"):
- launcher = "gksu --message \"<b>%s</b>\"" % sentence
+ if os.path.exists("/usr/bin/xdg-su") and os.path.exists("/usr/share/cinnamon/cinnamon-settings/bin/removeSchema.py"):
+ launcher = "xdg-su -c"
tool = "/usr/share/cinnamon/cinnamon-settings/bin/removeSchema.py %s" % (schema_filename)
command = "%s %s" % (launcher, tool)
os.system(command)